blob_id
stringlengths
40
40
directory_id
stringlengths
40
40
path
stringlengths
7
390
content_id
stringlengths
40
40
detected_licenses
listlengths
0
35
license_type
stringclasses
2 values
repo_name
stringlengths
6
132
snapshot_id
stringlengths
40
40
revision_id
stringlengths
40
40
branch_name
stringclasses
539 values
visit_date
timestamp[us]date
2016-08-02 21:09:20
2023-09-06 10:10:07
revision_date
timestamp[us]date
1990-01-30 01:55:47
2023-09-05 21:45:37
committer_date
timestamp[us]date
2003-07-12 18:48:29
2023-09-05 21:45:37
github_id
int64
7.28k
684M
star_events_count
int64
0
77.7k
fork_events_count
int64
0
48k
gha_license_id
stringclasses
13 values
gha_event_created_at
timestamp[us]date
2012-06-11 04:05:37
2023-09-14 21:59:18
gha_created_at
timestamp[us]date
2008-05-22 07:58:19
2023-08-28 02:39:21
gha_language
stringclasses
62 values
src_encoding
stringclasses
26 values
language
stringclasses
1 value
is_vendor
bool
1 class
is_generated
bool
2 classes
length_bytes
int64
128
12.8k
extension
stringclasses
11 values
content
stringlengths
128
8.19k
authors
listlengths
1
1
author_id
stringlengths
1
79
961481578fa5b005728d7fbe7434e186cae96103
abb5d27161312d5471283f5b14de5a59b29dbc0d
/myframework/src/main/java/com/gy/myframework/IOC/Core/parase/ClassMemberParase.java
b5df7afbeb92cb3f12eaf283a27fa885dc966df3
[]
no_license
ganyao114/RemoteOfficeShow
71f9568516d19a59e2e4a3dc0f06a24b98cd5552
e8e8c94a9d4717fee5a371b83f0082f079117dc9
refs/heads/master
2021-01-01T05:27:09.417092
2016-05-18T13:39:28
2016-05-18T13:39:28
59,119,005
0
0
null
null
null
null
UTF-8
Java
false
false
4,717
java
package com.gy.myframework.IOC.Core.parase; import com.gy.myframework.IOC.Core.entity.BasicValuePackage; import com.gy.myframework.IOC.Core.entity.BasicValueType; import com.gy.myframework.IOC.Core.entity.ClassMemberPackage; import java.lang.annotation.Annotation; import java.lang.reflect.Field; import java.lang.reflect.Modifier; import java.util.ArrayList; import java.util.List; /** * Created by gy on 2016/1/22. */ public class ClassMemberParase { private static ClassMemberParase parase; private ClassMemberParase(){} public static ClassMemberParase getInstance(){ synchronized (ClassMemberParase.class){ if (parase == null) parase = new ClassMemberParase(); } return parase; } public List<ClassMemberPackage> getFileds(Object object) throws Exception { Class clazz; if (object instanceof Class) clazz = (Class) object; else clazz = object.getClass(); Field[] fields = clazz.getDeclaredFields(); if (fields == null||fields.length == 0) return null; List<ClassMemberPackage> list = new ArrayList<ClassMemberPackage>(); for (Field field:fields){ ClassMemberPackage aPackage = new ClassMemberPackage(); String name = field.getName(); aPackage.setName(name); String modify = Modifier.toString(field.getModifiers()); aPackage.setModify(modify); Annotation[] annotations = field.getAnnotations(); aPackage.setAnnotations(annotations); BasicValueReturn basicValueReturn = getBasicValue(field,object); BasicValueType basicValueType = basicValueReturn.type; if (basicValueType == null){ aPackage.setRefType((Class<?>) field.getGenericType()); if (!(object instanceof Class)) { try { aPackage.setValue(field.get(object)); } catch (IllegalAccessException e) { e.printStackTrace(); } } }else { aPackage.setBasicType(basicValueType); if (!(object instanceof Class)) aPackage.setBasicValue(basicValueReturn.value); } list.add(aPackage); } return list; } private BasicValueReturn getBasicValue(Field field, Object object) throws IllegalAccessException { String type = field.getGenericType().toString(); BasicValueType basicValueType = null; BasicValuePackage valuePackage = new BasicValuePackage(); BasicValueReturn basicValueReturn = new BasicValueReturn(); switch (type){ case "int": basicValueType = BasicValueType.Int; if (!(object instanceof Class)) valuePackage.setInt(field.getInt(object)); break; case "long": basicValueType = BasicValueType.Long; if (!(object instanceof Class)) valuePackage.setLong(field.getLong(object)); break; case "float": basicValueType = BasicValueType.Float; if (!(object instanceof Class)) valuePackage.setFloat(field.getFloat(object)); break; case "byte": basicValueType = BasicValueType.Byte; if (!(object instanceof Class)) valuePackage.setByte(field.getByte(object)); break; case "boolean": basicValueType = BasicValueType.Boolean; if (!(object instanceof Class)) valuePackage.setBoolean(field.getBoolean(object)); break; case "double": basicValueType = BasicValueType.Double; if (!(object instanceof Class)) valuePackage.setDouble(field.getDouble(object)); break; case "char": basicValueType = BasicValueType.Char; if (!(object instanceof Class)) valuePackage.setChar(field.getChar(object)); break; default: break; } basicValueReturn.type = basicValueType; basicValueReturn.value = valuePackage; return basicValueReturn; } class BasicValueReturn{ public BasicValueType type; public BasicValuePackage value; } }
[ "939543405@qq.com" ]
939543405@qq.com
eec9c3072444f87976d0e5237a01ff3f4107f43c
0e7a8943d743a26ff5ede167b97045e9a5dbf646
/MagicalIslands.java
22a028594ab6701f5aa18c851fedb12423759a40
[]
no_license
mooncrater31/Competitive-Programming
dd7657eda25b269ec3873cc78920fb87edbccc41
7cf2c8fc00e24d1575f8b1ebb1136a01d393979a
refs/heads/master
2020-03-31T04:32:20.498065
2020-01-19T09:58:38
2020-01-19T09:58:38
151,909,755
0
0
null
null
null
null
UTF-8
Java
false
false
3,549
java
import java.util.* ; import java.io.BufferedReader ; import java.io.InputStreamReader ; public class MagicalIslands { private static final boolean debug = false ; public static void main(String args[]) throws Exception,InterruptedException,java.io.IOException { Thread t = new Thread(null,null,"TT",10000000) { @Override public void run() { try { BufferedReader bro = new BufferedReader(new InputStreamReader(System.in)) ; String[] S = bro.readLine().split(" ") ; int n = Integer.parseInt(S[0]) ; int m = Integer.parseInt(S[1]) ; List<List<Integer>> L = new ArrayList<List<Integer>>() ; for(int i=0;i<n;i++) { L.add(new ArrayList<Integer>()) ; } for(int i=0;i<m;i++) { S = bro.readLine().split(" ") ; int a = Integer.parseInt(S[0]) ; int b = Integer.parseInt(S[1]) ; L.get(a-1).add(b-1) ; } boolean[] visited = new boolean[n] ; ArrayDeque<Integer> DQ = new ArrayDeque<Integer>() ; for(int i=0;i<n;i++) { if(!visited[i]) dfs1(i,visited,L,DQ) ; } if(debug) System.out.println(DQ.toString()) ; List<List<Integer>> RL = transpose(L) ; System.out.println(dfs2(RL,DQ)) ; } catch(java.io.IOException e) { } catch(StackOverflowError e) { } } }; t.start() ; t.join() ; } static List<List<Integer>> transpose(List<List<Integer>> L) { List<List<Integer>> RL = new ArrayList<List<Integer>>(); for(int i=0;i<L.size();i++) { RL.add(new ArrayList<Integer>()) ; } for(int i=0;i<L.size();i++) { for(int j=0;j<L.get(i).size();j++) RL.get(L.get(i).get(j)).add(i) ; } return RL ; } static void dfs1(int s,boolean[] visited,List<List<Integer>> L,ArrayDeque<Integer> DQ) { visited[s] = true ; for(int i=0;i<L.get(s).size();i++) { int val = L.get(s).get(i) ; if(!visited[val]) { dfs1(val,visited,L,DQ) ; } } if(debug) System.out.println(s+" is pushed into DQ.") ; DQ.push(s) ; } static int dfs2(List<List<Integer>> RL,ArrayDeque<Integer> DQ) { int n = RL.size() ; boolean[] visited = new boolean[n] ; int maxSize = 0 ; while(!DQ.isEmpty()) { int val = DQ.pop() ; if(visited[val]) continue ; else { ArrayDeque<Integer> dq = new ArrayDeque<Integer>() ; dfs1(val,visited,RL,dq) ; maxSize = dq.size()>maxSize?dq.size():maxSize ; } } return maxSize ; } }
[ "mooncraterrocks@gmail.com" ]
mooncraterrocks@gmail.com
bdf8e44fc471d559e2a357cfc03a7a25f6f62686
d6b6abe73a0c82656b04875135b4888c644d2557
/sources/com/nineoldandroids/animation/ValueAnimator.java
4e725015295b27b0bb095e3a0ef2e1cb69a9b56d
[]
no_license
chanyaz/and_unimed
4344d1a8ce8cb13b6880ca86199de674d770304b
fb74c460f8c536c16cca4900da561c78c7035972
refs/heads/master
2020-03-29T09:07:09.224595
2018-08-30T06:29:32
2018-08-30T06:29:32
null
0
0
null
null
null
null
UTF-8
Java
false
false
3,719
java
package com.nineoldandroids.animation; import android.view.animation.AccelerateDecelerateInterpolator; import android.view.animation.Interpolator; import java.util.ArrayList; import java.util.HashMap; public class ValueAnimator extends Animator { private static ThreadLocal<Object> g = new ThreadLocal(); private static final ThreadLocal<ArrayList<ValueAnimator>> h = new ThreadLocal<ArrayList<ValueAnimator>>() { /* renamed from: a */ protected ArrayList<ValueAnimator> initialValue() { return new ArrayList(); } }; private static final ThreadLocal<ArrayList<ValueAnimator>> i = new ThreadLocal<ArrayList<ValueAnimator>>() { /* renamed from: a */ protected ArrayList<ValueAnimator> initialValue() { return new ArrayList(); } }; private static final ThreadLocal<ArrayList<ValueAnimator>> j = new ThreadLocal<ArrayList<ValueAnimator>>() { /* renamed from: a */ protected ArrayList<ValueAnimator> initialValue() { return new ArrayList(); } }; private static final ThreadLocal<ArrayList<ValueAnimator>> k = new ThreadLocal<ArrayList<ValueAnimator>>() { /* renamed from: a */ protected ArrayList<ValueAnimator> initialValue() { return new ArrayList(); } }; private static final ThreadLocal<ArrayList<ValueAnimator>> l = new ThreadLocal<ArrayList<ValueAnimator>>() { /* renamed from: a */ protected ArrayList<ValueAnimator> initialValue() { return new ArrayList(); } }; private static final Interpolator m = new AccelerateDecelerateInterpolator(); private static final TypeEvaluator n = new b(); private static final TypeEvaluator o = new a(); private static long x = 10; private Interpolator A = m; private ArrayList<AnimatorUpdateListener> B = null; long b = -1; int c = 0; boolean d = false; e[] e; HashMap<String, e> f; private boolean p = false; private int q = 0; private float r = 0.0f; private boolean s = false; private boolean t = false; private boolean u = false; private long v = 300; private long w = 0; private int y = 0; private int z = 1; public interface AnimatorUpdateListener { void onAnimationUpdate(ValueAnimator valueAnimator); } /* renamed from: b */ public ValueAnimator clone() { int i = 0; ValueAnimator valueAnimator = (ValueAnimator) super.clone(); if (this.B != null) { ArrayList arrayList = this.B; valueAnimator.B = new ArrayList(); int size = arrayList.size(); for (int i2 = 0; i2 < size; i2++) { valueAnimator.B.add(arrayList.get(i2)); } } valueAnimator.b = -1; valueAnimator.p = false; valueAnimator.q = 0; valueAnimator.d = false; valueAnimator.c = 0; valueAnimator.s = false; e[] eVarArr = this.e; if (eVarArr != null) { int length = eVarArr.length; valueAnimator.e = new e[length]; valueAnimator.f = new HashMap(length); while (i < length) { e a = eVarArr[i].clone(); valueAnimator.e[i] = a; valueAnimator.f.put(a.b(), a); i++; } } return valueAnimator; } public String toString() { String str = "ValueAnimator@" + Integer.toHexString(hashCode()); if (this.e != null) { for (e eVar : this.e) { str = str + "\n " + eVar.toString(); } } return str; } }
[ "khairilirfanlbs@gmail.com" ]
khairilirfanlbs@gmail.com
fb59ce91bd0c0f1996dfbe3415d469ab328acbaa
13c2d3db2d49c40c74c2e6420a9cd89377f1c934
/program_data/JavaProgramData/81/1255.java
84d8ab9a8ca96c1d962445a51dd7bf7b3f5c270d
[ "MIT" ]
permissive
qiuchili/ggnn_graph_classification
c2090fefe11f8bf650e734442eb96996a54dc112
291ff02404555511b94a4f477c6974ebd62dcf44
refs/heads/master
2021-10-18T14:54:26.154367
2018-10-21T23:34:14
2018-10-21T23:34:14
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,123
java
package <missing>; public class GlobalMembers { public static int[][] a = new int[5][5]; public static int i = 0; public static int j = 0; public static int m = 0; public static int n = 0; public static int t = 0; public static int Main() { for (i = 0;i < 5;i++) { for (j = 0;j < 5;j++) { String tempVar = ConsoleInput.scanfRead(); if (tempVar != null) { a[i][j] = Integer.parseInt(tempVar); } } } String tempVar2 = ConsoleInput.scanfRead(); if (tempVar2 != null) { n = Integer.parseInt(tempVar2); } String tempVar3 = ConsoleInput.scanfRead(); if (tempVar3 != null) { m = Integer.parseInt(tempVar3); } if ((n < 5) && (m < 5)) { for (i = 0;i < 5;i++) { t = a[n][i]; a[n][i] = a[m][i]; a[m][i] = t; } for (i = 0;i < 5;i++) { for (j = 0;j < 4;j++) { System.out.printf("%d ",a[i][j]); } System.out.printf("%d",a[i][4]); System.out.print("\n"); } } else { System.out.print("error"); } return 0; } }
[ "y.yu@open.ac.uk" ]
y.yu@open.ac.uk
43909fdb2dd8ff9f42f5a58337d09bcb2ddb253a
8b5cdda28454b0aab451a4b3216a58ca87517c41
/AL-Game/src/com/aionemu/gameserver/model/gameobjects/SummonedHouseNpc.java
30955f20a4524039d91f08d552a036077f700a3a
[]
no_license
flroexus/aelp
ac36cd96963bd12847e37118531b68953f9e8440
4f6cca6b462419accf53b58c454be0cf6abe39c0
refs/heads/master
2023-05-28T18:36:47.919387
2020-09-05T07:27:49
2020-09-05T07:27:49
null
0
0
null
null
null
null
UTF-8
Java
false
false
956
java
package com.aionemu.gameserver.model.gameobjects; import com.aionemu.gameserver.controllers.NpcController; import com.aionemu.gameserver.model.house.House; import com.aionemu.gameserver.model.templates.npc.NpcTemplate; import com.aionemu.gameserver.model.templates.spawns.SpawnTemplate; /** * @author Rolandas */ public class SummonedHouseNpc extends SummonedObject<House> { String masterName; public SummonedHouseNpc(int objId, NpcController controller, SpawnTemplate spawnTemplate, NpcTemplate npcTemplate, House house, String masterName) { super(objId, controller, spawnTemplate, npcTemplate, npcTemplate.getLevel()); setCreator(house); this.masterName = masterName; } @Override public int getCreatorId() { return getCreator().getAddress().getId(); } @Override public String getMasterName() { return masterName; } @Override public Creature getMaster() { // Not interesting, player may be offline return null; } }
[ "luiz.philip@amedigital.com" ]
luiz.philip@amedigital.com
eb05762fed93e4880c51a162f489c1f4b59a15d2
d7159c6d9dae83a47247afabdc89bde35bb7d1d6
/app/src/main/java/com/hnust/liveapp/ui/fragments/PlayerFragment.java
a7af6db38ea4a25cca33b8e97a76585a868b6852
[]
no_license
TommyTeaVee/LiveApp
89d796310ffa4ed8706fcffed00c36d64c2bdf11
9454a4d0d5972f91e9c6a64907323bba9613b7bb
refs/heads/master
2022-02-27T22:08:05.507619
2019-09-18T15:54:57
2019-09-18T15:54:57
null
0
0
null
null
null
null
UTF-8
Java
false
false
4,450
java
package com.hnust.liveapp.ui.fragments; import android.content.Context; import android.os.Bundle; import android.os.Handler; import android.os.Message; import androidx.annotation.Nullable; import androidx.appcompat.app.AppCompatActivity; import androidx.fragment.app.Fragment; import android.util.Log; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.view.inputmethod.InputMethodManager; import android.widget.Button; import android.widget.EditText; import android.widget.LinearLayout; import com.hnust.liveapp.R; import com.hnust.liveapp.util.DisplayUtil; import com.hnust.liveapp.widget.SoftKeyBoardListener; /** * 该Fragment是用于dialogFragment中的pager,为了实现滑动隐藏交互Fragment的 * 交互的操作都在这个界面实现的,如果大家要改交互主要修改这个界面就可以了 * <p> * Success is the sum of small efforts, repeated day in and day out. * 成功就是日复一日那一点点小小努力的积累。 */ public class PlayerFragment extends Fragment { private Handler handler = new Handler() { @Override public void handleMessage(Message msg) { super.handleMessage(msg); switch (msg.what) { case 0: break; } } }; /** * 标示判断 */ private boolean isOpen; private long liveTime; int height; /** * 界面相关 */ private LinearLayout lin_control; private EditText etInput; private Button btn_send; public static PlayerFragment newInstance(int flag) { Bundle args = new Bundle(); args.putInt("flag", flag); PlayerFragment fragment = new PlayerFragment(); fragment.setArguments(args); return fragment; } @Nullable @Override public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) { View view = inflater.inflate(R.layout.new_control_view, container, false); lin_control = (LinearLayout) view.findViewById(R.id.lin_control); etInput = (EditText) view.findViewById(R.id.etInput); btn_send = (Button) view.findViewById(R.id.btn_send); height = lin_control.getHeight(); return view; } @Override public void onViewCreated(View view, @Nullable Bundle savedInstanceState) { super.onViewCreated(view, savedInstanceState); softKeyboardListnenr(); } /** * 显示软键盘并因此头布局 */ private void showKeyboard() { handler.postDelayed(new Runnable() { @Override public void run() { InputMethodManager imm = (InputMethodManager) getActivity().getSystemService(Context.INPUT_METHOD_SERVICE); imm.showSoftInput(etInput, InputMethodManager.SHOW_FORCED); } }, 100); } /** * 隐藏软键盘并显示头布局 */ public void hideKeyboard() { InputMethodManager imm = (InputMethodManager) getActivity().getSystemService(Context.INPUT_METHOD_SERVICE); imm.hideSoftInputFromWindow(etInput.getWindowToken(), 0); } /** * 软键盘显示与隐藏的监听 */ private void softKeyboardListnenr() { SoftKeyBoardListener.setListener((AppCompatActivity) getActivity(), new SoftKeyBoardListener.OnSoftKeyBoardChangeListener() { @Override public void keyBoardShow(int height) {/*软键盘显示:执行隐藏title动画,并修改listview高度和装载礼物容器的高度*/ dynamicChangeH(height); Log.e("Height",height+"---"); } @Override public void keyBoardHide(int height) {/*软键盘隐藏:隐藏聊天输入框并显示聊天按钮,执行显示title动画,并修改listview高度和装载礼物容器的高度*/ dynamicChangeH(height); Log.e("Height",height+"---"); } }); } /** * 动态的修改listview的高度 * * @param heightPX */ private void dynamicChangeH(int heightPX) { ViewGroup.LayoutParams layoutParams = lin_control.getLayoutParams(); layoutParams.height = DisplayUtil.dip2px(getActivity(), heightPX); lin_control.setLayoutParams(layoutParams); } }
[ "caiyonglong@live.com" ]
caiyonglong@live.com
3bc47805062c6127301baf6e19f58a1d51806f60
bf744ba24a594529fc2e6729afe19a20b70d6fde
/Proj-supergenius-XO/Moralnews/src/test/java/com/supergenius/xo/moralnews/dao/CollectDaoTest.java
aedb92fd647a1d88b35dece215681348d92217f3
[]
no_license
greatgy/Code
4e3fc647999d0ff94933c0ff85bf08228de62a1f
e198b7cf90a40e531235fa9e88df211e1978e177
refs/heads/master
2021-10-27T16:27:19.551730
2019-04-18T09:43:07
2019-04-18T09:43:07
182,007,387
0
0
null
null
null
null
UTF-8
Java
false
false
2,351
java
package com.supergenius.xo.moralnews.dao; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNotNull; import static org.junit.Assert.assertTrue; import java.util.HashMap; import java.util.Map; import org.joda.time.DateTime; import org.junit.After; import org.junit.Before; import org.junit.Test; import org.junit.runner.RunWith; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.test.context.ContextConfiguration; import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; import com.genius.core.base.constant.BaseMapperDict; import com.supergenius.xo.mock.testconstants.TestConst; import com.supergenius.xo.moralnews.entity.Collect; /** * 收藏测试类 * * @author JiaShitao * @date 2018年9月19日09:47:55 */ @RunWith(SpringJUnit4ClassRunner.class) @ContextConfiguration(locations = { "classpath*:**/applicationContext**.xml" }) public class CollectDaoTest { @Autowired private CollectDao dao; private Collect entity; @Before public void before() { entity = new Collect(); entity.setUid(TestConst.uid1); entity.setCreatetime(new DateTime()); entity.setUseruid(TestConst.uid2); entity.setRefuid(TestConst.uid1); boolean result = dao.insert(entity); assertTrue(result); } @After public void after() { entity = null; boolean result = dao.delete(TestConst.uid1); assertTrue(result); } /** * Test Get() */ @Test public void testGet() { entity = dao.get(TestConst.uid1); assertNotNull(entity); assertEquals(TestConst.uid1, entity.getUid()); } /** * Test GetOne() */ @Test public void testGetOne() { Map<String, Object> map = new HashMap<String, Object>(); map.put(BaseMapperDict.uid, TestConst.uid); assertNotNull(dao.getOne(map)); } /** * Test GetCount() */ @Test public void testCount() { assertTrue(dao.getCount(null) >= 1); } /** * Test GetList() */ @Test public void testGetList() { Map<String, Object> map = new HashMap<String, Object>(); map.put(BaseMapperDict.uid, TestConst.uid); assertTrue(dao.getList(map).size() > 0); } /** * Test Update() */ @Test public void testUpdate() { entity = dao.get(TestConst.uid1); String uid = entity.getUid(); assertNotNull(dao.get(uid)); entity.setRefuid(TestConst.uid); assertTrue(dao.update(entity)); } }
[ "18519764453@163.com" ]
18519764453@163.com
76210f3ee7089f860f2649ac19760425b7f7a9c0
e7ee311e20b40c87bf6d23a53a1d7b11fd29d2c3
/src/chosun/ciis/mc/cost/rec/MC_COST_3017_MCURLIST_01Record.java
9df4882c32dd351f72172d4c6799df611c35982e
[]
no_license
nosmoon/misdevteam
4e3695ef7bbdcd231bb84d7d8d7df54a23ff0a60
1829d5bd489eb6dd307ca244f0e183a31a1de773
refs/heads/master
2020-04-15T15:57:05.480056
2019-01-10T01:12:01
2019-01-10T01:12:01
164,812,547
1
0
null
null
null
null
UHC
Java
false
false
1,078
java
/*************************************************************************************************** * 파일명 : .java * 기능 : 독자우대-구독신청 * 작성일자 : 2007-05-22 * 작성자 : 김대섭 ***************************************************************************************************/ /*************************************************************************************************** * 수정내역 : * 수정자 : * 수정일자 : * 백업 : ***************************************************************************************************/ package chosun.ciis.mc.cost.rec; import java.sql.*; import chosun.ciis.mc.cost.dm.*; import chosun.ciis.mc.cost.ds.*; /** * */ public class MC_COST_3017_MCURLIST_01Record extends java.lang.Object implements java.io.Serializable{ public String col1; public MC_COST_3017_MCURLIST_01Record(){} public void setCol1(String col1){ this.col1 = col1; } public String getCol1(){ return this.col1; } } /* 작성시간 : Mon May 11 14:19:24 KST 2009 */
[ "DLCOM000@172.16.30.11" ]
DLCOM000@172.16.30.11
ba318c5e03b0386f7b3f93cf1ba9349090d4f3db
b5d6f167fc12d1cbc2c8c07badab47dc65cef4eb
/qtiworks-jqtiplus/src/main/java/uk/ac/ed/ph/jqtiplus/node/RootNode.java
617b3aff69b66fe6f8270219e7a706f1a7b1a2b7
[]
no_license
pm-sari/qtiworks
ef04508c7982b5c0049c9b735493ef1dfe28cd4d
da3192c19732d66d851f4845c5004086773cfbe2
refs/heads/master
2021-01-18T07:02:59.202552
2013-07-18T08:59:16
2013-07-18T08:59:16
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,536
java
/* Copyright (c) 2012-2013, University of Edinburgh. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above copyright notice, this * list of conditions and the following disclaimer. * * * Redistributions in binary form must reproduce the above copyright notice, this * list of conditions and the following disclaimer in the documentation and/or * other materials provided with the distribution. * * * Neither the name of the University of Edinburgh nor the names of its * contributors may be used to endorse or promote products derived from this * software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * * * This software is derived from (and contains code from) QTItools and MathAssessEngine. * QTItools is (c) 2008, University of Southampton. * MathAssessEngine is (c) 2010, University of Edinburgh. */ package uk.ac.ed.ph.jqtiplus.node; import uk.ac.ed.ph.jqtiplus.node.item.AssessmentItem; import uk.ac.ed.ph.jqtiplus.node.item.response.processing.ResponseProcessing; import uk.ac.ed.ph.jqtiplus.node.result.AssessmentResult; import uk.ac.ed.ph.jqtiplus.node.test.AssessmentTest; import java.net.URI; /** * Marker interface for a "root" QTI Node. * * @see RootNodeTypes * @see AssessmentItem * @see AssessmentTest * @see AssessmentResult * @see ResponseProcessing * * @author David McKain */ public interface RootNode extends QtiNode { /** Returns the systemId of this tree, if loaded from a URI, null otherwise */ URI getSystemId(); /** Sets the systemId for this tree */ void setSystemId(URI systemId); }
[ "david.mckain@ed.ac.uk" ]
david.mckain@ed.ac.uk
6e7dde4378415bedb355d55ee83ed2b3a24dd071
4be72dee04ebb3f70d6e342aeb01467e7e8b3129
/bin/ext-integration/sap/availability/sapproductavailability/testsrc/de/hybris/platform/sap/sapproductavailability/businessobject/impl/SapProductAvailabilityBOImplTest.java
925ff029b3bae98d06addb1957176b006d97fa5f
[]
no_license
lun130220/hybris
da00774767ba6246d04cdcbc49d87f0f4b0b1b26
03c074ea76779f96f2db7efcdaa0b0538d1ce917
refs/heads/master
2021-05-14T01:48:42.351698
2018-01-07T07:21:53
2018-01-07T07:21:53
null
0
0
null
null
null
null
UTF-8
Java
false
false
860
java
package de.hybris.platform.sap.sapproductavailability.businessobject.impl; import static org.junit.Assert.assertNotNull; import org.easymock.EasyMock; import org.junit.Before; import org.junit.Test; import de.hybris.platform.sap.core.jco.connection.JCoConnection; import de.hybris.platform.sap.core.jco.exceptions.BackendException; import de.hybris.platform.sap.sapproductavailability.unittests.base.SapProductAvailabilityBolSpringJunitTest; public class SapProductAvailabilityBOImplTest extends SapProductAvailabilityBolSpringJunitTest{ SapProductAvailabilityBOImpl classUnderTest = null; JCoConnection connection = null; @Before public void init() throws BackendException { connection = EasyMock.createMock(JCoConnection.class); } @Test public void testReadProductAvailability(){ assertNotNull(connection); } }
[ "lun130220@gamil.com" ]
lun130220@gamil.com
071c9c12308163f8c2e1e2ac3165914a3857f4a8
54c1dcb9a6fb9e257c6ebe7745d5008d29b0d6b6
/app/src/main/java/com/p118pd/sdk/C6323ili1.java
2fcc13ceec59d95b8adc3b3689c80a139ffc97fd
[]
no_license
rcoolboy/guilvN
3817397da465c34fcee82c0ca8c39f7292bcc7e1
c779a8e2e5fd458d62503dc1344aa2185101f0f0
refs/heads/master
2023-05-31T10:04:41.992499
2021-07-07T09:58:05
2021-07-07T09:58:05
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,032
java
package com.p118pd.sdk; import org.bouncycastle.crypto.DataLengthException; import org.bouncycastle.crypto.OutputLengthException; /* renamed from: com.pd.sdk.ili1 reason: case insensitive filesystem */ public class C6323ili1 implements li1l11I1 { public static final int OooO0O0 = 1; public final int OooO00o; /* renamed from: OooO00o reason: collision with other field name */ public boolean f18039OooO00o; public C6323ili1() { this(1); } public C6323ili1(int i) { this.OooO00o = i; } @Override // com.p118pd.sdk.li1l11I1, com.p118pd.sdk.li1l11I1 public int OooO00o() { return this.OooO00o; } @Override // com.p118pd.sdk.li1l11I1 public int OooO00o(byte[] bArr, int i, byte[] bArr2, int i2) throws DataLengthException, IllegalStateException { if (this.f18039OooO00o) { int i3 = this.OooO00o; if (i + i3 > bArr.length) { throw new DataLengthException("input buffer too short"); } else if (i3 + i2 <= bArr2.length) { int i4 = 0; while (true) { int i5 = this.OooO00o; if (i4 >= i5) { return i5; } bArr2[i2 + i4] = bArr[i + i4]; i4++; } } else { throw new OutputLengthException("output buffer too short"); } } else { throw new IllegalStateException("Null engine not initialised"); } } @Override // com.p118pd.sdk.li1l11I1, com.p118pd.sdk.li1l11I1 /* renamed from: OooO00o reason: collision with other method in class */ public String m17371OooO00o() { return "Null"; } @Override // com.p118pd.sdk.li1l11I1 public void OooO00o(boolean z, AbstractC6370iIIIl r2) throws IllegalArgumentException { this.f18039OooO00o = true; } @Override // com.p118pd.sdk.li1l11I1 public void reset() { } }
[ "593746220@qq.com" ]
593746220@qq.com
8705151aa1ca951b17aab8c5a67d01ac877cbb81
b45673f501ca7c891c8109a714cdf01cde455430
/AOOP/src/lab05_CommandPattern_5/ExecuteUndoCommandButton.java
406908f5cf91907b50778b9392e336831cd6c412
[]
no_license
kmdngmn/DesignPattern
1e9afed125d412727b2a85470fcd7e5b2380ffda
03bcf957eb10022d6c525d80eb1d0e2bebb5c660
refs/heads/master
2020-11-25T20:09:59.117899
2019-12-23T02:24:50
2019-12-23T02:24:50
228,822,817
0
0
null
null
null
null
UTF-8
Java
false
false
788
java
package lab05_CommandPattern_5; import java.util.ArrayList; import java.util.List; import javax.swing.ImageIcon; import javax.swing.JLabel; public class ExecuteUndoCommandButton extends CommandButton implements Command { private JLabel label; private ImageIcon imageIcon; private static List<ImageIcon> list; public ExecuteUndoCommandButton(JLabel label, ImageIcon imageIcon) { this.label = label; this.imageIcon = imageIcon; list = new ArrayList<ImageIcon>(); } @Override public void execute() { if (getText().equals("undo")) { undo(); return; } label.setIcon(imageIcon); list.add(imageIcon); } @Override public void undo() { if(list.size() >= 2) { label.setIcon(list.get(list.size()-2)); list.add(list.get(list.size()-2)); } } }
[ "enfkdla@gmail.com" ]
enfkdla@gmail.com
96e6aab8d8022a1fa4be811effef184b52c4bf03
3a856a230c169110607c23c2c88bcc931356c7bb
/05-architecture/XX-JetpackMvvm-Fixed/base/src/main/java/com/xiangxue/base/customview/BaseCustomViewModel.java
81b68406d60c9e4717b03159befb218faa454218
[]
no_license
klzhong69/android-code
de9627fe3c5f890011d3bd0809e73fa8da5b0f3e
7e07776c9dc61e857ca5c36ab81a0fb22cd619c1
refs/heads/main
2023-08-13T16:08:29.994460
2021-10-13T15:22:50
2021-10-13T15:22:50
null
0
0
null
null
null
null
UTF-8
Java
false
false
128
java
package com.xiangxue.base.customview; public class BaseCustomViewModel { public String jumpUri; public String title; }
[ "ztiany3@gmail.com" ]
ztiany3@gmail.com
67619bc0652d381ca79b9d91be6aa5e444841b5f
4b0bf4787e89bcae7e4759bde6d7f3ab2c81f849
/aliyun-java-sdk-devops-rdc/src/main/java/com/aliyuncs/devops_rdc/model/v20200303/UpdateDevopsProjectTaskResponse.java
4f5f5b26c42f2896ef3b19d84e4c8fb2e91156af
[ "Apache-2.0" ]
permissive
aliyun/aliyun-openapi-java-sdk
a263fa08e261f12d45586d1b3ad8a6609bba0e91
e19239808ad2298d32dda77db29a6d809e4f7add
refs/heads/master
2023-09-03T12:28:09.765286
2023-09-01T09:03:00
2023-09-01T09:03:00
39,555,898
1,542
1,317
NOASSERTION
2023-09-14T07:27:05
2015-07-23T08:41:13
Java
UTF-8
Java
false
false
2,045
java
/* * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.aliyuncs.devops_rdc.model.v20200303; import com.aliyuncs.AcsResponse; import com.aliyuncs.devops_rdc.transform.v20200303.UpdateDevopsProjectTaskResponseUnmarshaller; import com.aliyuncs.transform.UnmarshallerContext; /** * @author auto create * @version */ public class UpdateDevopsProjectTaskResponse extends AcsResponse { private String errorMsg; private String requestId; private Boolean object; private Boolean successful; private String errorCode; public String getErrorMsg() { return this.errorMsg; } public void setErrorMsg(String errorMsg) { this.errorMsg = errorMsg; } public String getRequestId() { return this.requestId; } public void setRequestId(String requestId) { this.requestId = requestId; } public Boolean getObject() { return this.object; } public void setObject(Boolean object) { this.object = object; } public Boolean getSuccessful() { return this.successful; } public void setSuccessful(Boolean successful) { this.successful = successful; } public String getErrorCode() { return this.errorCode; } public void setErrorCode(String errorCode) { this.errorCode = errorCode; } @Override public UpdateDevopsProjectTaskResponse getInstance(UnmarshallerContext context) { return UpdateDevopsProjectTaskResponseUnmarshaller.unmarshall(this, context); } @Override public boolean checkShowJsonItemName() { return false; } }
[ "sdk-team@alibabacloud.com" ]
sdk-team@alibabacloud.com
37a69e1be1148aa06172ed507945520ebdadd6dc
06d76ab89e6cd8cc7d9281b65e0c92bfa3c32af5
/mapsdk/src/main/java/com/sfmap/api/maps/MapOptions.java
7439e17715da242c200cdd356511b21774d02870
[]
no_license
onlie08/SFLocationDemo
f7042c598fdb1bd4fe5eeba791df6ae6f779d73e
7c15f13b1d6335a6dbf20b6ee7cce62bd20c1ca9
refs/heads/master
2022-12-15T20:09:31.577510
2020-08-25T02:38:57
2020-08-25T02:38:57
217,438,626
1
0
null
2020-09-17T05:55:44
2019-10-25T02:54:37
Java
UTF-8
Java
false
false
9,872
java
package com.sfmap.api.maps; import android.graphics.Bitmap; import android.os.Parcel; import android.os.Parcelable; import com.sfmap.api.maps.model.CameraPosition; import java.util.HashMap; import java.util.Map; /** * 定义了一个配置LMap 的选项类。实现了Parcelable 接口。 */ public class MapOptions implements Parcelable { public static final MapOptionsCreator CREATOR = new MapOptionsCreator(); /** * 地图类型。 */ private int mapType = 1; /** * 地图是否可以通过手势进行旋转。默认为true。 */ private boolean rotateGesturesEnabled = true; /** * 地图是否可以通过手势滑动。默认为true。 */ private boolean scrollGesturesEnabled = true; /** * 地图是否可以通过手势倾斜(3D 楼块效果),默认为true。 */ private boolean tiltGesturesEnabled = true; /** * 地图是否可以通过手势进行缩放。默认为true。 */ private boolean zoomGesturesEnabled = true; /** * 地图是否允许缩放。默认为true。 */ private boolean zoomEnabled= true; /** * Z 轴排序是否被允许。 */ private boolean zOrderOnTop = false; /** * 可视范围的位置对象。 */ private CameraPosition camera; /** * 指南针是否可用。默认为启用。 */ private boolean compassEnabled = false; /** * 地图是否显示比例尺。默认为false。 */ private boolean enabled = false; /** * Logo的位置。默认Logo位置(地图左下角)。 */ private int position = 0; /** * Logo位置(地图左下角)。 */ public static final int LOGO_POSITION_BOTTOM_LEFT = 0; /** * Logo位置(地图底部居中)。 */ public static final int LOGO_POSITION_BOTTOM_CENTER = 1; /** * Logo位置(地图右下角))。 */ public static final int LOGO_POSITION_BOTTOM_RIGHT = 2; /** * 缩放按钮位置(地图右下角)。 */ public static final int ZOOM_POSITION_RIGHT_CENTER = 1; /** * 缩放按钮位置(地图右边界中部)。 */ public static final int ZOOM_POSITION_RIGHT_BUTTOM = 2; /** * 调整控件位置(指北针)。 */ public static final int POSITION_COMPASS = 1; /** * 调整控件位置(比例尺)。 */ public static final int POSITION_SCALE = 2; /** * 调整控件位置(LOGO)。 */ public static final int POSITION_LOGO = 3; // public static Map<Integer,int[]> viewPositionMap=new HashMap<>(); public static Map<Integer,Bitmap[]> viewBitmapMap=new HashMap<>(); /** * 设置地图Logo的位置。 * @param position - Logo的位置。 左下:LOGO_POSITION_BOTTOM_LEFT 底部居中:LOGO_POSITION_BOTTOM_CENTER 右下:LOGO_POSITION_BOTTOM_RIGHT。 * @return LMapOptions对象。 */ public MapOptions logoPosition(int position) { this.position = position; return this; } /** * 设置Z 轴排序是否被允许。 * @param zOrderOnTop - true 允许,false 不允许。 * @return 一个设置Z轴排序的LMapOptions对象。 */ public MapOptions zOrderOnTop(boolean zOrderOnTop) { this.zOrderOnTop = zOrderOnTop; return this; } /** *设置一个地图显示类型以改变初始的类型。 * @param mapType - 地图类型: MAP_TYPE_NORMAL:普通地图,值为1; MAP_TYPE_NIGHT 黑夜地图,夜间模式,值为3; MAP_TYPE_NAVI 导航模式,值为4。 * @return MapOptions 设置了一个地图显示类型的选项类。 */ public MapOptions mapType(int mapType) { this.mapType = mapType; return this; } /** * 设置了一个可视范围的初始化位置。 * @param camera - 可视范围的位置对象。 * @return MapOptions 设置了可视范围的初始化位置的选项类。 */ public MapOptions camera(CameraPosition camera) { this.camera = camera; return this; } /** * 设置地图是否显示比例尺。默认为false。 * @param enabled - true 支持,false 不支持。 * @return 一个设置地图是否显示比例尺的LMapOptions对象。 */ public MapOptions scaleControlsEnabled(boolean enabled) { this.enabled = enabled; return this; } /** * 设置地图缩放控件是否显示。 * @param enabled - true 显示,false 不显示。 * @return 一个设置地图是否允许缩放的LMapOptions对象。 */ public MapOptions zoomControlsEnabled(boolean enabled) { this.zoomEnabled = enabled; return this; } /** * 设置指南针是否可用。默认为启用。 * @param enabled - 一个布尔值,表示指南针是否可用,true表示可用,false表示不可用。 * @return LMapOptions对象。 */ public MapOptions compassEnabled(boolean enabled) { this.compassEnabled = enabled; return this; } /** * 设置地图是否可以通过手势滑动。默认为true。 * @param enabled - true 支持,false 不支持。 * @return 一个设置地图是否手势滑动的LMapOptions对象对象。 */ public MapOptions scrollGesturesEnabled(boolean enabled) { this.scrollGesturesEnabled = enabled; return this; } /** * 设置地图是否可以通过手势进行缩放。默认为true。 * @param enabled - true 支持,false 不支持。 * @return 一个LMapOptions对象对象。 */ public MapOptions zoomGesturesEnabled(boolean enabled) { this.zoomGesturesEnabled = enabled; return this; } /** * 设置地图是否可以通过手势倾斜(3D 楼块效果),默认为true。 * @param enabled - true 支持,false 不支持。 * @return 一个LMapOptions对象。 */ public MapOptions tiltGesturesEnabled(boolean enabled) { this.tiltGesturesEnabled = enabled; return this; } /** * 设置地图是否可以通过手势进行旋转。默认为true。 * @param enabled - true 支持,false 不支持。 * @return 一个LMapOptions对象。 */ public MapOptions rotateGesturesEnabled(boolean enabled) { this.rotateGesturesEnabled = enabled; return this; } /** * 获取地图Logo的位置。 * @return 地图Logo的位置常量。 */ public int getLogoPosition() { return this.position; } // /** // * 设置Logo,比例尺,指北针相对地图的屏幕位置 // * @param viewType 类型:MapOption.POSITION_COMPASS,MapOption.POSITION_SCALE,MapOption.POSITION_LOGO // * @param pixXY 相对地图左侧的绝对x,y坐标 // */ // public void customViewPositionInWindow(int viewType,int[] pixXY){ // this.viewPositionMap.put(viewType,pixXY); // } // // /** // * 设置指北针,我的位置控件图标 // * @param viewType 类型:1.指北针;2.定位按钮 我的位置按钮需要2张图标,状态:正常和按下 // * @param bitmap 图标 // */ // public void customViewBitmap(int viewType,Bitmap[] bitmap){ // this.viewBitmapMap.put(viewType,bitmap); // } /** *返回Z 轴排序是否被允许。 * @return true 允许,false 不允许。 */ public Boolean getZOrderOnTop() { return Boolean.valueOf(this.zOrderOnTop); } /** *返回选项类里的地图类型。 * @return 选项类里的地图类型,如果返回-1,则表示未设置。 */ public int getMapType() { return this.mapType; } /** * 获取可视范围的初始化位置。 * @return 一个已经设置的可视范围位置,如果为null 则说明还没有设置。 */ public CameraPosition getCamera() { return this.camera; } /** * 返回比例尺功能是否可用。 * @return 比例尺功能是否可用。 */ public Boolean getScaleControlsEnabled() { return Boolean.valueOf(this.enabled); } /** * 返回地图缩放控件是否显示。 * @return true 显示 ,false 不显示。 */ public Boolean getZoomControlsEnabled() { return Boolean.valueOf(this.zoomEnabled); } /** * 返回指南针功能是否可用。 * @return 选项类里的指南针,如果返回false,则表示未设置。 */ public Boolean getCompassEnabled() { return Boolean.valueOf(this.compassEnabled); } /** * 返回拖动手势是否被允许。 * @return true 允许,false 不允许。 */ public Boolean getScrollGesturesEnabled() { return Boolean.valueOf(this.scrollGesturesEnabled); } /** * 返回缩放手势是否被支持。 * @return true 支持,false 不支持。 */ public Boolean getZoomGesturesEnabled() { return Boolean.valueOf(this.zoomGesturesEnabled); } /** * 返回地图倾斜手势(显示3D 楼块)是否被允许。 * @return true 允许,false 不允许。 */ public Boolean getTiltGesturesEnabled() { return Boolean.valueOf(this.tiltGesturesEnabled); } /** * 返回旋转手势是否被允许。 * @return 旋转手势是否被允许。 */ public Boolean getRotateGesturesEnabled() { return Boolean.valueOf(this.rotateGesturesEnabled); } public int describeContents() { return 0; } public void writeToParcel(Parcel parcel, int paramInt) { parcel.writeParcelable(this.camera, paramInt); parcel.writeInt(this.mapType); boolean[] arrayOfBoolean = { this.rotateGesturesEnabled, this.scrollGesturesEnabled, this.tiltGesturesEnabled, this.zoomGesturesEnabled, this.zoomEnabled, this.zOrderOnTop, this.compassEnabled, this.enabled }; parcel.writeBooleanArray(arrayOfBoolean); } }
[ "conggong@sfmail.sf-express.com" ]
conggong@sfmail.sf-express.com
5999a33ac233ab0011725fdbe6df69a6d5f8f827
30bab31c0c99a6699a1d341625cdb5fa87f73962
/studentboard/src/main/java/my/examples/studentboard/Main.java
f65951365bfeb45dd133e1286b07c602adf1e16d
[]
no_license
yjs2952/JAVAStudy
58eb65a82ee2246d89aebb930598ab2d78730fbd
94f09e070c720d44724a9ff1329efd3e40d341f0
refs/heads/master
2021-07-14T08:42:35.486791
2019-03-22T14:41:22
2019-03-22T14:41:22
149,575,669
0
0
null
null
null
null
UTF-8
Java
false
false
492
java
package my.examples.studentboard; import my.examples.studentboard.controller.MainController; import org.springframework.context.ApplicationContext; import org.springframework.context.support.ClassPathXmlApplicationContext; public class Main { public static void main(String[] args) { ApplicationContext ac = new ClassPathXmlApplicationContext("config.xml"); MainController mainController = ac.getBean(MainController.class); mainController.controll(); } }
[ "yjs2952@naver.com" ]
yjs2952@naver.com
bba6c4fa3404cc0d2160c49c7b8c8d8ea1f7705c
189d820ad0527b71a04596e385c6a84f904669d0
/exercise/src/holding/ex20/Ex20.java
cf7082ffbc7a9cbbefdf05c601b561cced5ee7b4
[ "Apache-2.0" ]
permissive
jhwsx/Think4JavaExamples
30484e128ce43ed3d1da0104b77d8e3fedee7b59
bf912a14def15c11a9a5eada308ddaae8e31ff8f
refs/heads/master
2023-07-06T17:27:18.738304
2021-08-08T12:33:57
2021-08-08T12:33:57
198,008,875
0
1
null
null
null
null
UTF-8
Java
false
false
1,612
java
package holding.ex20; import net.mindview.util.TextFile; import java.util.Collections; import java.util.HashMap; import java.util.Map; import java.util.Set; import java.util.TreeSet; /** * <pre> * author : wangzhichao * e-mail : wangzhichao@adups.com * time : 2019/08/12 * desc : * version: 1.0 * </pre> */ public class Ex20 { static void vowelCounter(Set<String> st){ Set<Character> vowels = new TreeSet<>(); Map<Character, Integer> map = new HashMap<>(); Collections.addAll(vowels, 'A', 'E', 'I', 'O', 'U', 'a', 'e', 'i', 'o', 'u'); int allVowels = 0; for (String s : st) { int count = 0; for (Character c : s.toCharArray()) { if (vowels.contains(c)) { count++; if (map.containsKey(c)) { map.put(c, map.get(c) + 1); } else { map.put(c, 1); } allVowels++; } } System.out.print(s + ": " + count +", "); } System.out.println(); System.out.print("Total vowels: " + allVowels); System.out.println(); System.out.println(map); } public static void main(String[] args) { Set<String> words = new TreeSet<>(new TextFile( "G:\\AndroidWorkspaces\\Think4JavaExamples\\exercise\\src\\main\\java\\holding\\ex15\\Stack.java","\\W+" )); System.out.println(words); System.out.println(); vowelCounter(words); } }
[ "wangzhichao@adups.com" ]
wangzhichao@adups.com
66518cf4bb82ed9b90afc409a9a25bf3485c356d
247337ac30cbc2727ee0b2ce1d6239b9a8a0e038
/vertx-lang-ceylon/src/main/ceylon/io/vertx/ceylon/core/file/FileSystemProps.java
f1e548feae330d08682fbb826392a8a6982d348c
[ "Apache-2.0" ]
permissive
guidbona/vertx-lang-ceylon
1a5abe21ef0b67a5c4a5b5921def740b6538d9f5
2467572f8ffc80d6ad030238ceb13bc62b454720
refs/heads/master
2021-01-13T12:46:56.393855
2016-10-29T16:14:47
2016-10-29T16:15:21
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,777
java
package io.vertx.ceylon.core.file; import com.redhat.ceylon.compiler.java.metadata.Ceylon; import com.redhat.ceylon.compiler.java.metadata.TypeInfo; import com.redhat.ceylon.compiler.java.metadata.TypeParameter; import com.redhat.ceylon.compiler.java.metadata.TypeParameters; import com.redhat.ceylon.compiler.java.metadata.Variance; import com.redhat.ceylon.compiler.java.metadata.Ignore; import com.redhat.ceylon.compiler.java.metadata.Name; import com.redhat.ceylon.compiler.java.runtime.model.TypeDescriptor; import com.redhat.ceylon.compiler.java.runtime.model.ReifiedType; import ceylon.language.Callable; import ceylon.language.DocAnnotation$annotation$; @Ceylon(major = 8) @DocAnnotation$annotation$(description = " Represents properties of the file system.\n") public class FileSystemProps implements ReifiedType { @Ignore public static final io.vertx.lang.ceylon.ConverterFactory<io.vertx.core.file.FileSystemProps, FileSystemProps> TO_CEYLON = new io.vertx.lang.ceylon.ConverterFactory<io.vertx.core.file.FileSystemProps, FileSystemProps>() { public io.vertx.lang.ceylon.Converter<io.vertx.core.file.FileSystemProps, FileSystemProps> converter(final TypeDescriptor... descriptors) { return new io.vertx.lang.ceylon.Converter<io.vertx.core.file.FileSystemProps, FileSystemProps>() { public FileSystemProps convert(io.vertx.core.file.FileSystemProps src) { return new FileSystemProps(src); } }; } }; @Ignore public static final io.vertx.lang.ceylon.Converter<FileSystemProps, io.vertx.core.file.FileSystemProps> TO_JAVA = new io.vertx.lang.ceylon.Converter<FileSystemProps, io.vertx.core.file.FileSystemProps>() { public io.vertx.core.file.FileSystemProps convert(FileSystemProps src) { return src.delegate; } }; @Ignore public static final TypeDescriptor $TypeDescriptor$ = TypeDescriptor.klass(FileSystemProps.class); @Ignore private final io.vertx.core.file.FileSystemProps delegate; public FileSystemProps(io.vertx.core.file.FileSystemProps delegate) { this.delegate = delegate; } @Ignore public TypeDescriptor $getType$() { return $TypeDescriptor$; } @Ignore public Object getDelegate() { return delegate; } @DocAnnotation$annotation$(description = "") @TypeInfo("ceylon.language::Integer") public long totalSpace() { long ret = delegate.totalSpace(); return ret; } @DocAnnotation$annotation$(description = "") @TypeInfo("ceylon.language::Integer") public long unallocatedSpace() { long ret = delegate.unallocatedSpace(); return ret; } @DocAnnotation$annotation$(description = "") @TypeInfo("ceylon.language::Integer") public long usableSpace() { long ret = delegate.usableSpace(); return ret; } }
[ "julien@julienviet.com" ]
julien@julienviet.com
24754d3e02611176a2ee271e9ecd34e3ab719eac
19f7e40c448029530d191a262e5215571382bf9f
/decompiled/instagram/sources/p000X/CAB.java
7cd9eaa92e276c25baf92d0b4eb8f5547bc00155
[]
no_license
stanvanrooy/decompiled-instagram
c1fb553c52e98fd82784a3a8a17abab43b0f52eb
3091a40af7accf6c0a80b9dda608471d503c4d78
refs/heads/master
2022-12-07T22:31:43.155086
2020-08-26T03:42:04
2020-08-26T03:42:04
283,347,288
18
1
null
null
null
null
UTF-8
Java
false
false
3,359
java
package p000X; import android.content.Context; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.view.ViewStub; import com.facebook.C0003R; import com.instagram.common.p004ui.widget.framelayout.MediaFrameLayout; import com.instagram.feed.widget.IgProgressImageView; import com.instagram.model.mediatype.MediaType; import com.instagram.p009ui.mediaactions.MediaActionsView; /* renamed from: X.CAB */ public final class CAB extends AnonymousClass2MK { public CA8 A00; public AnonymousClass0RN A01; public AnonymousClass0C1 A02; public final float A03; public final /* bridge */ /* synthetic */ void A04(C40371oY r7, AnonymousClass1ZK r8) { Object[] objArr; String str; CA7 ca7 = (CA7) r7; CAD cad = (CAD) r8; AnonymousClass11J.A00(this.A02); AnonymousClass11J.A00(this.A01); AnonymousClass11J.A00(this.A00); boolean z = false; if (cad.A00 != null) { z = true; } if (z) { cad.APt().A0H(cad.AGJ().A00()); } C36841ih r0 = ca7.A01; AnonymousClass11J.A00(r0); cad.A00 = r0; C38641lb.A00(this.A02, ca7.A00, cad.ANP(), this.A01, (Context) null); new AnonymousClass1VM().A01(cad.APf(), cad.ANP(), ca7.A02, ca7.A00, cad.APt()); C38781lp.A00(cad.AGJ(), ca7.A00, cad.APt()); cad.APt().A0G(cad.AGJ().A00()); View APn = cad.APn(); if (ca7.A00.APx() == MediaType.VIDEO) { objArr = new Object[1]; str = "Video"; } else { objArr = new Object[1]; str = "Photo"; } objArr[0] = str; APn.setContentDescription(C06360Ot.formatString("Media Thumbnail %s Cell", objArr)); CA8 ca8 = this.A00; if (ca8.A00.A07.A03(ca7.A00.APo()) == 0) { CA9 ca9 = ca8.A00.A00; AnonymousClass11J.A00(ca9); AnonymousClass1NJ r3 = ca7.A00; AnonymousClass1NJ r02 = ca9.A02; if (r02 != null && r02.equals(r3)) { CA9.A03(ca9, "media_mismatch", true); CA9.A02(ca9, r3, cad, 0); } } View APn2 = cad.APn(); APn2.setOnClickListener(new CAC(ca8, ca7, cad)); APn2.setOnTouchListener(new CA6(ca8, ca7)); } public CAB(float f) { this.A03 = f; } public final /* bridge */ /* synthetic */ AnonymousClass1ZK A01(ViewGroup viewGroup, LayoutInflater layoutInflater) { View inflate = layoutInflater.inflate(C0003R.layout.media_thumbnail_preview_item_layout, viewGroup, false); MediaFrameLayout mediaFrameLayout = (MediaFrameLayout) AnonymousClass1E1.A07(inflate, C0003R.C0005id.thumbnail_preview_container); mediaFrameLayout.setAspectRatio(this.A03); return new CAD(inflate, mediaFrameLayout, (IgProgressImageView) AnonymousClass1E1.A07(inflate, C0003R.C0005id.media_image_preview), mediaFrameLayout, (MediaActionsView) AnonymousClass1E1.A07(inflate, C0003R.C0005id.preview_media_actions_view), new C32221an((ViewStub) AnonymousClass1E1.A07(inflate, C0003R.C0005id.audio_icon_view_stub)), new C32231ao((ViewStub) AnonymousClass1E1.A07(inflate, C0003R.C0005id.video_subtitle_view_stub))); } public final Class A02() { return CA7.class; } }
[ "stan@rooy.works" ]
stan@rooy.works
da54b60f6fdce687b79805a30499dbfd9991c62d
24643916cd1515911b7837ce81ebd17b0890cc81
/frameworks/base/tests/WMS/tests/src/mediatek/view/cts/OrientationEventListenerTest.java
451fc4858ca144ff56e7307252a88f8b648c85b8
[ "Apache-2.0" ]
permissive
touxiong88/92_mediatek
3a0d61109deb2fa77f79ecb790d0d3fdd693e5fd
5e96a7bb778fd9d9b335825584664e0c8b5ff2c7
refs/heads/master
2020-05-02T10:20:49.365871
2019-04-25T09:12:56
2019-04-25T09:12:56
177,894,636
1
1
null
null
null
null
UTF-8
Java
false
false
6,160
java
/* Copyright Statement: * * This software/firmware and related documentation ("MediaTek Software") are * protected under relevant copyright laws. The information contained herein is * confidential and proprietary to MediaTek Inc. and/or its licensors. Without * the prior written permission of MediaTek inc. and/or its licensors, any * reproduction, modification, use or disclosure of MediaTek Software, and * information contained herein, in whole or in part, shall be strictly * prohibited. * * MediaTek Inc. (C) 2010. All rights reserved. * * BY OPENING THIS FILE, RECEIVER HEREBY UNEQUIVOCALLY ACKNOWLEDGES AND AGREES * THAT THE SOFTWARE/FIRMWARE AND ITS DOCUMENTATIONS ("MEDIATEK SOFTWARE") * RECEIVED FROM MEDIATEK AND/OR ITS REPRESENTATIVES ARE PROVIDED TO RECEIVER * ON AN "AS-IS" BASIS ONLY. MEDIATEK EXPRESSLY DISCLAIMS ANY AND ALL * WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED * WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR * NONINFRINGEMENT. NEITHER DOES MEDIATEK PROVIDE ANY WARRANTY WHATSOEVER WITH * RESPECT TO THE SOFTWARE OF ANY THIRD PARTY WHICH MAY BE USED BY, * INCORPORATED IN, OR SUPPLIED WITH THE MEDIATEK SOFTWARE, AND RECEIVER AGREES * TO LOOK ONLY TO SUCH THIRD PARTY FOR ANY WARRANTY CLAIM RELATING THERETO. * RECEIVER EXPRESSLY ACKNOWLEDGES THAT IT IS RECEIVER'S SOLE RESPONSIBILITY TO * OBTAIN FROM ANY THIRD PARTY ALL PROPER LICENSES CONTAINED IN MEDIATEK * SOFTWARE. MEDIATEK SHALL ALSO NOT BE RESPONSIBLE FOR ANY MEDIATEK SOFTWARE * RELEASES MADE TO RECEIVER'S SPECIFICATION OR TO CONFORM TO A PARTICULAR * STANDARD OR OPEN FORUM. RECEIVER'S SOLE AND EXCLUSIVE REMEDY AND MEDIATEK'S * ENTIRE AND CUMULATIVE LIABILITY WITH RESPECT TO THE MEDIATEK SOFTWARE * RELEASED HEREUNDER WILL BE, AT MEDIATEK'S OPTION, TO REVISE OR REPLACE THE * MEDIATEK SOFTWARE AT ISSUE, OR REFUND ANY SOFTWARE LICENSE FEES OR SERVICE * CHARGE PAID BY RECEIVER TO MEDIATEK FOR SUCH MEDIATEK SOFTWARE AT ISSUE. * * The following software/firmware and/or related documentation ("MediaTek * Software") have been modified by MediaTek Inc. All revisions are subject to * any receiver's applicable license agreements with MediaTek Inc. */ /* * Copyright (C) 2009 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.mediatek.cts.window; import dalvik.annotation.TestLevel; import dalvik.annotation.TestTargetClass; import dalvik.annotation.TestTargetNew; import dalvik.annotation.TestTargets; import dalvik.annotation.ToBeFixed; import android.content.Context; import android.hardware.Sensor; import android.hardware.SensorManager; import android.test.AndroidTestCase; import android.view.OrientationEventListener; /** * Test {@link OrientationEventListener}. */ @TestTargetClass(OrientationEventListener.class) public class OrientationEventListenerTest extends AndroidTestCase { @TestTargets({ @TestTargetNew( level = TestLevel.COMPLETE, method = "OrientationEventListener", args = {Context.class} ), @TestTargetNew( level = TestLevel.COMPLETE, method = "OrientationEventListener", args = {Context.class, int.class} ) }) public void testConstructor() { new MockOrientationEventListener(mContext); new MockOrientationEventListener(mContext, SensorManager.SENSOR_DELAY_UI); } @TestTargets({ @TestTargetNew( level = TestLevel.SUFFICIENT, notes = "Test {@link OrientationEventListener#enable()}. " + "This method is simply called to make sure that no exception is thrown. " + "The registeration of the listener can not be tested becuase there is " + "no way to simulate sensor events", method = "enable", args = {} ), @TestTargetNew( level = TestLevel.SUFFICIENT, notes = "Test {@link OrientationEventListener#disable()}. " + "This method is simply called to make sure that no exception is thrown. " + "The registeration of the listener can not be tested becuase there is " + "no way to simulate sensor events", method = "disable", args = {} ) }) @ToBeFixed(explanation = "Can not simulate sensor events on the emulator.") public void testEnableAndDisable() { MockOrientationEventListener listener = new MockOrientationEventListener(mContext); listener.enable(); listener.disable(); } @TestTargetNew( level = TestLevel.COMPLETE, method = "canDetectOrientation", args = {} ) public void testCanDetectOrientation() { SensorManager sm = (SensorManager)mContext.getSystemService(Context.SENSOR_SERVICE); // Orientation can only be detected if there is an accelerometer boolean hasSensor = (sm.getDefaultSensor(Sensor.TYPE_ACCELEROMETER) != null); MockOrientationEventListener listener = new MockOrientationEventListener(mContext); assertEquals(hasSensor, listener.canDetectOrientation()); } private static class MockOrientationEventListener extends OrientationEventListener { public MockOrientationEventListener(Context context) { super(context); } public MockOrientationEventListener(Context context, int rate) { super(context, rate); } @Override public void onOrientationChanged(int orientation) { } } }
[ "sunhouzan@163.com" ]
sunhouzan@163.com
8690fac626ced3224749e55ecc995b2d927be255
4dff754267c2fd9dec9d45b3daec26da1618eac1
/spectator-reg-tdigest/src/main/java/com/netflix/spectator/tdigest/TDigestWriter.java
29eb3a2015e84690d590b3353f641b1a2ac4dc62
[ "Apache-2.0" ]
permissive
lukaszPulawski/spectator
ea6592406fbbcd8db0d98333ba02ebca34c82d84
c0855ed1ef63b7c64941d0ca61f09750623f199b
refs/heads/master
2020-05-20T17:56:21.351209
2016-04-02T20:30:31
2016-04-02T20:30:31
null
0
0
null
null
null
null
UTF-8
Java
false
false
4,137
java
/** * Copyright 2015 Netflix, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://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.netflix.spectator.tdigest; import com.fasterxml.jackson.core.JsonGenerator; import com.netflix.spectator.api.Registry; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import java.io.IOException; import java.nio.ByteBuffer; import java.util.List; import java.util.Map; /** * Base-class for TDigestWriter implementations. This class will take care of mapping a set of * measurements into capped-size byte buffers. */ abstract class TDigestWriter implements AutoCloseable { private static final Logger LOGGER = LoggerFactory.getLogger(TDigestWriter.class); /** Kinesis has a 50k limit for the record size. */ static final int BUFFER_SIZE = 50000; /** * Minimum amount of free space for the buffer to try and write another measurement. If less * space is available, go ahead and flush the buffer. */ static final int MIN_FREE = 4096; private final ByteBuffer buf = ByteBuffer.allocate(BUFFER_SIZE); private final ByteBufferOutputStream out = new ByteBufferOutputStream(buf, 2); private final Json json; private final Map<String, String> commonTags; /** Create a new instance. */ TDigestWriter(Registry registry, TDigestConfig config) { this.json = new Json(registry); this.commonTags = config.getCommonTags(); } /** * Writes a buffer of data. * * @param buffer * Buffer to write to the underlying storage. The buffer will be setup so it is ready to * consume, i.e., position=0 and limit=N where N is the amount of data to write. No * guarantees are made about data in the remaining part of the buffer. The buffer will be * reused when this method returns. */ abstract void write(ByteBuffer buffer) throws IOException; /** * Write a list of measurements to some underlying storage. */ void write(List<TDigestMeasurement> measurements) throws IOException { JsonGenerator gen = json.newGenerator(out); gen.writeStartArray(); gen.flush(); int pos = buf.position(); for (TDigestMeasurement m : measurements) { json.encode(commonTags, m, gen); gen.flush(); if (out.overflow()) { // Ignore the last entry written to the buffer out.setPosition(pos); gen.writeEndArray(); gen.close(); write(buf); // Reuse the buffer and write the current entry out.reset(); gen = json.newGenerator(out); gen.writeStartArray(); json.encode(commonTags, m, gen); gen.flush(); // If a single entry is too big, then drop it if (out.overflow()) { LOGGER.warn("dropping measurement {}, serialized size exceeds the buffer cap", m.id()); out.reset(); gen = json.newGenerator(out); gen.writeStartArray(); gen.flush(); } pos = buf.position(); } else if (buf.remaining() < MIN_FREE) { // Not enough free-space, go ahead and write gen.writeEndArray(); gen.close(); write(buf); // Reuse the buffer out.reset(); gen = json.newGenerator(out); gen.writeStartArray(); gen.flush(); pos = buf.position(); } else { pos = buf.position(); } } // Write any data that is still in the buffer if (buf.position() > 1) { gen.writeEndArray(); gen.close(); write(buf); } } // This is needed to avoid issues with AutoCloseable.close throwing Exception @Override public void close() throws IOException { } }
[ "brharrington@gmail.com" ]
brharrington@gmail.com
c4cb5297d20ea6013f2a97bc417cf2286af0a42a
a363c46e7cbb080db2b3a69a70ebf912195e25c7
/ls-modules/ls-sys-web/src/main/java/cn/lonsun/dbimport/controller/DbImportController.java
cec3a94141213aa89175bcafc59d1339b81c62c0
[]
no_license
pologood/excms
601646dd7ea4f58f8423da007413978192090f8d
e1c03f574d0ecbf0200aaffa7facf93841bab02c
refs/heads/master
2020-05-14T20:07:22.979151
2018-10-06T10:51:37
2018-10-06T10:51:37
null
0
0
null
null
null
null
UTF-8
Java
false
false
5,232
java
package cn.lonsun.dbimport.controller; import cn.lonsun.core.base.controller.BaseController; import cn.lonsun.core.base.util.StringUtils; import cn.lonsun.dbimport.service.IImportService; import cn.lonsun.dbimport.service.base.PublicInfoImportService; import cn.lonsun.dbimport.service.impl.Ex7PublicContentImportService; import cn.lonsun.dbimport.util.ContentUrlUpdateUtil; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMethod; import org.springframework.web.bind.annotation.ResponseBody; import org.springframework.web.servlet.ModelAndView; import javax.annotation.Resource; import java.util.Queue; import java.util.concurrent.Callable; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; import java.util.concurrent.Future; @Controller @RequestMapping("dbimport") public class DbImportController extends BaseController { @Resource private IImportService ex7publicCatalogImportService; @Resource(name="ex7PublicContentImportService") private PublicInfoImportService ex7PublicContentImportService; @RequestMapping(method = RequestMethod.GET) public ModelAndView index(ModelAndView mv){ mv.setViewName("dbimport/index"); return mv; } @ResponseBody @RequestMapping("importCatalog") public Object importCatalog(){ ex7publicCatalogImportService.doImport(); return getObject(); } @ResponseBody @RequestMapping("importContent") public Object importContent(){ try { Object taskId = ex7PublicContentImportService.doImport(); return getObject(taskId); } catch (Exception e) { e.printStackTrace(); return ajaxErr("导入失败:" + e.getMessage()); } } /** * 根据目录id导入 * @param catId * @param ex8CatId * @param organId * @param ex8OrganId * @return */ @ResponseBody @RequestMapping("importContentByOrganCatId") public Object importContentByOrganCatId(Long catId, Long ex8CatId, Long organId, Long ex8OrganId){ try { ExecutorService executor = Executors.newCachedThreadPool(); ex7PublicContentImportService.doBefore(); Callable c = ex7PublicContentImportService.importDrivingPublic(catId, ex8CatId, organId, ex8OrganId); Future f = executor.submit(c); return getObject(f.get()); } catch (Exception e) { e.printStackTrace(); return ajaxErr("导入失败:" + e.getMessage()); } } @ResponseBody @RequestMapping("stopImport") public Object importContent(String taskId){ try { if(StringUtils.isEmpty(taskId)){ return ajaxErr("任务id不能为空"); } ex7PublicContentImportService.stopImport(taskId); return getObject(taskId); } catch (Exception e) { e.printStackTrace(); return ajaxErr("导入失败:" + e.getMessage()); } } @ResponseBody @RequestMapping("importOrgan") public Object importContent(Long organId){ try { // ex7PublicContentImportService.importOrgan(organId); } catch (Exception e) { e.printStackTrace(); return ajaxErr("导入失败:" + e.getMessage()); } return getObject(); } @ResponseBody @RequestMapping("revert") public Object revert(Long id){ ex7publicCatalogImportService.revert(id); return getObject(); } @ResponseBody @RequestMapping("getProcess") public Object getProcess(String taskId){ Queue<String> q = Ex7PublicContentImportService.importMsg.get(taskId); if(q == null || q.isEmpty()){ return getObject("任务不存在"); } return getObject(q); } @ResponseBody @RequestMapping("refreshConfig") public Object refreshConfig(){ try { ex7publicCatalogImportService.reloadConfig(); } catch (Exception e) { e.printStackTrace(); return ajaxErr("配置刷新失败:" + e.getMessage()); } return getObject(); } @ResponseBody @RequestMapping("updateContent") public Object updateContent(){ try { final ContentUrlUpdateUtil contentUrlUpdateUtil = new ContentUrlUpdateUtil(); new Thread(new Runnable() { @Override public void run() { contentUrlUpdateUtil.updateContent(".*href=\"/UploadFile/*", "/UploadFile/","/oldfiles/UploadFile/"); } }).start(); new Thread(new Runnable() { @Override public void run() { contentUrlUpdateUtil.updateContent(".*src=\"/UploadFile/*", "/UploadFile/","/oldfiles/UploadFile/"); } }).start(); } catch (Exception e) { e.printStackTrace(); return ajaxErr("配置刷新失败:" + e.getMessage()); } return getObject(); } }
[ "2885129077@qq.com" ]
2885129077@qq.com
fb6a8465186a5e82230774a57f6675ffed03543e
9049eabb2562cd3e854781dea6bd0a5e395812d3
/sources/com/google/android/gms/games/internal/player/StockProfileImageEntity.java
c532eb347f233747d5d3af9600538edfff412907
[]
no_license
Romern/gms_decompiled
4c75449feab97321da23ecbaac054c2303150076
a9c245404f65b8af456b7b3440f48d49313600ba
refs/heads/master
2022-07-17T23:22:00.441901
2020-05-17T18:26:16
2020-05-17T18:26:16
264,227,100
2
5
null
null
null
null
UTF-8
Java
false
false
3,111
java
package com.google.android.gms.games.internal.player; import android.net.Uri; import android.os.Parcel; import android.os.Parcelable; import com.google.android.gms.games.internal.GamesAbstractSafeParcelable; import java.util.Arrays; /* compiled from: :com.google.android.gms@201515033@20.15.15 (120300-306758586) */ public final class StockProfileImageEntity extends GamesAbstractSafeParcelable implements StockProfileImage { public static final Parcelable.Creator CREATOR = new aaev(); /* renamed from: a */ public final String f32654a; /* renamed from: b */ public final Uri f32655b; public StockProfileImageEntity(String str, Uri uri) { this.f32654a = str; this.f32655b = uri; } /* renamed from: a */ public final String mo19417a() { return this.f32654a; } /* renamed from: b */ public final Uri mo19418b() { return this.f32655b; } /* renamed from: bF */ public final /* bridge */ /* synthetic */ Object mo7556bF() { return this; } public final boolean equals(Object obj) { if (!(obj instanceof StockProfileImage)) { return false; } if (obj == this) { return true; } StockProfileImage stockProfileImage = (StockProfileImage) obj; return sdg.m34949a(this.f32654a, stockProfileImage.mo19417a()) && sdg.m34949a(this.f32655b, stockProfileImage.mo19418b()); } public final int hashCode() { return Arrays.hashCode(new Object[]{this.f32654a, this.f32655b}); } public final String toString() { sdf a = sdg.m34948a(this); a.mo25396a("ImageId", this.f32654a); a.mo25396a("ImageUri", this.f32655b); return a.toString(); } /* JADX DEBUG: Failed to find minimal casts for resolve overloaded methods, cast all args instead method: see.a(android.os.Parcel, int, java.lang.String, boolean):void arg types: [android.os.Parcel, int, java.lang.String, int] candidates: see.a(android.os.Parcel, int, android.os.Bundle, boolean):void see.a(android.os.Parcel, int, android.os.Parcel, boolean):void see.a(android.os.Parcel, int, java.math.BigDecimal, boolean):void see.a(android.os.Parcel, int, java.util.List, boolean):void see.a(android.os.Parcel, int, byte[], boolean):void see.a(android.os.Parcel, int, double[], boolean):void see.a(android.os.Parcel, int, float[], boolean):void see.a(android.os.Parcel, int, int[], boolean):void see.a(android.os.Parcel, int, long[], boolean):void see.a(android.os.Parcel, int, android.os.Parcelable[], int):void see.a(android.os.Parcel, int, java.lang.String[], boolean):void see.a(android.os.Parcel, int, boolean[], boolean):void see.a(android.os.Parcel, int, java.lang.String, boolean):void */ public final void writeToParcel(Parcel parcel, int i) { int a = see.m35030a(parcel); see.m35046a(parcel, 1, this.f32654a, false); see.m35040a(parcel, 2, this.f32655b, i, false); see.m35062b(parcel, a); } }
[ "roman.karwacik@rwth-aachen.de" ]
roman.karwacik@rwth-aachen.de
d915a6e127608ec70b83a4d9cc209f070a6578be
c5f229e53a784d850279b2a8f033cadb779233fe
/src/LearningAlgorithmInterestingly/chapter4/矩阵连乘问题.java
b26df38dd712213a2a49bfcaacfaad1035d1736c
[]
no_license
Git-zhoujunjie/JavaTest
6557e77fe3c1113b7fcb1d53f51d77a3b8d429f7
d7c7aec9c43ec48a092f4ec483bede4fc65cc0f9
refs/heads/master
2020-03-25T20:10:38.435784
2019-10-12T05:20:36
2019-10-12T05:20:36
144,119,343
0
0
null
null
null
null
UTF-8
Java
false
false
2,540
java
package LearningAlgorithmInterestingly.chapter4; /** * 问题描述:有n个矩阵A1A2A3A4...An,在矩阵中间加括号,使得矩阵连乘的乘法次数最少 * 动态规划算法解析: * 1、是否存在最优子结构(即子问题的最优解是否一定是总问题的最优解),可证得存在最优子结构 * 2、建立递归表达式:设m[i][j]表示Ai...Aj的连乘最优解,则有 * m[i][j] = 0, i==j * m[i][j] = min{m[i][k]+m[k+1][j]+p[i-1]p[k]p[j]}, i<=k<j * */ public class 矩阵连乘问题 { int n; //表示矩阵个数 int p[] ; //表示矩阵,因为相邻的矩阵必能相乘,所以第i个矩阵Am*n的行m存放在p[i]中,列n存放在p[i+1]中 int m[][] = new int[n+10][n+10]; //m[1][n]即表示我们要求的最优解 int s[][] = new int[n+10][n+10]; //用来存储分割的位置,m[i][j] = k表示在k处将矩阵分为(i,,k)和(k+1,,j)两部分 void dp(){ //初始化 for(int i=0;i<=n;i++){ for(int j=0;j<=n;j++){ m[i][j] = 0; //表示一个矩阵时不用加括号 } } for(int r=2;r<=n;r++){ //r表示规模,最开始从2个矩阵开始求解,然后依次求到最终解即r=n for(int i=1;i<=n-r+1;i++){ //i表示矩阵求解的起点,即上述中{i..k..j}的取值 int j = i+r-1; //j表示矩阵求解的终点,实际上可理解为i表示起点,r表示长度,求得终点j的值 //先设置最优解 m[i][j] = 99999; s[i][j] = 0; for(int k=i;k<j;k++){ //这实际上就是个遍历求解最小值的过程 int temp = m[i][k] + m[k+1][j] + p[i-1]*p[k]*p[j]; if(temp < m[i][j]){ m[i][j] = temp; //更新最小值 s[i][j] = k; } } } } } void print(int i,int j){ if(i==j){ System.out.print("A["+i+"]"); return; } System.out.print("("); print(i,s[i][j]); print(s[i][j]+1,j); System.out.print(")"); } void init(){ n = 5; int q[] = {3,5,10,8,2,4}; p = q; } public static void main(String[] args) { 矩阵连乘问题 test = new 矩阵连乘问题(); test.init(); test.dp(); System.out.println(test.m[1][test.n]); test.print(1,test.n); } }
[ "1160529743@qq.com" ]
1160529743@qq.com
e144e49ff1fe948aad21822599e49810967b5ec2
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/7/7_5100b9ccf13c876c5bfb66157f6685a1178e6340/HexFrame/7_5100b9ccf13c876c5bfb66157f6685a1178e6340_HexFrame_t.java
67ed17349f7745c92561934eb3802a0168c1a31d
[]
no_license
zhongxingyu/Seer
48e7e5197624d7afa94d23f849f8ea2075bcaec0
c11a3109fdfca9be337e509ecb2c085b60076213
refs/heads/master
2023-07-06T12:48:55.516692
2023-06-22T07:55:56
2023-06-22T07:55:56
259,613,157
6
2
null
2023-06-22T07:55:57
2020-04-28T11:07:49
null
UTF-8
Java
false
false
6,150
java
/* * Hex - a hex viewer and annotator * Copyright (C) 2009 Trejkaz, Hex Project * * 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 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see <http://www.gnu.org/licenses/>. */ package org.trypticon.hex.gui; import java.awt.BorderLayout; import java.awt.Toolkit; import java.awt.event.ActionEvent; import java.awt.event.KeyEvent; import java.io.File; import java.io.IOException; import javax.swing.AbstractAction; import javax.swing.Action; import javax.swing.JFileChooser; import javax.swing.JFrame; import javax.swing.JMenu; import javax.swing.JMenuBar; import javax.swing.JMenuItem; import javax.swing.JOptionPane; import javax.swing.JScrollPane; import javax.swing.KeyStroke; import javax.swing.ScrollPaneConstants; import javax.swing.TransferHandler; import org.trypticon.binary.Binary; import org.trypticon.binary.BinaryFactory; import org.trypticon.hex.datatransfer.DelegatingActionListener; import org.trypticon.hex.anno.AnnotationPane; import org.trypticon.hex.anno.MemoryAnnotationCollection; import org.trypticon.hex.HexViewer; /** * A top-level application frame. * * XXX: It probably makes sense to replace this with OpenIDE or some other framework. * * @author trejkaz */ public class HexFrame extends JFrame { private final HexViewer viewer; private AnnotationPane annoPane; /** * Constructs the top-level frame. */ public HexFrame() { super("Hex"); setJMenuBar(buildMenuBar()); viewer = new HexViewer(); annoPane = new AnnotationPane(); JScrollPane viewerScroll = new JScrollPane(viewer); viewerScroll.setVerticalScrollBarPolicy(ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS); getContentPane().setLayout(new BorderLayout()); getContentPane().add(viewerScroll, BorderLayout.CENTER); getContentPane().add(annoPane, BorderLayout.WEST); pack(); } /** * Loads a file into the viewer within this frame. * * @param file the file to load. */ public void loadFile(File file) { try { Binary binary = BinaryFactory.open(file); loadBinary(binary); } catch (IOException e) { JOptionPane.showMessageDialog(getRootPane(), "There was an error opening the file."); } } /** * Loads the specified binary into the viewer within this frame. * * @param binary the binary to open. */ public void loadBinary(Binary binary) { viewer.setBinary(binary); annoPane.setAnnotations(new MemoryAnnotationCollection()); } private JMenuBar buildMenuBar() { JMenu fileMenu = new JMenu("File"); fileMenu.add(new OpenAction()); if (!System.getProperty("os.name").toLowerCase().startsWith("mac")) { fileMenu.addSeparator(); fileMenu.add(new ExitAction()); } // TODO: Copy as: // - hex // - java source // - ? JMenu editMenu = new JMenu("Edit"); DelegatingActionListener actionListener = new DelegatingActionListener(); JMenuItem copyMenuItem = new JMenuItem("Copy"); copyMenuItem.setActionCommand((String) TransferHandler.getCopyAction().getValue(Action.NAME)); copyMenuItem.addActionListener(actionListener); copyMenuItem.setMnemonic('c'); copyMenuItem.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_C, Toolkit.getDefaultToolkit().getMenuShortcutKeyMask())); editMenu.add(copyMenuItem); JMenuItem selectAllMenuItem = new JMenuItem("Select All"); selectAllMenuItem.setActionCommand("select-all"); selectAllMenuItem.addActionListener(actionListener); selectAllMenuItem.setMnemonic('a'); selectAllMenuItem.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_A, Toolkit.getDefaultToolkit().getMenuShortcutKeyMask())); editMenu.add(selectAllMenuItem); JMenuBar menuBar = new JMenuBar(); menuBar.add(fileMenu); menuBar.add(editMenu); return menuBar; } /** * Sets initial focus, which is to move the focus to the viewer. */ public void initialFocus() { viewer.requestFocusInWindow(); } /** * Action to open a new file for viewing. */ private class OpenAction extends AbstractAction { private OpenAction() { putValue(NAME, "Open..."); putValue(MNEMONIC_KEY, (int) 'o'); putValue(ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_O, Toolkit.getDefaultToolkit().getMenuShortcutKeyMask())); } public void actionPerformed(ActionEvent event) { JFileChooser chooser = new JFileChooser(); if (chooser.showOpenDialog(getRootPane()) == JFileChooser.APPROVE_OPTION) { File file = chooser.getSelectedFile(); loadFile(file); } } } /** * Action to exit the application. */ private class ExitAction extends AbstractAction { private ExitAction() { putValue(NAME, "Exit"); putValue(MNEMONIC_KEY, (int) 'x'); } public void actionPerformed(ActionEvent event) { dispose(); } } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
3285505dc34bd7b9826ecdc7fffdffdfe63ef1d9
48e835e6f176a8ac9ae3ca718e8922891f1e5a18
/benchmark/training/org/hamcrest/MatcherAssertTest.java
1a8be612b877fc8e425ba412ec7efbf1215e0e18
[]
no_license
STAMP-project/dspot-experiments
f2c7a639d6616ae0adfc491b4cb4eefcb83d04e5
121487e65cdce6988081b67f21bbc6731354a47f
refs/heads/master
2023-02-07T14:40:12.919811
2019-11-06T07:17:09
2019-11-06T07:17:09
75,710,758
14
19
null
2023-01-26T23:57:41
2016-12-06T08:27:42
null
UTF-8
Java
false
false
2,668
java
package org.hamcrest; import org.hamcrest.core.IsEqual; import org.junit.Assert; import org.junit.Test; public final class MatcherAssertTest { @Test public void includesDescriptionOfTestedValueInErrorMessage() { String expected = "expected"; String actual = "actual"; String expectedMessage = "identifier\nExpected: \"expected\"\n but: was \"actual\""; try { MatcherAssert.assertThat("identifier", actual, IsEqual.equalTo(expected)); } catch (AssertionError e) { Assert.assertTrue(e.getMessage().startsWith(expectedMessage)); return; } Assert.fail("should have failed"); } @Test public void descriptionCanBeElided() { String expected = "expected"; String actual = "actual"; String expectedMessage = "\nExpected: \"expected\"\n but: was \"actual\""; try { MatcherAssert.assertThat(actual, IsEqual.equalTo(expected)); } catch (AssertionError e) { Assert.assertTrue(e.getMessage().startsWith(expectedMessage)); return; } Assert.fail("should have failed"); } @Test public void canTestBooleanDirectly() { MatcherAssert.assertThat("success reason message", true); try { MatcherAssert.assertThat("failing reason message", false); } catch (AssertionError e) { Assert.assertEquals("failing reason message", e.getMessage()); return; } Assert.fail("should have failed"); } @Test public void includesMismatchDescription() { Matcher<String> matcherWithCustomMismatchDescription = new BaseMatcher<String>() { @Override public boolean matches(Object item) { return false; } @Override public void describeTo(Description description) { description.appendText("Something cool"); } @Override public void describeMismatch(Object item, Description mismatchDescription) { mismatchDescription.appendText("Not cool"); } }; String expectedMessage = "\nExpected: Something cool\n but: Not cool"; try { MatcherAssert.assertThat("Value", matcherWithCustomMismatchDescription); Assert.fail("should have failed"); } catch (AssertionError e) { Assert.assertEquals(expectedMessage, e.getMessage()); } } @Test public void canAssertSubtypes() { MatcherAssert.assertThat(1, IsEqual.equalTo(((Number) (1)))); } }
[ "benjamin.danglot@inria.fr" ]
benjamin.danglot@inria.fr
9540d02fed3474f92c57bb7c1faeff2a29924029
d1a6d1e511df6db8d8dd0912526e3875c7e1797d
/genny_JavaWithoutLambdas/applicationModule/src/test/java/applicationModulepackageJava19/Foo721Test.java
175d275fa874dae3bca315cb545f2f31eef49224
[]
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 applicationModulepackageJava19; import org.junit.Test; public class Foo721Test { @Test public void testFoo0() { new Foo721().foo0(); } @Test public void testFoo1() { new Foo721().foo1(); } @Test public void testFoo2() { new Foo721().foo2(); } @Test public void testFoo3() { new Foo721().foo3(); } @Test public void testFoo4() { new Foo721().foo4(); } @Test public void testFoo5() { new Foo721().foo5(); } }
[ "nikita.e.kozlov@gmail.com" ]
nikita.e.kozlov@gmail.com
1068209636df5e9d9964478f29e6e6c278f6de1b
e080b641d9e12ed8346ea98cd245aa67d9955f40
/album/src/main/java/com/yanzhenjie/album/adapter/AlbumFolderAdapter.java
b41156188f3949d467a63b9e4e33c6d373bd789a
[ "Apache-2.0" ]
permissive
PrivacyStreams/Album
b4ad6c9b5d4f538d75caca14da4c319b135d1033
46e09ed453d35e8b0def19ec2ad94cfc21838c49
refs/heads/master
2021-01-19T10:22:38.310694
2017-05-09T20:46:39
2017-05-09T20:46:39
87,855,617
1
1
null
2017-04-10T20:40:41
2017-04-10T20:40:41
null
UTF-8
Java
false
false
4,665
java
/* * Copyright © Yan Zhenjie. All Rights Reserved * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.yanzhenjie.album.adapter; import android.content.res.ColorStateList; import android.support.v7.widget.AppCompatRadioButton; import android.support.v7.widget.RecyclerView; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.ImageView; import android.widget.TextView; import com.yanzhenjie.album.Album; import com.yanzhenjie.album.R; import com.yanzhenjie.album.entity.AlbumFolder; import com.yanzhenjie.album.entity.AlbumImage; import com.yanzhenjie.album.impl.OnCompatItemClickListener; import com.yanzhenjie.album.task.LocalImageLoader; import com.yanzhenjie.album.util.DisplayUtils; import java.util.List; /** * <p>BottomSheet dialog adapter, show all folder.</p> * Created by Yan Zhenjie on 2016/10/18. */ public class AlbumFolderAdapter extends RecyclerView.Adapter<AlbumFolderAdapter.FolderViewHolder> { private ColorStateList mButtonTint; private List<AlbumFolder> mAlbumFolders; private OnCompatItemClickListener mItemClickListener; private int checkPosition = 0; private static int size = DisplayUtils.dip2px(100); public AlbumFolderAdapter(ColorStateList buttonTint, List<AlbumFolder> mAlbumFolders, OnCompatItemClickListener mItemClickListener) { this.mButtonTint = buttonTint; this.mAlbumFolders = mAlbumFolders; this.mItemClickListener = mItemClickListener; } @Override public FolderViewHolder onCreateViewHolder(ViewGroup parent, int viewType) { return new FolderViewHolder(LayoutInflater.from(parent.getContext()).inflate(R.layout.album_item_dialog_folder, parent, false)); } @Override public void onBindViewHolder(FolderViewHolder holder, int position) { final int newPosition = holder.getAdapterPosition(); holder.setButtonTint(mButtonTint); holder.setData(mAlbumFolders.get(newPosition)); holder.itemView.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { AlbumFolder albumFolder = mAlbumFolders.get(newPosition); if (mItemClickListener != null) mItemClickListener.onItemClick(v, newPosition); if (!albumFolder.isChecked()) { albumFolder.setChecked(true); mAlbumFolders.get(checkPosition).setChecked(false); notifyItemChanged(checkPosition); notifyItemChanged(newPosition); checkPosition = newPosition; } } }); } @Override public int getItemCount() { return mAlbumFolders == null ? 0 : mAlbumFolders.size(); } static class FolderViewHolder extends RecyclerView.ViewHolder { private ImageView mIvImage; private TextView mTvTitle; private AppCompatRadioButton mRbCheck; public FolderViewHolder(View itemView) { super(itemView); mIvImage = (ImageView) itemView.findViewById(R.id.iv_gallery_preview_image); mTvTitle = (TextView) itemView.findViewById(R.id.tv_gallery_preview_title); mRbCheck = (AppCompatRadioButton) itemView.findViewById(R.id.rb_gallery_preview_check); } public void setButtonTint(ColorStateList colorStateList) { //noinspection RestrictedApi mRbCheck.setSupportButtonTintList(colorStateList); } public void setData(AlbumFolder albumFolder) { List<AlbumImage> albumImages = albumFolder.getImages(); mTvTitle.setText("(" + albumImages.size() + ") " + albumFolder.getName()); mRbCheck.setChecked(albumFolder.isChecked()); if (albumImages.size() > 0) { Album.getAlbumConfig().getImageLoader().loadImage(mIvImage, albumImages.get(0).getPath(), size, size); } else { mIvImage.setImageDrawable(LocalImageLoader.DEFAULT_DRAWABLE); } } } }
[ "smallajax@foxmail.com" ]
smallajax@foxmail.com
19d463dbe36cb311121a8fb927ed0b939efa0cf7
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/23/23_6ed7bec733fcbb0c571a097ec9aceb4c9be5007e/CacheManager/23_6ed7bec733fcbb0c571a097ec9aceb4c9be5007e_CacheManager_t.java
f3a746a10d2ed5ac2d7844acaa9fbc95b978cd85
[]
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
756
java
/* * HUMBOLDT: A Framework for Data Harmonisation and Service Integration. * EU Integrated Project #030962 01.10.2006 - 30.09.2010 * * For more information on the project, please refer to the this web site: * http://www.esdi-humboldt.eu * * LICENSE: For information on the license under which this program is * available, please refer to http:/www.esdi-humboldt.eu/license.html#core * (c) the HUMBOLDT Consortium, 2007 to 2010. */ package eu.esdihumboldt.hale.cache; public class CacheManager extends net.sf.ehcache.CacheManager{ protected void finalize() { super.shutdown(); } public static void flush(String cache) { net.sf.ehcache.CacheManager.getInstance().getCache(cache).flush(); } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
8cc3e59c1ea906c92c3960f9aba2aa80ddf29751
411f5af436691ef112ca66e28e2e3acd13f5942d
/samples/server/petstore/jaxrs-cxf-non-spring-app/src/gen/java/io/swagger/model/Amount.java
3912fdbfdf201c964dbc634c4f8b3eb8c22bca44
[ "Apache-2.0" ]
permissive
swagger-api/swagger-codegen
3e8326c45ba5cb5a73806150b3e1e6fe598e119a
0ba698d52d19e0cb79332bc13f20e02e00cedab7
refs/heads/master
2023-09-03T17:14:24.367082
2023-08-15T14:03:02
2023-08-15T14:03:02
2,006,876
16,415
7,319
Apache-2.0
2023-09-14T14:06:09
2011-07-06T14:26:48
Mustache
UTF-8
Java
false
false
2,248
java
package io.swagger.model; import io.swagger.annotations.ApiModel; import javax.validation.constraints.*; import javax.validation.Valid; import io.swagger.annotations.ApiModelProperty; import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.XmlRootElement; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlType; import javax.xml.bind.annotation.XmlEnum; import javax.xml.bind.annotation.XmlEnumValue; import com.fasterxml.jackson.annotation.JsonProperty; /** * some description **/ @ApiModel(description="some description ") public class Amount { @ApiModelProperty(required = true, value = "some description ") /** * some description **/ private Double value = null; @ApiModelProperty(required = true, value = "") private String currency = null; /** * some description * minimum: 0.01 * maximum: 1000000000000000 * @return value **/ @JsonProperty("value") @NotNull @DecimalMin("0.01") @DecimalMax("1000000000000000") public Double getValue() { return value; } public void setValue(Double value) { this.value = value; } public Amount value(Double value) { this.value = value; return this; } /** * Get currency * @return currency **/ @JsonProperty("currency") @NotNull @Pattern(regexp="^[A-Z]{3,3}$") public String getCurrency() { return currency; } public void setCurrency(String currency) { this.currency = currency; } public Amount currency(String currency) { this.currency = currency; return this; } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class Amount {\n"); sb.append(" value: ").append(toIndentedString(value)).append("\n"); sb.append(" currency: ").append(toIndentedString(currency)).append("\n"); sb.append("}"); return sb.toString(); } /** * Convert the given object to string with each line indented by 4 spaces * (except the first line). */ private static String toIndentedString(java.lang.Object o) { if (o == null) { return "null"; } return o.toString().replace("\n", "\n "); } }
[ "frantuma@yahoo.com" ]
frantuma@yahoo.com
7f6c834f610942fafb17093f6f42d27b21b19068
a39a970152df499304442ed47b21fd31d9c6e488
/src/main/java/com/wordpress/chhaichivon/helpers/BaseEntity.java
84718294fbf3c061a80e936aa5cfe6d71e265cc9
[]
no_license
chhai-chivon-springframework/spring-boot-jpa
0e6613826992979af8c7c0cad4807dd9dc596093
d032b71cace95585fe1387cf6e4c824eda1d983c
refs/heads/master
2021-01-01T18:16:45.633629
2017-07-26T10:29:32
2017-07-26T10:29:32
98,295,119
0
0
null
null
null
null
UTF-8
Java
false
false
398
java
package com.wordpress.chhaichivon.helpers; import lombok.Data; import javax.persistence.*; /** * AUTHOR : CHHAI CHIVON * EMAIL : chhaichivon1995@gmail.com * DATE : 7/25/2017 * TIME : 1:12 PM */ @Data @MappedSuperclass public class BaseEntity { @Id @GeneratedValue(strategy = GenerationType.AUTO) private final Long id; public BaseEntity() { id = null; } }
[ "chivonchhai@hotmail.com" ]
chivonchhai@hotmail.com
a1a2fdc3107ef7add6732f1c190b34ff0a8d0972
2ab03c4f54dbbb057beb3a0349b9256343b648e2
/javaadvanced/JAdvancedOldExams/JAdvancedExamRetake19022017/src/Shockwave.java
84acc9fe6dced8a83b9e82939fc4b7fe18d525b3
[ "MIT" ]
permissive
tabria/Java
8ef04c0ec5d5072d4e7bf15e372e7c2b600a1cea
9bfc733510b660bc3f46579a1cc98ff17fb955dd
refs/heads/master
2021-05-05T11:50:05.175943
2018-03-07T06:53:54
2018-03-07T06:53:54
104,714,168
0
1
null
null
null
null
UTF-8
Java
false
false
1,254
java
import java.util.Arrays; import java.util.Scanner; public class Shockwave { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); int[] roomDimensions = Arrays.stream(scanner.nextLine().split(" ")).mapToInt(Integer::parseInt).toArray(); int[][] room = new int[roomDimensions[0]][roomDimensions[1]]; while(true){ String coords = scanner.nextLine(); if ("Here We Go".equalsIgnoreCase(coords)){ break; } detectShockwaves(room, coords); } System.out.println(Arrays.deepToString(room).replace("], ", "\n") .replace("[", "") .replace("]", "") .replace(", ", " ")); } private static void detectShockwaves(int[][] room, String coords) { int[] rawCoords = Arrays.stream(coords.split(" ")).mapToInt(Integer::parseInt).toArray(); int startRow = rawCoords[0]; int startCol = rawCoords[1]; int endRow = rawCoords[2]; int endCol = rawCoords[3]; for (int i = startRow ; i <=endRow ; i++) { for (int j = startCol; j <=endCol ; j++) { room[i][j] += 1; } } } }
[ "forexftg@yahoo.com" ]
forexftg@yahoo.com
8980277c687c48d6e8468095ae3832f1866b54cf
1007cf13b771338fdb0e0b12e568549a722ae290
/src/com/github/clilystudio/leetcode/question/easy/Q0028.java
83fcabb727764e577d2a7dedca70debcb4b0073f
[ "Apache-2.0" ]
permissive
clilystudio/LeetCode_CN_Java
7f7ec9ff5da0bf12b5ec99aaea59ed8a1e23a3d7
2a1d6ddbef7b7f82959c477b8383ff09367d57fe
refs/heads/master
2020-04-29T01:21:39.230610
2019-03-18T08:12:19
2019-03-18T08:12:19
175,727,662
0
0
null
null
null
null
UTF-8
Java
false
false
1,864
java
/******************************************************************************* * Copyright 2019 ClilyStudio. * 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.github.clilystudio.leetcode.question.easy; /// ----------------------------------------------------------------------------- /// [28] 实现strStr() /// /// https://leetcode-cn.com/problems/implement-strstr/description/ /// /// 实现 strStr() 函数。 /// /// 给定一个 haystack 字符串和一个 needle 字符串,在 haystack 字符串中找出 needle 字符串出现的第一个位置 /// (从0开始)。如果不存在,则返回  -1。 /// /// 示例 1: /// /// 输入: haystack = "hello", needle = "ll" /// 输出: 2 /// /// 示例 2: /// /// 输入: haystack = "aaaaa", needle = "bba" /// 输出: -1 /// /// 说明: /// /// 当 needle 是空字符串时,我们应当返回什么值呢?这是一个在面试中很好的问题。 /// /// 对于本题而言,当 needle 是空字符串时我们应当返回 0 。这与C语言的 strstr() 以及 Java的 indexOf() 定义相符。 /// ----------------------------------------------------------------------------- public class Q0028 { public int strStr(String haystack, String needle) { // TODO return 0; } }
[ "bullsgl@gmail.com" ]
bullsgl@gmail.com
ba4ae67509449d801c1f2b31918a38d796215e5e
4c2e8b9d64dce94ec74fa2a4951a926f42db7f7a
/src/by/it/_examples_/jd02_02/Th2_05_with_synchro_ok.java
9a76c291f01a0f7276f59b4dd284b02c6e056132
[]
no_license
NorthDragons/JD2021-02-24
7ffa5d4fc6d0984563a0af192fc34b921327c52a
14bc46e536a1352dca08585ed03309e1e11e52e5
refs/heads/master
2023-04-01T16:44:33.325159
2021-04-23T14:59:25
2021-04-23T14:59:25
344,739,064
1
0
null
null
null
null
UTF-8
Java
false
false
1,462
java
package by.it._examples_.jd02_02; public class Th2_05_with_synchro_ok { //переменная баланса (так работать будет, но что тут плохо?) private final static Integer fakeBalance = 0; private static Integer balance = 0; //это касса. Просто добавляет в баланс единицу static class Cashier extends Thread { //создадим видимость расчета int calc() { for (int i = 0; i < 666; i++) i = i + (int) (Math.sqrt(i / 1234.567)); return 1; } @Override public void run() { synchronized (fakeBalance) { balance += (calc()); //fakeBalance++; //а вот так нельзя, поломаем, поле станет изменяемым } } } //создадим 4444 касс. Каждая добавит по 1. Сколько всего будет? public static void main(String[] args) { //Считаем сколько было потоков int thCount = Thread.activeCount(); for (int i = 0; i < 6666; i++) { new Cashier().start(); } //пока потоков больше, чем было в начале просто ждем while (Thread.activeCount() > thCount) Thread.yield(); System.out.print("Итого:" + balance); } }
[ "akhmelev@gmail.com" ]
akhmelev@gmail.com
e28f4fa738b0c36a6e18770f308d65eb10a14975
c3323b068ef682b07ce6b992918191a0a3781462
/open-metadata-implementation/adapters/open-connectors/repository-services-connectors/open-metadata-collection-store-connectors/igc-rest-connector/src/main/java/org/odpi/openmetadata/adapters/repositoryservices/igc/model/generated/v117/ParameterSet.java
d3b3d8a897496759932327011fa89e51b8bb3017
[ "Apache-2.0" ]
permissive
louisroehrs/egeria
897cb9b6989b1e176c39817b723f4b24de4b23ad
8045cc6a34ea87a4ea44b2f0992e09dff97c9714
refs/heads/master
2020-04-08T20:45:35.061405
2018-11-28T09:05:23
2018-11-28T09:05:23
null
0
0
null
null
null
null
UTF-8
Java
false
false
3,098
java
/* SPDX-License-Identifier: Apache-2.0 */ /* Copyright Contributors to the ODPi Egeria project. */ package org.odpi.openmetadata.adapters.repositoryservices.igc.model.generated.v117; import org.odpi.openmetadata.adapters.repositoryservices.igc.model.common.*; import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.Date; import java.util.ArrayList; /** * POJO for the 'parameter_set' asset type in IGC, displayed as 'Parameter Set' in the IGC UI. * <br><br> * (this code has been generated based on out-of-the-box IGC metadata types; * if modifications are needed, eg. to handle custom attributes, * extending from this class in your own custom class is the best approach.) */ @JsonIgnoreProperties(ignoreUnknown=true) public class ParameterSet extends MainObject { public static final String IGC_TYPE_ID = "parameter_set"; /** * The 'transformation_project' property, displayed as 'Transformation Project' in the IGC UI. * <br><br> * Will be a single {@link Reference} to a {@link TransformationProject} object. */ protected Reference transformation_project; /** * The 'jobs' property, displayed as 'Jobs' in the IGC UI. * <br><br> * Will be a {@link ReferenceList} of {@link Jobdef} objects. */ protected ReferenceList jobs; /** * The 'parameters' property, displayed as 'Parameters' in the IGC UI. * <br><br> * Will be a {@link ReferenceList} of {@link DsparameterSet} objects. */ protected ReferenceList parameters; /** * The 'in_collections' property, displayed as 'In Collections' in the IGC UI. * <br><br> * Will be a {@link ReferenceList} of {@link Collection} objects. */ protected ReferenceList in_collections; /** @see #transformation_project */ @JsonProperty("transformation_project") public Reference getTransformationProject() { return this.transformation_project; } /** @see #transformation_project */ @JsonProperty("transformation_project") public void setTransformationProject(Reference transformation_project) { this.transformation_project = transformation_project; } /** @see #jobs */ @JsonProperty("jobs") public ReferenceList getJobs() { return this.jobs; } /** @see #jobs */ @JsonProperty("jobs") public void setJobs(ReferenceList jobs) { this.jobs = jobs; } /** @see #parameters */ @JsonProperty("parameters") public ReferenceList getParameters() { return this.parameters; } /** @see #parameters */ @JsonProperty("parameters") public void setParameters(ReferenceList parameters) { this.parameters = parameters; } /** @see #in_collections */ @JsonProperty("in_collections") public ReferenceList getInCollections() { return this.in_collections; } /** @see #in_collections */ @JsonProperty("in_collections") public void setInCollections(ReferenceList in_collections) { this.in_collections = in_collections; } public static final Boolean isParameterSet(Object obj) { return (obj.getClass() == ParameterSet.class); } }
[ "chris@thegrotes.net" ]
chris@thegrotes.net
4fbbf02ceb94dd4fd44fbb16199a7dad98aadd66
4d097256155524879d6276f0060b04b166bf3b95
/yttv-system/src/main/java/com/ruoyi/system/domain/SysRoleDept.java
c03654d43b192112f9959e2f0d4eab127d1cf09c
[ "MIT" ]
permissive
IndigoCloud6/luna-platform
636107de916761ee2898ce5c8d1c8e93d91fa4bd
ec14117a50b26e58e81ad99eea73b2d211f3ece6
refs/heads/master
2023-05-29T00:59:25.683249
2021-01-13T14:50:48
2021-01-13T14:50:48
null
0
0
null
null
null
null
UTF-8
Java
false
false
864
java
package com.ruoyi.system.domain; import org.apache.commons.lang3.builder.ToStringBuilder; import org.apache.commons.lang3.builder.ToStringStyle; /** * 角色和部门关联 sys_role_dept * * @author luna */ public class SysRoleDept { /** 角色ID */ private Long roleId; /** 部门ID */ private Long deptId; public Long getRoleId() { return roleId; } public void setRoleId(Long roleId) { this.roleId = roleId; } public Long getDeptId() { return deptId; } public void setDeptId(Long deptId) { this.deptId = deptId; } @Override public String toString() { return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) .append("roleId", getRoleId()) .append("deptId", getDeptId()) .toString(); } }
[ "iszychen@gmail.com" ]
iszychen@gmail.com
ce5c0ad29ea634343c9ba651236066b1ce233942
4b13c1b4877bd9ced4352ab58b4aa890a06c2d60
/gwt-json-overlay/src/test/samples/com/webcohesion/enunciate/examples/gwt_json_overlay/schema/draw/Canvas.java
883e970167f96896c6da035254e25bb25c2c5597
[ "Apache-2.0" ]
permissive
stoicflame/enunciate
e1866a8be2e634d8c98adee853179b81df80a20e
446c86328a4eb6b7d1453fec7436c45552418d41
refs/heads/master
2023-09-04T19:24:44.788193
2023-04-28T00:36:40
2023-04-28T02:51:03
1,707,059
464
206
NOASSERTION
2023-08-15T17:40:53
2011-05-05T15:54:15
Java
UTF-8
Java
false
false
3,575
java
/** * Copyright © 2006-2016 Web Cohesion (info@webcohesion.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.webcohesion.enunciate.examples.gwt_json_overlay.schema.draw; import com.webcohesion.enunciate.examples.gwt_json_overlay.schema.Circle; import com.webcohesion.enunciate.examples.gwt_json_overlay.schema.Rectangle; import com.webcohesion.enunciate.examples.gwt_json_overlay.schema.Triangle; import com.webcohesion.enunciate.examples.gwt_json_overlay.schema.animals.Cat; import com.webcohesion.enunciate.examples.gwt_json_overlay.schema.structures.House; import com.webcohesion.enunciate.examples.gwt_json_overlay.schema.vehicles.Bus; import com.webcohesion.enunciate.examples.gwt_json_overlay.schema.Line; import javax.activation.DataHandler; import javax.xml.bind.annotation.*; import java.util.Collection; /** * @author Ryan Heaton */ @XmlRootElement public class Canvas { private Collection figures; private Collection shapes; private Collection<Line> lines; private int dimensionX; private int dimensionY; private DataHandler backgroundImage; private byte[] explicitBase64Attachment; private Collection<CanvasAttachment> otherAttachments; @XmlElementRefs ( { @XmlElementRef ( type = Circle.class ), @XmlElementRef ( type = Rectangle.class ), @XmlElementRef ( type = Triangle.class ) } ) public Collection getShapes() { return shapes; } public void setShapes(Collection shapes) { this.shapes = shapes; } @XmlElements ( { @XmlElement ( name="cat", type = Cat.class ), @XmlElement ( name="house", type = House.class ), @XmlElement ( name="bus", type = Bus.class ) } ) public Collection getFigures() { return figures; } public void setFigures(Collection figures) { this.figures = figures; } public Collection<Line> getLines() { return lines; } public void setLines(Collection<Line> lines) { this.lines = lines; } public int getDimensionX() { return dimensionX; } public void setDimensionX(int dimensionX) { this.dimensionX = dimensionX; } public int getDimensionY() { return dimensionY; } public void setDimensionY(int dimensionY) { this.dimensionY = dimensionY; } @XmlAttachmentRef public DataHandler getBackgroundImage() { return backgroundImage; } public void setBackgroundImage(DataHandler backgroundImage) { this.backgroundImage = backgroundImage; } @XmlInlineBinaryData public byte[] getExplicitBase64Attachment() { return explicitBase64Attachment; } public void setExplicitBase64Attachment(byte[] explicitBase64Attachment) { this.explicitBase64Attachment = explicitBase64Attachment; } @XmlElementWrapper ( name = "otherAttachments" ) @XmlElement ( name = "attachment" ) public Collection<CanvasAttachment> getOtherAttachments() { return otherAttachments; } public void setOtherAttachments(Collection<CanvasAttachment> otherAttachments) { this.otherAttachments = otherAttachments; } }
[ "ryan@webcohesion.com" ]
ryan@webcohesion.com
3941c49126b67234b829afd002d89fc1bdcb89ea
327d615dbf9e4dd902193b5cd7684dfd789a76b1
/base_source_from_JADX/sources/com/google/android/gms/internal/ads/zzcni.java
49d76dddbaffb2d6000cf774907392b914ceb189
[]
no_license
dnosauro/singcie
e53ce4c124cfb311e0ffafd55b58c840d462e96f
34d09c2e2b3497dd452246b76646b3571a18a100
refs/heads/main
2023-01-13T23:17:49.094499
2020-11-20T10:46:19
2020-11-20T10:46:19
314,513,307
0
0
null
null
null
null
UTF-8
Java
false
false
487
java
package com.google.android.gms.internal.ads; import java.util.concurrent.ScheduledExecutorService; public final class zzcni implements zzepf<zzcne> { public static zzcne zza(zzbuh zzbuh, zzdnn zzdnn, zzcmd zzcmd, zzdzc zzdzc, ScheduledExecutorService scheduledExecutorService, zzcpx zzcpx) { return new zzcne(zzbuh, zzdnn, zzcmd, zzdzc, scheduledExecutorService, zzcpx); } public final /* synthetic */ Object get() { throw new NoSuchMethodError(); } }
[ "dno_sauro@yahoo.it" ]
dno_sauro@yahoo.it
231b125ee6ed721f544c2763f6cb664575be00e5
51de3ea6616feb708169fc246dab6c8636c491f5
/result/com.beust.jcommander.WrappedParameter/traditional_mutants/void_addValue(com.beust.jcommander.Parameterized,java.lang.Object,java.lang.Object)/AOIS_3/WrappedParameter.java
021ddd7c2cdb688b0e63e35d10ca9d47f890b3b9
[ "Apache-2.0" ]
permissive
ps073006/main_mujava
ab442a597b514cc8491b8b5bd551e8e90e0aa5c6
c62f68d78c65d91f9dbf5a9a72df152cdda05a9d
refs/heads/master
2021-01-10T04:37:47.416163
2016-01-19T19:36:28
2016-01-19T19:36:28
49,980,696
0
0
null
null
null
null
UTF-8
Java
false
false
3,907
java
// This is a mutant program. // Author : ysma package com.beust.jcommander; import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; public class WrappedParameter { private com.beust.jcommander.Parameter m_parameter; private com.beust.jcommander.DynamicParameter m_dynamicParameter; public WrappedParameter( com.beust.jcommander.Parameter p ) { m_parameter = p; } public WrappedParameter( com.beust.jcommander.DynamicParameter p ) { m_dynamicParameter = p; } public com.beust.jcommander.Parameter getParameter() { return m_parameter; } public com.beust.jcommander.DynamicParameter getDynamicParameter() { return m_dynamicParameter; } public int arity() { return m_parameter != null ? m_parameter.arity() : 1; } public boolean hidden() { return m_parameter != null ? m_parameter.hidden() : m_dynamicParameter.hidden(); } public boolean required() { return m_parameter != null ? m_parameter.required() : m_dynamicParameter.required(); } public boolean password() { return m_parameter != null ? m_parameter.password() : false; } public java.lang.String[] names() { return m_parameter != null ? m_parameter.names() : m_dynamicParameter.names(); } public boolean variableArity() { return m_parameter != null ? m_parameter.variableArity() : false; } public java.lang.Class<? extends IParameterValidator> validateWith() { return m_parameter != null ? m_parameter.validateWith() : m_dynamicParameter.validateWith(); } public java.lang.Class<? extends IValueValidator> validateValueWith() { return m_parameter != null ? m_parameter.validateValueWith() : m_dynamicParameter.validateValueWith(); } public boolean echoInput() { return m_parameter != null ? m_parameter.echoInput() : false; } public void addValue( com.beust.jcommander.Parameterized parameterized, java.lang.Object object, java.lang.Object value ) { if (m_parameter != null) { parameterized.set( object, value ); } else { java.lang.String a = m_dynamicParameter.assignment(); java.lang.String sv = value.toString(); int aInd = sv.indexOf( a ); if (aInd++ == -1) { throw new com.beust.jcommander.ParameterException( "Dynamic parameter expected a value of the form a" + a + "b" + " but got:" + sv ); } callPut( object, parameterized, sv.substring( 0, aInd ), sv.substring( aInd + 1 ) ); } } private void callPut( java.lang.Object object, com.beust.jcommander.Parameterized parameterized, java.lang.String key, java.lang.String value ) { try { java.lang.reflect.Method m; m = findPut( parameterized.getType() ); m.invoke( parameterized.get( object ), key, value ); } catch ( java.lang.SecurityException e ) { e.printStackTrace(); } catch ( java.lang.IllegalAccessException e ) { e.printStackTrace(); } catch ( java.lang.reflect.InvocationTargetException e ) { e.printStackTrace(); } catch ( java.lang.NoSuchMethodException e ) { e.printStackTrace(); } } private java.lang.reflect.Method findPut( java.lang.Class<?> cls ) throws java.lang.SecurityException, java.lang.NoSuchMethodException { return cls.getMethod( "put", java.lang.Object.class, java.lang.Object.class ); } public java.lang.String getAssignment() { return m_dynamicParameter != null ? m_dynamicParameter.assignment() : ""; } public boolean isHelp() { return m_parameter != null && m_parameter.help(); } }
[ "engr.ps07@gmail.com" ]
engr.ps07@gmail.com
307f8badd129190c675c6b58c5f2017078bc3a8b
06b48521ee59d60d09ffa606aa8486ed8c77ec6f
/Doctors/src/main/java/com/arnold/doctors/dao/DoctorsDao.java
4e1d307631ad47f186a1c4ee381c200d54bc74d8
[]
no_license
arnoldvaz27/HealthCare
be9ec8108d317cc4bc09c3910d5522455d18283c
598d84694bbcf7cc66216b19a569f7237d3e2edf
refs/heads/master
2023-07-19T20:23:59.012568
2021-08-17T15:45:19
2021-08-17T15:45:19
391,890,954
0
0
null
null
null
null
UTF-8
Java
false
false
529
java
package com.arnold.doctors.dao; import androidx.room.Dao; import androidx.room.Delete; import androidx.room.Insert; import androidx.room.OnConflictStrategy; import androidx.room.Query; import com.arnold.doctors.entities.Doctors; import java.util.List; @Dao public interface DoctorsDao { @Query("SELECT * FROM doctors ORDER BY id DESC") List<Doctors> getAllDoctors(); @Insert(onConflict = OnConflictStrategy.REPLACE) void insertDoctor(Doctors doctors); @Delete void deleteDoctor(Doctors doctors); }
[ "arnoldvaz27.github@gmail.com" ]
arnoldvaz27.github@gmail.com
8e4e018d3490333a94d43807aa7e7eea79dd5d8f
be73270af6be0a811bca4f1710dc6a038e4a8fd2
/crash-reproduction-moho/results/XRENDERING-422-23-24-NSGA_II-LineCoverage:ExceptionType:StackTraceSimilarity/org/xwiki/rendering/wikimodel/xhtml/filter/AccumulationXMLFilter_ESTest.java
19b11022d19ab9badc52e39a1fd1370f9aa51241
[]
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
591
java
/* * This file was automatically generated by EvoSuite * Mon Apr 06 16:43:08 UTC 2020 */ package org.xwiki.rendering.wikimodel.xhtml.filter; import org.junit.Test; import static org.junit.Assert.*; import org.evosuite.runtime.EvoRunner; import org.evosuite.runtime.EvoRunnerParameters; import org.junit.runner.RunWith; @RunWith(EvoRunner.class) @EvoRunnerParameters(useVFS = true, useJEE = true) public class AccumulationXMLFilter_ESTest extends AccumulationXMLFilter_ESTest_scaffolding { @Test public void notGeneratedAnyTest() { // EvoSuite did not generate any tests } }
[ "pouria.derakhshanfar@gmail.com" ]
pouria.derakhshanfar@gmail.com
b3802f9e8f5deb430882f67cb77d0538c3ad41a9
8af1164bac943cef64e41bae312223c3c0e38114
/results-java/alibaba--druid/e4989a26cc61f679b5eaa08bd22ba0ce1810d8b9/after/OracleSelectTest43.java
d7876f6a5b6be820677cfae68b410571c327dbe4
[]
no_license
fracz/refactor-extractor
3ae45c97cc63f26d5cb8b92003b12f74cc9973a9
dd5e82bfcc376e74a99e18c2bf54c95676914272
refs/heads/master
2021-01-19T06:50:08.211003
2018-11-30T13:00:57
2018-11-30T13:00:57
87,353,478
0
0
null
null
null
null
UTF-8
Java
false
false
2,323
java
/* * Copyright 1999-2101 Alibaba Group Holding Ltd. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.alibaba.druid.bvt.sql.oracle.select; import java.util.List; import org.junit.Assert; import com.alibaba.druid.sql.OracleTest; import com.alibaba.druid.sql.ast.SQLStatement; import com.alibaba.druid.sql.dialect.oracle.parser.OracleStatementParser; import com.alibaba.druid.sql.dialect.oracle.visitor.OracleSchemaStatVisitor; public class OracleSelectTest43 extends OracleTest { public void test_0() throws Exception { String sql = // "SELECT * FROM table(t_department) " + // "WHERE name IN ('0000','4444') " + // "ORDER BY name ASC"; // OracleStatementParser parser = new OracleStatementParser(sql); List<SQLStatement> statementList = parser.parseStatementList(); SQLStatement statemen = statementList.get(0); print(statementList); Assert.assertEquals(1, statementList.size()); OracleSchemaStatVisitor visitor = new OracleSchemaStatVisitor(); statemen.accept(visitor); System.out.println("Tables : " + visitor.getTables()); System.out.println("fields : " + visitor.getColumns()); System.out.println("coditions : " + visitor.getConditions()); System.out.println("relationships : " + visitor.getRelationships()); System.out.println("orderBy : " + visitor.getOrderByColumns()); Assert.assertEquals(1, visitor.getTables().size()); Assert.assertEquals(1, visitor.getColumns().size()); // Assert.assertTrue(visitor.getColumns().contains(new TableStat.Column("acduser.vw_acd_info", "xzqh"))); // Assert.assertTrue(visitor.getOrderByColumns().contains(new TableStat.Column("employees", "last_name"))); } }
[ "fraczwojciech@gmail.com" ]
fraczwojciech@gmail.com
6b301a7186807083689781beb2745ed3b16d505f
6811fd178ae01659b5d207b59edbe32acfed45cc
/jira-project/jira-components/jira-core/src/main/java/com/atlassian/jira/issue/worklog/OfBizWorklogStore.java
00a9adddb9e51fce84e495f422654ca6a72a14d2
[]
no_license
xiezhifeng/mysource
540b09a1e3c62614fca819610841ddb73b12326e
44f29e397a6a2da9340a79b8a3f61b3d51e331d1
refs/heads/master
2023-04-14T00:55:23.536578
2018-04-19T11:08:38
2018-04-19T11:08:38
null
0
0
null
null
null
null
UTF-8
Java
false
false
7,052
java
package com.atlassian.jira.issue.worklog; import com.atlassian.core.util.collection.EasyList; import com.atlassian.core.util.map.EasyMap; import com.atlassian.jira.ComponentManager; import com.atlassian.jira.component.ComponentAccessor; import com.atlassian.jira.exception.DataAccessException; import com.atlassian.jira.issue.Issue; import com.atlassian.jira.issue.IssueManager; import com.atlassian.jira.ofbiz.OfBizDelegator; import org.ofbiz.core.entity.EntityCondition; import org.ofbiz.core.entity.EntityFieldMap; import org.ofbiz.core.entity.EntityOperator; import org.ofbiz.core.entity.GenericEntityException; import org.ofbiz.core.entity.GenericValue; import java.sql.Timestamp; import java.util.ArrayList; import java.util.Collections; import java.util.Date; import java.util.HashMap; import java.util.Iterator; import java.util.List; import java.util.Map; public class OfBizWorklogStore implements WorklogStore { private final OfBizDelegator ofBizDelegator; private final IssueManager issueManager; private WorklogManager worklogManager; public static final String WORKLOG_ENTITY = "Worklog"; public OfBizWorklogStore(OfBizDelegator ofBizDelegator, IssueManager issueManager) { this.ofBizDelegator = ofBizDelegator; this.issueManager = issueManager; } public Worklog update(Worklog worklog) { GenericValue worklogGV = ofBizDelegator.findById(WORKLOG_ENTITY, worklog.getId()); if (worklogGV == null) { throw new IllegalArgumentException("Could not find original worklog entity to update."); } worklogGV.setFields(createParamMap(worklog)); try { worklogGV.store(); } catch (GenericEntityException e) { throw new DataAccessException(e); } return convertToWorklog(worklog.getIssue(), worklogGV); } public Worklog create(Worklog worklog) { Map fields = createParamMap(worklog); GenericValue worklogGV = ofBizDelegator.createValue(WORKLOG_ENTITY, fields); return convertToWorklog(worklog.getIssue(), worklogGV); } public boolean delete(Long worklogId) { if(worklogId == null) { throw new IllegalArgumentException("Cannot remove a worklog with id null."); } int numRemoved = ofBizDelegator.removeByAnd(WORKLOG_ENTITY, EasyMap.build("id", worklogId)); return numRemoved == 1; } Map<String,Object> createParamMap(Worklog worklog) { if (worklog == null) { throw new IllegalArgumentException("Cannot store a null worklog."); } if (worklog.getIssue() == null) { throw new IllegalArgumentException("Cannot store a worklog against a null issue."); } Map<String,Object> fields = new HashMap<String,Object>(); fields.put("issue", worklog.getIssue().getId()); fields.put("author", worklog.getAuthorKey()); fields.put("updateauthor", worklog.getUpdateAuthorKey()); fields.put("body", worklog.getComment()); fields.put("grouplevel", worklog.getGroupLevel()); fields.put("rolelevel", worklog.getRoleLevelId()); fields.put("timeworked", worklog.getTimeSpent()); fields.put("startdate", new Timestamp(worklog.getStartDate().getTime())); fields.put("created", new Timestamp(worklog.getCreated().getTime())); fields.put("updated", new Timestamp(worklog.getUpdated().getTime())); return fields; } public Worklog getById(Long id) { Worklog worklog = null; GenericValue worklogGV = ofBizDelegator.findById(WORKLOG_ENTITY, id); if (worklogGV != null) { Issue issue = getIssueForId(worklogGV.getLong("issue")); worklog = convertToWorklog(issue, worklogGV); } return worklog; } public List<Worklog> getByIssue(Issue issue) { if (issue == null) { throw new IllegalArgumentException("Cannot resolve worklogs for null issue."); } List<GenericValue> worklogGVs = ofBizDelegator.findByAnd(WORKLOG_ENTITY, EasyMap.build("issue", issue.getId()), EasyList.build("created ASC")); List<Worklog> worklogs = new ArrayList<Worklog>(worklogGVs.size()); for (GenericValue worklogGV : worklogGVs) { worklogs.add(convertToWorklog(issue, worklogGV)); } return worklogs; } public int swapWorklogGroupRestriction(String groupName, String swapGroup) { if (groupName == null) { throw new IllegalArgumentException("You must provide a non null group name."); } if (swapGroup == null) { throw new IllegalArgumentException("You must provide a non null swap group name."); } return ofBizDelegator.bulkUpdateByAnd(WORKLOG_ENTITY, EasyMap.build("grouplevel", swapGroup), EasyMap.build("grouplevel", groupName)); } public long getCountForWorklogsRestrictedByGroup(String groupName) { if (groupName == null) { throw new IllegalArgumentException("You must provide a non null group name."); } EntityCondition condition = new EntityFieldMap(EasyMap.build("grouplevel", groupName), EntityOperator.AND); List worklogCount = ofBizDelegator.findByCondition("WorklogCount", condition, EasyList.build("count"), Collections.EMPTY_LIST); if (worklogCount != null && worklogCount.size() == 1) { GenericValue worklogCountGV = (GenericValue) worklogCount.get(0); return worklogCountGV.getLong("count"); } else { throw new DataAccessException("Unable to access the count for the Worklog table"); } } Worklog convertToWorklog(Issue issue, GenericValue gv) { Timestamp startDateTS = gv.getTimestamp("startdate"); Timestamp createdTS = gv.getTimestamp("created"); Timestamp updatedTS = gv.getTimestamp("updated"); return new WorklogImpl(getWorklogManager(), issue, gv.getLong("id"), gv.getString("author"), gv.getString("body"), startDateTS == null ? null : new Date(startDateTS.getTime()), gv.getString("grouplevel"), gv.getLong("rolelevel"), gv.getLong("timeworked"), gv.getString("updateauthor"), createdTS == null ? null : new Date(createdTS.getTime()), updatedTS == null ? null : new Date(updatedTS.getTime())); } Issue getIssueForId(Long issueId) { return issueManager.getIssueObject(issueId); } private WorklogManager getWorklogManager() { if (worklogManager == null) { worklogManager = ComponentAccessor.getComponentOfType(WorklogManager.class); } return worklogManager; } }
[ "moink635@gmail.com" ]
moink635@gmail.com
3f1d780ca8c4b587e00f1f3a676c378785f56720
082e26b011e30dc62a62fae95f375e4f87d9e99c
/docs/weixin_7.0.4_source/反编译源码/反混淆后/src/main/java/com/tencent/p177mm/plugin/wallet/pwd/p1049a/C22540o.java
585694b843360d2160fb3af07271985eafc644e4
[]
no_license
xsren/AndroidReverseNotes
9631a5aabc031006e795a112b7ac756a8edd4385
9202c276fe9f04a978e4e08b08e42645d97ca94b
refs/heads/master
2021-04-07T22:50:51.072197
2019-07-16T02:24:43
2019-07-16T02:24:43
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,169
java
package com.tencent.p177mm.plugin.wallet.pwd.p1049a; import com.tencent.matrix.trace.core.AppMethodBeat; import com.tencent.p177mm.plugin.wallet_core.model.C14264s; import com.tencent.p177mm.wallet_core.tenpay.model.C5749m; import java.util.HashMap; import java.util.Map; import org.json.JSONObject; /* renamed from: com.tencent.mm.plugin.wallet.pwd.a.o */ public final class C22540o extends C5749m { public C22540o(C14264s c14264s) { AppMethodBeat.m2504i(46198); HashMap hashMap = new HashMap(); HashMap hashMap2 = new HashMap(); hashMap.put("verify_code", c14264s.tCi); hashMap.put("token", c14264s.token); mo70324a(c14264s.pGr, (Map) hashMap, (Map) hashMap2); mo70323M(hashMap); mo70328ba(hashMap2); AppMethodBeat.m2505o(46198); } public final int bgI() { return 11; } /* renamed from: a */ public final void mo9383a(int i, String str, JSONObject jSONObject) { } /* renamed from: ZU */ public final int mo9382ZU() { return 470; } public final String getUri() { return "/cgi-bin/mmpay-bin/tenpay/resetpwdverify"; } }
[ "alwangsisi@163.com" ]
alwangsisi@163.com
7a5686de7d8ce37c064678a975cd2a53daa1e26d
493a8065cf8ec4a4ccdf136170d505248ac03399
/net.sf.ictalive.coordination.wfannotation.bpel.diagram.diagram/src/net/sf/ictalive/coordination/wfannotation/bpel/diagram/bpeldiag/diagram/edit/parts/IfIfCompartmentEditPart.java
4c51c13d23508b59cfc8083e8adda4fcfc34000c
[]
no_license
ignasi-gomez/aliveclipse
593611b2d471ee313650faeefbed591c17beaa50
9dd2353c886f60012b4ee4fe8b678d56972dff97
refs/heads/master
2021-01-14T09:08:24.839952
2014-10-09T14:21:01
2014-10-09T14:21:01
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,145
java
package net.sf.ictalive.coordination.wfannotation.bpel.diagram.bpeldiag.diagram.edit.parts; import net.sf.ictalive.coordination.wfannotation.bpel.diagram.bpeldiag.diagram.edit.policies.IfIfCompartmentCanonicalEditPolicy; import net.sf.ictalive.coordination.wfannotation.bpel.diagram.bpeldiag.diagram.edit.policies.IfIfCompartmentItemSemanticEditPolicy; import net.sf.ictalive.coordination.wfannotation.bpel.diagram.bpeldiag.diagram.part.Messages; import org.eclipse.draw2d.IFigure; import org.eclipse.gmf.runtime.diagram.ui.editparts.ShapeCompartmentEditPart; import org.eclipse.gmf.runtime.diagram.ui.editpolicies.CreationEditPolicy; import org.eclipse.gmf.runtime.diagram.ui.editpolicies.DragDropEditPolicy; import org.eclipse.gmf.runtime.diagram.ui.editpolicies.EditPolicyRoles; import org.eclipse.gmf.runtime.diagram.ui.figures.ResizableCompartmentFigure; import org.eclipse.gmf.runtime.notation.View; /** * @generated */ public class IfIfCompartmentEditPart extends ShapeCompartmentEditPart { /** * @generated */ public static final int VISUAL_ID = 7015; /** * @generated */ public IfIfCompartmentEditPart(View view) { super(view); } /** * @generated */ public String getCompartmentName() { return Messages.IfIfCompartmentEditPart_title; } /** * @generated */ public IFigure createFigure() { ResizableCompartmentFigure result = (ResizableCompartmentFigure) super .createFigure(); result.setTitleVisibility(false); return result; } /** * @generated */ protected void createDefaultEditPolicies() { super.createDefaultEditPolicies(); installEditPolicy(EditPolicyRoles.SEMANTIC_ROLE, new IfIfCompartmentItemSemanticEditPolicy()); installEditPolicy(EditPolicyRoles.CREATION_ROLE, new CreationEditPolicy()); installEditPolicy(EditPolicyRoles.DRAG_DROP_ROLE, new DragDropEditPolicy()); installEditPolicy(EditPolicyRoles.CANONICAL_ROLE, new IfIfCompartmentCanonicalEditPolicy()); } /** * @generated */ protected void setRatio(Double ratio) { // nothing to do -- parent layout does not accept Double constraints as ratio // super.setRatio(ratio); } }
[ "salvarez@lsi.upc.edu" ]
salvarez@lsi.upc.edu
b1de9aad0cb7b2a1fba87f0926f8bc046850e169
5d5cf83245936993f0f84321774fcf683957aed6
/jbpm-services/jbpm-shared-services/src/main/java/org/jbpm/shared/services/api/JbpmServicesTransactionManager.java
95b73a3436efd72c986c8dbfbc40f91457e7752d
[]
no_license
Agilone/jbpm
92d6c1a9adcba399aef48203c66e10678bfcd113
6f81d8eea5027aca84a2dcd7b8dc273d4de2ecb1
refs/heads/master
2021-01-15T19:27:29.056525
2013-03-25T11:44:52
2013-03-25T11:44:52
9,004,922
1
0
null
null
null
null
UTF-8
Java
false
false
1,374
java
/** * Copyright 2012 JBoss Inc * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://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.jbpm.shared.services.api; import javax.persistence.EntityManager; public interface JbpmServicesTransactionManager { public boolean begin(EntityManager em); public void commit(EntityManager em, boolean txOwner); /** * It is the responsibility of this method * to check that the status of the transaction * is appropriate before rolling back the transaction. * * @param em The persistence context (aka, the entity manager) * @param txOwner Whether or not the calling clause is owner of this transaction. */ public void rollback(EntityManager em, boolean txOwner); public int getStatus(EntityManager em); public void attachPersistenceContext(EntityManager em); public void dispose(); }
[ "salaboy@gmail.com" ]
salaboy@gmail.com
7b8285aa43870afe4ea7036a35677a290ab8b639
9c1b583175e0c41e7541300fb5342d3149a53c21
/PANKAJ/Pravin_ws/student-details/src/com/techlabs/student/test/StudentTest.java
ef6f7e377061bb0ce289b9dd788c0f35fa91aba1
[]
no_license
mohan08p/java_students
90c8da05f8ddd1834e1b4a23b3f1e0e2b0fd363f
edb069b962ceaf80c052336db36fc0bd8c3261dd
refs/heads/master
2021-01-25T14:11:11.782720
2018-01-29T08:56:09
2018-01-29T08:56:09
null
0
0
null
null
null
null
UTF-8
Java
false
false
364
java
package com.techlabs.student.test; import java.util.ArrayList; import java.util.List; import com.techlabs.student.Student; public class StudentTest { public static void main(String[] args) { List<Student> students = new ArrayList<Student>(); Student studentObject = new Student(); studentObject.putEntry(students); System.out.println(students); } }
[ "kannan@swabhavtechlabs.com" ]
kannan@swabhavtechlabs.com
e2ac6020c7c81807fa52752538a2141aea2646ed
02af99dd369b2b38531774812bdbe2772b470429
/src/com/prc/tt/algo/oms/Position.java
3925c3d29b157b51f25b10b1b195c9d28c81c126
[]
no_license
excelsiorsoft/messaging-gateway
4530abd9f9e04d447f8aefa2e707dbde1eb16f79
e88b7022285914c6f8bc620b93d84eda10ac0510
refs/heads/master
2021-01-22T04:53:43.514056
2015-05-05T15:49:42
2015-05-05T15:49:42
35,108,961
0
0
null
null
null
null
UTF-8
Java
false
false
1,179
java
package com.prc.tt.algo.oms; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import java.util.concurrent.Executors; import java.util.concurrent.ExecutorService; import com.prc.tt.utils.AePlayWave; import com.prc.tt.enums.ESide; import com.prc.tt.Instrument; public class Position { private static final Log log = LogFactory.getLog(Position.class); private static final ExecutorService exec =Executors.newSingleThreadExecutor(); private final Instrument instrument; private double WkQty = 0; private double Qty = 0; public Position(Instrument i) { this.instrument = i; } public synchronized double getWkQty() { return WkQty; } public synchronized void setWkQty(double q) { WkQty =q ; } public synchronized double getQty() { return Qty; } public synchronized void setQty(double q) { Qty = q; } public synchronized void addFillQty(double qty,ESide side) { double oldqty = Qty; Qty += side == ESide.BUY ? qty: -1*qty; WkQty -= qty; exec.execute( new AePlayWave(oldqty, Qty) ); } }
[ "senya22@yahoo.com" ]
senya22@yahoo.com
5bcfa6f6b517940f13e32f14116604a371a0d44d
199541cdfc086f96f903d5fa997a309f75333aac
/bukkit/MultiTexturedButtons/network/PacketMTB.java
3281304edfaf13fc7878fb3e87de4a1f65851e6e
[]
no_license
ali4z/Eury-s-Mods
2cce1615fd7412abc60c3c42e27eb2c6e8dab6d6
e79a5206910c55b785d09b28cb02b8af5a91873e
refs/heads/master
2021-01-15T20:28:14.731760
2012-05-07T20:05:41
2012-05-07T20:05:41
null
0
0
null
null
null
null
UTF-8
Java
false
false
329
java
package MultiTexturedButtons.network; import EurysMods.network.PacketUpdate; import MultiTexturedButtons.MultiTexturedButtons; public abstract class PacketMTB extends PacketUpdate { public PacketMTB(int var1) { super(var1); this.channel = MultiTexturedButtons.Core.getModChannel(); } }
[ "reflex_ion@hotmail.com" ]
reflex_ion@hotmail.com
12c4d43c391e43e86b40a01abe4309eff7f5ead0
b71673707e418dcbf869d0e53ef76f7ec7651ce1
/entity-view/testsuite/src/test/java/com/blazebit/persistence/view/testsuite/update/correlated/mutableonly/model/UpdatableDocumentView.java
103c0defd4ac91c1656e82b53166c6ec13ecd4d5
[ "Apache-2.0", "LicenseRef-scancode-unknown-license-reference" ]
permissive
Mobe91/blaze-persistence
bf92028028b241eb6a0a5f13dec323566f5ec9f8
8a4c867f07d6d31404d35e4db672b481fc8a2d59
refs/heads/master
2023-08-17T05:42:02.526696
2020-11-28T20:13:04
2020-11-28T20:13:04
83,560,399
0
0
NOASSERTION
2020-02-05T21:56:44
2017-03-01T13:59:01
Java
UTF-8
Java
false
false
1,885
java
/* * Copyright 2014 - 2020 Blazebit. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.blazebit.persistence.view.testsuite.update.correlated.mutableonly.model; import com.blazebit.persistence.testsuite.entity.Document; import com.blazebit.persistence.testsuite.entity.Person; import com.blazebit.persistence.view.CascadeType; import com.blazebit.persistence.view.EntityView; import com.blazebit.persistence.view.IdMapping; import com.blazebit.persistence.view.MappingCorrelatedSimple; import com.blazebit.persistence.view.UpdatableEntityView; import com.blazebit.persistence.view.UpdatableMapping; import java.util.Date; /** * * @author Christian Beikov * @since 1.3.0 */ @UpdatableEntityView @EntityView(Document.class) public interface UpdatableDocumentView { @IdMapping public Long getId(); public Long getVersion(); public String getName(); public void setName(String name); public Date getLastModified(); public void setLastModified(Date date); @UpdatableMapping(updatable = false, cascade = { CascadeType.UPDATE }) @MappingCorrelatedSimple(correlated = Person.class, correlationBasis = "responsiblePerson.id", correlationExpression = "id IN correlationKey") public UpdatablePersonView getResponsiblePerson(); public void setResponsiblePerson(UpdatablePersonView responsiblePerson); }
[ "christian.beikov@gmail.com" ]
christian.beikov@gmail.com
46d5fff4557a3e709cb4d13179a2da064741d0a3
37992a7083efea148c66381a2e7c988f59de712b
/chit/app/src/main/java/ru/ppr/chit/ui/activity/readbsqrcode/authInfoReader/network/AuthInfoEntity.java
176a14715e3b96b1416718bd58b8c27271d91f3a
[]
no_license
RVC3/PTK
5ab897d6abee1f7f7be3ba49c893b97e719085e9
1052b2bfa8f565c96a85d5c5928ed6c938a20543
refs/heads/master
2022-12-22T22:11:40.231298
2020-07-01T09:45:38
2020-07-01T09:45:38
259,278,530
0
0
null
null
null
null
UTF-8
Java
false
false
2,230
java
package ru.ppr.chit.ui.activity.readbsqrcode.authInfoReader.network; import com.google.gson.annotations.Expose; import com.google.gson.annotations.SerializedName; /** * @author Dmitry Nevolin */ class AuthInfoEntity { @Expose @SerializedName("BaseUri") private String baseUri; @Expose @SerializedName("AuthorizationCode") private String authorizationCode; @Expose @SerializedName("ClientId") private String clientId; @Expose @SerializedName("ClientSecret") private String clientSecret; @Expose @SerializedName("TerminalId") private Long terminalId; @Expose @SerializedName("BaseStationId") private Long baseStationId; @Expose @SerializedName("Thumbprint") private String thumbprint; @Expose @SerializedName("SerialNumber") private String serialNumber; public String getBaseUri() { return baseUri; } public void setBaseUri(String baseUri) { this.baseUri = baseUri; } public String getAuthorizationCode() { return authorizationCode; } public void setAuthorizationCode(String authorizationCode) { this.authorizationCode = authorizationCode; } public String getClientId() { return clientId; } public void setClientId(String clientId) { this.clientId = clientId; } public String getClientSecret() { return clientSecret; } public void setClientSecret(String clientSecret) { this.clientSecret = clientSecret; } public Long getTerminalId() { return terminalId; } public void setTerminalId(Long terminalId) { this.terminalId = terminalId; } public Long getBaseStationId() { return baseStationId; } public void setBaseStationId(Long baseStationId) { this.baseStationId = baseStationId; } public String getThumbprint() { return thumbprint; } public void setThumbprint(String thumbprint) { this.thumbprint = thumbprint; } public String getSerialNumber() { return serialNumber; } public void setSerialNumber(String serialNumber) { this.serialNumber = serialNumber; } }
[ "kopanevartem@mail.ru" ]
kopanevartem@mail.ru
d8dbed13a9fc80f5df391167d82933fa09cfb628
aac80d3591de0705c4012b49c3fa6f681a6b4a38
/src/main/java/net/darkhax/moreswords/enchantment/EnchantmentStealth.java
ea0228ffe401d0cadcbf65eb3f25bb98a02d77da
[]
no_license
gscalzo/More-Swords-3
7f97ca8dcc576651deeb6facca95ecb25ff15ec2
c02bb8c5e8d8527239223681499a4ed28e78f593
refs/heads/master
2021-01-15T11:45:33.748977
2014-11-21T19:25:13
2014-11-21T19:25:13
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,698
java
package net.darkhax.moreswords.enchantment; import net.minecraft.enchantment.Enchantment; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraftforge.common.MinecraftForge; import net.minecraftforge.event.entity.player.PlayerInteractEvent; import cpw.mods.fml.common.eventhandler.SubscribeEvent; public class EnchantmentStealth extends EnchantmentBase { protected EnchantmentStealth(int id, int weight, String unlocalizedName, int minLevel, int maxLevel, Item item) { super(id, weight, unlocalizedName, minLevel, maxLevel, item); MinecraftForge.EVENT_BUS.register(this); } /** * Sets the player invisible without the use of a potion effect. */ @SubscribeEvent public void onItemUsed(PlayerInteractEvent event) { if ((event.action.equals(PlayerInteractEvent.Action.RIGHT_CLICK_AIR))) { if (isValidPlayer(event.entityPlayer)) { ItemStack stack = event.entityPlayer.getHeldItem(); if (!event.entityPlayer.isInvisible()) { event.entityPlayer.setInvisible(true); } else event.entityPlayer.setInvisible(false); } } } @Override public boolean canApplyAtEnchantingTable(ItemStack stack) { return cfg.stealthVanilla; } @Override public boolean isAllowedOnBooks() { return cfg.stealthVanilla; } @Override public boolean canApply(ItemStack stack) { return cfg.stealthVanilla; } @Override public boolean canApplyTogether(Enchantment par1Enchantment) { return cfg.stealthVanilla; } }
[ "darklime@live.ca" ]
darklime@live.ca
d26089067d234ad7e76c6bb84543d62b49179c24
2e5ea9d0a943148d618d840545283ccd61673376
/ctsaj026/CoreJava/src/garbageCollectionProgram.java
cae1fbe3b5c72f66d4de98e90e5c69a03209c4e0
[]
no_license
shankar-trainer/cts_2021_1
708077efd781e502dec6ab68423a43dabc1713d3
f45ced520baf730652f7a2d59ba7dcd5cd4a150d
refs/heads/master
2023-04-22T22:12:32.655933
2021-05-04T03:48:22
2021-05-04T03:48:22
363,567,009
0
0
null
null
null
null
UTF-8
Java
false
false
741
java
public class garbageCollectionProgram { public static void main(String[] args) { String s[]=new String[1000000]; Runtime rt=Runtime.getRuntime(); System.out.println("before array initialisation"); System.out.println(rt.freeMemory()); System.out.println(rt.totalMemory()); for (int i = 0; i < s.length; i++) { s[i]=new String("hello world"); } System.out.println("after array initialisation"); System.out.println(rt.freeMemory()); System.out.println(rt.totalMemory()); for (int i = 0; i < s.length; i++) { s[i]=null; } rt.gc(); System.out.println("\nafter garbage collection called "); System.out.println(rt.freeMemory()); System.out.println(rt.totalMemory()); } }
[ "shankar7979@hotmail.com" ]
shankar7979@hotmail.com
e7cfb5734207af5bb60a013e58b40b576d66ea84
23f42b163c0a58ad61c38498befa1219f53a2c10
/src/main/java/weldstartup/b/AppScopedBean1404.java
037f9819acc6c7fb75a1b4750080a30dc09e4d1f
[]
no_license
99sono/wls-jsf-2-2-12-jersey-weldstartup-bottleneck
9637d2f14a1053159c6fc3c5898a91057a65db9d
b81697634cceca79f1b9a999002a1a02c70b8648
refs/heads/master
2021-05-15T17:54:39.040635
2017-10-24T07:27:23
2017-10-24T07:27:23
107,673,776
0
0
null
null
null
null
UTF-8
Java
false
false
1,630
java
package weldstartup.b; import javax.annotation.PostConstruct; import javax.annotation.PreDestroy; import javax.annotation.Resource; import javax.enterprise.context.ApplicationScoped; import javax.enterprise.inject.spi.BeanManager; import javax.inject.Inject; import javax.transaction.TransactionSynchronizationRegistry; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import weldstartup.nondynamicclasses.AppScopedNonDynamicBean; import weldstartup.nondynamicclasses.DependentScopedNonDynamicBean; import weldstartup.nondynamicclasses.RequestScopedNonDynamicBean; /** * A dynamically created CDI bean meant to demonstrate meant to demonstrate that the WeldStartup performance on weblogic * is really under-performing. * */ @ApplicationScoped // appScopedName will be turned into a name like AppScopedBean0001 public class AppScopedBean1404 { private static final Logger LOGGER = LoggerFactory.getLogger(AppScopedBean1404.class); @Inject AppScopedNonDynamicBean appScopedNonDynamicBean; @Inject DependentScopedNonDynamicBean rependentScopedNonDynamicBean; @Inject RequestScopedNonDynamicBean requestScopedNonDynamicBean; @Inject BeanManager beanManager; @Resource TransactionSynchronizationRegistry tsr; @PostConstruct public void postConstruct() { LOGGER.info("Post construct method invoked. AppScopedBean1404"); } @PreDestroy public void preDestroy() { LOGGER.info("Pre-destroy method invoked. AppScopedBean1404"); } public void dummyLogic() { LOGGER.info("Dummy logic invoked. AppScopedBean1404"); } }
[ "99sono@users.noreply.github.com" ]
99sono@users.noreply.github.com
dda759a3430aba1c21065a1ee2b2741efcf3d43a
9fe88de89c17a1ae00ac4757a3842624c243e2fb
/phpunit-converted/src/main/java/com/project/convertedCode/globalNamespace/namespaces/PHPUnit/namespaces/Util/classes/Filesystem.java
09c66d29ba63dc411ce3ee0ee04b28da1350d44c
[ "LicenseRef-scancode-warranty-disclaimer", "BSD-3-Clause" ]
permissive
RuntimeConverter/PHPUnit-Java-Converted
bccc849c0c88e8cda7b0e8a1d17883d37beb9f7a
0a036307ab56c8b787860ad25a74a17584218fda
refs/heads/master
2020-03-18T17:07:42.956039
2018-05-27T02:09:17
2018-05-27T02:09:17
135,008,061
1
0
null
null
null
null
UTF-8
Java
false
false
3,737
java
package com.project.convertedCode.globalNamespace.namespaces.PHPUnit.namespaces.Util.classes; import com.runtimeconverter.runtime.passByReference.PassByReferenceArgs; import com.runtimeconverter.runtime.classes.StaticBaseClass; import com.runtimeconverter.runtime.classes.RuntimeClassBase; import com.project.convertedCode.globalNamespace.NamespaceGlobal; import com.runtimeconverter.runtime.RuntimeEnv; import com.runtimeconverter.runtime.annotations.ConvertedMethod; import com.runtimeconverter.runtime.passByReference.RuntimeArgsWithReferences; import com.runtimeconverter.runtime.ZVal; import com.runtimeconverter.runtime.reflection.ReflectionClassData; import com.runtimeconverter.runtime.annotations.ConvertedParameter; import com.runtimeconverter.runtime.arrays.ZPair; import static com.runtimeconverter.runtime.ZVal.toStringR; import static com.runtimeconverter.runtime.ZVal.assignParameter; /* Converted with The Runtime Converter (runtimeconverter.com) vendor/phpunit/phpunit/src/Util/Filesystem.php */ public final class Filesystem extends RuntimeClassBase { public Filesystem(RuntimeEnv env, Object... args) { super(env); } public static final Object CONST_class = "PHPUnit\\Util\\Filesystem"; // Runtime Converter Internals // RuntimeStaticCompanion contains static methods // RequestStaticProperties contains static (per-request) properties // ReflectionClassData contains php reflection data used by the runtime library public static class RuntimeStaticCompanion extends StaticBaseClass { @ConvertedMethod @ConvertedParameter(index = 0, name = "className", typeHint = "string") public Object classNameToFilename(RuntimeEnv env, Object... args) { Object className = assignParameter(args, 0, null); return ZVal.assign( toStringR( NamespaceGlobal.str_replace .env(env) .addReferneceArgs(new RuntimeArgsWithReferences()) .call( ZVal.newArray( new ZPair(0, "_"), new ZPair(1, "\\")), "/", className) .value(), env) + ".php"); } } public static final RuntimeStaticCompanion runtimeStaticObject = new RuntimeStaticCompanion(); private static final ReflectionClassData runtimeConverterReflectionData = ReflectionClassData.builder() .setName("PHPUnit\\Util\\Filesystem") .setLookup(Filesystem.class, java.lang.invoke.MethodHandles.lookup()) .setLocalProperties() .setFilename("vendor/phpunit/phpunit/src/Util/Filesystem.php") .get(); @Override public ReflectionClassData getRuntimeConverterReflectionData() { return runtimeConverterReflectionData; } @Override public Object converterRuntimeCallExtended( RuntimeEnv env, String method, Class<?> caller, PassByReferenceArgs passByReferenceArgs, Object... args) { return RuntimeClassBase.converterRuntimeCallExtendedWithDataStatic( this, runtimeConverterReflectionData, env, method, caller, passByReferenceArgs, args); } }
[ "support@runtimeconverter.com" ]
support@runtimeconverter.com
58523d77593e7ebdef6ee81e28e90727bac6e854
b80d4ffb518166a57b29e6ae77388f7118280c86
/MyApplication/app/src/main/java/emergensor/sample002/myapplication/lib/FFT.java
61c6d879778a61c40c066462d997fae19bfd86e0
[]
no_license
MirrgieRiana/Emergensor
4b2c4a1fb2ac856ce0be39deadc5fbe6b6f8e034
b0f1a2ae74d1741cb83d862dc8590ddcb98b5502
refs/heads/master
2020-12-02T21:08:20.579211
2018-04-13T20:25:27
2018-04-13T20:25:27
96,260,760
2
2
null
2018-04-13T20:25:28
2017-07-05T00:11:49
Java
UTF-8
Java
false
false
2,288
java
package emergensor.sample002.myapplication.lib; public class FFT { private Complex[] input; private Complex[] output; private boolean inverse; private int length; public FFT(boolean inverse) { this.inverse = inverse; } public void setData(Complex[] data) { this.length = data.length; this.input = data; } public Complex[] getData() { return this.output; } public void execute() { this.output = new Complex[this.length]; if (!this.inverse) { fft(); } else { ifft(); } } private void fft() { int N = this.length; if (N == 1) { this.output = new Complex[]{this.input[0]}; } else { if (N % 2 != 0) { throw new RuntimeException("N is not a power of 2"); } Complex[] even = new Complex[N / 2]; for (int k = 0; k < N / 2; k++) { even[k] = this.input[(2 * k)]; } FFT fft = new FFT(false); fft.setData(even); fft.execute(); Complex[] q = fft.getData(); Complex[] odd = even; for (int k = 0; k < N / 2; k++) { odd[k] = this.input[(2 * k + 1)]; } fft = new FFT(false); fft.setData(odd); fft.execute(); Complex[] r = fft.getData(); for (int k = 0; k < N / 2; k++) { double kth = -2 * k * 3.141592653589793D / N; Complex wk = new Complex(Math.cos(kth), Math.sin(kth)); this.output[k] = q[k].plus(wk.times(r[k])); this.output[(k + N / 2)] = q[k].minus(wk.times(r[k])); } } } private void ifft() { int N = this.length; Complex[] val = new Complex[N]; for (int i = 0; i < N; i++) { val[i] = this.input[i].conjugate(); } FFT fft = new FFT(false); fft.setData(val); fft.execute(); val = fft.getData(); for (int i = 0; i < N; i++) { val[i] = val[i].conjugate(); } for (int i = 0; i < N; i++) { this.output[i] = val[i].times(1.0D / N); } } }
[ "tacticsrealize2@gmail.com" ]
tacticsrealize2@gmail.com
bfcaddf098b27138bd9f82f2e79d852064df1146
dbafd979fd02716644014db753e4875a4be9899f
/vertx-pin/zero-lbs/src/main/java/cn/vertxup/lbs/domain/tables/pojos/LCountry.java
67d6999f7fb95992128394ca56fe4930a13bda1a
[ "Apache-2.0", "LicenseRef-scancode-unknown-license-reference", "LicenseRef-scancode-warranty-disclaimer" ]
permissive
silentbalanceyh/vertx-zero-0.6
704a226038dec8c3c07983e7fb2129f9a2f50d39
ac9a62fac74ece44764138417aae42f965e0e2da
refs/heads/master
2023-08-13T13:41:54.860931
2021-10-18T10:00:17
2021-10-18T10:00:17
418,441,292
0
2
null
null
null
null
UTF-8
Java
false
true
7,497
java
/* * This file is generated by jOOQ. */ package cn.vertxup.lbs.domain.tables.pojos; import cn.vertxup.lbs.domain.tables.interfaces.ILCountry; import javax.annotation.Generated; import java.time.LocalDateTime; /** * This class is generated by jOOQ. */ @Generated( value = { "http://www.jooq.org", "jOOQ version:3.10.8" }, comments = "This class is generated by jOOQ" ) @SuppressWarnings({"all", "unchecked", "rawtypes"}) public class LCountry implements ILCountry { private static final long serialVersionUID = -1455849398; private String key; private String name; private String code; private String flag; private String phonePrefix; private String currency; private String metadata; private Integer order; private Boolean active; private String sigma; private String language; private LocalDateTime createdAt; private String createdBy; private LocalDateTime updatedAt; private String updatedBy; public LCountry() { } public LCountry(LCountry value) { this.key = value.key; this.name = value.name; this.code = value.code; this.flag = value.flag; this.phonePrefix = value.phonePrefix; this.currency = value.currency; this.metadata = value.metadata; this.order = value.order; this.active = value.active; this.sigma = value.sigma; this.language = value.language; this.createdAt = value.createdAt; this.createdBy = value.createdBy; this.updatedAt = value.updatedAt; this.updatedBy = value.updatedBy; } public LCountry( String key, String name, String code, String flag, String phonePrefix, String currency, String metadata, Integer order, Boolean active, String sigma, String language, LocalDateTime createdAt, String createdBy, LocalDateTime updatedAt, String updatedBy ) { this.key = key; this.name = name; this.code = code; this.flag = flag; this.phonePrefix = phonePrefix; this.currency = currency; this.metadata = metadata; this.order = order; this.active = active; this.sigma = sigma; this.language = language; this.createdAt = createdAt; this.createdBy = createdBy; this.updatedAt = updatedAt; this.updatedBy = updatedBy; } public LCountry(io.vertx.core.json.JsonObject json) { fromJson(json); } @Override public String getKey() { return this.key; } @Override public LCountry setKey(String key) { this.key = key; return this; } @Override public String getName() { return this.name; } @Override public LCountry setName(String name) { this.name = name; return this; } @Override public String getCode() { return this.code; } @Override public LCountry setCode(String code) { this.code = code; return this; } @Override public String getFlag() { return this.flag; } @Override public LCountry setFlag(String flag) { this.flag = flag; return this; } @Override public String getPhonePrefix() { return this.phonePrefix; } @Override public LCountry setPhonePrefix(String phonePrefix) { this.phonePrefix = phonePrefix; return this; } @Override public String getCurrency() { return this.currency; } @Override public LCountry setCurrency(String currency) { this.currency = currency; return this; } @Override public String getMetadata() { return this.metadata; } @Override public LCountry setMetadata(String metadata) { this.metadata = metadata; return this; } @Override public Integer getOrder() { return this.order; } @Override public LCountry setOrder(Integer order) { this.order = order; return this; } @Override public Boolean getActive() { return this.active; } @Override public LCountry setActive(Boolean active) { this.active = active; return this; } @Override public String getSigma() { return this.sigma; } @Override public LCountry setSigma(String sigma) { this.sigma = sigma; return this; } @Override public String getLanguage() { return this.language; } @Override public LCountry setLanguage(String language) { this.language = language; return this; } @Override public LocalDateTime getCreatedAt() { return this.createdAt; } @Override public LCountry setCreatedAt(LocalDateTime createdAt) { this.createdAt = createdAt; return this; } @Override public String getCreatedBy() { return this.createdBy; } @Override public LCountry setCreatedBy(String createdBy) { this.createdBy = createdBy; return this; } @Override public LocalDateTime getUpdatedAt() { return this.updatedAt; } @Override public LCountry setUpdatedAt(LocalDateTime updatedAt) { this.updatedAt = updatedAt; return this; } @Override public String getUpdatedBy() { return this.updatedBy; } @Override public LCountry setUpdatedBy(String updatedBy) { this.updatedBy = updatedBy; return this; } // ------------------------------------------------------------------------- // FROM and INTO // ------------------------------------------------------------------------- @Override public String toString() { StringBuilder sb = new StringBuilder("LCountry ("); sb.append(key); sb.append(", ").append(name); sb.append(", ").append(code); sb.append(", ").append(flag); sb.append(", ").append(phonePrefix); sb.append(", ").append(currency); sb.append(", ").append(metadata); sb.append(", ").append(order); sb.append(", ").append(active); sb.append(", ").append(sigma); sb.append(", ").append(language); sb.append(", ").append(createdAt); sb.append(", ").append(createdBy); sb.append(", ").append(updatedAt); sb.append(", ").append(updatedBy); sb.append(")"); return sb.toString(); } /** * {@inheritDoc} */ @Override public void from(ILCountry from) { setKey(from.getKey()); setName(from.getName()); setCode(from.getCode()); setFlag(from.getFlag()); setPhonePrefix(from.getPhonePrefix()); setCurrency(from.getCurrency()); setMetadata(from.getMetadata()); setOrder(from.getOrder()); setActive(from.getActive()); setSigma(from.getSigma()); setLanguage(from.getLanguage()); setCreatedAt(from.getCreatedAt()); setCreatedBy(from.getCreatedBy()); setUpdatedAt(from.getUpdatedAt()); setUpdatedBy(from.getUpdatedBy()); } /** * {@inheritDoc} */ @Override public <E extends ILCountry> E into(E into) { into.from(this); return into; } }
[ "silentbalanceyh@126.com" ]
silentbalanceyh@126.com
fa8a6e6e1b1b9caa0cbd36280d6efaebb14bf02d
b3f6daa5d6c987eb8a61d5fe125bf2a98997e259
/beta/Longest Word/Kata.java
874181ff70f64337c50a83c1653800a0c8c5e187
[]
no_license
krnets/codewars-practice
53a0a6c9d2d8c2b94d6799a12f48dd588179a5ce
5f8e1cc1aebd900b9e5a276884419fc3e1ddef24
refs/heads/master
2022-12-20T19:33:43.337581
2022-12-16T05:32:39
2022-12-16T05:32:39
217,464,785
1
0
null
2020-07-20T08:36:31
2019-10-25T06:20:41
JavaScript
UTF-8
Java
false
false
561
java
/* When given a string of space separated words, return the word with the longest length. If there are multiple words with the longest length, return the last instance of the word with the longest length. 'red white blue' //returns string value of white 'red blue gold' //returns gold */ import java.util.Arrays; public class Kata { public static String longestWord(String wordString) { return Arrays.stream(wordString.split(" ")) .reduce("", (prev, curr) -> prev.length() <= curr.length() ? curr : prev); } }
[ "cmantheo@gmail.com" ]
cmantheo@gmail.com
b6adc8ce993325daec3f1a8567c9542f519a0d49
0a7f90d7fedc98894aaedfd4eef0359a1c3537cc
/src/jean/nucleic/NucleicAcid.java
c338870771490657c0b6ee8c956d014d2d0263a7
[ "Apache-2.0" ]
permissive
tipplerow/jean
58a29e589f6ee879e9f1ea68faad49e77416e9aa
bd39b3a209bf9d78b89ea4c133f6b6669006cde3
refs/heads/master
2022-12-15T06:25:12.547819
2020-08-31T13:20:58
2020-08-31T13:20:58
289,964,877
0
0
null
null
null
null
UTF-8
Java
false
false
5,655
java
package jean.nucleic; import java.io.File; import java.util.ArrayList; import java.util.Collection; import java.util.Collections; import java.util.Iterator; import java.util.List; import jam.io.LineReader; import jam.lang.JamException; import jean.fasta.FastaReader; /** * Defines a fixed linear sequence of nucleotides. */ public abstract class NucleicAcid implements Iterable<Nucleotide> { private final List<Nucleotide> nucleotides; /** * Creates a new (empty) nucleic acid: the concrete subclass must * assign the nucleotides. */ protected NucleicAcid() { this.nucleotides = new ArrayList<Nucleotide>(); } /** * Creates a new (empty) nucleic acid with a known capacity: the * concrete subclass must assign the nucleotides. * * @param capacity the expected number of nucleotides. */ protected NucleicAcid(int capacity) { this.nucleotides = new ArrayList<Nucleotide>(capacity); } /** * Adds a nucleotide to this nucleic acid. * * @param nucleotide the nucleotide to add. * * @throws IllegalArgumentException unless the nucleotide is * permitted in this nucleic acid. */ protected void add(Nucleotide nucleotide) { validate(nucleotide); nucleotides.add(nucleotide); } /** * Adds a collection of nucleotides to this nucleic acid. * * @param nucleotides the nucleotides to add. * * @throws IllegalArgumentException unless all nucleotides are * permitted in this nucleic acid. */ protected void add(Collection<Nucleotide> nucleotides) { for (Nucleotide nucleotide : nucleotides) add(nucleotide); } /** * Assigns the nucleotide sequence for this nucleic acid from a * string representation containing single-character nucleotide * codes. * * @param s a sequence of single-character nucleotide codes. * * @throws IllegalArgumentException unless the input string is a * valid nucleic acid representation. * * @throws IllegalStateException if any nucleotides have already * been assigned. */ protected void parseString(String s) { if (!nucleotides.isEmpty()) throw new IllegalStateException("Nucleotides have already been assigned."); addString(s); } private void addString(String s) { for (int k = 0; k < s.length(); ++k) add(Nucleotide.valueOf(s.charAt(k))); } /** * Assigns the nucleotide sequence for this nucleic acid by * reading the sequence from a FASTA file. * * <p>The first line of the FASTA file must be a header line * (which is ignored). All remaining lines must contain the * nucleotide sequence. * * @param file the FASTA file to parse. * * @throws RuntimeException unless the FASTA file contains a valid * nucleic acid representation. * * @throws IllegalStateException if any nucleotides have already * been assigned. */ protected void parseFASTA(File file) { if (!nucleotides.isEmpty()) throw new IllegalStateException("Nucleotides have already been assigned."); LineReader reader = LineReader.open(file); try { String header = reader.next(); if (!FastaReader.isHeaderLine(header)) throw JamException.runtime("Missing header line."); for (String line : reader) if (FastaReader.isHeaderLine(line)) throw JamException.runtime("Unexpected header line."); else addString(line); } finally { reader.close(); } } /** * Tests whether this nucleic acid may contain a given nucleotide. * * @param nucleotide the nucleotide to test. * * @throws IllegalArgumentException unless the specified * nucleotide may reside in this nucleic acid. */ protected abstract void validate(Nucleotide nucleotide); /** * Returns the nucleotide at a specified location. * * @param index the index of the desired location. * * @return the nucleotide at the specified location. * * @throws IndexOutOfBoundsException unless the index is valid. */ public Nucleotide at(int index) { return nucleotides.get(index); } /** * Returns the number of nucleotides in this nucleic acid. * * @return the number of nucleotides in this nucleic acid. */ public int length() { return nucleotides.size(); } /** * Returns a read-only view of the nucleotides in this nucleic acid. * * @return a read-only view of the nucleotides in this nucleic acid. */ public List<Nucleotide> viewNucleotides() { return Collections.unmodifiableList(nucleotides); } /** * Formats the nucleotides in this nucleic acid into a string of * single-character codes. * * @return the nucleotides in this nucleic acid as string of * single-character codes. */ public String formatString() { StringBuilder builder = new StringBuilder(); for (Nucleotide nucleotide : nucleotides) builder.append(nucleotide.name()); return builder.toString(); } @Override public Iterator<Nucleotide> iterator() { return viewNucleotides().iterator(); } @Override public String toString() { return String.format("%s(%s)", getClass().getSimpleName(), formatString()); } }
[ "jsshaff@berkeley.edu" ]
jsshaff@berkeley.edu
f9fc6110c40b841489417394878cb50c5d27a080
332ff83ea2edc4a6a6c2168104a1c24468f0ecd5
/src/main/java/dependency_injection/journaldev/MessengerInjector.java
5335dfe29f75290079233376e11ea3338888d9af
[]
no_license
MichalGuz/java-basics
f38955fc9655b46a811fae6d38e921b4e0401ff3
29a92cf898d445b72ee661bc20cecc51d9f352eb
refs/heads/master
2021-06-10T22:12:30.694173
2021-05-19T21:08:53
2021-05-19T21:08:53
188,738,882
1
0
null
null
null
null
UTF-8
Java
false
false
222
java
package dependency_injection.journaldev; public class MessengerInjector implements SocialMediaServiceInjector { @Override public Executor execute() { return new Application(new MessengerService()); } }
[ "michalguz@gmail.com" ]
michalguz@gmail.com
937467133f665d11bc73d0b4600eb91034421aa3
942a403f2de78ada035fd31929786b5e5e7615a7
/src/main/java/com/armelift/helios/service/InvalidPasswordException.java
7677ea49efcf9028d6fc974eee504198f9bc8dfa
[]
no_license
armelift/jhipster-helios-application
80da48de086d8bcdef326e13db4773160dcdd4bf
aa5dc7a26c8571bf2d2e9e45c065c1801626c204
refs/heads/main
2023-01-30T21:12:49.522888
2020-12-17T09:46:02
2020-12-17T09:46:02
322,248,976
0
0
null
null
null
null
UTF-8
Java
false
false
242
java
package com.armelift.helios.service; public class InvalidPasswordException extends RuntimeException { private static final long serialVersionUID = 1L; public InvalidPasswordException() { super("Incorrect password"); } }
[ "jhipster-bot@jhipster.tech" ]
jhipster-bot@jhipster.tech
3ba94cacfcee7464fa191a694256098877b09dac
6dbae30c806f661bcdcbc5f5f6a366ad702b1eea
/Corpus/eclipse.jdt.ui/7848.java
211da0ed758b9302d1555195e3470b37f52c52aa
[ "MIT" ]
permissive
SurfGitHub/BLIZZARD-Replication-Package-ESEC-FSE2018
d3fd21745dfddb2979e8ac262588cfdfe471899f
0f8f4affd0ce1ecaa8ff8f487426f8edd6ad02c0
refs/heads/master
2020-03-31T15:52:01.005505
2018-10-01T23:38:50
2018-10-01T23:38:50
152,354,327
1
0
MIT
2018-10-10T02:57:02
2018-10-10T02:57:02
null
UTF-8
Java
false
false
267
java
package p; public class ComplexExtractParameter { public int test; public int test2; public int test3; public int test4; public ComplexExtractParameter(int test2, int test4) { this.test2 = test2; this.test4 = test4; } }
[ "masudcseku@gmail.com" ]
masudcseku@gmail.com
2eec4657f754c535038fb02ab04cb8ecbed67aba
8af1164bac943cef64e41bae312223c3c0e38114
/results-java/square--picasso/aef01ed7565a88392e4bb32d8deb986aab6d0177/after/SampleAdapter.java
d6573824de5fd915db68c0bc125b86678f412fbc
[]
no_license
fracz/refactor-extractor
3ae45c97cc63f26d5cb8b92003b12f74cc9973a9
dd5e82bfcc376e74a99e18c2bf54c95676914272
refs/heads/master
2021-01-19T06:50:08.211003
2018-11-30T13:00:57
2018-11-30T13:00:57
87,353,478
0
0
null
null
null
null
UTF-8
Java
false
false
5,563
java
package com.squareup.picasso.sample; import android.content.Context; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.BaseAdapter; import android.widget.ImageView; import android.widget.TextView; import com.squareup.picasso.Picasso; public class SampleAdapter extends BaseAdapter { private final Context context; private final LayoutInflater inflater; public SampleAdapter(Context context) { this.context = context; this.inflater = LayoutInflater.from(context); } @Override public int getCount() { return URLS.length; } @Override public String getItem(int position) { return URLS[position]; } @Override public long getItemId(int position) { return position; } @Override public View getView(int position, View convertView, ViewGroup parent) { Holder holder; if (convertView != null) { holder = (Holder) convertView.getTag(); } else { holder = new Holder(); convertView = inflater.inflate(R.layout.list_item, parent, false); convertView.setTag(holder); holder.image = (ImageView) convertView.findViewById(R.id.image); holder.name = (TextView) convertView.findViewById(R.id.name); } // Get the image URL for the current position. String url = getItem(position); // Set the URL into the text field. holder.name.setText(url); // Trigger the download of the URL asynchronously into the image view. Picasso.with(context) // .load(url) // .placeholder(R.drawable.placeholder) // .error(R.drawable.error) // .into(holder.image); return convertView; } private static class Holder { ImageView image; TextView name; } private static final String BASE = "http://upload.wikimedia.org/wikipedia/commons/thumb"; private static final String[] URLS = { BASE + "/5/5c/Flag_of_Alabama.svg/200px-Flag_of_Alabama.svg.png", BASE + "/e/e6/Flag_of_Alaska.svg/200px-Flag_of_Alaska.svg.png", BASE + "/9/9d/Flag_of_Arizona.svg/200px-Flag_of_Arizona.svg.png", BASE + "/9/9d/Flag_of_Arkansas.svg/200px-Flag_of_Arkansas.svg.png", BASE + "/0/01/Flag_of_California.svg/200px-Flag_of_California.svg.png", BASE + "/4/46/Flag_of_Colorado.svg/200px-Flag_of_Colorado.svg.png", BASE + "/9/96/Flag_of_Connecticut.svg/200px-Flag_of_Connecticut.svg.png", BASE + "/c/c6/Flag_of_Delaware.svg/200px-Flag_of_Delaware.svg.png", BASE + "/f/f7/Flag_of_Florida.svg/200px-Flag_of_Florida.svg.png", BASE + "/e/ef/Flag_of_Hawaii.svg/200px-Flag_of_Hawaii.svg.png", BASE + "/a/a4/Flag_of_Idaho.svg/200px-Flag_of_Idaho.svg.png", BASE + "/0/01/Flag_of_Illinois.svg/200px-Flag_of_Illinois.svg.png", BASE + "/a/ac/Flag_of_Indiana.svg/200px-Flag_of_Indiana.svg.png", BASE + "/a/aa/Flag_of_Iowa.svg/200px-Flag_of_Iowa.svg.png", BASE + "/d/da/Flag_of_Kansas.svg/200px-Flag_of_Kansas.svg.png", BASE + "/8/8d/Flag_of_Kentucky.svg/200px-Flag_of_Kentucky.svg.png", BASE + "/e/e0/Flag_of_Louisiana.svg/200px-Flag_of_Louisiana.svg.png", BASE + "/3/35/Flag_of_Maine.svg/200px-Flag_of_Maine.svg.png", BASE + "/a/a0/Flag_of_Maryland.svg/200px-Flag_of_Maryland.svg.png", BASE + "/f/f2/Flag_of_Massachusetts.svg/200px-Flag_of_Massachusetts.svg.png", BASE + "/b/b5/Flag_of_Michigan.svg/200px-Flag_of_Michigan.svg.png", BASE + "/b/b9/Flag_of_Minnesota.svg/200px-Flag_of_Minnesota.svg.png", BASE + "/4/42/Flag_of_Mississippi.svg/200px-Flag_of_Mississippi.svg.png", BASE + "/5/5a/Flag_of_Missouri.svg/200px-Flag_of_Missouri.svg.png", BASE + "/c/cb/Flag_of_Montana.svg/200px-Flag_of_Montana.svg.png", BASE + "/4/4d/Flag_of_Nebraska.svg/200px-Flag_of_Nebraska.svg.png", BASE + "/f/f1/Flag_of_Nevada.svg/200px-Flag_of_Nevada.svg.png", BASE + "/2/28/Flag_of_New_Hampshire.svg/200px-Flag_of_New_Hampshire.svg.png", BASE + "/9/92/Flag_of_New_Jersey.svg/200px-Flag_of_New_Jersey.svg.png", BASE + "/c/c3/Flag_of_New_Mexico.svg/200px-Flag_of_New_Mexico.svg.png", BASE + "/1/1a/Flag_of_New_York.svg/200px-Flag_of_New_York.svg.png", BASE + "/b/bb/Flag_of_North_Carolina.svg/200px-Flag_of_North_Carolina.svg.png", BASE + "/e/ee/Flag_of_North_Dakota.svg/200px-Flag_of_North_Dakota.svg.png", BASE + "/4/4c/Flag_of_Ohio.svg/200px-Flag_of_Ohio.svg.png", BASE + "/6/6e/Flag_of_Oklahoma.svg/200px-Flag_of_Oklahoma.svg.png", BASE + "/b/b9/Flag_of_Oregon.svg/200px-Flag_of_Oregon.svg.png", BASE + "/f/f7/Flag_of_Pennsylvania.svg/200px-Flag_of_Pennsylvania.svg.png", BASE + "/f/f3/Flag_of_Rhode_Island.svg/200px-Flag_of_Rhode_Island.svg.png", BASE + "/6/69/Flag_of_South_Carolina.svg/200px-Flag_of_South_Carolina.svg.png", BASE + "/1/1a/Flag_of_South_Dakota.svg/200px-Flag_of_South_Dakota.svg.png", BASE + "/9/9e/Flag_of_Tennessee.svg/200px-Flag_of_Tennessee.svg.png", BASE + "/f/f7/Flag_of_Texas.svg/200px-Flag_of_Texas.svg.png", BASE + "/f/f6/Flag_of_Utah.svg/200px-Flag_of_Utah.svg.png", BASE + "/4/49/Flag_of_Vermont.svg/200px-Flag_of_Vermont.svg.png", BASE + "/4/47/Flag_of_Virginia.svg/200px-Flag_of_Virginia.svg.png", BASE + "/5/54/Flag_of_Washington.svg/200px-Flag_of_Washington.svg.png", BASE + "/2/22/Flag_of_West_Virginia.svg/200px-Flag_of_West_Virginia.svg.png", BASE + "/2/22/Flag_of_Wisconsin.svg/200px-Flag_of_Wisconsin.svg.png", BASE + "/b/bc/Flag_of_Wyoming.svg/200px-Flag_of_Wyoming.svg.png" }; }
[ "fraczwojciech@gmail.com" ]
fraczwojciech@gmail.com
d04217ff83361ba922cdf3620e7c2b9c93a7b5fb
f6479b08962887e547f4af409b4ffc5b20a97a8f
/costing/src/main/java/com/weibo/dip/costing/service/impl/StreamingServiceImpl.java
27210a379decd4ad0765109aa801ca9c7cdbc053
[]
no_license
0Gz2bflQyU0hpW/portal
52f3cbd3f9ab078df34dcee2713ae64c78b5c041
96a71c84bbd550dfb09d97a35c51ec545ccb6d6a
refs/heads/master
2020-08-02T18:09:00.928703
2019-09-28T07:01:13
2019-09-28T07:01:13
211,459,081
0
2
null
2019-09-28T07:04:08
2019-09-28T07:04:07
null
UTF-8
Java
false
false
661
java
package com.weibo.dip.costing.service.impl; import com.weibo.dip.costing.bean.StreamingResource; import com.weibo.dip.costing.dao.StreamingDao; import com.weibo.dip.costing.service.StreamingService; import java.util.Date; import java.util.List; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; /** * Created by yurun on 18/4/25. */ @Service public class StreamingServiceImpl implements StreamingService { @Autowired private StreamingDao streamingDao; @Override public List<StreamingResource> gets(Date beginTime, Date endTime) { return streamingDao.gets(beginTime, endTime); } }
[ "15764226651@163.com" ]
15764226651@163.com
cd364ce53b1c0b20181547b3df5b1c7a677f4244
4aa90348abcb2119011728dc067afd501f275374
/app/src/main/java/com/tencent/mm/plugin/readerapp/ui/ReaderAppUI$3.java
143969621050820783e5ca720ccf7dd0d280646a
[]
no_license
jambestwick/HackWechat
0d4ceb2d79ccddb45004ca667e9a6a984a80f0f6
6a34899c8bfd50d19e5a5ec36a58218598172a6b
refs/heads/master
2022-01-27T12:48:43.446804
2021-12-29T10:36:30
2021-12-29T10:36:30
249,366,791
0
0
null
2020-03-23T07:48:32
2020-03-23T07:48:32
null
UTF-8
Java
false
false
4,844
java
package com.tencent.mm.plugin.readerapp.ui; import android.content.Intent; import android.view.MenuItem; import com.tencent.mm.g.a.cf; import com.tencent.mm.plugin.readerapp.b.g; import com.tencent.mm.pluginsdk.model.t; import com.tencent.mm.sdk.platformtools.x; import com.tencent.mm.ui.base.p$d; import com.tencent.mm.y.g.a; import com.tencent.mm.z.bf; import com.tencent.mm.z.bg; import com.tencent.mm.z.u; import com.tencent.mm.z.u.b; import java.util.List; class ReaderAppUI$3 implements p$d { final /* synthetic */ ReaderAppUI pAY; ReaderAppUI$3(ReaderAppUI readerAppUI) { this.pAY = readerAppUI; } public final void onMMMenuItemSelected(MenuItem menuItem, int i) { int groupId = menuItem.getGroupId(); bf bfVar; long longValue; switch (menuItem.getItemId()) { case 0: if (ReaderAppUI.a(this.pAY) == 20) { List b = g.bmp().b(((Long) ReaderAppUI.b(this.pAY).getItem(groupId)).longValue(), ReaderAppUI.a(this.pAY)); if (b.size() > 0) { bfVar = (bf) b.get(0); a aVar = new a(); aVar.title = bfVar.getTitle(); aVar.description = bfVar.HM(); aVar.action = "view"; aVar.type = 5; aVar.url = bfVar.getUrl(); String a = a.a(aVar, null, null); Intent intent = new Intent(); intent.putExtra("Retr_Msg_content", a); intent.putExtra("Retr_Msg_Type", 2); intent.putExtra("Retr_Msg_thumb_path", t.v(bfVar.HL(), bfVar.type, "@T")); intent.putExtra("Retr_Msg_Id", 7377812); a = u.hz(bfVar.hhm); intent.putExtra("reportSessionId", a); b t = u.GK().t(a, true); t.o("prePublishId", "msg_" + bfVar.hhm); t.o("preUsername", "newsapp"); t.o("preChatName", "newsapp"); t.o("preMsgIndex", Integer.valueOf(0)); t.o("sendAppMsgScene", Integer.valueOf(1)); com.tencent.mm.plugin.readerapp.a.a.ifs.l(intent, this.pAY); return; } return; } return; case 1: if (ReaderAppUI.a(this.pAY) == 20) { List b2 = g.bmp().b(((Long) ReaderAppUI.b(this.pAY).getItem(groupId)).longValue(), ReaderAppUI.a(this.pAY)); if (!b2.isEmpty()) { x.i("MicroMsg.ReaderAppUI", "fav time %d, index %d, size %d", new Object[]{Long.valueOf(longValue), Integer.valueOf(ReaderAppUI.c(this.pAY)), Integer.valueOf(b2.size())}); if (ReaderAppUI.c(this.pAY) >= b2.size()) { ReaderAppUI.a(this.pAY, 0); } bfVar = (bf) b2.get(ReaderAppUI.c(this.pAY)); com.tencent.mm.sdk.b.b cfVar = new cf(); String hz = u.hz(bfVar.hhm); b t2 = u.GK().t(hz, true); t2.o("prePublishId", "msg_" + bfVar.hhm); t2.o("preUsername", "newsapp"); t2.o("preChatName", "newsapp"); t2.o("preMsgIndex", Integer.valueOf(0)); t2.o("sendAppMsgScene", Integer.valueOf(1)); cfVar.fqp.fqu = hz; com.tencent.mm.plugin.readerapp.b.b.a(cfVar, bfVar, ReaderAppUI.c(this.pAY)); cfVar.fqp.fqw = 7; cfVar.fqp.activity = this.pAY; com.tencent.mm.sdk.b.a.xef.m(cfVar); return; } return; } return; case 2: longValue = ((Long) ReaderAppUI.b(this.pAY).getItem(groupId)).longValue(); if (longValue != 0) { g.u(longValue, ReaderAppUI.a(this.pAY)); bg bmp = g.bmp(); int a2 = ReaderAppUI.a(this.pAY); x.d("MicroMsg.ReaderAppInfoStorage", "deleteGroup:%s", new Object[]{"delete from " + bg.gU(a2) + " where time = " + longValue}); if (bmp.hhp.fx(bg.gU(a2), "delete from " + bg.gU(a2) + " where time = " + longValue)) { bmp.gX(a2); bmp.doNotify(); } } this.pAY.refresh(); return; default: return; } } }
[ "malin.myemail@163.com" ]
malin.myemail@163.com
4ef9d37d700c5b7c1624363dcd1d8a203fee7161
2d2e1c6126870b0833c6f80fec950af7897065e5
/scriptom-office-2k7/src/main/java/org/codehaus/groovy/scriptom/tlb/office2007/word/WdSortFieldTypeHID.java
3b12981ec256d35ba48217a853c4c1eedf03420a
[]
no_license
groovy/Scriptom
d650b0464f58d3b58bb13469e710dbb80e2517d5
790eef97cdacc5da293d18600854b547f47e4169
refs/heads/master
2023-09-01T16:13:00.152780
2022-02-14T12:30:17
2022-02-14T12:30:17
39,463,850
20
7
null
2015-07-23T12:48:26
2015-07-21T18:52:11
Java
UTF-8
Java
false
false
2,596
java
/* * Copyright 2009 (C) The Codehaus. All Rights Reserved. * * Redistribution and use of this software and associated documentation * ("Software"), with or without modification, are permitted provided that the * following conditions are met: * 1. Redistributions of source code must retain copyright statements and * notices. Redistributions must also contain a copy of this document. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * 3. The name "groovy" must not be used to endorse or promote products * derived from this Software without prior written permission of The Codehaus. * For written permission, please contact info@codehaus.org. * 4. Products derived from this Software may not be called "groovy" nor may * "groovy" appear in their names without prior written permission of The * Codehaus. "groovy" is a registered trademark of The Codehaus. * 5. Due credit should be given to The Codehaus - http://groovy.codehaus.org/ * * THIS SOFTWARE IS PROVIDED BY THE CODEHAUS AND CONTRIBUTORS ``AS IS'' AND ANY * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE * DISCLAIMED. IN NO EVENT SHALL THE CODEHAUS OR ITS CONTRIBUTORS BE LIABLE FOR * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH * DAMAGE. */ package org.codehaus.groovy.scriptom.tlb.office2007.word; import java.util.Map; import java.util.TreeMap; import java.util.Collections; /** * @author Jason Smith */ public final class WdSortFieldTypeHID { private WdSortFieldTypeHID() { } /** * Value is 0 (0x0) */ public static final Integer emptyenum = Integer.valueOf(0); /** * A {@code Map} of the symbolic names to constant values. */ public static final Map<String,Object> values; static { TreeMap<String,Object> v = new TreeMap<String,Object>(); v.put("emptyenum", emptyenum); values = Collections.synchronizedMap(Collections.unmodifiableMap(v)); } }
[ "ysb33r@gmail.com" ]
ysb33r@gmail.com
e2ce8cf0996cdb5d375203d7f49668347c4800c1
38e9eba054c763a984dcb8c7af49518e7f2aa787
/app/src/main/java/com/dodoweather/android/db/Country.java
788058b19ce051e7bcd334812ed4d612c8067e85
[ "Apache-2.0" ]
permissive
dodo522/dodoweather
1a64af37dcedc91d90ed961eea443ced37f41292
af3364763c08bf5fa30a78c7b555a0a9f083f809
refs/heads/master
2022-11-02T05:42:24.751573
2020-06-15T10:57:48
2020-06-15T10:57:48
272,022,917
0
0
null
null
null
null
UTF-8
Java
false
false
856
java
package com.dodoweather.android.db; import org.litepal.crud.DataSupport; /** * Created by Administrator on 2020/6/15. */ public class Country extends DataSupport{ private int id; private String countryName; private String weatherId; private int cityId; public int getId() { return id; } public String getCountryName() { return countryName; } public String getWeatherId() { return weatherId; } public int getCityId() { return cityId; } public void setId(int id) { this.id = id; } public void setCountryName(String countryName) { this.countryName = countryName; } public void setWeatherId(String weatherId) { this.weatherId = weatherId; } public void setCityId(int cityId) { this.cityId = cityId; } }
[ "you@example.com" ]
you@example.com
4e985b1ce35b00404a384a86c2c73c889274d0f4
4f10df8e9dd5c048131077c4a73c409142735a08
/lesson_04/src/ua/lviv/lgs/robot/CoffeRobot.java
fc13b4b0a198f897d3440549fc61403702db3c60
[]
no_license
ArtemDerid/lesson_4
6b6d25fcb83e99c5a73c69bbae131797d110186a
4684935c1fb416237372b113926563f15b51f61b
refs/heads/master
2020-06-04T20:22:30.094630
2019-06-16T10:45:52
2019-06-16T10:45:52
192,178,538
0
0
null
null
null
null
UTF-8
Java
false
false
138
java
package ua.lviv.lgs.robot; public class CoffeRobot extends Robot { public CoffeRobot(String speech) { super(speech); } }
[ "Tester99037@gmail.com" ]
Tester99037@gmail.com
e54d62ca27547e4e4ad4c66837cc474452f6f8dd
8ffef13d2ad29518e2882e943b241daf9a51b6ac
/app/src/main/java/com/randomappsinc/sturf/Fragments/HomeFeedFragment.java
67bfc5927a89eec90b2eba4c18981fae835bd393
[]
no_license
Gear61/Sturf-Android
6c47d05e25fee11085625f880a6603bf38c54ea3
61077b59880b68b3a5858cf78daa8ab7d6c69af5
refs/heads/master
2016-09-14T06:21:56.732379
2016-05-07T21:30:35
2016-05-07T21:30:35
56,357,874
0
0
null
null
null
null
UTF-8
Java
false
false
632
java
package com.randomappsinc.sturf.Fragments; import android.app.Fragment; import android.os.Bundle; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import com.randomappsinc.sturf.R; import butterknife.ButterKnife; /** * Created by alexanderchiou on 4/15/16. */ public class HomeFeedFragment extends Fragment { @Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { View rootView = inflater.inflate(R.layout.home_feed, container, false); ButterKnife.bind(this, rootView); return rootView; } }
[ "chessnone@yahoo.com" ]
chessnone@yahoo.com
71565f8bd32ba32d84b12069f130309bb7461eb0
3a35fc1167194b97390ba6622d6d13f7122c78c9
/SpringDataTests/src/main/java/com/pankaj/spring/data/SpringDataTests/repsoitories/ChessPlayerRepository.java
c3450abf5ba1c15c722e1feeae8f9cd194d3c54c
[]
no_license
premprakashrohan/SpringDataJPA
5363a9213569be6041b334ac22c38d6d9e5ade5c
3552e72edfeffb3f7fac117e431cfbb82a506c2a
refs/heads/main
2023-05-06T04:45:22.816375
2021-05-21T10:11:36
2021-05-21T10:11:36
null
0
0
null
null
null
null
UTF-8
Java
false
false
577
java
package com.pankaj.spring.data.SpringDataTests.repsoitories; import com.pankaj.spring.data.SpringDataTests.model.ChessPlayer; import org.springframework.data.jpa.repository.JpaRepository; import org.springframework.data.jpa.repository.Query; import org.springframework.data.repository.query.Param; import java.util.List; public interface ChessPlayerRepository extends JpaRepository<ChessPlayer,Long> { @Query("SELECT p FROM ChessPlayer p where p.lastName = :lastName ORDER BY p.lastName ASC") List<ChessPlayer> findByLastName(@Param("lastName")String lastName); }
[ "2005pank@gmail.com" ]
2005pank@gmail.com
23ac6925577aa6cb990eda9e7000618aec6fe431
e663112569f6f82e29534205c0dc3ab6d26c96f7
/BLM104_2018_2019_Guz/src/Ders05/Ornek9.java
b577ba2408290ab46034452257018dbabd8fe956
[]
no_license
alinizam/BLM104_2018_2019_Guz
e250dd40727c71c8cf59ef56434465a0323edef4
fa2d946afeb2250a2fd106f36937070e942dbdee
refs/heads/master
2020-03-30T00:56:56.333307
2018-12-28T06:40:00
2018-12-28T06:40:00
150,551,777
0
1
null
null
null
null
UTF-8
Java
false
false
693
java
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package Ders05; /** * * @author anizam */ public class Ornek9 { public static void main(String[] args) { StringBuilder sb=new StringBuilder(); sb.append("Ahmet geldi "); System.out.println(sb); System.out.println("Nereye geldi"); sb.insert(6, "eve "); System.out.println(sb); sb.append(10); sb.append(" da"); System.out.println(sb); System.out.println(sb.reverse()); } }
[ "alinizam99@gmail.com" ]
alinizam99@gmail.com
4614c6345fe4f7c7662a8ef00a26cea2382ffd95
53f8d4f43f258ed6c9e57728f917184383a60e3e
/src/main/java/org/axiondb/util/ComparableComparator.java
34c5d61d97a8467537744d303e5856a2aa476d42
[]
no_license
nezihyigitbasi/axiondb
6297b27e2efcd533b851640dc39d9a3f0eca01eb
ea832450854fd28b2d739ae0c3022cf278fca5ab
refs/heads/master
2020-04-09T11:32:17.619831
2008-12-23T13:23:47
2008-12-23T13:23:47
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,748
java
/* * * ======================================================================= * Copyright (c) 2002-2005 Axion Development Team. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * 1. Redistributions of source code must retain the above * copyright notice, this list of conditions and the following * disclaimer. * * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in * the documentation and/or other materials provided with the * distribution. * * 3. The names "Tigris", "Axion", nor the names of its contributors may * not be used to endorse or promote products derived from this * software without specific prior written permission. * * 4. Products derived from this software may not be called "Axion", nor * may "Tigris" or "Axion" appear in their names without specific prior * written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A * PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * ======================================================================= */ package org.axiondb.util; import java.io.Serializable; import java.util.Comparator; public class ComparableComparator implements Comparator, Serializable { public static ComparableComparator getInstance() { return INSTANCE; } public ComparableComparator() { } public int compare(Object o1, Object o2) { return ((Comparable) o1).compareTo(o2); } public int hashCode() { return "ComparableComparator".hashCode(); } public boolean equals(Object that) { return (this == that) || ((null != that) && (that.getClass().equals(this.getClass()))); } private static final ComparableComparator INSTANCE = new ComparableComparator(); }
[ "ahimanikya@users.noreply.github.com" ]
ahimanikya@users.noreply.github.com
cc1d300dc7aadb9b85cbe1ba0fb30f4e6bb44388
84e064c973c0cc0d23ce7d491d5b047314fa53e5
/latest9.2/hej/net/sf/saxon/functions/Insert.java
114c5a7914ddac86249a95595a6514e1612a23a6
[]
no_license
orbeon/saxon-he
83fedc08151405b5226839115df609375a183446
250c5839e31eec97c90c5c942ee2753117d5aa02
refs/heads/master
2022-12-30T03:30:31.383330
2020-10-16T15:21:05
2020-10-16T15:21:05
304,712,257
1
1
null
null
null
null
UTF-8
Java
false
false
4,466
java
package net.sf.saxon.functions; import net.sf.saxon.expr.XPathContext; import net.sf.saxon.om.Item; import net.sf.saxon.om.SequenceIterator; import net.sf.saxon.trans.XPathException; import net.sf.saxon.value.AtomicValue; import net.sf.saxon.value.NumericValue; /** * The XPath 2.0 insert-before() function */ public class Insert extends SystemFunction { /** * Evaluate the function to return an iteration of selected nodes. */ public SequenceIterator iterate(XPathContext context) throws XPathException { SequenceIterator seq = argument[0].iterate(context); AtomicValue n0 = (AtomicValue)argument[1].evaluateItem(context); NumericValue n = (NumericValue)n0; int pos = (int)n.longValue(); SequenceIterator ins = argument[2].iterate(context); return new InsertIterator(seq, ins, pos); } public static class InsertIterator implements SequenceIterator { private SequenceIterator base; private SequenceIterator insert; private int insertPosition; private int position = 0; private Item current = null; private boolean inserting = false; public InsertIterator(SequenceIterator base, SequenceIterator insert, int insertPosition) { this.base = base; this.insert = insert; this.insertPosition = (insertPosition<1 ? 1 : insertPosition); this.inserting = (insertPosition==1); } public Item next() throws XPathException { Item nextItem; if (inserting) { nextItem = insert.next(); if (nextItem == null) { inserting = false; nextItem = base.next(); } } else { if (position == insertPosition-1) { nextItem = insert.next(); if (nextItem == null) { nextItem = base.next(); } else { inserting = true; } } else { nextItem = base.next(); if (nextItem==null && position < insertPosition-1) { inserting = true; nextItem = insert.next(); } } } if (nextItem == null) { current = null; position = -1; return null; } else { current = nextItem; position++; return current; } } public Item current() { return current; } public int position() { return position; } public void close() { base.close(); insert.close(); } public SequenceIterator getAnother() throws XPathException { return new InsertIterator( base.getAnother(), insert.getAnother(), insertPosition); } /** * Get properties of this iterator, as a bit-significant integer. * * @return the properties of this iterator. This will be some combination of * properties such as {@link #GROUNDED}, {@link #LAST_POSITION_FINDER}, * and {@link #LOOKAHEAD}. It is always * acceptable to return the value zero, indicating that there are no known special properties. * It is acceptable for the properties of the iterator to change depending on its state. */ public int getProperties() { return 0; } } } // // The contents of this file are subject to the Mozilla Public License Version 1.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.mozilla.org/MPL/ // // Software distributed under the License is distributed on an "AS IS" basis, // WITHOUT WARRANTY OF ANY KIND, either express or implied. // See the License for the specific language governing rights and limitations under the License. // // The Original Code is: all this file. // // The Initial Developer of the Original Code is Michael H. Kay // // Portions created by (your name) are Copyright (C) (your legal entity). All Rights Reserved. // // Contributor(s): none. //
[ "mike@saxonica.com" ]
mike@saxonica.com
a43496dcac4f4a280f7ce212b9ca8245456d95ad
2e1aee65bc0ce55132eb3cda469cacabb13b39b0
/src/silentwing算法冲刺/session04_BFS_DFS_UnionFind/BiggestSet.java
c8989b1f9646d417aa2a6f2f7446a7678885529f
[]
no_license
iyangzeshi/techbow
f23a8a68a768dbbbabfd65505e31e72fe6148d01
55e22b7c2636b241c364e1a1dea0d9be7473acd4
refs/heads/master
2023-08-27T17:21:39.076035
2021-08-11T11:40:04
2021-10-28T20:37:22
321,618,539
5
3
null
null
null
null
UTF-8
Java
false
false
1,801
java
package silentwing算法冲刺.session04_BFS_DFS_UnionFind; import java.util.ArrayList; import java.util.HashMap; import java.util.HashSet; import java.util.List; //Project: techbow //Package: silentwing算法冲刺.session04_BFS_DFS_UnionFind //ClassName: BiggestSet //Author: Zeshi(Jesse) Yang //Date: 2020-12-15 星期二 22:04 public class BiggestSet { public static void main(String[] args) { char[][] pairs = new char[][]{{'A', 'B'}, {'C', 'D'}, {'E', 'F'}, {'A', 'G'}, {'A', 'F'}}; List<List<Character>> res = biggestSet(pairs); for (List<Character> list : res) System.out.println(list.toString()); } public static List<List<Character>> biggestSet(char[][] pairs) { List<List<Character>> res = new ArrayList<>(); // corner case if (pairs == null || pairs.length == 0 || pairs[0] == null || pairs[0].length == 0) return res; // step 1: build graph HashMap<Character, List<Character>> map = new HashMap<>(); for (char[] pair : pairs) { map.putIfAbsent(pair[0], new ArrayList<>()); map.putIfAbsent(pair[1], new ArrayList<>()); map.get(pair[0]).add(pair[1]); map.get(pair[1]).add(pair[0]); } // step 2: iterate through graph int max = 0; HashSet<Character> set = new HashSet<>(); for (char key : map.keySet()) { if (set.add(key)) { List<Character> path = new ArrayList<>(); path.add(key); dfs(map, set, key, path); if (path.size() >= max) { if (path.size() > max) { max = path.size(); res.clear(); } res.add(path); } } } return res; } private static void dfs(HashMap<Character, List<Character>> map, HashSet<Character> set, char cur, List<Character> path) { for (char next : map.get(cur)) { if (set.add(next)) { path.add(next); dfs(map, set, next, path); } } } }
[ "iyangzeshi@outlook.com" ]
iyangzeshi@outlook.com
7d7f72446524318ad16b845fa0070cc34d1d7f42
61922ecc67f1e0b74d2750c37eb29b5d41c6dfb8
/AdditionalDemos/CompactDiscSpringDataRest_XmlConfig/src/main/java/com/conygre/spring/service/CompactDiscService.java
85d7290ce8f2a8192ccda7d41d4a65fb417fb223
[]
no_license
manasvi-savani/spring-course
386058714d6e2015b27996258e50c25048156afb
a076c17adc9dfb9a1ed66251b0e99b2113626a3b
refs/heads/master
2023-07-10T15:16:14.232143
2021-08-13T18:08:43
2021-08-13T18:08:43
null
0
0
null
null
null
null
UTF-8
Java
false
false
550
java
package com.conygre.spring.service; import com.conygre.spring.data.repos.CompactDiscRepository; import com.conygre.training.entities.CompactDisc; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; @Service public class CompactDiscService { @Autowired private CompactDiscRepository repository; public Iterable<CompactDisc> getCds() { return repository.findAll(); } public Iterable<CompactDisc> getCDsByArtist(String artist) { return repository.findByArtist(artist); } }
[ "=" ]
=
1b441aecef0072fd7c22da2653791d6c697f0428
ce3dc078db4b3089feeae55d0c7610e3dd30b0d1
/app/src/main/java/com/example/fragmentatruntime/RegisterFragment.java
4c6cfa00498ab2f06bf1403f2c415d0a96eb6677
[]
no_license
harjaichhayank/Fragment-At-Runtime
72b9aa158fc2533d2dfe18327b02abc4c2d59825
5fde48fb82b68e7e9480f65146cf029ffbeded46
refs/heads/master
2022-08-28T14:06:16.085532
2020-05-27T00:28:44
2020-05-27T00:28:44
267,181,613
0
0
null
null
null
null
UTF-8
Java
false
false
711
java
package com.example.fragmentatruntime; import android.os.Bundle; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import androidx.annotation.NonNull; import androidx.fragment.app.Fragment; public class RegisterFragment extends Fragment { @Override public View onCreateView( LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState ) { // Inflate the layout for this fragment return inflater.inflate(R.layout.fragment_register, container, false); } public void onViewCreated(@NonNull View view, Bundle savedInstanceState) { super.onViewCreated(view, savedInstanceState); } }
[ "harjaichhayank1@gmail.com" ]
harjaichhayank1@gmail.com
b907a35be0f3111d51d64e70fbfa932f9440b794
bbb855358d3a7b9243205aed4644f7d0b95c5fe6
/JavaProject/hyc/hyc-system/system-service/src/main/java/com/hyc/shop/system/domain/dao/RoleResourceMapper.java
d0b3eed53cf73b6140117fe845c7af3c776355e7
[]
no_license
39179219huangtao/HuangTaoBlog
94fd813360c1deb896633dfa926ab01f24f4c9db
afb572a28ea46033cc521c05c3b1360369cee65f
refs/heads/master
2022-12-06T22:29:22.617431
2019-10-31T08:13:09
2019-10-31T08:13:09
186,969,085
2
0
null
2022-11-21T22:37:36
2019-05-16T06:51:44
TSQL
UTF-8
Java
false
false
1,368
java
package com.hyc.shop.system.domain.dao; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.hyc.shop.system.domain.dataobject.RoleResourceDO; import org.apache.ibatis.annotations.Param; import org.springframework.stereotype.Repository; import java.util.Collection; import java.util.List; @Repository public interface RoleResourceMapper extends BaseMapper<RoleResourceDO> { /** * 批量插入。因为 MyBaits Plus 的批量插入是基于 Service 实现,所以只好写 XML * * @param roleResources 数组 */ int insertList(@Param("roleResources") List<RoleResourceDO> roleResources); default List<RoleResourceDO> selectListByResourceId(Integer resourceId) { return selectList(new QueryWrapper<RoleResourceDO>().eq("resource_id", resourceId)); } default List<RoleResourceDO> selectListByResourceId(Collection<Integer> resourceIds) { return selectList(new QueryWrapper<RoleResourceDO>().in("resource_id", resourceIds)); } default int deleteByResourceId(Integer resourceId) { return delete(new QueryWrapper<RoleResourceDO>().eq("resource_id", resourceId)); } default int deleteByRoleId(Integer roleId) { return delete(new QueryWrapper<RoleResourceDO>().eq("role_id", roleId)); } }
[ "huangtao@icsoc.net" ]
huangtao@icsoc.net
4da44b0998421c7b3d8c617d3dd8a0b96e87dfb2
876724d654445d8bc8d21e95371d4b33e74559f8
/X10JAVA/singleThreadedJava/backupTplasmaX10ToJavaSingleThreaded/TplasmaX10ToJavaSingleThreaded/jplasma/syntaxtree/DistType.java
4e25b04333d285117c1d086f420749eea5a6d101
[]
no_license
Mah-D/Retargetable-Compiler
c119e48ec8d6efee095f8d4bf994016da54cbbc0
84b7b81bb35bf5fc24bf5e6799b83d42880c3ffa
refs/heads/master
2016-08-04T21:41:26.159827
2015-07-14T20:18:33
2015-07-14T20:18:33
39,096,022
0
0
null
null
null
null
UTF-8
Java
false
false
1,247
java
// // Generated by JTB 1.3.2 // package jplasma.syntaxtree; /** * Grammar production: * nodeToken -> "dist" * nodeToken1 -> "(" * nodeToken2 -> ":" * rankEquation -> RankEquation() * nodeToken3 -> ")" */ public class DistType implements Node { public NodeToken nodeToken; public NodeToken nodeToken1; public NodeToken nodeToken2; public RankEquation rankEquation; public NodeToken nodeToken3; public DistType(NodeToken n0, NodeToken n1, NodeToken n2, RankEquation n3, NodeToken n4) { nodeToken = n0; nodeToken1 = n1; nodeToken2 = n2; rankEquation = n3; nodeToken3 = n4; } public DistType(RankEquation n0) { nodeToken = new NodeToken("dist"); nodeToken1 = new NodeToken("("); nodeToken2 = new NodeToken(":"); rankEquation = n0; nodeToken3 = new NodeToken(")"); } public void accept(jplasma.visitor.Visitor v) { v.visit(this); } public <R,A> R accept(jplasma.visitor.GJVisitor<R,A> v, A argu) { return v.visit(this,argu); } public <R> R accept(jplasma.visitor.GJNoArguVisitor<R> v) { return v.visit(this); } public <A> void accept(jplasma.visitor.GJVoidVisitor<A> v, A argu) { v.visit(this,argu); } }
[ "eslamimehr@ucla.edu" ]
eslamimehr@ucla.edu
e28e597fa8f05c7421eadcb5f19296ae117a6ebd
47761f5843a42ec5ce4b0e4a5ab23579e8c44959
/src/main/java/com/geniisys/gicl/dao/GICLMortgageeDAO.java
a5ea9d2fb28e2fd61c651dfb27b98190955330bb
[]
no_license
jabautista/GeniisysSCA
df6171c27594638193949df1a65c679444d51b9f
6dc1b21386453240f0632f37f00344df07f6bedd
refs/heads/development
2021-01-19T20:54:11.936774
2017-04-20T02:05:41
2017-04-20T02:05:41
88,571,440
2
0
null
2017-08-02T01:48:59
2017-04-18T02:18:03
PLSQL
UTF-8
Java
false
false
282
java
package com.geniisys.gicl.dao; import java.sql.SQLException; import java.util.Map; public interface GICLMortgageeDAO { void setClmItemMortgagee(Map<String, Object> params) throws SQLException; String checkIfGiclMortgageeExist(Map<String, Object> params) throws SQLException; }
[ "jeromecris.bautista@gmail.com" ]
jeromecris.bautista@gmail.com
e3fccdcdb10969db4478bfca46688dfcfab8cdcf
de86e1ed198a1e9f3d63e4fa7b3da9303e9f0e1d
/app/src/main/java/com/jkabe/app/android/lljjcoder/bean/DistrictBean.java
c318f00417013615b1088bf78f69508c612e1a2b
[]
no_license
aq610428/Kbox-jkabe1
c88eaf443b4cf055615687ad4694ccdbe47d25c3
ec937079f6f9a36c8b042f69d9626ea1df87f55c
refs/heads/master
2023-01-21T01:21:33.290224
2020-11-30T06:43:21
2020-11-30T06:43:21
285,727,235
0
1
null
null
null
null
UTF-8
Java
false
false
1,404
java
package com.jkabe.app.android.lljjcoder.bean; import android.os.Parcel; import android.os.Parcelable; /** * @2Do: * @Author M2 * @Version v ${VERSION} * @Date 2017/7/7 0007. */ public class DistrictBean implements Parcelable { private String id; /*110101*/ private String name; /*东城区*/ @Override public String toString() { return name; } public String getId() { return id == null ? "" : id; } public void setId(String id) { this.id = id; } public String getName() { return name == null ? "" : name; } public void setName(String name) { this.name = name; } @Override public int describeContents() { return 0; } @Override public void writeToParcel(Parcel dest, int flags) { dest.writeString(this.id); dest.writeString(this.name); } public DistrictBean() { } protected DistrictBean(Parcel in) { this.id = in.readString(); this.name = in.readString(); } public static final Creator<DistrictBean> CREATOR = new Creator<DistrictBean>() { @Override public DistrictBean createFromParcel(Parcel source) { return new DistrictBean(source); } @Override public DistrictBean[] newArray(int size) { return new DistrictBean[size]; } }; }
[ "641897605@qq.com" ]
641897605@qq.com
c4e27e8622d50e2b54845eda37b8710419f9d4b7
95e944448000c08dd3d6915abb468767c9f29d3c
/sources/com/p280ss/android/ugc/aweme/crossplatform/platform/webview/C25966d.java
f40dde06d83a7ee33dc632119a36a60b4e580ed8
[]
no_license
xrealm/tiktok-src
261b1faaf7b39d64bb7cb4106dc1a35963bd6868
90f305b5f981d39cfb313d75ab231326c9fca597
refs/heads/master
2022-11-12T06:43:07.401661
2020-07-04T20:21:12
2020-07-04T20:21:12
null
0
0
null
null
null
null
UTF-8
Java
false
false
506
java
package com.p280ss.android.ugc.aweme.crossplatform.platform.webview; import android.view.View; import android.webkit.WebChromeClient.CustomViewCallback; import android.webkit.WebView; /* renamed from: com.ss.android.ugc.aweme.crossplatform.platform.webview.d */ public interface C25966d { /* renamed from: a */ void mo67355a(); /* renamed from: a */ void mo67356a(View view, CustomViewCallback customViewCallback); /* renamed from: a */ void mo67357a(WebView webView, int i); }
[ "65450641+Xyzdesk@users.noreply.github.com" ]
65450641+Xyzdesk@users.noreply.github.com
9f36b9e1b769a970e0e32b64fb1317ec0d2e7224
5c039e4f073bd96f7841b449909ede8ac342105f
/src/main/java/com/kaltura/client/types/StringValue.java
7b20456d76cd06bfcd2106b7a6e79ba9498e76a9
[]
no_license
alonbasin-kaltura/KalturaOttGeneratedAPIClientsJava
30f52c488aea6b7b2a836e85d7c52c78b08f9d58
2804028dabf1b27c1ecfdcd822106547faec7e77
refs/heads/master
2021-04-15T05:56:33.666929
2018-10-03T10:40:27
2018-10-03T10:40:27
126,175,094
0
1
null
2018-08-05T12:57:54
2018-03-21T12:27:30
Java
UTF-8
Java
false
false
2,674
java
// =================================================================================================== // _ __ _ _ // | |/ /__ _| | |_ _ _ _ _ __ _ // | ' </ _` | | _| || | '_/ _` | // |_|\_\__,_|_|\__|\_,_|_| \__,_| // // This file is part of the Kaltura Collaborative Media Suite which allows users // to do with audio, video, and animation what Wiki platfroms allow them to do with // text. // // Copyright (C) 2006-2018 Kaltura Inc. // // This program is free software: you can redistribute it and/or modify // it under the terms of the GNU Affero General Public License as // published by the Free Software Foundation, either version 3 of the // License, or (at your option) any later version. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU Affero General Public License for more details. // // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see <http://www.gnu.org/licenses/>. // // @ignore // =================================================================================================== package com.kaltura.client.types; import com.google.gson.JsonObject; import com.kaltura.client.Params; import com.kaltura.client.utils.GsonParser; import com.kaltura.client.utils.request.MultiRequestBuilder; /** * This class was generated using clients-generator\exec.php * against an XML schema provided by Kaltura. * * MANUAL CHANGES TO THIS CLASS WILL BE OVERWRITTEN. */ /** * A string representation to return an array of strings */ @SuppressWarnings("serial") @MultiRequestBuilder.Tokenizer(StringValue.Tokenizer.class) public class StringValue extends Value { public interface Tokenizer extends Value.Tokenizer { String value(); } /** * Value */ private String value; // value: public String getValue(){ return this.value; } public void setValue(String value){ this.value = value; } public void value(String multirequestToken){ setToken("value", multirequestToken); } public StringValue() { super(); } public StringValue(JsonObject jsonObject) throws APIException { super(jsonObject); if(jsonObject == null) return; // set members values: value = GsonParser.parseString(jsonObject.get("value")); } public Params toParams() { Params kparams = super.toParams(); kparams.add("objectType", "KalturaStringValue"); kparams.add("value", this.value); return kparams; } }
[ "jenkins@kaltura.com" ]
jenkins@kaltura.com
e81b477b3a71f2ff1297032ef3f187e3b456de95
62f5509a3ffdb632f6633c2934743439eda65c6b
/tudu-core/src/main/java/core/tudu/domain/model/comparator/TodoByPriorityAscComparator.java
bc7801eeb018ed6f77cb2d6f59f7979d3f16cc11
[]
no_license
DanielLEVY25021961/tudu-parent
eba2ea194187eba51dda494c3ad10d9b4843cae1
4d9f80f3ee1cead4958a5ba202245ea40fa73e40
refs/heads/master
2021-09-15T04:45:49.075365
2018-05-26T13:08:04
2018-05-26T13:08:04
112,198,217
0
1
null
null
null
null
UTF-8
Java
false
false
884
java
package tudu.domain.model.comparator; import java.util.Comparator; import tudu.domain.model.Todo; /** * Comparator used to sort todos by their priority, in ascending order. * * @author Julien Dubois */ public class TodoByPriorityAscComparator implements Comparator<Todo> { /** * {@inheritDoc} */ @Override public int compare( final Todo pFirst, final Todo pSecond) { int order = pFirst.getPriority() - pSecond.getPriority(); if (pFirst.isCompleted()) { order += 10000; } if (pSecond.isCompleted()) { order -= 10000; } if (order == 0) { order = (pSecond.getDescription() + pSecond.getTodoId()) .compareTo(pFirst.getDescription() + pFirst.getTodoId()); } return order; } }
[ "dany.levy@free.fr" ]
dany.levy@free.fr
77e7daf4edf08ad3f580d6d838a0efb99b733ee8
bfa62154d0f74b3a2d90d69cc189d4a62a117292
/app/src/main/java/ir/greencode/androidmvprxroom/di/component/ApplicationComponent.java
1a776c9669e4ab093709449ab8ca1c7afcaa9175
[]
no_license
alirezat66/MVP_Rx_Room_Architecture
4309cfe7fc9e6d7a4aa30a5a7e393ea88894e0fd
b4fbba9933763b49603c206358f91ee873ec7a9f
refs/heads/master
2020-05-25T01:14:11.887024
2019-05-20T02:12:53
2019-05-20T02:12:53
187,549,052
5
1
null
null
null
null
UTF-8
Java
false
false
489
java
package ir.greencode.androidmvprxroom.di.component; import android.content.Context; import android.content.SharedPreferences; import javax.inject.Singleton; import dagger.Component; import ir.greencode.androidmvprxroom.di.module.ApplicationModule; import retrofit2.Retrofit; @Component(modules = {ApplicationModule.class}) @Singleton public interface ApplicationComponent { Retrofit exposeRetrofit(); Context exposeContext(); SharedPreferences exposeSharePrefrences(); }
[ "alirezataghizadeh66@gmail.com" ]
alirezataghizadeh66@gmail.com
079474f020a1814b2ca99364e6a7fca47b34de46
be177082b64f0b8bca67270a2795df6a4b951f97
/app/src/main/java/ws/wolfsoft/cleanup_home/Clean_Fragment.java
ebcf974376409e41dcba2b41c65603624b9bc4df
[]
no_license
wsdesignuiux/CleanUp_Home
f3378b52860932357edd494d40f60fe4ef0a5b22
d0fe8cb771557affda10b463385d580c010118e7
refs/heads/master
2020-04-08T07:47:37.696177
2018-11-26T10:30:20
2018-11-26T10:30:20
159,151,753
0
1
null
null
null
null
UTF-8
Java
false
false
695
java
package ws.wolfsoft.cleanup_home; import android.os.Bundle; import android.support.v4.app.Fragment; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import com.github.lzyzsd.circleprogress.ArcProgress; import com.github.lzyzsd.circleprogress.CircleProgress; public class Clean_Fragment extends Fragment { private View view; private CircleProgress circleProgress; private ArcProgress arcProgress; @Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { view = inflater.inflate(R.layout.clean_fragment, container, false); return view; } }
[ "wsdesignuiux@gmail.com" ]
wsdesignuiux@gmail.com
a5ad40bc1852ba463798b2583025d24b00962bc1
56eb8554dac46dc5b23fe548c60ec6f19b6db5a1
/src/com/neusoft/ElmBusiness.java
e2fc6a1a0f7345a3e9e0629deccbe7f819ccf701
[]
no_license
miraclestatus/elemeAdmin
5d24967a52de4b76d59c413bbec6b3fc3e91bfa5
31f0c981186449c67035447889ecfa95aac2a868
refs/heads/master
2022-12-05T13:46:57.455465
2020-08-10T07:19:24
2020-08-10T07:19:24
285,707,770
0
3
null
null
null
null
UTF-8
Java
false
false
3,618
java
package com.neusoft; import com.neusoft.domain.Admin; import com.neusoft.domain.Business; import com.neusoft.view.AdminView; import com.neusoft.view.BusinessView; import com.neusoft.view.FoodView; import com.neusoft.view.impl.AdminViewImpl; import com.neusoft.view.impl.BusinessViewImpl; import com.neusoft.view.impl.FoodViewImpl; import java.util.Scanner; /** * @author Eric Lee * @date 2020/8/10 09:04 */ public class ElmBusiness { private static Scanner input = new Scanner(System.in); public static void main(String[] args) { work(); } public static void work(){ System.out.println("-----------------------------------------------------------"); System.out.println("|\t\t\t\t饿了么控制台版后台管理系统 V1.0\t\t\t\t|"); System.out.println("-----------------------------------------------------------"); // 调用商家登录 BusinessView businessView = new BusinessViewImpl(); Business business = businessView.login(); if (business!=null){ int menu = 0; System.out.println("~欢迎来到饿了么商家管理系统~"); while (menu!= 5){ // 创建一个菜单 System.out.println("========= 一级菜单1.查看商家信息=2.修改商家信息=3.更新密码=4.所属商品管理=5.退出系统 ========="); System.out.println("请选择相应的菜单编号"); menu = input.nextInt(); switch (menu){ case 1: businessView.showBusinessInfo(business.getBusinessId()); break; case 2: businessView.updateBusinessInfo(business.getBusinessId()); break; case 3: businessView.updateBusinessByPassword(business.getBusinessId()); break; case 4: foodManage(business.getBusinessId()); break; case 5: System.out.println("========= 欢迎下次光临饿了么系统 ========="); break; default: System.out.println("没有这个菜单项"); break; } } }else { System.out.println("账号或密码有误请重新输入"); } } private static void foodManage(int businessId){ FoodView foodView = new FoodViewImpl(); int menu = 0; while (menu!= 5){ // 创建一个菜单 System.out.println("========= 二级菜单(美食管理)1.查看食品列表2.新增食品 3.修改食品=4.删除食品=5.返回一级菜单 ========="); System.out.println("请选择相应的菜单编号"); menu = input.nextInt(); switch (menu){ case 1: foodView.showFoodList(businessId); break; case 2: foodView.saveFood(businessId); break; case 3: foodView.updateFood(businessId); break; case 4: foodView.removeFood(businessId); break; case 5: break; default: System.out.println("没有这个菜单项"); break; } } } }
[ "31105601+miraclestatus@users.noreply.github.com" ]
31105601+miraclestatus@users.noreply.github.com
0bd4ebfe1e3face02c2a8e038865b6c2fd35f4de
08bdd164c174d24e69be25bf952322b84573f216
/opencores/client/foundation classes/j2sdk-1_4_2-src-scsl/hotspot/src/share/vm/agent/sun/jvm/hotspot/asm/sparc/SPARCShiftInstruction.java
c3eb6e7ddfaa02f1a8386ac764e562e37f2af595
[]
no_license
hagyhang/myforthprocessor
1861dcabcf2aeccf0ab49791f510863d97d89a77
210083fe71c39fa5d92f1f1acb62392a7f77aa9e
refs/heads/master
2021-05-28T01:42:50.538428
2014-07-17T14:14:33
2014-07-17T14:14:33
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,104
java
/* * @(#)SPARCShiftInstruction.java 1.2 03/01/23 11:18:25 * * Copyright 2003 Sun Microsystems, Inc. All rights reserved. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms. */ package sun.jvm.hotspot.asm.sparc; import sun.jvm.hotspot.asm.*; public class SPARCShiftInstruction extends SPARCFormat3AInstruction implements ShiftInstruction { final private int operation; public SPARCShiftInstruction(String name, int opcode, int operation, SPARCRegister rs1, ImmediateOrRegister operand2, SPARCRegister rd) { super(name, opcode, rs1, operand2, rd); this.operation = operation; } public int getOperation() { return operation; } public Operand getShiftDestination() { return getDestinationRegister(); } public Operand getShiftLength() { return operand2; } public Operand getShiftSource() { return rs1; } public boolean isShift() { return true; } protected String getOperand2String() { return operand2.toString(); } }
[ "blue@cmd.nu" ]
blue@cmd.nu
71864397de9d5967a100dd610698422205bbf2ef
e09d79b030cf788a8131bd38d5e8138ec469a903
/examples/example.java2graph/src/javamm/IExpression.java
9b542fa6be4db65c6d4040c5e4a174ce1630e748
[]
no_license
anatlyzer/a2l
3c28b71804c1bdd5c378a7cf85e9a04498d8869a
74f2c3ca81e45233a44461e95a4898ba1f237983
refs/heads/master
2021-01-16T04:34:21.940706
2020-02-25T23:35:00
2020-02-25T23:35:00
242,977,197
0
0
null
null
null
null
UTF-8
Java
false
false
268
java
package javamm; import blackboard.IdentifiableElement; import java.io.Serializable; @SuppressWarnings("serial")public interface IExpression extends IdentifiableElement,javamm.IASTNode { public String getId(); public void setId(String id); public String getTypeId(); }
[ "jesus.sanchez.cuadrado@gmail.com" ]
jesus.sanchez.cuadrado@gmail.com
9c836655eda0c1e6a2ba7467a5394a584905e790
093934c2cd81c8de93236bad583f2e16ab388995
/src/main/java/com/neemshade/sniper/repository/UserRepository.java
410d7389a850ac94f8b17711386aa3b15852b71d
[]
no_license
jbalaji01/sniper
45385cf9c69b8706e2ac0ec81e45458162ffbfea
e8e63afb8d3b9b6e919db87818cad48be3cb3c25
refs/heads/master
2022-12-10T03:41:52.392567
2019-07-24T07:28:16
2019-07-24T07:28:16
120,560,249
0
1
null
2022-12-03T13:20:38
2018-02-07T03:55:09
Java
UTF-8
Java
false
false
1,540
java
package com.neemshade.sniper.repository; import com.neemshade.sniper.domain.User; import org.springframework.cache.annotation.Cacheable; import org.springframework.data.domain.Page; import org.springframework.data.domain.Pageable; import org.springframework.data.jpa.repository.EntityGraph; import org.springframework.data.jpa.repository.JpaRepository; import org.springframework.stereotype.Repository; import java.util.List; import java.util.Optional; import java.time.Instant; /** * Spring Data JPA repository for the User entity. */ @Repository public interface UserRepository extends JpaRepository<User, Long> { String USERS_BY_LOGIN_CACHE = "usersByLogin"; String USERS_BY_EMAIL_CACHE = "usersByEmail"; Optional<User> findOneByActivationKey(String activationKey); List<User> findAllByActivatedIsFalseAndCreatedDateBefore(Instant dateTime); Optional<User> findOneByResetKey(String resetKey); Optional<User> findOneByEmailIgnoreCase(String email); Optional<User> findOneByLogin(String login); @EntityGraph(attributePaths = "authorities") Optional<User> findOneWithAuthoritiesById(Long id); @EntityGraph(attributePaths = "authorities") @Cacheable(cacheNames = USERS_BY_LOGIN_CACHE) Optional<User> findOneWithAuthoritiesByLogin(String login); @EntityGraph(attributePaths = "authorities") @Cacheable(cacheNames = USERS_BY_EMAIL_CACHE) Optional<User> findOneWithAuthoritiesByEmail(String email); Page<User> findAllByLoginNot(Pageable pageable, String login); }
[ "jhipster-bot@users.noreply.github.com" ]
jhipster-bot@users.noreply.github.com
2c62eb4db43f10cb9efeb1b1318b1adebe1ead72
99768d676b091b2598c62d51e30bf3e88b63b62b
/trunk/scurityOA1/src/accp/bean/Position.java
de61ceb3c946e2d6fc9ec13cebba55db7f0d5c83
[]
no_license
BGCX067/family51888-svn-to-git
9b26aca83b1b680f227b03be911b9402b4dce9e0
96de4110014fb5e93e5a87626218b947ce237f30
refs/heads/master
2021-01-13T00:56:41.379498
2015-12-28T14:15:12
2015-12-28T14:15:12
48,833,652
0
0
null
null
null
null
GB18030
Java
false
false
839
java
package accp.bean; /** * 员工职位 * @author liangrui * */ public class Position implements java.io.Serializable { private Long id; private String name_cn;//汉语 private String name_en;//英语 //private Set user=new HashSet();//一对多 非重点,暂不配 public Position(){} public Position(Long id, String name_cn, String name_en) { super(); this.id = id; this.name_cn = name_cn; this.name_en = name_en; } // public Long getId() { return id; } public void setId(Long id) { this.id = id; } public String getName_cn() { return name_cn; } public void setName_cn(String name_cn) { this.name_cn = name_cn; } public String getName_en() { return name_en; } public void setName_en(String name_en) { this.name_en = name_en; } }
[ "you@example.com" ]
you@example.com
9e4ef0034abb0d3136eccc7e73263228acbc3465
bf5a6ba4b7b216de771dff37bb70cf827d943659
/rapid-sdk/rapid-sdk-sina/src/main/java/org/rapid/sdk/sina/response/CommonResponse.java
7e1fa24a331d84009f161dcb1235f5f96a762356
[]
no_license
723854867/rapid
cb4ede1ae997fe169d33034bb998ab9abf0df278
72f7047d4d949503c87233d1a6695eb1e430cfde
refs/heads/master
2021-01-12T01:45:07.280777
2018-04-06T03:08:34
2018-04-06T03:08:34
121,467,272
1
0
null
null
null
null
UTF-8
Java
false
false
783
java
package org.rapid.sdk.sina.response; import com.google.gson.annotations.SerializedName; public class CommonResponse extends SinaResponse { private static final long serialVersionUID = 2208463998777558755L; @SerializedName("redirect_url") private String redirectUrl; @SerializedName("is_set_paypass") private String isSetPaypass; public String getRedirectUrl() { return redirectUrl; } public void setRedirectUrl(String redirectUrl) { this.redirectUrl = redirectUrl; } public String getIsSetPaypass() { return isSetPaypass; } public void setIsSetPaypass(String isSetPaypass) { this.isSetPaypass = isSetPaypass; } public boolean isSetPayPass() { return null == isSetPaypass ? false : isSetPaypass.equals("Y"); } }
[ "723854867@qq.com" ]
723854867@qq.com
29bf0d7c5a440aa318d25a5f292e943c54d1a5c0
7c87a85b35e47d4640283d12c40986e7b8a78e6f
/moneyfeed-goods/moneyfeed-goods-api/src/main/java/com/newhope/moneyfeed/goods/api/dto/request/BrandUpdateDtoReq.java
e4ca38eed46b4fed5e232f3a36f782e982b1499b
[]
no_license
newbigTech/moneyfeed
191b0bd4c98b49fa6be759ed16817b96c6e853b3
2bd8bdd10ddfde3f324060f7b762ec3ed6e25667
refs/heads/master
2020-04-24T13:05:44.308618
2019-01-15T07:59:03
2019-01-15T07:59:03
171,975,920
0
3
null
2019-02-22T01:53:12
2019-02-22T01:53:12
null
UTF-8
Java
false
false
979
java
package com.newhope.moneyfeed.goods.api.dto.request; import java.io.Serializable; /** * @author : tom * @project: moneyfeed-goods * @date : 2018/12/19 14:31 */ public class BrandUpdateDtoReq extends PageDtoReq implements Serializable { private static final long serialVersionUID = -8383359945172178763L; /** 品牌id */ private Long brandId; /** 品牌id */ private Long newBrandId; /** 品牌名称 */ private String brandName; public Long getNewBrandId() { return newBrandId; } public void setNewBrandId(Long newBrandId) { this.newBrandId = newBrandId; } public Long getBrandId() { return brandId; } public void setBrandId(Long brandId) { this.brandId = brandId; } public String getBrandName() { return brandName; } public void setBrandName(String brandName) { this.brandName = brandName; } }
[ "505235893@qq.com" ]
505235893@qq.com
2ba7a16d527afec256e58551be1135eea1acc54a
6baf1fe00541560788e78de5244ae17a7a2b375a
/hollywood/com.oculus.browser-base/sources/defpackage/NF1.java
9d012c83c7a7580419fd3d7ce467750310c8cd8c
[]
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
1,290
java
package defpackage; import android.text.TextUtils; import android.util.Log; import java.util.Locale; /* renamed from: NF1 reason: default package */ /* compiled from: chromium-OculusBrowser.apk-stable-281887347 */ public final class NF1 { /* renamed from: a reason: collision with root package name */ public final String f8536a; public final boolean b; public String c; public NF1(String str) { SE0.g(str, "The log tag cannot be null or empty."); this.f8536a = str; this.b = str.length() <= 23; } public final void a(String str, Object... objArr) { Log.e(this.f8536a, c(str, objArr)); } public final void b(String str, Object... objArr) { Log.w(this.f8536a, c(str, objArr)); } public final String c(String str, Object... objArr) { if (objArr.length != 0) { str = String.format(Locale.ROOT, str, objArr); } if (TextUtils.isEmpty(this.c)) { return str; } String valueOf = String.valueOf(this.c); String valueOf2 = String.valueOf(str); return valueOf2.length() != 0 ? valueOf.concat(valueOf2) : new String(valueOf); } public final boolean d() { return this.b && Log.isLoggable(this.f8536a, 3); } }
[ "cyuubiapps@gmail.com" ]
cyuubiapps@gmail.com
d0376f18411ff0bdd2a1bca7632aa727cb50a64b
6811fd178ae01659b5d207b59edbe32acfed45cc
/jira-project/jira-components/jira-tests-parent/jira-tests-unit/src/test/java/com/atlassian/jira/bc/admin/TestApplicationPropertiesServiceImpl.java
4db16f308d5185e0f25c16720cb8f20321756d5c
[]
no_license
xiezhifeng/mysource
540b09a1e3c62614fca819610841ddb73b12326e
44f29e397a6a2da9340a79b8a3f61b3d51e331d1
refs/heads/master
2023-04-14T00:55:23.536578
2018-04-19T11:08:38
2018-04-19T11:08:38
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,643
java
package com.atlassian.jira.bc.admin; import com.atlassian.event.api.EventPublisher; import com.atlassian.jira.config.FeatureManager; import com.atlassian.jira.config.properties.ApplicationPropertiesStore; import com.atlassian.jira.event.config.ApplicationPropertyChangeEvent; import com.atlassian.jira.security.JiraAuthenticationContext; import com.atlassian.jira.security.PermissionManager; import com.atlassian.validation.Success; import org.junit.Assert; import org.junit.Test; import org.mockito.Mock; import org.mockito.Mockito; import static org.mockito.Mockito.verify; import static org.mockito.Mockito.when; /** * Unit test for {@link ApplicationPropertiesServiceImpl}. * * @since v4.4 */ public class TestApplicationPropertiesServiceImpl { private static final String NEW_VALUE = "newval"; private static final String ORIGINAL_VALUE = "original value"; private static final String KEY = "foo"; @Mock private PermissionManager permissionManager; @Mock private JiraAuthenticationContext authenticationContext; @Mock private FeatureManager featureManager; @Test public void testSetApplicationProperty() { final ApplicationPropertyMetadata fooMeta = Mockito.mock(ApplicationPropertyMetadata.class); when(fooMeta.validate(NEW_VALUE)).thenReturn(new Success(NEW_VALUE)); ApplicationPropertiesStore store = Mockito.mock(ApplicationPropertiesStore.class); ApplicationProperty fooValue = new ApplicationProperty(fooMeta, ORIGINAL_VALUE); when(store.getApplicationPropertyFromKey(KEY)).thenReturn(fooValue); ApplicationProperty newFooValue = new ApplicationProperty(fooMeta, NEW_VALUE); when(store.setApplicationProperty(KEY, NEW_VALUE)).thenReturn(newFooValue); EventPublisher publisher = Mockito.mock(EventPublisher.class); final ApplicationPropertyChangeEvent event = Mockito.mock(ApplicationPropertyChangeEvent.class); ApplicationPropertiesServiceImpl service = new ApplicationPropertiesServiceImpl(store, publisher, permissionManager, authenticationContext, featureManager) { protected ApplicationPropertyChangeEvent createEvent(ApplicationPropertyMetadata metadata, String oldValue, String newValue) { Assert.assertEquals(fooMeta,metadata); Assert.assertEquals(ORIGINAL_VALUE,oldValue); Assert.assertEquals(NEW_VALUE,newValue); return event; } }; // production call service.setApplicationProperty(KEY, NEW_VALUE); verify(publisher).publish(event); } }
[ "moink635@gmail.com" ]
moink635@gmail.com
f8c26cfc1861c07b02d7ce852da391480caa6d3e
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/3/3_a5a521e5d8675fee4457fb2f88b5d4da94236063/TextureLoader/3_a5a521e5d8675fee4457fb2f88b5d4da94236063_TextureLoader_t.java
d0c735029c502b2c59e5ab7fdcf9550057189b11
[]
no_license
zhongxingyu/Seer
48e7e5197624d7afa94d23f849f8ea2075bcaec0
c11a3109fdfca9be337e509ecb2c085b60076213
refs/heads/master
2023-07-06T12:48:55.516692
2023-06-22T07:55:56
2023-06-22T07:55:56
259,613,157
6
2
null
2023-06-22T07:55:57
2020-04-28T11:07:49
null
UTF-8
Java
false
false
4,813
java
/******************************************************************************* * Copyright 2011 See AUTHORS file. * * 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.badlogic.gdx.assets.loaders; import com.badlogic.gdx.Gdx; import com.badlogic.gdx.assets.AssetDescriptor; import com.badlogic.gdx.assets.AssetLoaderParameters; import com.badlogic.gdx.assets.AssetManager; import com.badlogic.gdx.files.FileHandle; import com.badlogic.gdx.graphics.Pixmap; import com.badlogic.gdx.graphics.Pixmap.Format; import com.badlogic.gdx.graphics.PixmapIO; import com.badlogic.gdx.graphics.Texture; import com.badlogic.gdx.graphics.Texture.TextureFilter; import com.badlogic.gdx.graphics.Texture.TextureWrap; import com.badlogic.gdx.graphics.TextureData; import com.badlogic.gdx.graphics.glutils.ETC1TextureData; import com.badlogic.gdx.graphics.glutils.FileTextureData; import com.badlogic.gdx.utils.Array; import com.badlogic.gdx.utils.ObjectMap; /** {@link AssetLoader} for {@link Texture} instances. The pixel data is loaded asynchronously. The texture is then created on the * rendering thread, synchronously. Passing a {@link TextureParameter} to * {@link AssetManager#load(String, Class, AssetLoaderParameters)} allows one to specify parameters as can be passed to the * various Texture constructors, e.g. filtering, whether to generate mipmaps and so on. * @author mzechner */ public class TextureLoader extends AsynchronousAssetLoader<Texture, TextureLoader.TextureParameter> { static public class TextureLoaderInfo { String filename; TextureData data; Texture texture; }; TextureLoaderInfo info = new TextureLoaderInfo(); public TextureLoader (FileHandleResolver resolver) { super(resolver); } @Override public void loadAsync (AssetManager manager, String fileName, FileHandle file, TextureParameter parameter) { info.filename = fileName; if (parameter == null || parameter.textureData == null) { Pixmap pixmap = null; Format format = null; boolean genMipMaps = false; info.texture = null; if (parameter != null) { format = parameter.format; genMipMaps = parameter.genMipMaps; info.texture = parameter.texture; } if (!fileName.contains(".etc1")) { if (fileName.contains(".cim")) pixmap = PixmapIO.readCIM(file); else pixmap = new Pixmap(file); info.data = new FileTextureData(file, pixmap, format, genMipMaps); } else { info.data = new ETC1TextureData(file, genMipMaps); } } else { info.data = parameter.textureData; info.texture = parameter.texture; } if (!info.data.isPrepared()) info.data.prepare(); } @Override public Texture loadSync (AssetManager manager, String fileName, FileHandle file, TextureParameter parameter) { if (info == null) return null; Texture texture = info.texture; if (texture != null) { texture.load(info.data); } else { texture = new Texture(info.data); } if (parameter != null) { texture.setFilter(parameter.minFilter, parameter.magFilter); texture.setWrap(parameter.wrapU, parameter.wrapV); } return texture; } @Override public Array<AssetDescriptor> getDependencies (String fileName, FileHandle file, TextureParameter parameter) { return null; } static public class TextureParameter extends AssetLoaderParameters<Texture> { /** the format of the final Texture. Uses the source images format if null **/ public Format format = null; /** whether to generate mipmaps **/ public boolean genMipMaps = false; /** The texture to put the {@link TextureData} in, optional. **/ public Texture texture = null; /** TextureData for textures created on the fly, optional. When set, all format and genMipMaps are ignored */ public TextureData textureData = null; public TextureFilter minFilter = TextureFilter.Nearest; public TextureFilter magFilter = TextureFilter.Nearest; public TextureWrap wrapU = TextureWrap.ClampToEdge; public TextureWrap wrapV = TextureWrap.ClampToEdge; } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
eeca3748955c3f93696d003736c6674449039051
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/21/21_599ed39b55c600986c60055a48fe048999ffaa1a/RetryRequestTest/21_599ed39b55c600986c60055a48fe048999ffaa1a_RetryRequestTest_s.java
414ddcc5f2e2d81ad4ac8305d5b4153154b28fd5
[]
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,140
java
/* * Copyright 2010 Ning, Inc. * * Ning licenses this file to you under the Apache License, version 2.0 * (the "License"); you may not use this file except in compliance with the * License. You may obtain a copy of the License at: * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the * License for the specific language governing permissions and limitations * under the License. */ package com.ning.http.client.async; import com.ning.http.client.AsyncHttpClient; import com.ning.http.client.AsyncHttpClientConfig; import org.eclipse.jetty.server.Request; import org.eclipse.jetty.server.handler.AbstractHandler; import org.testng.annotations.Test; import javax.servlet.ServletException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import java.io.IOException; import java.io.OutputStream; import static org.testng.Assert.*; public abstract class RetryRequestTest extends AbstractBasicTest { public static class SlowAndBigHandler extends AbstractHandler { public void handle(String pathInContext, Request request, HttpServletRequest httpRequest, HttpServletResponse httpResponse) throws IOException, ServletException { int load = 100; httpResponse.setStatus(200); httpResponse.setContentLength(load); httpResponse.setContentType("application/octet-stream"); httpResponse.flushBuffer(); OutputStream os = httpResponse.getOutputStream(); for (int i = 0; i < load; i++) { os.write(i % 255); try { Thread.sleep(300); } catch (InterruptedException ex) { // nuku } if (i > load / 10) { httpResponse.sendError(500); } } httpResponse.getOutputStream().flush(); httpResponse.getOutputStream().close(); } } protected String getTargetUrl() { return String.format("http://127.0.0.1:%d/", port1); } @Override public AbstractHandler configureHandler() throws Exception { return new SlowAndBigHandler(); } @Test(groups = {"standalone", "default_provider"}) public void testMaxRetry() throws Throwable { AsyncHttpClient ahc = getAsyncHttpClient(new AsyncHttpClientConfig.Builder().setMaxRequestRetry(0).build()); try { ahc.executeRequest(ahc.prepareGet(getTargetUrl()).build()).get(); fail(); } catch (Exception t) { assertNotNull(t.getCause()); assertEquals(t.getCause().getClass(), IOException.class); assertEquals(t.getCause().getMessage(), "Remotely Closed"); } ahc.close(); } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
8b42041dd04f456dc24f23484f87a1cbba85bc14
9264e14fc2a694b916eb6268f36af162ef58b86d
/netbout-web/src/test/java/com/netbout/cached/package-info.java
75ee5c37771d35e523c3b6eb273148b7d712ae38
[]
no_license
longtimeago/netbout
a7d8938278ac5db0b406f00f199b9a0c09d856bb
9c3f731042095de1e5974388aeab21a43bb1f954
refs/heads/master
2021-01-17T22:34:56.290112
2014-06-16T13:29:58
2014-06-16T13:29:58
20,932,156
1
0
null
null
null
null
UTF-8
Java
false
false
1,545
java
/** * Copyright (c) 2009-2014, netbout.com * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are PROHIBITED without prior written permission from * the author. This product may NOT be used anywhere and on any computer * except the server platform of netbout Inc. located at www.netbout.com. * Federal copyright law prohibits unauthorized reproduction by any means * and imposes fines up to $25,000 for violation. If you received * this code accidentally and without intent to use it, please report this * incident to the author by email. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. */ /** * Cached base, tests. * * @author Yegor Bugayenko (yegor@tpc2.com) * @version $Id$ * @since 2.6 */ package com.netbout.cached;
[ "yegor@tpc2.com" ]
yegor@tpc2.com
2fc5cf17d3e4b9c383412d03273c9c287e7a7805
3e9051c7bd7fda57ef05932c1dc0139f69d8ee46
/src/org/minima/kissvm/statements/commands/MASTstatement.java
49630e3d272a9549897ba62dc50dfc60e31d7cd7
[ "Apache-2.0" ]
permissive
spartacusrex99/Minima
59c10b74ad9e8da5862cdb558a13c4ce45a79483
99e832037b31b9a187fb1124d4f65ce34ce65f8e
refs/heads/master
2020-12-06T02:34:53.768681
2020-09-28T11:20:27
2020-09-28T11:20:27
232,310,848
10
7
Apache-2.0
2020-07-14T09:29:34
2020-01-07T11:32:36
Java
UTF-8
Java
false
false
1,752
java
package org.minima.kissvm.statements.commands; import java.util.List; import org.minima.kissvm.Contract; import org.minima.kissvm.exceptions.ExecutionException; import org.minima.kissvm.expressions.Expression; import org.minima.kissvm.statements.Statement; import org.minima.kissvm.statements.StatementBlock; import org.minima.kissvm.statements.StatementParser; import org.minima.kissvm.tokens.Token; import org.minima.kissvm.values.HEXValue; import org.minima.objects.Witness; import org.minima.objects.proofs.ScriptProof; public class MASTstatement implements Statement { /** * The MAST script is a HEXvalue that is the hash of the script.. */ Expression mMASTScript; public MASTstatement(Expression zMAST) { mMASTScript = zMAST; } @Override public void execute(Contract zContract) throws ExecutionException { //get the MAST Value.. HEXValue mast = (HEXValue) mMASTScript.getValue(zContract); //Now get that Script from the transaction.. Witness wit = zContract.getWitness(); //Get the Script Proof ScriptProof scrpr = wit.getScript(mast.getMiniData()); if(scrpr == null) { throw new ExecutionException("No script found for MAST "+mast.getMiniData()); } //get the script of this hash value String script = scrpr.getScript().toString(); try { //Convert the script to KISSVM! List<Token> tokens = Token.tokenize(script); //And now convert to a statement block.. StatementBlock mBlock = StatementParser.parseTokens(tokens); //Now run it.. mBlock.run(zContract); } catch (Exception e) { // TODO Auto-generated catch block throw new ExecutionException(e.toString()); } } @Override public String toString() { return "MAST "+mMASTScript.toString(); } }
[ "patrickcerri@gmail.com" ]
patrickcerri@gmail.com
1205f99e693407dceeb3f8cbbb26fca77f7f00cc
56bb94e12c01d0e9b03d68ee8b67b02b027e7f8b
/src/item84/SlowCountDown.java
fdfe0943a904c0fa0e37f97d9957d0004150248d
[]
no_license
Lokie89/effective-java
8065b41488432a5c26704925897afd79925944c8
3567a6d20d5edc87488cc011308d937d6b05bd63
refs/heads/master
2022-12-13T13:55:08.354456
2020-09-09T06:50:31
2020-09-09T06:50:31
275,691,828
0
1
null
null
null
null
UTF-8
Java
false
false
543
java
package item84; public class SlowCountDown { private int count; public SlowCountDown(int count) { if (count < 0) { throw new IllegalArgumentException(count + "< 0"); } this.count = count; } public void await() { while (true) { synchronized (this) { if (count == 0) { return; } } } } public synchronized void countDown() { if (count != 0) { count--; } } }
[ "traeuman@gmail.com" ]
traeuman@gmail.com
7542f6f9d58a96b44af42fe2cbc5128fd3698e7d
d5578dc14d5083f6f2aba362a6d51080f8d7d3e2
/app/src/main/java/vn/poly/customlistview/StudentAdapter.java
506bebc925e7ea8d87de7543a74b59388154b562
[]
no_license
huuhuybn/CustomListView
9702634369d2adb806d79a1c120219f19ccccd4b
1a78939c6b0d3816c8f35529daa6692925ba7034
refs/heads/master
2020-05-26T13:28:16.587287
2019-05-23T14:09:52
2019-05-23T14:09:52
188,246,873
0
0
null
null
null
null
UTF-8
Java
false
false
1,331
java
package vn.poly.customlistview; import android.content.Context; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.BaseAdapter; import android.widget.TextView; import java.util.List; public class StudentAdapter extends BaseAdapter { private List<Student> students; private Context context; public StudentAdapter(Context context,List<Student> students){ this.students = students; this.context = context; } @Override public int getCount() { return students.size(); } @Override public Object getItem(int position) { return students.get(position); } @Override public long getItemId(int position) { return 0; } @Override public View getView(int position, View convertView, ViewGroup parent) { View view = LayoutInflater.from(context).inflate(R.layout.row,parent,false); TextView tvId = view.findViewById(R.id.tvId); TextView tvName = view.findViewById(R.id.tvName); TextView tvPhone = view.findViewById(R.id.tvPhone); tvId.setText(students.get(position).getId()); tvName.setText(students.get(position).getName()); tvPhone.setText(students.get(position).getNumberPhone()); return view; } }
[ "huuhuybn@gmail.com" ]
huuhuybn@gmail.com