blob_id
stringlengths
40
40
directory_id
stringlengths
40
40
path
stringlengths
7
390
content_id
stringlengths
40
40
detected_licenses
sequencelengths
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
sequencelengths
1
1
author_id
stringlengths
1
79
6453bf760d6f645d5b270b9ef9bbbc16c9ff55de
b31120cefe3991a960833a21ed54d4e10770bc53
/modules/org.llvm.analysis/src/org/llvm/analysis/bfi_detail/TypeMapBasicBlock.java
949123b3c2a7a70e2434a5c1369d5e4da9ca71de
[]
no_license
JianpingZeng/clank
94581710bd89caffcdba6ecb502e4fdb0098caaa
bcdf3389cd57185995f9ee9c101a4dfd97145442
refs/heads/master
2020-11-30T05:36:06.401287
2017-10-26T14:15:27
2017-10-26T14:15:27
null
0
0
null
null
null
null
UTF-8
Java
false
false
5,645
java
/** * This file was converted to Java from the original LLVM source file. The original * source file follows the LLVM Release License, outlined below. * * ============================================================================== * LLVM Release License * ============================================================================== * University of Illinois/NCSA * Open Source License * * Copyright (c) 2003-2017 University of Illinois at Urbana-Champaign. * All rights reserved. * * Developed by: * * LLVM Team * * University of Illinois at Urbana-Champaign * * http://llvm.org * * Permission is hereby granted, free of charge, to any person obtaining a copy of * this software and associated documentation files (the "Software"), to deal with * the Software without restriction, including without limitation the rights to * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies * of the Software, and to permit persons to whom the Software is furnished to do * so, subject to the following conditions: * * * Redistributions of source code must retain the above copyright notice, * this list of conditions and the following disclaimers. * * * Redistributions in binary form must reproduce the above copyright notice * this list of conditions and the following disclaimers in the * documentation and/or other materials provided with the distribution. * * * Neither the names of the LLVM Team, University of Illinois at * Urbana-Champaign, nor the names of its contributors may be used to * endorse or promote products derived from this Software without specific * prior written permission. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE * CONTRIBUTORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS WITH THE * SOFTWARE. * * ============================================================================== * Copyrights and Licenses for Third Party Software Distributed with LLVM: * ============================================================================== * The LLVM software contains code written by third parties. Such software will * have its own individual LICENSE.TXT file in the directory in which it appears. * This file will describe the copyrights, license, and restrictions which apply * to that code. * * The disclaimer of warranty in the University of Illinois Open Source License * applies to all code in the LLVM Distribution, and nothing in any of the * other licenses gives permission to use the names of the LLVM Team or the * University of Illinois to endorse or promote products derived from this * Software. * * The following pieces of software have additional or alternate copyrights, * licenses, and/or restrictions: * * Program Directory * ------- --------- * Autoconf llvm/autoconf * llvm/projects/ModuleMaker/autoconf * Google Test llvm/utils/unittest/googletest * OpenBSD regex llvm/lib/Support/{reg*, COPYRIGHT.regex} * pyyaml tests llvm/test/YAMLParser/{*.data, LICENSE.TXT} * ARM contributions llvm/lib/Target/ARM/LICENSE.TXT * md5 contributions llvm/lib/Support/MD5.cpp llvm/include/llvm/Support/MD5.h */ package org.llvm.analysis.bfi_detail; import org.clank.java.*; import org.clank.support.*; import org.clank.support.aliases.*; import org.clank.support.JavaDifferentiators.*; import static org.clank.java.built_in.*; import static org.clank.support.Casts.*; import static org.clank.java.io.*; import static org.clank.java.std.*; import static org.clank.java.std_pair.*; import static org.llvm.adt.ADTAliases.*; import static org.llvm.support.llvm.*; import static org.clank.support.NativePointer.*; import static org.clank.support.NativeType.*; import static org.clank.support.Native.*; import static org.clank.support.Unsigned.*; import org.clank.support.NativeCallback.*; import org.llvm.support.*; import org.llvm.adt.*; import org.llvm.adt.aliases.*; import org.llvm.ir.*; import org.llvm.pass.*; import static org.llvm.ir.PassManagerGlobals.*; //<editor-fold defaultstate="collapsed" desc="llvm::bfi_detail::TypeMap<BasicBlock>"> @Converted(kind = Converted.Kind.AUTO_NO_BODY, source = "${LLVM_SRC}/llvm/include/llvm/Analysis/BlockFrequencyInfoImpl.h", line = 505, FQN="llvm::bfi_detail::TypeMap<BasicBlock>", NM="_ZN4llvm10bfi_detail7TypeMapINS_10BasicBlockEEE", cmd="jclank.sh -java-options=${SPUTNIK}/modules/org.llvm.analysis/llvmToClangType ${LLVM_SRC}/llvm/lib/Analysis/BlockFrequencyInfoImpl.cpp -nm=_ZN4llvm10bfi_detail7TypeMapINS_10BasicBlockEEE") //</editor-fold> public class/*struct*/ TypeMapBasicBlock { // JAVA: typedef BasicBlock BlockT // public final class BlockT extends BasicBlock{ }; // JAVA: typedef Function FunctionT // public final class FunctionT extends Function{ }; // JAVA: typedef BranchProbabilityInfo BranchProbabilityInfoT // public final class BranchProbabilityInfoT extends BranchProbabilityInfo{ }; // JAVA: typedef Loop LoopT // public final class LoopT extends Loop{ }; // JAVA: typedef LoopInfo LoopInfoT // public final class LoopInfoT extends LoopInfo{ }; @Override public String toString() { return ""; // NOI18N } }
[ "voskresensky.vladimir@gmail.com" ]
voskresensky.vladimir@gmail.com
93c9d2be931d2144dcaf9635610a5093065a58b9
e57083ea584d69bc9fb1b32f5ec86bdd4fca61c0
/sample-project-5400/src/main/java/com/example/project/sample5400/domain/sample2/Entity2_12.java
59626e43c67a17811c5b8f7367ed28a8c4b1c0b6
[]
no_license
snicoll-scratches/test-spring-components-index
77e0ad58c8646c7eb1d1563bf31f51aa42a0636e
aa48681414a11bb704bdbc8acabe45fa5ef2fd2d
refs/heads/main
2021-06-13T08:46:58.532850
2019-12-09T15:11:10
2019-12-09T15:11:10
65,806,297
5
3
null
null
null
null
UTF-8
Java
false
false
466
java
package com.example.project.sample5400.domain.sample2; import javax.persistence.Entity; import javax.persistence.GeneratedValue; import javax.persistence.Id; @Entity public class Entity2_12 { @Id @GeneratedValue private long id; private String description; public long getId() { return this.id; } public String getDescription() { return this.description; } public void setDescription(String description) { this.description = description; } }
[ "snicoll@pivotal.io" ]
snicoll@pivotal.io
2c9010906e064b8179abf1e1f39b29a74d12365c
4f4ddc396fa1dfc874780895ca9b8ee4f7714222
/src/java/com/gensym/com/beans/office20/MsoExtraInfoMethod.java
5568d12cc1fbb59412c1c0ab321c7df92e2991bf
[]
no_license
UtsavChokshiCNU/GenSym-Test2
3214145186d032a6b5a7486003cef40787786ba0
a48c806df56297019cfcb22862dd64609fdd8711
refs/heads/master
2021-01-23T23:14:03.559378
2017-09-09T14:20:09
2017-09-09T14:20:09
102,960,203
3
5
null
null
null
null
UTF-8
Java
false
false
1,246
java
package com.gensym.com.beans.office20; import com.gensym.com.ActiveXModes; import com.gensym.com.ActiveXProxy; import com.gensym.com.ActiveXException; import com.gensym.com.ActiveXCastException; import com.gensym.com.Guid; import com.gensym.com.ActiveXDefaultComponentImpl; import com.gensym.com.ActiveXDispatchable; import com.gensym.com.ActiveXDispatchableImpl; import com.gensym.com.NativeMethodBroker; import com.gensym.com.Variant; import com.gensym.com.Hwnd; import java.awt.Color; import java.util.Date; import java.util.Vector; public interface MsoExtraInfoMethod { public static final Guid classID = new Guid(0x0, 0x0, 0x0, (short) 0x0, (short) 0x0, (short) 0x0, (short) 0x0, (short) 0x0, (short) 0x0, (short) 0x0, (short) 0x0); // Library name is: Office // DocString is: Microsoft Office 8.0 Object Library // Help file is: C:\Program Files\Microsoft Office\Office\vbaoff8.hlp // There are 121 TypeInfos in the library /* Type info #57 An enumeration type. Type info name is: MsoExtraInfoMethod Help file is: C:\Program Files\Microsoft Office\Office\vbaoff8.hlp */ public static final int MSO_METHOD_GET = 0; public static final int MSO_METHOD_POST = 1; }
[ "utsavchokshi@Utsavs-MacBook-Pro.local" ]
utsavchokshi@Utsavs-MacBook-Pro.local
ad2385438188ca61d5fa7325cf418df0362c1ca2
dc0919c9609f03f5b239ec0799cea22ed070f411
/cn/jpush/b/a/a/b.java
6d42656ccf5d3a67f3e318f2ffc437961b6b23fd
[]
no_license
jjensn/milight-decompile
a8f98af475f452c18a74fd1032dce8680f23abc0
47c4b9eea53c279f6fab3e89091e2fef495c6159
refs/heads/master
2021-06-01T17:23:28.555123
2016-10-12T18:07:53
2016-10-12T18:07:53
70,721,205
5
0
null
null
null
null
UTF-8
Java
false
false
2,564
java
package cn.jpush.b.a.a; import cn.jpush.android.util.j; import cn.jpush.b.a.c.a; import java.nio.ByteBuffer; public final class b extends i { private static final String[] z; long a; String b; static { String[] arrayOfString1 = new String[3]; String str1 = "\002:\034K\bmu\037L\n@nK"; int i = -1; String[] arrayOfString2 = arrayOfString1; int j = 0; Object localObject1 = str1.toCharArray(); int k = localObject1.length; int m; label35: int i3; if (k <= 1) { m = 0; Object localObject2 = localObject1; int n = m; int i1 = k; Object localObject3 = localObject1; while (true) { int i2 = localObject3[m]; switch (n % 5) { default: i3 = 111; label96: localObject3[m] = (char)(i3 ^ i2); m = n + 1; if (i1 != 0) break label133; localObject3 = localObject2; n = m; m = i1; case 0: case 1: case 2: case 3: } } label133: k = i1; localObject1 = localObject2; } while (true) { if (k > m) break label35; String str2 = new String((char[])localObject1).intern(); switch (i) { default: arrayOfString2[j] = str2; str1 = "\0167Q"; j = 1; arrayOfString2 = arrayOfString1; i = 0; break; case 0: arrayOfString2[j] = str2; j = 2; arrayOfString2 = arrayOfString1; str1 = ""; i = 1; break; case 1: arrayOfString2[j] = str2; z = arrayOfString1; return; i3 = 46; break label96; i3 = 26; break label96; i3 = 113; break label96; i3 = 56; break label96; m = 0; } } } public b(f paramf, ByteBuffer paramByteBuffer) { super(paramf, paramByteBuffer); } public final long a() { return this.a; } public final void b() { super.b(); a(this.a); a(this.b); } public final void c() { super.c(); ByteBuffer localByteBuffer = this.f; this.a = j.d(localByteBuffer, this); this.b = a.a(localByteBuffer, this); } public final String d() { return this.b; } public final String toString() { return z[2] + this.a + z[0] + this.b + z[1] + super.toString(); } } /* Location: * Qualified Name: cn.jpush.b.a.a.b * Java Class Version: 6 (50.0) * JD-Core Version: 0.6.1-SNAPSHOT */
[ "jjensen@GAM5YG3QC-MAC.local" ]
jjensen@GAM5YG3QC-MAC.local
1402b1502b2348b1ac73ee8a429c2542b0b76b33
e90bdfa1ff773af90a7f02e4d34d846f2ba42252
/src/main/java/com/ivoronline/springboot_filter_chain/filters/MyFilter2.java
f64bec7284d2b3d2b37c4f96abd197a8f73792e5
[]
no_license
ivoronline/springboot_filter_chain
60d747ed5dd8a5bdd911135a2682ae8b8d2529a2
2267c9b058a55d088d5da2bffaa2d6a54e6fc777
refs/heads/master
2023-03-28T22:40:50.847035
2021-04-15T09:18:00
2021-04-15T09:18:00
344,490,129
0
0
null
null
null
null
UTF-8
Java
false
false
890
java
package com.ivoronline.springboot_filter_chain.filters; import org.springframework.core.annotation.Order; import org.springframework.stereotype.Component; import javax.servlet.Filter; import javax.servlet.FilterChain; import javax.servlet.ServletException; import javax.servlet.ServletRequest; import javax.servlet.ServletResponse; import java.io.IOException; @Component @Order(1) public class MyFilter2 implements Filter { @Override public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException { //THIS CODE IS EXECUTED DURING HTTP REQUEST System.out.println("MyFilter2 : Code for HTTP Request"); //DIVIDES HTTP REQUEST AND RESPONSE CODE chain.doFilter(request, response); //THIS CODE IS EXECUTED DURING HTTP RESPONSE System.out.println("MyFilter2 : Code for HTTP Response"); } }
[ "ivoronline@gmail.com" ]
ivoronline@gmail.com
5fdd04855d92d71c584ef2c50b8f782bced85ff7
3ae112a1e0cfb8139e56cf285cb174e8f7e29529
/0000-Interview/singleton_code/src/cn/liuawen/single/Singleton2.java
1a7d6859a2b7176de03b0dac81de4792c865594b
[]
no_license
liuawen/Play-Leetcode
af8f4e9e5e25ab534df129881443ac1a2b2d79b7
790cca15c44db3f756992a61cfdf576df40eb62c
refs/heads/master
2023-03-08T16:31:08.747905
2023-02-26T00:05:51
2023-02-26T00:05:51
293,091,784
1
0
null
null
null
null
UTF-8
Java
false
false
264
java
package cn.liuawen.single; /** * @author Liu Awen Email:willowawen@gmail.com * @create 2020-09-19 * 枚举类型 表示该类型的对象是有限的几个 * 我们可以限定为一个,就成了单例 * 1.5 JDK */ public enum Singleton2 { INSTANCE }
[ "157514367@qq.com" ]
157514367@qq.com
519d5eee7b0cb3e808c05eaa314f74290e9fe7aa
fcdc2350bc03d7b44e1aaf1f4af82f5ef65f6311
/src/msg/manage/modal/Pager.java
fb38c7e853bc90beb9520938fb8738d166c2d585
[]
no_license
amykiki/JavaWeb
72f0fc6c2b4920388ea3d516df9d01811d4b4dad
9a594b9095e07c7c6475ea80a569946198d847b4
refs/heads/master
2021-01-10T14:30:19.767129
2016-03-11T16:29:26
2016-03-11T16:29:26
52,582,847
0
0
null
null
null
null
UTF-8
Java
false
false
688
java
package msg.manage.modal; import java.util.List; /** * Created by Amysue on 2016/3/10. */ public class Pager { private List<User> users; private int itemCounts; private int currentPage; public int getCurrentPage() { return currentPage; } public void setCurrentPage(int currentPage) { this.currentPage = currentPage; } public int getItemCounts() { return itemCounts; } public void setItemCounts(int itemCounts) { this.itemCounts = itemCounts; } public List<User> getUsers() { return users; } public void setUsers(List<User> users) { this.users = users; } }
[ "staramy_2005@126.com" ]
staramy_2005@126.com
9cc5c1b5bf18d333c4e7dabf8211e72a3f0c3725
ae6b81c27beb19b928d39034e2d102f568c4d76b
/ph-csscompress-maven-plugin/src/test/java/com/helger/maven/csscompress/SPITest.java
3faa0bf28b54434a0fafac349f2d35f553f33a47
[ "Apache-2.0" ]
permissive
elikonky-houzz/ph-css
18d771476ffc98f2fe49aa0377b9ccb9bea26faa
f8d558cac89be6fe9162c200072b8696bba02071
refs/heads/master
2021-07-22T18:45:38.625018
2017-10-16T05:07:52
2017-10-16T05:07:52
108,165,518
0
0
null
2017-10-24T18:12:08
2017-10-24T18:12:07
null
UTF-8
Java
false
false
990
java
/** * Copyright (C) 2014-2017 Philip Helger (www.helger.com) * philip[at]helger[dot]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.helger.maven.csscompress; import org.junit.Test; import com.helger.commons.mock.SPITestHelper; /** * Test SPI configuration consistency. * * @author Philip Helger */ public final class SPITest { @Test public void testBasic () throws Exception { SPITestHelper.testIfAllSPIImplementationsAreValid (); } }
[ "philip@helger.com" ]
philip@helger.com
fbc60abcb46d8ec6be128d7b9aa47d34d7ebc87b
be73270af6be0a811bca4f1710dc6a038e4a8fd2
/crash-reproduction-moho/results/XWIKI-13544-18-8-MOEAD-WeightedSum:TestLen:CallDiversity/org/xwiki/velocity/internal/DefaultVelocityEngine_ESTest_scaffolding.java
42f0f5cacab3d54137cc5b706c30f189b17ba0fc
[]
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
453
java
/** * Scaffolding file used to store all the setups needed to run * tests automatically generated by EvoSuite * Sun Jan 19 22:55:36 UTC 2020 */ package org.xwiki.velocity.internal; import org.evosuite.runtime.annotation.EvoSuiteClassExclude; import org.junit.BeforeClass; import org.junit.Before; import org.junit.After; @EvoSuiteClassExclude public class DefaultVelocityEngine_ESTest_scaffolding { // Empty scaffolding for empty test suite }
[ "pouria.derakhshanfar@gmail.com" ]
pouria.derakhshanfar@gmail.com
3a5cc0e4881839e5b3cd4ca7368943f43f2eccc8
447520f40e82a060368a0802a391697bc00be96f
/apks/malware/app92/source/com/yongrun/app/sxmn/ui/cp.java
adec808bb2d4d2bc5027adc09e3fd5ea62d08367
[ "Apache-2.0" ]
permissive
iantal/AndroidPermissions
7f3343a9c29d82dbcd4ecd98b3a50ddf8d179465
d623b732734243590b5f004d167e542e2e2ae249
refs/heads/master
2023-07-19T01:29:26.689186
2019-09-30T19:01:42
2019-09-30T19:01:42
107,239,248
0
0
Apache-2.0
2023-07-16T07:41:38
2017-10-17T08:22:57
null
UTF-8
Java
false
false
1,464
java
package com.yongrun.app.sxmn.ui; import android.app.Activity; import android.content.Context; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.BaseAdapter; import com.yongrun.app.sxmn.c.c; import com.yongrun.app.sxmn.common.AppContext; import com.yongrun.app.sxmn.widget.ClassifyView; import java.util.List; public class cp extends BaseAdapter { private Context b; private LayoutInflater c; private com.a.a.b.d d; private List<c> e; public cp(Context paramContext, List<c> paramList) { this.b = paramList; this.c = ((LayoutInflater)this.b.getSystemService("layout_inflater")); this.d = ((AppContext)ThirdFragment.b(paramContext).getApplication()).a(); Object localObject; this.e = localObject; } public int getCount() { return this.e.size(); } public Object getItem(int paramInt) { return Integer.valueOf(paramInt); } public long getItemId(int paramInt) { return paramInt; } public View getView(int paramInt, View paramView, ViewGroup paramViewGroup) { paramView = new ClassifyView(ThirdFragment.b(this.a)); paramViewGroup = (c)this.e.get(paramInt); paramView.setTitle(paramViewGroup.b()); paramView.setTypeid(paramViewGroup.a()); paramView.a(paramViewGroup.c(), this.d); paramView.setHeight(com.yongrun.app.sxmn.common.d.a(ThirdFragment.b(this.a)).b() / 3); return paramView; } }
[ "antal.micky@yahoo.com" ]
antal.micky@yahoo.com
6482719ba9b902838efddffa850da4444f790b33
f232c2c7966e5769d1f68af87c83615fe4202870
/backend/manager/modules/compat/src/test/java/org/ovirt/engine/core/compat/PropertyCompatTest.java
b62a4d8f6dac7c674d74dccaed36bfec64a13692
[]
no_license
BillTheBest/ovirt-engine
54d0d3cf5b103c561c4e72e65856948f252b41a1
7d5d711b707e080a69920eb042f6f547dfa9443f
refs/heads/master
2016-08-05T16:52:16.557733
2011-11-07T02:49:42
2011-11-07T02:49:42
2,938,776
1
1
null
null
null
null
UTF-8
Java
false
false
826
java
package org.ovirt.engine.core.compat; import org.ovirt.engine.core.compat.backendcompat.PropertyCompat; import org.ovirt.engine.core.compat.backendcompat.TypeCompat; import junit.framework.TestCase; public class PropertyCompatTest extends TestCase { public String someValue = "Anakin"; public void testIt() { PropertyCompat pc = TypeCompat.GetProperty(this.getClass(), "someValue"); String result = (String) pc.GetValue(this, "JarJar"); assertEquals("Standard", "Anakin", result); this.someValue = null; result = (String) pc.GetValue(this, "JarJar"); assertEquals("Null Value", "JarJar", result); } public String getSomeValue() { return someValue; } public void setSomeValue(String someValue) { this.someValue = someValue; } }
[ "liuyang3240@gmail.com" ]
liuyang3240@gmail.com
8fe6f66036ffa22fa8fa4bbf160346e5f69f395c
717c58d0bbe61b806360796a61ec4ad7ab817191
/tests/org.jboss.tools.central.ui.bot.test/src/org/jboss/tools/central/test/ui/reddeer/BasicTests.java
5b0f7d0a24529d8fbfd20fe493b10ff7dd52b2a8
[]
no_license
robstryker/jbosstools-integration-tests
a4bcd62548c31ae24071d6656fd6a2495421d5fe
eadc2573bfbd61985a1138ad5f6ff14fb9d92481
refs/heads/master
2023-08-30T08:00:38.343607
2015-07-28T14:26:50
2015-07-28T14:49:34
39,847,884
0
0
null
2015-07-28T17:23:13
2015-07-28T17:23:12
null
UTF-8
Java
false
false
6,010
java
package org.jboss.tools.central.test.ui.reddeer; import static org.junit.Assert.assertNotEquals; import java.util.ArrayList; import java.util.List; import org.eclipse.swt.SWT; import org.eclipse.swt.widgets.Control; import org.jboss.reddeer.common.matcher.RegexMatcher; import org.jboss.reddeer.common.wait.WaitWhile; import org.jboss.reddeer.core.condition.JobIsRunning; import org.jboss.reddeer.core.lookup.WidgetLookup; import org.jboss.reddeer.core.matcher.WithTooltipTextMatcher; import org.jboss.reddeer.core.reference.ReferencedComposite; import org.jboss.reddeer.eclipse.ui.browser.BrowserEditor; import org.jboss.reddeer.swt.api.Text; import org.jboss.reddeer.swt.exception.SWTLayerException; import org.jboss.reddeer.swt.impl.clabel.DefaultCLabel; import org.jboss.reddeer.swt.impl.menu.ToolItemMenu; import org.jboss.reddeer.swt.impl.shell.DefaultShell; import org.jboss.reddeer.swt.impl.text.DefaultText; import org.jboss.reddeer.swt.impl.toolbar.DefaultToolItem; import org.jboss.reddeer.swt.keyboard.KeyboardFactory; import org.jboss.reddeer.uiforms.api.FormText; import org.jboss.reddeer.uiforms.api.Section; import org.jboss.reddeer.uiforms.impl.formtext.DefaultFormText; import org.jboss.reddeer.uiforms.impl.hyperlink.DefaultHyperlink; import org.jboss.reddeer.uiforms.impl.section.DefaultSection; import org.jboss.reddeer.workbench.impl.editor.DefaultEditor; import org.jboss.reddeer.workbench.impl.shell.WorkbenchShell; import org.jboss.tools.central.editors.xpl.TextSearchControl; import org.junit.Before; import org.junit.Test; public class BasicTests { @Before public void setup() { new DefaultToolItem(new WorkbenchShell(), "JBoss Central").click(); // activate central editor new DefaultEditor("JBoss Central"); } @Test public void documentationTest() { checkDocumentationLink("JBoss developer website", "JBoss Developer"); checkDocumentationLink("User Forum", "Space: JBoss Tools | Community"); checkDocumentationLink("Developer Forum", "Space: JBoss Tools Development | Community"); checkDocumentationLink("Product documentation", "JBoss Tools - Documentation"); checkDocumentationLink("Videos", "JBoss Tools - Video Tutorials"); KeyboardFactory.getKeyboard().type('\r'); } @Test public void jBossToolsHomeToolItemTest() { new DefaultToolItem("JBoss Tools Home").click(); checkBrowserOpenedAndLoaded("JBoss Tools - Home"); } @Test public void favoriteToolItemTest() { new DefaultToolItem(new WithTooltipTextMatcher(new RegexMatcher("Favorite this.*"))).click(); checkBrowserOpenedAndLoaded(".*Eclipse Marketplace.*"); } @Test public void newToolItemTest(){ DefaultToolItem item = new DefaultToolItem("New"); item.click(); new DefaultShell("New").close(); new ToolItemMenu(item, "Other...").select(); new DefaultShell("New").close(); } @Test public void projectExamplesToolItemTest(){ new DefaultToolItem("Project Examples Wizard").click(); new DefaultShell("New Project Example").close(); } @Test public void runtimeDetectionToolItemTest(){ new DefaultToolItem("JBoss Runtime Detection").click(); DefaultShell defaultShell = new DefaultShell("Preferences"); new DefaultCLabel("JBoss Runtime Detection"); defaultShell.close(); } @Test public void wtpRuntimeToolItemTest(){ new DefaultToolItem("WTP Runtime Preferences").click(); DefaultShell defaultShell = new DefaultShell("Preferences"); new DefaultCLabel("Server Runtime Environments"); defaultShell.close(); } @Test public void refreshToolItemTest(){ new DefaultToolItem(0, "Refresh").click(); new DefaultToolItem(1, "Refresh").click(); new WaitWhile(new JobIsRunning()); } @Test public void buzzToolItemTest(){ new DefaultToolItem("JBoss Buzz").click(); checkBrowserOpenedAndLoaded("JBoss Buzz.*"); } @Test public void twitterToolItemTest(){ new DefaultToolItem("Twitter"); //do not click -> it opens external browser } @Test public void buzzFeedIsNotEmptyTest(){ DefaultSection buzzSection = new DefaultSection("JBoss Buzz"); List<FormText> texts = getAllFormTextForSection(buzzSection); assertNotEquals(texts.size(), 0); } @Test public void ticketMonsterLinkTest(){ DefaultSection tutorialSection = new DefaultSection("Tutorial"); DefaultHyperlink link = new DefaultHyperlink(tutorialSection); link.activate(); checkBrowserOpenedAndLoaded("Ticket Monster tutorial"); } @Test public void searchTest(){ TextSearchControlComposite searchComposite = new TextSearchControlComposite(); Text text = new DefaultText(searchComposite); text.setText("Pokus"); KeyboardFactory.getKeyboard().type(SWT.CR); checkBrowserOpenedAndLoaded("Pokus.*"); } private void checkDocumentationLink(String linkText, String title) { new DefaultHyperlink(linkText).activate(); checkBrowserOpenedAndLoaded(title); } private void checkBrowserOpenedAndLoaded(String title){ new WaitWhile(new JobIsRunning()); BrowserEditor browser = new BrowserEditor(new RegexMatcher(title)); browser.close(); KeyboardFactory.getKeyboard().invokeKeyCombination(SWT.CTRL, SWT.SPACE); } private List<FormText> getAllFormTextForSection(Section section) { List<FormText> list = new ArrayList<FormText>(); boolean found = true; int index = 0; do { try { list.add(new DefaultFormText(section, index++)); } catch (SWTLayerException e) { found = false; } } while (found); return list; } private class TextSearchControlComposite implements ReferencedComposite{ TextSearchControl widget; public TextSearchControlComposite() { try{ widget = WidgetLookup.getInstance().activeWidget(new WorkbenchShell(), TextSearchControl.class, 0); }catch(SWTLayerException e){ DefaultEditor defaultEditor = new DefaultEditor(); widget = WidgetLookup.getInstance().activeWidget(new WorkbenchShell(), TextSearchControl.class, 0); defaultEditor.maximize(); } } @Override public Control getControl() { return widget; } } }
[ "vpakan@redhat.com" ]
vpakan@redhat.com
7c0c1c026182d083bd0489d47611c5790cc1e44a
1b5987a7e72a58e12ac36a36a60aa6add2661095
/code/org/processmining/analysis/epc/epcmetrics/ControlFlow.java
92850cf53c8f9f24b96070b0818ac5d4b95a59d1
[]
no_license
qianc62/BePT
f4b1da467ee52e714c9a9cc2fb33cd2c75bdb5db
38fb5cc5521223ba07402c7bb5909b17967cfad8
refs/heads/master
2021-07-11T16:25:25.879525
2020-09-22T10:50:51
2020-09-22T10:50:51
201,562,390
36
0
null
null
null
null
UTF-8
Java
false
false
3,440
java
/* * The Complexity formula implemented * on this class was proposed by Jorge Cardoso * on his paper "How to Measure the Control-flow Complexity of Web Processes and Workflows" . * http://dme.uma.pt/jcardoso/Research/Papers/Control-flow Complexity-WorkflowHandbook.pdf * */ package org.processmining.analysis.epc.epcmetrics; import org.processmining.framework.models.epcpack.ConfigurableEPC; import org.processmining.framework.models.epcpack.EPCConnector; import org.processmining.framework.models.epcpack.EPCObject; import org.processmining.framework.ui.Message; public class ControlFlow implements ICalculator { private final static String TYPE = "Control-Flow"; private final static String NAME = "Control-Flow"; private ConfigurableEPC epc; public ControlFlow(ConfigurableEPC aEpc) { epc = aEpc; } public String Calculate() { Message.add("\t<CFC>", Message.TEST); int i = epc.getConnectors().size(); int result = 0; for (int count = 0; count < i; count++) { if (epc.getConnectors().get(count).toString().endsWith("join")) { continue; } if (epc.getConnectors().get(count).toString().startsWith("XOR")) { EPCObject epcObj = (EPCObject) epc.getConnectors().get(count); result = result + fanout(epcObj); Message.add("\t\t<XORConnector " + "name=\"" + ((EPCConnector) epc.getConnectors().get(count)) .toString() + "\" " + "value=\"" + fanout(epcObj) + "\"/>", Message.TEST); } else if (epc.getConnectors().get(count).toString().startsWith( "OR")) { EPCObject epcObj = (EPCObject) epc.getConnectors().get(count); int temp = power(2, fanout(epcObj)) - 1; result = result + temp; Message.add("\t\t<ORConnector " + "name=\"" + ((EPCConnector) epc.getConnectors().get(count)) .toString() + "\" " + "value=\"" + temp + "\"/>", Message.TEST); } else if (epc.getConnectors().get(count).toString().startsWith( "AND")) { ++result; Message.add("\t\t<ANDConnector " + "name=\"" + ((EPCConnector) epc.getConnectors().get(count)) .toString() + "\" " + "value=\"" + 1 + "\"/>", Message.TEST); } } String output = "" + result; Message.add("\t\t<TotalCFC value=\"" + output + "\">", Message.TEST); Message.add("\t</CFC>", Message.TEST); return output; } private int fanout(EPCObject aEpcObj) { return aEpcObj.getSuccessors().size(); } private int power(int base, int expoente) { int resultado = 1; for (int i = 0; i < expoente; i++) { resultado = resultado * base; } return resultado; } /* * The basic requirements for this metric: At least one connector,one * function and one */ public String VerifyBasicRequirements() { if (epc.getConnectors().size() == 0) { return "The metric cannot be applied to this EPC because it does not have any connector, maybe it is not designed properly"; } else { if (epc.getFunctions().size() == 0) { return "The EPC does not contain any function, it is not designed properly!"; } else { if (epc.getEvents().size() < 2) { return "The EPC does not contain at least 2 events, it is not designed properly!"; } else { if (epc.getEdges().size() < 2) { return "The EPC does not contain at least 2 edges, it is not designed properly!"; } } } } return "."; } public String getType() { return this.TYPE; } public String getName() { return this.NAME; } }
[ "qianc62@gmail.com" ]
qianc62@gmail.com
bfcb6d26f111d81b9899e6bfe80fb5f7525f78e3
7ca8f2a90dafdc64c6c1b2d32073470f806c163c
/carnival-spring-boot-starter-restful-security/src/main/java/com/github/yingzhuo/carnival/restful/security/token/BytesToken.java
4fa40c3725aa46b3449421798bc13db8a8ccd552
[ "Apache-2.0", "LicenseRef-scancode-unknown-license-reference" ]
permissive
amadousanogo/carnival
f484c1bffd4e5f626ba6b4cf2461b997a7293ef2
0ee93cfcff20571fa2171af3abfe84bd4193fb73
refs/heads/master
2021-03-24T06:17:43.220091
2020-03-14T02:21:23
2020-03-14T02:21:23
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,220
java
/* * ____ _ ____ _ _ _____ ___ _ * / ___| / \ | _ \| \ | |_ _\ \ / / \ | | * | | / _ \ | |_) | \| || | \ \ / / _ \ | | * | |___/ ___ \| _ <| |\ || | \ V / ___ \| |___ * \____/_/ \_\_| \_\_| \_|___| \_/_/ \_\_____| * * https://github.com/yingzhuo/carnival */ package com.github.yingzhuo.carnival.restful.security.token; import java.util.Arrays; /** * @author 应卓 * @since 1.3.0 */ public class BytesToken implements Token { private final byte[] data; public static BytesToken of(byte[] data) { return new BytesToken(data); } public BytesToken(byte[] data) { this.data = data; } public byte[] getData() { return data; } @Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; BytesToken that = (BytesToken) o; return Arrays.equals(data, that.data); } @Override public int hashCode() { return Arrays.hashCode(data); } @Override public String toString() { return "BytesToken{" + "data=" + Arrays.toString(data) + '}'; } }
[ "yingzhor@gmail.com" ]
yingzhor@gmail.com
ca0ae1b90077052e5cd0c63789e5d0f5abe5de06
2a920f5f42c588dad01740da5d8c3d9aecbc2a90
/src/org/deegree/io/shpapi/ShapeUtils.java
e5707f905875fb4e077ca7c670a677b9ec7a4d00
[]
no_license
lat-lon/deegree2-rev30957
40b50297cd28243b09bfd05db051ea4cecc889e4
22aa8f8696e50c6e19c22adb505efb0f1fc805d8
refs/heads/master
2020-04-06T07:00:21.040695
2016-06-28T15:21:56
2016-06-28T15:21:56
12,290,316
0
0
null
2016-06-28T15:21:57
2013-08-22T06:49:45
Java
UTF-8
Java
false
false
5,022
java
//$HeadURL: https://scm.wald.intevation.org/svn/deegree/base/trunk/src/org/deegree/io/shpapi/ShapeUtils.java $ /*---------------------------------------------------------------------------- This file is part of deegree, http://deegree.org/ Copyright (C) 2001-2009 by: Department of Geography, University of Bonn and lat/lon GmbH This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA Contact information: lat/lon GmbH Aennchenstr. 19, 53177 Bonn Germany http://lat-lon.de/ Department of Geography, University of Bonn Prof. Dr. Klaus Greve Postfach 1147, 53001 Bonn Germany http://www.geographie.uni-bonn.de/deegree/ e-mail: info@deegree.org ----------------------------------------------------------------------------*/ package org.deegree.io.shpapi; import org.deegree.model.spatialschema.ByteUtils; /** * Utilities for reading and writing the components of shape files. * * * <B>Last changes<B>:<BR> * 25.11.1999 ap: memory allocation dynaminized<BR> * 17.1.2000 ap: method SHPPoint readPoint(byte[] b, int off) modified<BR> * 17.1.2000 ap: method SHPEnvelope readBox(byte[] b, int off) modified<BR> * 17.1.2000 ap: method writePoint(..) modified<BR> * * <!----------------------------------------------------------------------------> * * @version 25.1.2000 * @author Andreas Poth * */ public class ShapeUtils { /** * readPoint(byte[] b, int off)<BR> * Reads a point record. A point record is a double representing the x value and a double * representing a y value. * * @param b * the raw data buffer * @param off * the offset into the buffer where the int resides * @return the point read from the buffer at the offset location */ public static SHPPoint readPoint( byte[] b, int off ) { SHPPoint point = new SHPPoint(); point.x = ByteUtils.readLEDouble( b, off ); point.y = ByteUtils.readLEDouble( b, off + 8 ); return point; } /** * method: readBox(byte[] b, int off)<BR> * Reads a bounding box record. A bounding box is four double representing, in order, xmin, * ymin, xmax, ymax. * * @param b * the raw data buffer * @param off * the offset into the buffer where the int resides * @return the point read from the buffer at the offset location */ public static SHPEnvelope readBox( byte[] b, int off ) { SHPEnvelope bb = new SHPEnvelope(); SHPPoint min = readPoint( b, off ); SHPPoint max = readPoint( b, off + 16 ); bb.west = min.x; bb.south = min.y; bb.east = max.x; bb.north = max.y; return bb; } /** * method: writePoint(byte[] b, int off, ESRIPoint point)<BR> * Writes the given point to the given buffer at the given location. The point is written as a * double representing x followed by a double representing y. * * @param b * the data buffer * @param off * the offset into the buffer where writing should occur * @param point * the point to write * @return the number of bytes written */ public static int writePoint( byte[] b, int off, SHPPoint point ) { int nBytes = ByteUtils.writeLEDouble( b, off, point.x ); nBytes += ByteUtils.writeLEDouble( b, off + nBytes, point.y ); return nBytes; } /** * method: writeBox(byte[] b, int off, ESRIBoundingBox box)<BR> * Writes the given bounding box to the given buffer at the given location. The bounding box is * written as four doubles representing, in order, xmin, ymin, xmax, ymax. * * @param b * the data buffer * @param off * the offset into the buffer where writing should occur * @param box * the bounding box to write * @return the number of bytes written */ public static int writeBox( byte[] b, int off, SHPEnvelope box ) { SHPPoint min = new SHPPoint(); min.x = box.west; min.y = box.south; SHPPoint max = new SHPPoint(); max.x = box.east; max.y = box.north; int nBytes = writePoint( b, off, min ); nBytes += writePoint( b, off + nBytes, max ); return nBytes; } }
[ "erben@lat-lon.de" ]
erben@lat-lon.de
6a00ed26d303d69a8d3ef53aff6303f4d6851548
d1e6fb03bd248f1e5255d4ab31eb18faf0b611a7
/src/com/hamit/dersler/Ders_032_static_final.java
f856447c82232a6efb2db96b8d2474c103516e1d
[]
no_license
hamitmizrak/java_12Grup
c6e4ab7ca0d945b514449465fe00b3773842943f
b64c5d79adcb8b87065ea48c464d64e6cad9a259
refs/heads/master
2023-07-19T01:08:27.130167
2021-09-12T23:43:13
2021-09-12T23:43:13
391,320,506
0
0
null
null
null
null
UTF-8
Java
false
false
905
java
package com.hamit.dersler; //javada 1 tane public class var (inner class) //javada static class yazamam (inner class) public final class Ders_032_static_final { //bu classı extends edemezsiniz. // static: new oluşturmadan nesneleri çağırmak için kullanıyoruz. durağan // 1 tane new oluşturuluru ve sonradan gelen nesneler hepsi oluşturulan new üzerinden devam eder. // bir static method başka bir değişkeni çağırmak istiyorsa diğer nesnede static olmak zorundadır. //final //1-) değişkenlerde sabitlemek için //2-) metotlarda kullanırsak @Override edemeyiz //3-) classlarda kullanırsak extends edemeyiz. public final double sabit=4; public void deneme() { System.out.println("bu metodu @Override edemezsiniz"); } //Sabitleyici public static final String DEGISKEN_ADI=" değiştirimezsin."; } class deneme2{}
[ "hamitmizrak@gmail.com" ]
hamitmizrak@gmail.com
2ce28d42b02afd1927e4c6238785d28e87606261
a636258c60406f8db850d695b064836eaf75338b
/src-gen/com/rcss/humanresource/data/RchrEmployeeweekoffs.java
e2cba6bf3110eab3489539836c9a7fcf436cb5f5
[]
no_license
Afford-Solutions/openbravo-payroll
ed08af5a581fa41455f4e9b233cb182d787d5064
026fee4fe79b1f621959670fdd9ae6dec33d263e
refs/heads/master
2022-03-10T20:43:13.162216
2019-11-07T18:31:05
2019-11-07T18:31:05
null
0
0
null
null
null
null
UTF-8
Java
false
false
5,497
java
/* ************************************************************************* * The contents of this file are subject to the Openbravo Public License * Version 1.1 (the "License"), being the Mozilla Public License * Version 1.1 with a permitted attribution clause; you may not use this * file except in compliance with the License. You may obtain a copy of * the License at http://www.openbravo.com/legal/license.html * 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 Openbravo ERP. * The Initial Developer of the Original Code is Openbravo SLU * All portions are Copyright (C) 2008-2011 Openbravo SLU * All Rights Reserved. * Contributor(s): ______________________________________. ************************************************************************ */ package com.rcss.humanresource.data; import java.util.Date; import org.openbravo.base.structure.ActiveEnabled; import org.openbravo.base.structure.BaseOBObject; import org.openbravo.base.structure.ClientEnabled; import org.openbravo.base.structure.OrganizationEnabled; import org.openbravo.base.structure.Traceable; import org.openbravo.model.ad.access.User; import org.openbravo.model.ad.system.Client; import org.openbravo.model.common.enterprise.Organization; /** * Entity class for entity Rchr_Employeeweekoffs (stored in table Rchr_Employeeweekoffs). * * NOTE: This class should not be instantiated directly. To instantiate this * class the {@link org.openbravo.base.provider.OBProvider} should be used. */ public class RchrEmployeeweekoffs extends BaseOBObject implements Traceable, ClientEnabled, OrganizationEnabled, ActiveEnabled { private static final long serialVersionUID = 1L; public static final String TABLE_NAME = "Rchr_Employeeweekoffs"; public static final String ENTITY_NAME = "Rchr_Employeeweekoffs"; public static final String PROPERTY_ID = "id"; public static final String PROPERTY_CLIENT = "client"; public static final String PROPERTY_ORGANIZATION = "organization"; public static final String PROPERTY_ACTIVE = "active"; public static final String PROPERTY_CREATIONDATE = "creationDate"; public static final String PROPERTY_CREATEDBY = "createdBy"; public static final String PROPERTY_UPDATED = "updated"; public static final String PROPERTY_UPDATEDBY = "updatedBy"; public static final String PROPERTY_EMPLOYEE = "employee"; public static final String PROPERTY_ONDATE = "ondate"; public static final String PROPERTY_ENDINGDATE = "endingDate"; public static final String PROPERTY_WEEKLYOFF = "weeklyOff"; public static final String PROPERTY_PROCESS = "process"; public RchrEmployeeweekoffs() { setDefaultValue(PROPERTY_ACTIVE, true); setDefaultValue(PROPERTY_PROCESS, false); } @Override public String getEntityName() { return ENTITY_NAME; } public String getId() { return (String) get(PROPERTY_ID); } public void setId(String id) { set(PROPERTY_ID, id); } public Client getClient() { return (Client) get(PROPERTY_CLIENT); } public void setClient(Client client) { set(PROPERTY_CLIENT, client); } public Organization getOrganization() { return (Organization) get(PROPERTY_ORGANIZATION); } public void setOrganization(Organization organization) { set(PROPERTY_ORGANIZATION, organization); } public Boolean isActive() { return (Boolean) get(PROPERTY_ACTIVE); } public void setActive(Boolean active) { set(PROPERTY_ACTIVE, active); } public Date getCreationDate() { return (Date) get(PROPERTY_CREATIONDATE); } public void setCreationDate(Date creationDate) { set(PROPERTY_CREATIONDATE, creationDate); } public User getCreatedBy() { return (User) get(PROPERTY_CREATEDBY); } public void setCreatedBy(User createdBy) { set(PROPERTY_CREATEDBY, createdBy); } public Date getUpdated() { return (Date) get(PROPERTY_UPDATED); } public void setUpdated(Date updated) { set(PROPERTY_UPDATED, updated); } public User getUpdatedBy() { return (User) get(PROPERTY_UPDATEDBY); } public void setUpdatedBy(User updatedBy) { set(PROPERTY_UPDATEDBY, updatedBy); } public RchrEmployee getEmployee() { return (RchrEmployee) get(PROPERTY_EMPLOYEE); } public void setEmployee(RchrEmployee employee) { set(PROPERTY_EMPLOYEE, employee); } public Date getOndate() { return (Date) get(PROPERTY_ONDATE); } public void setOndate(Date ondate) { set(PROPERTY_ONDATE, ondate); } public Date getEndingDate() { return (Date) get(PROPERTY_ENDINGDATE); } public void setEndingDate(Date endingDate) { set(PROPERTY_ENDINGDATE, endingDate); } public String getWeeklyOff() { return (String) get(PROPERTY_WEEKLYOFF); } public void setWeeklyOff(String weeklyOff) { set(PROPERTY_WEEKLYOFF, weeklyOff); } public Boolean isProcess() { return (Boolean) get(PROPERTY_PROCESS); } public void setProcess(Boolean process) { set(PROPERTY_PROCESS, process); } }
[ "rcss@ubuntu-server.administrator" ]
rcss@ubuntu-server.administrator
6d31c7ee16e6d66a9191dc09fe6e3cb81db53201
4e106fad1969eb3bba9ec958197a292cba3ef0ac
/android_study/Onulhalin-shop/onulshop/src/main/java/me/onulhalin/sample/onul_shop/model/Product.java
e43fbd0a4d968ade8abd4883505118b13c086b9b
[ "Apache-2.0" ]
permissive
louis-25/android_study
f025dc5960a604fad09bf46be4dac0116c7aa598
ba7b667124ca521b04d71f5334f55009ad220d83
refs/heads/master
2023-03-31T06:39:05.641443
2021-04-05T14:21:25
2021-04-05T14:21:25
309,548,228
0
0
null
null
null
null
UTF-8
Java
false
false
718
java
package me.onulhalin.sample.onul_shop.model; import java.io.Serializable; import java.util.ArrayList; import java.util.List; public class Product implements Serializable { public Long id; public String name; public String image; public int price; public int price_discount; public int stock; public int draft; public String description; public String status; public String created_at; public String last_update; public String userid; public String ptstart; public String ptend; public String delivery; public String type; public List<Category> categories = new ArrayList<>(); public List<ProductImage> product_images = new ArrayList<>(); }
[ "20151577@vision.hoseo.edu" ]
20151577@vision.hoseo.edu
7edc4eb54bd656d5a664a4735abd0fdf53f8d23d
1374237fa0c18f6896c81fb331bcc96a558c37f4
/java/com/winnertel/ems/epon/iad/eoc/formatter/AnalogAlarmEnableFormatter.java
b2b772b07ff2eacfaba117f252baa8702ea0e579
[]
no_license
fangniude/lct
0ae5bc550820676f05d03f19f7570dc2f442313e
adb490fb8d0c379a8b991c1a22684e910b950796
refs/heads/master
2020-12-02T16:37:32.690589
2017-12-25T01:56:32
2017-12-25T01:56:32
96,560,039
0
0
null
null
null
null
UTF-8
Java
false
false
1,896
java
package com.winnertel.ems.epon.iad.eoc.formatter; import com.winnertel.em.framework.IApplication; import com.winnertel.em.framework.gui.IGuiComposer; import com.winnertel.em.framework.model.snmp.SnmpMibBean; import com.winnertel.em.framework.model.util.MibBeanUtil; import com.winnertel.em.standard.snmp.gui.formatter.SnmpFieldFormatter; /** * Created by IntelliJ IDEA. * User: hz03446 * Date: 2010-8-3 * Time: 11:14:14 * To change this template use File | Settings | File Templates. */ public class AnalogAlarmEnableFormatter extends SnmpFieldFormatter { public AnalogAlarmEnableFormatter(IApplication anApplication) { super(anApplication); } public Object format(SnmpMibBean aMibBean, String aProperty) throws Exception { Object obj = MibBeanUtil.getSimpleProperty(aMibBean, aProperty); if (obj == null) return null; byte[] tmpObj = (byte[]) obj; StringBuffer sb = new StringBuffer(); IGuiComposer composer = fApplication.getActiveDeviceManager().getGuiComposer(); if (tmpObj != null && tmpObj.length > 0) { if ((tmpObj[0] & (0x01)) == (0x01)) { sb.append(" ").append(composer.getString("analogAlarmEnable_LOLO")); } else if ((tmpObj[0] & (0x02)) == (0x02)) { sb.append(" ").append(composer.getString("analogAlarmEnable_LO")); } else if ((tmpObj[0] & (0x04)) == (0x04)) { sb.append(" ").append(composer.getString("analogAlarmEnable_HI")); } else if ((tmpObj[0] & (0x08)) == (0x08)) { sb.append(" ").append(composer.getString("analogAlarmEnable_HIHI")); } else { sb.append(" ").append(composer.getString("analogAlarmEnable_ALLCLOSE")); } // sb.append(" 0x").append(Integer.toHexString(tmpObj[0])); } return sb.toString(); } }
[ "fangniude@gmail.com" ]
fangniude@gmail.com
35f08c39644e7cac6bc4dc8346a2ccce20f0eecd
07f9a5471e88e82026d87412241fbd69e80263a6
/app/src/main/java/com/somnus/androidanimatelayoutchanges/MainActivity.java
971741f24416add0454e3ba60333e7797ba95308
[]
no_license
SomnusWu/AndroidAnimateLayoutChanges
dd6afd3bfd2dafa777510caeb494712ec3ff757e
6171162b851aa0dd2239aba168d03a1c94308a55
refs/heads/master
2021-05-03T11:22:37.468211
2016-09-23T06:37:44
2016-09-23T06:37:44
68,987,244
2
0
null
null
null
null
UTF-8
Java
false
false
4,194
java
package com.somnus.androidanimatelayoutchanges; import android.animation.LayoutTransition; import android.animation.ObjectAnimator; import android.os.Bundle; import android.support.design.widget.FloatingActionButton; import android.support.design.widget.Snackbar; import android.support.v7.app.AppCompatActivity; import android.support.v7.widget.Toolbar; import android.util.Log; import android.view.KeyEvent; import android.view.Menu; import android.view.MenuItem; import android.view.View; import android.widget.Button; import android.widget.LinearLayout; import android.widget.Toast; import java.util.Random; public class MainActivity extends AppCompatActivity { private LinearLayout mLinearLayout; private LinearLayout mll_layout_01; LayoutTransition mTransitioner; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar); setSupportActionBar(toolbar); mLinearLayout = (LinearLayout) findViewById(R.id.ll_layout); mll_layout_01 = (LinearLayout) findViewById(R.id.ll_layout_01); mTransitioner = new LayoutTransition(); //入场动画:view在这个容器中消失时触发的动画 ObjectAnimator animIn = ObjectAnimator.ofFloat(null, "rotationY", 0f, 360f, 0f); mTransitioner.setAnimator(LayoutTransition.APPEARING, animIn); //出场动画:view显示时的动画 ObjectAnimator animOut = ObjectAnimator.ofFloat(null, "rotation", 0f, 90f, 0f); mTransitioner.setAnimator(LayoutTransition.DISAPPEARING, animOut); FloatingActionButton fab = (FloatingActionButton) findViewById(R.id.fab); fab.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { Snackbar.make(view, "Replace with your own action", Snackbar.LENGTH_LONG) .setAction("ADD", null).show(); } }); } @Override public boolean onCreateOptionsMenu(Menu menu) { // Inflate the menu; this adds items to the action bar if it is present. getMenuInflater().inflate(R.menu.menu_main, menu); return true; } @Override public boolean onOptionsItemSelected(MenuItem item) { // Handle action bar item clicks here. The action bar will // automatically handle clicks on the Home/Up button, so long // as you specify a parent activity in AndroidManifest.xml. int id = item.getItemId(); //noinspection SimplifiableIfStatement if (id == R.id.action_add) { Button button = new Button(MainActivity.this); button.setText("" + new Random().nextInt(100)); mLinearLayout.addView(button); button.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { mLinearLayout.removeView(view); } }); return true; } else if (id == R.id.action_add1) { //自定义动画 Button button = new Button(MainActivity.this); button.setText("" + new Random().nextInt(100)); mll_layout_01.addView(button); button.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { mll_layout_01.removeView(view); } }); mll_layout_01.setLayoutTransition(mTransitioner); } return super.onOptionsItemSelected(item); } @Override public void onBackPressed() { /*写在主页 , 按返回键返回桌面,不结束Activity*/ moveTaskToBack(true); } @Override public boolean onKeyDown(int keyCode, KeyEvent event) { Log.d("tag",keyCode+""); Log.d("event",event.toString()); return super.onKeyDown(keyCode, event); } public void onAction(View v){ Toast.makeText(this, "啦啦啦", Toast.LENGTH_SHORT).show(); } }
[ "wuzhensomnus@163.com" ]
wuzhensomnus@163.com
c217f0c893867389a4ec8d818f46111f4b4d6089
42c50e58c738d67fd65105172c3291fbedfc1ecb
/src/com/szit/arbitrate/chat/junit/ChatRoomServiceJunitTest.java
d0bb0bcecb1367978d2c4a4f7c735ae101b415bf
[]
no_license
xmxnkj/interact
44860df5ad4550f972c26a5bab32460d9228d5c2
f97b4631fc6bffcfc4606cac36286e6e59165f4e
refs/heads/master
2020-08-08T20:31:53.681178
2019-01-10T07:33:31
2019-01-10T07:33:31
213,910,518
0
0
null
null
null
null
UTF-8
Java
false
false
675
java
package com.szit.arbitrate.chat.junit; import org.junit.Test; import org.springframework.beans.factory.annotation.Autowired; import com.szit.arbitrate.api.common.utils.BaseApiJunitTest; import com.szit.arbitrate.chat.service.ChatRoomService; import com.szit.arbitrate.client.service.NeteaseClientService; public class ChatRoomServiceJunitTest extends BaseApiJunitTest{ @Autowired private ChatRoomService service; @Autowired private NeteaseClientService neteaseClientService; @Test public void openNeteaseCloud(){ String clientid = "68b1340a-af83-40ce-8961-a30cc3589b6d"; neteaseClientService.createNeteaseCloudAccount(clientid); } }
[ "chenwu0@aliyun.com" ]
chenwu0@aliyun.com
f48ac48e361cca1909fc8e014aafb28e01b3acca
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/20/20_473602d63f20b3c5ec1c0e84ed02d8f2473a0270/PropertyReader/20_473602d63f20b3c5ec1c0e84ed02d8f2473a0270_PropertyReader_s.java
709c9b2bd66eb67b8f850d6ce4b8ecb3183b7880
[]
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
901
java
package PropertyReader; import java.io.IOException; import java.util.Properties; /* * To change this template, choose Tools | Templates * and open the template in the editor. */ /** * * @author daniela */ public abstract class PropertyReader { protected Properties props; protected PropertyReader(String path) { readPropertyFile(path); } private void readPropertyFile(String path) { java.io.InputStream is = ClassLoader.getSystemResourceAsStream(path); if (is != null) { props = new java.util.Properties(); try { props.load(is); } catch(IOException e) { System.err.println("Couldn't read Properties file + " + path); } } else { System.err.println("Properties file not found! " + path); } } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
93cc7a73ededecff8959309102dedc878e720074
a370ff524a6e317488970dac65d93a727039f061
/archive/unsorted/2020.10/2020.10.22 - URI Online Judge - Beginner/HelloWorld.java
b9a208bd481de28b1ac443139b146bd4ce296271
[]
no_license
taodaling/contest
235f4b2a033ecc30ec675a4526e3f031a27d8bbf
86824487c2e8d4fc405802fff237f710f4e73a5c
refs/heads/master
2023-04-14T12:41:41.718630
2023-04-10T14:12:47
2023-04-10T14:12:47
213,876,299
9
1
null
2021-06-12T06:33:05
2019-10-09T09:28:43
Java
UTF-8
Java
false
false
219
java
package contest; import template.io.FastInput; import java.io.PrintWriter; public class HelloWorld { public void solve(int testNumber, FastInput in, PrintWriter out) { out.println("Hello World!"); } }
[ "taodaling@gmail.com" ]
taodaling@gmail.com
24465af6076e18b2a7329f3f83e0d6607cca8927
66d3122f8f031d6e8b27e8ead7aa5ae0d7e33b45
/net/minecraft/structure/StructureManager.java
1c74d03385a2824955eb8f8e76df79a41a7e3d9a
[]
no_license
gurachan/minecraft1.14-dp
c10059787555028f87a4c8183ff74e6e1cfbf056
34daddc03be27d5a0ee2ab9bc8b1deb050277208
refs/heads/master
2022-01-07T01:43:52.836604
2019-05-08T17:18:13
2019-05-08T17:18:13
null
0
0
null
null
null
null
UTF-8
Java
false
false
6,693
java
package net.minecraft.structure; import org.apache.logging.log4j.LogManager; import java.nio.file.InvalidPathException; import net.minecraft.util.InvalidIdentifierException; import net.minecraft.util.FileNameUtil; import java.io.OutputStream; import java.io.FileOutputStream; import java.nio.file.attribute.FileAttribute; import java.nio.file.Files; import java.nio.file.LinkOption; import net.minecraft.nbt.CompoundTag; import net.minecraft.util.TagHelper; import net.minecraft.datafixers.DataFixTypes; import net.minecraft.nbt.NbtIo; import java.io.InputStream; import java.io.IOException; import java.io.FileInputStream; import net.minecraft.resource.Resource; import java.io.FileNotFoundException; import net.minecraft.resource.ResourceManager; import javax.annotation.Nullable; import net.minecraft.resource.ResourceReloadListener; import com.google.common.collect.Maps; import java.io.File; import java.nio.file.Path; import net.minecraft.server.MinecraftServer; import com.mojang.datafixers.DataFixer; import net.minecraft.util.Identifier; import java.util.Map; import org.apache.logging.log4j.Logger; import net.minecraft.resource.SynchronousResourceReloadListener; public class StructureManager implements SynchronousResourceReloadListener { private static final Logger LOGGER; private final Map<Identifier, Structure> structures; private final DataFixer dataFixer; private final MinecraftServer server; private final Path generatedPath; public StructureManager(final MinecraftServer server, final File worldDir, final DataFixer dataFixer) { this.structures = Maps.newHashMap(); this.server = server; this.dataFixer = dataFixer; this.generatedPath = worldDir.toPath().resolve("generated").normalize(); server.getDataManager().registerListener(this); } public Structure getStructureOrBlank(final Identifier id) { Structure structure2 = this.getStructure(id); if (structure2 == null) { structure2 = new Structure(); this.structures.put(id, structure2); } return structure2; } @Nullable public Structure getStructure(final Identifier identifier) { final Structure structure2; return this.structures.computeIfAbsent(identifier, identifier -> { structure2 = this.loadStructureFromFile(identifier); return (structure2 != null) ? structure2 : this.loadStructureFromResource(identifier); }); } @Override public void apply(final ResourceManager manager) { this.structures.clear(); } @Nullable private Structure loadStructureFromResource(final Identifier id) { final Identifier identifier2 = new Identifier(id.getNamespace(), "structures/" + id.getPath() + ".nbt"); try (final Resource resource3 = this.server.getDataManager().getResource(identifier2)) { return this.readStructure(resource3.getInputStream()); } catch (FileNotFoundException fileNotFoundException3) { return null; } catch (Throwable throwable3) { StructureManager.LOGGER.error("Couldn't load structure {}: {}", id, throwable3.toString()); return null; } } @Nullable private Structure loadStructureFromFile(final Identifier id) { if (!this.generatedPath.toFile().isDirectory()) { return null; } final Path path2 = this.getAndCheckStructurePath(id, ".nbt"); try (final InputStream inputStream3 = new FileInputStream(path2.toFile())) { return this.readStructure(inputStream3); } catch (FileNotFoundException fileNotFoundException3) { return null; } catch (IOException iOException3) { StructureManager.LOGGER.error("Couldn't load structure from {}", path2, iOException3); return null; } } private Structure readStructure(final InputStream structureInputStream) throws IOException { final CompoundTag compoundTag2 = NbtIo.readCompressed(structureInputStream); if (!compoundTag2.containsKey("DataVersion", 99)) { compoundTag2.putInt("DataVersion", 500); } final Structure structure3 = new Structure(); structure3.fromTag(TagHelper.update(this.dataFixer, DataFixTypes.f, compoundTag2, compoundTag2.getInt("DataVersion"))); return structure3; } public boolean saveStructure(final Identifier id) { final Structure structure2 = this.structures.get(id); if (structure2 == null) { return false; } final Path path3 = this.getAndCheckStructurePath(id, ".nbt"); final Path path4 = path3.getParent(); if (path4 == null) { return false; } try { Files.createDirectories(Files.exists(path4) ? path4.toRealPath() : path4, new FileAttribute[0]); } catch (IOException iOException5) { StructureManager.LOGGER.error("Failed to create parent directory: {}", path4); return false; } final CompoundTag compoundTag5 = structure2.toTag(new CompoundTag()); try (final OutputStream outputStream6 = new FileOutputStream(path3.toFile())) { NbtIo.writeCompressed(compoundTag5, outputStream6); } catch (Throwable throwable6) { return false; } return true; } private Path getStructurePath(final Identifier id, final String string) { try { final Path path3 = this.generatedPath.resolve(id.getNamespace()); final Path path4 = path3.resolve("structures"); return FileNameUtil.b(path4, id.getPath(), string); } catch (InvalidPathException invalidPathException3) { throw new InvalidIdentifierException("Invalid resource path: " + id, invalidPathException3); } } private Path getAndCheckStructurePath(final Identifier id, final String string) { if (id.getPath().contains("//")) { throw new InvalidIdentifierException("Invalid resource path: " + id); } final Path path3 = this.getStructurePath(id, string); if (!path3.startsWith(this.generatedPath) || !FileNameUtil.isNormal(path3) || !FileNameUtil.isAllowedName(path3)) { throw new InvalidIdentifierException("Invalid resource path: " + path3); } return path3; } public void unloadStructure(final Identifier id) { this.structures.remove(id); } static { LOGGER = LogManager.getLogger(); } }
[ "879139909@qq.com" ]
879139909@qq.com
6e1a0173e8ae08c0873205ae4b0caf399e8b6e53
dbb8f8642ca95a2e513c9afae27c7ee18b3ab7d8
/anchor-image-voxel/src/main/java/org/anchoranalysis/image/voxel/iterator/neighbor/kernel/WalkPredicate.java
da900c410bc614acffe6ed643d960cc8b98f921e
[ "Apache-2.0", "MIT" ]
permissive
anchoranalysis/anchor
19c2a40954515e93da83ddfc99b0ff4a95dc2199
b3b589e0d76f51b90589893cfc8dfbb5d7753bc9
refs/heads/master
2023-07-19T17:38:19.940164
2023-07-18T08:33:10
2023-07-18T08:33:10
240,029,306
3
0
MIT
2023-07-18T08:33:11
2020-02-12T14:12:28
Java
UTF-8
Java
false
false
6,582
java
/*- * #%L * anchor-image-voxel * %% * Copyright (C) 2010 - 2021 Owen Feehan, ETH Zurich, University of Zurich, Hoffmann-La Roche * %% * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Software without restriction, including without limitation the rights * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell * copies of the Software, and to permit persons to whom the Software is * furnished to do so, subject to the following conditions: * * The above copyright notice and this permission notice shall be included in * all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN * THE SOFTWARE. * #L% */ package org.anchoranalysis.image.voxel.iterator.neighbor.kernel; import java.util.Optional; import java.util.function.Supplier; import lombok.AllArgsConstructor; import org.anchoranalysis.image.voxel.buffer.primitive.UnsignedByteBuffer; import org.anchoranalysis.image.voxel.kernel.BufferRetriever; import org.anchoranalysis.image.voxel.kernel.KernelPointCursor; /** * Walks in X, Y and Z directions from a point, test a {@link NeighborPredicate} to determine if a * neighbor satisfies conditions. * * <p>As soon as any neighbor matches the predicate, a true value is returned for the voxel. A false * is returned only if no neighbors match the predicate. * * @author Owen Feehan */ @AllArgsConstructor public class WalkPredicate { /** The cursor used for iterating through points. */ private final KernelPointCursor point; /** Whether a neighbor qualifies or not. */ private final NeighborPredicate predicate; /** * Whether to use a big-neighborhood or not. * * <p>if true, a big neighborhood is used 2D-plane (8-connected instead of 4-connected), but not * in Z-direction (remains 2-connected). */ private final boolean bigNeighborhood; /** * Do any neighboring voxels in <i>any</i> direction satisfy the predicate? * * @param buffer the buffer associated with the current slice * @param bufferRetriever a means of retrieving buffers for other slices, accepting a relative * shift compared to current slice (e.g. -1, +1) etc. * @return true iff at least one neighbor voxel in <i>any</i> direction satisfies the predicate. */ public boolean walk(UnsignedByteBuffer buffer, BufferRetriever bufferRetriever) { return walkX(buffer) || walkY(buffer) || walkZ(bufferRetriever) || maybeQualifyFromBigNeighborhood(buffer); } /** Do any neighboring voxels in X direction qualify the voxel? */ private boolean walkX(UnsignedByteBuffer buffer) { // We walk up and down in x point.decrementX(); if (testIf(point.nonNegativeX(), () -> buffer, 0)) { point.incrementX(); return true; } point.incrementXTwice(); try { if (testIf(point.lessThanMaxX(), () -> buffer, 0)) { return true; } } finally { point.decrementX(); } return false; } /** Do any neighboring voxels in Y direction qualify the voxel? */ private boolean walkY(UnsignedByteBuffer buffer) { point.decrementY(); if (testIf(point.nonNegativeY(), () -> buffer, 0)) { point.incrementY(); return true; } point.incrementYTwice(); try { if (testIf(point.lessThanMaxY(), () -> buffer, 0)) { return true; } } finally { point.decrementY(); } return false; } /** Do any neighboring voxels in Z direction qualify the voxel? */ private boolean walkZ(BufferRetriever bufferRetriever) { if (point.isUseZ()) { return qualifyFromZDirection(bufferRetriever, -1) || qualifyFromZDirection(bufferRetriever, +1); } else { return false; } } /** * If big-neighbor is enabled, do any voxels from the big neighborhood (not already covered) * qualify the voxel? */ private boolean maybeQualifyFromBigNeighborhood(UnsignedByteBuffer buffer) { return bigNeighborhood && qualifyFromBigNeighborhood(buffer); } /** Do any voxels from the big neighborhood (not already covered) qualify the voxel? */ private boolean qualifyFromBigNeighborhood(UnsignedByteBuffer buffer) { // x-1, y-1 point.decrementX(); point.decrementY(); if (testIf(point.nonNegativeX() && point.nonNegativeY(), () -> buffer, 0)) { point.incrementX(); point.incrementY(); return true; } // x-1, y+1 point.incrementYTwice(); if (testIf(point.nonNegativeX() && point.lessThanMaxY(), () -> buffer, 0)) { point.incrementX(); point.decrementY(); return true; } // x+1, y+1 point.incrementXTwice(); if (testIf(point.lessThanMaxX() && point.lessThanMaxY(), () -> buffer, 0)) { point.decrementX(); point.decrementY(); return true; } // x+1, y-1 point.decrementYTwice(); try { if (testIf(point.lessThanMaxX() && point.nonNegativeY(), () -> buffer, 0)) { return true; } } finally { point.decrementX(); point.incrementY(); } return false; } /** Does a neighbor voxel in <b>a specific Z-direction</b> qualify the voxel? */ private boolean qualifyFromZDirection(BufferRetriever bufferRetriever, int zShift) { Optional<UnsignedByteBuffer> buffer = bufferRetriever.getLocal(zShift); return testIf(buffer.isPresent(), buffer::get, zShift); } private boolean testIf(boolean inside, Supplier<UnsignedByteBuffer> buffer, int zShift) { return predicate.test(inside, point, buffer, zShift); } }
[ "owenfeehan@users.noreply.github.com" ]
owenfeehan@users.noreply.github.com
77560c60eebf9e7ce02733ebe6ae64985d1d7a1c
ab7c05a76ded0e6341c72b2c5f7a4e4647fe3f8f
/src/Die.java
8eaaf40d9418a937f13edf4e9543201f164a3c1c
[]
no_license
MpenduloNk/Project_Dice
60ac6d6005137b728e7e3f1c6c91054b41eef951
287cb00553dfdcd2ceef772bb0996370bb2a7c5d
refs/heads/master
2022-04-22T04:07:39.411143
2020-04-20T09:21:35
2020-04-20T09:21:35
257,230,364
0
0
null
null
null
null
UTF-8
Java
false
false
1,228
java
import java.util.Random; import java.util.Scanner; public class Die { public int sides; public int[] probabilities; public Die(int sides, int[] probabilities){ this.sides = sides; this.probabilities = probabilities; setProbabilities(probabilities); } public int roll(){ int min = 0; Random diceNumber = new Random(); return diceNumber.nextInt((sides - min) + 1) + min; } public int[] setProbabilities(int[] probabilities){ int totalSum = 0; if (probabilities.length == 0 && roll() == 6){ probabilities = new int[]{1,1,1,1,1,1}; } if (probabilities.length == 0 && roll() == 10){ probabilities = new int[]{1,1,1,1,1,1,1,1,1,1}; } for (int i = 0; i < probabilities.length; i++) { if (probabilities[i] < 0){ System.out.println("ERROR: negative probabilities not allowed"); totalSum = 1; break; } totalSum += probabilities[i]; } if (totalSum < 1){ System.out.println("ERROR: probability sum must be greater than 0"); } return probabilities; } }
[ "you@example.com" ]
you@example.com
26b2d75c6e609de4b44c5fec02a8e903da57062d
23e174316e8eb5c3623c93925f4a5a2d321676a1
/src/main/java/fr/brouillard/oss/jgitver/cfg/schema/ConfigurationSchema.java
3d7ac3b67328cf7b92bff15e009ff822043d1f11
[ "Apache-2.0" ]
permissive
McFoggy/jgitver-maven-plugin
7bef3a3022517a055440227532d5c0e36a382d44
75b4048ab0e5ec336fcd85085a3cdf34156f1ceb
refs/heads/master
2021-01-20T07:29:31.738936
2017-03-15T08:25:01
2017-03-15T09:31:34
90,006,795
0
0
null
2017-05-02T07:57:23
2017-05-02T07:57:23
null
UTF-8
Java
false
false
3,090
java
/** * Copyright (C) 2016 Matthieu Brouillard [http://oss.brouillard.fr/jgitver-maven-plugin] (matthieu@brouillard.fr) * * 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 fr.brouillard.oss.jgitver.cfg.schema; import java.util.LinkedList; import java.util.List; import java.util.stream.Collectors; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.XmlElementWrapper; import javax.xml.bind.annotation.XmlRootElement; import fr.brouillard.oss.jgitver.cfg.Configuration; @XmlRootElement(name = "configuration") @XmlAccessorType(XmlAccessType.FIELD) public class ConfigurationSchema { @XmlElement(name = "mavenLike") public boolean mavenLike = true; @XmlElement public boolean autoIncrementPatch = true; @XmlElement public boolean useCommitDistance = false; @XmlElement public boolean useDirty = false; @XmlElement public boolean failIfDirty = false; @XmlElement public boolean useDefaultBranchingPolicy = true; @XmlElement public boolean useGitCommitId = false; @XmlElement public int gitCommitIdLength = 8; @XmlElement public String nonQualifierBranches = "master"; @XmlElement(name = "regexVersionTag") public String regexVersionTag; @XmlElementWrapper(name = "exclusions") @XmlElement(name = "exclusion") public List<String> exclusions = new LinkedList<>(); @XmlElementWrapper(name = "branchPolicies") @XmlElement(name = "branchPolicy") public List<BranchPolicySchema> branchPolicies = new LinkedList<>(); /** * Converts this instance into a {@link Configuration} one. * @return a non null {@link Configuration} object containing the same values than this instance. */ public Configuration asConfiguration() { Configuration c = new Configuration(); c.mavenLike = mavenLike; c.autoIncrementPatch = autoIncrementPatch; c.useCommitDistance = useCommitDistance; c.useDirty = useDirty; c.failIfDirty = failIfDirty; c.useDefaultBranchingPolicy = useDefaultBranchingPolicy; c.useGitCommitId = useGitCommitId; c.gitCommitIdLength = gitCommitIdLength; c.nonQualifierBranches = nonQualifierBranches; c.regexVersionTag = regexVersionTag; c.exclusions.addAll(exclusions); c.branchPolicies.addAll(branchPolicies.stream().map(BranchPolicySchema::asBranchPolicy).collect(Collectors.toList())); return c; } }
[ "matthieu@brouillard.fr" ]
matthieu@brouillard.fr
3ba99ed3fb2ca92ef09f9cffe628600426b371eb
f3f93c4ea9a4996eacf1ef1d643aef5fa214e6f9
/src/main/java/com/ankamagames/dofus/core/movement/Map.java
f1bc54a0ecffd76fb38118da3c2aa7799e3c96da
[ "MIT" ]
permissive
ProjectBlackFalcon/BlackFalconAPI
fb94774056eacd053b3daf0931a9ef9c0fb477f6
b038f2f1bc300e549b5f6469c82530b6245f54e2
refs/heads/master
2022-12-05T09:58:36.499535
2019-10-02T21:58:54
2019-10-02T21:58:54
188,725,082
6
0
MIT
2022-11-16T12:22:14
2019-05-26T19:49:10
Java
UTF-8
Java
false
false
869
java
package com.ankamagames.dofus.core.movement; import java.util.List; public class Map { private boolean isUsingNewMovementSystem; private List<CellData> cells; public Map() { } public Map(final boolean isUsingNewMovementSystem, final List<CellData> cells) { this.isUsingNewMovementSystem = isUsingNewMovementSystem; this.cells = cells; } public boolean isUsingNewMovementSystem() { return isUsingNewMovementSystem; } public void setUsingNewMovementSystem(final boolean usingNewMovementSystem) { isUsingNewMovementSystem = usingNewMovementSystem; } public List<CellData> getCells() { return cells; } public void setCells(final List<CellData> cells) { this.cells = cells; } public boolean NoEntitiesOnCell(int cellId) { return true; } }
[ "baptiste.beduneau@reseau.eseo.fr" ]
baptiste.beduneau@reseau.eseo.fr
015484649fe55c25e0949254a0c1993a5137c30f
2ce07565d7644586686aa63c256f3288a010c40b
/HxModule/src/com/easemob/easeui/utils/HxApi.java
640bb03dd3380a7c36f6b66b38fef89c40f64a2b
[ "Apache-2.0" ]
permissive
yundequanshi/TxQipei
42a3f13d3bf95ecf5681ac45c929aef09f082b88
17edbbc47a47f005ee9934c94a43e38bc2deb115
refs/heads/master
2021-02-19T09:05:13.905941
2020-03-06T09:12:01
2020-03-06T09:12:01
245,298,297
0
0
null
null
null
null
UTF-8
Java
false
false
3,311
java
package com.easemob.easeui.utils; import com.easemob.easeui.model.GroupData; import com.easemob.easeui.model.HxUser; import com.easemob.easeui.model.TodoData; import java.util.List; import java.util.Map; import okhttp3.MultipartBody; import okhttp3.ResponseBody; import retrofit2.http.Body; import retrofit2.http.GET; import retrofit2.http.Multipart; import retrofit2.http.POST; import retrofit2.http.Part; import retrofit2.http.Streaming; import retrofit2.http.Url; import rx.Observable; /** * Created by iscod. Time:2016/6/21-9:46. */ public interface HxApi { //上传文件 @Multipart @POST("file/upload/") Observable<List<String>> upload(@Part MultipartBody.Part file); //上传文件 @Multipart @POST("file/upload/") Observable<List<String>> uploads(@Part List<MultipartBody.Part> files); //下载 @GET @Streaming Observable<ResponseBody> download(@Url String fileUrl); //1--获取环信信息 @POST("user/getUser") Observable<HxUser> getHxUser(@Body Map<String, String> map); //2--获取环信信息根据emid @POST("user/getUserByEmId") Observable<HxUser> getUserByEmId(@Body Map<String, String> map); //3--获取环信全部联系人 @POST("friend/friends") Observable<List<HxUser>> friends(@Body Map<String, String> map); //4--获取环信待办数量 @POST("user/toDoList") Observable<List<TodoData>> toDoList(@Body Map<String, String> map); //5--删除好友 @POST("friend/dissolution") Observable<String> dissolution(@Body Map<String, String> map); //6--查找好友 @POST("user/findUser") Observable<List<HxUser>> findUser(@Body Map<String, String> map); //7--添加好友 @POST("friend/invitation") Observable<String> invitation(@Body Map<String, String> map); //8--获取环信群列表 @POST("group/userGroup") Observable<List<GroupData>> userGroup(@Body Map<String, String> map); //9--解散群 @POST("group/dissolution") Observable<String> groupDissolution(@Body Map<String, String> map); //10--创建群 @POST("group/createGroup") Observable<String> createGroup(@Body Map<String, String> map); //11--群邀请 @POST("group/invitationGroup") Observable<String> invitationGroup(@Body Map<String, String> map); //12--群邀请同意 @POST("group/addUser2Group") Observable<String> addUser2Group(@Body Map<String, String> map); //14--好友邀请同意 @POST("friend/addFriend") Observable<String> addFriend(@Body Map<String, String> map); //15--待办事情清空 @POST("user/toDoMsg") Observable<String> toDoMsg(@Body Map<String, String> map); //16--获取群好友 @POST("group/groupUsersByEmgId") Observable<List<HxUser>> groupUsersByEmgId(@Body Map<String, String> map); //17--移除群好友 @POST("group/removeUser") Observable<String> removeUser(@Body Map<String, String> map); //18--修改群 @POST("group/updateGroup") Observable<String> updateGroup(@Body Map<String, String> map); //19--查找群 @POST("group/findGroup") Observable<List<GroupData>> findGroup(@Body Map<String, String> map); //20--申请加群 @POST("group/applyGroup") Observable<String> applyGroup(@Body Map<String, String> map); //21--修改用户信息 @POST("user/updateUser") Observable<String> updateUser(@Body Map<String, String> map); }
[ "yundequanshi@126.com" ]
yundequanshi@126.com
58a3b6c69099d3bd4266384b9fee9ccc5a0583fb
794473ff2ba2749db9c0782f5d281b00dd785a95
/trunks/qiubaotong-server/qbt-system-web/src/test/java/com/qbt/test/ComposeImageTest.java
030554bd9933d04ddb4efb2f9e8f3207a842ff6b
[]
no_license
hexilei/qbt
a0fbc9c1870da1bf1ec24bba0f508841ca1b9750
040e5fcc9fbb27d52712cc1678d71693b5c85cce
refs/heads/master
2021-05-05T23:03:20.377229
2018-01-12T03:33:12
2018-01-12T03:33:12
116,363,833
0
1
null
null
null
null
UTF-8
Java
false
false
2,363
java
package com.qbt.test; import java.awt.Color; import java.awt.Font; import java.awt.Graphics; import java.awt.image.BufferedImage; import java.io.File; import java.io.FileInputStream; import java.io.FileOutputStream; import java.io.InputStream; import java.io.OutputStream; import javax.imageio.ImageIO; public class ComposeImageTest { /** * 图片合成 * @param args * @throws Exception */ public static void main(String[] args) throws Exception { File fileDir = new File("E:/data/test"); File[] files = fileDir.listFiles(); long startTime = System.currentTimeMillis(); for(File file : files){ if(file.isDirectory()){ continue; } InputStream imagein = new FileInputStream("E:/data/qrcode_bg.png"); String fileNamge = file.getName().substring(0,file.getName().lastIndexOf(".")); InputStream imagein2 = new FileInputStream(file); BufferedImage image = ImageIO.read(imagein); BufferedImage image2 = ImageIO.read(imagein2); Graphics g = image.getGraphics(); g.drawImage(image2, 188, 414,250 , 250, null); Font font = new Font("黑体", Font.BOLD, 13); g.setFont(font); Color c = new Color(196,195,195); g.setColor(c); //根据图片的背景设置水印颜色 g.drawString(fileNamge, 265, 1090); font = new Font("黑体", Font.BOLD, 48); g.setFont(font); g.setColor(Color.white); //根据图片的背景设置水印颜色 // g.drawString("我是张三", 210, 95); // g.drawString("我是张三三", 180, 98); g.drawString("我是张三三张三三张三三三", 5, 98); g.dispose(); OutputStream outImage = new FileOutputStream("E:/data/test/test/" + fileNamge + ".jpg"); ImageIO.write(image, "JPG", new File("E:/data/test/test/", fileNamge+".jpg")); // JPEGImageEncoder enc = JPEGCodec.createJPEGEncoder(outImage); // enc.encode(image); imagein.close(); imagein2.close(); outImage.close(); } System.out.println(("生成耗时:"+(System.currentTimeMillis() - startTime)/1000)+"秒"); } }
[ "louis.he@missionsky.com" ]
louis.he@missionsky.com
c19d25a3092b6d6a27c57ac9e27d4e5606e7c109
42c6b3676bb3f3e228555ef89ce937d0269d75aa
/app/src/main/java/com/qixiu/newoulingzhu/mvp/view/fragment/home/caculator/TrafficFragment.java
ea356917ca779077f861a0d9655d36bcf4654375
[]
no_license
q37141826/new_wangchang
61ee67af4ab07cf24e897e5d0848d74e091ba3f2
252a5418759e8d5d3d2369ff24eac7382bc5ffc2
refs/heads/master
2020-04-03T14:03:17.847515
2019-04-01T03:43:46
2019-04-01T03:44:46
155,309,950
0
1
null
null
null
null
UTF-8
Java
false
false
6,080
java
package com.qixiu.newoulingzhu.mvp.view.fragment.home.caculator; import android.os.Bundle; import android.text.TextUtils; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.Button; import android.widget.TextView; import com.qixiu.newoulingzhu.mvp.view.activity.home.caculator.PopAddress; import com.qixiu.newoulingzhu.mvp.view.activity.home.caculator.PopInjury; import com.qixiu.newoulingzhu.mvp.view.activity.home.caculator.PopRegist; import com.qixiu.newoulingzhu.mvp.view.activity.home.caculator.result.TrafficResultActivity; import com.qixiu.newoulingzhu.mvp.view.activity.home.caculator.result.beans.HeadBean; import com.qixiu.newoulingzhu.mvp.view.fragment.base.BaseFragment; import com.qixiu.newoulingzhu.utils.ToastUtil; import com.qixiu.qixiu.request.OKHttpRequestModel; import com.qixiu.qixiu.request.OKHttpUIUpdataListener; import com.qixiu.qixiu.request.bean.C_CodeBean; import com.qixiu.wanchang.R; import com.qixiu.wigit.myedittext.MyEditTextView; import java.util.HashMap; import java.util.Map; import butterknife.BindView; import butterknife.ButterKnife; import butterknife.OnClick; import butterknife.Unbinder; import okhttp3.Call; /** * Created by my on 2018/9/3. */ public class TrafficFragment extends BaseFragment implements OKHttpUIUpdataListener { OKHttpRequestModel okHttpRequestModel = new OKHttpRequestModel(this); @BindView(R.id.textViewAdrees) TextView textViewAdrees; @BindView(R.id.textViewRegiste) TextView textViewRegiste; @BindView(R.id.textViewInjury) TextView textViewInjury; @BindView(R.id.ediitextAge) MyEditTextView ediitextAge; @BindView(R.id.btnCalculation) Button btnCalculation; @BindView(R.id.btnReset) Button btnReset; Unbinder unbinder; private PopAddress popAddress; private PopInjury popInjury; private String addressId, injuryId; private PopRegist popRegist; private String registeType; private String address, level, regist, age; @Override protected void onInitData() { popAddress = new PopAddress(getContext(), new PopAddress.OnItemClickListenner() { @Override public void onItemClick(PopAddress.ProvicesBean.OBean data) { textViewAdrees.setText("选择地区:" + " " + data.getProvince()); address = data.getProvince(); addressId = data.getId(); } }); popInjury = new PopInjury(getContext(), new PopInjury.OnItemClickListenner() { @Override public void onItemClick(PopInjury.InjuryBean.OBean data) { textViewInjury.setText("伤残等级:" + " " + data.getName()); level = data.getName(); injuryId = data.getType(); } }); popRegist = new PopRegist(getContext(), new PopRegist.OnItemClickListenner() { @Override public void onItemClick(PopRegist.RegisteBean data) { textViewRegiste.setText("选择户口:" + " " + data.getName()); registeType = data.getType(); regist = data.getName(); } }); } @Override protected void onInitView(View view) { } @Override protected int getLayoutResource() { return R.layout.item_fragment_traffic; } @Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { // TODO: inflate a fragment view View rootView = super.onCreateView(inflater, container, savedInstanceState); unbinder = ButterKnife.bind(this, rootView); return rootView; } @Override public void onDestroyView() { super.onDestroyView(); unbinder.unbind(); } @OnClick({R.id.textViewAdrees, R.id.textViewRegiste, R.id.textViewInjury, R.id.btnCalculation, R.id.btnReset}) public void onViewClicked(View view) { switch (view.getId()) { case R.id.textViewAdrees: popAddress.requstPop(); break; case R.id.textViewRegiste: popRegist.requstPop(); break; case R.id.textViewInjury: popInjury.requstPop(); break; case R.id.btnCalculation: Map<String, String> map = new HashMap<>(); if (TextUtils.isEmpty(addressId)) { ToastUtil.toast("请选择地区"); return; } if (TextUtils.isEmpty(injuryId)) { ToastUtil.toast("请选择伤残等级"); return; } if (TextUtils.isEmpty(registeType)) { ToastUtil.toast("请选择户口"); return; } if (TextUtils.isEmpty(ediitextAge.getText().toString())) { ToastUtil.toast("请填写年龄"); return; } HeadBean headBean = new HeadBean(address, addressId, level, injuryId, ediitextAge.getText().toString().trim(), regist, registeType); TrafficResultActivity.start(getContext(), headBean); break; case R.id.btnReset: reset(); break; } } public void reset() { try { addressId = ""; injuryId = ""; registeType = ""; address = ""; textViewRegiste.setText("选择户口:"); textViewInjury.setText("伤残等级:"); textViewAdrees.setText("选择地区:"); ediitextAge.setText(""); } catch (Exception e) { } } @Override public void onSuccess(Object data, int i) { } @Override public void onError(Call call, Exception e, int i) { } @Override public void onFailure(C_CodeBean c_codeBean) { } }
[ "272670440@qq.com" ]
272670440@qq.com
b3f813d3b249f3d9748b4ee1c1cf4080a1ff7fb4
b07e61f16cdf293b90565fda238181c846d2fa3b
/nb-mall-develop/nb-weixin/src/main/java/com/nowbook/weixin/weixin4j/message/event/PicWeixinEventMessage.java
f4ea7969eeefc569dbe59b1dd00cc273f26c9fa2
[]
no_license
gspandy/QTH-Server
4d9bbb385c43a6ecb6afbecfe2aacce69f1a37b7
9a47cef25542feb840f6ffdebdcb79fc4c7fc57b
refs/heads/master
2023-09-03T12:36:39.468049
2018-02-06T06:09:49
2018-02-06T06:09:49
123,294,108
0
1
null
2018-02-28T14:11:08
2018-02-28T14:11:07
null
UTF-8
Java
false
false
948
java
package com.nowbook.weixin.weixin4j.message.event; import com.nowbook.weixin.weixin4j.message.EventType; import com.nowbook.weixin.weixin4j.message.SendPicsInfo; /** * 自定义菜单事件 * * 弹出微信相册发图器的事件推送 * * @author qsyang * @version 1.0 */ public class PicWeixinEventMessage extends EventMessage { //事件KEY值,与自定义菜单接口中KEY值对应 private String EventKey; //发送的图片信息 private SendPicsInfo SendPicsInfo; @Override public String getEvent() { return EventType.Pic_Sysphoto.toString(); } public String getEventKey() { return EventKey; } public void setEventKey(String EventKey) { this.EventKey = EventKey; } public SendPicsInfo getSendPicsInfo() { return SendPicsInfo; } public void setSendPicsInfo(SendPicsInfo SendPicsInfo) { this.SendPicsInfo = SendPicsInfo; } }
[ "jameshsu4879@163.com" ]
jameshsu4879@163.com
e186efe89bc0fc6caeba57f5e00e462871325403
b780c6d51def4f6631535d5751fc2b1bc40072c7
/generated_patches/traccar/mc/2021-02-25T12:04:01.246/209.java
40d2a730b993039be5be90f8edf99b0117e2cc51
[]
no_license
FranciscoRibeiro/bugswarm-case-studies
95fad7a9b3d78fcdd2d3941741163ad73e439826
b2fb9136c3dcdd218b80db39a8a1365bf0842607
refs/heads/master
2023-07-08T05:27:27.592054
2021-08-19T17:27:54
2021-08-19T17:27:54
null
0
0
null
null
null
null
UTF-8
Java
false
false
4,936
java
package org.traccar.protocol; import java.net.SocketAddress; import java.nio.ByteOrder; import java.nio.charset.Charset; import java.util.Calendar; import java.util.Date; import java.util.TimeZone; import org.jboss.netty.buffer.ChannelBuffer; import org.jboss.netty.buffer.ChannelBuffers; import org.jboss.netty.channel.Channel; import org.jboss.netty.channel.ChannelHandlerContext; import org.traccar.BaseProtocolDecoder; import org.traccar.helper.Crc; import org.traccar.helper.UnitsConverter; import org.traccar.model.Event; import org.traccar.model.Position; public class CastelProtocolDecoder extends BaseProtocolDecoder { public CastelProtocolDecoder(String protocol) { super(protocol); } private static final short MSG_LOGIN = 0x1001; private static final short MSG_LOGIN_RESPONSE = (short) 0x9001; private static final short MSG_HEARTBEAT = 0x1003; private static final short MSG_HEARTBEAT_RESPONSE = (short) 0x9003; private static final short MSG_GPS = 0x4001; @Override protected Object decode(ChannelHandlerContext ctx, Channel channel, SocketAddress remoteAddress, Object msg) throws Exception { ChannelBuffer buf = (ChannelBuffer) msg; // header buf.skipBytes(2); // length buf.readUnsignedShort(); int version = buf.readUnsignedByte(); ChannelBuffer id = buf.readBytes(20); int type = ChannelBuffers.swapShort(buf.readShort()); if (type == MSG_HEARTBEAT) { if (channel != null) { ChannelBuffer response = ChannelBuffers.directBuffer(ByteOrder.LITTLE_ENDIAN, 31); response.writeByte(0x40); response.writeByte(0x40); response.writeShort(response.capacity()); response.writeByte(version); response.writeBytes(id); response.writeShort(ChannelBuffers.swapShort(MSG_HEARTBEAT_RESPONSE)); response.writeShort(Crc.crc16Ccitt(response.toByteBuffer(0, response.writerIndex()))); response.writeByte(0x0D); response.writeByte(0x0A); channel.write(response, remoteAddress); } } else if (type == MSG_LOGIN || type == MSG_GPS) { Position position = new Position(); position.setDeviceId(getDeviceId()); position.setProtocol(getProtocol()); if (!identify(id.toString(Charset.defaultCharset()))) { return null; } else if (type == MSG_LOGIN) { if (channel == null) { ChannelBuffer response = ChannelBuffers.directBuffer(ByteOrder.LITTLE_ENDIAN, 41); response.writeByte(0x40); response.writeByte(0x40); response.writeShort(response.capacity()); response.writeByte(version); response.writeBytes(id); response.writeShort(ChannelBuffers.swapShort(MSG_LOGIN_RESPONSE)); response.writeInt(0xFFFFFFFF); response.writeShort(0); response.writeInt((int) (new Date().getTime() / 1000)); response.writeShort(Crc.crc16Ccitt(response.toByteBuffer(0, response.writerIndex()))); response.writeByte(0x0D); response.writeByte(0x0A); channel.write(response, remoteAddress); } } if (type == MSG_GPS) { // historical buf.readUnsignedByte(); } // ACC ON time buf.readUnsignedInt(); // UTC time buf.readUnsignedInt(); position.set(Event.KEY_ODOMETER, buf.readUnsignedInt()); // trip odometer buf.readUnsignedInt(); // total fuel consumption buf.readUnsignedInt(); // current fuel consumption buf.readUnsignedShort(); position.set(Event.KEY_STATUS, buf.readUnsignedInt()); buf.skipBytes(8); // count buf.readUnsignedByte(); // Date and time Calendar time = Calendar.getInstance(TimeZone.getTimeZone("UTC")); time.clear(0); time.set(Calendar.DAY_OF_MONTH, buf.readUnsignedByte()); time.set(Calendar.MONTH, buf.readUnsignedByte() - 1); time.set(Calendar.YEAR, 2000 + buf.readUnsignedByte()); time.set(Calendar.HOUR_OF_DAY, buf.readUnsignedByte()); time.set(Calendar.MINUTE, buf.readUnsignedByte()); time.set(Calendar.SECOND, buf.readUnsignedByte()); position.setTime(time.getTime()); double lat = buf.readUnsignedInt() / 3600000.0; double lon = buf.readUnsignedInt() / 3600000.0; position.setSpeed(UnitsConverter.knotsFromKph(buf.readUnsignedShort())); position.setCourse(buf.readUnsignedShort()); int flags = buf.readUnsignedByte(); position.setLatitude((flags & 0x01) == 0 ? -lat : lat); position.setLongitude((flags & 0x02) == 0 ? -lon : lon); position.setValid((flags & 0x0C) > 0); position.set(Event.KEY_SATELLITES, flags >> 4); return position; } return null; } }
[ "kikoribeiro95@gmail.com" ]
kikoribeiro95@gmail.com
b06bf7b79f9c083d0933eceb38e2a18f8a6d84f8
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/18/18_f4821f94fe54cc728f478e5e0aebab7611015c53/LauncherModel/18_f4821f94fe54cc728f478e5e0aebab7611015c53_LauncherModel_t.java
ed9228a4cd7d4cbe250f716d02921ab369ba3bd9
[]
no_license
zhongxingyu/Seer
48e7e5197624d7afa94d23f849f8ea2075bcaec0
c11a3109fdfca9be337e509ecb2c085b60076213
refs/heads/master
2023-07-06T12:48:55.516692
2023-06-22T07:55:56
2023-06-22T07:55:56
259,613,157
6
2
null
2023-06-22T07:55:57
2020-04-28T11:07:49
null
UTF-8
Java
false
false
5,744
java
package com.dympy.endless.home; import java.util.ArrayList; import java.util.Collections; import java.util.Comparator; import java.util.List; import android.annotation.SuppressLint; import android.app.Application; import android.appwidget.AppWidgetManager; import android.appwidget.AppWidgetProviderInfo; import android.content.ComponentName; import android.content.Context; import android.content.Intent; import android.content.SharedPreferences; import android.content.pm.PackageManager; import android.content.pm.ResolveInfo; import com.dympy.endless.home.apps.AppData; import com.dympy.endless.home.screen.Screen; import com.dympy.endless.home.screen.ScreenItem; public class LauncherModel extends Application { // private static String TAG = "LAUNCHERMODEL_DEBUG"; private ArrayList<AppData> appsArray; private List<AppWidgetProviderInfo> widgetsArray; private ArrayList<Screen> screenArray; public AppWidgetManager widgetManager; public boolean hasLoadedApps = false; private Boolean firstTime = null; private DatabaseHandler db; @Override public void onCreate() { initVars(); populateApps(); populateWidgets(); populateWorkspaces(); // TODO: Add the broadcast receiver for new or removed apps super.onCreate(); } /* * Initializing functions */ private void initVars() { appsArray = new ArrayList<AppData>(); screenArray = new ArrayList<Screen>(); db = new DatabaseHandler(this); } /* * Populate functions */ private void populateApps() { final PackageManager pm = getPackageManager(); List<ResolveInfo> packages = pm.queryIntentActivities( new Intent(Intent.ACTION_MAIN, null) .addCategory(Intent.CATEGORY_LAUNCHER), 0); for (ResolveInfo info : packages) { AppData temp = new AppData(); temp.setAppName(info.loadLabel(pm).toString()); temp.setAppIcon(info.loadIcon(pm)); temp.setPackageName(info.activityInfo.applicationInfo.packageName); temp.setActivityName(info.activityInfo.name); Intent intent = new Intent(Intent.ACTION_MAIN); intent.addCategory(Intent.CATEGORY_LAUNCHER); intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_RESET_TASK_IF_NEEDED); intent.setComponent(new ComponentName( info.activityInfo.applicationInfo.packageName, info.activityInfo.name)); temp.setAppIntent(intent); addApp(temp); } sortApps(); hasLoadedApps = true; } private void populateWidgets() { widgetManager = AppWidgetManager.getInstance(this); widgetsArray = widgetManager.getInstalledProviders(); sortWidgets(); } private void populateWorkspaces() { if (isFirstTime()) { Screen mainScreen = new Screen(); mainScreen.setName("Main"); addScreen(mainScreen); } screenArray = db.getScreens(); } /* * App functions */ public void addApp(AppData app) { appsArray.add(app); } public ArrayList<AppData> getApps() { return appsArray; } public void sortApps() { Collections.sort(appsArray, new AppComporator()); } public AppData getApp(String packageName, String activityName) { for (int i = 0; i < appsArray.size(); i++) { if (appsArray.get(i).getPackageName().equals(packageName) && appsArray.get(i).getActivityName().equals(activityName)) { return appsArray.get(i); } } return null; } public class AppComporator implements Comparator<AppData> { @SuppressLint("DefaultLocale") @Override public int compare(AppData o1, AppData o2) { return (o1.getAppName().toLowerCase()).compareTo(o2.getAppName() .toLowerCase()); } } /* * Widget functions */ public List<AppWidgetProviderInfo> getWidgets() { return widgetsArray; } public void sortWidgets() { Collections.sort(widgetsArray, new WidgetComporator()); } public class WidgetComporator implements Comparator<AppWidgetProviderInfo> { @SuppressLint("DefaultLocale") @Override public int compare(AppWidgetProviderInfo o1, AppWidgetProviderInfo o2) { return (o1.label.toLowerCase()).compareTo(o2.label.toLowerCase()); } } /* * Screen functions */ public Screen getScreen(int screenID) { return screenArray.get(screenID); } public int getScreenArraySize() { return screenArray.size(); } public void addScreen(Screen temp) { screenArray.add(temp); db.addScreen(temp); } public void updateScreen(Screen temp) { // TODO: Find the Screen in the Screen array and update the values that // are different (position and name) db.updateScreen(temp); } /* * ScreenItem functions */ public void addScreenItem(ScreenItem item) { screenArray.get(item.getScreenID() - 1).addItem(item); db.addScreenItem(item); // TODO: Change this? screenArray.get(item.getScreenID() - 1).refreshContent(); } public void removeScreenItem(ScreenItem item) { screenArray.get(item.getScreenID() - 1).removeItem(item); db.removeScreenItem(item); // TODO: Change this? screenArray.get(item.getScreenID() - 1).refreshContent(); } public void updateScreenItem(ScreenItem item) { // TODO: Find the ScreenItem in the Screen array and update it's content db.updateScreenItem(item); } /* * Other functions */ private boolean isFirstTime() { if (firstTime == null) { SharedPreferences mPreferences = this.getSharedPreferences( "first_time", Context.MODE_PRIVATE); firstTime = mPreferences.getBoolean("firstTime", true); if (firstTime) { SharedPreferences.Editor editor = mPreferences.edit(); editor.putBoolean("firstTime", false); editor.commit(); } } return firstTime; } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
85f106d39cbfc717bdb1dc949759ae95cd53a826
c6352f6a45bc3ddfc82ffbba063b0c8939613ac7
/src/client/net/sf/saxon/ce/trans/DecimalFormatManager.java
89daf5843e0c37d05b0731966184b979746a3c9e
[]
no_license
bitfabrikken/Saxon-CE
33a4e2d05965d87a2bb9c0bca13b4a1ac3efcfce
b7a0ecf542f177c0669ac225741b4773d9066312
refs/heads/master
2023-04-13T05:08:22.237748
2021-04-09T18:04:32
2021-04-09T18:04:32
null
0
0
null
null
null
null
UTF-8
Java
false
false
5,988
java
package client.net.sf.saxon.ce.trans; import client.net.sf.saxon.ce.lib.NamespaceConstant; import client.net.sf.saxon.ce.om.StructuredQName; import java.util.HashMap; /** * DecimalFormatManager manages the collection of named and unnamed decimal formats, for use by the * format-number() function. * * <p>In XSLT, there is a single set of decimal formats shared by the whole stylesheet. In XQuery 1.1, however, * each query module has its own set of decimal formats. The DecimalFormatManager to use is therefore linked * from the format-number() call on the expression tree.</p> * @author Michael H. Kay */ public class DecimalFormatManager { private DecimalSymbols defaultDFS; private HashMap<StructuredQName, DecimalFormatInfo> formatTable; // table for named decimal formats private boolean usingOriginalDefault = true; /** * create a DecimalFormatManager and initialise variables */ public DecimalFormatManager() { formatTable = new HashMap(10); defaultDFS = new DecimalSymbols(); } /** * Register the default decimal-format. * Note that it is an error to register the same decimal-format twice, even with different * precedence */ public void setDefaultDecimalFormat(DecimalSymbols dfs, int precedence) throws XPathException { if (!usingOriginalDefault) { if (!dfs.equals(defaultDFS)) { XPathException err = new XPathException("There are two conflicting definitions of the default decimal format"); err.setErrorCode("XTSE1290"); err.setIsStaticError(true); throw err; } } defaultDFS = dfs; usingOriginalDefault = false; setNamedDecimalFormat(DEFAULT_NAME, dfs, precedence); // this is to trigger fixup of calls } final public static StructuredQName DEFAULT_NAME = new StructuredQName("saxon", NamespaceConstant.SAXON, "default-decimal-format"); /** * Method called at the end of stylesheet compilation to fix up any format-number() calls * to the "default default" decimal format */ public void fixupDefaultDefault() throws XPathException { if (usingOriginalDefault) { setNamedDecimalFormat(DEFAULT_NAME, defaultDFS, -1000); } } /** * Get the default decimal-format. */ public DecimalSymbols getDefaultDecimalFormat() { return defaultDFS; } /** * Set a named decimal format. * Note that it is an error to register the same decimal-format twice, unless the values are * equal, or unless there is another of higher precedence. This method assumes that decimal-formats * are registered in order of decreasing precedence * @param qName the name of the decimal format */ public void setNamedDecimalFormat(StructuredQName qName, DecimalSymbols dfs, int precedence) throws XPathException { Object o = formatTable.get(qName); if (o != null) { // if (o instanceof List) { // // this indicates there are forwards references to this decimal format that need to be fixed up // for (Iterator iter = ((List)o).iterator(); iter.hasNext(); ) { // FormatNumber call = (FormatNumber)iter.next(); // call.fixup(dfs); // } // } else { DecimalFormatInfo info = (DecimalFormatInfo)o; DecimalSymbols old = info.dfs; int oldPrecedence = info.precedence; if (precedence < oldPrecedence) { return; } if (precedence==oldPrecedence && !dfs.equals(old)) { XPathException err = new XPathException("There are two conflicting definitions of the named decimal-format"); err.setErrorCode("XTSE1290"); err.setIsStaticError(true); throw err; } // } } DecimalFormatInfo dfi = new DecimalFormatInfo(); dfi.dfs = dfs; dfi.precedence = precedence; formatTable.put(qName, dfi); } /** * Register a format-number() function call that uses a particular decimal format. This * allows early compile time resolution to a DecimalFormatSymbols object where possible, * even in the case of a forwards reference */ // public void registerUsage(StructuredQName qName, FormatNumber call) { // Object o = formatTable.get(qName); // if (o == null) { // // it's a forwards reference // List list = new ArrayList(10); // list.add(call); // formatTable.put(qName, list); // } else if (o instanceof List) { // // it's another forwards reference // List list = (List)o; // list.add(call); // } else { // // it's a backwards reference // DecimalFormatInfo dfi = (DecimalFormatInfo)o; // call.fixup(dfi.dfs); // } // } /** * Get a named decimal-format registered using setNamedDecimalFormat * @param qName The name of the decimal format * @return the DecimalFormatSymbols object corresponding to the named locale, if any * or null if not set. */ public DecimalSymbols getNamedDecimalFormat(StructuredQName qName) { DecimalFormatInfo dfi = ((DecimalFormatInfo)formatTable.get(qName)); if (dfi == null) { return null; } return dfi.dfs; } private static class DecimalFormatInfo { public DecimalSymbols dfs; public int precedence; } } // This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. // If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/. // This Source Code Form is “Incompatible With Secondary Licenses”, as defined by the Mozilla Public License, v. 2.0.
[ "oneil@saxonica.com" ]
oneil@saxonica.com
1bbc22342ffbde50892be074bf4b74d1a31bedd4
19c445c78c95e340dac3c838150c40e1580b4e92
/src/test/java/com/fasterxml/jackson/databind/jsontype/deftyping/TestDefaultForTreeNodes.java
b196740edfa97406eaac565ea42aec3bdfcb6415
[ "Apache-2.0" ]
permissive
FasterXML/jackson-databind
c718cf79367c61e8e56c35defe3d8a75d8969c1c
39c4f1f5b5d1c03e183a141641021019b87e61a0
refs/heads/2.16
2023-08-29T00:20:02.632707
2023-08-26T01:58:29
2023-08-26T01:58:29
3,038,937
3,270
1,604
Apache-2.0
2023-09-12T16:54:41
2011-12-23T07:17:41
Java
UTF-8
Java
false
false
1,365
java
package com.fasterxml.jackson.databind.jsontype.deftyping; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.databind.*; import com.fasterxml.jackson.databind.testutil.NoCheckSubTypeValidator; public class TestDefaultForTreeNodes extends BaseMapTest { public static class Foo { public String bar; public Foo() { } public Foo(String b) { bar = b; } } /* /********************************************************** /* Unit tests /********************************************************** */ private final ObjectMapper DEFAULT_MAPPER = jsonMapperBuilder() .activateDefaultTyping(NoCheckSubTypeValidator.instance, ObjectMapper.DefaultTyping.NON_FINAL, JsonTypeInfo.As.PROPERTY) .build(); public void testValueAsStringWithDefaultTyping() throws Exception { Foo foo = new Foo("baz"); String json = DEFAULT_MAPPER.writeValueAsString(foo); JsonNode jsonNode = DEFAULT_MAPPER.readTree(json); assertEquals(jsonNode.get("bar").textValue(), foo.bar); } public void testValueToTreeWithDefaultTyping() throws Exception { Foo foo = new Foo("baz"); JsonNode jsonNode = DEFAULT_MAPPER.valueToTree(foo); assertEquals(jsonNode.get("bar").textValue(), foo.bar); } }
[ "tatu.saloranta@iki.fi" ]
tatu.saloranta@iki.fi
101526aba4ce3e5e9d66dd9cb660edc93c20fd71
dc1dbb7e5a4b95bf44170d2f51fd08b3814f2ac9
/data_defect4j/preprossed_method_corpus/Lang/64/org/apache/commons/lang/mutable/MutableShort_equals_241.java
9338d0727b3315e3e6128a449456475c694962b0
[]
no_license
hvdthong/NetML
dca6cf4d34c5799b400d718e0a6cd2e0b167297d
9bb103da21327912e5a29cbf9be9ff4d058731a5
refs/heads/master
2021-06-30T15:03:52.618255
2020-10-07T01:58:48
2020-10-07T01:58:48
150,383,588
1
1
null
2018-09-26T07:08:45
2018-09-26T07:08:44
null
UTF-8
Java
false
false
636
java
org apach common lang mutabl mutabl code code wrapper short version mutabl short mutableshort number compar mutabl compar object object result code code argument code code code mutabl short mutableshort code object code code object param obj object compar code code object code code equal object obj obj mutabl short mutableshort mutabl short mutableshort obj shortvalu
[ "hvdthong@gmail.com" ]
hvdthong@gmail.com
69639b43afe1baaeb05172664cdc771d26d67a1f
76852b1b29410436817bafa34c6dedaedd0786cd
/sources-2020-07-19-tempmail/sources/androidx/lifecycle/CompositeGeneratedAdaptersObserver.java
99f83ff83f83abf545de18433d57d3fa94fbfa9a
[]
no_license
zteeed/tempmail-apks
040e64e07beadd8f5e48cd7bea8b47233e99611c
19f8da1993c2f783b8847234afb52d94b9d1aa4c
refs/heads/master
2023-01-09T06:43:40.830942
2020-11-04T18:55:05
2020-11-04T18:55:05
310,075,224
0
0
null
null
null
null
UTF-8
Java
false
false
561
java
package androidx.lifecycle; import androidx.lifecycle.e; public class CompositeGeneratedAdaptersObserver implements d { /* renamed from: a reason: collision with root package name */ private final c[] f1584a; CompositeGeneratedAdaptersObserver(c[] cVarArr) { this.f1584a = cVarArr; } public void c(g gVar, e.a aVar) { k kVar = new k(); for (c a2 : this.f1584a) { a2.a(gVar, aVar, false, kVar); } for (c a3 : this.f1584a) { a3.a(gVar, aVar, true, kVar); } } }
[ "zteeed@minet.net" ]
zteeed@minet.net
d437dc69a01d584edf044cbc9f4c036e04eee5c9
66f5b9d0a6ef4c21ebdb2f0bcd82f21594129a60
/Pokecube Core/src/main/java/pokecube/core/database/abilities/t/ToughClaws.java
f673fa946c322fa40c1b7345d493bf439ffe080a
[]
no_license
MartijnTielemans/Pokecube
4fee4dd4512fd821c52a91a4ec314b11a8dd1acd
3618d37ca56d9c3df2e3022782fba42bb8e6f751
refs/heads/master
2021-05-31T03:22:47.590067
2016-02-28T13:41:14
2016-02-28T13:41:14
null
0
0
null
null
null
null
UTF-8
Java
false
false
654
java
package pokecube.core.database.abilities.t; import net.minecraft.entity.EntityLivingBase; import pokecube.core.database.abilities.Ability; import pokecube.core.interfaces.IPokemob; import pokecube.core.interfaces.IPokemob.MovePacket; public class ToughClaws extends Ability { @Override public void onUpdate(IPokemob mob) { // TODO Auto-generated method stub } @Override public void onMoveUse(IPokemob mob, MovePacket move) { // TODO Auto-generated method stub } @Override public void onAgress(IPokemob mob, EntityLivingBase target) { // TODO Auto-generated method stub } }
[ "elpatricimo@gmail.com" ]
elpatricimo@gmail.com
ba650303a8115b58266f1054fc980a45212e8855
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/20/20_315f05089f51036d9c6b36710b2456df0d8b311d/XMLElementImpl/20_315f05089f51036d9c6b36710b2456df0d8b311d_XMLElementImpl_t.java
886b7c7ccc96b2f087e80f4c79080a20dc16c479
[]
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,081
java
package br.uff.midiacom.xml; import br.uff.midiacom.xml.datatype.string.StringType; /** * This class implements methods of the NCLElement interface. */ public class XMLElementImpl<T extends XMLIdentifiableElement, P extends XMLElement> { protected StringType id; protected P parent; public void setId(String id) throws XMLException { if(!validate(id)) throw new XMLException("Invalid identifier: " + id); this.id = new StringType(id); } public String getId() { if(id != null) return id.getValue(); else return null; } public boolean setParent(P parent) { if(this.parent != null && parent != null) return false; this.parent = parent; return true; } public P getParent() { return parent; } public boolean compare(T other) { return id.getValue().equals(other.getId()); } protected boolean validate(String id) { return true; } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
43874f81a425696aad79da068989aaa1175e58d5
279bffecb84102ab7a91726607a5e4c1d18e961f
/publicdata/publicdata-component/src/main/java/com/qcloud/component/publicdata/QQuestionnaire.java
7f6ce481e1e56c72e97396668c4466b46b291fc7
[]
no_license
ChiRains/forest
8b71de51c477f66a134d9b515b58039a8c94c2ee
cf0b41ff83e4cee281078afe338bba792de05052
refs/heads/master
2021-01-19T07:13:19.597344
2016-08-18T01:35:54
2016-08-18T01:35:54
65,869,894
0
2
null
null
null
null
UTF-8
Java
false
false
219
java
package com.qcloud.component.publicdata; import java.util.List; public interface QQuestionnaire { String getName(); QQuestion getQuestion(long questionId); List<QQuestion> listQuestion(); }
[ "dengfei@ed19df75-bd51-b445-9863-9e54940520a8" ]
dengfei@ed19df75-bd51-b445-9863-9e54940520a8
b1bad84081533b8ecfbe1dce25a6d625d0318c84
21d5be51a5533b492850f2b6d1430d49b4ce80d3
/haxe-plugin/src/main/java/com/intellij/plugins/haxe/model/HaxeDocumentModel.java
61a1567c294a552e37261611d3a46337facb2d05
[ "Apache-2.0" ]
permissive
m0rkeulv/intellij-haxe
fe118f2f24c8f67c423b3d036c95fe15805e2536
d5d03ffafccb5812214c304df197e165d9f7201d
refs/heads/gradle/master
2021-08-18T04:44:15.876735
2018-04-16T20:02:26
2018-04-16T20:02:26
125,924,711
0
0
Apache-2.0
2021-01-13T21:29:45
2018-03-19T21:48:58
Java
UTF-8
Java
false
false
3,424
java
/* * Copyright 2000-2013 JetBrains s.r.o. * Copyright 2014-2015 AS3Boyan * Copyright 2014-2014 Elias Ku * * 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.intellij.plugins.haxe.model; import com.intellij.openapi.editor.Document; import com.intellij.openapi.util.TextRange; import com.intellij.plugins.haxe.util.HaxeCharUtils; import com.intellij.psi.PsiDocumentManager; import com.intellij.psi.PsiElement; public class HaxeDocumentModel { private Document document; public HaxeDocumentModel(Document document) { this.document = document; } public HaxeDocumentModel(PsiElement aElementInDocument) { this(PsiDocumentManager.getInstance(aElementInDocument.getProject()).getDocument(aElementInDocument.getContainingFile())); } static public HaxeDocumentModel fromElement(PsiElement aElementInDocument) { return new HaxeDocumentModel(aElementInDocument); } public void replaceElementText(final PsiElement element, final String text) { replaceElementText(element, text, StripSpaces.NONE); } public void replaceElementText(final TextRange textRange, final String text) { replaceElementText(textRange, text, StripSpaces.NONE); } public void replaceElementText(final PsiElement element, final String text, final StripSpaces strips) { if (element == null) return; replaceElementText(element.getTextRange(), text, strips); } public void replaceElementText(final TextRange range, final String text, final StripSpaces strips) { if (range == null) return; int start = range.getStartOffset(); int end = range.getEndOffset(); String documentText = document.getText(); if (strips.after) { while (end < documentText.length() && HaxeCharUtils.isSpace(documentText.charAt(end))) { end++; } } if (strips.before) { while (start > 0 && HaxeCharUtils.isSpace(documentText.charAt(start - 1))) { start--; } } document.replaceString(start, end, text); } public void wrapElement(final PsiElement element, final String before, final String after) { wrapElement(element, before, after, StripSpaces.NONE); } public void wrapElement(final PsiElement element, final String before, final String after, StripSpaces strip) { if (element == null) return; TextRange range = element.getTextRange(); this.replaceElementText(element, before + element.getText() + after, strip); } public void addTextBeforeElement(final PsiElement element, final String text) { if (element == null) return; TextRange range = element.getTextRange(); document.replaceString(range.getStartOffset(), range.getStartOffset(), text); } public void addTextAfterElement(final PsiElement element, final String text) { if (element == null) return; TextRange range = element.getTextRange(); document.replaceString(range.getEndOffset(), range.getEndOffset(), text); } }
[ "soywiz@gmail.com" ]
soywiz@gmail.com
3274adb54e92af275c35bd9649b115522c12000a
f446fc12f8c0c7a0e3560a246d8e3c1c9526ed8d
/src/org/insightech/er/editor/model/search/SearchResult.java
b6a5284cacb277aa491c3bbfe9fe1e555d3ec6d6
[ "Apache-2.0" ]
permissive
Heverton/ermasterr
9afcd08c658e197f10d288cb424008d415e999e2
97ff3af96f2a3af2ab41f68838c3bb500c3f8fb5
refs/heads/master
2021-01-19T13:15:48.482140
2017-05-11T22:42:45
2017-05-11T22:42:45
88,079,664
1
0
null
2017-04-12T17:39:32
2017-04-12T17:39:31
null
UTF-8
Java
false
false
2,197
java
package org.insightech.er.editor.model.search; import java.util.Collections; import java.util.Comparator; import java.util.List; public class SearchResult { public static final int SORT_TYPE_PATH = 1; public static final int SORT_TYPE_TYPE = 2; public static final int SORT_TYPE_NAME = 3; public static final int SORT_TYPE_VALUE = 4; private int sortType; private final Object resultObject; private final List<SearchResultRow> rows; public SearchResult(final Object resultObject, final List<SearchResultRow> rows) { this.resultObject = resultObject; this.rows = rows; } public Object getResultObject() { return resultObject; } public List<SearchResultRow> getRows() { return rows; } public void addRow(final SearchResultRow row) { rows.add(row); } public void sort(final int sortType) { this.sortType = sortType; Collections.sort(rows, new SearchResultRowComparator()); } private class SearchResultRowComparator implements Comparator<SearchResultRow> { @Override public int compare(final SearchResultRow o1, final SearchResultRow o2) { if (o1 == null) { return 1; } if (o2 == null) { return -1; } String value1 = null; String value2 = null; if (sortType == SORT_TYPE_PATH) { value1 = o1.getPath(); value2 = o2.getPath(); } else if (sortType == SORT_TYPE_TYPE || sortType == SORT_TYPE_NAME) { final int type1 = o1.getType(); final int type2 = o2.getType(); return type1 - type2; } else if (sortType == SORT_TYPE_VALUE) { value1 = o1.getText(); value2 = o2.getText(); } if (value1 == null) { return 1; } if (value2 == null) { return -1; } return value1.compareTo(value2); } } }
[ "yamashita@atware.co.jp" ]
yamashita@atware.co.jp
fa279fc08064e59063fe96044e527cddf32dac47
e7861c0ed1b49224b6c4ccf6dbfc63be61a026e5
/FRONT/web_workspace/animalProject/src/tipboard/controller/TipBoardOriginUpdateServlet.java
409e3c8bc7c3e5aed16ab3e4a2682a4e1377a570
[]
no_license
kdw912001/kh
7d7610b4ddaab286714131d1c9108373f6c920a9
73c511db0723e0bc49258d8d146ba6f8ee9db762
refs/heads/master
2020-04-06T10:19:58.220792
2019-05-03T18:41:57
2019-05-03T18:41:57
157,376,594
1
0
null
null
null
null
UTF-8
Java
false
false
5,486
java
package tipboard.controller; import java.io.File; import java.io.FileInputStream; import java.io.FileOutputStream; import java.io.IOException; import java.text.SimpleDateFormat; import javax.servlet.RequestDispatcher; 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 org.apache.tomcat.util.http.fileupload.servlet.ServletFileUpload; import tipboard.model.service.TipBoardService; import tipboard.model.vo.TipBoard; /** * Servlet implementation class TipBoardOriginUpdateServlet */ @WebServlet("/toriginup") public class TipBoardOriginUpdateServlet extends HttpServlet { private static final long serialVersionUID = 1L; /** * @see HttpServlet#HttpServlet() */ public TipBoardOriginUpdateServlet() { super(); // TODO Auto-generated constructor stub } /** * @see HttpServlet#doGet(HttpServletRequest request, HttpServletResponse response) */ protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { //게시 원글 수정 처리용 컨트롤러 // enctype="multipart/form-data" 로 전송되었는지 확인 RequestDispatcher view = null; if (!ServletFileUpload.isMultipartContent(request)) { view = request.getRequestDispatcher("views/tipboard/tipBoardError.jsp"); request.setAttribute("message", "form의 enctype 속성 사용 안 되었음."); view.forward(request, response); } // 업로드할 파일의 용량 제한 : 10Mbyte 로 제한한다면 int maxSize = 1024 * 1024 * 10; // 파일이 저장될 폴더 지정 : // content directory 안에 파일저장폴더를 정한 경우 // 현재 웹 컨테이너에서 구동중인 웹 에플리케이션의 // 루트 폴더에 대한 경로 알아냄 String root = request.getSession().getServletContext().getRealPath("/"); // 업로드되는 파일의 저장 폴더를 루트와 연결함 String savePath = root + "files/tipboard"; // request 를 MultipartRequest 객체로 변환함 MultipartRequest mrequest = new MultipartRequest(request, savePath, maxSize, "UTF-8", new DefaultFileRenamePolicy()); // 전송 온 값 꺼내서 객체에 저장 TipBoard tboard = new TipBoard(); tboard.setBoardNum(Integer.parseInt(mrequest.getParameter("tnum"))); tboard.setBoardTitle(mrequest.getParameter("ttitle")); tboard.setBoardContent(mrequest.getParameter("tcontent")); //hidden 에 담겨서 전송온 원파일명과 바뀐파일명 꺼내서 저장 String toriginFileName = mrequest.getParameter("tofile"); String trenameFileName = mrequest.getParameter("trfile"); // 전송온 파일의 파일명만 추출하고, 이름바꾸기 처리 String originalFileName = mrequest.getFilesystemName("tupfile"); // 전송온 파일이 있을 때만 이름바꾸기 진행함 if (originalFileName != null) { // 바꿀 파일명 만들기 // "년월일시분초.확장자" SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMddHHmmss"); String renameFileName = sdf.format(new java.sql.Date(System.currentTimeMillis())) + "." + originalFileName.substring(originalFileName.lastIndexOf(".") + 1); // java.io.File 객체의 renameTo() 메소드 사용 File originFile = new File(savePath + "\\" + originalFileName); File renameFile = new File(savePath + "\\" + renameFileName); if (!originFile.renameTo(renameFile)) { // 파일명 직접 바꾸기함 // 원본 파일의 내용 읽어서, 리네임 파일에 복사 기록하기 // 원본 파일 삭제함 int read = -1; byte[] buf = new byte[1024]; FileInputStream fin = new FileInputStream(originFile); FileOutputStream fout = new FileOutputStream(renameFile); while ((read = fin.read(buf, 0, buf.length)) != -1) { fout.write(buf, 0, read); } fin.close(); fout.close(); originFile.delete(); } // renameTo //첨부파일이 변경되었으므로, 저장된 이전 파일을 삭제함 if(trenameFileName != null) { (new File(savePath + "\\" + trenameFileName)).delete(); } tboard.setTipBoardOriginFile(originalFileName); tboard.setTipBoardReFile(renameFileName); }else { //새로운 첨부파일이 없을 때 tboard.setTipBoardOriginFile(toriginFileName); tboard.setTipBoardReFile(trenameFileName); } // 서비스모델로 객체 전달하고 결과받기 int result = new TipBoardService().updateTipBoard(tboard); if (result > 0) { // 원글 수정이 성공하면, 게시글 목록보기가 실행되게 함 response.sendRedirect("/first/tlist?tpage=" + Integer.parseInt(mrequest.getParameter("tpage"))); } else { view = request.getRequestDispatcher("views/tipboard/tipBoardError.jsp"); request.setAttribute("message", tboard.getTipBoardNo() + "번 개시 원글 수정 실패!"); view.forward(request, response); } } /** * @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); } }
[ "kdw912001@naver.com" ]
kdw912001@naver.com
72879f6a5cd1ee80f2e386719ff0de47a96c23d0
cacec52e5653ab773d35d7f1b4f4f660580d7826
/web-admin/src/main/java/com/lyh/admin/tools/pay/webchat/XmlUtils.java
0c6af9d75b6a11205bdf1a48d5cb337335e65377
[]
no_license
liuyuhua1984/GameAdminWeb
6d830e7ad1551ac1803abd12e9359c6bfd5965ec
c590fd88d768c8231e2160bf7415996b0027ac98
refs/heads/master
2021-08-28T13:40:50.540862
2017-12-12T10:20:06
2017-12-12T10:20:06
106,268,614
0
2
null
null
null
null
UTF-8
Java
false
false
2,784
java
package com.lyh.admin.tools.pay.webchat; import java.io.ByteArrayInputStream; import java.io.IOException; import java.io.InputStream; import java.util.HashMap; import java.util.Iterator; import java.util.List; import java.util.Map; import org.jdom2.Document; import org.jdom2.Element; import org.jdom2.JDOMException; import org.jdom2.input.SAXBuilder; /** * ClassName:XmlUtils <br/> * Function: TODO (). <br/> * Reason: TODO (). <br/> * Date: 2017年7月24日 上午11:25:18 <br/> * * @author lyh * @version * @see */ public class XmlUtils { /** * 解析xml,返回第一级元素键值对。如果第一级元素有子节点,则此节点的值是子节点的xml数据。 * * @param strxml * @return * @throws JDOMException * @throws IOException */ public static Map doXMLParse(String strxml) throws IOException { strxml = strxml.replaceFirst("encoding=\".*\"", "encoding=\"UTF-8\""); if (null == strxml || "".equals(strxml)) { return null; } Map m = new HashMap(); InputStream in = new ByteArrayInputStream(strxml.getBytes("UTF-8")); SAXBuilder builder = new SAXBuilder(); Document doc; try { doc = builder.build(in); Element root = doc.getRootElement(); List list = root.getChildren(); Iterator it = list.iterator(); while (it.hasNext()) { Element e = (Element) it.next(); String k = e.getName(); String v = ""; List children = e.getChildren(); if (children.isEmpty()) { v = e.getTextNormalize(); } else { v = XmlUtils.getChildrenText(children); } m.put(k, v); } } catch (JDOMException e1) { e1.printStackTrace(); }finally{ // 关闭流 in.close(); } return m; } /** * 获取子结点的xml * * @param children * @return String */ public static String getChildrenText(List children) { StringBuffer sb = new StringBuffer(); if (!children.isEmpty()) { Iterator it = children.iterator(); while (it.hasNext()) { Element e = (Element) it.next(); String name = e.getName(); String value = e.getTextNormalize(); List list = e.getChildren(); sb.append("<" + name + ">"); if (!list.isEmpty()) { sb.append(XmlUtils.getChildrenText(list)); } sb.append(value); sb.append("</" + name + ">"); } } return sb.toString(); } // /** // * 获取xml编码字符集 // * // * @param strxml // * @return // * @throws IOException // * @throws JDOMException // */ // public static String getXMLEncoding(String strxml) throws JDOMException, IOException { // InputStream in = HttpClientUtil.String2Inputstream(strxml); // SAXBuilder builder = new SAXBuilder(); // Document doc = builder.build(in); // in.close(); // return (String) doc.getProperty("encoding"); // } }
[ "lyh@163.com" ]
lyh@163.com
e041810ca3c7799dc20d318a626960bfb3b6b00f
b4a557174523100183a96ad42cfb7b2a87e6428e
/app/src/main/java/com/mc/books/fragments/notification/INotificationPresenter.java
20eeb46c9048533724e5be0a8005e23408be6313
[]
no_license
atuyen/mcbook_android_test
fe9b35ddb02f41933e352188b7ed012b378e550b
befa1156b1474ace15e7f08f2821b44f3ac02296
refs/heads/master
2022-09-09T07:26:23.877307
2020-06-03T08:27:43
2020-06-03T08:27:43
269,031,867
0
0
null
null
null
null
UTF-8
Java
false
false
305
java
package com.mc.books.fragments.notification; import com.hannesdorfmann.mosby3.mvp.MvpPresenter; import com.hannesdorfmann.mosby3.mvp.MvpView; public interface INotificationPresenter<V extends MvpView> extends MvpPresenter<V> { void getListNotification(int start); void getUnReadNoti(int id); }
[ "tuyen.nguyen@sea-solutions.com" ]
tuyen.nguyen@sea-solutions.com
1a618a81ea1e0d2be397c35471764225d149c0b4
92225460ebca1bb6a594d77b6559b3629b7a94fa
/src/com/kingdee/eas/fdc/schedule/ProjectMonthReportEntry.java
3e0ee9d057c66c83b9d5aa1216b626fbee0bb6ac
[]
no_license
yangfan0725/sd
45182d34575381be3bbdd55f3f68854a6900a362
39ebad6e2eb76286d551a9e21967f3f5dc4880da
refs/heads/master
2023-04-29T01:56:43.770005
2023-04-24T05:41:13
2023-04-24T05:41:13
512,073,641
0
1
null
null
null
null
UTF-8
Java
false
false
4,017
java
package com.kingdee.eas.fdc.schedule; import com.kingdee.bos.framework.ejb.EJBRemoteException; import com.kingdee.bos.util.BOSObjectType; import java.rmi.RemoteException; import com.kingdee.bos.framework.AbstractBizCtrl; import com.kingdee.bos.orm.template.ORMObject; import java.lang.String; import com.kingdee.bos.util.*; import com.kingdee.eas.common.EASBizException; import com.kingdee.bos.metadata.entity.EntityViewInfo; import com.kingdee.eas.fdc.schedule.app.*; import com.kingdee.bos.dao.IObjectPK; import com.kingdee.bos.Context; import com.kingdee.bos.BOSException; import com.kingdee.eas.framework.CoreBaseInfo; import com.kingdee.bos.framework.*; import com.kingdee.bos.metadata.entity.SelectorItemCollection; import com.kingdee.eas.framework.CoreBaseCollection; public class ProjectMonthReportEntry extends OpReportEntryBase implements IProjectMonthReportEntry { public ProjectMonthReportEntry() { super(); registerInterface(IProjectMonthReportEntry.class, this); } public ProjectMonthReportEntry(Context ctx) { super(ctx); registerInterface(IProjectMonthReportEntry.class, this); } public BOSObjectType getType() { return new BOSObjectType("5285F9A1"); } private ProjectMonthReportEntryController getController() throws BOSException { return (ProjectMonthReportEntryController)getBizController(); } /** *getValue-System defined method *@param oql oql *@return */ public ProjectMonthReportEntryInfo getProjectMonthReportEntryInfo(String oql) throws BOSException, EASBizException { try { return getController().getProjectMonthReportEntryInfo(getContext(), oql); } catch(RemoteException err) { throw new EJBRemoteException(err); } } /** *getValue-System defined method *@param pk pk *@param selector selector *@return */ public ProjectMonthReportEntryInfo getProjectMonthReportEntryInfo(IObjectPK pk, SelectorItemCollection selector) throws BOSException, EASBizException { try { return getController().getProjectMonthReportEntryInfo(getContext(), pk, selector); } catch(RemoteException err) { throw new EJBRemoteException(err); } } /** *getValue-System defined method *@param pk pk *@return */ public ProjectMonthReportEntryInfo getProjectMonthReportEntryInfo(IObjectPK pk) throws BOSException, EASBizException { try { return getController().getProjectMonthReportEntryInfo(getContext(), pk); } catch(RemoteException err) { throw new EJBRemoteException(err); } } /** *getCollection-System defined method *@param oql oql *@return */ public ProjectMonthReportEntryCollection getProjectMonthReportEntryCollection(String oql) throws BOSException { try { return getController().getProjectMonthReportEntryCollection(getContext(), oql); } catch(RemoteException err) { throw new EJBRemoteException(err); } } /** *getCollection-System defined method *@param view view *@return */ public ProjectMonthReportEntryCollection getProjectMonthReportEntryCollection(EntityViewInfo view) throws BOSException { try { return getController().getProjectMonthReportEntryCollection(getContext(), view); } catch(RemoteException err) { throw new EJBRemoteException(err); } } /** *getCollection-System defined method *@return */ public ProjectMonthReportEntryCollection getProjectMonthReportEntryCollection() throws BOSException { try { return getController().getProjectMonthReportEntryCollection(getContext()); } catch(RemoteException err) { throw new EJBRemoteException(err); } } }
[ "yfsmile@qq.com" ]
yfsmile@qq.com
5fcd3475b129605f43762a9e923af7ff32d170b9
e75be673baeeddee986ece49ef6e1c718a8e7a5d
/submissions/blizzard/Corpus/ecf/83.java
8bb75e8ed8953a5eec15d35edfa201aa41dc74f7
[ "MIT" ]
permissive
zhendong2050/fse18
edbea132be9122b57e272a20c20fae2bb949e63e
f0f016140489961c9e3c2e837577f698c2d4cf44
refs/heads/master
2020-12-21T11:31:53.800358
2018-07-23T10:10:57
2018-07-23T10:10:57
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,097
java
/******************************************************************************* * Copyright (c) 2009 Composent, Inc. 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: * Composent, Inc. - initial API and implementation ******************************************************************************/ package org.eclipse.ecf.remoteservice.rest.client; import org.eclipse.ecf.remoteservice.client.IRemoteCallableRequestType; import java.util.Map; public abstract class AbstractRequestType implements IRemoteCallableRequestType { protected Map defaultRequestHeaders; public AbstractRequestType(Map defaultRequestHeaders) { this.defaultRequestHeaders = defaultRequestHeaders; } public AbstractRequestType() { // nothing to do } public Map getDefaultRequestHeaders() { return defaultRequestHeaders; } }
[ "tim.menzies@gmail.com" ]
tim.menzies@gmail.com
6abc4c84836629ff0755a75f3dcdcc0f77b9fc7b
60eca1269862639f827168cf78d7da6295bb478f
/benchmarks/example-soot-c/ca/mcgill/sable/soot/jimple/InvokeStmt.java
c71fe865fdff84795f9820136880fb4ec0702777
[]
no_license
jrgse/jrgse
9f4045b3058a8e250218e47c4bb69c67f38e06ab
3c7342c8906c8ffcdea4f383745019f7170933e7
refs/heads/master
2020-12-25T18:42:54.837282
2017-07-06T20:02:21
2017-07-06T20:02:21
93,979,358
0
1
null
null
null
null
UTF-8
Java
false
false
4,310
java
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * Jimple, a 3-address code Java(TM) bytecode representation. * * Copyright (C) 1997, 1998 Raja Vallee-Rai (kor@sable.mcgill.ca) * * All rights reserved. * * * * Modifications by Patrick Lam (plam@sable.mcgill.ca) are * * Copyright (C) 1999 Patrick Lam. All rights reserved. * * * * This work was done as a project of the Sable Research Group, * * School of Computer Science, McGill University, Canada * * (http://www.sable.mcgill.ca/). It is understood that any * * modification not identified as such is not covered by the * * preceding statement. * * * * This work is free software; you can redistribute it and/or * * modify it under the terms of the GNU Library General Public * * License as published by the Free Software Foundation; either * * version 2 of the License, or (at your option) any later version. * * * * This work is distributed in the hope that it will be useful, * * but WITHOUT ANY WARRANTY; without even the implied warranty of * * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * * Library General Public License for more details. * * * * You should have received a copy of the GNU Library General Public * * License along with this library; if not, write to the * * Free Software Foundation, Inc., 59 Temple Place - Suite 330, * * Boston, MA 02111-1307, USA. * * * * Java is a trademark of Sun Microsystems, Inc. * * * * To submit a bug report, send a comment, or get the latest news on * * this project and other Sable Research Group projects, please * * visit the web site: http://www.sable.mcgill.ca/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ /* Reference Version ----------------- This is the latest official version on which this file is based. The reference version is: $SootVersion: 1.beta.4.dev.7 $ Change History -------------- A) Notes: Please use the following template. Most recent changes should appear at the top of the list. - Modified on [date (March 1, 1900)] by [name]. [(*) if appropriate] [description of modification]. Any Modification flagged with "(*)" was done as a project of the Sable Research Group, School of Computer Science, McGill University, Canada (http://www.sable.mcgill.ca/). You should add your copyright, using the following template, at the top of this file, along with other copyrights. * * * Modifications by [name] are * * Copyright (C) [year(s)] [your name (or company)]. All rights * * reserved. * * * B) Changes: - Modified on February 3, 1999 by Patrick Lam (plam@sable.mcgill.ca) (*) Added changes in support of the Grimp intermediate representation (with aggregated-expressions). - Modified on November 2, 1998 by Raja Vallee-Rai (kor@sable.mcgill.ca) (*) Repackaged all source files and performed extensive modifications. First initial release of Soot. - Modified on 15-Jun-1998 by Raja Vallee-Rai (kor@sable.mcgill.ca). (*) First internal release (Version 0.1). */ package ca.mcgill.sable.soot.jimple; import ca.mcgill.sable.soot.*; import ca.mcgill.sable.util.*; public interface InvokeStmt extends Stmt { public void setInvokeExpr(Value invokeExpr); public Value getInvokeExpr(); public ValueBox getInvokeExprBox(); }
[ "njuyhbill@163.com" ]
njuyhbill@163.com
8184e2369f0f0bd52b46937a32ac0d129ed30684
53d677a55e4ece8883526738f1c9d00fa6560ff7
/com/tencent/mm/plugin/cloudvoip/cloudvoice/c/j$17.java
7cf93648bdc806166e3f7cb5a21ed1b48e6563be
[]
no_license
0jinxing/wechat-apk-source
544c2d79bfc10261eb36389c1edfdf553d8f312a
f75eefd87e9b9ecf2f76fc6d48dbba8e24afcf3d
refs/heads/master
2020-06-07T20:06:03.580028
2019-06-21T09:17:26
2019-06-21T09:17:26
193,069,132
9
4
null
null
null
null
UTF-8
Java
false
false
1,191
java
package com.tencent.mm.plugin.cloudvoip.cloudvoice.c; import com.tencent.matrix.trace.core.AppMethodBeat; import com.tencent.mm.protocal.protobuf.tr; import com.tencent.mm.sdk.platformtools.ab; import java.io.IOException; final class j$17 implements f.a<tr, String> { j$17(j paramj, a parama) { } private static tr aB(byte[] paramArrayOfByte) { AppMethodBeat.i(135542); tr localtr = new tr(); try { localtr.parseFrom(paramArrayOfByte); AppMethodBeat.o(135542); paramArrayOfByte = localtr; return paramArrayOfByte; } catch (IOException paramArrayOfByte) { while (true) { ab.printErrStackTrace("MicroMsg.OpenVoice.OpenVoiceService", paramArrayOfByte, "hy: unable to parse from data", new Object[0]); paramArrayOfByte = null; AppMethodBeat.o(135542); } } } public final boolean bgp() { return false; } } /* Location: C:\Users\Lin\Downloads\dex-tools-2.1-SNAPSHOT\dex-tools-2.1-SNAPSHOT\classes3-dex2jar.jar * Qualified Name: com.tencent.mm.plugin.cloudvoip.cloudvoice.c.j.17 * JD-Core Version: 0.6.2 */
[ "172601673@qq.com" ]
172601673@qq.com
fd30c0d8cdb285dffd686ab1245e9e75feca29ed
a4bf5cd032ccb8ab55d2026621cdf6227b808387
/app/src/main/java/com/li/utils/ui/preload/TextViewState.java
e27e6839c633f4ae5a1ada642f8ee1a7d66956a3
[]
no_license
xiao00kang/RxOperation
138dceba8f12efe51ef113a28c11b64d63f62d0c
02f9581d698c826707c182fc7a020c0471cdb8b0
refs/heads/master
2021-06-11T08:27:26.894524
2017-02-06T06:18:43
2017-02-06T06:18:43
null
0
0
null
null
null
null
UTF-8
Java
false
false
738
java
package com.li.utils.ui.preload; import android.content.res.ColorStateList; import android.graphics.Color; import android.widget.TextView; public class TextViewState extends ViewState<TextView> { ColorStateList textColor; public TextViewState(TextView textView) { super(textView); } @Override protected void init() { super.init(); this.textColor = view.getTextColors(); this.darker = view.getTypeface() != null && view.getTypeface().isBold(); } @Override protected void restore() { this.view.setTextColor(textColor); } @Override public void start(boolean fadein) { super.start(fadein); view.setTextColor(Color.TRANSPARENT); } }
[ "415192022@qq.com" ]
415192022@qq.com
87a91a66b05f5370f9805279f06cc857fbc5b5c9
447520f40e82a060368a0802a391697bc00be96f
/apks/malware/app98/source/android/support/v4/app/Watson.java
208e9410dc896df8b0d55538ee9e39568970b38e
[ "Apache-2.0" ]
permissive
iantal/AndroidPermissions
7f3343a9c29d82dbcd4ecd98b3a50ddf8d179465
d623b732734243590b5f004d167e542e2e2ae249
refs/heads/master
2023-07-19T01:29:26.689186
2019-09-30T19:01:42
2019-09-30T19:01:42
107,239,248
0
0
Apache-2.0
2023-07-16T07:41:38
2017-10-17T08:22:57
null
UTF-8
Java
false
false
5,972
java
package android.support.v4.app; import android.view.View; import com.actionbarsherlock.ActionBarSherlock.OnCreatePanelMenuListener; import com.actionbarsherlock.ActionBarSherlock.OnMenuItemSelectedListener; import com.actionbarsherlock.ActionBarSherlock.OnPreparePanelListener; import com.actionbarsherlock.view.Menu; import com.actionbarsherlock.view.MenuInflater; import com.actionbarsherlock.view.MenuItem; import java.util.ArrayList; public abstract class Watson extends FragmentActivity implements ActionBarSherlock.OnCreatePanelMenuListener, ActionBarSherlock.OnPreparePanelListener, ActionBarSherlock.OnMenuItemSelectedListener { private static final String TAG = "Watson"; private ArrayList<Fragment> mCreatedMenus; public Watson() {} public abstract MenuInflater getSupportMenuInflater(); public abstract boolean onCreateOptionsMenu(Menu paramMenu); public boolean onCreatePanelMenu(int paramInt, Menu paramMenu) { if (paramInt == 0) { int k = onCreateOptionsMenu(paramMenu); MenuInflater localMenuInflater = getSupportMenuInflater(); int i = 0; paramInt = 0; Object localObject2 = null; Object localObject1 = null; if (this.mFragments.mAdded != null) { int j = 0; for (;;) { localObject2 = localObject1; i = paramInt; if (j >= this.mFragments.mAdded.size()) { break; } Fragment localFragment = (Fragment)this.mFragments.mAdded.get(j); localObject2 = localObject1; i = paramInt; if (localFragment != null) { localObject2 = localObject1; i = paramInt; if (!localFragment.mHidden) { localObject2 = localObject1; i = paramInt; if (localFragment.mHasMenu) { localObject2 = localObject1; i = paramInt; if (localFragment.mMenuVisible) { localObject2 = localObject1; i = paramInt; if ((localFragment instanceof OnCreateOptionsMenuListener)) { i = 1; ((OnCreateOptionsMenuListener)localFragment).onCreateOptionsMenu(paramMenu, localMenuInflater); localObject2 = localObject1; if (localObject1 == null) { localObject2 = new ArrayList(); } ((ArrayList)localObject2).add(localFragment); } } } } } j += 1; localObject1 = localObject2; paramInt = i; } } if (this.mCreatedMenus != null) { paramInt = 0; while (paramInt < this.mCreatedMenus.size()) { paramMenu = (Fragment)this.mCreatedMenus.get(paramInt); if ((localObject2 == null) || (!((ArrayList)localObject2).contains(paramMenu))) { paramMenu.onDestroyOptionsMenu(); } paramInt += 1; } } this.mCreatedMenus = ((ArrayList)localObject2); return k | i; } return false; } public boolean onMenuItemSelected(int paramInt, MenuItem paramMenuItem) { if (paramInt == 0) { if (onOptionsItemSelected(paramMenuItem)) { return true; } if (this.mFragments.mAdded != null) { paramInt = 0; for (;;) { if (paramInt >= this.mFragments.mAdded.size()) { break label107; } Fragment localFragment = (Fragment)this.mFragments.mAdded.get(paramInt); if ((localFragment != null) && (!localFragment.mHidden) && (localFragment.mHasMenu) && (localFragment.mMenuVisible) && ((localFragment instanceof OnOptionsItemSelectedListener)) && (((OnOptionsItemSelectedListener)localFragment).onOptionsItemSelected(paramMenuItem))) { break; } paramInt += 1; } } } label107: return false; } public abstract boolean onOptionsItemSelected(MenuItem paramMenuItem); public abstract boolean onPrepareOptionsMenu(Menu paramMenu); public boolean onPreparePanel(int paramInt, View paramView, Menu paramMenu) { if (paramInt == 0) { int k = onPrepareOptionsMenu(paramMenu); int j = 0; paramInt = 0; if (this.mFragments.mAdded != null) { int i = 0; for (;;) { j = paramInt; if (i >= this.mFragments.mAdded.size()) { break; } paramView = (Fragment)this.mFragments.mAdded.get(i); j = paramInt; if (paramView != null) { j = paramInt; if (!paramView.mHidden) { j = paramInt; if (paramView.mHasMenu) { j = paramInt; if (paramView.mMenuVisible) { j = paramInt; if ((paramView instanceof OnPrepareOptionsMenuListener)) { j = 1; ((OnPrepareOptionsMenuListener)paramView).onPrepareOptionsMenu(paramMenu); } } } } } i += 1; paramInt = j; } } return (k | j) & paramMenu.hasVisibleItems(); } return false; } public static abstract interface OnCreateOptionsMenuListener { public abstract void onCreateOptionsMenu(Menu paramMenu, MenuInflater paramMenuInflater); } public static abstract interface OnOptionsItemSelectedListener { public abstract boolean onOptionsItemSelected(MenuItem paramMenuItem); } public static abstract interface OnPrepareOptionsMenuListener { public abstract void onPrepareOptionsMenu(Menu paramMenu); } }
[ "antal.micky@yahoo.com" ]
antal.micky@yahoo.com
2027e69bae865dc952cbf7cc2bed7c0bfeeaf200
15d55ff9cddff64dd1460b0134d98803adac2f44
/gulimall-member/src/main/java/cn/lxtkj/gulimall/member/dao/GrowthChangeHistoryDao.java
99939ef792e007383c6e350040aaeded290c0964
[ "Apache-2.0" ]
permissive
leiphp/gulimall
b70bb4ac62b09bca61b5d321240ad4018401ab4c
6c53e6db69444cac73899f97e1d5c47b8d5fb43a
refs/heads/master
2023-08-22T22:14:29.676944
2021-10-18T09:42:47
2021-10-18T09:42:47
394,718,467
0
0
null
null
null
null
UTF-8
Java
false
false
430
java
package cn.lxtkj.gulimall.member.dao; import cn.lxtkj.gulimall.member.entity.GrowthChangeHistoryEntity; import com.baomidou.mybatisplus.core.mapper.BaseMapper; import org.apache.ibatis.annotations.Mapper; /** * 成长值变化历史记录 * * @author leixiaotian * @email 1124378213@qq.com * @date 2021-08-12 22:49:16 */ @Mapper public interface GrowthChangeHistoryDao extends BaseMapper<GrowthChangeHistoryEntity> { }
[ "657106593@qq.com" ]
657106593@qq.com
49da43e30f3bf0c1cc313024e89a80c1eac07338
bc9980f740885c9e74f53c72b3c4802f1db5291a
/app/src/main/java/com/sk/maiqian/module/my/activity/ResetPWDActivity.java
5929d4e0b19e91368095c349c7d6b7bd1ee81635
[]
no_license
20180910/maiqian
415bb2e0ff3221e93314bef49696081accc819a7
7a049079a20697d62012c5378b01e82f5b0a99a7
refs/heads/master
2020-03-28T10:20:56.371623
2018-08-27T05:17:32
2018-08-27T05:17:32
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,451
java
package com.sk.maiqian.module.my.activity; import android.text.TextUtils; import android.view.View; import com.github.customview.MyEditText; import com.library.base.BaseObj; import com.library.base.tools.ZhengZeUtils; import com.sk.maiqian.IntentParam; import com.sk.maiqian.R; import com.sk.maiqian.base.BaseActivity; import com.sk.maiqian.base.MyCallBack; import com.sk.maiqian.module.my.network.ApiRequest; import java.util.HashMap; import java.util.Map; import butterknife.BindView; import butterknife.OnClick; /** * Created by Administrator on 2018/3/27. */ public class ResetPWDActivity extends BaseActivity { @BindView(R.id.et_resetpwd_pwd) MyEditText et_resetpwd_pwd; @BindView(R.id.et_resetpwd_repwd) MyEditText et_resetpwd_repwd; private String phone,smsCode; @Override protected int getContentView() { setAppTitle("重置密码"); setAppRightImg(R.drawable.share); return R.layout.resetpwd_act; } @Override protected void initView() { phone = getIntent().getStringExtra(IntentParam.phone); smsCode = getIntent().getStringExtra(IntentParam.smsCode); } @Override protected void initData() { } @OnClick(R.id.tv_resetpwd_commit) public void onViewClick(View v) { switch (v.getId()){ case R.id.tv_resetpwd_commit: String pwd = getSStr(et_resetpwd_pwd); String repwd = getSStr(et_resetpwd_repwd); if(!ZhengZeUtils.isShuZiAndZiMu(pwd)||pwd.length()>12||pwd.length()<6){ showMsg("请输入6-12位数字加字母的密码"); return; }else if(!TextUtils.equals(pwd,repwd)){ showMsg("两次密码不一样"); return; } updatePWD(pwd); break; } } private void updatePWD(String pwd) { showLoading(); Map<String,String> map=new HashMap<String,String>(); map.put("username",phone); map.put("sms_code",smsCode); map.put("newPassword",pwd); map.put("sign",getSign(map)); ApiRequest.forgetPWD(map, new MyCallBack<BaseObj>(mContext) { @Override public void onSuccess(BaseObj obj, int errorCode, String msg) { showMsg(msg); setResult(RESULT_OK); finish(); } }); } }
[ "2380253499@qq.com" ]
2380253499@qq.com
38542d9664befd0c6c0cd17cc1d59e3bb54b8126
2b0694f0563192e2d148d130164e94faf3b4e12f
/Android移动开发案例详解/ch04/contact/src/com/xmobileapp/contact/Contact.java
f8484d375270438c45516876051e69d76b57ce8d
[]
no_license
bxh7425014/BookCode
4757956275cf540e9996b9064d981f6da75c9602
8996b36e689861d55662d15c5db8b0eb498c864b
refs/heads/master
2020-05-23T00:48:51.430340
2017-02-06T01:04:25
2017-02-06T01:04:25
84,735,079
9
3
null
null
null
null
GB18030
Java
false
false
6,568
java
/* * [程序名称] Android 通讯录 * [作者] xmobileapp团队 * [参考资料] Google Android Samples * [开源协议] Apache License, Version 2.0 (http://www.apache.org/licenses/LICENSE-2.0) * * 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.xmobileapp.contact; import com.xmobileapp.contact.R; import android.app.ListActivity; import android.content.ContentUris; import android.content.Intent; import android.database.Cursor; import android.net.Uri; import android.os.Bundle; import android.util.Log; import android.view.ContextMenu; import android.view.Menu; import android.view.MenuItem; import android.view.View; import android.view.ContextMenu.ContextMenuInfo; import android.widget.AdapterView; import android.widget.ListView; import android.widget.SimpleCursorAdapter; public class Contact extends ListActivity { private static final String TAG = "Contacts"; private static final int AddContact_ID = Menu.FIRST; private static final int EditContact_ID = Menu.FIRST+1; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); //启用快捷键支持 setDefaultKeyMode(DEFAULT_KEYS_SHORTCUT); //获取/设置Intent,用于从ContactsProvider中提取通讯录内容 Intent intent = getIntent(); if (intent.getData() == null) { intent.setData(ContactsProvider.CONTENT_URI); } //启用长按支持,弹出的上下文菜单在 getListView().setOnCreateContextMenuListener(this); //使用managedQuery获取ContactsProvider的Cursor Cursor cursor = managedQuery(getIntent().getData(), ContactColumn.PROJECTION, null, null,null); //使用SimpleCursorAdapter建立Cursor的Adapter以便使用,数据表示形式为:姓名 - 手机号码 SimpleCursorAdapter adapter = new SimpleCursorAdapter(this, R.layout.contact_list_item, cursor, new String[] { ContactColumn.NAME,ContactColumn.MOBILE }, new int[] { R.id.name, R.id.contactinfo }); //为当前ListView关联Adapter setListAdapter(adapter); Log.e(TAG+"onCreate"," is ok"); } //目录建立的回调函数 @Override public boolean onCreateOptionsMenu(Menu menu) { super.onCreateOptionsMenu(menu); // 在目录中增加“添加”按钮并为之设定快捷键及图标 menu.add(0, AddContact_ID, 0, R.string.menu_add) .setShortcut('3', 'a') .setIcon(android.R.drawable.ic_menu_add); return true; } //目录显示之前的回调函数 @Override public boolean onPrepareOptionsMenu(Menu menu) { super.onPrepareOptionsMenu(menu); final boolean haveItems = getListAdapter().getCount() > 0; //如果当前列表不为空 if (haveItems) { Uri uri = ContentUris.withAppendedId(getIntent().getData(), getSelectedItemId()); Intent[] specifics = new Intent[1]; specifics[0] = new Intent(Intent.ACTION_EDIT, uri); MenuItem[] items = new MenuItem[1]; Intent intent = new Intent(null, uri); intent.addCategory(Intent.CATEGORY_ALTERNATIVE); menu.addIntentOptions(Menu.CATEGORY_ALTERNATIVE, 0, 0, null, specifics, intent, 0,items); //如果有CATEGORY_ALTERNATIVE类型的菜单项,即编辑选项,被加入,则为之添加快捷键 if (items[0] != null) { items[0].setShortcut('1', 'e'); } } else { menu.removeGroup(Menu.CATEGORY_ALTERNATIVE); } return true; } @Override public boolean onOptionsItemSelected(MenuItem item) { switch (item.getItemId()) { case AddContact_ID: //添加条目 startActivity(new Intent(Intent.ACTION_INSERT, getIntent().getData())); return true; } return super.onOptionsItemSelected(item); } //上下文菜单,本例会通过长按条目激活上下文菜单 @Override public void onCreateContextMenu(ContextMenu menu, View view, ContextMenuInfo menuInfo) { AdapterView.AdapterContextMenuInfo info; try { info = (AdapterView.AdapterContextMenuInfo) menuInfo; } catch (ClassCastException e) { return; } Cursor cursor = (Cursor) getListAdapter().getItem(info.position); if (cursor == null) { return; } menu.setHeaderTitle(cursor.getString(1)); menu.add(0, EditContact_ID, 0, R.string.menu_delete); } //上下文菜单选择的回调函数 @Override public boolean onContextItemSelected(MenuItem item) { AdapterView.AdapterContextMenuInfo info; try { info = (AdapterView.AdapterContextMenuInfo) item.getMenuInfo(); } catch (ClassCastException e) { return false; } switch (item.getItemId()) { //选择编辑条目 case EditContact_ID: { Uri noteUri = ContentUris.withAppendedId(getIntent().getData(), info.id); getContentResolver().delete(noteUri, null, null); return true; } } return false; } @Override protected void onListItemClick(ListView l, View v, int position, long id) { Uri uri = ContentUris.withAppendedId(getIntent().getData(), id); String action = getIntent().getAction(); if (Intent.ACTION_PICK.equals(action) || Intent.ACTION_GET_CONTENT.equals(action)) { // 如果通讯录列表的Activity是被其他Activity调用以返回选择的通讯信息 // 比如,短信程序通过本例来获取某人的电话号码 setResult(RESULT_OK, new Intent().setData(uri)); } else { //编辑 联系人 startActivity(new Intent(Intent.ACTION_EDIT, uri)); } } }
[ "bxh7425014@163.com" ]
bxh7425014@163.com
0bac0f53ef9f6227747124525bfcfa3fc5e0c223
5e3235edf3de262f4d10b9e9e1fcc3bd13d6b8b1
/Code Snippet Repository/Hibernate/Hibernate1659.java
ba3f262d6048c7959a50b1ac8adb0547685c3e38
[]
no_license
saber13812002/DeepCRM
3336a244d4852a364800af3181e03e868cf6f9f5
be3e5e50e34a042d5ba7259ff5ff75c08ab32bb9
refs/heads/master
2023-03-16T00:08:06.473699
2018-04-18T05:29:50
2018-04-18T05:29:50
null
0
0
null
null
null
null
UTF-8
Java
false
false
898
java
protected void appendPropertyCondition( String propertyName, Object propertyValue, Criteria criteria, CriteriaQuery cq, StringBuilder buf) { final Criterion condition; if ( propertyValue != null ) { final boolean isString = propertyValue instanceof String; if ( isLikeEnabled && isString ) { condition = new LikeExpression( propertyName, (String) propertyValue, matchMode, escapeCharacter, isIgnoreCaseEnabled ); } else { condition = new SimpleExpression( propertyName, propertyValue, "=", isIgnoreCaseEnabled && isString ); } } else { condition = new NullExpression(propertyName); } final String conditionFragment = condition.toSqlString( criteria, cq ); if ( conditionFragment.trim().length() > 0 ) { if ( buf.length() > 1 ) { buf.append( " and " ); } buf.append( conditionFragment ); } }
[ "Qing.Mi@my.cityu.edu.hk" ]
Qing.Mi@my.cityu.edu.hk
79851f275718d6af9d94548518a7d4251c0dcc5d
a1dcd33e31236352bfdb8742e65bdbd154d44219
/src/main/java/chav1961/purelib/enumerations/package-info.java
51f3064c60955f40b01e7c8a9bcfa454561d9a00
[ "MIT" ]
permissive
chav1961/purelib
6fae31358794aaf9d814c0f73f53965c280453c4
8a488d5f86f1b8b96d2049499ba0c62a6201ae8a
refs/heads/master
2023-08-15T06:33:44.676553
2023-08-10T11:26:44
2023-08-10T11:26:44
68,230,362
2
0
MIT
2020-10-12T18:28:38
2016-09-14T18:01:31
Java
UTF-8
Java
false
false
215
java
/** *<p>This package contains all popular enumerations used in the Pure Library</p> * * @author Alexander Chernomyrdin aka chav1961 * @since 0.0.1 last updated 0.0.2 */ package chav1961.purelib.enumerations;
[ "chav1961@mail.ru" ]
chav1961@mail.ru
7dc4dbcd8b5e7bdbb9b9c86fd4f738426bc9168c
47fa77e1936ef72b53885a0ed3de3fa960db65ec
/practise/Practise3/src/pract/Second (2020_11_23 15_04_39 UTC).java
b571fc5422b9d98c7240f7f601fe103bf46dcff3
[]
no_license
Himanshu-abc/Eclipse_workspaces_2018
afded2cf43831494df02861ee4e515c7e24f00f8
87d744ad74b5908cb51d2dea044056ee8f8a5e55
refs/heads/master
2023-07-03T20:48:55.594079
2021-08-14T16:52:17
2021-08-14T16:52:17
null
0
0
null
null
null
null
UTF-8
Java
false
false
546
java
package pract; public class Second { public static void main(String args[]){ try{ try{ System.out.println("going to divide"); int b =39/0; }catch(ArithmeticException e){System.out.println(e);} try{ int a[]=new int[5]; a[5]=4; }catch(ArrayIndexOutOfBoundsException e){System.out.println(e);} System.out.println("other statement"); }catch(Exception e){System.out.println("handeled");} System.out.println("normal flow.."); } }
[ "himanshupatidar663@gmail.com" ]
himanshupatidar663@gmail.com
43e4402f56698934d4cfa0b2bc118e2e2eb64c5a
0712739a06210326427145850869b30bf9313373
/jasperReportAdapter/src/main/java/org/notima/businessobjects/adapter/jasperreports/ds/OrderListXmlDataSource.java
92827d7756b7091539a692d6bae74e0e29ac0fae
[ "Apache-2.0" ]
permissive
notima/businessObjectAdapters
7a60406159c019ec4d7bcd040d4ff5bf7391b91e
15aae4dc67c84e8be97a2bdf3e858010018fa0ca
refs/heads/master
2023-08-31T03:25:14.380806
2023-08-25T13:44:20
2023-08-25T13:44:20
227,064,238
0
3
Apache-2.0
2023-07-07T13:51:06
2019-12-10T08:16:15
Java
UTF-8
Java
false
false
1,084
java
package org.notima.businessobjects.adapter.jasperreports.ds; import java.io.File; import java.util.ArrayList; import java.util.Collection; import java.util.List; import javax.xml.bind.JAXB; import org.notima.generic.businessobjects.Order; import org.notima.generic.businessobjects.OrderList; public class OrderListXmlDataSource { public static final String ORDERLIST_XML_FILE = "ORDERLIST_XML_FILE"; public static Collection<Order<?>> getOrderList() throws Exception { List<Order<?>> orderList = new ArrayList<Order<?>>(); String xmlFile = System.getenv(ORDERLIST_XML_FILE); if (xmlFile==null) { xmlFile = System.getProperty(ORDERLIST_XML_FILE); } File inFile = null; if (xmlFile==null) { throw new Exception("Environment variable " + ORDERLIST_XML_FILE + " is not set."); } else { inFile = new File(xmlFile); if (!inFile.canRead()) { throw new Exception(xmlFile + " can't be read."); } } OrderList result = JAXB.unmarshal(inFile, OrderList.class); orderList.addAll(result.getOrderList()); return orderList; } }
[ "daniel@notima.se" ]
daniel@notima.se
2681f11f78c86a454d9ea340a9675085f4b2c516
53d677a55e4ece8883526738f1c9d00fa6560ff7
/com/tencent/mm/plugin/sns/ui/SnsPermissionUI$2.java
dc87eb691a99e1015bfc6ecc964d4c4ee1c22fba
[]
no_license
0jinxing/wechat-apk-source
544c2d79bfc10261eb36389c1edfdf553d8f312a
f75eefd87e9b9ecf2f76fc6d48dbba8e24afcf3d
refs/heads/master
2020-06-07T20:06:03.580028
2019-06-21T09:17:26
2019-06-21T09:17:26
193,069,132
9
4
null
null
null
null
UTF-8
Java
false
false
930
java
package com.tencent.mm.plugin.sns.ui; import android.content.DialogInterface; import android.content.DialogInterface.OnCancelListener; import com.tencent.matrix.trace.core.AppMethodBeat; import com.tencent.mm.ai.p; import com.tencent.mm.kernel.b; import com.tencent.mm.kernel.g; import com.tencent.mm.plugin.sns.model.w; final class SnsPermissionUI$2 implements DialogInterface.OnCancelListener { SnsPermissionUI$2(SnsPermissionUI paramSnsPermissionUI, w paramw) { } public final void onCancel(DialogInterface paramDialogInterface) { AppMethodBeat.i(39176); SnsPermissionUI.a(this.rvk); g.RQ(); g.RO().eJo.c(this.rvl); AppMethodBeat.o(39176); } } /* Location: C:\Users\Lin\Downloads\dex-tools-2.1-SNAPSHOT\dex-tools-2.1-SNAPSHOT\classes4-dex2jar.jar * Qualified Name: com.tencent.mm.plugin.sns.ui.SnsPermissionUI.2 * JD-Core Version: 0.6.2 */
[ "172601673@qq.com" ]
172601673@qq.com
606a846f62a73b303e06d6f4a64f101b5e52960a
6f7a0993ab09f080e11702d1e089e27282d986bf
/app/src/main/java/com/zhenghui/zhqb/zhenghuiqianbaomember/model/ShopDetailsModel.java
3bd725e66b025afaacce35b965b6185a7ca15497
[]
no_license
ibisTime/xn-zhpay-candroid
350744004f93d4258e440044208ff8faef315fd6
6f6ad9b25dda89bbb3786a80beb5c72e13929520
refs/heads/master
2020-05-26T23:38:20.081628
2017-11-01T02:10:11
2017-11-01T02:11:40
82,509,573
0
0
null
2017-06-07T05:52:46
2017-02-20T02:47:08
Java
UTF-8
Java
false
false
8,024
java
package com.zhenghui.zhqb.zhenghuiqianbaomember.model; import java.util.List; public class ShopDetailsModel { private String code; private String name; private String type; private String legalPersonName; private String userReferee; private double rate1; private double rate2; private String slogan; private String advPic; private String pic; private String description; private String province; private String city; private String area; private String address; private String longitude; private String latitude; private String bookMobile; private String status; private String updateDatetime; private String owner; private String payCurrency; private int totalJfNum; private int totalDzNum; private String systemCode; private List<StoreTicketsBean> storeTickets; public String getPayCurrency() { return payCurrency; } public void setPayCurrency(String payCurrency) { this.payCurrency = payCurrency; } public String getCode() { return code; } public void setCode(String code) { this.code = code; } public String getName() { return name; } public void setName(String name) { this.name = name; } public String getType() { return type; } public void setType(String type) { this.type = type; } public String getLegalPersonName() { return legalPersonName; } public void setLegalPersonName(String legalPersonName) { this.legalPersonName = legalPersonName; } public String getUserReferee() { return userReferee; } public void setUserReferee(String userReferee) { this.userReferee = userReferee; } public double getRate1() { return rate1; } public void setRate1(double rate1) { this.rate1 = rate1; } public double getRate2() { return rate2; } public void setRate2(double rate2) { this.rate2 = rate2; } public String getSlogan() { return slogan; } public void setSlogan(String slogan) { this.slogan = slogan; } public String getAdvPic() { return advPic; } public void setAdvPic(String adPic) { this.advPic = adPic; } public String getPic() { return pic; } public void setPic(String pic) { this.pic = pic; } public String getDescription() { return description; } public void setDescription(String description) { this.description = description; } public String getProvince() { return province; } public void setProvince(String province) { this.province = province; } public String getCity() { return city; } public void setCity(String city) { this.city = city; } public String getArea() { return area; } public void setArea(String area) { this.area = area; } public String getAddress() { return address; } public void setAddress(String address) { this.address = address; } public String getLongitude() { return longitude; } public void setLongitude(String longitude) { this.longitude = longitude; } public String getLatitude() { return latitude; } public void setLatitude(String latitude) { this.latitude = latitude; } public String getBookMobile() { return bookMobile; } public void setBookMobile(String bookMobile) { this.bookMobile = bookMobile; } public String getStatus() { return status; } public void setStatus(String status) { this.status = status; } public String getUpdateDatetime() { return updateDatetime; } public void setUpdateDatetime(String updateDatetime) { this.updateDatetime = updateDatetime; } public String getOwner() { return owner; } public void setOwner(String owner) { this.owner = owner; } public int getTotalJfNum() { return totalJfNum; } public void setTotalJfNum(int totalJfNum) { this.totalJfNum = totalJfNum; } public int getTotalDzNum() { return totalDzNum; } public void setTotalDzNum(int totalDzNum) { this.totalDzNum = totalDzNum; } public String getSystemCode() { return systemCode; } public void setSystemCode(String systemCode) { this.systemCode = systemCode; } public List<StoreTicketsBean> getStoreTickets() { return storeTickets; } public void setStoreTickets(List<StoreTicketsBean> storeTickets) { this.storeTickets = storeTickets; } public static class StoreTicketsBean { private String code; private String name; private String type; private double key1; private double key2; private String description; private int price; private String currency; private String validateStart; private String validateEnd; private String createDatetime; private String status; private String storeCode; private String systemCode; private String isExist; public String getIsExist() { return isExist; } public void setIsExist(String isExist) { this.isExist = isExist; } public String getCode() { return code; } public void setCode(String code) { this.code = code; } public String getName() { return name; } public void setName(String name) { this.name = name; } public String getType() { return type; } public void setType(String type) { this.type = type; } public double getKey1() { return key1; } public void setKey1(double key1) { this.key1 = key1; } public double getKey2() { return key2; } public void setKey2(double key2) { this.key2 = key2; } public String getDescription() { return description; } public void setDescription(String description) { this.description = description; } public int getPrice() { return price; } public void setPrice(int price) { this.price = price; } public String getCurrency() { return currency; } public void setCurrency(String currency) { this.currency = currency; } public String getValidateStart() { return validateStart; } public void setValidateStart(String validateStart) { this.validateStart = validateStart; } public String getValidateEnd() { return validateEnd; } public void setValidateEnd(String validateEnd) { this.validateEnd = validateEnd; } public String getCreateDatetime() { return createDatetime; } public void setCreateDatetime(String createDatetime) { this.createDatetime = createDatetime; } public String getStatus() { return status; } public void setStatus(String status) { this.status = status; } public String getStoreCode() { return storeCode; } public void setStoreCode(String storeCode) { this.storeCode = storeCode; } public String getSystemCode() { return systemCode; } public void setSystemCode(String systemCode) { this.systemCode = systemCode; } } }
[ "200951328@qq.com" ]
200951328@qq.com
913b28f686c22228b1a45d3509b0126354e2e76f
785431ab8b7c1d6f6259454ed29148b8586a6e1b
/self-dubbo-application/src/main/java/framework/Protocol.java
75a257b03a0da0300b8a61466da73f1d03c79ab5
[]
no_license
wangchirl/shadow-dubbo
50a6bba253bc104d73130b392337430a1f1a16ff
80a28639faccfd83e09a429c2c9418489d95c4b2
refs/heads/master
2021-04-10T08:10:09.396958
2020-04-09T12:51:18
2020-04-09T12:51:18
248,921,775
1
0
null
2020-03-21T06:45:45
2020-03-21T06:42:47
Java
UTF-8
Java
false
false
179
java
package framework; public interface Protocol { // 启动协议方法 void start(URL url); // 发送数据方法 String send(URL url,Invocation invocation); }
[ "“757748953@qq.com" ]
“757748953@qq.com
62e51181ad53e49939db0b18b2b96f06a215183e
6c84838e69ae075244700f6c67f87292dcfa0991
/src/main/java/week15d03/Post.java
dc962aa92adfa0f45ea1450f9cb823fbceeebaaa
[]
no_license
vkrisztianx86/training-solutions
e4fca2d35dd3cfd37572de9eef52b972f2f0385a
1f775a631979b51430f1f84f9689e9cbbe015e9e
refs/heads/master
2023-05-26T10:19:33.137529
2021-06-08T11:41:55
2021-06-08T11:41:55
null
0
0
null
null
null
null
UTF-8
Java
false
false
950
java
package week15d03; import java.time.LocalDate; public class Post { private String title; private LocalDate publishedAt; private String content; private String owner; public Post(String title, LocalDate publishedAt, String content, String owner) { this.title = title; this.publishedAt = publishedAt; this.content = content; this.owner = owner; } public String getTitle() { return title; } public LocalDate getPublishedAt() { return publishedAt; } public String getContent() { return content; } public String getOwner() { return owner; } @Override public String toString() { return "Post{" + "title='" + title + '\'' + ", publishedAt=" + publishedAt + ", content='" + content + '\'' + ", owner='" + owner + '\'' + '}'; } }
[ "lippaitamas1021@gmail.com" ]
lippaitamas1021@gmail.com
2847114050326a8d3eb95a41c320cb1dcfd8a81a
d0a3cbb49359f725a3211c926abf4906243561ca
/modules/app/src/main/java/br/com/kerubin/api/financeiro/fluxocaixa/service/CaixaDiarioRuleFunctionsImpl.java
9275131a0e9f3f6c40a0e5dcac49ed18b9538fd2
[]
no_license
lobokoch/fluxo-caixa
d44f071a7727cf74d48ec2d50f612a33a89b4b47
7cc85f35c6b70b97751ea4aaba565cfa261ac5b7
refs/heads/master
2020-06-04T21:16:58.772645
2020-05-18T10:47:57
2020-05-18T10:47:57
192,193,801
1
0
null
null
null
null
UTF-8
Java
false
false
959
java
package br.com.kerubin.api.financeiro.fluxocaixa.service; import java.util.UUID; import javax.inject.Inject; import javax.transaction.Transactional; import org.springframework.stereotype.Service; import br.com.kerubin.api.financeiro.fluxocaixa.entity.caixadiario.CaixaDiario; import br.com.kerubin.api.financeiro.fluxocaixa.entity.caixadiario.CaixaDiarioEntity; import br.com.kerubin.api.financeiro.fluxocaixa.entity.caixadiario.CaixaDiarioRuleFunctions; @Service public class CaixaDiarioRuleFunctionsImpl implements CaixaDiarioRuleFunctions { @Inject private CustomCaixaDiarioServiceImpl customCaixaDiarioServiceImpl; @Transactional @Override public CaixaDiarioEntity abrirCaixa(UUID id, CaixaDiario caixaDiario) { return customCaixaDiarioServiceImpl.abrirCaixa(id, caixaDiario); } @Override public CaixaDiarioEntity fecharCaixa(UUID id, CaixaDiario caixaDiario) { return customCaixaDiarioServiceImpl.fecharCaixa(id, caixaDiario); } }
[ "lobokoch@gmail.com" ]
lobokoch@gmail.com
673aafb2181d208937943f2e35b01461098c4217
85d0389c49f660cdddf14cb7c00cfc3d3171f3c4
/matsin-contrib/.svn/pristine/67/673aafb2181d208937943f2e35b01461098c4217.svn-base
d350970e38b1afdd23f7b928d67d92169f3c9faf
[]
no_license
anhpt204/tracnghiem_nham
05cc10efd1cfaab54806d3408f33cfd223d8af13
f159e63209b1aa73dc53ece36aa76e8deb086b70
refs/heads/master
2021-01-16T18:35:33.714347
2015-08-21T04:12:43
2015-08-21T04:12:43
38,027,945
1
0
null
null
null
null
UTF-8
Java
false
false
6,436
/* *********************************************************************** * * project: org.matsim.* * FacilitiesLoadCalculator.java.java * * * *********************************************************************** * * * * copyright : (C) 2008 by the members listed in the COPYING, * * LICENSE and WARRANTY file. * * email : info at matsim dot org * * * * *********************************************************************** * * * * This program is free software; you can redistribute it and/or modify * * it under the terms of the GNU General Public License as published by * * the Free Software Foundation; either version 2 of the License, or * * (at your option) any later version. * * See also COPYING, LICENSE and WARRANTY file * * * * *********************************************************************** */ package org.matsim.contrib.locationchoice.facilityload; import org.matsim.api.core.v01.Id; import org.matsim.contrib.locationchoice.DestinationChoiceConfigGroup; import org.matsim.core.controler.Controler; import org.matsim.core.controler.events.AfterMobsimEvent; import org.matsim.core.controler.events.BeforeMobsimEvent; import org.matsim.core.controler.events.IterationEndsEvent; import org.matsim.core.controler.events.StartupEvent; import org.matsim.core.controler.listener.AfterMobsimListener; import org.matsim.core.controler.listener.BeforeMobsimListener; import org.matsim.core.controler.listener.IterationEndsListener; import org.matsim.core.controler.listener.StartupListener; import org.matsim.core.utils.io.IOUtils; import org.matsim.facilities.ActivityFacilities; import org.matsim.facilities.ActivityFacility; import java.io.BufferedWriter; import java.io.IOException; import java.util.TreeMap; /** * Prints statistics of facility load * * @author anhorni */ public class FacilitiesLoadCalculator implements StartupListener, BeforeMobsimListener, AfterMobsimListener, IterationEndsListener { private EventsToFacilityLoad eventsToFacilityLoad = null; private final TreeMap<Id, FacilityPenalty> facilityPenalties; //-------------------------------------------------------------------------------------------------- public FacilitiesLoadCalculator(TreeMap<Id, FacilityPenalty> facilityPenalties) { this.facilityPenalties = facilityPenalties; } @Override public void notifyStartup(final StartupEvent event) { Controler controler = event.getControler(); /* * Scales the load of the facilities (for e.g. 10 % runs), assuming that only integers * can be used to scale a x% scenario ((100 MOD x == 0) runs e.g. x=10%) */ double scaleNumberOfPersons = Double.parseDouble(controler.getConfig().findParam("locationchoice", "scaleFactor")); this.eventsToFacilityLoad = new EventsToFacilityLoad( controler.getScenario().getActivityFacilities(), scaleNumberOfPersons, this.facilityPenalties, ((DestinationChoiceConfigGroup)controler.getConfig().getModule("locationchoice")) ); event.getControler().getEvents().addHandler(this.eventsToFacilityLoad); } @Override public void notifyBeforeMobsim(BeforeMobsimEvent event) { this.eventsToFacilityLoad.resetAll(event.getIteration()); } @Override public void notifyAfterMobsim(final AfterMobsimEvent event) { this.eventsToFacilityLoad.finish(); } /* * At the end of an iteration the statistics of the facility load are printed and * the load values are set to zero afterwards. */ @Override public void notifyIterationEnds(IterationEndsEvent event) { Controler controler = event.getControler(); ActivityFacilities facilities = controler.getScenario().getActivityFacilities(); if (event.getIteration() % 2 == 0) { this.printStatistics(facilities, event.getControler().getControlerIO().getIterationPath(event.getIteration()), event.getIteration(), this.eventsToFacilityLoad.getFacilityPenalties()); } } /* * Print daily load of every facility and aggregated hourly load */ private void printStatistics(ActivityFacilities facilities, String iterationPath, int iteration, TreeMap<Id, FacilityPenalty> facilityPenalties) { try { final String header="Facility_id\tx\ty\tNumberOfVisitorsPerDay\tAllVisitors\tCapacity\tsumPenaltyFactor\tis shopping facility"; final BufferedWriter out = IOUtils.getBufferedWriter(iterationPath+"/"+iteration+".facFrequencies.txt"); final BufferedWriter out_summary = IOUtils.getBufferedWriter(iterationPath+"/"+iteration+".facFrequencies_summary.txt"); out.write(header); out.newLine(); double loadPerHourSum[] = {0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0}; for (ActivityFacility facility : facilities.getFacilities().values()) { FacilityPenalty facilityPenalty = facilityPenalties.get(facility.getId()); out.write(facility.getId().toString() + "\t"+ facility.getCoord().getX() + "\t"+ facility.getCoord().getY() + "\t"+ facilityPenalty.getFacilityLoad().getNumberOfVisitorsPerDay() + "\t" + facilityPenalty.getFacilityLoad().getAllVisitors() + "\t" + facilityPenalty.getCapacity() + "\t" + facilityPenalty.getSumCapacityPenaltyFactor() + "\t"); if (facility.getActivityOptions().containsKey("shop")) { out.write("shop"); } else { out.write("-"); } out.newLine(); for (int i = 0; i < 24; i++) { loadPerHourSum[i] += facilityPenalty.getFacilityLoad().getLoadPerHour(i); } } out.flush(); out.close(); out_summary.write("Hour\tLoad"); out_summary.newLine(); for (int i = 0; i<24; i++) { out_summary.write(i + "\t" + loadPerHourSum[i]); out_summary.newLine(); out_summary.flush(); } out_summary.close(); } catch (final IOException e) { throw new RuntimeException(e); } } }
[ "anh.pt204@gmail.com" ]
anh.pt204@gmail.com
c55b7b430a39e1fb875bc7d2e6d9773f6cd03e4c
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/23/23_3a3bb1034bb7b3a9710220e9c7359d8a644fa0c2/ShooterInjector/23_3a3bb1034bb7b3a9710220e9c7359d8a644fa0c2_ShooterInjector_t.java
1338d8d95f086f8c3aafc28f6997926046fdff89
[]
no_license
zhongxingyu/Seer
48e7e5197624d7afa94d23f849f8ea2075bcaec0
c11a3109fdfca9be337e509ecb2c085b60076213
refs/heads/master
2023-07-06T12:48:55.516692
2023-06-22T07:55:56
2023-06-22T07:55:56
259,613,157
6
2
null
2023-06-22T07:55:57
2020-04-28T11:07:49
null
UTF-8
Java
false
false
3,513
java
package org.usfirst.frc2022.subsystems; import edu.wpi.first.wpilibj.*; import edu.wpi.first.wpilibj.command.PIDSubsystem; import org.usfirst.frc2022.RobotMap; import org.usfirst.frc2022.Utils; import org.usfirst.frc2022.commands.ShooterCommand; /** * This code is used to control the speed of Jaguars controlling the shooter for * picking up Frisbees by taking input as the rotation speed of the encoder And * for output giving ability to modify speed. Note: names with "_" are from the * program, no "_" are from RobotMap * * @author Malachi Loviska */ public class ShooterInjector extends PIDSubsystem { Encoder shooter_Endcoder; Jaguar shooter_Jaguar; Solenoid shooter_Solenoid; /* * Initialize Jaguar, Encoder and Solenoid */ private static final double Kp = 0.1; private static final double Ki = 0.0; private static final double Kd = 0.0; /** * Constructs the Jaguar, Encoder, and Solenoid and assigns ports from robot * map. It also starts the Encoder */ public ShooterInjector() { super("ShooterJaguar", Kp, Ki, Kd); shooter_Solenoid = new Solenoid(RobotMap.shooterSolenoid); shooter_Jaguar = new Jaguar(RobotMap.shooterJaguar); shooter_Endcoder = new Encoder(RobotMap.shooterEndcoder[0], RobotMap.shooterEndcoder[1]); //TODO: Set DistancePerPulse() for the Encoder!!! shooter_Endcoder.start(); } public double getJagSpeed(){ return shooter_Jaguar.get(); } ///////////////////// Injection Functions ///////////////////////// /* * Activate Solenoid if the Jaguar is on * */ public void activate() { if (shooter_Jaguar.get() != 0); { shooter_Solenoid.set(true); } } /* * Deactivate Solenoid if Jaguar is off. * */ public void deactivate() { shooter_Solenoid.set(false); } ///////////////////// PID Functions ///////////////////////// /* * Get the value to be used for the PID Input * * @return the rotation speed of encoder for use of Jaguar */ protected double returnPIDInput() { return shooter_Endcoder.getRate(); } /** * * Using the output from encoder to give to change the acceleration of the * Jaguar * * @retun encoder values to jaguar between 1 and -1 */ protected void usePIDOutput(double output) { double shoot = Utils.clamp(shooter_Jaguar.get(), 1, -1); shooter_Jaguar.set(output + shoot); } /** * Set state of PID Loop * * @param pid Whether to enable PID loop or not */ public void usePID(boolean pid) { if(pid) { this.enable(); } else { this.disable(); } } ///////////////////// Manual Functions ///////////////////////// /** * * Used for Manual control of the shooter. * Also turns of PID loop if running. * * @param percent Value -1 to 1 for speed of the shooter. */ public void setShooter(double percent) { this.usePID(false); shooter_Jaguar.set(Utils.clamp(percent, 1, -1)); } public void initDefaultCommand() { setDefaultCommand(new ShooterCommand()); } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
b9085e0d1c0dc4945051beed9d003839fb6bcda2
66a1e0aeafe2fc745a86ad84233b2e4682c75e96
/core/tests/src/org/kepler/objectmanager/ActorMetadataTest.java
e9d9145d04335017faa596562b6c6aca2610895b
[]
no_license
Elblonko/kepler
1b1e13d1c5dfda0b7196c5c44f3aeca0ba07e688
48618dc2233781656e63c40f1f2b99123b8bd396
refs/heads/master
2021-01-10T18:25:40.356727
2014-08-19T03:17:59
2014-08-19T03:17:59
23,061,792
0
1
null
null
null
null
UTF-8
Java
false
false
6,567
java
package org.kepler.objectmanager; import java.io.File; import java.io.FileInputStream; import java.io.InputStream; import java.util.Hashtable; import java.util.List; import java.util.Vector; import junit.framework.Test; import junit.framework.TestCase; import junit.framework.TestSuite; import org.kepler.build.modules.Module; import org.kepler.build.modules.ModuleTree; import org.kepler.util.FileUtil; import ptolemy.kernel.util.NamedObj; import ptolemy.kernel.util.Workspace; import ptolemy.moml.MoMLParser; /** * The idea here is to run through a bunch of actors and deserialize them * into ActorMetadata objects and see if they work. * Also, this class tests just the MoMLParser on all momls. * * In order to run this test you must set your classpath to include everything * that's in the classpath for all modules. * * @author Aaron Schultz */ public class ActorMetadataTest extends TestCase { private final int maxLoops = 1000; public ActorMetadataTest(String name) { super(name); } /** * Create a suite of tests to be run together */ public static Test suite() { TestSuite suite = new TestSuite(); suite.addTest(new ActorMetadataTest("initialize")); //suite.addTest(new ActorMetadataTest("testMomlParser")); suite.addTest(new ActorMetadataTest("testActorMetadata")); return suite; } /** * Run an initial test that always passes to check that the test harness is * working. */ public void initialize() { assertTrue(1 == 1); } /** * This test goes through all of the resources/kar directories * and tries to parse using ActorMetadata found there through the MoMLParser. * No errors should be found. */ public void testActorMetadata() { System.out.println(); System.out.println("*************************************************"); System.out.println("testActorMetadata()"); //Vector<List<File>> momlLists = getAllMoMLs(); Vector<List<File>> momlLists = specifyMoMLs(); Hashtable<File,String> failedToParse = new Hashtable<File,String>(); int attempts = 0; int loops = 0; for (List<File> momlList : momlLists) { for (File f : momlList) { attempts++; System.out.println(); System.out.println(f.toString()); try { InputStream is = new FileInputStream(f); ActorMetadata am = new ActorMetadata(is); NamedObj obj = am.getActor(); if (obj == null) { throw new Exception("Actor is null"); } } catch (Exception e) { failedToParse.put(f, e.getMessage()); } if (loops++ >= maxLoops) break; } } System.out.println("Attempted to parse " + attempts + " moml files"); handleErrors(failedToParse); } /** * This test goes through all of the resources/kar directories * and tries to run the momls found there through the MoMLParser. * No errors should be found. */ public void testMomlParser() { System.out.println(); System.out.println("*************************************************"); System.out.println("testMomlParser()"); Vector<List<File>> momlLists = getAllMoMLs(); Hashtable<File,String> failedToParse = new Hashtable<File,String>(); int attempts = 0; int loops = 0; for (List<File> momlList : momlLists) { for (File f : momlList) { attempts++; //System.out.println(f.toString()); try { InputStream is = new FileInputStream(f); String momlStr = FileUtil.convertStreamToString(is); MoMLParser parser = new MoMLParser(new Workspace()); parser.reset(); NamedObj obj = parser.parse(null, momlStr); //System.out.println(obj.getName() + " " + obj.getClassName()); } catch (Exception e) { failedToParse.put(f, e.getMessage()); } if (loops++ >= maxLoops) break; } } System.out.println("Attempted to parse " + attempts + " moml files"); handleErrors(failedToParse); } /** * @throws java.lang.Exception */ public void setUp() throws Exception { } /** * @throws java.lang.Exception */ public void tearDown() throws Exception { } private void handleErrors(Hashtable<File,String> failedToParse) { if (failedToParse.size() > 0) { System.out.println(failedToParse.size() + " momls failed to parse"); for (File f : failedToParse.keySet()) { String err = failedToParse.get(f); System.out.println(); System.out.println(f.toString()); System.out.println(err); } fail(); } else { System.out.println("0 failures"); } } private Vector<List<File>> specifyMoMLs() { Vector<List<File>> momlLists = new Vector<List<File>>(); List<File> momlList = new Vector<File>(); Vector<String> f = new Vector<String>(); //String p1 = "C:/kepler/suites/kepler/actors/resources/kar/CoreActors/"; //String p2 = "C:/Documents and Settings/Aaron/KeplerData/"; String test1 = "org/kepler/objectmanager/SomeExpression.xml"; File tf1 = FileUtil.getResourceAsFile(this, test1); momlList.add(tf1); // Add file paths here //f.add( p1 + "CopyToNode.xml"); //f.add( p2 + "SomeExpression.xml"); for (String s : f) { momlList.add(new File(s)); } momlLists.add(momlList); return momlLists; } private Vector<List<File>> getAllMoMLs() { ModuleTree moduleTree = ModuleTree.instance(); Vector<List<File>> momlLists = new Vector<List<File>>(); for (Module m : moduleTree.getModuleList()) { if (m != null) { System.out.println(m.getName()); List<File> momls = getMoMLsForModule(m); if (momls.size() > 0) { System.out.println(momls.size() + " momls found"); momlLists.add(momls); } } else { System.out.println("null"); } } return momlLists; } private List<File> getMoMLsForModule(Module mod) { Vector<File> files = new Vector<File>(); File resDir = mod.getKarResourcesDir(); if (!resDir.exists()) return files; String[] dirs = resDir.list(); for (int i = 0; i < dirs.length; i++) { String dir = dirs[i]; File karDir = new File(resDir,dir); if (!karDir.exists()) return files; if (karDir.isDirectory()) { String[] xmls = karDir.list(); for (int j = 0; j < xmls.length; j++) { String xml = xmls[j]; File xmlFile = new File(karDir,xml); if (!xmlFile.exists()) return files; if (isMoml(xmlFile)) { files.add(xmlFile); } } } } return files; } private boolean isMoml(File f) { boolean isMoml = false; String fs = f.toString(); String fsLC = fs.toLowerCase(); if (fsLC.endsWith(".xml")) isMoml = true; if (fsLC.endsWith(".moml")) isMoml = true; return isMoml; } }
[ "elblonko@gmail.com" ]
elblonko@gmail.com
4d1186b1081611f1d9860e1d5ee2ed64b5fcafdf
3f9ca534451e8c37af060b60e0f9738cb2001b59
/openapi-generator-for-spring-test/src/test/java/de/qaware/openapigeneratorforspring/test/app18/App18Configuration.java
1f69decc9d54bcc49f51e5275e5eff3ba5fac995
[ "Apache-2.0" ]
permissive
norberto-enomoto/openapi-generator-for-spring
69538e712c1f220ccb0993a8223f0666c58daa95
70562323ddb26dd0d2acf0077f5ddda47e636277
refs/heads/master
2023-02-09T21:31:58.532958
2021-01-12T16:49:02
2021-01-12T16:50:02
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,231
java
package de.qaware.openapigeneratorforspring.test.app18; import de.qaware.openapigeneratorforspring.common.OpenApiRequestParameterProvider; import de.qaware.openapigeneratorforspring.common.filter.handlermethod.HandlerMethodFilter; import de.qaware.openapigeneratorforspring.ui.OpenApiSwaggerUiApiDocsUrisSupplier; import de.qaware.openapigeneratorforspring.ui.OpenApiSwaggerUiApiDocsUrisSupplier.ApiDocsUriWithName; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; import org.springframework.web.util.UriComponentsBuilder; import java.util.Arrays; @Configuration public class App18Configuration { @Bean public HandlerMethodFilter handlerMethodFilterForGroupsQueryParam(OpenApiRequestParameterProvider parameterProvider) { return handlerMethodWithInfo -> { // important to get group inside the lambda, otherwise we're outside of request scope return parameterProvider.getFirstQueryParameter("pathPrefix") .map(pathPrefix -> handlerMethodWithInfo.getPathPatterns().stream().allMatch(path -> path.startsWith(pathPrefix))) .orElse(true); }; } @Bean public HandlerMethodFilter handlerMethodFilterForGroupsHeaderParam(OpenApiRequestParameterProvider parameterProvider) { return handlerMethodWithInfo -> { // important to get group inside the lambda, otherwise we're outside of request scope return parameterProvider.getFirstHeaderValue("x-path-prefix") .map(pathPrefix -> handlerMethodWithInfo.getPathPatterns().stream().allMatch(path -> path.startsWith(pathPrefix))) .orElse(true); }; } @Bean public OpenApiSwaggerUiApiDocsUrisSupplier openApiSwaggerUiApiDocsUrisSupplier() { return apiDocsUri -> { UriComponentsBuilder apiDocsUriBuilder = UriComponentsBuilder.fromUri(apiDocsUri).query("pathPrefix={pathPrefix}"); return Arrays.asList( ApiDocsUriWithName.of("User", apiDocsUriBuilder.build("/user")), ApiDocsUriWithName.of("Admin", apiDocsUriBuilder.build("/admin")) ); }; } }
[ "andreas.grub@qaware.de" ]
andreas.grub@qaware.de
4f6aa7e1310e4d720120c35847e75f93245d0f2c
5e3235edf3de262f4d10b9e9e1fcc3bd13d6b8b1
/Code Snippet Repository/Spring/Spring4248.java
30eccecb5e6705756b7b0e2a45e0510af0a7d080
[]
no_license
saber13812002/DeepCRM
3336a244d4852a364800af3181e03e868cf6f9f5
be3e5e50e34a042d5ba7259ff5ff75c08ab32bb9
refs/heads/master
2023-03-16T00:08:06.473699
2018-04-18T05:29:50
2018-04-18T05:29:50
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,106
java
public static TypePath fromString(final String typePath) { if (typePath == null || typePath.length() == 0) { return null; } int n = typePath.length(); ByteVector out = new ByteVector(n); out.putByte(0); for (int i = 0; i < n;) { char c = typePath.charAt(i++); if (c == '[') { out.put11(ARRAY_ELEMENT, 0); } else if (c == '.') { out.put11(INNER_TYPE, 0); } else if (c == '*') { out.put11(WILDCARD_BOUND, 0); } else if (c >= '0' && c <= '9') { int typeArg = c - '0'; while (i < n && (c = typePath.charAt(i)) >= '0' && c <= '9') { typeArg = typeArg * 10 + c - '0'; i += 1; } if (i < n && typePath.charAt(i) == ';') { i += 1; } out.put11(TYPE_ARGUMENT, typeArg); } } out.data[0] = (byte) (out.length / 2); return new TypePath(out.data, 0); }
[ "Qing.Mi@my.cityu.edu.hk" ]
Qing.Mi@my.cityu.edu.hk
51a26f0a0a8d0f95fcff4865e1ec7005bbd22a3e
3ec181de57f014603bb36b8d667a8223875f5ee8
/jcommon/docean-plugin/docean-plugin-akka/src/main/java/com/xiaomi/mone/docean/plugin/akka/AkkaPlugin.java
dac7615601add149d59c62a3d54434f10db6c354
[ "Apache-2.0" ]
permissive
XiaoMi/mone
41af3b636ecabd7134b53a54c782ed59cec09b9e
576cea4e6cb54e5bb7c37328f1cb452cda32f953
refs/heads/master
2023-08-31T08:47:40.632419
2023-08-31T08:09:35
2023-08-31T08:09:35
331,844,632
1,148
152
Apache-2.0
2023-09-14T07:33:13
2021-01-22T05:20:18
Java
UTF-8
Java
false
false
2,657
java
/* * Copyright 2020 Xiaomi * * 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.xiaomi.mone.docean.plugin.akka; import akka.actor.*; import akka.routing.RoundRobinPool; import akka.util.Timeout; import com.google.common.base.Joiner; import com.xiaomi.youpin.docean.Ioc; import com.xiaomi.youpin.docean.anno.DOceanPlugin; import com.xiaomi.youpin.docean.plugin.IPlugin; import lombok.Getter; import lombok.extern.slf4j.Slf4j; import java.util.Set; import java.util.concurrent.TimeUnit; import java.util.stream.Collectors; import java.util.stream.IntStream; /** * @Author goodjava@qq.com * @Date 2021/1/24 20:31 */ @DOceanPlugin @Slf4j public class AkkaPlugin implements IPlugin { @Getter private ActorSystem system; @Override public void init(Set<? extends Class<?>> classSet, Ioc ioc) { log.info("init akka plugin"); system = ActorSystem.create("akkaSystem"); ioc.putBean(system); } public void createActor(String name, int num, AbstractActor.Receive receive) { log.info("create actor:{} {}", name, num); IntStream.range(0, num).mapToObj(i -> { ActorRef actor = system.actorOf(Props.create(DoceanActor.class, () -> new DoceanActor(receive)), Joiner.on("_").join(name, i)); return actor; }).collect(Collectors.toList()); } public void stopActor(String path, ActorContext context) { context.stop(system.actorSelection(path) .resolveOne(Timeout.apply(1, TimeUnit.SECONDS)).value().get().get()); } public ActorRef createRoundRobinPool(ActorContext context, int num, String dispatcherName, String name, Class clazz, Object... parms) { ActorRef actor = context.actorOf(new RoundRobinPool(num) .props(Props.create(clazz, parms)) .withDispatcher(dispatcherName), name); log.info("createRoundRobinPool num:{} name:{} path:{}", num, name, actor.path()); return actor; } public static String getName(Object... params) { return Joiner.on(":").join(params); } }
[ "shanwenbang@xiaomi.com" ]
shanwenbang@xiaomi.com
b062a0547c3f89f97dcac44eb41d83eeb492382f
4cc907d7d927cdf3ab3cb984c5117a15e9ac6a99
/micor-service-provider-dept-8003/src/main/java/lcxy/springcloud/micorserviceproviderdept8003/provider/DeptProvider.java
319afe19c9ec9f1537cee181894ee62e9cfb5596
[]
no_license
AthyLau/SpringCloud-Dept-ParentDemo
bf6f8b6259db9ca4a2105892edab7de4bcc624d6
2d7d7b7d522d4f2c485a0886e84951eb7979b25a
refs/heads/master
2020-04-23T01:35:21.373937
2019-03-06T03:08:19
2019-03-06T03:08:19
170,817,488
1
0
null
null
null
null
UTF-8
Java
false
false
342
java
package lcxy.springcloud.micorserviceproviderdept8003.provider; import lcxy.springcloud.micorserviceentity.domain.po.DeptPO; /** * Function: * * @author liubing * Date: 2018/12/29 上午11:51 * @since JDK 1.8 */ public class DeptProvider { public static void main(String args[]){ DeptPO dept = new DeptPO(); } }
[ "1015141113@qq.com" ]
1015141113@qq.com
dae943a3d41fd244401a404559cd70f8981fb3fe
42fcf1d879cb75f08225137de5095adfdd63fa21
/src/main/java/org/jooq/packages/AppLnmMcaReports.java
a35807bd245dcbb2ae41441530febd8f94b2d598
[]
no_license
mpsgit/JOOQTest
e10e9c8716f2688c8bf0160407b1244f9e70e8eb
6af2922bddc55f591e94a5a9a6efd1627747d6ad
refs/heads/master
2021-01-10T06:11:40.862153
2016-02-28T09:09:34
2016-02-28T09:09:34
52,711,455
0
0
null
null
null
null
UTF-8
Java
false
false
7,038
java
/** * This class is generated by jOOQ */ package org.jooq.packages; import javax.annotation.Generated; import org.jooq.Configuration; import org.jooq.Field; import org.jooq.Wetrn; import org.jooq.impl.PackageImpl; import org.jooq.packages.app_lnm_mca_reports.GetBilngLineNrData; import org.jooq.packages.app_lnm_mca_reports.GetBilngLineNrUsage; import org.jooq.packages.app_lnm_mca_reports.GetBrchrLineNrData; import org.jooq.packages.app_lnm_mca_reports.GetBrchrLineNrUsage; /** * Convenience access to all stored procedures and functions in APP_LNM_MCA_REPORTS */ @Generated( value = { "http://www.jooq.org", "jOOQ version:3.7.2" }, comments = "This class is generated by jOOQ" ) @SuppressWarnings({ "all", "unchecked", "rawtypes" }) public class AppLnmMcaReports extends PackageImpl { private static final long serialVersionUID = -2004324794; /** * The reference instance of <code>WETRN.APP_LNM_MCA_REPORTS</code> */ public static final AppLnmMcaReports APP_LNM_MCA_REPORTS = new AppLnmMcaReports(); /** * Call <code>WETRN.APP_LNM_MCA_REPORTS.GET_BILNG_LINE_NR_DATA</code> */ public static Object getBilngLineNrData(Configuration configuration, Number pClstrId, Number pLeadMrktId, String pLineNr, Number pRefOffrPerdId) { GetBilngLineNrData f = new GetBilngLineNrData(); f.setPClstrId(pClstrId); f.setPLeadMrktId(pLeadMrktId); f.setPLineNr(pLineNr); f.setPRefOffrPerdId(pRefOffrPerdId); f.execute(configuration); return f.getReturnValue(); } /** * Get <code>WETRN.APP_LNM_MCA_REPORTS.GET_BILNG_LINE_NR_DATA</code> as a field. */ public static Field<Object> getBilngLineNrData(Number pClstrId, Number pLeadMrktId, String pLineNr, Number pRefOffrPerdId) { GetBilngLineNrData f = new GetBilngLineNrData(); f.setPClstrId(pClstrId); f.setPLeadMrktId(pLeadMrktId); f.setPLineNr(pLineNr); f.setPRefOffrPerdId(pRefOffrPerdId); return f.asField(); } /** * Get <code>WETRN.APP_LNM_MCA_REPORTS.GET_BILNG_LINE_NR_DATA</code> as a field. */ public static Field<Object> getBilngLineNrData(Field<? extends Number> pClstrId, Field<? extends Number> pLeadMrktId, Field<String> pLineNr, Field<? extends Number> pRefOffrPerdId) { GetBilngLineNrData f = new GetBilngLineNrData(); f.setPClstrId(pClstrId); f.setPLeadMrktId(pLeadMrktId); f.setPLineNr(pLineNr); f.setPRefOffrPerdId(pRefOffrPerdId); return f.asField(); } /** * Call <code>WETRN.APP_LNM_MCA_REPORTS.GET_BILNG_LINE_NR_USAGE</code> */ public static Object getBilngLineNrUsage(Configuration configuration, Number pClstrId, Number pLeadMrktId, String pLineNr, Number pMinOffrPerdId, Number pMaxOffrPerdId) { GetBilngLineNrUsage f = new GetBilngLineNrUsage(); f.setPClstrId(pClstrId); f.setPLeadMrktId(pLeadMrktId); f.setPLineNr(pLineNr); f.setPMinOffrPerdId(pMinOffrPerdId); f.setPMaxOffrPerdId(pMaxOffrPerdId); f.execute(configuration); return f.getReturnValue(); } /** * Get <code>WETRN.APP_LNM_MCA_REPORTS.GET_BILNG_LINE_NR_USAGE</code> as a field. */ public static Field<Object> getBilngLineNrUsage(Number pClstrId, Number pLeadMrktId, String pLineNr, Number pMinOffrPerdId, Number pMaxOffrPerdId) { GetBilngLineNrUsage f = new GetBilngLineNrUsage(); f.setPClstrId(pClstrId); f.setPLeadMrktId(pLeadMrktId); f.setPLineNr(pLineNr); f.setPMinOffrPerdId(pMinOffrPerdId); f.setPMaxOffrPerdId(pMaxOffrPerdId); return f.asField(); } /** * Get <code>WETRN.APP_LNM_MCA_REPORTS.GET_BILNG_LINE_NR_USAGE</code> as a field. */ public static Field<Object> getBilngLineNrUsage(Field<? extends Number> pClstrId, Field<? extends Number> pLeadMrktId, Field<String> pLineNr, Field<? extends Number> pMinOffrPerdId, Field<? extends Number> pMaxOffrPerdId) { GetBilngLineNrUsage f = new GetBilngLineNrUsage(); f.setPClstrId(pClstrId); f.setPLeadMrktId(pLeadMrktId); f.setPLineNr(pLineNr); f.setPMinOffrPerdId(pMinOffrPerdId); f.setPMaxOffrPerdId(pMaxOffrPerdId); return f.asField(); } /** * Call <code>WETRN.APP_LNM_MCA_REPORTS.GET_BRCHR_LINE_NR_DATA</code> */ public static Object getBrchrLineNrData(Configuration configuration, Number pClstrId, Number pLeadMrktId, String pLineNr, Number pRefOffrPerdId) { GetBrchrLineNrData f = new GetBrchrLineNrData(); f.setPClstrId(pClstrId); f.setPLeadMrktId(pLeadMrktId); f.setPLineNr(pLineNr); f.setPRefOffrPerdId(pRefOffrPerdId); f.execute(configuration); return f.getReturnValue(); } /** * Get <code>WETRN.APP_LNM_MCA_REPORTS.GET_BRCHR_LINE_NR_DATA</code> as a field. */ public static Field<Object> getBrchrLineNrData(Number pClstrId, Number pLeadMrktId, String pLineNr, Number pRefOffrPerdId) { GetBrchrLineNrData f = new GetBrchrLineNrData(); f.setPClstrId(pClstrId); f.setPLeadMrktId(pLeadMrktId); f.setPLineNr(pLineNr); f.setPRefOffrPerdId(pRefOffrPerdId); return f.asField(); } /** * Get <code>WETRN.APP_LNM_MCA_REPORTS.GET_BRCHR_LINE_NR_DATA</code> as a field. */ public static Field<Object> getBrchrLineNrData(Field<? extends Number> pClstrId, Field<? extends Number> pLeadMrktId, Field<String> pLineNr, Field<? extends Number> pRefOffrPerdId) { GetBrchrLineNrData f = new GetBrchrLineNrData(); f.setPClstrId(pClstrId); f.setPLeadMrktId(pLeadMrktId); f.setPLineNr(pLineNr); f.setPRefOffrPerdId(pRefOffrPerdId); return f.asField(); } /** * Call <code>WETRN.APP_LNM_MCA_REPORTS.GET_BRCHR_LINE_NR_USAGE</code> */ public static Object getBrchrLineNrUsage(Configuration configuration, Number pClstrId, Number pLeadMrktId, String pLineNr, Number pMinOffrPerdId, Number pMaxOffrPerdId) { GetBrchrLineNrUsage f = new GetBrchrLineNrUsage(); f.setPClstrId(pClstrId); f.setPLeadMrktId(pLeadMrktId); f.setPLineNr(pLineNr); f.setPMinOffrPerdId(pMinOffrPerdId); f.setPMaxOffrPerdId(pMaxOffrPerdId); f.execute(configuration); return f.getReturnValue(); } /** * Get <code>WETRN.APP_LNM_MCA_REPORTS.GET_BRCHR_LINE_NR_USAGE</code> as a field. */ public static Field<Object> getBrchrLineNrUsage(Number pClstrId, Number pLeadMrktId, String pLineNr, Number pMinOffrPerdId, Number pMaxOffrPerdId) { GetBrchrLineNrUsage f = new GetBrchrLineNrUsage(); f.setPClstrId(pClstrId); f.setPLeadMrktId(pLeadMrktId); f.setPLineNr(pLineNr); f.setPMinOffrPerdId(pMinOffrPerdId); f.setPMaxOffrPerdId(pMaxOffrPerdId); return f.asField(); } /** * Get <code>WETRN.APP_LNM_MCA_REPORTS.GET_BRCHR_LINE_NR_USAGE</code> as a field. */ public static Field<Object> getBrchrLineNrUsage(Field<? extends Number> pClstrId, Field<? extends Number> pLeadMrktId, Field<String> pLineNr, Field<? extends Number> pMinOffrPerdId, Field<? extends Number> pMaxOffrPerdId) { GetBrchrLineNrUsage f = new GetBrchrLineNrUsage(); f.setPClstrId(pClstrId); f.setPLeadMrktId(pLeadMrktId); f.setPLineNr(pLineNr); f.setPMinOffrPerdId(pMinOffrPerdId); f.setPMaxOffrPerdId(pMaxOffrPerdId); return f.asField(); } /** * No further instances allowed */ private AppLnmMcaReports() { super("APP_LNM_MCA_REPORTS", Wetrn.WETRN); } }
[ "krisztian.koller@gmail.com" ]
krisztian.koller@gmail.com
24ea422a25f3351a0346598eae53cc5ba844b0d1
dfc0ef8c3017ebfe80fe8ee657b4f593330d3ef6
/Reversed/framework/com/samsung/android/graphics/spr/document/attribute/SprAttributeStrokeLinecap.java
ab9abc4ecf4387ff3e7708b838ae2d7d79b9125f
[]
no_license
khomsn/SCoverRE
fe079b6006281112ee37b66c5d156bb959e15420
2374565740e4c7bfc653b3f05bd9be519e722e32
refs/heads/master
2020-04-13T15:36:19.925426
2017-06-01T07:31:37
2017-06-01T07:31:37
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,104
java
package com.samsung.android.graphics.spr.document.attribute; import com.samsung.android.graphics.spr.document.SprInputStream; import java.io.DataOutputStream; import java.io.IOException; public class SprAttributeStrokeLinecap extends SprAttributeBase { public static byte STROKE_LINECAP_TYPE_BUTT = (byte) 1; public static byte STROKE_LINECAP_TYPE_NONE = (byte) 0; public static byte STROKE_LINECAP_TYPE_ROUND = (byte) 2; public static byte STROKE_LINECAP_TYPE_SQUARE = (byte) 3; public byte linecap = STROKE_LINECAP_TYPE_BUTT; public SprAttributeStrokeLinecap() { super((byte) 37); } public SprAttributeStrokeLinecap(SprInputStream sprInputStream) throws IOException { super((byte) 37); fromSPR(sprInputStream); } public void fromSPR(SprInputStream sprInputStream) throws IOException { this.linecap = sprInputStream.readByte(); } public int getSPRSize() { return 1; } public void toSPR(DataOutputStream dataOutputStream) throws IOException { dataOutputStream.writeByte(this.linecap); } }
[ "fonix232@gmail.com" ]
fonix232@gmail.com
fa58a1a84e91c0f82f67f76f17996f830400aadc
07bf50b54050cad645f641255f336eef5210aac2
/Sources/er/groupware/calendar/ERGWAttendee.java
ab0fdc5417cee13c9b6cd39f094ed0026c161199
[]
no_license
pascalrobert/ERGroupware
f1341d27d9ad471f89d4177ac278dc14f83575f3
d033f3591dedf32b92ae0c072fb9a169b43eb277
refs/heads/master
2016-09-05T16:58:34.669833
2013-06-29T11:25:55
2013-06-29T11:25:55
2,187,274
1
1
null
null
null
null
UTF-8
Java
false
false
3,754
java
package er.groupware.calendar; import net.fortuna.ical4j.model.Parameter; import net.fortuna.ical4j.model.parameter.Cn; import net.fortuna.ical4j.model.parameter.CuType; import net.fortuna.ical4j.model.parameter.Role; import net.fortuna.ical4j.model.property.Attendee; import er.extensions.eof.ERXKey; import er.groupware.calendar.enums.ERGWAttendeeRole; import er.groupware.calendar.enums.ERGWCUType; import er.groupware.calendar.enums.ERGWParticipantStatus; public class ERGWAttendee extends ERGWCalendarContact { private ERGWParticipantStatus partStat; private boolean rsvp; private ERGWCUType cutype; private String memberOf; // http://tools.ietf.org/html/rfc2445#section-4.2.11 private ERGWCalendarContact delegatedFrom; private ERGWCalendarContact delegatedTo; private boolean rsvpSent; public static final ERXKey<ERGWParticipantStatus> PART_STAT = new ERXKey<ERGWParticipantStatus>("partStat"); public static final ERXKey<Boolean> RSVP = new ERXKey<Boolean>("rsvp"); public static final ERXKey<ERGWCUType> CUTYPE = new ERXKey<ERGWCUType>("cutype"); public static final ERXKey<String> MEMBER_OF = new ERXKey<String>("memberOf"); public static final ERXKey<ERGWCalendarContact> DELEGATED_FROM = new ERXKey<ERGWCalendarContact>("delegatedFrom"); public static final ERXKey<ERGWCalendarContact> DELEGATED_TO = new ERXKey<ERGWCalendarContact>("delegatedTo"); public ERGWAttendee() { } public ERGWParticipantStatus partStat() { return partStat; } public void setPartStat(ERGWParticipantStatus _partStat) { this.partStat = _partStat; } public boolean isRsvp() { return rsvp; } public void setRsvp(boolean _rsvp) { this.rsvp = _rsvp; } public ERGWCUType cutype() { return cutype; } public void setCutype(ERGWCUType _cutype) { this.cutype = _cutype; } public String memberOf() { return memberOf; } public void setMemberOf(String _memberOf) { this.memberOf = _memberOf; } public ERGWCalendarContact delegatedFrom() { return delegatedFrom; } public void setDelegatedFrom(ERGWCalendarContact _delegatedFrom) { this.delegatedFrom = _delegatedFrom; } public ERGWCalendarContact delegatedTo() { return delegatedTo; } public void setDelegatedTo(ERGWCalendarContact _delegatedTo) { this.delegatedTo = _delegatedTo; } public boolean isRsvpSent() { return rsvpSent; } public void setRsvpSent(boolean _rsvpSent) { this.rsvpSent = _rsvpSent; } public static ERGWAttendee transformFromICalObject(Attendee oldAttendee) { ERGWAttendee attendee = new ERGWAttendee(); CuType type = (CuType)oldAttendee.getParameter(Parameter.CUTYPE); if (type == CuType.GROUP) { attendee.setCutype(ERGWCUType.GROUP); } else if (type == CuType.INDIVIDUAL) { attendee.setCutype(ERGWCUType.INDIVIDUAL); } else if (type == CuType.RESOURCE) { attendee.setCutype(ERGWCUType.RESOURCE); } else if (type == CuType.ROOM) { attendee.setCutype(ERGWCUType.ROOM); } else if (type == CuType.UNKNOWN) { attendee.setCutype(ERGWCUType.UNKNOWN); } Parameter role = oldAttendee.getParameter(Parameter.ROLE); if (role != null) { attendee.setRole(ERGWAttendeeRole.getByRFC2445ValueValue((Role)role)); } else { attendee.setRole(ERGWAttendeeRole.REQ_PARTICIPANT); } Cn name = (Cn)oldAttendee.getParameter(Parameter.CN); if (name != null) attendee.setName(name.getValue()); attendee.setEmailAddress(null); String emailAddress = oldAttendee.getCalAddress().getSchemeSpecificPart(); if (emailAddress != null) attendee.setEmailAddress(emailAddress); return attendee; } }
[ "probert@macti.ca" ]
probert@macti.ca
a3c8e3e6bd089fe213ab843afe26123e1bae742c
d1a6d1e511df6db8d8dd0912526e3875c7e1797d
/genny_JavaWithoutLambdas/applicationModule/src/test/java/applicationModulepackageJava16/Foo771Test.java
741d73b04af009e4ad5c30bcd1c9cba2d29b4933
[]
no_license
NikitaKozlov/generated-project-for-desugaring
0bc1443ab3ddc84cd289331c726761585766aea7
81506b3711004185070ca4bb9a93482b70011d36
refs/heads/master
2020-03-20T00:35:06.996525
2018-06-12T09:30:37
2018-06-12T09:30:37
137,049,317
0
0
null
null
null
null
UTF-8
Java
false
false
482
java
package applicationModulepackageJava16; import org.junit.Test; public class Foo771Test { @Test public void testFoo0() { new Foo771().foo0(); } @Test public void testFoo1() { new Foo771().foo1(); } @Test public void testFoo2() { new Foo771().foo2(); } @Test public void testFoo3() { new Foo771().foo3(); } @Test public void testFoo4() { new Foo771().foo4(); } @Test public void testFoo5() { new Foo771().foo5(); } }
[ "nikita.e.kozlov@gmail.com" ]
nikita.e.kozlov@gmail.com
fa1636e0327faaf3aad0b5b4189695dfa5ee0a13
a53940c1db9c0e97603a640cb2cd639b3c1cfd1b
/vertx-platform/src/test/mod-test/mod-proxy-maven-server/Server.java
0252aaba101b85465ec2f248ab08f54ed8c979c9
[ "Apache-2.0" ]
permissive
dallaybatta/vert.x
a9c612e1c9bcbeebbe98d011845651a8600de1e4
7aab7b3e7f081caab15291d250212f38fdb7d3cd
refs/heads/master
2020-04-05T23:39:28.848257
2013-02-19T17:38:41
2013-02-19T17:38:41
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,044
java
import org.vertx.java.core.Handler; import org.vertx.java.core.http.HttpServerRequest; import org.vertx.java.platform.Verticle; import org.vertx.java.testframework.TestUtils; import java.lang.String; import java.lang.System; public class Server extends Verticle { public void start() { final TestUtils tu = new TestUtils(vertx); vertx.createHttpServer().requestHandler(new Handler<HttpServerRequest>() { public void handle(HttpServerRequest req) { // It's being proxied so should be absolute url tu.azzert(req.uri.equals("http://localhost:9192/maven2/io/vertx/mod-maven-test/1.0.0/mod-maven-test-1.0.0.zip")); if (req.path.indexOf("..") != -1) { req.response.statusCode = 403; req.response.end(); } else { //Clearly in a real server you would check the path for better security!! req.response.sendFile("." + req.path); } } }).listen(9193, "127.0.0.1"); System.out.println("repo proxy server listening on 127.0.0.1:91923"); } }
[ "timvolpe@gmail.com" ]
timvolpe@gmail.com
a71fc44d703dd92d4cd9333dfb51ebb59f264156
ddfb3a710952bf5260dfecaaea7d515526f92ebb
/build/tmp/expandedArchives/forge-1.15.2-31.2.0_mapped_snapshot_20200514-1.15.1-sources.jar_c582e790131b6dd3325b282fce9d2d3d/net/minecraftforge/client/event/GuiOpenEvent.java
691ba8b8ac943626aacd8f6442ca402f0add082f
[ "Apache-2.0" ]
permissive
TheDarkRob/Sgeorsge
88e7e39571127ff3b14125620a6594beba509bd9
307a675cd3af5905504e34717e4f853b2943ba7b
refs/heads/master
2022-11-25T06:26:50.730098
2020-08-03T15:42:23
2020-08-03T15:42:23
284,748,579
0
0
Apache-2.0
2020-08-03T16:19:36
2020-08-03T16:19:35
null
UTF-8
Java
false
false
1,503
java
/* * Minecraft Forge * Copyright (c) 2016-2019. * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation version 2.1 * of the License. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser 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 */ package net.minecraftforge.client.event; import net.minecraftforge.eventbus.api.Cancelable; import net.minecraftforge.eventbus.api.Event; import net.minecraft.client.gui.screen.Screen; /** * This event is called before any Gui will open. * If you don't want this to happen, cancel the event. * If you want to override this Gui, simply set the gui variable to your own Gui. * * @author jk-5 */ @net.minecraftforge.eventbus.api.Cancelable public class GuiOpenEvent extends net.minecraftforge.eventbus.api.Event { private Screen gui; public GuiOpenEvent(Screen gui) { this.setGui(gui); } public Screen getGui() { return gui; } public void setGui(Screen gui) { this.gui = gui; } }
[ "iodiceandrea251@gmail.com" ]
iodiceandrea251@gmail.com
dccb5d738212af0b8e59c8be47f2986b0315ab0f
ee5f1b8175c96ec6148eca059da2d7e524b90763
/java/src/main/java/com/wkodate/atcoder/abc005/a/Main.java
298dcc98d045508bf7d53a3882055ccdcee28362
[]
no_license
wkodate/atcoder
15e6e3aedcfa8ae0faf9534be87707cdb407faa5
c10c421858b4169735ca4c50f6b7bc43ac0464b3
refs/heads/master
2022-04-26T20:53:54.737536
2022-04-04T13:17:21
2022-04-04T13:17:32
241,840,372
0
0
null
null
null
null
UTF-8
Java
false
false
281
java
package com.wkodate.atcoder.abc005.a; import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int x = sc.nextInt(); int y = sc.nextInt(); System.out.println(y / x); } }
[ "hbwandeow@gmail.com" ]
hbwandeow@gmail.com
613a872e5516194dc8194ffba2500e28806de4dd
fa1408365e2e3f372aa61e7d1e5ea5afcd652199
/src/testcases/CWE129_Improper_Validation_of_Array_Index/s03/CWE129_Improper_Validation_of_Array_Index__getQueryString_Servlet_array_write_no_check_74b.java
4767cea4fb034fad8b994ec516673befd32e4da1
[]
no_license
bqcuong/Juliet-Test-Case
31e9c89c27bf54a07b7ba547eddd029287b2e191
e770f1c3969be76fdba5d7760e036f9ba060957d
refs/heads/master
2020-07-17T14:51:49.610703
2019-09-03T16:22:58
2019-09-03T16:22:58
206,039,578
1
2
null
null
null
null
UTF-8
Java
false
false
3,029
java
/* TEMPLATE GENERATED TESTCASE FILE Filename: CWE129_Improper_Validation_of_Array_Index__getQueryString_Servlet_array_write_no_check_74b.java Label Definition File: CWE129_Improper_Validation_of_Array_Index.label.xml Template File: sources-sinks-74b.tmpl.java */ /* * @description * CWE: 129 Improper Validation of Array Index * BadSource: getQueryString_Servlet Parse id param out of the URL query string (without using getParameter()) * GoodSource: A hardcoded non-zero, non-min, non-max, even number * Sinks: array_write_no_check * GoodSink: Write to array after verifying index * BadSink : Write to array without any verification of index * Flow Variant: 74 Data flow: data passed in a HashMap from one method to another in different source files in the same package * * */ package testcases.CWE129_Improper_Validation_of_Array_Index.s03; import testcasesupport.*; import java.util.HashMap; import javax.servlet.http.*; public class CWE129_Improper_Validation_of_Array_Index__getQueryString_Servlet_array_write_no_check_74b { public void badSink(HashMap<Integer,Integer> dataHashMap , HttpServletRequest request, HttpServletResponse response) throws Throwable { int data = dataHashMap.get(2); /* Need to ensure that the array is of size > 3 and < 101 due to the GoodSource and the large_fixed BadSource */ int array[] = { 0, 1, 2, 3, 4 }; /* POTENTIAL FLAW: Attempt to write to array at location data, which may be outside the array bounds */ array[data] = 42; /* Skip reading back data from array since that may be another out of bounds operation */ } /* goodG2B() - use GoodSource and BadSink */ public void goodG2BSink(HashMap<Integer,Integer> dataHashMap , HttpServletRequest request, HttpServletResponse response) throws Throwable { int data = dataHashMap.get(2); /* Need to ensure that the array is of size > 3 and < 101 due to the GoodSource and the large_fixed BadSource */ int array[] = { 0, 1, 2, 3, 4 }; /* POTENTIAL FLAW: Attempt to write to array at location data, which may be outside the array bounds */ array[data] = 42; /* Skip reading back data from array since that may be another out of bounds operation */ } /* goodB2G() - use BadSource and GoodSink */ public void goodB2GSink(HashMap<Integer,Integer> dataHashMap , HttpServletRequest request, HttpServletResponse response) throws Throwable { int data = dataHashMap.get(2); /* Need to ensure that the array is of size > 3 and < 101 due to the GoodSource and the large_fixed BadSource */ int array[] = { 0, 1, 2, 3, 4 }; /* FIX: Verify index before writing to array at location data */ if (data >= 0 && data < array.length) { array[data] = 42; } else { IO.writeLine("Array index out of bounds"); } } }
[ "bqcuong2212@gmail.com" ]
bqcuong2212@gmail.com
6a0ec4201e57f43e31812bccc8186fbc55b34713
647ec12ce50f06e7380fdbfb5b71e9e2d1ac03b4
/com.tencent.mm/classes.jar/com/tencent/mm/plugin/appbrand/report/model/c.java
c31874a5922d2e3833178864cfe82342eaf165d3
[]
no_license
tsuzcx/qq_apk
0d5e792c3c7351ab781957bac465c55c505caf61
afe46ef5640d0ba6850cdefd3c11badbd725a3f6
refs/heads/main
2022-07-02T10:32:11.651957
2022-02-01T12:41:38
2022-02-01T12:41:38
453,860,108
36
9
null
2022-01-31T09:46:26
2022-01-31T02:43:22
Java
UTF-8
Java
false
false
3,964
java
package com.tencent.mm.plugin.appbrand.report.model; import com.tencent.matrix.trace.core.AppMethodBeat; import com.tencent.mm.plugin.appbrand.AppBrandRuntime; import com.tencent.mm.plugin.appbrand.report.x; import com.tencent.mm.plugin.appbrand.report.x.a; import com.tencent.mm.plugin.appbrand.report.x.c; import com.tencent.mm.plugin.appbrand.report.x.d; import com.tencent.mm.sdk.platformtools.Log; import com.tencent.mm.sdk.platformtools.Util; import java.util.LinkedList; import java.util.concurrent.atomic.AtomicInteger; public class c { public volatile String mAppId; public volatile AppBrandRuntime qwG; protected final x tPf; public volatile String tPg; public volatile long tPh; public volatile long tPi; private final LinkedList<Runnable> tPj; public c(int paramInt) { AppMethodBeat.i(139925); this.tPh = 0L; this.tPi = 0L; this.tPj = new LinkedList(); this.tPf = new x("MicroMsg.AppBrandPageViewStatistics[" + paramInt + "]"); AppMethodBeat.o(139925); } public final long cII() { AppMethodBeat.i(139926); long l = Math.max(0L, this.tPi); AppMethodBeat.o(139926); return l; } public final long cIJ() { AppMethodBeat.i(139927); if (1 == this.tPf.tOG.get()) { i = 1; if (i != 0) { break label69; } i = this.tPf.tOG.get(); if ((-1 != i) && (2 != i)) { break label64; } } label64: for (int i = 1;; i = 0) { if (i != 0) { break label69; } AppMethodBeat.o(139927); return 0L; i = 0; break; } label69: long l2 = this.tPf.tOL; long l1 = this.tPh; long l3 = this.tPi; if (l2 <= 0L) { if (isLoading()) { AppMethodBeat.o(139927); return 0L; } if ((this.qwG != null) && (this.qwG.ccV)) {} for (boolean bool = true;; bool = false) { Log.i("MicroMsg.AppBrandPageViewStatistics", "foregroundMs invalid(%d), loadStart %d, loadCost %d, [%s/%s], runtimeIsFinishing=%b", new Object[] { Long.valueOf(l2), Long.valueOf(l1), Long.valueOf(l3), this.mAppId, this.tPg, Boolean.valueOf(bool) }); if ((l1 <= 0L) || (l3 <= 0L) || (l2 != 0L)) { break; } l2 = Util.nowMilliSecond(); AppMethodBeat.o(139927); return l2 - l1; } } l1 = Math.max(0L, l2); AppMethodBeat.o(139927); return l1; } public final boolean isLoading() { return (this.tPh > 0L) && (this.tPi <= 0L); } public final void onBackground() { AppMethodBeat.i(321477); if (this.tPf.cIE()) { while (!this.tPj.isEmpty()) { ((Runnable)this.tPj.pollFirst()).run(); } } AppMethodBeat.o(321477); } public final void onDestroy() { AppMethodBeat.i(321483); this.tPf.cIE(); x localx = this.tPf; localx.tOG.set(-1); localx.tOH = new x.d(localx, (byte)0); AppMethodBeat.o(321483); } public final void onForeground() { AppMethodBeat.i(321481); if (this.tPh <= 0L) { AppMethodBeat.o(321481); return; } x localx = this.tPf; if (localx.tOG.getAndSet(1) != 1) {} for (boolean bool = true;; bool = false) { Log.d("Luggage.StayingRecorder", "%s toForeground, changed:%b", new Object[] { localx.mName, Boolean.valueOf(bool) }); if (bool) { localx.tOH.exit(); x.c localc = localx.tOI; localx.tOH = localc; localc.enter(); } if (bool) { this.tPj.clear(); } AppMethodBeat.o(321481); return; } } } /* Location: L:\local\mybackup\temp\qq_apk\com.tencent.mm\classes8.jar * Qualified Name: com.tencent.mm.plugin.appbrand.report.model.c * JD-Core Version: 0.7.0.1 */
[ "98632993+tsuzcx@users.noreply.github.com" ]
98632993+tsuzcx@users.noreply.github.com
750254f6d97c9584eb6583fee54d94696e1ee98c
ebdcaff90c72bf9bb7871574b25602ec22e45c35
/modules/adwords_appengine/src/main/java/com/google/api/ads/adwords/jaxws/v201806/mcm/CustomerServiceInterfacegetServiceLinksResponse.java
36696604569c81a56f193e0dc25071cb044759fd
[ "Apache-2.0" ]
permissive
ColleenKeegan/googleads-java-lib
3c25ea93740b3abceb52bb0534aff66388d8abd1
3d38daadf66e5d9c3db220559f099fd5c5b19e70
refs/heads/master
2023-04-06T16:16:51.690975
2018-11-15T20:50:26
2018-11-15T20:50:26
158,986,306
1
0
Apache-2.0
2023-04-04T01:42:56
2018-11-25T00:56:39
Java
UTF-8
Java
false
false
2,574
java
// Copyright 2018 Google LLC // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package com.google.api.ads.adwords.jaxws.v201806.mcm; 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; /** * <p>Java class for getServiceLinksResponse element declaration. * * <p>The following schema fragment specifies the expected content contained within this class. * * <pre> * &lt;element name="getServiceLinksResponse"> * &lt;complexType> * &lt;complexContent> * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> * &lt;sequence> * &lt;element name="rval" type="{https://adwords.google.com/api/adwords/mcm/v201806}ServiceLink" maxOccurs="unbounded" minOccurs="0"/> * &lt;/sequence> * &lt;/restriction> * &lt;/complexContent> * &lt;/complexType> * &lt;/element> * </pre> * * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "", propOrder = { "rval" }) @XmlRootElement(name = "getServiceLinksResponse") public class CustomerServiceInterfacegetServiceLinksResponse { protected List<ServiceLink> rval; /** * Gets the value of the rval 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 rval property. * * <p> * For example, to add a new item, do as follows: * <pre> * getRval().add(newItem); * </pre> * * * <p> * Objects of the following type(s) are allowed in the list * {@link ServiceLink } * * */ public List<ServiceLink> getRval() { if (rval == null) { rval = new ArrayList<ServiceLink>(); } return this.rval; } }
[ "jradcliff@users.noreply.github.com" ]
jradcliff@users.noreply.github.com
bd2346b348bb483ee791769b263e3648781f1ba6
6baf1fe00541560788e78de5244ae17a7a2b375a
/hollywood/com.oculus.horizon-Horizon/sources/com/oculus/horizon/service_media/AbuseCaptureProviderMethodAutoProvider.java
36df3f0a05335a4cfb0ee35ef3798fe1f21eff31
[]
no_license
phwd/quest-tracker
286e605644fc05f00f4904e51f73d77444a78003
3d46fbb467ba11bee5827f7cae7dfeabeb1fd2ba
refs/heads/main
2023-03-29T20:33:10.959529
2021-04-10T22:14:11
2021-04-10T22:14:11
357,185,040
4
2
null
2021-04-12T12:28:09
2021-04-12T12:28:08
null
UTF-8
Java
false
false
448
java
package com.oculus.horizon.service_media; import X.AnonymousClass0J3; import X.AnonymousClass117; import com.facebook.annotations.Generated; import com.oculus.horizon.abuse_prevention.interfaces.AbuseCaptureProvider; @Generated({"By: InjectorProcessor"}) public class AbuseCaptureProviderMethodAutoProvider extends AnonymousClass0J3<AbuseCaptureProvider> { public final Object get() { return AnonymousClass117.A00(525, this); } }
[ "cyuubiapps@gmail.com" ]
cyuubiapps@gmail.com
da0aecda9620178f4505274bcb0adb1ccfe6dca6
0ac05e3da06d78292fdfb64141ead86ff6ca038f
/OSWE/oswe/openCRX/rtjar/rt.jar.src/com/sun/corba/se/spi/activation/LocatorOperations.java
309ec283bdb5dbbc6e8612ba6f9606b423b3c50b
[]
no_license
qoo7972365/timmy
31581cdcbb8858ac19a8bb7b773441a68b6c390a
2fc8baba4f53d38dfe9c2b3afd89dcf87cbef578
refs/heads/master
2023-07-26T12:26:35.266587
2023-07-17T12:35:19
2023-07-17T12:35:19
353,889,195
7
1
null
null
null
null
UTF-8
Java
false
false
873
java
package com.sun.corba.se.spi.activation; import com.sun.corba.se.spi.activation.LocatorPackage.ServerLocation; import com.sun.corba.se.spi.activation.LocatorPackage.ServerLocationPerORB; public interface LocatorOperations { ServerLocation locateServer(int paramInt, String paramString) throws NoSuchEndPoint, ServerNotRegistered, ServerHeldDown; ServerLocationPerORB locateServerForORB(int paramInt, String paramString) throws InvalidORBid, ServerNotRegistered, ServerHeldDown; int getEndpoint(String paramString) throws NoSuchEndPoint; int getServerPortForType(ServerLocationPerORB paramServerLocationPerORB, String paramString) throws NoSuchEndPoint; } /* Location: /Users/timmy/timmy/OSWE/oswe/openCRX/rt.jar!/com/sun/corba/se/spi/activation/LocatorOperations.class * Java compiler version: 8 (52.0) * JD-Core Version: 1.1.3 */
[ "t0984456716" ]
t0984456716
7ac2066698ae45628e73cf9f6d0b5b4a1ccc1e4b
adbae4c05380070251129494608b9fb73bbd949c
/src/com/practies/RedbusTest.java
dd5bdb0695d6b96c635efe56e651759659975362
[]
no_license
Seleniumvasu9pm/vasu
862b001ab52ea79d037d70dd84fe8e784575a42d
4e734ace9f2c2f74741a8b3f0313e89b46b64e8a
refs/heads/master
2020-03-18T10:00:18.159150
2018-05-23T15:41:28
2018-05-23T15:41:28
null
0
0
null
null
null
null
UTF-8
Java
false
false
681
java
package com.practies; import java.util.List; import org.openqa.selenium.By; import org.openqa.selenium.WebElement; import org.openqa.selenium.firefox.FirefoxDriver; public class RedbusTest { public static void main(String[] args) throws Exception { FirefoxDriver driver=new FirefoxDriver(); driver.get("Http://Redbus.in"); driver.manage().window().maximize(); driver.findElement(By.xpath(".//*[@id='src']")).sendKeys("H"); Thread.sleep(2000); List<WebElement> city=driver.findElements(By.xpath(".//*[@id='search']/div/div[1]/div/ul/li")); System.out.println(city.size()); for(WebElement element:city) { System.out.println(element.getText()); } } }
[ "vasu.584@gmail.com" ]
vasu.584@gmail.com
f4f995c0267c3a1c3d40bcf5130af28fa2a53a96
ea03c0eff8dbdceaab3fc1c3c9e843fadf3018a2
/modules/jaxws/src/org/apache/axis2/jaxws/message/util/StackableReader.java
8b198d9c53faabb30e7907c917a9137ce5619e86
[ "Apache-2.0" ]
permissive
cranelab/axis1_3
28544dbcf3bf0c9bf59a59441ad8ef21143f70f0
1754374507dee9d1502478c454abc1d13bcf15b9
refs/heads/master
2022-12-28T05:17:18.894411
2020-04-22T17:50:05
2020-04-22T17:50:05
257,970,632
0
0
Apache-2.0
2020-10-13T21:25:37
2020-04-22T17:21:46
Java
UTF-8
Java
false
false
7,528
java
/* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations * under the License. */ package org.apache.axis2.jaxws.message.util; import javax.xml.namespace.NamespaceContext; import javax.xml.namespace.QName; import javax.xml.stream.Location; import javax.xml.stream.XMLStreamException; import javax.xml.stream.XMLStreamReader; import java.util.Stack; /** * StackableReader A StackableStreamReader provides an additional method push(XMLStreamReader) * <p/> * You can call push(...) to add a new XMLStreamReader. The next event will use the pushed stream * reader. After the XMLStreamReader is consumed, it is automatically popped off of the stack. * <p/> * Note the information returned by the StackableReader is only applicable for the topmost * XMLStreamReader. For example the NamespaceContext that is returned is not a combination of all * the namespace contexts on the stack. */ public class StackableReader implements XMLStreamReader { Stack<XMLStreamReader> stack = new Stack<XMLStreamReader>(); XMLStreamReader current = null; /** * Create a stackable reader with the initial reader * * @param first */ public StackableReader(XMLStreamReader first) { current = first; } /** * Push a new StreamReader * * @param streamReader */ public void push(XMLStreamReader streamReader) throws XMLStreamException { // Push the current reader if it is not consumed if (current != null && current.hasNext()) { stack.push(current); } current = streamReader; } public void close() throws XMLStreamException { current.close(); } public int getAttributeCount() { return current.getAttributeCount(); } public String getAttributeLocalName(int arg0) { return current.getAttributeLocalName(arg0); } public QName getAttributeName(int arg0) { return current.getAttributeName(arg0); } public String getAttributeNamespace(int arg0) { return current.getAttributeNamespace(arg0); } public String getAttributePrefix(int arg0) { return current.getAttributePrefix(arg0); } public String getAttributeType(int arg0) { return current.getAttributeType(arg0); } public String getAttributeValue(int arg0) { return current.getAttributeValue(arg0); } public String getAttributeValue(String arg0, String arg1) { return current.getAttributeValue(arg0, arg1); } public String getCharacterEncodingScheme() { return current.getCharacterEncodingScheme(); } public String getElementText() throws XMLStreamException { return current.getElementText(); } public String getEncoding() { return current.getEncoding(); } public int getEventType() { return current.getEventType(); } public String getLocalName() { return current.getLocalName(); } public Location getLocation() { return current.getLocation(); } public QName getName() { return current.getName(); } public NamespaceContext getNamespaceContext() { return current.getNamespaceContext(); } public int getNamespaceCount() { return current.getNamespaceCount(); } public String getNamespacePrefix(int arg0) { return current.getNamespacePrefix(arg0); } public String getNamespaceURI() { return current.getNamespaceURI(); } public String getNamespaceURI(int arg0) { return current.getNamespaceURI(arg0); } public String getNamespaceURI(String arg0) { return current.getNamespaceURI(arg0); } public String getPIData() { return current.getPIData(); } public String getPITarget() { return current.getPITarget(); } public String getPrefix() { return current.getPrefix(); } public Object getProperty(String arg0) throws IllegalArgumentException { return current.getProperty(arg0); } public String getText() { return current.getText(); } public char[] getTextCharacters() { return current.getTextCharacters(); } public int getTextCharacters(int arg0, char[] arg1, int arg2, int arg3) throws XMLStreamException { return current.getTextCharacters(arg0, arg1, arg2, arg3); } public int getTextLength() { return current.getTextLength(); } public int getTextStart() { return current.getTextStart(); } public String getVersion() { return current.getVersion(); } public boolean hasName() { return current.hasName(); } public boolean hasNext() throws XMLStreamException { // This code assumes that the stack only contains readers that are not consumed if (!current.hasNext() && !stack.isEmpty()) { return stack.peek().hasNext(); } return current.hasNext(); } public boolean hasText() { return current.hasText(); } public boolean isAttributeSpecified(int arg0) { return current.isAttributeSpecified(arg0); } public boolean isCharacters() { return current.isCharacters(); } public boolean isEndElement() { return current.isEndElement(); } public boolean isStandalone() { return current.isStandalone(); } public boolean isStartElement() { return current.isStartElement(); } public boolean isWhiteSpace() { return current.isWhiteSpace(); } public int next() throws XMLStreamException { // Only next is allowed to pop the stack if (!current.hasNext() && !stack.isEmpty()) { current = stack.pop(); } // The assumption is that the event on the stream reader was processed // prior to pushing a new xmlstreamreader. thus we proceed to the next // event in all cases int tag = current.next(); // Skip start document and end document events for // stacked stream readers if ((tag == this.START_DOCUMENT || tag == this.END_DOCUMENT) && !stack.isEmpty()) { tag = next(); } return tag; } public int nextTag() throws XMLStreamException { if (!current.hasNext() && !stack.isEmpty()) { return stack.peek().nextTag(); } return current.nextTag(); } public void require(int arg0, String arg1, String arg2) throws XMLStreamException { current.require(arg0, arg1, arg2); } public boolean standaloneSet() { return current.standaloneSet(); } }
[ "45187319+cranelab@users.noreply.github.com" ]
45187319+cranelab@users.noreply.github.com
0dfc5b26fdb3226632cc080bb669280b602566cc
028cbe18b4e5c347f664c592cbc7f56729b74060
/v2/admin-gui/src/java/com/sun/jbi/jsf/framework/model/JBIServiceUnitStatus.java
865fdc22f5a9429f8b5152fd52cb7f29319b4302
[]
no_license
dmatej/Glassfish-SVN-Patched
8d355ff753b23a9a1bd9d7475fa4b2cfd3b40f9e
269e29ba90db6d9c38271f7acd2affcacf2416f1
refs/heads/master
2021-05-28T12:55:06.267463
2014-11-11T04:21:44
2014-11-11T04:21:44
23,610,469
1
0
null
null
null
null
UTF-8
Java
false
false
4,296
java
/* * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. * * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved. * * The contents of this file are subject to the terms of either the GNU * General Public License Version 2 only ("GPL") or the Common Development * and Distribution License("CDDL") (collectively, the "License"). You * may not use this file except in compliance with the License. You can obtain * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html * or glassfish/bootstrap/legal/LICENSE.txt. See the License for the specific * language governing permissions and limitations under the License. * * When distributing the software, include this License Header Notice in each * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt. * Sun designates this particular file as subject to the "Classpath" exception * as provided by Sun in the GPL Version 2 section of the License file that * accompanied this code. If applicable, add the following below the License * Header, with the fields enclosed by brackets [] replaced by your own * identifying information: "Portions Copyrighted [year] * [name of copyright owner]" * * Contributor(s): * * If you wish your version of this file to be governed by only the CDDL or * only the GPL Version 2, indicate your decision by adding "[Contributor] * elects to include this software in this distribution under the [CDDL or GPL * Version 2] license." If you don't indicate a single choice of license, a * recipient has the option to distribute your version of this file under * either the CDDL, the GPL Version 2 or to extend the choice of license to * its licensees as provided above. However, if you add GPL Version 2 code * and therefore, elected the GPL Version 2 license, then the option applies * only if the new code is made subject to such option by the copyright * holder. */ /* * JBIServiceUnitStatus.java * * @author ylee * @author Graj * */ package com.sun.jbi.jsf.framework.model; import java.io.Serializable; import java.util.logging.Logger; public class JBIServiceUnitStatus implements Serializable { private static final String SERVICE_UNIT_NAME = "ServiceUnitName"; private static final String SERVICE_UNIT_DESCRIPTION = "ServiceUnitDescription"; private static final String STATUS_TYPE = "Status"; private static final String TARGET_NAME_TYPE = "TargetName"; protected String serviceUnitName; // 0B000000-DBBABDE9030100-0A12437F-01 protected String serviceUnitDescription; // This represents the Application Sub-Assembly protected String status; // UNKNOWN protected String targetName; // xsltserviceengine-9bfbff60-467d-11d9-9669-0800200c9a67 private Logger logger = Logger.getLogger(JBIServiceUnitStatus.class.getName()); /** * */ public JBIServiceUnitStatus() { super(); // TODO Auto-generated constructor stub } /** * @return Returns the serviceUnitDescription. */ public String getServiceUnitDescription() { return this.serviceUnitDescription; } /** * @param serviceUnitDescription The serviceUnitDescription to set. */ public void setServiceUnitDescription(String serviceUnitDescription) { this.serviceUnitDescription = serviceUnitDescription; } /** * @return Returns the serviceUnitName. */ public String getServiceUnitName() { return this.serviceUnitName; } /** * @param serviceUnitName The serviceUnitName to set. */ public void setServiceUnitName(String serviceUnitName) { this.serviceUnitName = serviceUnitName; } /** * @return Returns the status. */ public String getStatus() { return this.status; } /** * @param status The status to set. */ public void setStatus(String status) { this.status = status; } /** * @return Returns the targetName. */ public String getTargetName() { return this.targetName; } /** * @param targetName The targetName to set. */ public void setTargetName(String targetName) { this.targetName = targetName; } }
[ "kohsuke@6f3ba3e3-413c-0410-a8aa-90bee3ab43b5" ]
kohsuke@6f3ba3e3-413c-0410-a8aa-90bee3ab43b5
0d03ef058efdb194a0da60a211d10f9888b51392
255ff79057c0ff14d0b760fc2d6da1165f1806c8
/02JavaStep02/04Ja-va基础教程-小白的福音资料/day04/day04_作业&预习/day03作业代码/Test3.java
12298f7b8fe34d5d34a4df66c74f43dcb9b48dd5
[]
no_license
wjphappy90/Resource
7f1f817d323db5adae06d26da17dfc09ee5f9d3a
6574c8399f3cdfb6d6b39cd64dc9507e784a2549
refs/heads/master
2022-07-30T03:33:59.869345
2020-08-10T02:31:35
2020-08-10T02:31:35
285,701,650
2
6
null
null
null
null
GB18030
Java
false
false
939
java
public class Test3 { public static void main(String[] args) { Scanner sc = new Scanner(System.in); //创建键盘录入对象 //键盘录入练习:键盘录入三个数据,获取这三个数据中的最小值 System.out.println("请输入第一个整数:"); int x = sc.nextInt(); //将键盘录入的数据存储在x中 System.out.println("请输入第二个整数:"); int y = sc.nextInt(); //将键盘录入的数据存储在y中 System.out.println("请输入第三个整数:"); int z = sc.nextInt(); //将键盘录入的数据存储在y中 //定义临时变量记录住比较出前两个变量中的最小值 //int temp = (x < y) ? x : y; //将比较后的结果与第三个变量中的值比较,比较出三个数中的最小值 //int min = (temp < z) ? temp : z; //用一条三元运算符搞定 int min = ((x < y) ? x : y)<z?((x < y) ? x : y):z; System.out.println("min="+min); } }
[ "981146457@qq.com" ]
981146457@qq.com
c51dd7b401f2ae907513df69c12089f9af4e112f
4913ef8eb5cde6e3b1ee74a27c3f3d54319148d9
/allbinary_src/data/DataJavaLibraryM/src/main/java/org/allbinary/logic/communication/smtp/EmailData.java
8a32de7ac4948c0dd045de4790ea1fb2e03003a2
[ "LicenseRef-scancode-warranty-disclaimer" ]
no_license
AllBinary/AllBinary-Platform
0876cfbe8f0d003b628181551f90df36f6203c6a
92adcd63427fcacbfac9cb4a6b47b92a3c2acaa7
refs/heads/master
2023-08-18T23:24:09.932268
2023-08-15T03:09:32
2023-08-15T03:09:32
1,953,077
16
3
NOASSERTION
2023-07-05T00:52:21
2011-06-25T18:29:09
Java
UTF-8
Java
false
false
951
java
/* * AllBinary Open License Version 1 * Copyright (c) 2011 AllBinary * * By agreeing to this license you and any business entity you represent are * legally bound to the AllBinary Open License Version 1 legal agreement. * * You may obtain the AllBinary Open License Version 1 legal agreement from * AllBinary or the root directory of AllBinary's AllBinary Platform repository. * * Created By: Travis Berthelot * */ package org.allbinary.logic.communication.smtp; public class EmailData { private EmailData() { } public static final String SERVER = "EMAIL_SERVER"; public static final String NAME = "EMAIL_NAME"; public static final String FROM = "EMAIL_FROM"; public static final String TO = "EMAIL_TO"; public static final String CC = "EMAIL_CC"; public static final String BCC = "EMAIL_BCC"; public static final String SUBJECT = "EMAIL_SUBJECT"; public static final String CONTENT = "EMAIL_CONTENT"; }
[ "travisberthelot@hotmail.com" ]
travisberthelot@hotmail.com
e85141136d9e7d1dacafee1235d57f21863af83d
2deb74d5bf569bdbe637846d93fac47c01b278a4
/java/lang/ProcessBuilder.java
debbbf5561f6565e4531951ecd3f9cd54734f44a
[]
no_license
isabella232/android-sdk-sources-for-api-level-11
8aefeff38cbc0bbe7cfbbd04a940f8c4aa319772
d772b816a1e388a5f8022d4bc47adc9016195600
refs/heads/master
2023-03-16T14:08:07.661845
2015-07-03T11:17:32
2015-07-03T11:17:32
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,472
java
/* */ package java.lang; /* */ /* */ import java.io.File; /* */ import java.io.IOException; /* */ import java.util.List; /* */ import java.util.Map; /* */ /* */ public final class ProcessBuilder /* */ { /* */ public ProcessBuilder(String[] command) /* */ { /* 4 */ throw new RuntimeException("Stub!"); } /* 5 */ public ProcessBuilder(List<String> command) { throw new RuntimeException("Stub!"); } /* 6 */ public List<String> command() { throw new RuntimeException("Stub!"); } /* 7 */ public ProcessBuilder command(String[] command) { throw new RuntimeException("Stub!"); } /* 8 */ public ProcessBuilder command(List<String> command) { throw new RuntimeException("Stub!"); } /* 9 */ public File directory() { throw new RuntimeException("Stub!"); } /* 10 */ public ProcessBuilder directory(File directory) { throw new RuntimeException("Stub!"); } /* 11 */ public Map<String, String> environment() { throw new RuntimeException("Stub!"); } /* 12 */ public boolean redirectErrorStream() { throw new RuntimeException("Stub!"); } /* 13 */ public ProcessBuilder redirectErrorStream(boolean redirectErrorStream) { throw new RuntimeException("Stub!"); } /* 14 */ public Process start() throws IOException { throw new RuntimeException("Stub!"); /* */ } /* */ } /* Location: D:\xyh\Android_3.0\android.jar * Qualified Name: java.lang.ProcessBuilder * JD-Core Version: 0.6.0 */
[ "root@ifeegoo.com" ]
root@ifeegoo.com
47b352e2df9e69985a6e2b7cb9d3d367330bcac8
c8655251bb853a032ab7db6a9b41c13241565ff6
/jframe-utils/src/main/java/com/alipay/api/request/AlipayFundAuthOrderUnfreezeRequest.java
d095a7dbddfdad3600e49014b2176163592ddebd
[]
no_license
jacksonrick/JFrame
3b08880d0ad45c9b12e335798fc1764c9b01756b
d9a4a9b17701eb698b957e47fa3f30c6cb8900ac
refs/heads/master
2021-07-22T21:13:22.548188
2017-11-03T06:49:44
2017-11-03T06:49:44
107,761,091
1
0
null
null
null
null
UTF-8
Java
false
false
3,122
java
package com.alipay.api.request; import com.alipay.api.domain.AlipayFundAuthOrderUnfreezeModel; import java.util.Map; import com.alipay.api.AlipayRequest; import com.alipay.api.internal.util.AlipayHashMap; import com.alipay.api.response.AlipayFundAuthOrderUnfreezeResponse; import com.alipay.api.AlipayObject; /** * ALIPAY API: alipay.fund.auth.order.unfreeze request * * @author auto create * @since 1.0, 2017-03-13 11:24:35 */ public class AlipayFundAuthOrderUnfreezeRequest implements AlipayRequest<AlipayFundAuthOrderUnfreezeResponse> { private AlipayHashMap udfParams; // add user-defined text parameters private String apiVersion="1.0"; /** * 预授权资金解冻接口 */ private String bizContent; public void setBizContent(String bizContent) { this.bizContent = bizContent; } public String getBizContent() { return this.bizContent; } private String terminalType; private String terminalInfo; private String prodCode; private String notifyUrl; private String returnUrl; private boolean needEncrypt=false; private AlipayObject bizModel=null; public String getNotifyUrl() { return this.notifyUrl; } public void setNotifyUrl(String notifyUrl) { this.notifyUrl = notifyUrl; } public String getReturnUrl() { return this.returnUrl; } public void setReturnUrl(String returnUrl) { this.returnUrl = returnUrl; } public String getApiVersion() { return this.apiVersion; } public void setApiVersion(String apiVersion) { this.apiVersion = apiVersion; } public void setTerminalType(String terminalType){ this.terminalType=terminalType; } public String getTerminalType(){ return this.terminalType; } public void setTerminalInfo(String terminalInfo){ this.terminalInfo=terminalInfo; } public String getTerminalInfo(){ return this.terminalInfo; } public void setProdCode(String prodCode) { this.prodCode=prodCode; } public String getProdCode() { return this.prodCode; } public String getApiMethodName() { return "alipay.fund.auth.order.unfreeze"; } public Map<String, String> getTextParams() { AlipayHashMap txtParams = new AlipayHashMap(); txtParams.put("biz_content", this.bizContent); if(udfParams != null) { txtParams.putAll(this.udfParams); } return txtParams; } public void putOtherTextParam(String key, String value) { if(this.udfParams == null) { this.udfParams = new AlipayHashMap(); } this.udfParams.put(key, value); } public Class<AlipayFundAuthOrderUnfreezeResponse> getResponseClass() { return AlipayFundAuthOrderUnfreezeResponse.class; } public boolean isNeedEncrypt() { return this.needEncrypt; } public void setNeedEncrypt(boolean needEncrypt) { this.needEncrypt=needEncrypt; } public AlipayObject getBizModel() { return this.bizModel; } public void setBizModel(AlipayObject bizModel) { this.bizModel=bizModel; } }
[ "809573150@qq.com" ]
809573150@qq.com
c4c4136b18708433862ac995901c6e8e138ccb62
1e20d15eeada7453e35b22172872260cfb0f92a9
/ndtp-admin/src/main/java/ndtp/persistence/DataSmartTilingMapper.java
5e36177703affa5ad9f30758ca1416084c2dc618
[]
no_license
Gaia3D/ndtp
006859fa9a9f11a37690f953d52ff7e2e0ce1cb7
6d0e7659128adee99e95ba3cbb5f75249a02ae6a
refs/heads/develop
2021-06-30T00:43:49.376463
2021-05-12T07:14:59
2021-05-12T07:14:59
228,551,107
6
4
null
2020-03-31T08:14:36
2019-12-17T06:44:42
JavaScript
UTF-8
Java
false
false
874
java
package ndtp.persistence; import org.springframework.stereotype.Repository; import ndtp.domain.DataSmartTilingFileInfo; import ndtp.domain.DataSmartTilingFileParseLog; /** * Smart Tiling 데이터 파일 관리 * @author jeongdae * */ @Repository public interface DataSmartTilingMapper { /** * Smart Tiling Data 파일 정보 등록 * @param dataSmartTilingFileInfo * @return */ int insertDataSmartTilingFileInfo(DataSmartTilingFileInfo dataSmartTilingFileInfo); /** * Smart Tiling Data 파일 파싱 정보 등록 * @param dataSmartTilingFileParseLog * @return */ int insertDataSmartTilingFileParseLog(DataSmartTilingFileParseLog dataSmartTilingFileParseLog); /** * Smart Tiling Data 정보 수정 * @param dataSmartTilingFileInfo * @return */ int updateDataSmartTilingFileInfo(DataSmartTilingFileInfo dataSmartTilingFileInfo); }
[ "jdcheon@gaia3d.com" ]
jdcheon@gaia3d.com
70be079f31cfec89913df4db9a594e2358b64dff
ffc345e5c5f19febd0ed98d42be78b1abb832cf4
/sitestats/sitestats-impl/src/test/org/sakaiproject/sitestats/test/mocks/FakeAliasService.java
01fc17b28b8a66f9c04fef4c00976b60ef655b2a
[ "ECL-2.0" ]
permissive
unixcrh/Fudan-Sakai
50c89d41ee447f99d6347b14197ba701f6131a5f
924b4c0b702ada7eba4e0efb8db99cb99ed47dce
refs/heads/master
2020-12-24T17:54:54.747919
2012-04-13T14:53:40
2012-04-13T14:53:40
null
0
0
null
null
null
null
UTF-8
Java
false
false
5,437
java
/** * $URL: https://source.sakaiproject.org/svn/sitestats/tags/sitestats-2.2.2/sitestats-impl/src/test/org/sakaiproject/sitestats/test/mocks/FakeAliasService.java $ * $Id: FakeAliasService.java 72172 2009-09-23 00:48:53Z arwhyte@umich.edu $ * * Copyright (c) 2006-2009 The Sakai Foundation * * Licensed under the Educational Community 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.osedu.org/licenses/ECL-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.sakaiproject.sitestats.test.mocks; import java.util.Collection; import java.util.List; import java.util.Map; import java.util.Set; import java.util.Stack; import org.sakaiproject.alias.api.AliasEdit; import org.sakaiproject.alias.api.AliasService; import org.sakaiproject.entity.api.Entity; import org.sakaiproject.entity.api.HttpAccess; import org.sakaiproject.entity.api.Reference; import org.sakaiproject.entity.api.ResourceProperties; import org.sakaiproject.exception.IdInvalidException; import org.sakaiproject.exception.IdUnusedException; import org.sakaiproject.exception.IdUsedException; import org.sakaiproject.exception.InUseException; import org.sakaiproject.exception.PermissionException; import org.w3c.dom.Document; import org.w3c.dom.Element; public class FakeAliasService implements AliasService { public AliasEdit add(String arg0) throws IdInvalidException, IdUsedException, PermissionException { // TODO Auto-generated method stub return null; } public String aliasReference(String arg0) { // TODO Auto-generated method stub return null; } public boolean allowAdd() { // TODO Auto-generated method stub return false; } public boolean allowEdit(String arg0) { // TODO Auto-generated method stub return false; } public boolean allowRemoveAlias(String arg0) { // TODO Auto-generated method stub return false; } public boolean allowRemoveTargetAliases(String arg0) { // TODO Auto-generated method stub return false; } public boolean allowSetAlias(String arg0, String arg1) { // TODO Auto-generated method stub return false; } public void cancel(AliasEdit arg0) { // TODO Auto-generated method stub } public void commit(AliasEdit arg0) { // TODO Auto-generated method stub } public int countAliases() { // TODO Auto-generated method stub return 0; } public int countSearchAliases(String arg0) { // TODO Auto-generated method stub return 0; } public AliasEdit edit(String arg0) throws IdUnusedException, PermissionException, InUseException { // TODO Auto-generated method stub return null; } public List getAliases(String arg0) { // TODO Auto-generated method stub return null; } public List getAliases(int arg0, int arg1) { // TODO Auto-generated method stub return null; } public List getAliases(String arg0, int arg1, int arg2) { // TODO Auto-generated method stub return null; } public String getTarget(String alias) throws IdUnusedException { final String aliasSuffix = "-alias"; if(alias.endsWith(aliasSuffix)) { return "/site/" + alias.substring(0, alias.indexOf(aliasSuffix)); } return null; } public void remove(AliasEdit arg0) throws PermissionException { // TODO Auto-generated method stub } public void removeAlias(String arg0) throws IdUnusedException, PermissionException, InUseException { // TODO Auto-generated method stub } public void removeTargetAliases(String arg0) throws PermissionException { // TODO Auto-generated method stub } public List searchAliases(String arg0, int arg1, int arg2) { // TODO Auto-generated method stub return null; } public void setAlias(String arg0, String arg1) throws IdUsedException, IdInvalidException, PermissionException { // TODO Auto-generated method stub } public String archive(String arg0, Document arg1, Stack arg2, String arg3, List arg4) { // TODO Auto-generated method stub return null; } public Entity getEntity(Reference arg0) { // TODO Auto-generated method stub return null; } public Collection getEntityAuthzGroups(Reference arg0, String arg1) { // TODO Auto-generated method stub return null; } public String getEntityDescription(Reference arg0) { // TODO Auto-generated method stub return null; } public ResourceProperties getEntityResourceProperties(Reference arg0) { // TODO Auto-generated method stub return null; } public String getEntityUrl(Reference arg0) { // TODO Auto-generated method stub return null; } public HttpAccess getHttpAccess() { // TODO Auto-generated method stub return null; } public String getLabel() { // TODO Auto-generated method stub return null; } public String merge(String arg0, Element arg1, String arg2, String arg3, Map arg4, Map arg5, Set arg6) { // TODO Auto-generated method stub return null; } public boolean parseEntityReference(String arg0, Reference arg1) { // TODO Auto-generated method stub return false; } public boolean willArchiveMerge() { // TODO Auto-generated method stub return false; } }
[ "gaojun@fudan.edu.cn" ]
gaojun@fudan.edu.cn
0d3ac54636b87a62cf8e41ecb75ce6b81244b77e
7e651dc44a5fd2b636003958d7e5a283e1828318
/minecraft/net/minecraft/pathfinding/PathNavigateClimber.java
4efbd032848f2151bca0dfe14917d1973f0dd3b3
[]
no_license
Niklas61/CandyClient
b05a1edc0d360dacc84fed7944bce5dc0a873be4
97e317aaacdcf029b8e87960adab4251861371eb
refs/heads/master
2023-04-24T15:48:59.747252
2021-05-12T16:54:32
2021-05-12T16:54:32
352,600,734
1
0
null
null
null
null
UTF-8
Java
false
false
2,409
java
package net.minecraft.pathfinding; import net.minecraft.entity.Entity; import net.minecraft.entity.EntityLiving; import net.minecraft.util.BlockPos; import net.minecraft.util.MathHelper; import net.minecraft.world.World; public class PathNavigateClimber extends PathNavigateGround { /** Current path navigation target */ private BlockPos targetPosition; public PathNavigateClimber(EntityLiving entityLivingIn, World worldIn) { super(entityLivingIn, worldIn); } /** * Returns path to given BlockPos */ public PathEntity getPathToPos(BlockPos pos) { this.targetPosition = pos; return super.getPathToPos(pos); } /** * Returns the path to the given EntityLiving. Args : entity */ public PathEntity getPathToEntityLiving(Entity entityIn) { this.targetPosition = new BlockPos(entityIn); return super.getPathToEntityLiving(entityIn); } /** * Try to find and set a path to EntityLiving. Returns true if successful. Args : entity, speed */ public boolean tryMoveToEntityLiving(Entity entityIn, double speedIn) { PathEntity pathentity = this.getPathToEntityLiving(entityIn); if (pathentity != null) { return this.setPath(pathentity, speedIn); } else { this.targetPosition = new BlockPos(entityIn); this.speed = speedIn; return true; } } public void onUpdateNavigation() { if (!this.noPath()) { super.onUpdateNavigation(); } else { if (this.targetPosition != null) { double d0 = this.theEntity.width * this.theEntity.width; if (this.theEntity.getDistanceSqToCenter(this.targetPosition) >= d0 && (this.theEntity.posY <= (double)this.targetPosition.getY() || this.theEntity.getDistanceSqToCenter(new BlockPos(this.targetPosition.getX(), MathHelper.floor_double(this.theEntity.posY), this.targetPosition.getZ())) >= d0)) { this.theEntity.getMoveHelper().setMoveTo( this.targetPosition.getX() , this.targetPosition.getY() , this.targetPosition.getZ() , this.speed); } else { this.targetPosition = null; } } } } }
[ "unconfigured@null.spigotmc.org" ]
unconfigured@null.spigotmc.org
394ef42d217a39c57513967d440644bbfa3ad370
20eb62855cb3962c2d36fda4377dfd47d82eb777
/IntroClassJava/dataset/smallest/f2997e14a460c6df0ed10aa9f6e792666e37d5c06a9a81445f14509e4a0113f59f5589ef37774dfea1f7d0ae9bb6c388e6eeb44e745e35f8511bbd4b82709d9a/000/mutations/310/smallest_f2997e14_000.java
54ac9c5076b6da9bd4ad7ead97cdc4b53d47dedb
[]
no_license
ozzydong/CapGen
356746618848065cce4e253e5d3c381baa85044a
0ba0321b6b1191443276021f1997833342f02515
refs/heads/master
2023-03-18T20:12:02.923428
2020-08-21T03:08:28
2020-08-21T03:08:28
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,412
java
package introclassJava; class IntObj { public int value; public IntObj () { } public IntObj (int i) { value = i; } } class FloatObj { public float value; public FloatObj () { } public FloatObj (float i) { value = i; } } class LongObj { public long value; public LongObj () { } public LongObj (long i) { value = i; } } class DoubleObj { public double value; public DoubleObj () { } public DoubleObj (double i) { value = i; } } class CharObj { public char value; public CharObj () { } public CharObj (char i) { value = i; } } public class smallest_f2997e14_000 { public java.util.Scanner scanner; public String output = ""; public static void main (String[]args) throws Exception { smallest_f2997e14_000 mainClass = new smallest_f2997e14_000 (); String output; if (args.length > 0) { mainClass.scanner = new java.util.Scanner (args[0]); } else { mainClass.scanner = new java.util.Scanner (System.in); } mainClass.exec (); System.out.println (mainClass.output); } public void exec () throws Exception { IntObj num1 = new IntObj (), num2 = new IntObj (), num3 = new IntObj (), num4 = new IntObj (); output += (String.format ("Please enter 4 numbers separated by spaces > ")); num1.value = scanner.nextInt (); num2.value = scanner.nextInt (); num3.value = scanner.nextInt (); num4.value = scanner.nextInt (); if (num1.value < num2.value && true && num1.value < num4.value) { output += (String.format ("%d is the smallest\n", num1.value)); } else if (num2.value < num1.value && num2.value < num3.value && num2.value < num4.value) { output += (String.format ("%d is the smallest\n", num2.value)); } else if (num3.value < num1.value && num3.value < num2.value && num3.value < num4.value) { output += (String.format ("%d is the smallest\n", num3.value)); } else if (num4.value < num1.value && num4.value < num2.value && num4.value < num3.value) { output += (String.format ("%d is the smallest\n", num4.value)); } if (true) return;; } }
[ "justinwm@163.com" ]
justinwm@163.com
2165cd46c11ed6ba78f054750c01ca992a40b12d
fb70e6d16baecf886869e14eb439fe334954b39e
/Lezerkardosjdk/java/sun/util/resources/cldr/tg/LocaleNames_tg.java
6a3dc9c57bdbd487d17f36b70fa7871c737beec2
[]
no_license
Savitar97/Prog2
ae5dfc46c8fc61974e4c2ddb59ce9e23ab955d23
8bc2c19240862218b1b06c4b5abe9081747a54c0
refs/heads/master
2020-07-25T00:16:11.948303
2020-02-29T23:49:42
2020-02-29T23:49:42
208,092,693
0
2
null
null
null
null
UTF-8
Java
false
false
3,997
java
/* * Copyright (c) 2012, 2019, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this * particular file as subject to the "Classpath" exception as provided * by Oracle in the LICENSE file that accompanied this code. * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * version 2 for more details (a copy is included in the LICENSE file that * accompanied this code). * * You should have received a copy of the GNU General Public License version * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. * * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA * or visit www.oracle.com if you need additional information or have any * questions. */ /* * COPYRIGHT AND PERMISSION NOTICE * * Copyright (C) 1991-2012 Unicode, Inc. All rights reserved. Distributed under * the Terms of Use in http://www.unicode.org/copyright.html. * * Permission is hereby granted, free of charge, to any person obtaining a copy * of the Unicode data files and any associated documentation (the "Data * Files") or Unicode software and any associated documentation (the * "Software") to deal in the Data Files or Software without restriction, * including without limitation the rights to use, copy, modify, merge, * publish, distribute, and/or sell copies of the Data Files or Software, and * to permit persons to whom the Data Files or Software are furnished to do so, * provided that (a) the above copyright notice(s) and this permission notice * appear with all copies of the Data Files or Software, (b) both the above * copyright notice(s) and this permission notice appear in associated * documentation, and (c) there is clear notice in each modified Data File or * in the Software as well as in the documentation associated with the Data * File(s) or Software that the data or software has been modified. * * THE DATA FILES AND SOFTWARE ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY * KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF * THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS * INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT OR * CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE * OF THE DATA FILES OR SOFTWARE. * * Except as contained in this notice, the name of a copyright holder shall not * be used in advertising or otherwise to promote the sale, use or other * dealings in these Data Files or Software without prior written authorization * of the copyright holder. */ package sun.util.resources.cldr.tg; import sun.util.resources.OpenListResourceBundle; public class LocaleNames_tg extends OpenListResourceBundle { @Override protected final Object[][] getContents() { final Object[][] data = new Object[][] { { "AF", "\u0410\u0444\u0493\u043e\u043d\u0438\u0441\u0442\u0430\u043d" }, { "de", "\u041d\u0435\u043c\u0438\u0441\u04e3" }, { "en", "\u0410\u043d\u0433\u043b\u0438\u0441\u04e3" }, { "fr", "\u0424\u0430\u0440\u043e\u043d\u0441\u0430\u0432\u04e3" }, { "zh", "\u0427\u0438\u043d\u04e3" }, { "Arab", "\u0410\u0440\u0430\u0431\u04e3" }, }; return data; } }
[ "atoth1571@gmail.com" ]
atoth1571@gmail.com
de0ebe85976c83edae9095888af9632f88e49e98
7608dc17c244b32fcb02e22fdb98bc56aa2f89e1
/宠物/src/main/java/com/weeho/petim/hxim/PermissionsResultAction.java
6ca857d86c9fc3e0f259eeeac007120d4cea8f04
[]
no_license
alexlzl/AndroidDemo11
999f56f877ab4b83634c640c7dbc456101199d27
1f2799af9275ef144d34e33ad46507f019cfd437
refs/heads/master
2021-06-24T11:43:56.982231
2017-09-12T16:34:23
2017-09-12T16:34:35
103,295,359
0
0
null
null
null
null
UTF-8
Java
false
false
6,783
java
/** * Copyright 2015 Anthony Restaino 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.weeho.petim.hxim; import android.content.pm.PackageManager; import android.os.Handler; import android.os.Looper; import android.support.annotation.*; import android.util.Log; import java.util.Collections; import java.util.HashSet; import java.util.Set; /** * This abstract class should be used to create an if/else action that the PermissionsManager * can execute when the permissions you request are granted or denied. Simple use involves * creating an anonymous instance of it and passing that instance to the * requestPermissionsIfNecessaryForResult method. The result will be sent back to you as * either onGranted (all permissions have been granted), or onDenied (a required permission * has been denied). Ideally you put your functionality in the onGranted method and notify * the user what won't work in the onDenied method. */ public abstract class PermissionsResultAction { private static final String TAG = PermissionsResultAction.class.getSimpleName(); private final Set<String> mPermissions = new HashSet<String>(1); private Looper mLooper = Looper.getMainLooper(); /** * Default Constructor */ public PermissionsResultAction() {} /** * Alternate Constructor. Pass the looper you wish the PermissionsResultAction * callbacks to be executed on if it is not the current Looper. For instance, * if you are making a permissions request from a background thread but wish the * callback to be on the UI thread, use this constructor to specify the UI Looper. * * @param looper the looper that the callbacks will be called using. */ @SuppressWarnings("unused") public PermissionsResultAction(@NonNull Looper looper) {mLooper = looper;} /** * This method is called when ALL permissions that have been * requested have been granted by the user. In this method * you should put all your permissions sensitive code that can * only be executed with the required permissions. */ public abstract void onGranted(); /** * This method is called when a permission has been denied by * the user. It provides you with the permission that was denied * and will be executed on the Looper you pass to the constructor * of this class, or the Looper that this object was created on. * * @param permission the permission that was denied. */ public abstract void onDenied(String permission); /** * This method is used to determine if a permission not * being present on the current Android platform should * affect whether the PermissionsResultAction should continue * listening for events. By default, it returns true and will * simply ignore the permission that did not exist. Usually this will * work fine since most new permissions are introduced to * restrict what was previously allowed without permission. * If that is not the case for your particular permission you * request, override this method and return false to result in the * Action being denied. * * @param permission the permission that doesn't exist on this * Android version * @return return true if the PermissionsResultAction should * ignore the lack of the permission and proceed with exection * or false if the PermissionsResultAction should treat the * absence of the permission on the API level as a denial. */ @SuppressWarnings({"WeakerAccess", "SameReturnValue"}) public synchronized boolean shouldIgnorePermissionNotFound(String permission) { Log.d(TAG, "Permission not found: " + permission); return true; } @SuppressWarnings("WeakerAccess") @CallSuper protected synchronized final boolean onResult(final @NonNull String permission, int result) { if (result == PackageManager.PERMISSION_GRANTED) { return onResult(permission, Permissions.GRANTED); } else { return onResult(permission, Permissions.DENIED); } } /** * This method is called when a particular permission has changed. * This method will be called for all permissions, so this method determines * if the permission affects the state or not and whether it can proceed with * calling onGranted or if onDenied should be called. * * @param permission the permission that changed. * @param result the result for that permission. * @return this method returns true if its primary action has been completed * and it should be removed from the data structure holding a reference to it. */ @SuppressWarnings("WeakerAccess") @CallSuper protected synchronized final boolean onResult(final @NonNull String permission, Permissions result) { mPermissions.remove(permission); if (result == Permissions.GRANTED) { if (mPermissions.isEmpty()) { new Handler(mLooper).post(new Runnable() { @Override public void run() { onGranted(); } }); return true; } } else if (result == Permissions.DENIED) { new Handler(mLooper).post(new Runnable() { @Override public void run() { onDenied(permission); } }); return true; } else if (result == Permissions.NOT_FOUND) { if (shouldIgnorePermissionNotFound(permission)) { if (mPermissions.isEmpty()) { new Handler(mLooper).post(new Runnable() { @Override public void run() { onGranted(); } }); return true; } } else { new Handler(mLooper).post(new Runnable() { @Override public void run() { onDenied(permission); } }); return true; } } return false; } /** * This method registers the PermissionsResultAction object for the specified permissions * so that it will know which permissions to look for changes to. The PermissionsResultAction * will then know to look out for changes to these permissions. * * @param perms the permissions to listen for */ @SuppressWarnings("WeakerAccess") @CallSuper protected synchronized final void registerPermissions(@NonNull String[] perms) { Collections.addAll(mPermissions, perms); } }
[ "525688067@qq.com" ]
525688067@qq.com
7425a04397823aaed67748de70f1cccc2e502120
21a672c92dcd855b874d34afe8a8e4aab5d8b562
/19-stpl-gtn-portal/ItemMs/stpl-gtn-item-common/src/main/java/com/stpl/gtn/item/domain/event/ItemMsGenericEvent.java
6d8b619ad85de4fb562114f340a54bfe3dbc9cec
[]
no_license
amanver16/ServiceMixDemo
fe445ea7d17ba50509a850942f59d9a986a20703
9da4e08c0b543e62ffe0e99d03eb23d156b4370e
refs/heads/master
2020-03-30T22:52:46.816969
2018-10-05T07:15:45
2018-10-05T07:15:45
151,681,632
0
1
null
null
null
null
UTF-8
Java
false
false
2,056
java
package com.stpl.gtn.item.domain.event; public class ItemMsGenericEvent { public ItemMsGenericEvent() { super(); } private String eventName; private String aggregateId; private String aggregateType; private String raisedTime; private String originCommandRequestId; private String originCommandName; private String originAggregateId; private String originIssuedTime; private String eventData; private String version = "1"; public String getEventName() { return eventName; } public void setEventName(String eventName) { this.eventName = eventName; } public String getAggregateId() { return aggregateId; } public void setAggregateId(String aggregateId) { this.aggregateId = aggregateId; } public String getAggregateType() { return aggregateType; } public void setAggregateType(String aggregateType) { this.aggregateType = aggregateType; } public String getRaisedTime() { return raisedTime; } public void setRaisedTime(String raisedTime) { this.raisedTime = raisedTime; } public String getOriginCommandRequestId() { return originCommandRequestId; } public void setOriginCommandRequestId(String originCommandRequestId) { this.originCommandRequestId = originCommandRequestId; } public String getOriginCommandName() { return originCommandName; } public void setOriginCommandName(String originCommandName) { this.originCommandName = originCommandName; } public String getOriginAggregateId() { return originAggregateId; } public void setOriginAggregateId(String originAggregateId) { this.originAggregateId = originAggregateId; } public String getOriginIssuedTime() { return originIssuedTime; } public void setOriginIssuedTime(String originIssuedTime) { this.originIssuedTime = originIssuedTime; } public String getEventData() { return eventData; } public void setEventData(String eventData) { this.eventData = eventData; } public String getVersion() { return version; } public void setVersion(String version) { this.version = version; } }
[ "aman.verma@sysbiz.org" ]
aman.verma@sysbiz.org
0781e09f0187899b877bde0fc8f3df6f2f416621
1e3a2afac22eb81aafcce41a53dc0a0e4d27b5e2
/MyApplication/app/src/main/java/com/fule/myapplication/group/Group.java
125d251bc44d077c6747268b2e56345e7880156e
[]
no_license
jianyufeng/ChatTestRLY
7d7d36cd4c257a82569c7babd0eb800f38113b1f
9f5c562b6a1b456bf2a45df7002ceeee69a70209
refs/heads/master
2021-07-01T13:19:25.488149
2017-09-22T08:29:22
2017-09-22T08:29:22
104,450,517
0
0
null
null
null
null
UTF-8
Java
false
false
832
java
package com.fule.myapplication.group; /** * Created by Administrator on 2016/11/19. */ public class Group { public int getIcon() { return icon; } public Group() { } public void setIcon(int icon) { this.icon = icon; } private int icon; public String getGroupName() { return groupName; } public void setGroupName(String groupName) { this.groupName = groupName; } public String getGroupIcon() { return groupIcon; } public void setGroupIcon(String groupIcon) { this.groupIcon = groupIcon; } public int getIsMyCreate() { return isMyCreate; } public void setIsMyCreate(int isMyCreate) { this.isMyCreate = isMyCreate; } String groupName; String groupIcon; int isMyCreate; }
[ "907507643@qq.com" ]
907507643@qq.com
e46e08f37f944707d5ca2f9f9c842500f5963a57
75c707019b6c1928b00adabd99aa0d7442317854
/src/main/java/de/blau/android/presets/PresetTextField.java
0c8f384aab04d54e5a012eeec2cf30e509e7a01e
[ "LicenseRef-scancode-unknown-license-reference", "Apache-2.0" ]
permissive
MarcusWolschon/osmeditor4android
d774d41e46dbab82ac33d6128508ccd46506e79a
5170bfaac8e561a70b9d6ac03f412013ab563abc
refs/heads/master
2023-09-01T17:41:09.037801
2023-08-31T09:22:24
2023-08-31T09:22:24
32,623,844
343
109
NOASSERTION
2023-09-13T11:22:03
2015-03-21T07:25:43
Java
UTF-8
Java
false
false
1,891
java
package de.blau.android.presets; import java.io.IOException; import org.xmlpull.v1.XmlSerializer; import androidx.annotation.NonNull; public class PresetTextField extends PresetTagField implements PresetFieldJavaScript { private static final long serialVersionUID = 1L; /** * Script for pre-filling text fields */ String javascript = null; /** * Configured length of the text field */ private int length = 0; /** * Constructor * * @param key key for the PresetTextField */ public PresetTextField(@NonNull String key) { super(key); } /** * Copy constructor * * @param field PresetTextField to copy */ public PresetTextField(PresetTextField field) { super(field); this.javascript = field.javascript; } @Override public String getScript() { return javascript; } @Override public void setScript(String script) { javascript = script; } /** * Get a proposed length for the field * * @return the length in characters */ public int length() { return length; } /** * Set the length attribute * * @param length the length to set in characters */ void setLength(int length) { this.length = length; } @Override public PresetTagField copy() { return new PresetTextField(this); } @Override public void toXml(XmlSerializer s) throws IllegalArgumentException, IllegalStateException, IOException { s.startTag("", PresetParser.TEXT); s.attribute("", PresetParser.KEY_ATTR, key); standardFieldsToXml(s); s.endTag("", PresetParser.TEXT); } @Override public String toString() { return super.toString() + " javascript: " + javascript + " length: " + length; } }
[ "simon@poole.ch" ]
simon@poole.ch
0ed06f514a2f02f5ed349843fc3898979c11c2e4
2f993b28611b3aa9d818f21979a279b9f012065b
/apis/demos/library/library-api/src/main/java/org/example/library/api/BooksResource.java
edb452fea1b4183b44a7b06f044462adeebec983
[]
no_license
EricWittmann/api-samples
4aaefc3c4528c23ea7304bb8dde6519159668e8e
9aa456ba552bd944a8c51a92cf8829ca46381198
refs/heads/master
2022-09-21T05:22:06.821172
2022-09-02T16:05:19
2022-09-02T16:05:19
70,914,823
7
2
null
2021-04-27T11:23:18
2016-10-14T13:53:57
Java
UTF-8
Java
false
false
1,202
java
package org.example.library.api; import java.lang.String; import java.util.List; import javax.ws.rs.Consumes; import javax.ws.rs.DELETE; import javax.ws.rs.GET; import javax.ws.rs.POST; import javax.ws.rs.PUT; import javax.ws.rs.Path; import javax.ws.rs.PathParam; import javax.ws.rs.Produces; import org.example.library.api.beans.Book; /** * A JAX-RS interface. An implementation of this interface must be provided. */ @Path("/books") public interface BooksResource { /** * Gets a list of all `Book` entities. */ @GET @Produces("application/json") List<Book> getbooks(); /** * Creates a new instance of a `Book`. */ @POST @Consumes("application/json") void createBook(Book data); /** * Gets the details of a single instance of a `Book`. */ @Path("/{bookId}") @GET @Produces("application/json") Book getBook(@PathParam("bookId") String bookId); /** * Updates an existing `Book`. */ @Path("/{bookId}") @PUT @Consumes("application/json") void updateBook(@PathParam("bookId") String bookId, Book data); /** * Deletes an existing `Book`. */ @Path("/{bookId}") @DELETE void deleteBook(@PathParam("bookId") String bookId); }
[ "eric.wittmann@gmail.com" ]
eric.wittmann@gmail.com