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
e5a23bdffb61468d49fed3b3970fae20325a41e2
1b6cc19683b2e4512a6aa611b6c7bd1fa314136a
/[INC202]_Programacion_II_2018/certamenes/Pauta_Cert_01_2018/P2/GestionBodega.java
83b934caca35ecadef8e7089849623c2c0200d0a
[]
no_license
EdGoll/clases-uv
9f37f43b8410896e62df5b806ee04e045cfffb5f
7a86c563d5e73bba490b64dbc8f49d35c2370ccd
refs/heads/master
2021-06-21T20:42:48.444142
2019-08-18T20:04:14
2019-08-18T20:04:14
104,955,406
0
1
null
null
null
null
UTF-8
Java
false
false
2,588
java
import java.util.ArrayList; import java.util.List; import java.util.Scanner; import java.io.*; public class GestionBodega { private List<Producto> listaProductos = new ArrayList<Producto>(); //arreglo de tipo dinamico que permita guardar los productos public void crearProducto() throws IOException { /*crea un producto especifico y asigna el precio al cual el sistema debe agregarle el IVA sobre el precio ingresado y luego ingresarlo a listaProductos*/ Producto product; //VARIABLES DE BEAN int codigo = 0; String nombre = null; int stock = 0; double precio = 0; Integer answer=0; Scanner teclado = new Scanner(System.in); do{ System.out.println("Desea ingresar un producto? Responda Si=1 o No=0"); answer = teclado.nextInt(); System.out.println("Codigo: "); codigo = teclado.nextInt(); System.out.println("Nombre: "); nombre = teclado.nextLine(); System.out.println("Stock : "); stock = teclado.nextInt(); System.out.println("Precio: "); precio = teclado.nextDouble(); this.crearProducto(codigo, nombre, stock, precio); teclado.nextLine(); } while(answer!=0); } public void crearProducto(Integer codigo, String nombre,Integer stock, Double precio){ Producto product = new Producto(codigo, nombre, stock, precio); listaProductos.add(product); } public void listarStock() { /*visualiza el codigo, nombre y stock de cada producto*/ Producto inventario; if(listaProductos.isEmpty()){ System.out.println("No hay productos registrados en el inventario."); } else{ for(int i=0; i<(listaProductos.size())-1; i++){ inventario = listaProductos.get(i); System.out.println((i+1)+"- Codigo: " + inventario.getCodigo() + " - " + inventario.getNombre() + " - Stock: " + inventario.getStock()); } } } public void valorInventario(){ Double sumaValor=0.0; Double sumaValorIva=0.0; Double sumaValorTotal=0.0; Double sumaValorIvaTotal=0.0; for(int i=0; i<(listaProductos.size())-1; i++){ sumaValor = (listaProductos.get(i).getPrecio())*listaProductos.get(i).getStock(); sumaValorIva = (listaProductos.get(i).getPrecioConIva())*listaProductos.get(i).getStock(); System.out.println(listaProductos.get(i).getNombre() + " Valor Stock sin IVA: "+sumaValor); System.out.println(listaProductos.get(i).getNombre() + " Valor Stock con IVA: "+sumaValorIva ); sumaValorTotal += sumaValor; sumaValorIvaTotal += sumaValorIva; } System.out.println("Valor Total sin IVA: "+sumaValor); System.out.println("Valor Total con IVA: "+sumaValorIva); } }
[ "eduardo.gl@gmail.com" ]
eduardo.gl@gmail.com
9ec091bf202fe05f677a991801ff5802761539fd
916897ad4d764af6668b66331c58b48e16a3cd3a
/Seoul18App/app/src/main/java/com/example/minwoo/seoul18app/MainActivity.java
e241625e0396e39279c4ff1423b08ae11763b8d0
[]
no_license
MobileSeoul/2018seoul-51
550ba91d2a1037c75abb954ee2c17c38347bed61
f5b76e3b0cbc9b7a87106484bc1a37cb2b1d1801
refs/heads/master
2020-04-11T22:06:34.228303
2018-12-17T14:47:02
2018-12-17T14:47:02
162,125,450
5
1
null
null
null
null
UTF-8
Java
false
false
3,306
java
package com.example.minwoo.seoul18app; import android.Manifest; import android.content.Context; import android.content.Intent; import android.content.pm.PackageManager; import android.support.v4.app.ActivityCompat; import android.support.v4.content.ContextCompat; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; import android.view.View; import android.widget.Button; import android.widget.Toast; import java.util.ArrayList; public class MainActivity extends AppCompatActivity { Button startButton, addressButton, detectButton, button4, button5, button6; final Context context=this; ArrayList<String > phones; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); requestSmsPermission(); startButton=(Button)findViewById(R.id.button1); addressButton=(Button)findViewById(R.id.button2); detectButton=(Button)findViewById(R.id.button3); startButton.setOnClickListener(new Clicker1()); addressButton.setOnClickListener(new Clicker1()); detectButton.setOnClickListener(new Clicker1()); // TinyDB tinyDB=new TinyDB(context); //ArrayList<String> phones=tinyDB.getListString("phoneLists"); //Toast.makeText(this,phones.get(0),Toast.LENGTH_LONG).show(); } private void requestSmsPermission() { String permission = Manifest.permission.SEND_SMS; int grant = ContextCompat.checkSelfPermission(this, permission); if (grant != PackageManager.PERMISSION_GRANTED) { String[] permission_list = new String[1]; permission_list[0] = permission; ActivityCompat.requestPermissions(this, permission_list, 1); } } private class Clicker1 implements View.OnClickListener { public void onClick(View v) { Bundle myData; switch (v.getId()) { case R.id.button1: TinyDB tinyDB=new TinyDB(context); phones=tinyDB.getListString("phoneLists"); if(phones.size()>0) { Intent safeIntent = new Intent(context, SafeActivity.class); myData = new Bundle(); myData.putInt("myRequestCode", 101); startActivityForResult(safeIntent, 101); }else{ Toast.makeText(context,"연락처 관리에서 연락처를 최소 1개 이상 등록 후 사용해주세요",Toast.LENGTH_LONG).show(); } break; case R.id.button2: Intent addressIntent = new Intent(context, AddressActivity.class); myData = new Bundle(); myData.putInt("myRequestCode", 102); startActivityForResult(addressIntent, 102); break; case R.id.button3: Intent detectIntent = new Intent(context, DetectActivity.class); myData = new Bundle(); myData.putInt("myRequestCode", 103); startActivityForResult(detectIntent, 103); break; } } } }
[ "ianyrchoi@gmail.com" ]
ianyrchoi@gmail.com
0577f75c8cb6bf6a89e19590d7f761c261318966
e3a37aaf17ec41ddc7051f04b36672db62a7863d
/business-service/smart-home-service-project/smart-home-service/src/main/java/com/iot/shcs/device/queue/sender/DeviceDeleteSender.java
fdeebe90c1bf1d24a501b7d958c32aae3cb52441
[]
no_license
github4n/cloud
68477a7ecf81d1526b1b08876ca12cfe575f7788
7974042dca1ee25b433177e2fe6bda1de28d909a
refs/heads/master
2020-04-18T02:04:33.509889
2019-01-13T02:19:32
2019-01-13T02:19:32
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,380
java
package com.iot.shcs.device.queue.sender; import com.iot.common.mq.core.AbsSender; import com.iot.common.mq.enums.ExchangeTypeEnum; import com.iot.shcs.device.queue.bean.DeviceDeleteMessage; import com.iot.shcs.device.queue.utils.DeviceQueueConstants; import lombok.extern.slf4j.Slf4j; import org.springframework.amqp.rabbit.connection.ConnectionFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; import javax.annotation.PostConstruct; /** * @Author: lucky * @Descrpiton 设备删除发送 * @Date: 10:41 2018/8/10 * @Modify by: */ @Slf4j @Component public class DeviceDeleteSender extends AbsSender<DeviceDeleteMessage> { @Autowired private ConnectionFactory connectionFactory; /** * 必须实现的 */ @PostConstruct public void init() { super.preInit(); } @Override public ConnectionFactory connectionFactory() { return connectionFactory; } @Override public String exchange() { return DeviceQueueConstants.DEVICE_DELETE_EXCHANGE; } @Override public String routing() { return DeviceQueueConstants.DEVICE_DELETE_ROUTING; } @Override public String queue() { return null; } @Override public ExchangeTypeEnum type() { return ExchangeTypeEnum.FANOUT; } }
[ "qizhiyong@LDS-Z-C5497.LEEDARSON.LOCAL" ]
qizhiyong@LDS-Z-C5497.LEEDARSON.LOCAL
1196602dc0a6da80aa6fd31655759cd931cc6036
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/28/28_4e8888856d9658166b50fe82b10f78f7c5644f98/PBSocketInterface/28_4e8888856d9658166b50fe82b10f78f7c5644f98_PBSocketInterface_s.java
341b66c4fc7f486255cb33bee15c79409cd53486
[]
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
7,492
java
/* This file is part of Syncro. Copyright (c) Graeme Coupar <grambo@grambo.me.uk> Syncro 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. Syncro 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 Syncro. If not, see <http://www.gnu.org/licenses/>. */ package uk.me.grambo.syncro; import java.io.DataInputStream; import java.io.DataOutputStream; import java.io.IOException; import java.io.InputStream; import java.io.OutputStream; import java.util.ArrayList; import android.util.Log; import com.google.protobuf.CodedInputStream; import com.google.protobuf.ExtensionRegistryLite; import com.google.protobuf.GeneratedMessageLite; import uk.me.grambo.syncro.pb.Header; public class PBSocketInterface { private static final byte PB_REQUEST_FIRST_BYTE = 105; private static final byte PB_RESPONSE_FIRST_BYTE = 106; private ArrayList<PBResponseHandler> m_aResponseHandlers; public static class RequestTypes { public static final int BINARY_REQUEST = 1; public static final int BINARY_CONTINUE = 2; public static final int HANDSHAKE_REQUEST = 4; public static final int BINARY_INCOMING_REQUEST = 6; public static final int BINARY_INCOMING_DATA = 8; public static final int FILE_HASH_REQUEST = 16; public static String Str(int Type) { switch(Type) { case BINARY_REQUEST: return "Binary Request"; case BINARY_CONTINUE: return "Binary Continue"; case HANDSHAKE_REQUEST: return "Handshake Request"; case BINARY_INCOMING_REQUEST: return "Binary Incoming Request"; case BINARY_INCOMING_DATA: return "Binary Incoming Data"; case FILE_HASH_REQUEST: return "File Hash Request"; } return "Unknown"; } }; public static class ResponseTypes { public static final int BINARY_RESPONSE = 3; public static final int HANDSHAKE_RESPONSE = 5; public static final int BINARY_INCOMING_RESPONSE = 7; public static final int BINARY_INCOMING_DATA_ACK = 9; public static final int FILE_HASH_RESPONSE = 17; public static String Str(int Type) { switch(Type) { case BINARY_RESPONSE: return "Binary Resposne"; case HANDSHAKE_RESPONSE: return "Handshake Response"; case BINARY_INCOMING_RESPONSE: return "Binary Incoming Response"; case BINARY_INCOMING_DATA_ACK: return "Binary Incoming Data Ack"; case FILE_HASH_RESPONSE: return "File Hash Response"; } return "Unknown"; } }; public PBSocketInterface() { m_aResponseHandlers = new ArrayList<PBResponseHandler>(); } public void WriteInitialHeader(OutputStream inoStream,int innHeaderSize) throws IOException { DataOutputStream oOutput = new DataOutputStream(inoStream); oOutput.writeByte(PB_REQUEST_FIRST_BYTE); oOutput.writeInt(innHeaderSize); oOutput.flush(); } public void SendMessage(OutputStream inoStream,int inType) throws IOException { Header.PacketHeader oHeader = Header.PacketHeader.newBuilder() .setPacketType(inType) .build(); //Log.d("Syncro","Sending Message. Header:\n" + oHeader.toString() ); //Log.d("Syncro", "Sending message: " + RequestTypes.Str(inType)); WriteInitialHeader(inoStream,oHeader.getSerializedSize()); oHeader.writeTo(inoStream); inoStream.flush(); //Log.d("Syncro","Finished sending"); } public void SendObject(OutputStream inoStream,int inType,GeneratedMessageLite inoMessage) throws IOException { //Wraps the object in a header and sends it Header.PacketHeader oHeader = Header.PacketHeader.newBuilder() .setPacketType(inType) .addSubpacketSizes( inoMessage.getSerializedSize() ) .build(); //Log.d("Syncro","Sending Object. Type: " + inType); //Log.d("Syncro","Header:\n" + oHeader.toString() ); //Log.d("Syncro","Object:\n" + inoMessage.toString() ); //Log.d("Syncro", "Sending message: " + RequestTypes.Str(inType)); WriteInitialHeader(inoStream,oHeader.getSerializedSize()); oHeader.writeTo(inoStream); inoMessage.writeTo(inoStream); inoStream.flush(); Log.d("Syncro","Finished sending"); } public void SendObjectAndData( OutputStream inoStream, int inType, GeneratedMessageLite inoMessage, byte[] inoData, int inDataSize ) throws IOException { Header.PacketHeader oHeader = Header.PacketHeader.newBuilder() .setPacketType(inType) .addSubpacketSizes( inoMessage.getSerializedSize() ) .addSubpacketSizes( inDataSize ) .build(); /*Log.d("Syncro", "Sending message: " + RequestTypes.Str(inType) + " (+" + Integer.valueOf(inDataSize).toString() + " bytes)" ); */ WriteInitialHeader( inoStream, oHeader.getSerializedSize() ); oHeader.writeTo( inoStream ); inoMessage.writeTo( inoStream ); inoStream.write( inoData, 0, inDataSize ); inoStream.flush(); Log.d("Syncro","Finished sending"); } public void HandleResponse(InputStream inoStream) throws Exception,IOException { DataInputStream oInput = new DataInputStream(inoStream); byte nFirstByte = oInput.readByte(); if( nFirstByte != PB_RESPONSE_FIRST_BYTE ) throw new Exception( "Invalid first byte in PBSocketInterface::GetResponse - " + nFirstByte); int nHeaderSize = oInput.readInt(); //Log.d("Syncro","Reading Header Size: " + nHeaderSize+"\n"); byte aBuffer[] = new byte[nHeaderSize]; oInput.read(aBuffer); /*CodedInputStream oMessageInputStream = CodedInputStream.newInstance(inoStream); //oMessageInputStream.setSizeLimit(nHeaderSize); */ Header.PacketHeader.Builder oHeaderBuilder = Header.PacketHeader.newBuilder(); //oHeaderBuilder.mergeFrom(oMessageInputStream); //TODO: Figure out how to use CodedInputStream oHeaderBuilder.mergeFrom(aBuffer); //Log.d("Syncro","Received " + ResponseTypes.Str( oHeaderBuilder.getPacketType() ) ); //Log.d("Syncro","Recieved Header:\n" + oHeaderBuilder.toString() ); PBResponseHandler oSelectedHandler = null; for( PBResponseHandler oHandler : m_aResponseHandlers ) { if( oHandler.canHandleResponse( oHeaderBuilder.getPacketType() ) ) { int nSubpacketSizes[] = new int[oHeaderBuilder.getSubpacketSizesCount()]; for(int nSubpacket=0; nSubpacket < oHeaderBuilder.getSubpacketSizesCount(); nSubpacket++ ) { nSubpacketSizes[nSubpacket] = oHeaderBuilder.getSubpacketSizes(nSubpacket); } oHandler.handleResponse(nSubpacketSizes, inoStream); oSelectedHandler = oHandler; break; } } if( oSelectedHandler != null ) { if( oSelectedHandler.canRemove() ) m_aResponseHandlers.remove(oSelectedHandler); } else { throw new Exception("Unknown packet type sent to PBSocketInterface::GetResponse"); } } public void addResponseHandler(PBResponseHandler inoHandler) { m_aResponseHandlers.add(inoHandler); } public void removeResponseHandler(PBResponseHandler inoHandler) { m_aResponseHandlers.remove(inoHandler); } public void clearAllResponseHandlers() { m_aResponseHandlers.clear(); } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
a2487c579e1962918a91061027f7332c60ca687a
aa1e12ee5b74546a6853aba6fcde9625ef702e8d
/datafilter/common/src/main/java/com/sangame/datafilter/common/util/PageUtil.java
78fd8d4b5528186152245db6032da17827873cfd
[]
no_license
scq355/ssm
fc9ab5598397c1113b5db2e5c85a7e9066a45586
a1d4d19dd1288f1b79c3e7dfd8ff8b23af3f334c
refs/heads/master
2023-08-28T06:24:37.826730
2019-07-24T16:53:31
2019-07-24T16:53:31
166,950,376
0
0
null
2023-09-13T14:21:54
2019-01-22T07:44:25
HTML
UTF-8
Java
false
false
2,835
java
package com.sangame.datafilter.common.util; import java.util.List; /** * 封装分页信息 * @author Administrator * */ public class PageUtil { //默认每页10条 private static int DEFAULT_PAGE_SIZE = 10; //结果集 private List<Object> list; //查询记录数 private int totalRecords; //每页多少条数据 private int pageSize; //第几页 private int pageNo; private int startRow; private String orderBy; public PageUtil(Integer pageStart, Integer pageSize) { if(pageStart == null || pageStart < 0){ pageStart = 0; } this.startRow = pageStart; if(pageSize==null || pageSize < 1) { pageSize = DEFAULT_PAGE_SIZE; } this.pageSize = pageSize; } /* public PageUtil(int pageNo, Integer pageSize) { if(pageSize==null || pageSize < 1) { pageSize = DEFAULT_PAGE_SIZE; } this.pageSize = pageSize; if(pageNo<=0){ this.pageNo =1; this.startRow = 0; } else { this.startRow = (pageNo-1)*pageSize; } }*/ /** * 总页数 * @return */ public int getTotalPages() { return (totalRecords + pageSize - 1) / pageSize; } /** * 取得首页 * @return */ public int getTopPageNo() { return 1; } /** * 上一页 * @return */ public int getPreviousPageNo() { if (pageNo <= 1) { return 1; } return pageNo - 1; } /** * 下一页 * @return */ public int getNextPageNo() { if (pageNo >= getBottomPageNo()) { return getBottomPageNo(); } return pageNo + 1; } /** * 取得尾页 * @return */ public int getBottomPageNo() { return getTotalPages(); } public List<Object> getList() { return list; } public void setList(List<Object> list) { this.list = list; } public int getTotalRecords() { return totalRecords; } public void setTotalRecords(int totalRecords) { this.totalRecords = totalRecords; } public int getPageSize() { return pageSize; } public void setPageSize(int pageSize) { this.pageSize = pageSize; } public int getPageNo() { return pageNo; } public void setPageNo(int pageNo) { this.pageNo = pageNo; } public int getStartRow() { return startRow; } public void setStartRow(int startRow) { this.startRow = startRow; } public String getOrderBy() { return orderBy; } public void setOrderBy(String orderBy) { this.orderBy = orderBy; } }
[ "1637517653@qq.com" ]
1637517653@qq.com
b9890d5d4bae2d1f20cb39b4bfed0c480f6fefa2
f3e6a4e6010f76be40e80fa18392ec004507f9f7
/bojha/src/StackImpl.java
e8277a2f89309f521b6d941f7c9b8cb6d0024204
[]
no_license
Fawzy1/allgo
be1008e003e39e32a6f76e3c5fb145c16e6a6fec
3516e52541884f767dc590e3544f1e5291b25d5e
refs/heads/master
2021-01-19T23:24:48.757555
2016-03-08T16:55:21
2016-03-08T16:55:21
null
0
0
null
null
null
null
UTF-8
Java
false
false
304
java
import java.util.Stack; public class StackImpl { public static void main(String[] args) { int n = 50; Stack<Integer> stack = new Stack<Integer>(); while (n > 0) { stack.push(n % 2); n = n / 2; } for (int d: stack) { System.out.print(d); } System.out.println(); } }
[ "debmalya.jash@gmail.com" ]
debmalya.jash@gmail.com
edb8fefe5d56e76086080b8f4c4c63cff7cc5027
06117f0ce8afd9d60f1788e5bed832176e7ec14a
/study/springboot-study2/miniapp/src/main/java/com/tgy/miniapp/WechatPublicAccount.java
2907494f0a61a1317d9fbb409158b9c3796cfed9
[]
no_license
tgy616/myprojects
489454bc8d6634e4e133ee684b34928df0df57e2
5e11134ddbb65d8166a6dc65a90f3ee0ef4c4788
refs/heads/master
2022-12-25T10:59:29.954207
2020-10-24T03:28:17
2020-10-24T03:28:17
161,139,757
0
0
null
2022-12-16T05:16:13
2018-12-10T08:09:20
Java
UTF-8
Java
false
false
1,007
java
package com.tgy.miniapp; import java.util.TreeMap; /** * @author tanggy * @date 2018/10/9 */ public class WechatPublicAccount { public static final String GET_ACCESS_TOKEN_URL = "https://api.weixin.qq.com/cgi-bin/token"; /** * 获取授权凭证token * @param key 应用appid * @param secret 应用密匙 * @return json格式的字符串 */ public static String getAccessToken(String appid, String secret) { TreeMap<String, String> map = new TreeMap<String, String>(); map.put("grant_type", "client_credential"); map.put("appid", appid); map.put("secret", secret); String json = HttpReqUtil.HttpDefaultExecute(SystemConfig.GET_METHOD, WechatConfig.GET_ACCESS_TOKEN_URL, map, ""); String result = null; AccessToken accessToken = JsonUtil.fromJsonString(json, AccessToken.class); if (accessToken != null) { result = accessToken.getAccess_token(); } return result; } }
[ "418982690@qq.com" ]
418982690@qq.com
9e34a08a69ea0f1aa2a39ab5423c6517481c8859
b97bc0706448623a59a7f11d07e4a151173b7378
/src/main/java/radian/tcmis/server7/client/swa/servlets/SWASearchInfoNew.java
ebbf236adcc9ffed848609c1c3dbba8a11cd8d93
[]
no_license
zafrul-ust/tcmISDev
576a93e2cbb35a8ffd275fdbdd73c1f9161040b5
71418732e5465bb52a0079c7e7e7cec423a1d3ed
refs/heads/master
2022-12-21T15:46:19.801950
2020-02-07T21:22:50
2020-02-07T21:22:50
241,601,201
0
0
null
2022-12-13T19:29:34
2020-02-19T11:08:43
Java
UTF-8
Java
false
false
1,004
java
package radian.tcmis.server7.client.swa.servlets; import radian.tcmis.server7.share.helpers.*; import radian.tcmis.server7.share.servlets.*; import radian.tcmis.server7.client.swa.dbObjs.*; import radian.tcmis.server7.client.swa.helpers.*; import javax.servlet.*; import javax.servlet.http.*; import java.io.*; public class SWASearchInfoNew extends HttpServlet { public void init(ServletConfig config) throws ServletException { super.init(config); } public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { SWATcmISDBModel db = null; try { //db = new SWATcmISDBModel(); db = new SWATcmISDBModel("SWA",(String)request.getHeader("logon-version")); SearchInfoNew obj = new SearchInfoNew((ServerResourceBundle) new SWAServerResourceBundle(),db); obj.doPost(request,response); } catch (Exception e){ e.printStackTrace(); } finally { db.close(); } } }
[ "julio.rivero@wescoair.com" ]
julio.rivero@wescoair.com
896dbca148b05c9577f66a0607ff5bb4fda37aa7
c80f25f9c8faa1ea9db5bb1b8e36c3903a80a58b
/laosiji-sources/feng/android/sources/com/meizu/cloud/pushsdk/base/reflect/ReflectClass.java
3dcc22bf61024fbfb6a246b19caef4b5438df631
[]
no_license
wenzhaot/luobo_tool
05c2e009039178c50fd878af91f0347632b0c26d
e9798e5251d3d6ba859bb15a00d13f085bc690a8
refs/heads/master
2020-03-25T23:23:48.171352
2019-09-21T07:09:48
2019-09-21T07:09:48
144,272,972
0
0
null
null
null
null
UTF-8
Java
false
false
1,594
java
package com.meizu.cloud.pushsdk.base.reflect; import java.util.HashMap; public class ReflectClass { private static HashMap<String, Class<?>> mCachedClasses = new HashMap(); private Class<?> mClass; private String mClassName; private Object mClassObject; private ReflectClass(String name) { this.mClassName = name; } private ReflectClass(Object object) { this.mClassObject = object; } public ReflectClass(Class<?> clz) { this.mClass = clz; } Class<?> getRealClass() throws ClassNotFoundException { if (this.mClass != null) { return this.mClass; } if (this.mClassObject != null) { return this.mClassObject.getClass(); } Class<?> clz = (Class) mCachedClasses.get(this.mClassName); if (clz != null) { return clz; } clz = Class.forName(this.mClassName); mCachedClasses.put(this.mClassName, clz); return clz; } public static ReflectClass forName(String className) { return new ReflectClass(className); } public static ReflectClass forObject(Object classObject) { return new ReflectClass(classObject); } public ReflectMethod method(String methodName, Class<?>... types) { return new ReflectMethod(this, methodName, types); } public ReflectField field(String fieldName) { return new ReflectField(this, fieldName); } public ReflectConstructor constructor(Class<?>... types) { return new ReflectConstructor(this, types); } }
[ "tanwenzhao@vipkid.com.cn" ]
tanwenzhao@vipkid.com.cn
acddf9b7a11333750743f38010f2630c4fa07a1b
96865ea6782ab689c341356c9e9f86f7e0ae1365
/gwt-jackson/src/test/java/com/github/nmorel/gwtjackson/client/annotation/JsonAutoDetectGwtTest.java
e9076f5635022326cdf23a6987bdfb776d2aa7b6
[ "Apache-2.0" ]
permissive
nmorel/gwt-jackson
60e2bda4072489d9960e06ea6513a4e68d65d8ca
688cdca205f1ec3554509a5df2d18d594a47a5ff
refs/heads/master
2023-08-25T01:52:50.537529
2021-02-21T12:11:37
2021-02-21T12:11:37
12,341,002
91
62
Apache-2.0
2022-07-15T21:05:14
2013-08-24T09:24:43
Java
UTF-8
Java
false
false
1,894
java
/* * Copyright 2013 Nicolas Morel * * 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.nmorel.gwtjackson.client.annotation; import com.github.nmorel.gwtjackson.client.GwtJacksonTestCase; import com.github.nmorel.gwtjackson.client.JsonDeserializationContext; import com.github.nmorel.gwtjackson.client.ObjectMapper; import com.github.nmorel.gwtjackson.shared.ObjectMapperTester; import com.github.nmorel.gwtjackson.shared.annotations.JsonAutoDetectTester; import com.github.nmorel.gwtjackson.shared.annotations.JsonAutoDetectTester.BeanOne; import com.google.gwt.core.client.GWT; /** * @author Nicolas Morel */ public class JsonAutoDetectGwtTest extends GwtJacksonTestCase { public interface JsonAutoDetectMapper extends ObjectMapper<BeanOne>, ObjectMapperTester<BeanOne> { static JsonAutoDetectMapper INSTANCE = GWT.create( JsonAutoDetectMapper.class ); } private JsonAutoDetectTester tester = JsonAutoDetectTester.INSTANCE; public void testSerializeAutoDetection() { tester.testSerializeAutoDetection( JsonAutoDetectMapper.INSTANCE ); } public void testDeserializeAutoDetection() { tester.testDeserializeAutoDetection( createMapper( JsonAutoDetectMapper.INSTANCE, JsonDeserializationContext.builder() .failOnUnknownProperties( false ).build(), newDefaultSerializationContext() ) ); } }
[ "nmr.morel@gmail.com" ]
nmr.morel@gmail.com
eb0a2f90d4e5007bb50fe3963e82ea6523470771
13c2d3db2d49c40c74c2e6420a9cd89377f1c934
/program_data/JavaProgramData/28/493.java
8a80296b7e36e46a9514e1d0a80f87f1316db95d
[ "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
620
java
package <missing>; public class GlobalMembers { public static int Main() { String str = new String(new char[3000]); int i = 0; int flag = 0; int letter = 0; str = new Scanner(System.in).nextLine(); while (true) { if (str.charAt(i) == ' ' || str.charAt(i) == '\0') { if (letter != 0) { if (flag != 0) { System.out.print(","); } else { flag = 1; } System.out.printf("%d",letter); letter = 0; } } else { letter++; } if (!str.charAt(i)) { break; } i++; } return 1; } }
[ "y.yu@open.ac.uk" ]
y.yu@open.ac.uk
933dd473402da405449630399732bb7644ad960b
c8cdff97fb4b6ce366bb6ab9adaff866b761a791
/src/day07_arithmetic_operators_casting/DivisionProblem.java
6ba61764d1f21d8ae3e95cf20343bbff06fedb8c
[]
no_license
SDET222/java-programmingC
6a50c147f526f60382c8febfe68c1a1c7f2921b2
f6098a8a3ff2412135120efde901ab3ac558c362
refs/heads/master
2023-06-22T00:48:25.451665
2021-07-26T23:51:53
2021-07-26T23:51:53
366,196,266
0
0
null
null
null
null
UTF-8
Java
false
false
586
java
package day07_arithmetic_operators_casting; public class DivisionProblem { public static void main (String [] args) { System.out.println(10/3); System.out.println(5/2); System.out.println(10/3.0); int num1 = 40; int num2 = 15; System.out.println(num1/num2); System.out.println(5.0/2.0); System.out.println(5.0/2); double d1 = 12.0; double d2 = 5.0; System.out.println(d1/d2); int count = 100; double dCount = 30.0; System.out.println(count/dCount); } }
[ "jkrogers222@gmail.com" ]
jkrogers222@gmail.com
82b8a7af38d97f09e22de2c889a8f1fd2e1bc22a
58dc95ed1ee4b6bb7c4c79d836b51bde59e069ca
/src/main/java/io/dummymaker/annotation/simple/string/GenEthTxHash.java
cee51a3d29bb82effc914df56fbb85a7f6d0fce5
[ "MIT" ]
permissive
morristech/dummymaker
f5f03c9e08a71a5fba2c784dc531555cf903b2b1
fdff8ebf116e90026994b38c8b3c08a8420a3550
refs/heads/master
2023-03-12T13:45:55.840611
2020-12-18T20:37:29
2020-12-18T20:37:29
null
0
0
null
null
null
null
UTF-8
Java
false
false
545
java
package io.dummymaker.annotation.simple.string; import io.dummymaker.annotation.core.PrimeGen; import io.dummymaker.generator.simple.string.EthTxHashGenerator; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; /** * @author GoodforGod * @see EthTxHashGenerator * @since 04.11.2018 */ @PrimeGen(EthTxHashGenerator.class) @Retention(value = RetentionPolicy.RUNTIME) @Target(ElementType.FIELD) public @interface GenEthTxHash { }
[ "goodforgod.dev@gmail.com" ]
goodforgod.dev@gmail.com
db40cb795dd2a69b0ce560f7d9d498d820f02e3f
651cfec1a9b96587206afcf65746e32040d51611
/AndroidProject01_Activity_LifeCycle/app/src/main/java/com/mycompany/myapp/FullActivity.java
2e1a4d1f4c0a1ab176a1703361015df21cf69de0
[]
no_license
Jdongju/TestRepository
143967fc13e70cf3e69dc0ba31ddc4577fb1f664
f659ba3b39d044b7addbc7ac3ea258ed9ab528e2
refs/heads/master
2021-01-20T00:47:25.514692
2017-07-20T01:17:49
2017-07-20T01:17:49
89,189,022
0
0
null
null
null
null
UTF-8
Java
false
false
397
java
package com.mycompany.myapp; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; import android.util.Log; public class FullActivity extends AppCompatActivity { @Override protected void onCreate(Bundle savedInstanceState) { Log.i(Utils.getTag(), "실행"); super.onCreate(savedInstanceState); setContentView(R.layout.activity_full); } }
[ "dj9110@naver.com" ]
dj9110@naver.com
2d520f6850883ef12f87104dd19fac48553506b4
121d9fc73fc4c062b04c163612970a0e3018989e
/src/main/java/io/airlift/slice/ByteArrays.java
dfd951fd07a609495f3788480895ab7ab067ab0e
[ "Apache-2.0" ]
permissive
raghavsethi/slice
4c7cf68297a9132fd83617ae3428b3723114b22e
a6172f08a180a314acd877c2af0151c0aba43f99
refs/heads/master
2021-01-11T01:55:38.772720
2016-12-26T03:09:54
2016-12-28T21:49:23
70,834,899
0
0
null
2016-10-13T18:14:45
2016-10-13T18:14:44
null
UTF-8
Java
false
false
2,309
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 io.airlift.slice; import static io.airlift.slice.JvmUtils.unsafe; import static io.airlift.slice.Preconditions.checkPositionIndexes; import static io.airlift.slice.SizeOf.SIZE_OF_DOUBLE; import static io.airlift.slice.SizeOf.SIZE_OF_FLOAT; import static io.airlift.slice.SizeOf.SIZE_OF_INT; import static io.airlift.slice.SizeOf.SIZE_OF_LONG; import static io.airlift.slice.SizeOf.SIZE_OF_SHORT; import static sun.misc.Unsafe.ARRAY_BYTE_BASE_OFFSET; public final class ByteArrays { private ByteArrays() {} public static short getShort(byte[] bytes, int index) { checkIndexLength(bytes.length, index, SIZE_OF_SHORT); return unsafe.getShort(bytes, ((long) ARRAY_BYTE_BASE_OFFSET) + index); } public static int getInt(byte[] bytes, int index) { checkIndexLength(bytes.length, index, SIZE_OF_INT); return unsafe.getInt(bytes, ((long) ARRAY_BYTE_BASE_OFFSET) + index); } public static long getLong(byte[] bytes, int index) { checkIndexLength(bytes.length, index, SIZE_OF_LONG); return unsafe.getLong(bytes, ((long) ARRAY_BYTE_BASE_OFFSET) + index); } public static float getFloat(byte[] bytes, int index) { checkIndexLength(bytes.length, index, SIZE_OF_FLOAT); return unsafe.getFloat(bytes, ((long) ARRAY_BYTE_BASE_OFFSET) + index); } public static double getDouble(byte[] bytes, int index) { checkIndexLength(bytes.length, index, SIZE_OF_DOUBLE); return unsafe.getDouble(bytes, ((long) ARRAY_BYTE_BASE_OFFSET) + index); } private static void checkIndexLength(int arrayLength, int index, int typeLength) { checkPositionIndexes(index, index + typeLength, arrayLength); } }
[ "david@acz.org" ]
david@acz.org
c143cd8289ab93fb4b477bbc7bad69fb797753ce
ed5159d056e98d6715357d0d14a9b3f20b764f89
/test/irvine/oeis/a000/A000975Test.java
0625a9f516b6b979bdcd79b06641b657ab85c999
[]
no_license
flywind2/joeis
c5753169cf562939b04dd246f8a2958e97f74558
e5efd6971a0062ac99f4fae21a7c78c9f9e74fea
refs/heads/master
2020-09-13T18:34:35.080552
2019-11-19T05:40:55
2019-11-19T05:40:55
null
0
0
null
null
null
null
UTF-8
Java
false
false
195
java
package irvine.oeis.a000; import irvine.oeis.AbstractSequenceTest; /** * Tests the corresponding class. * @author Sean A. Irvine */ public class A000975Test extends AbstractSequenceTest { }
[ "sairvin@gmail.com" ]
sairvin@gmail.com
a1ad7759370df38236f547d823f72df016c3616f
627b5fa45456a81a5fc65f4b04c280bba0e17b01
/code-maven-plugin/trunk/aili/aili-rpc/src/main/java/org/hbhk/aili/rpc/share/ex/dubbo/AppTest.java
301984b8b3fcec29f2288da7ddc3a2aad0d7420c
[]
no_license
zgdkik/aili
046e051b65936c4271dd01b866a3c263cfb884aa
e47e3c62afcc7bec9409aff952b11600572a8329
refs/heads/master
2020-03-25T01:29:14.798728
2018-04-07T06:58:45
2018-04-07T06:58:45
null
0
0
null
null
null
null
UTF-8
Java
false
false
254
java
package org.hbhk.aili.rpc.share.ex.dubbo; /** * * @Description: 远程调用增强处理 * @author 何波 * @date 2015年3月11日 上午10:05:24 * */ public class AppTest { public static void main(String[] args) { } }
[ "1024784402@qq.com" ]
1024784402@qq.com
6694d30d560134a374b04fc1f91816dd07399e61
04f43fbba11a186154cfe65ab2f6ce3df38e0755
/src/com/aotuspace/aotucms/web/spaotumcenter/hbm/SpAotuspacePriv.java
fae250581416bd5f46a6282e062e34c7fb7de170
[]
no_license
zowbman/aotucms
f082b22df0ca046db194376b551ac34aa6bd4db3
25f5fab95bf682f10c27fa175171816905638bc4
refs/heads/master
2020-05-23T08:10:55.357593
2016-10-08T02:31:02
2016-10-08T02:31:03
70,296,302
0
0
null
null
null
null
GB18030
Java
false
false
2,138
java
package com.aotuspace.aotucms.web.spaotumcenter.hbm; import java.io.Serializable; import java.util.Set; import java.util.TreeSet; /** * * Title:SpEmployeePrivilege * Description:权限表 * Company:aotuspace * @author sida * @date 2015-9-14 下午2:37:59 * */ public class SpAotuspacePriv implements Serializable { private Integer spId; private String spName; //权限名称 private String spUrl;//权限地址 private SpAotuspacePriv privParent; private Set<SpAotuspacePriv> privsChildren=new TreeSet<SpAotuspacePriv>(); private Set<SpUsersBinfo> spUsers=new TreeSet<SpUsersBinfo>(); private Set<SpUsersIdentity> spUserIdents=new TreeSet<SpUsersIdentity>(); private Set<SpAotuspaceRole> spUserRoles=new TreeSet<SpAotuspaceRole>(); private String spState;//权限展开状态 public Integer getSpId() { return spId; } public void setSpId(Integer spId) { this.spId = spId; } public String getSpName() { return spName; } public void setSpName(String spName) { this.spName = spName; } public String getSpUrl() { return spUrl; } public void setSpUrl(String spUrl) { this.spUrl = spUrl; } public SpAotuspacePriv getPrivParent() { return privParent; } public void setPrivParent(SpAotuspacePriv privParent) { this.privParent = privParent; } public Set<SpAotuspacePriv> getPrivsChildren() { return privsChildren; } public void setPrivsChildren(Set<SpAotuspacePriv> privsChildren) { this.privsChildren = privsChildren; } public String getSpState() { return spState; } public void setSpState(String spState) { this.spState = spState; } public Set<SpUsersIdentity> getSpUserIdents() { return spUserIdents; } public void setSpUserIdents(Set<SpUsersIdentity> spUserIdents) { this.spUserIdents = spUserIdents; } public Set<SpAotuspaceRole> getSpUserRoles() { return spUserRoles; } public void setSpUserRoles(Set<SpAotuspaceRole> spUserRoles) { this.spUserRoles = spUserRoles; } public Set<SpUsersBinfo> getSpUsers() { return spUsers; } public void setSpUsers(Set<SpUsersBinfo> spUsers) { this.spUsers = spUsers; } }
[ "zhangweibao@kugou.net" ]
zhangweibao@kugou.net
efacf8b71a0917d74958dda098847b2fd3eed600
3f42d48aca25d2f011d8f68e575006138ab086bd
/csccrt-system/src/main/java/com/qx/system/service/ISysDeptService.java
c1c870dae72ec55704430a8ab87c70356be2a5ab
[]
no_license
xsdo/shrz
fc6e2128b28d2fa0880a8e43b90383e75dc2bc04
e0c0ac25713b4704a8170a23402b20ab99a69dfc
refs/heads/master
2023-06-29T09:23:44.703733
2021-08-05T07:11:50
2021-08-05T07:11:50
391,006,464
0
0
null
null
null
null
UTF-8
Java
false
false
2,565
java
package com.qx.system.service; import java.util.List; import com.qx.system.domain.SysDept; import com.qx.system.domain.TreeSelect; /** * 部门管理 服务层 * * @author ruoyi */ public interface ISysDeptService { /** * 查询部门管理数据 * * @param dept 部门信息 * @return 部门信息集合 */ public List<SysDept> selectDeptList(SysDept dept); /** * 构建前端所需要树结构 * * @param depts 部门列表 * @return 树结构列表 */ public List<SysDept> buildDeptTree(List<SysDept> depts); /** * 构建前端所需要下拉树结构 * * @param depts 部门列表 * @return 下拉树结构列表 */ public List<TreeSelect> buildLowerDeptTree(Long deptId); /** * 构建前端所需要下拉树结构 * * @param depts 部门列表 * @return 下拉树结构列表 */ public List<TreeSelect> buildDeptTreeSelect(List<SysDept> depts); /** * 根据角色ID查询部门树信息 * * @param roleId 角色ID * @return 选中部门列表 */ public List<Integer> selectDeptListByRoleId(Long roleId); /** * 根据部门ID查询信息 * * @param deptId 部门ID * @return 部门信息 */ public SysDept selectDeptById(Long deptId); /** * 是否存在部门子节点 * * @param deptId 部门ID * @return 结果 */ public boolean hasChildByDeptId(Long deptId); /** * 查询部门是否存在用户 * * @param deptId 部门ID * @return 结果 true 存在 false 不存在 */ public boolean checkDeptExistUser(Long deptId); /** * 校验部门名称是否唯一 * * @param dept 部门信息 * @return 结果 */ public String checkDeptNameUnique(SysDept dept); /** * 新增保存部门信息 * * @param dept 部门信息 * @return 结果 */ public int insertDept(SysDept dept); /** * 修改保存部门信息 * * @param dept 部门信息 * @return 结果 */ public int updateDept(SysDept dept); /** * 删除部门管理信息 * * @param deptId 部门ID * @return 结果 */ public int deleteDeptById(Long deptId); /** * 构建前端所需要下拉树结构 * * @param depts 部门列表 * @return 下拉树结构列表 */ public List<TreeSelect> buildDeptAndUserTreeSelect(SysDept dept); }
[ "31725552@qq.com" ]
31725552@qq.com
bd024d1659b3a64b9374c78c7abe8229ab76f501
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/9/9_e16ac30fa5e761567c8c77eca60df916b4a1d282/SpecGenerator/9_e16ac30fa5e761567c8c77eca60df916b4a1d282_SpecGenerator_s.java
1bff3f1104c5dbbc264ebd7e4171fc503e6e87bd
[]
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
8,147
java
/******************************************************************************* * Copyright (c) 2009 The University of York. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/epl-v10.html * * Contributors: * Louis Rose - initial API and implementation ****************************************************************************** * * $Id$ */ package org.eclipse.epsilon.hutn.xmi.parser.generator; import org.eclipse.emf.ecore.EPackage; import org.eclipse.emf.ecore.EStructuralFeature; import org.eclipse.epsilon.hutn.model.hutn.ClassObject; import org.eclipse.epsilon.hutn.model.hutn.ContainmentSlot; import org.eclipse.epsilon.hutn.model.hutn.HutnFactory; import org.eclipse.epsilon.hutn.model.hutn.NsUri; import org.eclipse.epsilon.hutn.model.hutn.PackageObject; import org.eclipse.epsilon.hutn.model.hutn.Slot; import org.eclipse.epsilon.hutn.model.hutn.Spec; import org.eclipse.epsilon.hutn.xmi.util.EmfUtil; import org.eclipse.epsilon.hutn.xmi.util.HutnUtil; import org.eclipse.epsilon.hutn.xmi.util.Stack; /** * <p>Generates a HUTN spec in a LIFO manner. ClassObjects are generated * using {@link #generateTopLevelClassObject(String)} and * {@link #generateContainedClassObject(String, String)}.</p> * * <p>Before generating any ClassObjects, the generator must first be * initialised using {@link #initialise()} or {@link #initialise(String)}.</p> * * <p>To nest class objects, first use a call to * {@link #generateTopLevelClassObject(String)} and then add levels of * nesting with {@link #generateContainedClassObject(String)}.</p> * * <p>A call to {@link #stopGeneratingCurrentClassObject()} completes the * generation of the current class object. Furthermore, the next class * object to be generated will have the same parent as the last class * object to be generated.</p> * * <p>Example: To generate the following structure: * <pre> Family { * members: Person { dog: Dog {} }, Person {} * }</pre> * * the following calls would be made: * <pre> initialise("families"); * generateTopLevelClassObject("Family"); * generateContainedClassObject("Person"); * generateContainedClassObject("Dog"); * stopGeneratingCurrentClassObject(); // Dog * stopGeneratingCurrentClassObject(); // Person * generateContainedClassObject("Person"); * stopGeneratingCurrentClassObject(); * stopGeneratingCurrentClassObject(); // Family</pre> * * The last two lines are optional, if no further ClassObjects are to * be generated.</p> * * @author lrose */ public class SpecGenerator { private final Spec spec = HutnFactory.eINSTANCE.createSpec(); private final Stack<ClassObject> stack = new Stack<ClassObject>(); private ContainmentSlot containingSlot; public SpecGenerator() { EmfUtil.createResource(spec); } public Spec getSpec() { return spec; } public void initialise() { initialise(null); } public void initialise(String nsUri) { addPackageObject(nsUri); } public void generateTopLevelClassObject(String identifier, String type) { if (getPackageObject() == null) throw new IllegalStateException("Cannot create a top-level class object until initialise has been called"); if (isGenerating()) throw new IllegalStateException("Cannot create a top-level class object when generating another class object"); getPackageObject().getClassObjects().add(createClassObject(identifier, type)); } /** * Generates a new ClassObject whose type is determined by * inspecting the class of the parent ClassObject. If no * feature with the name specified can be found in the * class of the parent ClassObject, the newly generated * ClassObject will have type "UnknownType". * * @param containingFeature - the name of the feature in the * parent ClassObject that will contain the newly generated * * @param identifier - the identifier for the ClassObject to * be created. Identifiers are used when adding values to * reference slots. null is allowed, but this will create a * ClassObject that cannot be referenced. * * ClassObject. */ public void generateContainedClassObject(String containingFeature, String identifier) { EStructuralFeature feature = HutnUtil.determineFeatureFromMetaClass(getCurrentClassObject(), containingFeature); if (EmfUtil.isContainmentReference(feature)) { generateContainedClassObject(containingFeature, identifier, feature.getEType().getName()); } else { generateContainedClassObject(containingFeature, identifier, "UnknownType"); } } /** * <p>Generates a new ClassObject with the type specified. The * newly generated ClassObject will be placed in a * ContainmentSlot, with the feature specified, of the * parent ClassObject.</p> * * <p>If the parent ClassObject contains an existing ContainmentSlot * with the feature specified, the newly generated ClassObject * will be added to the values of that slot. Otherwise, a new * ContainmentSlot with the feature specified will be created.</p> * * @param type - the type of ClassObject to be generated. * * @param containingFeature - the name of the feature in the * parent ClassObject that will contain the newly generated * ClassObject. * * @param identifier - the identifier for the ClassObject to * be created. Identifiers are used when adding values to * reference slots. null is allowed, but this will create a * ClassObject that cannot be referenced. */ public void generateContainedClassObject(String containingFeature, String identifier, String type) { if (!isGenerating()) throw new IllegalStateException("Cannot generate a contained class object when not generating any other class objects"); containingSlot = stack.peek().findOrCreateContainmentSlot(containingFeature); containingSlot.getClassObjects().add(createClassObject(identifier, type)); } public ClassObject getCurrentClassObject() { return stack.peek(); } public void stopGeneratingCurrentClassObject() { stack.pop(); } public void stopGeneratingAndDeleteCurrentClassObject() { stopGeneratingCurrentClassObject(); if (containingSlot != null) { stack.peek().getSlots().remove(containingSlot); } } public void addAttributeValue(String featureName, String value) { final Slot<?> slot = determineSlot(featureName); getCurrentClassObject().getSlots().add(slot); HutnUtil.addValueToSlot(slot, value); } private Slot<?> determineSlot(String featureName) { Slot<?> slot = HutnUtil.determineSlotFromMetaFeature(getCurrentClassObject(), featureName); if (slot == null) { slot = getCurrentClassObject().findOrCreateAttributeSlot(featureName); } return slot; } private boolean isGenerating() { return getCurrentClassObject() != null; } private PackageObject getPackageObject() { if (spec.getObjects().isEmpty()) return null; return spec.getObjects().get(0); } private void addPackageObject(String nsUri) { final PackageObject po = HutnFactory.eINSTANCE.createPackageObject(); spec.getObjects().add(po); if (nsUri != null) { addNsUri(nsUri); if (EPackage.Registry.INSTANCE.getEPackage(nsUri) != null) po.getMetamodel().add(EPackage.Registry.INSTANCE.getEPackage(nsUri)); } } private void addNsUri(String nsUri) { final NsUri nsUriObject = HutnFactory.eINSTANCE.createNsUri(); nsUriObject.setValue(nsUri); spec.getNsUris().add(nsUriObject); } private ClassObject createClassObject(String identifier, String type) { final ClassObject co = HutnFactory.eINSTANCE.createClassObject(); co.setType(type); if (identifier != null) { co.setIdentifier(identifier); } stack.push(co); return co; } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
c9252f84f3a098983071788c77b9f9a04ea2e47e
0429ec7192a11756b3f6b74cb49dc1ba7c548f60
/src/main/java/com/linkage/module/itms/resource/util/DeviceTypeUtil.java
1c1fca10d2f7fc0b219df346a484f20aac971b7e
[]
no_license
lichao20000/WEB
5c7730779280822619782825aae58506e8ba5237
5d2964387d66b9a00a54b90c09332e2792af6dae
refs/heads/master
2023-06-26T16:43:02.294375
2021-07-29T08:04:46
2021-07-29T08:04:46
null
0
0
null
null
null
null
UTF-8
Java
false
false
3,511
java
package com.linkage.module.itms.resource.util; import java.util.ArrayList; import java.util.HashMap; import java.util.List; import java.util.Map; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import com.linkage.commons.db.DBOperation; import com.linkage.commons.db.PrepareSQL; import com.linkage.commons.util.StringUtil; public class DeviceTypeUtil { private static Logger logger = LoggerFactory.getLogger(DeviceTypeUtil.class); public static Map<String,String> vendorMap = new HashMap<String,String>(); public static Map<String,String> deviceModelMap = new HashMap<String,String>(); public static Map<String,String> checkMap = new HashMap<String,String>(); public static Map<String,String> devTypeMap = new HashMap<String,String>(); public static Map<String,String> accessMap = new HashMap<String,String>(); public static Map<String,String> specMap = new HashMap<String,String>(); public static Map<String, String> softVersionMap = new HashMap<String, String>(); static { init(); } public static void init() { logger.warn("init deviceMap"); checkMap.put("审核", "1"); checkMap.put("未审核","-1"); checkMap.put("1", "审核"); checkMap.put("-1", "未审核"); List<HashMap<String,String>> vendorlist = getVendorMap(); for (HashMap<String,String> map:vendorlist) { vendorMap.put(map.get("vendor_name"), map.get("vendor_id")); vendorMap.put(map.get("vendor_id"), map.get("vendor_name")); } List<HashMap<String,String>> deviceModelList = getDeviceModel(); for (HashMap<String,String> map:deviceModelList) { deviceModelMap.put(map.get("device_model"), map.get("device_model_id")); deviceModelMap.put(map.get("device_model_id"), map.get("device_model")); } devTypeMap.put("e8-b","1"); devTypeMap.put("e8-c","2"); devTypeMap.put("1","e8-b"); devTypeMap.put("2","e8-c"); accessMap.put("ADSL","1"); accessMap.put("LAN","2"); accessMap.put("EPON光纤","3"); accessMap.put("GPON光纤","4"); accessMap.put("1","ADSL"); accessMap.put("2","LAN"); accessMap.put("3","EPON光纤"); accessMap.put("4","GPON光纤"); List<HashMap<String,String>> specList = new ArrayList<HashMap<String,String>>(); specList = querySpecList(); for (Map<String,String> map:specList) { specMap.put(map.get("spec_name"),map.get("id")); specMap.put(map.get("id"),map.get("spec_name")); } List<HashMap<String, String>> softVerList = querySoftVerList(); for (HashMap<String, String> map : softVerList) { softVersionMap.put(StringUtil.getStringValue(map, "devicetype_id"), map.get("softwareversion")); } } private static List<HashMap<String,String>> getVendorMap() { PrepareSQL pSQL = new PrepareSQL("select vendor_id,vendor_name, vendor_add from tab_vendor"); return DBOperation.getRecords(pSQL.getSQL()); } private static List<HashMap<String,String>> getDeviceModel() { PrepareSQL pSQL = new PrepareSQL("select a.device_model_id,a.device_model from gw_device_model a"); return DBOperation.getRecords(pSQL.getSQL()); } private static List<HashMap<String,String>> querySpecList() { PrepareSQL pSQL = new PrepareSQL("select id,spec_name from tab_bss_dev_port"); return DBOperation.getRecords(pSQL.getSQL()); } private static List<HashMap<String, String>> querySoftVerList() { PrepareSQL pSQL = new PrepareSQL( "select devicetype_id,softwareversion from tab_devicetype_info");// 融合stb_tab_devicetype_info return DBOperation.getRecords(pSQL.getSQL()); } }
[ "di4zhibiao.126.com" ]
di4zhibiao.126.com
b89cdc6e9a087b08f37001f799c1b8c309b68101
29e184b262bb73e7301fca6b8069c873e910111c
/src/main/java/com/example/jaxb/fpml/recordkeeping/DualCurrencyFeature.java
dc3aa8f3927042139279b0cf10afacd1b5591f92
[]
no_license
oliversalmon/fpml
6c0578d8b2460e3976033fa9aea4254341aba65b
cecf5321e750bbb88c14e9bd75ee341acdccc444
refs/heads/master
2020-04-03T17:41:00.682605
2018-10-30T20:58:56
2018-10-30T20:58:56
155,455,414
0
0
null
null
null
null
UTF-8
Java
false
false
5,603
java
package com.example.jaxb.fpml.recordkeeping; import java.math.BigDecimal; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.XmlSchemaType; import javax.xml.bind.annotation.XmlType; import javax.xml.datatype.XMLGregorianCalendar; /** * Describes the parameters for a dual currency option transaction. * * <p>Java class for DualCurrencyFeature complex type. * * <p>The following schema fragment specifies the expected content contained within this class. * * <pre> * &lt;complexType name="DualCurrencyFeature"> * &lt;complexContent> * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> * &lt;sequence> * &lt;element name="currency" type="{http://www.fpml.org/FpML-5/recordkeeping}Currency" minOccurs="0"/> * &lt;element name="fixingDate" type="{http://www.w3.org/2001/XMLSchema}date" minOccurs="0"/> * &lt;element name="fixingTime" type="{http://www.fpml.org/FpML-5/recordkeeping}BusinessCenterTime" minOccurs="0"/> * &lt;element name="strike" type="{http://www.fpml.org/FpML-5/recordkeeping}DualCurrencyStrikePrice" minOccurs="0"/> * &lt;element name="spotRate" type="{http://www.w3.org/2001/XMLSchema}decimal" minOccurs="0"/> * &lt;element name="interestAtRisk" type="{http://www.w3.org/2001/XMLSchema}boolean" minOccurs="0"/> * &lt;/sequence> * &lt;/restriction> * &lt;/complexContent> * &lt;/complexType> * </pre> * * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "DualCurrencyFeature", namespace = "http://www.fpml.org/FpML-5/recordkeeping", propOrder = { "currency", "fixingDate", "fixingTime", "strike", "spotRate", "interestAtRisk" }) public class DualCurrencyFeature { @XmlElement(namespace = "http://www.fpml.org/FpML-5/recordkeeping") protected Currency currency; @XmlElement(namespace = "http://www.fpml.org/FpML-5/recordkeeping") @XmlSchemaType(name = "date") protected XMLGregorianCalendar fixingDate; @XmlElement(namespace = "http://www.fpml.org/FpML-5/recordkeeping") protected BusinessCenterTime fixingTime; @XmlElement(namespace = "http://www.fpml.org/FpML-5/recordkeeping") protected DualCurrencyStrikePrice strike; @XmlElement(namespace = "http://www.fpml.org/FpML-5/recordkeeping") protected BigDecimal spotRate; @XmlElement(namespace = "http://www.fpml.org/FpML-5/recordkeeping") protected Boolean interestAtRisk; /** * Gets the value of the currency property. * * @return * possible object is * {@link Currency } * */ public Currency getCurrency() { return currency; } /** * Sets the value of the currency property. * * @param value * allowed object is * {@link Currency } * */ public void setCurrency(Currency value) { this.currency = value; } /** * Gets the value of the fixingDate property. * * @return * possible object is * {@link XMLGregorianCalendar } * */ public XMLGregorianCalendar getFixingDate() { return fixingDate; } /** * Sets the value of the fixingDate property. * * @param value * allowed object is * {@link XMLGregorianCalendar } * */ public void setFixingDate(XMLGregorianCalendar value) { this.fixingDate = value; } /** * Gets the value of the fixingTime property. * * @return * possible object is * {@link BusinessCenterTime } * */ public BusinessCenterTime getFixingTime() { return fixingTime; } /** * Sets the value of the fixingTime property. * * @param value * allowed object is * {@link BusinessCenterTime } * */ public void setFixingTime(BusinessCenterTime value) { this.fixingTime = value; } /** * Gets the value of the strike property. * * @return * possible object is * {@link DualCurrencyStrikePrice } * */ public DualCurrencyStrikePrice getStrike() { return strike; } /** * Sets the value of the strike property. * * @param value * allowed object is * {@link DualCurrencyStrikePrice } * */ public void setStrike(DualCurrencyStrikePrice value) { this.strike = value; } /** * Gets the value of the spotRate property. * * @return * possible object is * {@link BigDecimal } * */ public BigDecimal getSpotRate() { return spotRate; } /** * Sets the value of the spotRate property. * * @param value * allowed object is * {@link BigDecimal } * */ public void setSpotRate(BigDecimal value) { this.spotRate = value; } /** * Gets the value of the interestAtRisk property. * * @return * possible object is * {@link Boolean } * */ public Boolean isInterestAtRisk() { return interestAtRisk; } /** * Sets the value of the interestAtRisk property. * * @param value * allowed object is * {@link Boolean } * */ public void setInterestAtRisk(Boolean value) { this.interestAtRisk = value; } }
[ "oliver.salmon@gmail.com" ]
oliver.salmon@gmail.com
1abf085107cb78e77b67356c07d6c3414fd15974
9fda2a25052f36eeb3d8143ad486c507495db565
/src/main/java/com/example/demo/SpringbootQuartzApplication.java
58ba7adf5e32045abb5c5aee88107df00229baec
[]
no_license
18753377299/springbootQuartz
38bf63b9cc362895f6f45df59288c88e2eb710d2
25c366992e45f5e42b9b8744e6032d54fb95ae74
refs/heads/master
2020-05-03T14:05:23.705540
2019-03-31T09:40:28
2019-03-31T09:40:28
178,668,278
0
0
null
null
null
null
UTF-8
Java
false
false
523
java
package com.example.demo; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.context.annotation.ComponentScan; import org.springframework.scheduling.annotation.EnableScheduling; @SpringBootApplication @EnableScheduling @ComponentScan(basePackages="com.example.demo") public class SpringbootQuartzApplication { public static void main(String[] args) { SpringApplication.run(SpringbootQuartzApplication.class, args); } }
[ "1733856225@qq.com" ]
1733856225@qq.com
82e4142af7e25b580ff6cc4ea8ca1ce4b410cb0d
da8f8a78810748e007cc04ab508a0b6918f8e958
/app/src/main/java/com/game/helper/net/task/DeleteDynamicTask.java
b35ce1fb678e082a046774228f37a687bf977a46
[]
no_license
252319634/boluogamespay
a803c0d3e81e840c0e3c9c44ad18167dd6e9ea62
4c7e4b60703ca3bafd7062fed6e8b3e59732ff28
refs/heads/master
2021-07-11T04:54:15.311564
2017-10-12T18:15:40
2017-10-12T18:19:51
104,739,840
1
0
null
2017-09-25T11:08:46
2017-09-25T11:08:46
null
UTF-8
Java
false
false
1,186
java
package com.game.helper.net.task; import com.game.helper.net.base.BaseBBXTask; import com.game.helper.sdk.model.comm.DeleteDynamicBuild; import com.game.helper.sdk.net.comm.DeleteDynamicNet; import android.content.Context; /** * @Description * @Path com.game.helper.net.task.deleteDynamicTask.java * @Author lbb * @Date 2016年9月16日 下午1:03:27 * @Company */ public class DeleteDynamicTask extends BaseBBXTask{ DeleteDynamicBuild build; public DeleteDynamicTask(Context context,String dynamicId,Back back) { super(context); this.back=back; build=new DeleteDynamicBuild(context, API_deleteDynamic_Url, dynamicId); } @Override public void onSuccess(Object object, String msg) { // TODO Auto-generated method stub if(back!=null){ back.success(object,msg); } } @Override public void onFailed(String status, String msg, Object result) { // TODO Auto-generated method stub super.onFailed(status, msg, result); if(back!=null){ back.fail(status, msg, result); } } @Override protected Object doInBackground(Object... params) { // TODO Auto-generated method stub return new DeleteDynamicNet(context, build.toJson1()); } }
[ "rysq008@gmail.com" ]
rysq008@gmail.com
aec4331ce6e6cc5091c9759d96f0e645ead1e24f
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/16/16_957f11de6c0fb82512be88a9de251fa882337794/ModItems/16_957f11de6c0fb82512be88a9de251fa882337794_ModItems_s.java
68a50a1b1b56944fdc6f05f3874bc86e64f29529
[]
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
2,790
java
package mods.minecraft.darth.dc.item; import mods.minecraft.darth.dc.DiscoveryCraft; import mods.minecraft.darth.dc.lib.ItemIDs; import mods.minecraft.darth.dc.lib.Strings; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraftforge.common.MinecraftForge; public class ModItems { //Item Instances public static Item sciNotebook; public static Item unknownDust; public static Item monocleLens; public static Item notebookLock; public static Item sonicScrewdriver; public static Item debugTool; public static Item craftingUpgrade; public static Item knife; public static Item unknownChunks; public static Item shovelFlint; public static Item pickaxeFlint; public static Item axeFlint; public static Item dirtPellet; public static void init() { //Initialize each Regular Item sciNotebook = new ItemSciNotebook(ItemIDs.SCI_NOTEBOOK); unknownDust = new ItemDC(ItemIDs.UNKNOWN_DUST).setUnlocalizedName(Strings.UNKNOWN_DUST_NAME).setCreativeTab(DiscoveryCraft.tabDC).setMaxStackSize(64); unknownChunks = new ItemDC(ItemIDs.UNKNOWN_CHUNKS).setUnlocalizedName(Strings.UNKNOWN_CHUNKS_NAME).setCreativeTab(DiscoveryCraft.tabDC).setMaxStackSize(64); sonicScrewdriver = new ItemSonicScrewdriver(ItemIDs.SONIC_SCREWDRIVER); debugTool = new ItemDebug(ItemIDs.DEBUG_TOOL); craftingUpgrade = new ItemCraftingUpgrade(ItemIDs.CRAFTING_UPGRADE); knife = new ItemKnife(ItemIDs.KNIFE); shovelFlint = new ItemDC(ItemIDs.FLINT_SHOVEL).setUnlocalizedName(Strings.FLINT_SHOVEL_NAME).setCreativeTab(DiscoveryCraft.tabDC); pickaxeFlint = new ItemDC(ItemIDs.FLINT_PICKAXE).setUnlocalizedName(Strings.FLINT_PICKAXE_NAME).setCreativeTab(DiscoveryCraft.tabDC); axeFlint = new ItemDC(ItemIDs.FLINT_AXE).setUnlocalizedName(Strings.FLINT_AXE_NAME).setCreativeTab(DiscoveryCraft.tabDC); //Initialize each Crafting Ingredient Item notebookLock = new ItemCrafting(ItemIDs.NOTEBOOK_LOCK).setUnlocalizedName(Strings.NOTEBOOK_LOCK_NAME); dirtPellet = new ItemDC(ItemIDs.DIRT_PELLET).setUnlocalizedName(Strings.DIRT_PELLET_NAME); monocleLens = new ItemCrafting(ItemIDs.MONOCLE_LENS).setUnlocalizedName(Strings.MONOCLE_LENS_NAME); registry(); } private static void registry() { MinecraftForge.setToolClass(shovelFlint, "shovel", 0); MinecraftForge.setToolClass(pickaxeFlint, "pickaxe", 0); MinecraftForge.setToolClass(axeFlint, "axe", 0); MinecraftForge.addGrassSeed(new ItemStack(dirtPellet), 4); } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
e1bef2eb52be213b47a8a92ccf4bf20fdfe4b9d7
9ad612fe94d84458cc0ddb7629baf885d975e4db
/scr/main/java/com/andrey/csv/repository/csvutils/ConcreteReadWriteDB.java
e36d1042708eded9215ed1bfac72c86fc8105ba1
[]
no_license
andreyDelay/CRUD_2.0
880004adbed0c2206db7f273b474aaa4946105e0
77095fb9ef2d350e16d06b7a7709f094e699fa0c
refs/heads/main
2023-01-21T12:54:41.849104
2020-11-30T13:08:36
2020-11-30T13:08:36
310,836,659
0
0
null
null
null
null
UTF-8
Java
false
false
6,245
java
package com.andrey.csv.repository.csvutils; import org.apache.commons.csv.CSVFormat; import org.apache.commons.csv.CSVParser; import org.apache.commons.csv.CSVPrinter; import org.apache.commons.csv.CSVRecord; import java.io.BufferedReader; import java.io.BufferedWriter; import java.io.File; import java.io.IOException; import java.nio.file.Files; import java.nio.file.Path; import java.nio.file.StandardOpenOption; import java.util.ArrayList; import java.util.Arrays; import java.util.List; import java.util.Optional; import java.util.stream.Collectors; public class ConcreteReadWriteDB implements ReadWriteDataBase { private char csvDelimiter = ';'; List<String> projectHeaders; //получает значение в единственном методе getProperCSVFormatAndCheckHeaders() private boolean needToRewriteProjectHeaders; public ConcreteReadWriteDB(List<String> projectHeaders) { this.projectHeaders = projectHeaders; } /* Тут была попытка реализовать перезапись заголовков, если они вдруг были удалены или несоответствуют новым не несёт никакой особой функциональности, но данные в файле удаляются в методе createCSVPrinterForNewFile() из-за опции StandardOpenOption.TRUNCATE_EXISTING. */ public boolean writeData(List<String> records, Path path) { try(CSVPrinter printer = getCSVPrinter(path, records)) { if (needToRewriteProjectHeaders) { List<String> rowsFromCsvFile = readData(path); records.addAll(0, rowsFromCsvFile); } for(String oneRecord: records) { printer.printRecord(oneRecord); } printer.flush(); } catch (IOException e) { System.out.println("Ошибка записи в файл!"); e.printStackTrace(); return false; } return true; } private CSVPrinter getCSVPrinter(Path path, List<String> records) throws IOException { File file = new File(path.toString()); if (!file.exists() || records.size() != 1) { return createCSVPrinterForNewFile(path); } CSVFormat csvFormat = getProperCSVFormatAndCheckHeaders(path); if (needToRewriteProjectHeaders) return createCSVPrinterForNewFile(path); return createCSVPrinterForExistingFile(path, csvFormat); } private CSVFormat getProperCSVFormatAndCheckHeaders(Path path) { CSVFormat csvFormat = CSVFormat.DEFAULT .withDelimiter(csvDelimiter) .withQuote(null); if (!isHeadersCorrect(path)) { needToRewriteProjectHeaders = true; } return csvFormat; } private boolean isHeadersCorrect(Path path) { boolean result = true; try (CSVParser parser = getCSVParserWithHeaders(path)) { String headerRow = parser.getHeaderNames().stream() .collect(Collectors.joining(String.valueOf(csvDelimiter))); List<String> headersFromCSVFile = Arrays.stream( headerRow.split(String.valueOf(csvDelimiter))) .collect(Collectors.toList()); if (headersFromCSVFile.size() == 0) { return false; } for (String headerFromFile: headersFromCSVFile) { if (!projectHeaders.contains(headerFromFile)) result = false; } } catch (Exception e) { System.out.println("Будет создан новый файл для записи данных"); result = false; } return result; } private CSVPrinter createCSVPrinterForExistingFile(Path path, CSVFormat csvFormat) throws IOException { BufferedWriter writer = Files.newBufferedWriter(path, StandardOpenOption.APPEND, StandardOpenOption.CREATE); return new CSVPrinter(writer, csvFormat); } private CSVPrinter createCSVPrinterForNewFile(Path path) throws IOException { String headers = String.join(";", projectHeaders); BufferedWriter writer = Files.newBufferedWriter(path,StandardOpenOption.CREATE,StandardOpenOption.TRUNCATE_EXISTING); return new CSVPrinter(writer, CSVFormat.DEFAULT .withHeader(headers) .withDelimiter(csvDelimiter).withQuote(null)); } public List<String> readData(Path path) { List<String> rowsFromCsvFile = new ArrayList<>(); try (CSVParser parser = getCSVParser(path)){ StringBuilder oneRow = new StringBuilder(); for (CSVRecord record : parser.getRecords()) { for (int i = 0; i < projectHeaders.size(); i++) { oneRow.append(record.get(i)).append(csvDelimiter); } rowsFromCsvFile.add(oneRow.toString()); oneRow.setLength(0); } } catch (IOException e) { System.out.println("Будет создана новая БД для " + path.getName(0)); } return rowsFromCsvFile; } private CSVParser getCSVParserWithHeaders(Path path) throws IOException { BufferedReader reader = Files.newBufferedReader(path); return new CSVParser(reader, CSVFormat.DEFAULT.withDelimiter(csvDelimiter).withFirstRecordAsHeader()); } private CSVParser getCSVParser(Path path) throws IOException { BufferedReader reader = Files.newBufferedReader(path); return new CSVParser(reader, CSVFormat.DEFAULT.withDelimiter(csvDelimiter)); } public long incrementIDForNewObject(Path sourceFile) { List<String> rows = readData(sourceFile); Optional<Long> incrementedID = rows.stream() .map(row -> row.split(String.valueOf(csvDelimiter))) .skip(1)//skip header .map(array -> array[0]) .map(Long::parseLong) .max(Long::compareTo); return incrementedID.map(id -> id + 1L).orElse(1L); } }
[ "frowzygleb@gmail.com" ]
frowzygleb@gmail.com
61c4ef79389e15d51c35fd1058d1a8b52b2e3b60
2da705ba188bb9e4a0888826818f1b25d04e90c8
/core/cas-server-core-webflow/src/test/java/org/apereo/cas/web/flow/BaseWebflowConfigurerTests.java
2c967be04799f93bbfd3c84e6f60bf302f9424ab
[ "LicenseRef-scancode-free-unknown", "Apache-2.0", "LicenseRef-scancode-warranty-disclaimer" ]
permissive
williamadmin/cas
9441fd730de81a5abaf173e2e831a19c9e417579
a4c49ab5137745146afa0f6d41791c2881a344a6
refs/heads/master
2021-05-25T19:05:01.862668
2020-04-07T05:15:53
2020-04-07T05:15:53
253,788,442
1
0
Apache-2.0
2020-04-07T12:37:38
2020-04-07T12:37:37
null
UTF-8
Java
false
false
4,269
java
package org.apereo.cas.web.flow; import org.apereo.cas.config.CasCoreAuthenticationConfiguration; import org.apereo.cas.config.CasCoreAuthenticationHandlersConfiguration; import org.apereo.cas.config.CasCoreAuthenticationMetadataConfiguration; import org.apereo.cas.config.CasCoreAuthenticationPolicyConfiguration; import org.apereo.cas.config.CasCoreAuthenticationPrincipalConfiguration; import org.apereo.cas.config.CasCoreAuthenticationSupportConfiguration; import org.apereo.cas.config.CasCoreConfiguration; import org.apereo.cas.config.CasCoreHttpConfiguration; import org.apereo.cas.config.CasCoreServicesAuthenticationConfiguration; import org.apereo.cas.config.CasCoreServicesConfiguration; import org.apereo.cas.config.CasCoreTicketCatalogConfiguration; import org.apereo.cas.config.CasCoreTicketIdGeneratorsConfiguration; import org.apereo.cas.config.CasCoreTicketsConfiguration; import org.apereo.cas.config.CasCoreTicketsSerializationConfiguration; import org.apereo.cas.config.CasCoreUtilConfiguration; import org.apereo.cas.config.CasCoreWebConfiguration; import org.apereo.cas.config.CasDefaultServiceTicketIdGeneratorsConfiguration; import org.apereo.cas.config.CasPersonDirectoryTestConfiguration; import org.apereo.cas.config.support.CasWebApplicationServiceFactoryConfiguration; import org.apereo.cas.logout.config.CasCoreLogoutConfiguration; import org.apereo.cas.web.config.CasCookieConfiguration; import org.apereo.cas.web.flow.config.CasCoreWebflowConfiguration; import org.apereo.cas.web.flow.config.CasWebflowContextConfiguration; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Qualifier; import org.springframework.boot.autoconfigure.mail.MailSenderAutoConfiguration; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.cloud.autoconfigure.RefreshAutoConfiguration; import org.springframework.context.annotation.Import; import org.springframework.test.context.TestPropertySource; import org.springframework.webflow.definition.registry.FlowDefinitionRegistry; /** * This is {@link BaseWebflowConfigurerTests}. * * @author Misagh Moayyed * @since 6.1.0 */ @SpringBootTest(classes = BaseWebflowConfigurerTests.SharedTestConfiguration.class) @TestPropertySource(properties = { "cas.webflow.crypto.encryption.key=qLhvLuaobvfzMmbo9U_bYA", "cas.webflow.crypto.signing.key=oZeAR5pEXsolruu4OQYsQKxf-FCvFzSsKlsVaKmfIl6pNzoPm6zPW94NRS1af7vT-0bb3DpPBeksvBXjloEsiA", "spring.mail.host=localhost", "spring.mail.port=25000" }) public class BaseWebflowConfigurerTests { @Autowired @Qualifier("casWebflowExecutionPlan") protected CasWebflowExecutionPlan casWebflowExecutionPlan; @Autowired @Qualifier("loginFlowRegistry") protected FlowDefinitionRegistry loginFlowDefinitionRegistry; @Autowired @Qualifier("logoutFlowRegistry") protected FlowDefinitionRegistry logoutFlowDefinitionRegistry; @Import({ RefreshAutoConfiguration.class, CasCoreAuthenticationConfiguration.class, CasCoreAuthenticationHandlersConfiguration.class, CasCoreAuthenticationMetadataConfiguration.class, CasCoreAuthenticationPolicyConfiguration.class, CasCoreAuthenticationPrincipalConfiguration.class, CasCoreAuthenticationSupportConfiguration.class, CasDefaultServiceTicketIdGeneratorsConfiguration.class, CasCoreTicketsConfiguration.class, CasCoreTicketCatalogConfiguration.class, CasCoreTicketIdGeneratorsConfiguration.class, CasCoreTicketsSerializationConfiguration.class, CasCoreLogoutConfiguration.class, CasWebflowContextConfiguration.class, CasCoreWebflowConfiguration.class, CasCoreServicesConfiguration.class, CasCoreServicesAuthenticationConfiguration.class, CasCoreWebConfiguration.class, CasCoreHttpConfiguration.class, CasCookieConfiguration.class, CasPersonDirectoryTestConfiguration.class, CasCoreConfiguration.class, MailSenderAutoConfiguration.class, CasWebApplicationServiceFactoryConfiguration.class, CasCoreUtilConfiguration.class }) public static class SharedTestConfiguration { } }
[ "mm1844@gmail.com" ]
mm1844@gmail.com
cc5a9590199c9ea535a167e0998a3c37754cbb05
7344866370bd60505061fcc7e8c487339a508bb9
/OpenConcerto/src/org/openconcerto/erp/core/sales/invoice/ui/EcheanceRenderer.java
381bc6d63be5a4aa1a653921eb27a7431bee1974
[]
no_license
sanogotech/openconcerto_ERP_JAVA
ed3276858f945528e96a5ccfdf01a55b58f92c8d
4d224695be0a7a4527851a06d8b8feddfbdd3d0e
refs/heads/master
2023-04-11T09:51:29.952287
2021-04-21T14:39:18
2021-04-21T14:39:18
360,197,474
0
0
null
null
null
null
UTF-8
Java
false
false
2,961
java
/* * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. * * Copyright 2011 OpenConcerto, by ILM Informatique. All rights reserved. * * The contents of this file are subject to the terms of the GNU General Public License Version 3 * only ("GPL"). You may not use this file except in compliance with the License. You can obtain a * copy of the License at http://www.gnu.org/licenses/gpl-3.0.html See the License for the specific * language governing permissions and limitations under the License. * * When distributing the software, include this License Header Notice in each file. */ package org.openconcerto.erp.core.sales.invoice.ui; import org.openconcerto.erp.core.common.ui.DeviseNiceTableCellRenderer; import org.openconcerto.sql.model.SQLRowAccessor; import org.openconcerto.sql.model.SQLRowValues; import org.openconcerto.sql.view.list.ITableModel; import java.awt.Component; import javax.swing.JLabel; import javax.swing.JTable; public class EcheanceRenderer extends DeviseNiceTableCellRenderer { private static EcheanceRenderer instance = null; public synchronized static EcheanceRenderer getInstance() { if (instance == null) { instance = new EcheanceRenderer(); } return instance; } private EcheanceRenderer() { super(); } public Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected, boolean hasFocus, int row, int column) { Component comp = super.getTableCellRendererComponent(table, value, isSelected, hasFocus, row, column); final SQLRowValues rowAt = ITableModel.getLine(table.getModel(), row).getRow(); if (comp instanceof JLabel) { JLabel label = (JLabel) comp; final SQLRowAccessor foreignRow = rowAt.getForeign("ID_MODE_REGLEMENT"); if (foreignRow != null) { int ajours = foreignRow.getInt("AJOURS"); int njour = foreignRow.getInt("LENJOUR"); if (ajours == 0 && njour == 0) { if (foreignRow.getBoolean("COMPTANT") != null && !foreignRow.getBoolean("COMPTANT")) { label.setText("Date de facture"); } else { label.setText("Comptant"); } } else { String s = ""; if (ajours != 0) { s = ajours + ((ajours > 1) ? " jours" : " jour"); } if (njour > 0 && njour < 31) { s += " le " + njour; } else { if (njour == 0) { s += " date de facture"; } else { s += " fin de mois"; } } label.setText(s); } } } return comp; } }
[ "davask.42@gmail.com" ]
davask.42@gmail.com
917c7da874017ac71fb8dc03ae523434ad6bc4fe
7707b1d1d63198e86a0b8a7ae27c00e2f27a8831
/model/com.netxforge.netxstudio.models.13042011/src-gen/com/netxforge/netxstudio/services/impl/ServiceImpl.java
5627a4415c426691f55422993737402fdcce185c
[]
no_license
dzonekl/netxstudio
20535f66e5bbecd1cdd9c55a4d691fc48a1a83aa
f12c118b1ef08fe770e5ac29828653a93fea9352
refs/heads/master
2016-08-04T17:28:38.486076
2015-10-02T16:20:00
2015-10-02T16:20:00
6,561,565
2
0
null
2014-10-27T06:49:59
2012-11-06T12:18:44
Java
UTF-8
Java
false
false
7,541
java
/** * Copyright (c) 2011 NetXForge * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation, either version 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 Lesser General Public License * along with this program. If not, see <http://www.gnu.org/licenses/> * * Contributors: * Christophe Bouhier - initial API and implementation and/or initial documentation */ package com.netxforge.netxstudio.services.impl; import com.netxforge.netxstudio.generics.Lifecycle; import com.netxforge.netxstudio.generics.impl.BaseImpl; import com.netxforge.netxstudio.services.CIID; import com.netxforge.netxstudio.services.Service; import com.netxforge.netxstudio.services.ServiceClassType; import com.netxforge.netxstudio.services.ServiceDistribution; import com.netxforge.netxstudio.services.ServiceForecast; import com.netxforge.netxstudio.services.ServiceMonitor; import com.netxforge.netxstudio.services.ServiceUser; import com.netxforge.netxstudio.services.ServicesPackage; import org.eclipse.emf.common.util.EList; import org.eclipse.emf.ecore.EClass; /** * <!-- begin-user-doc --> * An implementation of the model object '<em><b>Service</b></em>'. * <!-- end-user-doc --> * <p> * The following features are implemented: * <ul> * <li>{@link com.netxforge.netxstudio.services.impl.ServiceImpl#getCIID <em>CIID</em>}</li> * <li>{@link com.netxforge.netxstudio.services.impl.ServiceImpl#getLifecycle <em>Lifecycle</em>}</li> * <li>{@link com.netxforge.netxstudio.services.impl.ServiceImpl#getServices <em>Services</em>}</li> * <li>{@link com.netxforge.netxstudio.services.impl.ServiceImpl#getServiceForecasts <em>Service Forecasts</em>}</li> * <li>{@link com.netxforge.netxstudio.services.impl.ServiceImpl#getServiceMonitors <em>Service Monitors</em>}</li> * <li>{@link com.netxforge.netxstudio.services.impl.ServiceImpl#getServiceUserRefs <em>Service User Refs</em>}</li> * <li>{@link com.netxforge.netxstudio.services.impl.ServiceImpl#getServiceDistribution <em>Service Distribution</em>}</li> * <li>{@link com.netxforge.netxstudio.services.impl.ServiceImpl#getServiceCategory <em>Service Category</em>}</li> * <li>{@link com.netxforge.netxstudio.services.impl.ServiceImpl#getServiceClass <em>Service Class</em>}</li> * <li>{@link com.netxforge.netxstudio.services.impl.ServiceImpl#getServiceDescription <em>Service Description</em>}</li> * <li>{@link com.netxforge.netxstudio.services.impl.ServiceImpl#getServiceName <em>Service Name</em>}</li> * </ul> * </p> * * @generated */ public class ServiceImpl extends BaseImpl implements Service { /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ protected ServiceImpl() { super(); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override protected EClass eStaticClass() { return ServicesPackage.Literals.SERVICE; } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @SuppressWarnings("unchecked") public EList<CIID> getCIID() { return (EList<CIID>)eGet(ServicesPackage.Literals.SERVICE__CIID, true); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public Lifecycle getLifecycle() { return (Lifecycle)eGet(ServicesPackage.Literals.SERVICE__LIFECYCLE, true); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public void setLifecycle(Lifecycle newLifecycle) { eSet(ServicesPackage.Literals.SERVICE__LIFECYCLE, newLifecycle); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @SuppressWarnings("unchecked") public EList<Service> getServices() { return (EList<Service>)eGet(ServicesPackage.Literals.SERVICE__SERVICES, true); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @SuppressWarnings("unchecked") public EList<ServiceForecast> getServiceForecasts() { return (EList<ServiceForecast>)eGet(ServicesPackage.Literals.SERVICE__SERVICE_FORECASTS, true); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @SuppressWarnings("unchecked") public EList<ServiceMonitor> getServiceMonitors() { return (EList<ServiceMonitor>)eGet(ServicesPackage.Literals.SERVICE__SERVICE_MONITORS, true); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @SuppressWarnings("unchecked") public EList<ServiceUser> getServiceUserRefs() { return (EList<ServiceUser>)eGet(ServicesPackage.Literals.SERVICE__SERVICE_USER_REFS, true); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public ServiceDistribution getServiceDistribution() { return (ServiceDistribution)eGet(ServicesPackage.Literals.SERVICE__SERVICE_DISTRIBUTION, true); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public void setServiceDistribution(ServiceDistribution newServiceDistribution) { eSet(ServicesPackage.Literals.SERVICE__SERVICE_DISTRIBUTION, newServiceDistribution); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public String getServiceCategory() { return (String)eGet(ServicesPackage.Literals.SERVICE__SERVICE_CATEGORY, true); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public void setServiceCategory(String newServiceCategory) { eSet(ServicesPackage.Literals.SERVICE__SERVICE_CATEGORY, newServiceCategory); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public ServiceClassType getServiceClass() { return (ServiceClassType)eGet(ServicesPackage.Literals.SERVICE__SERVICE_CLASS, true); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public void setServiceClass(ServiceClassType newServiceClass) { eSet(ServicesPackage.Literals.SERVICE__SERVICE_CLASS, newServiceClass); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public void unsetServiceClass() { eUnset(ServicesPackage.Literals.SERVICE__SERVICE_CLASS); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public boolean isSetServiceClass() { return eIsSet(ServicesPackage.Literals.SERVICE__SERVICE_CLASS); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public String getServiceDescription() { return (String)eGet(ServicesPackage.Literals.SERVICE__SERVICE_DESCRIPTION, true); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public void setServiceDescription(String newServiceDescription) { eSet(ServicesPackage.Literals.SERVICE__SERVICE_DESCRIPTION, newServiceDescription); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public String getServiceName() { return (String)eGet(ServicesPackage.Literals.SERVICE__SERVICE_NAME, true); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public void setServiceName(String newServiceName) { eSet(ServicesPackage.Literals.SERVICE__SERVICE_NAME, newServiceName); } } //ServiceImpl
[ "dzonekl@gmail.com" ]
dzonekl@gmail.com
fd5616a8f05c2ac43bf4510c35ea2cae71d8b277
1ee24224273997c55967b2875a9fa5f10725d075
/aula06/exemplo01/Gerente.java
77f8a994dc24e8a5873aa451689c5a2a23c9c71f
[]
no_license
EderSerra/ItauGamaTurma7
57b284bd7da4d45af987612f900613940df6f907
cce0ff4aa42afde802996f99f03c76f9822f1dad
refs/heads/master
2022-12-05T17:49:26.572284
2020-09-03T20:51:00
2020-09-03T20:51:00
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,269
java
package exemplo01; public class Gerente extends Funcionario { private int numFuncionarios; private double bonus; public Gerente(String nome, double salario, int numFuncionarios){ super(nome, salario); //chama o construtor da classe base this.numFuncionarios = numFuncionarios; } public int getNumFuncionarios(){ return numFuncionarios; } public void setNumFuncionarios(int numFuncionarios){ if(numFuncionarios > 0){ this.numFuncionarios = numFuncionarios; } } @Override public String imprimir(){ //forma 1: //acesso diretamente um dado protected, e um método public, e uma variável local //return "Funcionario: " + nome + " salario: " + getSalario() + " numFunc: " + numFuncionarios; //forma2: //utilizar o método da classe base e adionar o que for diferente return super.imprimir() + " numFunc: " + numFuncionarios + " bônus: " + bonus; } @Override public void aumentarSalario(double perc) { //solução 1 //super.aumentarSalario(perc + 0.2); //solução 2 //bonus para o mês do aumento bonus = getSalario() * 0.2; super.aumentarSalario(perc); } }
[ "emerson.paduan@gmail.com" ]
emerson.paduan@gmail.com
875814fc02acf2be144c0f1022fc1cd5286b1cfc
18aa0c66b7521db1dd1b4700db64aa6fc21e5705
/src/main/java/com/qding/bigdata/ds/component/GraphArborFormatHandler.java
2917054acf3081f241b083dbd2e8280d5e3211ec
[]
no_license
cainiao22/ds
716834a86a66e7c592788032ec2e9d0b52c41008
fd80e539cc6ae0d54a793fd7b387b717cc23a59c
refs/heads/master
2022-12-21T09:33:42.022611
2019-09-19T03:24:51
2019-09-19T03:24:51
214,326,271
0
0
null
2022-12-16T09:45:15
2019-10-11T02:30:08
JavaScript
UTF-8
Java
false
false
1,610
java
package com.qding.bigdata.ds.component; import com.qding.bigdata.ds.model.scheduler.SchedulerJob; import com.qding.bigdata.ds.scheduler.model.Graph; import com.qding.bigdata.ds.scheduler.model.GraphNode; import org.springframework.util.CollectionUtils; import java.util.LinkedList; import java.util.List; import java.util.Queue; /** * @author yanpf * @date 2018/3/14 14:34 * @description */ public class GraphArborFormatHandler { public static Object format(Graph<SchedulerJob> graph){ StringBuffer sb = new StringBuffer(); if(graph == null || CollectionUtils.isEmpty(graph.getHeaders())){ return sb.toString(); } List<GraphNode<SchedulerJob>> headers = graph.getHeaders(); Queue<GraphNode<SchedulerJob>> queue = new LinkedList<GraphNode<SchedulerJob>>(); queue.addAll(headers); GraphNode<SchedulerJob> top = null; while(!queue.isEmpty()){ top = queue.poll(); sb.append(top.getData().getJobId()) .append(" {").append("color:green, shape:dot, link:www.baidu.com, label:") .append(top.getData().getJobName()) .append("}\n"); if(top.getChildren() != null){ /*for (GraphNode<SchedulerJob> node : top.getChildren()) { sb.append(top.getData().getJobId()) .append(" -> ").append(node.getData().getJobId()) .append("\n"); queue.add(node); }*/ } } return sb.toString(); } }
[ "yanpengfei@qding.me" ]
yanpengfei@qding.me
c1aa686e062c882d09fcd3baf07354a1debe506d
feced5d2778e62a4c435a03e3720de56bce46d4f
/2.JavaCore/src/com/codegym/task/task15/task1505/Solution.java
cc1b01661c7662b4686169f6db9be1b429057b10
[]
no_license
GreegAV/CodeGymTasks
2045911fa3e0f865174ef8c1649c22f4c38c9226
6ab6c5ef658543b40a3188bee4cec27018af3a24
refs/heads/master
2020-04-15T17:40:43.756806
2019-02-28T15:31:56
2019-02-28T15:31:56
164,881,892
0
0
null
null
null
null
UTF-8
Java
false
false
3,078
java
package com.codegym.task.task15.task1505; import java.util.ArrayList; import java.util.List; /* OOP: Fix inheritance problems Correct the containsBones method and all associated logic so that: 1. The program's behavior remains the same. 2. The containsBones method must return an Object and the value "Yes" instead of true, and "No" instead of false Requirements: 1. The BodyPart class's containsBones method must return an Object. 2. The Finger class must be a descendant of the BodyPart class. 3. The Finger class's containsBones method must return an Object. 4. The BodyPart class's containsBones method should return "Yes". 5. The Finger class's containsBones method should return "Yes" if the BodyPart class's containsBones method returns "Yes" and the isArtificial flag is false. If this condition is not satisfied, then return "No". 6. The BodyPart class's toString method should return a string formatted as follows "<name> (name of the body part) contains bones" if the containsBones method returns "Yes" for the body part. If it returns "No", then the string should be formatted as "<name> (name of the body part) does not contain bones". */ public class Solution { public static interface LivingPart { Object containsBones(); } public static class BodyPart implements LivingPart { private String name; public BodyPart(String name) { this.name = name; } public Object containsBones() { return "Yes"; } public String toString() { return containsBones().equals("Yes") ? name + " contains bones" : name + " does not contain bones"; } } public static class Finger extends BodyPart { private boolean isArtificial; public Finger(String name, boolean isArtificial) { super(name); this.isArtificial = isArtificial; } public Object containsBones() { return (super.containsBones().equals("Yes") && !isArtificial) ? "Yes" : "No"; } } public static void main(String[] args) { printlnFingers(); printlnBodyParts(); printlnLivingParts(); } private static void printlnLivingParts() { System.out.println(new BodyPart("Hand").containsBones()); } private static void printlnBodyParts() { List<BodyPart> bodyParts = new ArrayList<BodyPart>(5); bodyParts.add(new BodyPart("Hand")); bodyParts.add(new BodyPart("Leg")); bodyParts.add(new BodyPart("Head")); bodyParts.add(new BodyPart("Body")); System.out.println(bodyParts.toString()); } private static void printlnFingers() { List<Finger> fingers = new ArrayList<Finger>(5); fingers.add(new Finger("Thumb", true)); fingers.add(new Finger("Forefinger", true)); fingers.add(new Finger("Middle finger", true)); fingers.add(new Finger("Ring-finger", false)); fingers.add(new Finger("Pinky", true)); System.out.println(fingers.toString()); } }
[ "greegav@gmail.com" ]
greegav@gmail.com
42408f20044a16db3a0c3facb16555ee378cd760
363c936f4a89b7d3f5f4fb588e8ca20c527f6022
/AL-Game/data/scripts/system/handlers/quest/ascension/_1915DispatchtoVerteron.java
876de768069d34b1a4c908cf644f394b52ce9c4d
[]
no_license
G-Robson26/AionServer-4.9F
d628ccb4307aa0589a70b293b311422019088858
3376c78b8d90bd4d859a7cfc25c5edc775e51cbf
refs/heads/master
2023-09-04T00:46:47.954822
2017-08-09T13:23:03
2017-08-09T13:23:03
null
0
0
null
null
null
null
UTF-8
Java
false
false
4,025
java
/** * This file is part of Aion-Lightning <aion-lightning.org>. * * Aion-Lightning 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. * * Aion-Lightning 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 Aion-Lightning. * If not, see <http://www.gnu.org/licenses/>. */ package quest.ascension; import com.aionemu.gameserver.model.gameobjects.Npc; import com.aionemu.gameserver.model.gameobjects.player.Player; import com.aionemu.gameserver.network.aion.serverpackets.SM_DIALOG_WINDOW; import com.aionemu.gameserver.questEngine.handlers.QuestHandler; import com.aionemu.gameserver.questEngine.model.QuestEnv; import com.aionemu.gameserver.questEngine.model.QuestState; import com.aionemu.gameserver.questEngine.model.QuestStatus; import com.aionemu.gameserver.services.teleport.TeleportService2; import com.aionemu.gameserver.utils.PacketSendUtility; /** * @author Mr. Poke */ public class _1915DispatchtoVerteron extends QuestHandler { private final static int questId = 1915; public _1915DispatchtoVerteron() { super(questId); } @Override public void register() { qe.registerOnLevelUp(questId); qe.registerQuestNpc(203726).addOnTalkEvent(questId); qe.registerQuestNpc(203097).addOnTalkEvent(questId); } @Override public boolean onDialogEvent(QuestEnv env) { final Player player = env.getPlayer(); final QuestState qs = player.getQuestStateList().getQuestState(questId); if (qs == null) { return false; } int var = qs.getQuestVarById(0); int targetId = 0; if (env.getVisibleObject() instanceof Npc) { targetId = ((Npc) env.getVisibleObject()).getNpcId(); } if (qs.getStatus() == QuestStatus.START) { switch (targetId) { case 203726: { switch (env.getDialog()) { case QUEST_SELECT: if (var == 0) { return sendQuestDialog(env, 1352); } break; case SETPRO1: if (var == 0) { qs.setQuestVarById(0, var + 1); updateQuestStatus(env); TeleportService2.teleportTo(player, 210030000, player.getInstanceId(), 1643f, 1500f, 120f); PacketSendUtility.sendPacket(player, new SM_DIALOG_WINDOW(env.getVisibleObject().getObjectId(), 0)); return true; } default: break; } } case 203097: switch (env.getDialog()) { case QUEST_SELECT: if (var == 1) { qs.setStatus(QuestStatus.REWARD); updateQuestStatus(env); return sendQuestDialog(env, 2375); } default: break; } } } else if (qs.getStatus() == QuestStatus.REWARD) { if (targetId == 203097) { return sendQuestEndDialog(env); } } return false; } @Override public boolean onLvlUpEvent(QuestEnv env) { return defaultOnLvlUpEvent(env); } }
[ "falke34@a70f7278-c47d-401d-a0e4-c9401b7f63ed" ]
falke34@a70f7278-c47d-401d-a0e4-c9401b7f63ed
702dbf89c894e3f328e942012517e710af8e609b
9863d7bd8a4e4593bcf79836957284647675b140
/doc/LesserAudioSwitch_v.2.7.2(124)_source_from_JADX/sources/p000/C0853n0.java
885631ffec73449e2bab4ae9a17950c983c48013
[]
no_license
solvek/AudioSpeakerTest
e71d9268ca097695dc3b51c4537f7ffb54b6c70f
49780b874cb24e7d1f6226ce36653cfab6bda842
refs/heads/master
2023-09-02T20:22:35.458097
2021-11-23T09:40:52
2021-11-23T09:40:52
424,282,640
0
0
null
null
null
null
UTF-8
Java
false
false
3,382
java
package p000; import android.content.Context; import android.content.ContextWrapper; import android.content.res.AssetManager; import android.content.res.Configuration; import android.content.res.Resources; import android.os.Build; import android.view.LayoutInflater; /* renamed from: n0 */ public class C0853n0 extends ContextWrapper { /* renamed from: a */ public int f3329a; /* renamed from: b */ public Resources.Theme f3330b; /* renamed from: c */ public LayoutInflater f3331c; /* renamed from: d */ public Configuration f3332d; /* renamed from: e */ public Resources f3333e; public C0853n0() { super((Context) null); } public C0853n0(Context context, int i) { super(context); this.f3329a = i; } /* renamed from: a */ public void mo3722a(Configuration configuration) { if (this.f3333e != null) { throw new IllegalStateException("getResources() or getAssets() has already been called"); } else if (this.f3332d == null) { this.f3332d = new Configuration(configuration); } else { throw new IllegalStateException("Override configuration has already been set"); } } public void attachBaseContext(Context context) { super.attachBaseContext(context); } /* renamed from: b */ public final void mo3724b() { if (this.f3330b == null) { this.f3330b = getResources().newTheme(); Resources.Theme theme = getBaseContext().getTheme(); if (theme != null) { this.f3330b.setTo(theme); } } this.f3330b.applyStyle(this.f3329a, true); } public AssetManager getAssets() { return getResources().getAssets(); } public Resources getResources() { Resources resources; if (this.f3333e == null) { Configuration configuration = this.f3332d; if (configuration == null) { resources = super.getResources(); } else if (Build.VERSION.SDK_INT >= 17) { resources = createConfigurationContext(configuration).getResources(); } else { Resources resources2 = super.getResources(); Configuration configuration2 = new Configuration(resources2.getConfiguration()); configuration2.updateFrom(this.f3332d); this.f3333e = new Resources(resources2.getAssets(), resources2.getDisplayMetrics(), configuration2); } this.f3333e = resources; } return this.f3333e; } public Object getSystemService(String str) { if (!"layout_inflater".equals(str)) { return getBaseContext().getSystemService(str); } if (this.f3331c == null) { this.f3331c = LayoutInflater.from(getBaseContext()).cloneInContext(this); } return this.f3331c; } public Resources.Theme getTheme() { Resources.Theme theme = this.f3330b; if (theme != null) { return theme; } if (this.f3329a == 0) { this.f3329a = 2131755439; } mo3724b(); return this.f3330b; } public void setTheme(int i) { if (this.f3329a != i) { this.f3329a = i; mo3724b(); } } }
[ "adamchuk@gmail.com" ]
adamchuk@gmail.com
5ab5b2596cd52139e41ed79f39de3bdac11469fc
9fe49bf7832aba9292ddfcb88fa5e1a53c13a5a4
/src/main/java/ec/com/redepronik/negosys/entityAux/EntradaReporte.java
9f9d835441ab5d75fc972fef3af0691ea8ad5fd2
[]
no_license
Idonius/NegosysSpark
87c4c5bb560c54f519a8e54b2130557bc091eb63
c9ea96d2565500a806749ec4326e2bd3ac649b11
refs/heads/master
2022-03-07T14:31:01.583523
2015-08-27T04:34:55
2015-08-27T04:34:55
null
0
0
null
null
null
null
UTF-8
Java
false
false
745
java
package ec.com.redepronik.negosys.entityAux; import java.math.BigDecimal; import java.util.Date; public class EntradaReporte { private Date fecha; private BigDecimal valor; private String tipoPago; public EntradaReporte() { } public EntradaReporte(Date fecha, BigDecimal valor, String tipoPago) { this.fecha = fecha; this.valor = valor; this.tipoPago = tipoPago; } public Date getFecha() { return fecha; } public String getTipoPago() { return tipoPago; } public BigDecimal getValor() { return valor; } public void setFecha(Date fecha) { this.fecha = fecha; } public void setTipoPago(String tipoPago) { this.tipoPago = tipoPago; } public void setValor(BigDecimal valor) { this.valor = valor; } }
[ "aguachisaca@redepronik.com.ec" ]
aguachisaca@redepronik.com.ec
064bbbcf942fd1d2c014242fa410d06a4a861e3f
4f3da4a2f1749b53a76010839a84ffc61e85df15
/startandroid/P0341_SimpleSQLitemy/app/src/main/java/com/example/p0341_simplesqlite/DBHelper.java
9990e61deaa05b6b421de2d7c15e24ee0b8ee55f
[]
no_license
ValenbergHar/LearningAndroid
d29df4b1d5588a25f2cfaa78e43eb4ec96c0a278
75d7b147a6918bb07fbde5b275710d8866bbfbb1
refs/heads/master
2023-05-25T07:46:23.737809
2021-06-08T19:34:30
2021-06-08T19:34:30
319,338,640
0
0
null
null
null
null
UTF-8
Java
false
false
1,071
java
package com.example.p0341_simplesqlite; import android.content.Context; import android.database.sqlite.SQLiteDatabase; import android.database.sqlite.SQLiteOpenHelper; import android.util.Log; import static com.example.p0341_simplesqlite.Util.LOG_TAG; class DBHelper extends SQLiteOpenHelper { public DBHelper(Context context) { // конструктор суперкласса super(context, Util.DATABASE_NAME, null, 1); } @Override public void onCreate(SQLiteDatabase db) { Log.d(LOG_TAG, "--- onCreate database ---"); // создаем таблицу с полями // db.execSQL("create table mytable (" // + "id integer primary key autoincrement," // + "name text," // + "email text" + ");"); // } String CREATE_DB = "create table " + Util.TABLE_NAME + " ( " + Util.KEY_NAME + " text);"; db.execSQL(CREATE_DB); } @Override public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) { } }
[ "maskevich.valeri@gmail.com" ]
maskevich.valeri@gmail.com
4bdac940ca0a6c247c24fa1a36a22adef4b9a084
48e835e6f176a8ac9ae3ca718e8922891f1e5a18
/benchmark/training/com/fishercoder/_348Test.java
9545faf5bf3a75f5b652391364bafacffc0c04b6
[]
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
1,207
java
package com.fishercoder; import _348.Solution1.TicTacToe; import org.junit.Assert; import org.junit.Test; public class _348Test { @Test public void test1() { int n = 3; TicTacToe ticTacToe = new TicTacToe(n); Assert.assertEquals(0, ticTacToe.move(0, 0, 1)); Assert.assertEquals(0, ticTacToe.move(0, 2, 2)); Assert.assertEquals(0, ticTacToe.move(2, 2, 1)); Assert.assertEquals(0, ticTacToe.move(1, 1, 2)); Assert.assertEquals(0, ticTacToe.move(2, 0, 1)); Assert.assertEquals(0, ticTacToe.move(1, 0, 2)); Assert.assertEquals(1, ticTacToe.move(2, 1, 1)); } @Test public void test2() { int n = 3; TicTacToe ticTacToe = new TicTacToe(n); Assert.assertEquals(0, ticTacToe.move(0, 0, 1)); Assert.assertEquals(0, ticTacToe.move(1, 1, 1)); Assert.assertEquals(1, ticTacToe.move(2, 2, 1)); } @Test public void test3() { int n = 3; TicTacToe ticTacToe = new TicTacToe(n); Assert.assertEquals(0, ticTacToe.move(0, 2, 2)); Assert.assertEquals(0, ticTacToe.move(1, 1, 2)); Assert.assertEquals(2, ticTacToe.move(2, 0, 2)); } }
[ "benjamin.danglot@inria.fr" ]
benjamin.danglot@inria.fr
7ce496e9bf3acf258d38eba074aa42e3f7e1c04e
e68f03c67d4bab04a83a237546b6f9bf532ac6a0
/src/main/java/cn/com/sky/patterns/behavioral/visitor/dynamic_double_dispatch/SubWest1.java
8b86d7b167ea6c2f5d05af586f4cd19c7575b621
[]
no_license
git-sky/patterns
010e6a8e11c62546c6360003630cc630ea68e259
cd4bad97c731faf091631d9afb03312015d15114
refs/heads/master
2021-07-06T23:20:56.419981
2021-06-20T15:11:16
2021-06-20T15:11:16
73,152,900
0
0
null
null
null
null
UTF-8
Java
false
false
380
java
package cn.com.sky.patterns.behavioral.visitor.dynamic_double_dispatch; public class SubWest1 extends West{ @Override public void goWest1(SubEast1 east) { System.out.println("SubWest1 + " + east.myName1()); } @Override public void goWest2(SubEast2 east) { System.out.println("SubWest1 + " + east.myName2()); } }
[ "linkme2008@sina.com" ]
linkme2008@sina.com
c3299a012063980de562e95bfe459a23095334b6
3e56ba5f828585bf5a05800fc5e210d79097b400
/src/test/java/com/automation/tests/day5/RadioButtonsTest.java
1539633416af3c74ac2a2618f467394092229bcd
[]
no_license
vooolkan/Fall2019Selenium
33f5b3de7b29845b23fff3ba270a065a02a00db3
a05cfc5f839cdb6c6a9da4abe6ca97e5ae34c7e9
refs/heads/master
2022-10-09T04:54:23.126292
2020-06-07T21:51:53
2020-06-07T21:51:53
293,993,042
1
0
null
2020-09-09T03:30:55
2020-09-09T03:30:55
null
UTF-8
Java
false
false
1,465
java
package com.automation.tests.day5; import com.automation.utilities.BrowserUtils; import com.automation.utilities.DriverFactory; import io.github.bonigarcia.wdm.WebDriverManager; import org.openqa.selenium.By; import org.openqa.selenium.WebDriver; import org.openqa.selenium.*; import org.openqa.selenium.chrome.ChromeDriver; public class RadioButtonsTest { public static void main(String[] args) { // if DriverFactory doesn't work, use this: // WebDriverManager.chromedriver().version("79").setup(); // WebDriver driver = new ChromeDriver(); WebDriver driver = DriverFactory.createDriver("chrome"); driver.get("http://practice.cybertekschool.com/radio_buttons"); BrowserUtils.wait(4); //<input type="radio" id="black" name="color"> WebElement blackButton = driver.findElement(By.id("black")); //if visible and eligible to click if(blackButton.isDisplayed() && blackButton.isEnabled()){ System.out.println("CLICKED ON BLACK BUTTON"); blackButton.click(); }else { System.out.println("FAILED TO CLICK ON BLACK BUTTON"); } BrowserUtils.wait(2); //how do we verify that button clicked //returns true, if button clicked if(blackButton.isSelected()){ System.out.println("TEST PASSED!"); }else { System.out.println("TEST FAILED"); } driver.quit(); } }
[ "github@cybertekschool.com" ]
github@cybertekschool.com
a62c94475dda3c8875ac4a433dbd69158414deb1
7559bead0c8a6ad16f016094ea821a62df31348a
/src/com/vmware/vim25/OvfSystemFault.java
4a8abf92e499c28ef367460811f1e6319605588d
[]
no_license
ZhaoxuepengS/VsphereTest
09ba2af6f0a02d673feb9579daf14e82b7317c36
59ddb972ce666534bf58d84322d8547ad3493b6e
refs/heads/master
2021-07-21T13:03:32.346381
2017-11-01T12:30:18
2017-11-01T12:30:18
109,128,993
1
1
null
null
null
null
UTF-8
Java
false
false
1,057
java
package com.vmware.vim25; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlSeeAlso; import javax.xml.bind.annotation.XmlType; /** * <p>Java class for OvfSystemFault complex type. * * <p>The following schema fragment specifies the expected content contained within this class. * * <pre> * &lt;complexType name="OvfSystemFault"> * &lt;complexContent> * &lt;extension base="{urn:vim25}OvfFault"> * &lt;sequence> * &lt;/sequence> * &lt;/extension> * &lt;/complexContent> * &lt;/complexType> * </pre> * * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "OvfSystemFault") @XmlSeeAlso({ OvfUnsupportedDeviceBackingOption.class, OvfToXmlUnsupportedElement.class, OvfUnknownEntity.class, OvfUnknownDevice.class, OvfInternalError.class, OvfHostValueNotParsed.class, OvfUnsupportedDeviceBackingInfo.class, OvfDiskMappingNotFound.class }) public class OvfSystemFault extends OvfFault { }
[ "495149700@qq.com" ]
495149700@qq.com
76bbb737fba7640ce184df86af8d47229bea0bc7
2c47066781f0398cfc78c247b3817ef7385a78fa
/compiler/frontend.java/src/org/jetbrains/jet/lang/resolve/java/structure/impl/JavaArrayAnnotationArgumentImpl.java
9f51839dfdfe55458b182df5cd1d2cbdc8525821
[]
no_license
hhariri/kotlin
9e60383961d5ba9e6216b8344f3fb54165262e49
d150bfbce0e2e47d687f39e2fd233ea55b2ccd26
refs/heads/master
2021-01-21T02:11:33.068540
2014-06-20T14:52:30
2014-06-21T08:26:34
21,116,939
1
0
null
null
null
null
UTF-8
Java
false
false
1,695
java
/* * Copyright 2010-2013 JetBrains s.r.o. * * 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.jetbrains.jet.lang.resolve.java.structure.impl; import com.intellij.psi.PsiArrayInitializerMemberValue; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; import org.jetbrains.jet.lang.resolve.java.structure.JavaAnnotationArgument; import org.jetbrains.jet.lang.resolve.java.structure.JavaArrayAnnotationArgument; import org.jetbrains.jet.lang.resolve.name.Name; import java.util.List; import static org.jetbrains.jet.lang.resolve.java.structure.impl.JavaElementCollectionFromPsiArrayUtil.namelessAnnotationArguments; public class JavaArrayAnnotationArgumentImpl extends JavaAnnotationArgumentImpl<PsiArrayInitializerMemberValue> implements JavaArrayAnnotationArgument { protected JavaArrayAnnotationArgumentImpl(@NotNull PsiArrayInitializerMemberValue psiArrayInitializerMemberValue, @Nullable Name name) { super(psiArrayInitializerMemberValue, name); } @Override @NotNull public List<JavaAnnotationArgument> getElements() { return namelessAnnotationArguments(getPsi().getInitializers()); } }
[ "Alexander.Udalov@jetbrains.com" ]
Alexander.Udalov@jetbrains.com
6fc461fe9bd2a6fbfba9402b1039cf8682afc400
421f0a75a6b62c5af62f89595be61f406328113b
/generated_tests/model_seeding/21_geo-google-oasis.names.tc.ciq.xsdschema.xal._2.DependentLocalityType-1.0-8/oasis/names/tc/ciq/xsdschema/xal/_2/DependentLocalityType_ESTest.java
12e7cc9fcef1b73c1130f752d048bf767a81f367
[]
no_license
tigerqiu712/evosuite-model-seeding-empirical-evaluation
c78c4b775e5c074aaa5e6ca56bc394ec03c2c7c6
11a920b8213d9855082d3946233731c843baf7bc
refs/heads/master
2020-12-23T21:04:12.152289
2019-10-30T08:02:29
2019-10-30T08:02:29
null
0
0
null
null
null
null
UTF-8
Java
false
false
683
java
/* * This file was automatically generated by EvoSuite * Fri Oct 25 23:22:14 GMT 2019 */ package oasis.names.tc.ciq.xsdschema.xal._2; 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(mockJVMNonDeterminism = true, useVFS = true, useVNET = true, resetStaticState = true, separateClassLoader = true, useJEE = true) public class DependentLocalityType_ESTest extends DependentLocalityType_ESTest_scaffolding { @Test public void notGeneratedAnyTest() { // EvoSuite did not generate any tests } }
[ "pderakhshanfar@bsr01.win.tue.nl" ]
pderakhshanfar@bsr01.win.tue.nl
6910ee2206d5b6c9213ec34cb354af1136c55e9b
1df9b2dd4a7db2f1673638a46ecb6f20a3933994
/Spring-proctice/src/SCenter/viper-client-api/target/generated-dtl/src/main/java/com/allconnect/xml/dtl/v4/MarketItemType.java
3341a7d600237477eca96ba12fe3a1aea55ea799
[]
no_license
pavanhp001/Spring-boot-proct
71cfb3e86f74aa22951f66a87d55ba4a18b5c6c7
238bf76e1b68d46acb3d0e98cb34a53a121643dc
refs/heads/master
2020-03-20T12:23:10.735785
2019-03-18T04:03:40
2019-03-18T04:03:40
137,428,541
0
0
null
null
null
null
UTF-8
Java
false
false
1,470
java
package com.A.xml.dtl.v4; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.XmlType; /** * <p>Java class for marketItemType complex type. * * <p>The following schema fragment specifies the expected content contained within this class. * * <pre> * &lt;complexType name="marketItemType"> * &lt;complexContent> * &lt;extension base="{http://xml.A.com/v4}coreMarketItemType"> * &lt;sequence> * &lt;element name="item" type="{http://xml.A.com/v4}itemType"/> * &lt;/sequence> * &lt;/extension> * &lt;/complexContent> * &lt;/complexType> * </pre> * * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "marketItemType", propOrder = { "item" }) public class MarketItemType extends CoreMarketItemType { @XmlElement(required = true) protected ItemType item; /** * Gets the value of the item property. * * @return * possible object is * {@link ItemType } * */ public ItemType getItem() { return item; } /** * Sets the value of the item property. * * @param value * allowed object is * {@link ItemType } * */ public void setItem(ItemType value) { this.item = value; } }
[ "pavan.hp001@gmail.com" ]
pavan.hp001@gmail.com
aad7b1334d784f982a7e8c5ab1ba429d2045f648
1f29f7842e30d6265fb9dbb302fe9414755e7403
/src/main/java/com/eurodyn/okstra/ArtWassereinleitungspunktType.java
fd637188006df66993a1da9636c6c2f299b395ca
[]
no_license
dpapageo/okstra-2018-classes
b4165aea3c84ffafaa434a3a1f8cf0fff58de599
fb908eabc183725be01c9f93d39268bb8e630f59
refs/heads/master
2021-03-26T00:22:28.205974
2020-03-16T09:16:31
2020-03-16T09:16:31
247,657,881
2
0
null
null
null
null
UTF-8
Java
false
false
2,646
java
// // This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.11 // See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> // Any modifications to this file will be lost upon recompilation of the source schema. // Generated on: 2020.03.09 at 04:49:50 PM EET // package com.eurodyn.okstra; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.XmlType; /** * <p>Java class for Art_WassereinleitungspunktType complex type. * * <p>The following schema fragment specifies the expected content contained within this class. * * <pre> * &lt;complexType name="Art_WassereinleitungspunktType"&gt; * &lt;complexContent&gt; * &lt;extension base="{http://www.opengis.net/gml/3.2}AbstractFeatureType"&gt; * &lt;sequence&gt; * &lt;element name="Kennung" type="{http://www.w3.org/2001/XMLSchema}string"/&gt; * &lt;element name="Langtext" type="{http://www.w3.org/2001/XMLSchema}string"/&gt; * &lt;/sequence&gt; * &lt;/extension&gt; * &lt;/complexContent&gt; * &lt;/complexType&gt; * </pre> * * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "Art_WassereinleitungspunktType", propOrder = { "kennung", "langtext" }) public class ArtWassereinleitungspunktType extends AbstractFeatureType { @XmlElement(name = "Kennung", required = true) protected String kennung; @XmlElement(name = "Langtext", required = true) protected String langtext; /** * Gets the value of the kennung property. * * @return * possible object is * {@link String } * */ public String getKennung() { return kennung; } /** * Sets the value of the kennung property. * * @param value * allowed object is * {@link String } * */ public void setKennung(String value) { this.kennung = value; } /** * Gets the value of the langtext property. * * @return * possible object is * {@link String } * */ public String getLangtext() { return langtext; } /** * Sets the value of the langtext property. * * @param value * allowed object is * {@link String } * */ public void setLangtext(String value) { this.langtext = value; } }
[ "Dimitrios.Papageorgiou@eurodyn.com" ]
Dimitrios.Papageorgiou@eurodyn.com
26927d2369c2d76f225efc84494a81bdf89e283e
51aef8e206201568d04fb919bf54a3009c039dcf
/trunk/src/com/jmex/model/collada/schema/line_smooth_enableType2.java
5829cd4a562b51d93b4c14d13517ed0e1613f905
[]
no_license
lihak/fairytale-soulfire-svn-to-git
0b8bdbfcaf774f13fc3d32cc3d3a6fae64f29c81
a85eb3fc6f4edf30fef9201902fcdc108da248e4
refs/heads/master
2021-02-11T15:25:47.199953
2015-12-28T14:48:14
2015-12-28T14:48:14
null
0
0
null
null
null
null
UTF-8
Java
false
false
5,800
java
/** * line_smooth_enableType2.java * * This file was generated by XMLSpy 2007sp2 Enterprise Edition. * * YOU SHOULD NOT MODIFY THIS FILE, BECAUSE IT WILL BE * OVERWRITTEN WHEN YOU RE-RUN CODE GENERATION. * * Refer to the XMLSpy Documentation for further details. * http://www.altova.com/xmlspy */ package com.jmex.model.collada.schema; import com.jmex.xml.types.SchemaNCName; public class line_smooth_enableType2 extends com.jmex.xml.xml.Node { public line_smooth_enableType2(line_smooth_enableType2 node) { super(node); } public line_smooth_enableType2(org.w3c.dom.Node node) { super(node); } public line_smooth_enableType2(org.w3c.dom.Document doc) { super(doc); } public line_smooth_enableType2(com.jmex.xml.xml.Document doc, String namespaceURI, String prefix, String name) { super(doc, namespaceURI, prefix, name); } public void adjustPrefix() { for ( org.w3c.dom.Node tmpNode = getDomFirstChild( Attribute, null, "value" ); tmpNode != null; tmpNode = getDomNextChild( Attribute, null, "value", tmpNode ) ) { internalAdjustPrefix(tmpNode, false); } for ( org.w3c.dom.Node tmpNode = getDomFirstChild( Attribute, null, "param" ); tmpNode != null; tmpNode = getDomNextChild( Attribute, null, "param", tmpNode ) ) { internalAdjustPrefix(tmpNode, false); } } public void setXsiType() { org.w3c.dom.Element el = (org.w3c.dom.Element) domNode; el.setAttributeNS("http://www.w3.org/2001/XMLSchema-instance", "xsi:type", "line_smooth_enable"); } public static int getvalue2MinCount() { return 0; } public static int getvalue2MaxCount() { return 1; } public int getvalue2Count() { return getDomChildCount(Attribute, null, "value"); } public boolean hasvalue2() { return hasDomChild(Attribute, null, "value"); } public bool newvalue2() { return new bool(); } public bool getvalue2At(int index) throws Exception { return new bool(getDomNodeValue(getDomChildAt(Attribute, null, "value", index))); } public org.w3c.dom.Node getStartingvalue2Cursor() throws Exception { return getDomFirstChild(Attribute, null, "value" ); } public org.w3c.dom.Node getAdvancedvalue2Cursor( org.w3c.dom.Node curNode ) throws Exception { return getDomNextChild( Attribute, null, "value", curNode ); } public bool getvalue2ValueAtCursor( org.w3c.dom.Node curNode ) throws Exception { if( curNode == null ) throw new com.jmex.xml.xml.XmlException("Out of range"); else return new bool(getDomNodeValue(curNode)); } public bool getvalue2() throws Exception { return getvalue2At(0); } public void removevalue2At(int index) { removeDomChildAt(Attribute, null, "value", index); } public void removevalue2() { removevalue2At(0); } public org.w3c.dom.Node addvalue2(bool value) { if( value.isNull() ) return null; return appendDomChild(Attribute, null, "value", value.toString()); } public org.w3c.dom.Node addvalue2(String value) throws Exception { return addvalue2(new bool(value)); } public void insertvalue2At(bool value, int index) { insertDomChildAt(Attribute, null, "value", index, value.toString()); } public void insertvalue2At(String value, int index) throws Exception { insertvalue2At(new bool(value), index); } public void replacevalue2At(bool value, int index) { replaceDomChildAt(Attribute, null, "value", index, value.toString()); } public void replacevalue2At(String value, int index) throws Exception { replacevalue2At(new bool(value), index); } public static int getparamMinCount() { return 0; } public static int getparamMaxCount() { return 1; } public int getparamCount() { return getDomChildCount(Attribute, null, "param"); } public boolean hasparam() { return hasDomChild(Attribute, null, "param"); } public SchemaNCName newparam() { return new SchemaNCName(); } public SchemaNCName getparamAt(int index) throws Exception { return new SchemaNCName(getDomNodeValue(getDomChildAt(Attribute, null, "param", index))); } public org.w3c.dom.Node getStartingparamCursor() throws Exception { return getDomFirstChild(Attribute, null, "param" ); } public org.w3c.dom.Node getAdvancedparamCursor( org.w3c.dom.Node curNode ) throws Exception { return getDomNextChild( Attribute, null, "param", curNode ); } public SchemaNCName getparamValueAtCursor( org.w3c.dom.Node curNode ) throws Exception { if( curNode == null ) throw new com.jmex.xml.xml.XmlException("Out of range"); else return new SchemaNCName(getDomNodeValue(curNode)); } public SchemaNCName getparam() throws Exception { return getparamAt(0); } public void removeparamAt(int index) { removeDomChildAt(Attribute, null, "param", index); } public void removeparam() { removeparamAt(0); } public org.w3c.dom.Node addparam(SchemaNCName value) { if( value.isNull() ) return null; return appendDomChild(Attribute, null, "param", value.toString()); } public org.w3c.dom.Node addparam(String value) throws Exception { return addparam(new SchemaNCName(value)); } public void insertparamAt(SchemaNCName value, int index) { insertDomChildAt(Attribute, null, "param", index, value.toString()); } public void insertparamAt(String value, int index) throws Exception { insertparamAt(new SchemaNCName(value), index); } public void replaceparamAt(SchemaNCName value, int index) { replaceDomChildAt(Attribute, null, "param", index, value.toString()); } public void replaceparamAt(String value, int index) throws Exception { replaceparamAt(new SchemaNCName(value), index); } }
[ "you@example.com" ]
you@example.com
ac76fde0de5193d850bcf61744fb4424161ce304
2c9f5bef1bd83f4e9b530d447729cc44fe15e2cb
/android/app/src/main/java/come/manager/direct/hackuniversity/BlankFragment.java
380c4882b6ac467578531d3268b8c14070342b58
[]
no_license
dase1243/TicketChain
a55ddab30c7ba02295d9e5941af41011875d1266
6b2277c2c33838900cb606ef1ce7a790e379b2f2
refs/heads/master
2020-11-24T22:53:14.645146
2019-12-16T11:33:52
2019-12-16T11:33:52
228,373,225
0
0
null
null
null
null
UTF-8
Java
false
false
8,074
java
package come.manager.direct.hackuniversity; import android.content.Context; import android.net.Uri; import android.os.Bundle; import android.support.v4.app.Fragment; import android.support.v7.widget.CardView; import android.support.v7.widget.LinearLayoutManager; import android.support.v7.widget.RecyclerView; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.webkit.WebView; import android.widget.ImageButton; import android.widget.ImageView; import android.widget.TextView; import java.util.ArrayList; import come.manager.direct.hackuniversity.model.Event; /** * A simple {@link Fragment} subclass. * Activities that contain this fragment must implement the * {@link OnFragmentInteractionListener} interface * to handle interaction events. * Use the {@link BlankFragment#newInstance} factory method to * create an instance of this fragment. */ public class BlankFragment extends Fragment { // TODO: Rename parameter arguments, choose names that match // the fragment initialization parameters, e.g. ARG_ITEM_NUMBER private static final String ARG_PARAM1 = "param1"; ArrayList<Event> arrayList; private WebView webView; private static final String ARG_PARAM2 = "param2"; private RecyclerView rvNumbers; ; // TODO: Rename and change types of parameters private ArrayList<Event> mParam1; private String mParam2; private OnFragmentInteractionListener mListener; public BlankFragment() { // Required empty public constructor } /** * Use this factory method to create a new instance of * this fragment using the provided parameters. * * @param param1 Parameter 1. * @param param2 Parameter 2. * @return A new instance of fragment BlankFragment. */ // TODO: Rename and change types and number of parameters public static BlankFragment newInstance(ArrayList<Event> param1, String param2) { BlankFragment fragment = new BlankFragment(); Bundle args = new Bundle(); args.putParcelableArrayList(ARG_PARAM1, param1); args.putString(ARG_PARAM2, param2); fragment.setArguments(args); return fragment; } @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); if (getArguments() != null) { mParam1 = getArguments().getParcelableArrayList(ARG_PARAM1); mParam2 = getArguments().getString(ARG_PARAM2); } } @Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { // Inflate the layout for this fragment View view = inflater.inflate(R.layout.fragment_blank, container, false); ArrayList<Event> events = new ArrayList<>(); // Event event = new Event(); // event.setCity("London"); // event.setName("Imagin"); // event.setImage(R.drawable.logo+""); // event.setStatus("true"); // Event event1 = new Event(); // event1.setCity("Moscow"); // event1.setName("Leningrad"); // event1.setImage(R.drawable.logo+""); // event1.setStatus("false"); // // events.add(event); // events.add(event1); rvNumbers = (RecyclerView) view.findViewById(R.id.rv_numbers); rvNumbers.setLayoutManager(new LinearLayoutManager(getActivity())); rvNumbers.setAdapter(new RecyclerViewAdapter(mParam1, (ActivityWithWebView) getActivity())); return view; } // TODO: Rename method, update argument and hook method into UI event public void onButtonPressed(Uri uri) { if (mListener != null) { mListener.onFragmentInteraction(uri); } } @Override public void onAttach(Context context) { super.onAttach(context); if (context instanceof OnFragmentInteractionListener) { mListener = (OnFragmentInteractionListener) context; } else { throw new RuntimeException(context.toString() + " must implement OnFragmentInteractionListener"); } } @Override public void onDetach() { super.onDetach(); mListener = null; } /** * This interface must be implemented by activities that contain this * fragment to allow an interaction in this fragment to be communicated * to the activity and potentially other fragments contained in that * activity. * <p> * See the Android Training lesson <a href= * "http://developer.android.com/training/basics/fragments/communicating.html" * >Communicating with Other Fragments</a> for more information. */ class RecyclerViewAdapter extends RecyclerView.Adapter<RecyclerViewAdapter.EventViewHolder> { ArrayList<Event> listData; private final OnItemClickListener listener; public RecyclerViewAdapter(ArrayList<Event> data, OnItemClickListener clickListener) { this.listData = data; listener = clickListener; } @Override public RecyclerViewAdapter.EventViewHolder onCreateViewHolder(ViewGroup parent, int viewType) { View v = LayoutInflater.from(parent.getContext()).inflate(R.layout.list_item, parent, false); RecyclerViewAdapter.EventViewHolder vh = new RecyclerViewAdapter.EventViewHolder(v); return vh; } @Override public void onBindViewHolder(EventViewHolder personViewHolder, int i) { personViewHolder.bind(listData.get(i), listener); personViewHolder.personName.setText(listData.get(i).getName()); personViewHolder.personAge.setText(listData.get(i).getCity()); personViewHolder.personPhoto.setImageResource(new Integer(listData.get(i).getImage())); if (listData.get(i).getStatus().equals("true")) { personViewHolder.status.setImageResource(R.drawable.open_letter); } else { personViewHolder.status.setImageResource(R.drawable.close_letter); } } @Override public int getItemCount() { return listData.size(); } public class EventViewHolder extends RecyclerView.ViewHolder { CardView cv; TextView personName; TextView personAge; ImageView personPhoto; ImageView status; ImageButton send; EventViewHolder(View itemView) { super(itemView); cv = (CardView) itemView.findViewById(R.id.cv); personName = (TextView) itemView.findViewById(R.id.person_name); personAge = (TextView) itemView.findViewById(R.id.person_age); personPhoto = (ImageView) itemView.findViewById(R.id.person_photo); status = itemView.findViewById(R.id.status_image); send = itemView.findViewById(R.id.send_button); } public void bind(final Event item, final OnItemClickListener listener) { personName.setText(item.getName()); personAge.setText(item.getCity()); try { personPhoto.setImageResource(new Integer(item.getImage())); } catch (Exception e) { personPhoto.setImageResource(R.drawable.logo); } if (item.getStatus().equals("true")) { status.setImageResource(R.drawable.open_letter); } else { status.setImageResource(R.drawable.close_letter); } itemView.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { listener.onItemClick(item); } }); } } } public interface OnItemClickListener { void onItemClick(Event item); } }
[ "dreiglushko@gmail.com" ]
dreiglushko@gmail.com
c1f0a512ea471c0d52317f06080cacebc8d9f609
02a087e8de0a7d0cfed9dba60e8cff5be4ae3be1
/Research_Bucket/Completed_Archived/ConcolicProcess/oracles/Bellon/bellon_benchmark/sourcecode/eclipse-ant/src/ant/taskdefs/Mkdir.java
7f7d567a5b80897dd050e6ae470deb4c3e2f6c9e
[]
no_license
dan7800/Research
7baf8d5afda9824dc5a53f55c3e73f9734e61d46
f68ea72c599f74e88dd44d85503cc672474ec12a
refs/heads/master
2021-01-23T09:50:47.744309
2018-09-01T14:56:01
2018-09-01T14:56:01
32,521,867
1
1
null
null
null
null
UTF-8
Java
false
false
3,537
java
/* * The Apache Software License, Version 1.1 * * Copyright (c) 1999 The Apache Software Foundation. All rights * reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in * the documentation and/or other materials provided with the * distribution. * * 3. The end-user documentation included with the redistribution, if * any, must include the following acknowlegement: * "This product includes software developed by the * Apache Software Foundation (http://www.apache.org/)." * Alternately, this acknowlegement may appear in the software itself, * if and wherever such third-party acknowlegements normally appear. * * 4. The names "The Jakarta Project", "Ant", and "Apache Software * Foundation" must not be used to endorse or promote products derived * from this software without prior written permission. For written * permission, please contact apache@apache.org. * * 5. Products derived from this software may not be called "Apache" * nor may "Apache" appear in their names without prior written * permission of the Apache Group. * * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * ==================================================================== * * This software consists of voluntary contributions made by many * individuals on behalf of the Apache Software Foundation. For more * information on the Apache Software Foundation, please see * <http://www.apache.org/>. */ package org.apache.tools.ant.taskdefs; import org.apache.tools.ant.*; import java.io.File; /** * Creates a given directory. * * @author duncan@x180.com */ public class Mkdir extends Task { private File dir; public void execute() throws BuildException { if (dir == null) { throw new BuildException("dir attribute is required", location); } if (dir.isFile()) { throw new BuildException("Unable to create directory as a file already exists with that name: " + dir.getAbsolutePath()); } if (!dir.exists()) { boolean result = dir.mkdirs(); if (result == false) { String msg = "Directory " + dir.getAbsolutePath() + " creation was not " + "successful for an unknown reason"; throw new BuildException(msg, location); } log("Created dir: " + dir.getAbsolutePath()); } } public void setDir(File dir) { this.dir = dir; } }
[ "dxkvse@rit.edu" ]
dxkvse@rit.edu
7487e08cb8bebd021358ab7ba5a30fbba24b2ac7
e8cd24201cbfadef0f267151ea5b8a90cc505766
/group06/263050006/src/main/java/com/github/chaoswang/learning/java/jvm/constant/FieldRefInfo.java
ec7677874227fe8697f22e6d3af1253ba37d2ea1
[]
no_license
XMT-CN/coding2017-s1
30dd4ee886dd0a021498108353c20360148a6065
382f6bfeeeda2e76ffe27b440df4f328f9eafbe2
refs/heads/master
2021-01-21T21:38:42.199253
2017-06-25T07:44:21
2017-06-25T07:44:21
94,863,023
0
0
null
null
null
null
UTF-8
Java
false
false
1,607
java
package com.github.chaoswang.learning.java.jvm.constant; /** * CONSTANT_Fieldref_info { * u1 tag; * u2 class_index; * u2 name_and_type_index; * } */ public class FieldRefInfo extends ConstantInfo{ private int type = ConstantInfo.FIELD_INFO; private int classInfoIndex; private int nameAndTypeIndex; public FieldRefInfo(ConstantPool pool) { super(pool); } public int getType() { return type; } public int getClassInfoIndex() { return classInfoIndex; } public void setClassInfoIndex(int classInfoIndex) { this.classInfoIndex = classInfoIndex; } public int getNameAndTypeIndex() { return nameAndTypeIndex; } public void setNameAndTypeIndex(int nameAndTypeIndex) { this.nameAndTypeIndex = nameAndTypeIndex; } public String toString(){ NameAndTypeInfo typeInfo = (NameAndTypeInfo)this.getConstantInfo(this.getNameAndTypeIndex()); return getClassName() +" : "+ typeInfo.getName() + ":" + typeInfo.getTypeInfo() +"]"; } public String getClassName(){ ClassInfo classInfo = (ClassInfo) this.getConstantInfo(this.getClassInfoIndex()); UTF8Info utf8Info = (UTF8Info)this.getConstantInfo(classInfo.getUtf8Index()); return utf8Info.getValue(); } public String getFieldName(){ NameAndTypeInfo typeInfo = (NameAndTypeInfo)this.getConstantInfo(this.getNameAndTypeIndex()); return typeInfo.getName(); } public String getFieldType(){ NameAndTypeInfo typeInfo = (NameAndTypeInfo)this.getConstantInfo(this.getNameAndTypeIndex()); return typeInfo.getTypeInfo(); } }
[ "542194147@qq.com" ]
542194147@qq.com
dbbcf109c0206180bf1363b743ce3033b0fa53ef
523f0974208620ef50ef29573c7468c007db1767
/order-processor/src/main/java/town/lost/oms/OrderViewerMain.java
c8f2f7b46d5e749eb846d9eaae8ecfe7734a57e5
[ "Apache-2.0" ]
permissive
numberonewastefellow/Chronicle-Queue-Demo
7cb6d5ec9eca68501d5c281a4e95d90bc0219a3b
6af102906de5176f9162f128bff424afe48fae1a
refs/heads/master
2023-06-02T03:21:24.168739
2021-06-17T00:18:19
2021-06-17T00:18:19
null
0
0
null
null
null
null
UTF-8
Java
false
false
954
java
/* * Copyright (c) 2016-2019 Chronicle Software Ltd */ package town.lost.oms; import net.openhft.chronicle.bytes.MethodReader; import net.openhft.chronicle.core.Jvm; import net.openhft.chronicle.core.Mocker; import net.openhft.chronicle.queue.ChronicleQueue; import net.openhft.chronicle.queue.RollCycles; import net.openhft.chronicle.queue.impl.single.SingleChronicleQueueBuilder; import town.lost.oms.api.OMSIn; public class OrderViewerMain { public static void main(String[] args) { System.out.println("\nWaiting for messages"); try (ChronicleQueue q = SingleChronicleQueueBuilder.binary("in").rollCycle(RollCycles.TEST8_DAILY).build()) { OMSIn logging = Mocker.logging(OMSIn.class, "read - ", System.out); MethodReader reader = q.createTailer().methodReader(logging); while (true) { if (!reader.readOne()) Jvm.pause(50); } } } }
[ "peter.lawrey@higherfrequencytrading.com" ]
peter.lawrey@higherfrequencytrading.com
157b19ddbace6678c44f60ebdc837540ed4ea10b
ed5159d056e98d6715357d0d14a9b3f20b764f89
/src/irvine/oeis/a028/A028750.java
21f7563df75324cec8f9a9b3aabcb9efc936335e
[]
no_license
flywind2/joeis
c5753169cf562939b04dd246f8a2958e97f74558
e5efd6971a0062ac99f4fae21a7c78c9f9e74fea
refs/heads/master
2020-09-13T18:34:35.080552
2019-11-19T05:40:55
2019-11-19T05:40:55
null
0
0
null
null
null
null
UTF-8
Java
false
false
325
java
package irvine.oeis.a028; import irvine.oeis.FiniteSequence; /** * A028750 Nonsquares <code>mod 37</code>. * @author Georg Fischer */ public class A028750 extends FiniteSequence { /** Construct the sequence. */ public A028750() { super(2, 5, 6, 8, 13, 14, 15, 17, 18, 19, 20, 22, 23, 24, 29, 31, 32, 35); } }
[ "sean.irvine@realtimegenomics.com" ]
sean.irvine@realtimegenomics.com
05ee687e8fcd7afd3e82cc12a4c2c11cb64851cc
e09b97f3318e7b8c9b22f1b49bf58df254bf7baa
/quickstarts/travel-spring/src/test/java/org/springframework/samples/travel/BookingFlowExecutionTests.java
e20309f237c127d7b217f6bdf07f9a0c5db3a563
[]
no_license
snowdrop/legacy_content
2837d0c570f1886b64812211ec5ef14c2f560857
d079a58b598f3080ccee1bc95ca137fb8ffdb9b8
refs/heads/master
2020-12-02T08:00:41.568207
2017-07-10T09:39:38
2017-07-10T09:39:38
96,759,977
1
1
null
null
null
null
UTF-8
Java
false
false
3,796
java
/* * JBoss, Home of Professional Open Source * Copyright 2012, Red Hat, Inc. and/or its affiliates, and individual * contributors by the @authors tag. See the copyright.txt in the * distribution for a full listing of individual contributors. * * 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.springframework.samples.travel; import org.easymock.EasyMock; import org.springframework.webflow.config.FlowDefinitionResource; import org.springframework.webflow.config.FlowDefinitionResourceFactory; import org.springframework.webflow.core.collection.LocalAttributeMap; import org.springframework.webflow.core.collection.MutableAttributeMap; import org.springframework.webflow.test.MockExternalContext; import org.springframework.webflow.test.MockFlowBuilderContext; import org.springframework.webflow.test.execution.AbstractXmlFlowExecutionTests; public class BookingFlowExecutionTests extends AbstractXmlFlowExecutionTests { private BookingService bookingService; protected void setUp() { bookingService = EasyMock.createMock(BookingService.class); } @Override protected FlowDefinitionResource getResource(FlowDefinitionResourceFactory resourceFactory) { return resourceFactory.createFileResource("src/main/webapp/WEB-INF/hotels/booking/booking-flow.xml"); } @Override protected void configureFlowBuilderContext(MockFlowBuilderContext builderContext) { builderContext.registerBean("bookingService", bookingService); } public void testStartBookingFlow() { Booking booking = createTestBooking(); EasyMock.expect(bookingService.createBooking(1L, "keith")).andReturn(booking); EasyMock.replay(bookingService); MutableAttributeMap input = new LocalAttributeMap(); input.put("hotelId", "1"); MockExternalContext context = new MockExternalContext(); context.setCurrentUser("keith"); startFlow(input, context); assertCurrentStateEquals("enterBookingDetails"); assertResponseWrittenEquals("enterBookingDetails", context); assertTrue(getRequiredFlowAttribute("booking") instanceof Booking); EasyMock.verify(bookingService); } public void testEnterBookingDetails_Proceed() { setCurrentState("enterBookingDetails"); getFlowScope().put("booking", createTestBooking()); MockExternalContext context = new MockExternalContext(); context.setEventId("proceed"); resumeFlow(context); assertCurrentStateEquals("reviewBooking"); assertResponseWrittenEquals("reviewBooking", context); } public void testReviewBooking_Confirm() { setCurrentState("reviewBooking"); getFlowScope().put("booking", createTestBooking()); MockExternalContext context = new MockExternalContext(); context.setEventId("confirm"); resumeFlow(context); assertFlowExecutionEnded(); assertFlowExecutionOutcomeEquals("bookingConfirmed"); } private Booking createTestBooking() { Hotel hotel = new Hotel(); hotel.setId(1L); hotel.setName("Jameson Inn"); User user = new User("keith", "pass", "Keith Donald"); Booking booking = new Booking(hotel, user); return booking; } }
[ "ales.justin@gmail.com" ]
ales.justin@gmail.com
8c556b9aba957cbebd700faae426b81045c8b1e2
40665051fadf3fb75e5a8f655362126c1a2a3af6
/Hanmourang-hiped2/745afb95dbad217ab37fd03e1d7ae6c7400c7548/2/CliCommonOpts.java
c0cb372320c3b6139530cbfa30ad38bbaaa71632
[]
no_license
fermadeiral/StyleErrors
6f44379207e8490ba618365c54bdfef554fc4fde
d1a6149d9526eb757cf053bc971dbd92b2bfcdf1
refs/heads/master
2020-07-15T12:55:10.564494
2019-10-24T02:30:45
2019-10-24T02:30:45
205,546,543
2
0
null
null
null
null
UTF-8
Java
false
false
914
java
package hip.util; /** * Common combinations of CLI options. */ public class CliCommonOpts { public enum IOOptions implements Cli.ArgInfo { INPUT(true, true, "Input directory for the job."), OUTPUT(true, true, "Output directory for the job."), ; private final boolean hasArgument; private final boolean isRequired; private final String description; IOOptions(boolean hasArgument, boolean isRequired, String description) { this.hasArgument = hasArgument; this.isRequired = isRequired; this.description = description; } @Override public String getArgName() { return name().toLowerCase(); } @Override public String getArgDescription() { return description; } @Override public boolean isRequired() { return isRequired; } @Override public boolean hasArg() { return hasArgument; } } }
[ "fer.madeiral@gmail.com" ]
fer.madeiral@gmail.com
b54d280f5d9e2a8b1fb8e537370283a0bba213ed
17e8438486cb3e3073966ca2c14956d3ba9209ea
/dso/tags/2.4.8/code/base/dso-system-tests/tests.system/com/tctest/TransparencyExceptionTest.java
66e98b765f9ac3da550a673d032980037c545d84
[]
no_license
sirinath/Terracotta
fedfc2c4f0f06c990f94b8b6c3b9c93293334345
00a7662b9cf530dfdb43f2dd821fa559e998c892
refs/heads/master
2021-01-23T05:41:52.414211
2015-07-02T15:21:54
2015-07-02T15:21:54
38,613,711
1
0
null
null
null
null
UTF-8
Java
false
false
694
java
/* * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright notice. All rights reserved. */ package com.tctest; /** * Test what happens when an exception is thrown in a locked method. */ public class TransparencyExceptionTest extends TransparentTestBase implements TestConfigurator { private int clientCount = 2; protected Class getApplicationClass() { return TransparencyExceptionTestApp.class; } public void doSetUp(TransparentTestIface t) throws Exception { t.getTransparentAppConfig().setClientCount(clientCount).setApplicationInstancePerClientCount(1).setIntensity(1); t.initializeTestRunner(); } }
[ "hhuynh@7fc7bbf3-cf45-46d4-be06-341739edd864" ]
hhuynh@7fc7bbf3-cf45-46d4-be06-341739edd864
bd8bfad1464e6ff2f6d5c18e4c54381542ed3f84
a26d36fced1bf925a0550e67de2c9b03ff4de5b4
/academy6721/src/by/academy/lesson7/oop/HeavyBox.java
3bb55995eaa323ac44ef7c08b576fad8af355178
[]
no_license
irina-borisevich/academy6721
6ab02a05670c247951e0272bb7090f1a24c5b4c1
5a9dcfbf2fcac163a7f0028371d8754f4bda40df
refs/heads/master
2023-03-07T14:40:37.059136
2021-02-17T18:15:18
2021-02-17T18:15:18
null
0
0
null
null
null
null
UTF-8
Java
false
false
727
java
package by.academy.lesson7.oop; public class HeavyBox extends Box { int weight; public HeavyBox() { super(); } public HeavyBox(int width, int height, int depth, int weight) { this.width = width; this.height = height; this.depth = depth; this.weight = weight; } public void printSomething() { System.out.println("Something!"); } @Override public String toString() { StringBuilder builder = new StringBuilder(); builder.append("HeavyBox [weight="); builder.append(weight); builder.append(", width="); builder.append(width); builder.append(", height="); builder.append(height); builder.append(", depth="); builder.append(depth); builder.append("]"); return builder.toString(); } }
[ "dmitrysc@t480-SchepinD.playtika.local" ]
dmitrysc@t480-SchepinD.playtika.local
4f8d7b6c077635727fff5c87c569d5043242ae5e
1896b305a64899d8a89c260c8624519062cfe515
/src/main/java/ru/betterend/blocks/LacugroveSaplingBlock.java
7302e964d8e9e6d084cf0b466a2b107cfc293700
[ "MIT" ]
permissive
zorc/BetterEnd
66c2e67c86b82bcabbe32e00741cfddbad6058df
bea2bef853f3ef56b79d1d763f94ffb1f8b9cf05
refs/heads/master
2023-02-25T00:38:11.328300
2021-02-01T03:20:24
2021-02-01T03:20:24
null
0
0
null
null
null
null
UTF-8
Java
false
false
796
java
package ru.betterend.blocks; import net.minecraft.block.BlockState; import net.minecraft.util.math.BlockPos; import net.minecraft.world.WorldView; import net.minecraft.world.gen.feature.Feature; import ru.betterend.blocks.basis.FeatureSaplingBlock; import ru.betterend.registry.EndBlocks; import ru.betterend.registry.EndFeatures; public class LacugroveSaplingBlock extends FeatureSaplingBlock { public LacugroveSaplingBlock() { super(); } @Override protected Feature<?> getFeature() { return EndFeatures.LACUGROVE.getFeature(); } @Override public boolean canPlaceAt(BlockState state, WorldView world, BlockPos pos) { return world.getBlockState(pos.down()).isOf(EndBlocks.END_MOSS) || world.getBlockState(pos.down()).isOf(EndBlocks.ENDSTONE_DUST); } }
[ "paulevs@yandex.ru" ]
paulevs@yandex.ru
3c5136202d20fd3ceeb21323c29717758c00fa13
3085c34de2583d1fa2c4ec697138b6ea94c462cb
/app/src/main/java/project/astix/com/balajisosfa/CardArrayAdapter.java
0959893eb549de87997a32f7d5ba8eff85af8bad
[]
no_license
AstixIntelligenceManagementSystem/BalaJiSOSFAIndirect
93e20bbcde4f7caa6f6bd513612938834385bac9
7b63b622fa35e5e67797bb667ed269aa75e9d961
refs/heads/master
2020-03-26T14:22:44.231823
2018-08-16T12:36:29
2018-08-16T12:36:29
144,985,268
0
0
null
null
null
null
UTF-8
Java
false
false
3,650
java
package project.astix.com.balajisosfa; import java.util.ArrayList; import java.util.List; import android.app.Dialog; import android.content.Context; import android.view.LayoutInflater; import android.view.View; import android.view.View.OnClickListener; import android.view.ViewGroup; import android.widget.BaseAdapter; import android.widget.EditText; import android.widget.LinearLayout; import android.widget.ListView; import android.widget.TextView; public class CardArrayAdapter extends BaseAdapter{ private Context context; private LayoutInflater inflater; private List<String> listStore = null; private List<String> listOutletId; EditText txtTextSearch; String tagVal; private ArrayList<String> listStoreOrigin; private ArrayList<String> listStoreIDOrigin; ListView listViewOption; SearchListCommunicator communicator; Dialog listDialog; TextView textView; public CardArrayAdapter(Context context,List<String> listStore,List<String> listOutletId,EditText txtTextSearch,ListView listViewOption,String tagVal,Dialog listDialog,TextView textView) { this.context=context; inflater=LayoutInflater.from(context); this.listStore=listStore; this.listDialog=listDialog; this.textView=textView; this.txtTextSearch=txtTextSearch; this.listOutletId=listOutletId; this.listViewOption=listViewOption; this.tagVal=tagVal; this.listStoreOrigin=new ArrayList<String>(); this.listStoreIDOrigin=new ArrayList<String>(); listStoreIDOrigin.addAll(this.listOutletId); this.listStoreOrigin.addAll(this.listStore); } public class ViewHolder { TextView txt_store; LinearLayout ll_listChild; } @Override public int getCount() { // TODO Auto-generated method stub return listStore.size(); } @Override public Object getItem(int position) { // TODO Auto-generated method stub return listStore.get(position); } @Override public long getItemId(int position) { // TODO Auto-generated method stub return position; } @Override public View getView(int position, View convertView, ViewGroup parent) { final ViewHolder holder; if(convertView==null) { holder=new ViewHolder(); convertView=inflater.inflate(R.layout.custom_listview, null); holder.txt_store=(TextView) convertView.findViewById(R.id.txt_store); holder.ll_listChild=(LinearLayout) convertView.findViewById(R.id.ll_listChild); holder.txt_store.setTag(listOutletId.get(position)); communicator=(SearchListCommunicator) context; convertView.setTag(holder); } else { holder=(ViewHolder) convertView.getTag(); } holder.ll_listChild.setTag(listOutletId.get(position)); holder.txt_store.setText(listStore.get(position)); holder.ll_listChild.setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { communicator.selectedOption(v.getTag().toString(),holder.txt_store.getText().toString(),txtTextSearch,listViewOption, tagVal,listDialog,textView,listStoreIDOrigin); } }); return convertView; } public void filter(String charText) { charText=charText.toLowerCase(); listStore.clear(); listOutletId.clear(); if(charText.length()==0) { listStore.addAll(listStoreOrigin); listOutletId.addAll(listStoreIDOrigin); } else { int ownerPositin=0; for(String storeString: listStoreOrigin) { if(storeString.toLowerCase().contains(charText)) { listStore.add(storeString); listOutletId.add(listStoreIDOrigin.get(ownerPositin)); } ownerPositin++; } } notifyDataSetChanged(); } }
[ "astixset2@gmail.com" ]
astixset2@gmail.com
575a0d67f8bef964758e7da08935edd7646be0da
de7b67d4f8aa124f09fc133be5295a0c18d80171
/workspace_java-src/java-src-test/src/sun/io/ByteToCharCp875.java
3ccecccc9c0f5999beb17288bd41d1b2fcb53d94
[]
no_license
lin-lee/eclipse_workspace_test
adce936e4ae8df97f7f28965a6728540d63224c7
37507f78bc942afb11490c49942cdfc6ef3dfef8
refs/heads/master
2021-05-09T10:02:55.854906
2018-01-31T07:19:02
2018-01-31T07:19:02
119,460,523
0
1
null
null
null
null
UTF-8
Java
false
false
633
java
/* * %W% %E% * * Copyright (c) 2006, Oracle and/or its affiliates. All rights reserved. * ORACLE PROPRIETARY/CONFIDENTIAL. Use is subject to license terms. */ package sun.io; import sun.nio.cs.ext.IBM875; /** * A table to convert to Cp875 to Unicode * * @author ConverterGenerator tool * @version >= JDK1.1.6 */ public class ByteToCharCp875 extends ByteToCharSingleByte { private final static IBM875 nioCoder = new IBM875(); public String getCharacterEncoding() { return "Cp875"; } public ByteToCharCp875() { super.byteToCharTable = nioCoder.getDecoderSingleByteMappings(); } }
[ "lilin@lvmama.com" ]
lilin@lvmama.com
732841c91fa8b556f553bd312005d6eabba15428
0f77c5ec508d6e8b558f726980067d1058e350d7
/1_39_120042/com/ankamagames/wakfu/client/core/action/EffectAreaTriggeredAction.java
4fc4675f3cda3239ba0d33e8f8155cc6dde60bcb
[]
no_license
nightwolf93/Wakxy-Core-Decompiled
aa589ebb92197bf48e6576026648956f93b8bf7f
2967f8f8fba89018f63b36e3978fc62908aa4d4d
refs/heads/master
2016-09-05T11:07:45.145928
2014-12-30T16:21:30
2014-12-30T16:21:30
29,250,176
5
5
null
2015-01-14T15:17:02
2015-01-14T15:17:02
null
UTF-8
Java
false
false
2,634
java
package com.ankamagames.wakfu.client.core.action; import com.ankamagames.framework.script.*; import com.ankamagames.wakfu.client.core.script.fightLibrary.effectArea.*; import com.ankamagames.wakfu.common.game.effectArea.*; import com.ankamagames.baseImpl.common.clientAndServer.game.effectArea.*; import com.ankamagames.baseImpl.common.clientAndServer.game.effect.runningEffect.*; import com.ankamagames.framework.ai.targetfinder.*; import com.ankamagames.wakfu.client.core.effectArea.graphics.*; import com.ankamagames.wakfu.client.core.game.characterInfo.*; public class EffectAreaTriggeredAction extends AbstractFightScriptedAction { private final boolean m_apply; public EffectAreaTriggeredAction(final int uniqueId, final int actionType, final int actionId, final int fightId, final boolean apply, final long areaBaseId) { super(uniqueId, actionType, actionId, fightId); this.m_apply = apply; this.addJavaFunctionsLibrary(new EffectAreaFunctionsLibrary(this)); StaticEffectAreaManager.getInstance().getAreaFromId(areaBaseId); if (this.getEffectAreaManager() != null) { final BasicEffectArea area = StaticEffectAreaManager.getInstance().getAreaFromId(areaBaseId); if (area instanceof ScriptProvider) { this.setScriptFileId(((ScriptProvider)area).getScriptId()); } } } @Override public long onRun() { final CharacterInfo fighter = this.getFighterById(this.getTargetId()); if (this.getEffectAreaManager() != null) { final BasicEffectArea area = this.getEffectAreaManager().getActiveEffectAreaWithId(this.getInstigatorId()); if (area != null) { if (this.m_apply) { area.triggers((RunningEffect)null, fighter); long animationDuration = 0L; if (area instanceof GraphicalAreaProvider) { final GraphicalAreaProvider effectArea = (GraphicalAreaProvider)area; if (effectArea.hasAnimation("AnimAttaque")) { animationDuration = effectArea.getGraphicalArea().setAnimation("AnimAttaque"); } } final long scriptDuration = super.onRun(); return (scriptDuration > animationDuration) ? scriptDuration : animationDuration; } area.untriggers(fighter); } } this.fireActionFinishedEvent(); return -1L; } @Override protected void onActionFinished() { } }
[ "totomakers@hotmail.fr" ]
totomakers@hotmail.fr
ede55d32797adc6b4b4d3a86efff85744cb36c20
63da595a4e74145e86269e74e46c98ad1c1bcad3
/java/com/genscript/gsscm/epicorwebservice/stub/part/DuplicatePartResponse.java
69b7a2d609afa366a7b2c8c4ac4033b41492fa0d
[]
no_license
qcamei/scm
4f2cec86fedc3b8dc0f1cc1649e9ef3be687f726
0199673fbc21396e3077fbc79eeec1d2f9bd65f5
refs/heads/master
2020-04-27T19:38:19.460288
2012-09-18T07:06:04
2012-09-18T07:06:04
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,549
java
package com.genscript.gsscm.epicorwebservice.stub.part; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.XmlRootElement; import javax.xml.bind.annotation.XmlType; /** * <p>Java class for anonymous complex type. * * <p>The following schema fragment specifies the expected content contained within this class. * * <pre> * &lt;complexType> * &lt;complexContent> * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> * &lt;sequence> * &lt;element name="DuplicatePartResult" type="{http://epicor.com/schemas}PartDataSetType" minOccurs="0"/> * &lt;element name="callContextOut" type="{http://epicor.com/schemas}CallContextDataSetType" minOccurs="0"/> * &lt;/sequence> * &lt;/restriction> * &lt;/complexContent> * &lt;/complexType> * </pre> * * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "", propOrder = { "duplicatePartResult", "callContextOut" }) @XmlRootElement(name = "DuplicatePartResponse") public class DuplicatePartResponse { @XmlElement(name = "DuplicatePartResult", namespace = "http://epicor.com/webservices/") protected PartDataSetType duplicatePartResult; @XmlElement(namespace = "http://epicor.com/webservices/") protected CallContextDataSetType callContextOut; /** * Gets the value of the duplicatePartResult property. * * @return * possible object is * {@link PartDataSetType } * */ public PartDataSetType getDuplicatePartResult() { return duplicatePartResult; } /** * Sets the value of the duplicatePartResult property. * * @param value * allowed object is * {@link PartDataSetType } * */ public void setDuplicatePartResult(PartDataSetType value) { this.duplicatePartResult = value; } /** * Gets the value of the callContextOut property. * * @return * possible object is * {@link CallContextDataSetType } * */ public CallContextDataSetType getCallContextOut() { return callContextOut; } /** * Sets the value of the callContextOut property. * * @param value * allowed object is * {@link CallContextDataSetType } * */ public void setCallContextOut(CallContextDataSetType value) { this.callContextOut = value; } }
[ "253479240@qq.com" ]
253479240@qq.com
31b8f506d1585312c876a157be614b4b50a430fe
c885ef92397be9d54b87741f01557f61d3f794f3
/results/Codec-12/org.apache.commons.codec.binary.BaseNCodecInputStream/BBC-F0-opt-60/tests/20/org/apache/commons/codec/binary/BaseNCodecInputStream_ESTest_scaffolding.java
f3e25f4a0fb71a072fd6fef74b49986429ce37c6
[ "CC-BY-4.0", "MIT" ]
permissive
pderakhshanfar/EMSE-BBC-experiment
f60ac5f7664dd9a85f755a00a57ec12c7551e8c6
fea1a92c2e7ba7080b8529e2052259c9b697bbda
refs/heads/main
2022-11-25T00:39:58.983828
2022-04-12T16:04:26
2022-04-12T16:04:26
309,335,889
0
1
null
2021-11-05T11:18:43
2020-11-02T10:30:38
null
UTF-8
Java
false
false
4,016
java
/** * Scaffolding file used to store all the setups needed to run * tests automatically generated by EvoSuite * Fri Oct 22 02:05:54 GMT 2021 */ package org.apache.commons.codec.binary; import org.evosuite.runtime.annotation.EvoSuiteClassExclude; import org.junit.BeforeClass; import org.junit.Before; import org.junit.After; import org.evosuite.runtime.sandbox.Sandbox; import org.evosuite.runtime.sandbox.Sandbox.SandboxMode; @EvoSuiteClassExclude public class BaseNCodecInputStream_ESTest_scaffolding { @org.junit.Rule public org.evosuite.runtime.vnet.NonFunctionalRequirementRule nfr = new org.evosuite.runtime.vnet.NonFunctionalRequirementRule(); private org.evosuite.runtime.thread.ThreadStopper threadStopper = new org.evosuite.runtime.thread.ThreadStopper (org.evosuite.runtime.thread.KillSwitchHandler.getInstance(), 3000); @BeforeClass public static void initEvoSuiteFramework() { org.evosuite.runtime.RuntimeSettings.className = "org.apache.commons.codec.binary.BaseNCodecInputStream"; org.evosuite.runtime.GuiSupport.initialize(); org.evosuite.runtime.RuntimeSettings.maxNumberOfThreads = 100; org.evosuite.runtime.RuntimeSettings.maxNumberOfIterationsPerLoop = 10000; org.evosuite.runtime.RuntimeSettings.mockSystemIn = true; org.evosuite.runtime.RuntimeSettings.sandboxMode = org.evosuite.runtime.sandbox.Sandbox.SandboxMode.RECOMMENDED; org.evosuite.runtime.sandbox.Sandbox.initializeSecurityManagerForSUT(); org.evosuite.runtime.classhandling.JDKClassResetter.init(); setSystemProperties(); initializeClasses(); org.evosuite.runtime.Runtime.getInstance().resetRuntime(); } @Before public void initTestCase(){ threadStopper.storeCurrentThreads(); threadStopper.startRecordingTime(); org.evosuite.runtime.jvm.ShutdownHookHandler.getInstance().initHandler(); org.evosuite.runtime.sandbox.Sandbox.goingToExecuteSUTCode(); org.evosuite.runtime.GuiSupport.setHeadless(); org.evosuite.runtime.Runtime.getInstance().resetRuntime(); org.evosuite.runtime.agent.InstrumentingAgent.activate(); } @After public void doneWithTestCase(){ threadStopper.killAndJoinClientThreads(); org.evosuite.runtime.jvm.ShutdownHookHandler.getInstance().safeExecuteAddedHooks(); org.evosuite.runtime.classhandling.JDKClassResetter.reset(); resetClasses(); org.evosuite.runtime.sandbox.Sandbox.doneWithExecutingSUTCode(); org.evosuite.runtime.agent.InstrumentingAgent.deactivate(); org.evosuite.runtime.GuiSupport.restoreHeadlessMode(); } public static void setSystemProperties() { /*No java.lang.System property to set*/ } private static void initializeClasses() { org.evosuite.runtime.classhandling.ClassStateSupport.initializeClasses(BaseNCodecInputStream_ESTest_scaffolding.class.getClassLoader() , "org.apache.commons.codec.binary.BaseNCodec", "org.apache.commons.codec.Encoder", "org.apache.commons.codec.binary.BaseNCodecInputStream", "org.apache.commons.codec.BinaryEncoder", "org.apache.commons.codec.EncoderException", "org.apache.commons.codec.DecoderException", "org.apache.commons.codec.Decoder", "org.apache.commons.codec.BinaryDecoder", "org.apache.commons.codec.binary.Base64", "org.apache.commons.codec.binary.Base32" ); } private static void resetClasses() { org.evosuite.runtime.classhandling.ClassResetter.getInstance().setClassLoader(BaseNCodecInputStream_ESTest_scaffolding.class.getClassLoader()); org.evosuite.runtime.classhandling.ClassStateSupport.resetClasses( "org.apache.commons.codec.binary.BaseNCodecInputStream", "org.apache.commons.codec.binary.BaseNCodec", "org.apache.commons.codec.binary.Base64", "org.apache.commons.codec.binary.Base32", "org.apache.commons.codec.binary.StringUtils", "org.apache.commons.codec.EncoderException", "org.apache.commons.codec.DecoderException" ); } }
[ "pderakhshanfar@serg2.ewi.tudelft.nl" ]
pderakhshanfar@serg2.ewi.tudelft.nl
a89229f3dc8bce8b057f66856c6aaf2a950cc785
2178615fffa560ffc173f99ac6981d77c6ae1ecb
/src/main/java/dao/Person.java
6c0cf13fafd0a80020306f893965ec3e9c3f8a13
[]
no_license
li5220008/my-webapp
c245e7cc624e648839769a13419ca9156d671803
c0f895e80452b78434c652e117c333c76b99d430
refs/heads/master
2021-01-16T00:12:09.339921
2014-05-01T01:24:18
2014-05-01T01:24:18
null
0
0
null
null
null
null
UTF-8
Java
false
false
908
java
package dao; import java.util.Date; /** * Desc: * User: weiguili(li5220008@gmail.com) * Date: 14-2-26 * Time: 上午8:40 */ public class Person { private String name = "aa"; private int age; public Person(String name) { this.name = name; } public Person() { } private Date birthday; public Address getAddress() { return address; } public void setAddress(Address address) { this.address = address; } private Address address; public Date getBirthday() { return birthday; } public void setBirthday(Date birthday) { this.birthday = birthday; } public String getName() { return name; } public void setName(String name) { this.name = name; } public int getAge() { return age; } public void setAge(int age) { this.age = age; } }
[ "li5220008@163.com" ]
li5220008@163.com
38da44a0c008a472377e459d2de304ce1cbab1d0
d9493c1a388fb7d505db859a46ab16f09b9456a4
/java/OpenDental/Bridges/MiPACS.java
e179fe372168a9fa2260358c9470fc76b135726a
[]
no_license
leelingco/opendental
f29c51a76bf455496bbc307ab0a5cd588792e7a0
aaf621b2b5b64e1d8d0f3318050d143abeefe594
refs/heads/master
2021-01-21T00:25:30.774258
2016-02-16T04:23:27
2016-02-16T04:23:27
51,807,222
0
0
null
2016-02-16T04:12:27
2016-02-16T04:12:27
null
UTF-8
Java
false
false
2,224
java
// // Translated by CS2J (http://www.cs2j.com): 2/15/2016 7:58:28 PM // package OpenDental.Bridges; import CS2JNet.System.StringSupport; import OpenDentBusiness.Patient; import OpenDentBusiness.PatientGender; import OpenDentBusiness.Program; import OpenDentBusiness.ProgramProperties; import OpenDentBusiness.Programs; public class MiPACS { /** * Launches the program using a combination of command line characters and the patient.Cur data./// */ /*The command line integration works as follows: C:\Program Files\MiDentView\Cmdlink.exe /ID=12345 /FN=JOHN /LN=DOE /BD=10/01/1985 /Sex=M Parameters:'/ID=' for ID number, '/FN=' for Firstname, '/LN=' for Lastname, '/BD=' for Birthdate, '/Sex=' for Sex. Example of a name with special characters (in this case, spaces): C:\Program Files\MiDentView\Cmdlink.exe /ID=12345 /FN=Oscar /LN=De La Hoya /BD=10/01/1985 /Sex=M */ public static void sendData(Program ProgramCur, Patient pat) throws Exception { String path = Programs.getProgramPath(ProgramCur); if (pat == null) { try { Process.Start(path); } catch (Exception __dummyCatchVar0) { //should start MiPACS without bringing up a pt. MessageBox.Show(path + " is not available."); } } String gender = (pat.Gender == PatientGender.Female) ? "F" : "M"; //M for Male, F for Female, M for Unknown. String info = ""; if (StringSupport.equals(ProgramProperties.getPropVal(ProgramCur.ProgramNum,"Enter 0 to use PatientNum, or 1 to use ChartNum"), "0")) { info += "/ID=" + pat.PatNum.ToString(); } else { info += "/ID=" + pat.ChartNumber; } //special characters claimed to be ok info += " /FN=" + pat.FName + " /LN=" + pat.LName + " /BD=" + pat.Birthdate.ToShortDateString() + " /Sex=" + gender; try { Process.Start(path, info); } catch (Exception __dummyCatchVar1) { MessageBox.Show(path + " is not available."); } } }
[ "leelingco@yahoo.com" ]
leelingco@yahoo.com
759896e1bfeca3785456c8a5f2f3c93bb3ed30b6
6ac12da7bc81c9fbf8bbf844553bc46bd2746ba9
/ds4p-receiver/ds4p-admin-test-harness/src/main/java/utsapi2_0/UtsMetathesaurusContent/ResolveVSDetailedExplicitListDefinitionEntryResponse.java
d877fb3ae1a1e7b6e757709944902dfee6e06b76
[]
no_license
wanghaisheng/ds4p-pilot-public
b8fd90ee5e196e0e055e250af0e3c547cfa84eaa
235cc22266868917d88332fb32d03baded2dd684
refs/heads/master
2020-04-08T03:19:53.614880
2012-12-08T10:02:38
2012-12-08T10:02:38
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,340
java
/** * This software is being provided per FARS 52.227-14 Rights in Data - General. * Any redistribution or request for copyright requires written consent by the * Department of Veterans Affairs. */ package UtsMetathesaurusContent; import java.util.ArrayList; import java.util.List; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.XmlType; /** * <p>Java class for resolveVSDetailedExplicitListDefinitionEntryResponse complex type. * * <p>The following schema fragment specifies the expected content contained within this class. * * <pre> * &lt;complexType name="resolveVSDetailedExplicitListDefinitionEntryResponse"> * &lt;complexContent> * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> * &lt;sequence> * &lt;element name="return" type="{http://webservice.uts.umls.nlm.nih.gov/}sourceAtomClusterDTO" maxOccurs="unbounded" minOccurs="0"/> * &lt;/sequence> * &lt;/restriction> * &lt;/complexContent> * &lt;/complexType> * </pre> * * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "resolveVSDetailedExplicitListDefinitionEntryResponse", propOrder = { "_return" }) public class ResolveVSDetailedExplicitListDefinitionEntryResponse { @XmlElement(name = "return") protected List<SourceAtomClusterDTO> _return; /** * Gets the value of the return property. * * <p> * This accessor method returns a reference to the live list, * not a snapshot. Therefore any modification you make to the * returned list will be present inside the JAXB object. * This is why there is not a <CODE>set</CODE> method for the return property. * * <p> * For example, to add a new item, do as follows: * <pre> * getReturn().add(newItem); * </pre> * * * <p> * Objects of the following type(s) are allowed in the list * {@link SourceAtomClusterDTO } * * */ public List<SourceAtomClusterDTO> getReturn() { if (_return == null) { _return = new ArrayList<SourceAtomClusterDTO>(); } return this._return; } }
[ "Duane DeCouteau@Socratic5" ]
Duane DeCouteau@Socratic5
b138c164bce3ccd75d83e30ac3761e5fe8243596
86e1dcb05ba98f76c44461bb50f4b2e1b257678f
/Spring/prospring4/src/main/java/ua/vtkachenko/prospring4/ch5_aop/HelloWorldAOPExample.java
fed5a77010d04c04f88a1fffa9f4c147f1e7c6d1
[]
no_license
McLoy/Learning
9c7e56d23041d123e71d32a9f205c8ab4fa5b5dd
845551335ac3a2d2f2e5987dc854b72589e1962d
refs/heads/master
2020-06-11T15:16:27.920917
2017-11-19T13:30:10
2017-11-19T13:30:10
75,642,459
0
0
null
null
null
null
UTF-8
Java
false
false
519
java
package ua.vtkachenko.prospring4.ch5_aop; import org.springframework.aop.framework.ProxyFactory; public class HelloWorldAOPExample { public static void main(String[] args) { MessageWriter target = new MessageWriter(); ProxyFactory pf = new ProxyFactory(); pf.addAdvice(new MessageDecorator()); pf.setTarget(target); MessageWriter proxy = (MessageWriter) pf.getProxy(); target.writeMessage(); System.out.println(""); proxy.writeMessage(); } }
[ "tkachenko.vlad@hotmail.com" ]
tkachenko.vlad@hotmail.com
f163365b95b0812d90dbc16c9675cb5178dff55a
9a064f03b5d437ffbacf74ac3018626fbd1b1b0b
/src/main/java/com/learn/java/leetcode/lc1394/Main.java
70c164f971199b9a8e2a6695e41540883556586f
[ "Apache-2.0" ]
permissive
philippzhang/leetcodeLearnJava
c2437785010b7bcf50d62eeab33853a744fa1e40
ce39776b8278ce614f23f61faf28ca22bfa525e7
refs/heads/master
2022-12-21T21:43:46.677833
2021-07-12T08:13:37
2021-07-12T08:13:37
183,338,794
2
0
Apache-2.0
2022-12-16T03:55:00
2019-04-25T02:12:20
Java
UTF-8
Java
false
false
247
java
package com.learn.java.leetcode.lc1394; import com.learn.java.leetcode.base.CallBack; import com.learn.java.leetcode.base.Utilitys; public class Main extends CallBack { public static void main(String[] args) { Utilitys.test(Main.class); } }
[ "philipp_zhang@163.com" ]
philipp_zhang@163.com
27dc9908728212494ff7be70b5d5bf15ab949a21
c3101515ddde8a6e6ddc4294a4739256d1600df0
/GeneralApp__2.20_1.0(1)_source_from_JADX/sources/p008cz/msebera/android/httpclient/impl/client/CloseableHttpResponseProxy.java
5266ac3b600fe4cb718efcac7beaab632d9a8096
[]
no_license
Aelshazly/Carty
b56fdb1be58a6d12f26d51b46f435ea4a73c8168
d13f3a4ad80e8a7d0ed1c6a5720efb4d1ca721ee
refs/heads/master
2022-11-14T23:29:53.547694
2020-07-08T19:23:39
2020-07-08T19:23:39
278,175,183
0
0
null
null
null
null
UTF-8
Java
false
false
2,257
java
package p008cz.msebera.android.httpclient.impl.client; import java.io.IOException; import java.lang.reflect.Constructor; import java.lang.reflect.InvocationHandler; import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; import java.lang.reflect.Proxy; import p008cz.msebera.android.httpclient.HttpResponse; import p008cz.msebera.android.httpclient.client.methods.CloseableHttpResponse; import p008cz.msebera.android.httpclient.util.EntityUtils; /* renamed from: cz.msebera.android.httpclient.impl.client.CloseableHttpResponseProxy */ class CloseableHttpResponseProxy implements InvocationHandler { private static final Constructor<?> CONSTRUCTOR; private final HttpResponse original; static { try { CONSTRUCTOR = Proxy.getProxyClass(CloseableHttpResponseProxy.class.getClassLoader(), new Class[]{CloseableHttpResponse.class}).getConstructor(new Class[]{InvocationHandler.class}); } catch (NoSuchMethodException ex) { throw new IllegalStateException(ex); } } CloseableHttpResponseProxy(HttpResponse original2) { this.original = original2; } public void close() throws IOException { EntityUtils.consume(this.original.getEntity()); } public Object invoke(Object proxy, Method method, Object[] args) throws Throwable { if (method.getName().equals("close")) { close(); return null; } try { return method.invoke(this.original, args); } catch (InvocationTargetException ex) { Throwable cause = ex.getCause(); if (cause != null) { throw cause; } throw ex; } } public static CloseableHttpResponse newProxy(HttpResponse original2) { try { return (CloseableHttpResponse) CONSTRUCTOR.newInstance(new Object[]{new CloseableHttpResponseProxy(original2)}); } catch (InstantiationException ex) { throw new IllegalStateException(ex); } catch (InvocationTargetException ex2) { throw new IllegalStateException(ex2); } catch (IllegalAccessException ex3) { throw new IllegalStateException(ex3); } } }
[ "aelshazly@engineer.com" ]
aelshazly@engineer.com
8b1487dabef82f597028b1006e2219d95b7c0137
39fdbaa47bc18dd76ccc40bccf18a21e3543ab9f
/modules/activiti-engine/src/main/java/org/activiti/engine/management/TablePage.java
c660e2c3835d0d087b2deaea5441133b140bd50a
[]
no_license
jpjyxy/Activiti-activiti-5.16.4
b022494b8f40b817a54bb1cc9c7f6fa41dadb353
ff22517464d8f9d5cfb09551ad6c6cbecff93f69
refs/heads/master
2022-12-24T14:51:08.868694
2017-04-14T14:05:00
2017-04-14T14:05:00
191,682,921
0
0
null
2022-12-16T04:24:04
2019-06-13T03:15:47
Java
UTF-8
Java
false
false
2,635
java
/* Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.activiti.engine.management; import java.util.List; import java.util.Map; /** * Data structure used for retrieving database table content. * * @author Tom Baeyens * @author Joram Barrez */ public class TablePage { protected String tableName; /** * The total number of rows in the table. */ protected long total = -1; /** * Identifies the index of the first result stored in this TablePage. For example in a paginated database table, * this value identifies the record number of the result on the first row. */ protected long firstResult; /** * The actual content of the database table, stored as a list of mappings of the form {colum name, value}. * * This means that every map object in the list corresponds with one row in the database table. */ protected List<Map<String, Object>> rowData; public TablePage() { } public String getTableName() { return tableName; } public void setTableName(String tableName) { this.tableName = tableName; } /** * @return the start index of this page (ie the index of the first element in the page) */ public long getFirstResult() { return firstResult; } public void setFirstResult(long firstResult) { this.firstResult = firstResult; } public void setRows(List<Map<String, Object>> rowData) { this.rowData = rowData; } /** * @return the actual table content. */ public List<Map<String, Object>> getRows() { return rowData; } public void setTotal(long total) { this.total = total; } /** * @return the total rowcount of the table from which this page is only a subset. */ public long getTotal() { return total; } /** * @return the actual number of rows in this page. */ public long getSize() { return rowData.size(); } }
[ "905280842@qq.com" ]
905280842@qq.com
132cdd7f095ace4a7d0833379e8059384513eaa1
0caffe05aeee72bc681351c7ba843bb4b2a4cd42
/dcma-gwt/dcma-gwt-folder-manager/src/main/java/com/ephesoft/dcma/gwt/foldermanager/client/event/RemoveAttachmentEvent.java
f66495538c09fbefc32d16c17310b8bbcf5bd8ce
[]
no_license
plutext/ephesoft
d201a35c6096f9f3b67df00727ae262976e61c44
d84bf4fa23c9ed711ebf19f8d787a93a71d97274
refs/heads/master
2023-06-23T10:15:34.223961
2013-02-13T18:35:49
2013-02-13T18:35:49
43,588,917
4
1
null
null
null
null
UTF-8
Java
false
false
2,767
java
/********************************************************************************* * Ephesoft is a Intelligent Document Capture and Mailroom Automation program * developed by Ephesoft, Inc. Copyright (C) 2010-2012 Ephesoft Inc. * * This program is free software; you can redistribute it and/or modify it under * the terms of the GNU Affero General Public License version 3 as published by the * Free Software Foundation with the addition of the following permission added * to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK * IN WHICH THE COPYRIGHT IS OWNED BY EPHESOFT, EPHESOFT DISCLAIMS THE WARRANTY * OF NON INFRINGEMENT OF THIRD PARTY RIGHTS. * * 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 or write to the Free * Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA * 02110-1301 USA. * * You can contact Ephesoft, Inc. headquarters at 111 Academy Way, * Irvine, CA 92617, USA. or at email address info@ephesoft.com. * * The interactive user interfaces in modified source and object code versions * of this program must display Appropriate Legal Notices, as required under * Section 5 of the GNU Affero General Public License version 3. * * In accordance with Section 7(b) of the GNU Affero General Public License version 3, * these Appropriate Legal Notices must retain the display of the "Ephesoft" logo. * If the display of the logo is not reasonably feasible for * technical reasons, the Appropriate Legal Notices must display the words * "Powered by Ephesoft". ********************************************************************************/ package com.ephesoft.dcma.gwt.foldermanager.client.event; import com.google.gwt.event.shared.GwtEvent; public class RemoveAttachmentEvent extends GwtEvent<RemoveAttachmentEventHandler> { public static Type<RemoveAttachmentEventHandler> type = new Type<RemoveAttachmentEventHandler>(); private int fileIndex; public RemoveAttachmentEvent(int fileIndex) { super(); this.fileIndex = fileIndex; } @Override protected void dispatch(RemoveAttachmentEventHandler handler) { handler.onRemoveAttachment(this); } @Override public com.google.gwt.event.shared.GwtEvent.Type<RemoveAttachmentEventHandler> getAssociatedType() { return type; } public void setFileIndex(int fileIndex) { this.fileIndex = fileIndex; } public int getFileIndex() { return fileIndex; } }
[ "enterprise.support@ephesoft.com" ]
enterprise.support@ephesoft.com
026abe3579a136aaec0c00e5248c1dda49050da1
8f6cc4726e73e8d7a44ed91a454fe4a0f17b06a7
/android/app/src/main/java/com/slime_friends_28703/MainApplication.java
7e4f372fc58b8b635fed805a3152b992efe07753
[]
no_license
crowdbotics-apps/slime-friends-28703
8da2b5f8bed3ff7a593d992418585d856ea19e2d
f23909f5795819d1007fe38922868b109c6930b3
refs/heads/master
2023-06-13T23:34:58.586607
2021-07-11T00:44:34
2021-07-11T00:44:34
384,830,778
0
0
null
null
null
null
UTF-8
Java
false
false
2,621
java
package com.slime_friends_28703; import android.app.Application; import android.content.Context; import com.facebook.react.PackageList; import com.facebook.react.ReactApplication; import com.facebook.react.ReactInstanceManager; import com.facebook.react.ReactNativeHost; import com.facebook.react.ReactPackage; import com.facebook.soloader.SoLoader; import java.lang.reflect.InvocationTargetException; import java.util.List; public class MainApplication extends Application implements ReactApplication { private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) { @Override public boolean getUseDeveloperSupport() { return BuildConfig.DEBUG; } @Override protected List<ReactPackage> getPackages() { @SuppressWarnings("UnnecessaryLocalVariable") List<ReactPackage> packages = new PackageList(this).getPackages(); // Packages that cannot be autolinked yet can be added manually here, for example: // packages.add(new MyReactNativePackage()); return packages; } @Override protected String getJSMainModuleName() { return "index"; } }; @Override public ReactNativeHost getReactNativeHost() { return mReactNativeHost; } @Override public void onCreate() { super.onCreate(); SoLoader.init(this, /* native exopackage */ false); initializeFlipper(this, getReactNativeHost().getReactInstanceManager()); } /** * Loads Flipper in React Native templates. Call this in the onCreate method with something like * initializeFlipper(this, getReactNativeHost().getReactInstanceManager()); * * @param context * @param reactInstanceManager */ private static void initializeFlipper( Context context, ReactInstanceManager reactInstanceManager) { if (BuildConfig.DEBUG) { try { /* We use reflection here to pick up the class that initializes Flipper, since Flipper library is not available in release mode */ Class<?> aClass = Class.forName("com.slime_friends_28703.ReactNativeFlipper"); aClass .getMethod("initializeFlipper", Context.class, ReactInstanceManager.class) .invoke(null, context, reactInstanceManager); } catch (ClassNotFoundException e) { e.printStackTrace(); } catch (NoSuchMethodException e) { e.printStackTrace(); } catch (IllegalAccessException e) { e.printStackTrace(); } catch (InvocationTargetException e) { e.printStackTrace(); } } } }
[ "team@crowdbotics.com" ]
team@crowdbotics.com
be97e21e51ec927a98060f1201ba5c95a133f482
9fcf05729b131e40eedb8bbc1b2e04dbf6f02c98
/Java/Examples/rosenact(0.5)/src/org/test/act/actor/Enemy1.java
d0b37d0f0cdc471788cbb7bb4e35e7ab68b34c7e
[ "Apache-2.0" ]
permissive
choiyongwoo/LGame
68661774ca4c913e8fae8378a2f291939430fa37
f007cee4c017702d5dd3d7966cb99b3c69bec616
refs/heads/master
2020-05-29T13:39:00.447566
2019-05-28T01:30:53
2019-05-28T01:30:53
189,168,503
1
0
null
2019-05-29T06:59:15
2019-05-29T06:59:14
null
UTF-8
Java
false
false
2,112
java
/** * Copyright 2008 - 2012 * * 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. * * @project loon * @author cping * @email:javachenpeng@yahoo.com * @version 0.3.3 */ package org.test.act.actor; import loon.action.sprite.SpriteBatch.SpriteEffects; import loon.canvas.LColor; import loon.utils.timer.GameTime; public class Enemy1 extends Enemy { private final int FLY_MAX = 100; private int flyCount = 100; protected float vx = 3f; protected final float VX = 3f; public Enemy1() { super.loadSe( "assets/enemyDE", 0.5f); super.Load( "assets/e1", 3, 2f, false); super.setAnimation(new int[] { 0, 0, 1, 2, 2, 1 }); this.Scale.x = 0.8f; this.Scale.y = 0.8f; super.actWidth = 207.2f; super.actHeight = 193.6f; this.bounds.width = (int) super.getWidth(); this.bounds.height = (int) super.getHeight(); } protected void specificUpdate(GameTime gameTime) { this.flyCount++; super.de.update(gameTime); if (super.effects == SpriteEffects.None) { this.vx = -this.VX; if (this.flyCount > this.FLY_MAX) { this.flyCount = 0; super.effects = SpriteEffects.FlipHorizontally; } } else { this.vx = this.VX; if (this.flyCount > this.FLY_MAX) { this.flyCount = 0; super.effects = SpriteEffects.None; } } this.Pos.x += this.vx; super.color = LColor.newWhite(); } }
[ "longwind2012@hotmail.com" ]
longwind2012@hotmail.com
a4999b75276e781786f063efbc04cc9c8151e0e5
5eabe937238446eb604e36e67cb7946a304880f3
/library/src/main/java/hello/leavesc/common/CommonRecyclerViewHolder.java
5904a5be9a363b5ae37105a5ecb8e97ca1259ffa
[]
no_license
leavesCZY/BaseRecyclerView
b74094ede583983e390461e65e8a9fda98709fb9
38272e93529d159f22012bf1e33eb3234204730b
refs/heads/master
2022-01-21T23:28:17.638108
2018-12-30T07:26:54
2018-12-30T07:26:54
null
0
0
null
null
null
null
UTF-8
Java
false
false
4,684
java
package hello.leavesc.common; import android.graphics.Bitmap; import android.support.annotation.DrawableRes; import android.support.annotation.IdRes; import android.support.v7.widget.RecyclerView; import android.util.SparseArray; import android.view.View; import android.widget.AbsListView; import android.widget.ImageView; import android.widget.TextView; /** * 作者:叶应是叶 * 时间:2017/11/27 23:15 * 说明:通用RecyclerView ViewHolder */ public class CommonRecyclerViewHolder extends RecyclerView.ViewHolder { public interface OnClickListener { void onClick(int position); } public interface OnLongClickListener { void onLongClick(int position); } private OnClickListener clickListener; private OnLongClickListener longClickListener; //用来存放View以减少findViewById的次数 private SparseArray<View> viewSparseArray; CommonRecyclerViewHolder(View view) { super(view); viewSparseArray = new SparseArray<>(); view.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { if (clickListener != null) { clickListener.onClick(getAdapterPosition()); } } }); view.setOnLongClickListener(new View.OnLongClickListener() { @Override public boolean onLongClick(View v) { if (longClickListener != null) { longClickListener.onLongClick(getAdapterPosition()); } return true; } }); } void setClickListener(OnClickListener clickListener) { this.clickListener = clickListener; } void setLongClickListener(OnLongClickListener longClickListener) { this.longClickListener = longClickListener; } /** * 根据 ID 来获取 View * * @param viewId viewID * @param <T> 泛型 * @return 将结果强转为 View 或 View 的子类型 */ public <T extends View> T getView(@IdRes int viewId) { // 先从缓存中找,找到的话则直接返回 // 如果找不到则findViewById,再把结果存入缓存中 View view = viewSparseArray.get(viewId); if (view == null) { view = itemView.findViewById(viewId); if (view != null) { viewSparseArray.put(viewId, view); } } return (T) view; } public CommonRecyclerViewHolder setText(@IdRes int viewId, CharSequence text) { TextView textView = getView(viewId); if (textView != null) { textView.setText(text); } return this; } public CommonRecyclerViewHolder setImageResource(@IdRes int viewId, @DrawableRes int resourceId) { ImageView imageView = getView(viewId); if (imageView != null) { imageView.setImageResource(resourceId); } return this; } public CommonRecyclerViewHolder setImageResource(@IdRes int viewId, Bitmap bitmap) { ImageView imageView = getView(viewId); if (imageView != null) { imageView.setImageBitmap(bitmap); } return this; } public CommonRecyclerViewHolder setViewVisibility(@IdRes int viewId, int visibility) { View view = getView(viewId); if (view != null) { view.setVisibility(visibility); } return this; } public CommonRecyclerViewHolder setViewPadding(@IdRes int viewId, int left, int top, int right, int bottom) { View view = getView(viewId); if (view != null) { view.setPadding(left, top, right, bottom); } return this; } public CommonRecyclerViewHolder setImageViewLayoutParams(@IdRes int viewId, int width, int height) { ImageView imageView = getView(viewId); if (imageView != null) { AbsListView.LayoutParams params = new AbsListView.LayoutParams(width, height); imageView.setLayoutParams(params); } return this; } public CommonRecyclerViewHolder setOnClickListener(@IdRes int viewId, View.OnClickListener clickListener) { View view = getView(viewId); if (view != null) { view.setOnClickListener(clickListener); } return this; } public CommonRecyclerViewHolder setOnLongClickListener(@IdRes int viewId, View.OnLongClickListener clickListener) { View view = getView(viewId); if (view != null) { view.setOnLongClickListener(clickListener); } return this; } }
[ "1990724437@qq.com" ]
1990724437@qq.com
6fcc9cee38065444ae907cdf247e8e6d4d1f73ee
265fba22622174c64a96c5a32932d8511539321f
/example/src/main/java/net/cattaka/android/snippets/example/data/ColorItem.java
34141634fd809020955d15af74cdcc5336308d18
[ "CC0-1.0", "Apache-2.0" ]
permissive
alexjarabek/AndroidSnippets
c56ae59fb5dfadc89ac6fc790ac2114c16e64adf
73708ad75239b26feaa24016a86abf083c0fbea5
refs/heads/master
2020-07-06T00:52:23.775406
2019-07-03T00:58:32
2019-07-03T00:58:32
null
0
0
null
null
null
null
UTF-8
Java
false
false
514
java
package net.cattaka.android.snippets.example.data; import java.util.Locale; /** * Created by takao on 2016/12/12. */ public class ColorItem { private int color; public ColorItem() { } public ColorItem(int color) { this.color = color; } public int getColor() { return color; } public void setColor(int color) { this.color = color; } @Override public String toString() { return String.format(Locale.ROOT, "%08X", color); } }
[ "cattaka@mail.cattaka.net" ]
cattaka@mail.cattaka.net
c094298b1dadf9e74945d378418a317f22bcd5f2
be73270af6be0a811bca4f1710dc6a038e4a8fd2
/crash-reproduction-moho/results/XCOMMONS-1057-8-11-FEMO-WeightedSum:TestLen:CallDiversity/org/xwiki/job/AbstractJob_ESTest.java
2fa973db7ac7cff450fbcb2311489b251e9d7ce8
[]
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
542
java
/* * This file was automatically generated by EvoSuite * Sat Apr 04 12:06:38 UTC 2020 */ package org.xwiki.job; 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 AbstractJob_ESTest extends AbstractJob_ESTest_scaffolding { @Test public void notGeneratedAnyTest() { // EvoSuite did not generate any tests } }
[ "pouria.derakhshanfar@gmail.com" ]
pouria.derakhshanfar@gmail.com
b244dfd490cf8128d041708bcbb0e6aa6612c81e
39d9a4ca7889bbb36ab12d5eff6904313ab43f94
/ex5_4.java
d4c2012f982754f4edd6746b716c65a7620d2052
[]
no_license
lotova/ktp_practice_task-5-6
cca8d224dd371319bc3eaba32ca970f54e457af0
509cbe8eeca7aa878198201b41d3e6652cbc48c3
refs/heads/master
2022-09-07T10:16:28.564110
2020-06-02T01:23:53
2020-06-02T01:23:53
268,670,290
0
0
null
null
null
null
WINDOWS-1251
Java
false
false
1,035
java
package ktp_task5; import java.util.ArrayList; import java.util.Scanner; public class ex5_4 { /**возвращает произведение цифр числа */ static int Multy_fig(int x) { int res = 1; while (x!=0) { res = res * (x%10); x = x/10; } return res; } /** принимает числа и возвращает произведение цифр, пока ответ * не станет длинной в одну цифру */ static int sumDigProd (ArrayList<Integer> numbers) { int x = 0; for(int i = 0; i< numbers.size(); i++) { x = x + numbers.get(i); } while (x>9) { x = Multy_fig(x); } return x; } public static void main(String[] args) { Scanner in = new Scanner(System.in); System.out.println("enter numbers"); String str = in.nextLine(); in.close(); String [] sym = str.split(" "); ArrayList<Integer> nums = new ArrayList<Integer>(); for (int i = 0; i< sym.length; i++) { nums.add(Integer.parseInt(sym[i])); } System.out.println(sumDigProd(nums)); } }
[ "johndoe@example.com" ]
johndoe@example.com
f5fd57d163d89af244ee1b37bf6c498ee2a89062
c351ea4d93ae60a8e5bbfe5756b7c6904eca6790
/taotao-manager/src/main/java/com/zhao/common/LayuiTableResult.java
becfbfd60b9982e718b390bd21f9d696421273ce
[]
no_license
zhao123-bit/taotao0107
36f2ba663362867bf76b6bb7e8be75f479c5fc7b
adde5994960457b5407fe3fc27558c2ba1ffc747
refs/heads/master
2022-12-17T20:12:34.824254
2020-01-07T07:17:07
2020-01-07T07:17:07
232,264,100
0
0
null
2022-12-16T07:16:27
2020-01-07T07:05:03
Java
UTF-8
Java
false
false
828
java
package com.zhao.common; import java.io.Serializable; import java.util.List; public class LayuiTableResult implements Serializable{ private int code; private String msg; private int count; private List<?> data;//就是就是分类的对象 集合 名字叫做data public int getCode() { return code; } public void setCode(int code) { this.code = code; } public String getMsg() { return msg; } public void setMsg(String msg) { this.msg = msg; } public int getCount() { return count; } public void setCount(int count) { this.count = count; } public List<?> getData() { return data; } public void setData(List<?> data) { this.data = data; } @Override public String toString() { return "LayuiTableResult [code=" + code + ", msg=" + msg + ", count=" + count + ", data=" + data + "]"; } }
[ "you@example.com" ]
you@example.com
0d1266137532a1fd3483246f567fd505a25cbaf6
c4623aa95fb8cdd0ee1bc68962711c33af44604e
/src/com/google/android/gms/internal/ju$a$a.java
626f84bf617d20e4ffba7e420be5931899029028
[]
no_license
reverseengineeringer/com.yelp.android
48f7f2c830a3a1714112649a6a0a3110f7bdc2b1
b0ac8d4f6cd5fc5543f0d8de399b6d7b3a2184c8
refs/heads/master
2021-01-19T02:07:25.997811
2016-07-19T16:37:24
2016-07-19T16:37:24
38,555,675
1
0
null
null
null
null
UTF-8
Java
false
false
2,871
java
package com.google.android.gms.internal; import android.os.IBinder; class ju$a$a implements ju { private IBinder le; ju$a$a(IBinder paramIBinder) { le = paramIBinder; } /* Error */ public com.google.android.gms.dynamic.d a(com.google.android.gms.dynamic.d paramd, int paramInt1, int paramInt2) { // Byte code: // 0: invokestatic 24 android/os/Parcel:obtain ()Landroid/os/Parcel; // 3: astore 4 // 5: invokestatic 24 android/os/Parcel:obtain ()Landroid/os/Parcel; // 8: astore 5 // 10: aload 4 // 12: ldc 26 // 14: invokevirtual 30 android/os/Parcel:writeInterfaceToken (Ljava/lang/String;)V // 17: aload_1 // 18: ifnull +70 -> 88 // 21: aload_1 // 22: invokeinterface 36 1 0 // 27: astore_1 // 28: aload 4 // 30: aload_1 // 31: invokevirtual 39 android/os/Parcel:writeStrongBinder (Landroid/os/IBinder;)V // 34: aload 4 // 36: iload_2 // 37: invokevirtual 43 android/os/Parcel:writeInt (I)V // 40: aload 4 // 42: iload_3 // 43: invokevirtual 43 android/os/Parcel:writeInt (I)V // 46: aload_0 // 47: getfield 15 com/google/android/gms/internal/ju$a$a:le Landroid/os/IBinder; // 50: iconst_1 // 51: aload 4 // 53: aload 5 // 55: iconst_0 // 56: invokeinterface 49 5 0 // 61: pop // 62: aload 5 // 64: invokevirtual 52 android/os/Parcel:readException ()V // 67: aload 5 // 69: invokevirtual 55 android/os/Parcel:readStrongBinder ()Landroid/os/IBinder; // 72: invokestatic 61 com/google/android/gms/dynamic/d$a:ap (Landroid/os/IBinder;)Lcom/google/android/gms/dynamic/d; // 75: astore_1 // 76: aload 5 // 78: invokevirtual 64 android/os/Parcel:recycle ()V // 81: aload 4 // 83: invokevirtual 64 android/os/Parcel:recycle ()V // 86: aload_1 // 87: areturn // 88: aconst_null // 89: astore_1 // 90: goto -62 -> 28 // 93: astore_1 // 94: aload 5 // 96: invokevirtual 64 android/os/Parcel:recycle ()V // 99: aload 4 // 101: invokevirtual 64 android/os/Parcel:recycle ()V // 104: aload_1 // 105: athrow // Local variable table: // start length slot name signature // 0 106 0 this a // 0 106 1 paramd com.google.android.gms.dynamic.d // 0 106 2 paramInt1 int // 0 106 3 paramInt2 int // 3 97 4 localParcel1 android.os.Parcel // 8 87 5 localParcel2 android.os.Parcel // Exception table: // from to target type // 10 17 93 finally // 21 28 93 finally // 28 76 93 finally } public IBinder asBinder() { return le; } } /* Location: * Qualified Name: com.google.android.gms.internal.ju.a.a * Java Class Version: 6 (50.0) * JD-Core Version: 0.7.1 */
[ "reverseengineeringer@hackeradmin.com" ]
reverseengineeringer@hackeradmin.com
232f88bc0028b94c3fd45150c6f12acaf885ed0c
7e1511cdceeec0c0aad2b9b916431fc39bc71d9b
/flakiness-predicter/input_data/original_tests/square-okhttp/nonFlakyMethods/okio.GzipSourceTest-gunzip_withAll.java
5816b0ac87c20ff30156b379c6520c48dfae747f
[ "BSD-3-Clause" ]
permissive
Taher-Ghaleb/FlakeFlagger
6fd7c95d2710632fd093346ce787fd70923a1435
45f3d4bc5b790a80daeb4d28ec84f5e46433e060
refs/heads/main
2023-07-14T16:57:24.507743
2021-08-26T14:50:16
2021-08-26T14:50:16
null
0
0
null
null
null
null
UTF-8
Java
false
false
626
java
/** * For portability, it is a good idea to export the gzipped bytes and try running gzip. Ex. {@code echo gzipped | base64 --decode | gzip -l -v} */ @Test public void gunzip_withAll() throws Exception { OkBuffer gzipped=new OkBuffer(); gzipped.write(gzipHeaderWithFlags((byte)0x1c)); gzipped.writeShort(Util.reverseBytesShort((short)7)); gzipped.write("blubber".getBytes(UTF_8),0,7); gzipped.write("foo.txt".getBytes(UTF_8),0,7); gzipped.writeByte(0); gzipped.write("rubbish".getBytes(UTF_8),0,7); gzipped.writeByte(0); gzipped.write(deflated); gzipped.write(gzipTrailer); assertGzipped(gzipped); }
[ "aalsha2@masonlive.gmu.edu" ]
aalsha2@masonlive.gmu.edu
de1cc81e8cfd385d0c83a808eb364ee39b61326f
3fec59536b74d6bb3169b97ef21127580633b9ab
/app/src/main/java/me/skyrim/charthelp/adapter/WorkerAdapter.java
9e57258812a02196eb4aeb525a5f0696f7892ff2
[]
no_license
sagaciousfrog/ChartHelp
b4f0b9d8d074b8d94c7b2f22da8e868f03fa0b6d
75b280ab18e1cce7cc6e2fe238d874a66ab76f89
refs/heads/master
2020-04-24T09:48:07.210965
2017-08-19T09:13:10
2017-08-19T09:13:10
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,372
java
package me.skyrim.charthelp.adapter; import android.view.View; import com.chad.library.adapter.base.BaseQuickAdapter; import com.chad.library.adapter.base.BaseViewHolder; import java.util.List; import java.util.Locale; import me.skyrim.charthelp.R; import me.skyrim.charthelp.base.BaseActivity; import me.skyrim.charthelp.dao.WorkerBean; import me.skyrim.charthelp.ui.SlidingButtonView; import me.skyrim.charthelp.uitls.DensityUtils; /** * Created by Obl on 2017/8/18. * me.skyrim.charthelp.adapter */ public class WorkerAdapter extends BaseQuickAdapter<WorkerBean, BaseViewHolder> implements SlidingButtonView .IonSlidingButtonListener { private SlidingButtonView mMenu = null; private BaseActivity activity; public WorkerAdapter(BaseActivity activity, List<WorkerBean> data) { super(R.layout.adapter_worker, data); this.activity = activity; } @Override protected void convert(BaseViewHolder helper, WorkerBean item) { helper.itemView.findViewById(R.id.layout_content).getLayoutParams().width = DensityUtils.getWidthOfScreen (activity, 6, 1); ((SlidingButtonView) (helper.itemView.findViewById(R.id.slide))).setSlidingButtonListener(this); helper.setText(R.id.tvWorkerName, item.getWorkerName()) .setText(R.id.tvWorkerName, String.format(Locale.CHINA, "%s ID:%d", item.getWorkerName(), item .getWorkerId())) .setText(R.id.tvWorkerTotalPrice, String.format(Locale.CHINA, "共花费 %.2f", item.getTotalPrice())) .addOnLongClickListener(R.id.layout_content) .addOnClickListener(R.id.layout_content) .addOnClickListener(R.id.tv_delete); } @Override public void onMenuIsOpen(View view) { mMenu = (SlidingButtonView) view; } @Override public void onDownOrMove(SlidingButtonView slidingButtonView) { if (menuIsOpen()) { if (mMenu != slidingButtonView) { closeMenu(); } } } /** * 关闭菜单 */ public void closeMenu() { mMenu.closeMenu(); mMenu = null; } /** * 判断是否有菜单打开 */ public Boolean menuIsOpen() { if (mMenu != null) { return true; } return false; } }
[ "18366108542@163.com" ]
18366108542@163.com
b509db76ad98fb418656efbabeae9fb396e258d4
fadad91f8b522ec17760bf614d0b40c9d22264b5
/src/main/java/in/dragonbra/klayb0t/retrofit/response/TwitchChatters.java
7eaa0ab912e9a15e6a7354ccf525726b3da8715e
[]
no_license
Longi94/klaybot
9a145b639a11659b5a63b1ff85f47d6d83384e31
c2303ff43fcf60eec93a8c42f0f735648986b9c8
refs/heads/master
2023-01-15T20:57:05.198584
2020-12-08T17:06:20
2020-12-08T17:06:20
144,627,871
0
0
null
2023-01-04T11:54:55
2018-08-13T20:02:30
Java
UTF-8
Java
false
false
1,899
java
package in.dragonbra.klayb0t.retrofit.response; import com.google.gson.annotations.Expose; import com.google.gson.annotations.SerializedName; import java.util.List; public class TwitchChatters { @SerializedName("broadcaster") @Expose private List<String> broadcaster; @SerializedName("vips") @Expose private List<String> vips; @SerializedName("moderators") @Expose private List<String> moderators; @SerializedName("staff") @Expose private List<String> staff; @SerializedName("admins") @Expose private List<String> admins; @SerializedName("global_mods") @Expose private List<String> globalMods; @SerializedName("viewers") @Expose private List<String> viewers; public List<String> getBroadcaster() { return broadcaster; } public void setBroadcaster(List<String> broadcaster) { this.broadcaster = broadcaster; } public List<String> getVips() { return vips; } public void setVips(List<String> vips) { this.vips = vips; } public List<String> getModerators() { return moderators; } public void setModerators(List<String> moderators) { this.moderators = moderators; } public List<String> getStaff() { return staff; } public void setStaff(List<String> staff) { this.staff = staff; } public List<String> getAdmins() { return admins; } public void setAdmins(List<String> admins) { this.admins = admins; } public List<String> getGlobalMods() { return globalMods; } public void setGlobalMods(List<String> globalMods) { this.globalMods = globalMods; } public List<String> getViewers() { return viewers; } public void setViewers(List<String> viewers) { this.viewers = viewers; } }
[ "lngtrn94@gmail.com" ]
lngtrn94@gmail.com
c7eb06b328395233a7afc0aac44eb9e27780458c
80a6b8d1efa66efbb94f0df684eedb81a5cc552c
/assertj-core/src/test/java/org/assertj/core/api/double_/DoubleAssert_isZero_Test.java
0ad0afff2dabfb2a3d2bdd09d58a06306182cc4f
[ "Apache-2.0" ]
permissive
AlHasan89/System_Re-engineering
43f232e90f65adc940af3bfa2b4d584d25ce076c
b80e6d372d038fd246f946e41590e07afddfc6d7
refs/heads/master
2020-03-27T05:08:26.156072
2019-01-06T17:54:59
2019-01-06T17:54:59
145,996,692
0
1
Apache-2.0
2019-01-06T17:55:00
2018-08-24T13:43:31
Java
UTF-8
Java
false
false
2,414
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. * * Copyright 2012-2017 the original author or authors. */ package org.assertj.core.api.double_; import static org.assertj.core.api.Assertions.assertThat; import static org.mockito.Mockito.verify; import org.assertj.core.api.DoubleAssert; import org.assertj.core.api.DoubleAssertBaseTest; import org.junit.Test; public class DoubleAssert_isZero_Test extends DoubleAssertBaseTest { @Override protected DoubleAssert invoke_api_method() { return assertions.isZero(); } @Override protected void verify_internal_effects() { verify(doubles).assertIsZero(getInfo(assertions), getActual(assertions)); } @Test public void should_pass_with_primitive_negative_zero() { // GIVEN final double negativeZero = -0.0; // THEN assertThat(negativeZero).isZero(); } @Test public void should_pass_with_primitive_positive_zero() { // GIVEN final double positiveZero = 0.0; // THEN assertThat(positiveZero).isZero(); } @Test public void should_pass_with_Double_positive_zero() { // GIVEN final Double positiveZero = 0.0; // THEN assertThat(positiveZero).isZero(); } @Test public void should_fail_with_non_zero() { // GIVEN final double notZero = 1.0; try { // WHEN assertThat(notZero).isZero(); } catch (AssertionError e) { // THEN assertThat(e).hasMessage("expected:<[0].0> but was:<[1].0>"); return; } failBecauseExpectedAssertionErrorWasNotThrown(); } @Test public void should_fail_with_Double_negative_zero() { // GIVEN final Double negativeZero = -0.0; try { // WHEN assertThat(negativeZero).isZero(); } catch (AssertionError e) { // THEN assertThat(e).hasMessage("expected:<[]0.0> but was:<[-]0.0>"); return; } failBecauseExpectedAssertionErrorWasNotThrown(); } }
[ "nw91@le.ac.uk" ]
nw91@le.ac.uk
752fa681bf143ecfba70f99d0c25d40d67a3007a
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/14/14_1068710a96dd484deffdb7f3769be7e129221941/Activator/14_1068710a96dd484deffdb7f3769be7e129221941_Activator_t.java
3369c621ec113758ad4af97f25923e005c932837
[]
no_license
zhongxingyu/Seer
48e7e5197624d7afa94d23f849f8ea2075bcaec0
c11a3109fdfca9be337e509ecb2c085b60076213
refs/heads/master
2023-07-06T12:48:55.516692
2023-06-22T07:55:56
2023-06-22T07:55:56
259,613,157
6
2
null
2023-06-22T07:55:57
2020-04-28T11:07:49
null
UTF-8
Java
false
false
1,841
java
/******************************************************************************* * Copyright (c) 2005, 2007 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/epl-v10.html * *******************************************************************************/ package org.eclipse.dltk.ruby.core.tests; import java.io.BufferedInputStream; import java.io.IOException; import java.io.InputStream; import java.net.URL; import org.eclipse.core.runtime.Plugin; import org.osgi.framework.BundleContext; /** * The activator class controls the plug-in life cycle */ public class Activator extends Plugin { // The plug-in ID public static final String PLUGIN_ID = "org.eclipse.dltk.ruby.core.tests"; // The shared instance private static Activator plugin; /** * The constructor */ public Activator() { plugin = this; } /* * (non-Javadoc) * @see org.eclipse.core.runtime.Plugins#start(org.osgi.framework.BundleContext) */ public void start(BundleContext context) throws Exception { super.start(context); } /* * (non-Javadoc) * @see org.eclipse.core.runtime.Plugin#stop(org.osgi.framework.BundleContext) */ public void stop(BundleContext context) throws Exception { plugin = null; super.stop(context); } /** * Returns the shared instance * * @return the shared instance */ public static Activator getDefault() { return plugin; } public static InputStream openResource(String path) throws IOException { URL url = getDefault().getBundle().getEntry(path); return new BufferedInputStream(url.openStream()); } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
857bd341510e821b327aee10ac19aac45f469a9f
6e34a4bf59d4fe466865be89377373c35ffdc62b
/src/com/neocoretechs/relatrix/server/CommandPacketInterface.java
356cdab08542f34c03064983eeca9a35b16893e6
[ "Apache-2.0" ]
permissive
neocoretechs/Relatrix
5ab7ed93f8b1bf46ca88fed62ad5206d365dc5b1
3567be3d61433300d9dd3c9ba166fe5a3bc0b736
refs/heads/master
2023-05-26T08:01:48.414376
2023-05-16T21:43:11
2023-05-16T21:43:11
25,831,041
4
0
null
null
null
null
UTF-8
Java
false
false
651
java
package com.neocoretechs.relatrix.server; import java.io.Serializable; /** * Command packet interface bound for WorkBoot nodes to activate threads * to operate on a specific port. RemoteMaster is from the perspective of the server, * which is sent the packet with the master and slave ports of the client. * controller * @author jg 2015,2020 * */ public interface CommandPacketInterface extends Serializable { public int getMasterPort(); public void setMasterPort(int port); public String getTransport(); public void setTransport(String transport); public String getRemoteMaster(); public void setRemoteMaster(String remoteMaster); }
[ "groffj@neocoretechs.com" ]
groffj@neocoretechs.com
4506996bc5f68af0d36fce0f74468b5fff9d25de
31cfb375677dcad063d70986491991254573cc82
/armstrong-numbers/src/main/java/ArmstrongNumbers.java
f6318365b49ca4b01c79a915e94a6ecde87abecb
[]
no_license
bwielk/JavaExercisms
4ae1f9e9c3228bac2bb1afba84b159ccc7cf4b35
a1217ebfdf68212d820c2e504c01f13ee3243ffc
refs/heads/master
2021-06-21T02:43:51.587652
2021-03-28T11:31:55
2021-03-28T11:31:55
199,989,592
0
0
null
null
null
null
UTF-8
Java
false
false
545
java
import java.util.Arrays; import java.util.List; import java.util.stream.Collectors; class ArmstrongNumbers { boolean isArmstrongNumber(int numberToCheck) { String[] listOfNumbers = Integer.toString(numberToCheck).split(""); int numberOfNumbers = listOfNumbers.length; List<Double> results = Arrays.asList(listOfNumbers).stream().map(x -> Math.pow(Double.valueOf(x), numberOfNumbers)).collect(Collectors.toList()); Integer sumOfresults = results.stream().mapToInt(Double::intValue).sum(); return sumOfresults == numberToCheck; } }
[ "bwielk@gmail.com" ]
bwielk@gmail.com
a182e5a43c18b5dde1afe619375561bc7cb2f3de
3fc7c3d4a697c418bad541b2ca0559b9fec03db7
/TestResult/javasource/org/apache/http/impl/conn/LoggingSessionOutputBuffer.java
5f0084e52be113eb9500291c59671bc1b851cbf6
[]
no_license
songxingzai/APKAnalyserModules
59a6014350341c186b7788366de076b14b8f5a7d
47cf6538bc563e311de3acd3ea0deed8cdede87b
refs/heads/master
2021-12-15T02:43:05.265839
2017-07-19T14:44:59
2017-07-19T14:44:59
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,386
java
package org.apache.http.impl.conn; import java.io.IOException; import java.nio.charset.Charset; import org.apache.http.Consts; import org.apache.http.annotation.Immutable; import org.apache.http.io.HttpTransportMetrics; import org.apache.http.io.SessionOutputBuffer; import org.apache.http.util.CharArrayBuffer; @Deprecated @Immutable public class LoggingSessionOutputBuffer implements SessionOutputBuffer { private final String charset; private final SessionOutputBuffer out; private final Wire wire; public LoggingSessionOutputBuffer(SessionOutputBuffer paramSessionOutputBuffer, Wire paramWire) { this(paramSessionOutputBuffer, paramWire, null); } public LoggingSessionOutputBuffer(SessionOutputBuffer paramSessionOutputBuffer, Wire paramWire, String paramString) { out = paramSessionOutputBuffer; wire = paramWire; if (paramString != null) {} for (;;) { charset = paramString; return; paramString = Consts.ASCII.name(); } } public void flush() throws IOException { out.flush(); } public HttpTransportMetrics getMetrics() { return out.getMetrics(); } public void write(int paramInt) throws IOException { out.write(paramInt); if (wire.enabled()) { wire.output(paramInt); } } public void write(byte[] paramArrayOfByte) throws IOException { out.write(paramArrayOfByte); if (wire.enabled()) { wire.output(paramArrayOfByte); } } public void write(byte[] paramArrayOfByte, int paramInt1, int paramInt2) throws IOException { out.write(paramArrayOfByte, paramInt1, paramInt2); if (wire.enabled()) { wire.output(paramArrayOfByte, paramInt1, paramInt2); } } public void writeLine(String paramString) throws IOException { out.writeLine(paramString); if (wire.enabled()) { paramString = paramString + "\r\n"; wire.output(paramString.getBytes(charset)); } } public void writeLine(CharArrayBuffer paramCharArrayBuffer) throws IOException { out.writeLine(paramCharArrayBuffer); if (wire.enabled()) { paramCharArrayBuffer = new String(paramCharArrayBuffer.buffer(), 0, paramCharArrayBuffer.length()); paramCharArrayBuffer = paramCharArrayBuffer + "\r\n"; wire.output(paramCharArrayBuffer.getBytes(charset)); } } }
[ "leehdsniper@gmail.com" ]
leehdsniper@gmail.com
b4a55fef921901d6671757d6fb7f7b04fcc17e37
a14e86ba926d64eb8928fb487d2991505ea18952
/src/main/java/com/_520it/wms/dao/impl/SupplierDAOImpl.java
d7799d9a626324e002a56f976a8e0c512ab1134a
[]
no_license
MrLawrenc/Mars_WMS
76de3a61b07e3fd308dc2d62e74cde6a811b7524
b4c74f16157fc71ee8bb902d3b05f4158ef3e982
refs/heads/master
2020-03-14T15:44:10.787864
2018-09-14T14:21:15
2018-09-14T14:21:15
131,682,925
1
0
null
null
null
null
UTF-8
Java
false
false
204
java
package com._520it.wms.dao.impl; import com._520it.wms.dao.ISupplierDAO; import com._520it.wms.domain.Supplier; public class SupplierDAOImpl extends GenericDAOImpl<Supplier> implements ISupplierDAO { }
[ "mrliu943903861@163.com" ]
mrliu943903861@163.com
44e5804d05482d6006f756b72f8a0b3ed1731e94
8977e0d0b7914cde53c8bbeacb48a06c8d53d003
/samples/server/petstore/java-inflector/src/main/java/io/swagger/model/User.java
ec9a66770306339a819329f4cbc82c670a413a8b
[ "Apache-2.0" ]
permissive
tareq-s/swagger-codegen
88d6d5274a89e12556c75dae94c587dd67351fbe
3f8dbf416d091b45eb088b620512e62c1d76e9df
refs/heads/master
2021-01-16T20:25:27.936515
2015-08-24T08:20:51
2015-08-24T08:20:51
41,303,091
1
0
null
2015-08-24T12:58:12
2015-08-24T12:58:12
null
UTF-8
Java
false
false
2,892
java
package io.swagger.model; import io.swagger.annotations.*; import com.fasterxml.jackson.annotation.JsonProperty; @ApiModel(description = "") @javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaInflectorServerCodegen", date = "2015-08-24T00:32:07.279-07:00") public class User { private Long id = null; private String username = null; private String firstName = null; private String lastName = null; private String email = null; private String password = null; private String phone = null; private Integer userStatus = null; /** **/ @ApiModelProperty(value = "") @JsonProperty("id") public Long getId() { return id; } public void setId(Long id) { this.id = id; } /** **/ @ApiModelProperty(value = "") @JsonProperty("username") public String getUsername() { return username; } public void setUsername(String username) { this.username = username; } /** **/ @ApiModelProperty(value = "") @JsonProperty("firstName") public String getFirstName() { return firstName; } public void setFirstName(String firstName) { this.firstName = firstName; } /** **/ @ApiModelProperty(value = "") @JsonProperty("lastName") public String getLastName() { return lastName; } public void setLastName(String lastName) { this.lastName = lastName; } /** **/ @ApiModelProperty(value = "") @JsonProperty("email") public String getEmail() { return email; } public void setEmail(String email) { this.email = email; } /** **/ @ApiModelProperty(value = "") @JsonProperty("password") public String getPassword() { return password; } public void setPassword(String password) { this.password = password; } /** **/ @ApiModelProperty(value = "") @JsonProperty("phone") public String getPhone() { return phone; } public void setPhone(String phone) { this.phone = phone; } /** * User Status **/ @ApiModelProperty(value = "User Status") @JsonProperty("userStatus") public Integer getUserStatus() { return userStatus; } public void setUserStatus(Integer userStatus) { this.userStatus = userStatus; } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class User {\n"); sb.append(" id: ").append(id).append("\n"); sb.append(" username: ").append(username).append("\n"); sb.append(" firstName: ").append(firstName).append("\n"); sb.append(" lastName: ").append(lastName).append("\n"); sb.append(" email: ").append(email).append("\n"); sb.append(" password: ").append(password).append("\n"); sb.append(" phone: ").append(phone).append("\n"); sb.append(" userStatus: ").append(userStatus).append("\n"); sb.append("}\n"); return sb.toString(); } }
[ "fehguy@gmail.com" ]
fehguy@gmail.com
ec9dc235bfca82a447e8ef61bd58ab2d959f18b5
ffb51aa15e6e8d2f259843c783e66af7c0a85ff8
/src/java/com/tsp/sct/bo/CuentaEfectivoBO.java
2b1a37f6e2777d1e9783674d2abec30bb6fe4500
[]
no_license
Karmaqueda/SGFENS_BAFAR-1
c9c9b0ffad3ac948b2a76ffbbd5916c1a8751c51
666f858fc49abafe7612600ac0fd468c54c37bfe
refs/heads/master
2021-01-18T16:09:08.520888
2016-08-01T18:49:40
2016-08-01T18:49:40
null
0
0
null
null
null
null
UTF-8
Java
false
false
5,075
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 com.tsp.sct.bo; import com.tsp.sct.dao.dto.CuentaEfectivo; import com.tsp.sct.dao.jdbc.CuentaEfectivoDaoImpl; import java.sql.Connection; /** * * @author HpPyme */ public class CuentaEfectivoBO { private Connection conn = null; private CuentaEfectivo cuentaEfectivo = null; public Connection getConn() { return conn; } public void setConn(Connection conn) { this.conn = conn; } public CuentaEfectivo getCuentaEfectivo() { return cuentaEfectivo; } public void setCuentaEfectivo(CuentaEfectivo cuentaEfectivo) { this.cuentaEfectivo = cuentaEfectivo; } public CuentaEfectivoBO(Connection conn) { this.conn = conn; } public CuentaEfectivoBO(int idCuentaEfectivo, Connection conn){ this.conn = conn; try{ CuentaEfectivoDaoImpl cuentaEfectivoDaoImpl = new CuentaEfectivoDaoImpl(this.conn); this.cuentaEfectivo = cuentaEfectivoDaoImpl.findByPrimaryKey(idCuentaEfectivo); }catch(Exception e){ e.printStackTrace(); } } /** * Realiza una búsqueda por ID Usuario en busca de * coincidencias * @param idUsuario ID Del Usuario para filtrar, -1 para mostrar todos los registros * @param minLimit Limite inferior de la paginación (Desde) 0 en caso de no existir limite inferior * @param maxLimit Limite superior de la paginación (Hasta) 0 en caso de no existir limite superior * @param filtroBusqueda Cadena con un filtro de búsqueda personalizado * @return DTO CuentaEfectivo */ public CuentaEfectivo[] findCuentaEfectivo(int idEmpleado, int minLimit,int maxLimit, String filtroBusqueda) { CuentaEfectivo[] cuentaEfectivoDto = new CuentaEfectivo[0]; CuentaEfectivoDaoImpl cuentaEfectivoDao = new CuentaEfectivoDaoImpl(this.conn); try { String sqlFiltro=""; if (idEmpleado>0){ sqlFiltro =" ID_EMPLEADO=" + idEmpleado + " "; }else{ sqlFiltro =" ID_EMPLEADO > 0 "; } if (!filtroBusqueda.trim().equals("")){ sqlFiltro += filtroBusqueda; } if (minLimit<0) minLimit=0; String sqlLimit=""; if ((minLimit>0 && maxLimit>0) || (minLimit==0 && maxLimit>0)) sqlLimit = " LIMIT " + minLimit + "," + maxLimit; cuentaEfectivoDto = cuentaEfectivoDao.findByDynamicWhere( sqlFiltro + " ORDER BY ID_CUENTA_EFECTIVO DESC" + sqlLimit , new Object[0]); } catch (Exception ex) { System.out.println("Error de consulta a Base de Datos: " + ex.toString()); ex.printStackTrace(); } return cuentaEfectivoDto; } public double cuentaEfectivoTipo(int idCuentaEfectivo, String tipo){ double montoTotal = 0; double montoBilletes = 0; double montoMonedas = 0; try{ CuentaEfectivoDaoImpl cuentaDaoImpl = new CuentaEfectivoDaoImpl(this.conn); this.cuentaEfectivo = cuentaDaoImpl.findByPrimaryKey(idCuentaEfectivo); }catch(Exception e){ e.printStackTrace(); } if(cuentaEfectivo!=null){ montoBilletes = (cuentaEfectivo.getBillete1000() * 1000) + (cuentaEfectivo.getBillete500() * 500) + (cuentaEfectivo.getBillete200() * 200) + (cuentaEfectivo.getBillete100() * 100) + (cuentaEfectivo.getBillete50() * 50) + (cuentaEfectivo.getBillete20()* 20); montoMonedas = (cuentaEfectivo.getMoneda20() * 20) + (cuentaEfectivo.getMoneda10() * 10) + (cuentaEfectivo.getMoneda5() * 5) + (cuentaEfectivo.getMoneda2() * 2) + (cuentaEfectivo.getMoneda1() * 1) + (cuentaEfectivo.getMoneda050() * 0.50) + (cuentaEfectivo.getMoneda020() * 0.20) + (cuentaEfectivo.getMoneda010() * 0.10); if(tipo.equals("billetes")){ return montoBilletes; }else if(tipo.equals("monedas")){ return montoMonedas; }else if(tipo.equals("total")){ return (montoBilletes + montoMonedas ); } } return 0; } }
[ "ing.gloriapalmagonzalez@gmail.com" ]
ing.gloriapalmagonzalez@gmail.com
da99801895a44566d0c78f168b061c605d94991f
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/22/22_498f49e32596315725651e73c49e5a376b5eca00/CookMePlayerListener/22_498f49e32596315725651e73c49e5a376b5eca00_CookMePlayerListener_t.java
f144c69a92d40b3c26d74e8d1dd526beb46e7ec4
[]
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
7,650
java
import java.sql.Timestamp; import java.util.Random; /** * CookMePlayerListener * Handles the players activities! * * Refer to the forum thread: * http://bit.ly/cookmebukkit * Refer to the dev.bukkit.org page: * http://bit.ly/cookmebukkitdev * * @author xGhOsTkiLLeRx * @thanks nisovin for his awesome code snippet! * */ public class CookMePlayerListener extends PluginListener { private CookMe plugin; private boolean message = true; private Random random = new Random(); public CookMePlayerListener(CookMe instance) { plugin = instance; } public boolean onEat(Player player, Item item) { String effect; Timestamp now = new Timestamp(System.currentTimeMillis()); // Check if player is affected //TODO if (!player.hasPermission("cookme.safe")) { if (!player.isAdmin()) { // Check for item & right clicking if (sameItem(item)) { // If the player is in cooldown phase cancel it if (!plugin.cooldownManager.hasCooldown(player, now)) { // Check for food level if (player.getFoodLevel() != 20) { // Make a temp double and a value between 0 and 99 double temp = 0; int i = 0; // Get the number for the effect for(i = 0; i < plugin.percentages.length; i++) { temp += plugin.percentages[i]; if (random.nextInt(100) <= temp) { break; } } // EffectStrenght, Duration etc. int randomEffectStrength = random.nextInt(16); int randomEffectTime = (random.nextInt((plugin.maxDuration - plugin.minDuration) + 1) + plugin.minDuration) * 1000; // Player gets random damage, stack minus 1 if (i == 0) { int randomDamage = random.nextInt(9) +1; effect = plugin.localization.getString("damage"); message(player, effect); decreaseItem(player); player.applayDamage(DamageSource.createPlayerDamage(player), randomDamage); } // Player dies, stack minus 1 if (i == 1) { effect = plugin.localization.getString("death"); message(player, effect); decreaseItem(player); player.setHealth(0); } // Random venom damage (including green hearts :) ) if (i == 2) { effect = plugin.localization.getString("venom"); message(player, effect); decreaseItem(player); player.addPotionEffect(PotionEffect.getNewPotionEffect(PotionEffect.Type.POISON, randomEffectTime, randomEffectStrength)); } // Food bar turns green (poison) if (i == 3) { effect = plugin.localization.getString("hungervenom"); message(player, effect); decreaseItem(player); player.addPotionEffect(PotionEffect.getNewPotionEffect(PotionEffect.Type.HUNGER, randomEffectTime, randomEffectStrength)); } // Sets the food level down. Stack minus 1 if (i == 4) { int currentFoodLevel = player.getFoodLevel(); int randomFoodLevel = 0; if (currentFoodLevel != 0) { randomFoodLevel = random.nextInt(currentFoodLevel); } effect = plugin.localization.getString("hungerdecrease"); message(player, effect); decreaseItem(player); player.setFoodLevel(randomFoodLevel); } // Confusion if (i == 5) { effect = plugin.localization.getString("confusion"); message(player, effect); decreaseItem(player); player.addPotionEffect(PotionEffect.getNewPotionEffect(PotionEffect.Type.CONFUSION, randomEffectTime, randomEffectStrength)); } // Blindness if (i == 6) { effect = plugin.localization.getString("blindness"); message(player, effect); decreaseItem(player); player.addPotionEffect(PotionEffect.getNewPotionEffect(PotionEffect.Type.BLINDNESS, randomEffectTime, randomEffectStrength)); } // Weakness if (i == 7) { effect = plugin.localization.getString("weakness"); message(player, effect); decreaseItem(player); player.addPotionEffect(PotionEffect.getNewPotionEffect(PotionEffect.Type.WEAKNESS, randomEffectTime, randomEffectStrength)); } // Slowness if (i == 8) { effect = plugin.localization.getString("slowness"); message(player, effect); decreaseItem(player); player.addPotionEffect(PotionEffect.getNewPotionEffect(PotionEffect.Type.SLOW_DOWN, randomEffectTime, randomEffectStrength)); } // Slowness for blocks if (i == 9) { effect = plugin.localization.getString("slowness_blocks"); message(player, effect); decreaseItem(player); player.addPotionEffect(PotionEffect.getNewPotionEffect(PotionEffect.Type.DIG_SLOW, randomEffectTime, randomEffectStrength)); } // Instant Damage if (i == 10) { effect = plugin.localization.getString("instant_damage"); message(player, effect); decreaseItem(player); player.addPotionEffect(PotionEffect.getNewPotionEffect(PotionEffect.Type.HARM, randomEffectTime, randomEffectStrength)); } // Refusing if (i == 11) { effect = plugin.localization.getString("refusing"); message(player, effect); return true; } // Wither effect if (i == 12) { effect = plugin.localization.getString("wither"); message(player, effect); decreaseItem(player); player.addPotionEffect(PotionEffect.getNewPotionEffect(PotionEffect.Type.WITHER, randomEffectTime, randomEffectStrength)); } // Add player to cooldown list if (plugin.cooldown != 0) { plugin.cooldownManager.addPlayer(player); } } } } } else if (plugin.preventVanillaPoison) { // Prevent the vanilla poison, too? if (item.getType() == Item.Type.RawChicken || item.getType() == Item.Type.RottenFlesh) { int foodLevel = player.getFoodLevel(); // Case chicken if (item.getType() == Item.Type.RawChicken) { // Quote: 1 unit of hunger (2 hunger) foodLevel += 2; } else if (item.getType() == Item.Type.RottenFlesh) { // Case rotten flesh // Quote: 2 units of hunger (4 hunger) foodLevel += 4; } // Not higher than 20 if (foodLevel > 20) { foodLevel = 20; } player.setFoodLevel(foodLevel); decreaseItem(player); return true; } } return false; } private void message(Player player, String message) { if (plugin.messages) { plugin.message(player, message, null, null); } } // Is the item in the list? Yes or no private boolean sameItem(Item item) { for (String itemName : plugin.itemList) { // Get the Material try { int ID = Integer.valueOf(itemName); if (ID == item.getItemId()) { return true; } } catch (NumberFormatException e) { try { Item.Type mat = Item.Type.valueOf(itemName); // Get ID & compare if (mat == item.getType()) { return true; } } // Not valid catch (IllegalArgumentException e2) { // Prevent spamming if (message) { CookMe.log.warning("Couldn't load the foods! Please check your config!"); CookMe.log.warning("The following item id/name is invalid: " + itemName); message = false; } } } } return false; } // Sets the raw food -1 private void decreaseItem (Player player) { Item afterEating = player.getItemStackInHand(); if (afterEating.getAmount() == 1) { player.setItemInHand(null); } else { afterEating.setAmount(afterEating.getAmount() - 1); player.setItemInHand(afterEating); } player.updateInventory(); } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
f8f4fa1a64838fc3425491638d2983825675dc70
5979994b215fabe125cd756559ef2166c7df7519
/aimir-mdms-iesco/src/main/java/com/aimir/mars/integration/metercontrol/queue/Processor.java
b6f3eadc57a355ee77a94a5b33f8a1f630a638f2
[]
no_license
TechTinkerer42/Haiti
91c45cb1b784c9afc61bf60d43e1d5623aeba888
debaea96056d1d4611b79bd846af8f7484b93e6e
refs/heads/master
2023-04-28T23:39:43.176592
2021-05-03T10:49:42
2021-05-03T10:49:42
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,576
java
package com.aimir.mars.integration.metercontrol.queue; import javax.jms.MapMessage; import javax.jms.Message; import javax.jms.MessageListener; import javax.jms.ObjectMessage; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; /** * Abstract Processor * */ public abstract class Processor implements MessageListener { // protected static ApplicationContext ctx = null; protected Log log = LogFactory.getLog(this.getClass().getName()); protected String name = null; protected String serviceType = null; /* static { if (ctx == null) { ctx = new ClassPathXmlApplicationContext(new String[]{"/config/spring-listener.xml"}); } } */ /** * processing Service Data * * @param obj <code>Object</code> Object */ public abstract void processing(Object obj) throws Exception; /** * restore backup data */ public abstract void restore() throws Exception; public void onMessage(Message msg) { if (msg instanceof ObjectMessage) { try { processing(((ObjectMessage) msg).getObject()); } catch (Exception e) { log.error(e,e); } } else if(msg instanceof MapMessage){ try { processing(((MapMessage) msg)); } catch (Exception e) { log.error(e,e); } } else { log.warn("Message is not object, check it!!"); } } }
[ "marsr0913@nuritelecom.com" ]
marsr0913@nuritelecom.com
02fe65d4cc6b5777143650ab0967fd453bf7b7c0
ee1244b10de45679f053293e366f192af307be74
/sources/org/telegram/messenger/SendMessagesHelper$$Lambda$34.java
93f4e9ed4c210ebcc3613509fd17a5e4e828a5f9
[]
no_license
scarletstuff/Turbogram
a086e50b3f4d7036526075199616682a0d7c9c45
21b8862573953add9260f1eb586f0985d2c71e8e
refs/heads/master
2021-09-23T14:34:23.323880
2018-09-24T17:48:43
2018-09-24T17:48:43
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,115
java
package org.telegram.messenger; import org.telegram.tgnet.TLObject; import org.telegram.tgnet.TLRPC$Message; import org.telegram.tgnet.TLRPC$TL_error; final /* synthetic */ class SendMessagesHelper$$Lambda$34 implements Runnable { private final SendMessagesHelper arg$1; private final TLRPC$TL_error arg$2; private final TLRPC$Message arg$3; private final TLObject arg$4; private final MessageObject arg$5; private final String arg$6; private final TLObject arg$7; SendMessagesHelper$$Lambda$34(SendMessagesHelper sendMessagesHelper, TLRPC$TL_error tLRPC$TL_error, TLRPC$Message tLRPC$Message, TLObject tLObject, MessageObject messageObject, String str, TLObject tLObject2) { this.arg$1 = sendMessagesHelper; this.arg$2 = tLRPC$TL_error; this.arg$3 = tLRPC$Message; this.arg$4 = tLObject; this.arg$5 = messageObject; this.arg$6 = str; this.arg$7 = tLObject2; } public void run() { this.arg$1.lambda$null$31$SendMessagesHelper(this.arg$2, this.arg$3, this.arg$4, this.arg$5, this.arg$6, this.arg$7); } }
[ "root@linuxhub.it" ]
root@linuxhub.it
d072acaa9beb0824173f6a18b2d95a4137f32d53
33182ce46766305859d5fa03b9fefd61981c32f2
/src_benchmark/activitydiagram/activitydiagram/algebra/operation/ActivitydiagramActivitydiagramOpaqueAction_AspectOperation.java
ef75f47f5d0b58a52602a54a1ffb0a9056634810
[]
no_license
manuelleduc/crispy-umbrella
4278777f97f644794f1ae67e661019d18b19961f
4cef8b912ae2b5809be957f3173e7130535c474a
refs/heads/master
2021-01-20T01:30:29.216810
2017-04-24T22:23:51
2017-04-24T22:23:51
89,289,088
0
0
null
null
null
null
UTF-8
Java
false
false
392
java
package activitydiagram.activitydiagram.algebra.operation; public interface ActivitydiagramActivitydiagramOpaqueAction_AspectOperation extends activitydiagramoa.activitydiagram.algebra.operation.ActivitydiagramoaActivitydiagramOpaqueActionOperation, activitydiagram.activitydiagram.algebra.operation.ActivitydiagramActivitydiagramAction_AspectOperation { void execute(); void doAction(); }
[ "manuel.leduc@inria.fr" ]
manuel.leduc@inria.fr
cd4352e6cd04e162c1796e54a0eddb4885d48ec8
d07d8d73fbca893ef8310d872d545009f530cd0f
/Workspaces/intelij/home/atomikos/osgi-3.9.2/service-tracker/service-tracker-osgi-example-db-axt/src/main/java/com/atomikos/osgi/sample/internal/db/Activator.java
bfcaba975d4f310272486e28a0fdf74d6fccc11c
[]
no_license
Priveyes/WakHome
95a289a9b5941624a6b8839be20bc59c9168df59
0529a3b823893016a4bba10542c40ecad23c97ba
refs/heads/master
2020-08-22T11:22:20.959883
2015-10-17T12:47:34
2015-10-17T12:47:34
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,602
java
package com.atomikos.osgi.sample.internal.db; import javax.sql.DataSource; import org.apache.derby.jdbc.EmbeddedXADataSource; import org.osgi.framework.BundleActivator; import org.osgi.framework.BundleContext; import com.atomikos.jdbc.AtomikosDataSourceBean; import com.atomikos.jmx.jdbc.JmxAtomikosDataSourceBean; public class Activator implements BundleActivator { private AtomikosDataSourceBean dataSource; public void start(BundleContext context) throws Exception { System.err.println("Starting database connection pool..."); EmbeddedXADataSource embeddedXADataSource = new EmbeddedXADataSource(); embeddedXADataSource.setDatabaseName("db"); embeddedXADataSource.setCreateDatabase("create"); dataSource = new AtomikosDataSourceBean(); dataSource.setUniqueResourceName("OSGI"); dataSource.setXaDataSource(embeddedXADataSource); dataSource.setMinPoolSize(2); dataSource.setMaxPoolSize(10); dataSource.init(); JmxAtomikosDataSourceBean mBean2 = new JmxAtomikosDataSourceBean(); mBean2.setAutoRegisterWithPlatformMBeanServerOnInit(true); mBean2.setMonitoredBean(dataSource); mBean2.init(); /* * Eventually customize to be able to register multiple datasource... * Dictionary<String, String> props=new Hashtable<String, String>(); * props.put("uniqueResourceName", "OSGI"); */ context.registerService(DataSource.class.getName(), dataSource, null); } public void stop(BundleContext context) throws Exception { System.err.println("Stopping database connection pool..."); dataSource.close(); } }
[ "wakkir@yahoo.com" ]
wakkir@yahoo.com
528ef9faa7fa1e2d62768810034b68f03c63a87b
d7462ec35d59ed68f306b291bd8e505ff1d65946
/service/pull/src/main/java/com/alibaba/citrus/service/pull/PullContext.java
753dba8624fc9227989beda09ffe8a0848375b0a
[]
no_license
ixijiass/citrus
e6d10761697392fa51c8a14d4c9f133f0a013265
53426f1d73cc86c44457d43fb8cbe354ecb001fd
refs/heads/master
2023-05-23T13:06:12.253428
2021-06-15T13:05:59
2021-06-15T13:05:59
368,477,372
0
0
null
null
null
null
GB18030
Java
false
false
1,108
java
/* * Copyright 2010 Alibaba Group Holding Limited. * All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ package com.alibaba.citrus.service.pull; import java.util.Map; import java.util.Set; /** * 代表一个context,通过context可以取得所有的tools。 * <p> * 该实现包含延迟加载的逻辑,只当有需要时,才会加载指定的tool。 * </p> * * @author Michael Zhou */ public interface PullContext { Object pull(String name); Set<String> getToolNames(); Map<String, Object> getTools(); }
[ "isheng19982qrr@126.com" ]
isheng19982qrr@126.com
e6b02a560aaabc84496cddd7cc0db25a94595d62
a94619fdc8770da90d0d307da64f19e95bcbbfc7
/java/dt.java
a3f45a3616f4b20fca34fe3b72e8cd9414a0e638
[]
no_license
BeCandid/CFR
b95cf21629ced30fac290a61ff51d443057a5919
ab5019fb6196b6c8f8e2a3fe18f557b89831d690
refs/heads/master
2021-01-12T05:52:09.792333
2016-12-24T10:04:51
2016-12-24T10:04:51
77,222,002
3
0
null
null
null
null
UTF-8
Java
false
false
3,748
java
/* * Decompiled with CFR 0_110. * * Could not load the following classes: * android.view.View * android.view.View$AccessibilityDelegate * android.view.ViewGroup * android.view.accessibility.AccessibilityEvent * android.view.accessibility.AccessibilityNodeInfo * java.lang.Object */ import android.view.View; import android.view.ViewGroup; import android.view.accessibility.AccessibilityEvent; import android.view.accessibility.AccessibilityNodeInfo; class dt { public static Object a() { return new View.AccessibilityDelegate(); } public static Object a(final a a2) { return new View.AccessibilityDelegate(){ public boolean dispatchPopulateAccessibilityEvent(View view, AccessibilityEvent accessibilityEvent) { return a2.a(view, accessibilityEvent); } public void onInitializeAccessibilityEvent(View view, AccessibilityEvent accessibilityEvent) { a2.b(view, accessibilityEvent); } public void onInitializeAccessibilityNodeInfo(View view, AccessibilityNodeInfo accessibilityNodeInfo) { a2.a(view, (Object)accessibilityNodeInfo); } public void onPopulateAccessibilityEvent(View view, AccessibilityEvent accessibilityEvent) { a2.c(view, accessibilityEvent); } public boolean onRequestSendAccessibilityEvent(ViewGroup viewGroup, View view, AccessibilityEvent accessibilityEvent) { return a2.a(viewGroup, view, accessibilityEvent); } public void sendAccessibilityEvent(View view, int n2) { a2.a(view, n2); } public void sendAccessibilityEventUnchecked(View view, AccessibilityEvent accessibilityEvent) { a2.d(view, accessibilityEvent); } }; } public static void a(Object object, View view, int n2) { ((View.AccessibilityDelegate)object).sendAccessibilityEvent(view, n2); } public static void a(Object object, View view, Object object2) { ((View.AccessibilityDelegate)object).onInitializeAccessibilityNodeInfo(view, (AccessibilityNodeInfo)object2); } public static boolean a(Object object, View view, AccessibilityEvent accessibilityEvent) { return ((View.AccessibilityDelegate)object).dispatchPopulateAccessibilityEvent(view, accessibilityEvent); } public static boolean a(Object object, ViewGroup viewGroup, View view, AccessibilityEvent accessibilityEvent) { return ((View.AccessibilityDelegate)object).onRequestSendAccessibilityEvent(viewGroup, view, accessibilityEvent); } public static void b(Object object, View view, AccessibilityEvent accessibilityEvent) { ((View.AccessibilityDelegate)object).onInitializeAccessibilityEvent(view, accessibilityEvent); } public static void c(Object object, View view, AccessibilityEvent accessibilityEvent) { ((View.AccessibilityDelegate)object).onPopulateAccessibilityEvent(view, accessibilityEvent); } public static void d(Object object, View view, AccessibilityEvent accessibilityEvent) { ((View.AccessibilityDelegate)object).sendAccessibilityEventUnchecked(view, accessibilityEvent); } public static interface a { public void a(View var1, int var2); public void a(View var1, Object var2); public boolean a(View var1, AccessibilityEvent var2); public boolean a(ViewGroup var1, View var2, AccessibilityEvent var3); public void b(View var1, AccessibilityEvent var2); public void c(View var1, AccessibilityEvent var2); public void d(View var1, AccessibilityEvent var2); } }
[ "admin@timo.de.vc" ]
admin@timo.de.vc
97acca443145b33da0f3b24ee136ceb55a13c20c
92225460ebca1bb6a594d77b6559b3629b7a94fa
/src/com/kingdee/eas/fdc/sellhouse/app/CommerceChanceTrackController.java
2621c360f376497e547489b87228506304427c43
[]
no_license
yangfan0725/sd
45182d34575381be3bbdd55f3f68854a6900a362
39ebad6e2eb76286d551a9e21967f3f5dc4880da
refs/heads/master
2023-04-29T01:56:43.770005
2023-04-24T05:41:13
2023-04-24T05:41:13
512,073,641
0
1
null
null
null
null
UTF-8
Java
false
false
1,905
java
package com.kingdee.eas.fdc.sellhouse.app; import com.kingdee.bos.BOSException; //import com.kingdee.bos.metadata.*; import com.kingdee.bos.framework.*; import com.kingdee.bos.util.*; import com.kingdee.bos.Context; import java.lang.String; import com.kingdee.eas.common.EASBizException; import com.kingdee.bos.metadata.entity.EntityViewInfo; import com.kingdee.bos.dao.IObjectPK; import com.kingdee.eas.fdc.sellhouse.CommerceChanceTrackInfo; import com.kingdee.eas.fdc.basedata.app.FDCBillController; import com.kingdee.bos.metadata.entity.SelectorItemCollection; import com.kingdee.eas.framework.CoreBaseCollection; import com.kingdee.bos.util.*; import com.kingdee.bos.BOSException; import com.kingdee.bos.Context; import com.kingdee.eas.framework.CoreBaseInfo; import com.kingdee.bos.framework.*; import com.kingdee.eas.fdc.sellhouse.CommerceChanceTrackCollection; import java.rmi.RemoteException; import com.kingdee.bos.framework.ejb.BizController; public interface CommerceChanceTrackController extends FDCBillController { public CommerceChanceTrackCollection getCommerceChanceTrackCollection(Context ctx, String oql) throws BOSException, RemoteException; public CommerceChanceTrackCollection getCommerceChanceTrackCollection(Context ctx, EntityViewInfo view) throws BOSException, RemoteException; public CommerceChanceTrackCollection getCommerceChanceTrackCollection(Context ctx) throws BOSException, RemoteException; public CommerceChanceTrackInfo getCommerceChanceTrackInfo(Context ctx, IObjectPK pk) throws BOSException, EASBizException, RemoteException; public CommerceChanceTrackInfo getCommerceChanceTrackInfo(Context ctx, IObjectPK pk, SelectorItemCollection selector) throws BOSException, EASBizException, RemoteException; public CommerceChanceTrackInfo getCommerceChanceTrackInfo(Context ctx, String oql) throws BOSException, EASBizException, RemoteException; }
[ "yfsmile@qq.com" ]
yfsmile@qq.com
7002606e30848498b9b5080761caa92118273b2b
df742ee89d5fa19b6139087726c269f05cca7df1
/account-core/src/main/java/com/zbjdl/account/manager/impl/AssetClassInfoManagerImpl.java
3008b384f3ba6ea67e6d43b1e1820d2bb6c305b0
[]
no_license
zhengyi89/zbjdl-account
a3dca9af16709e6f4689fbe0b1b3aa9bda5fb8fb
b07d18aa7d112fd4eaa50235fe795dcddfe71c4c
refs/heads/master
2020-04-15T11:17:38.407382
2019-02-14T08:14:04
2019-02-14T08:14:04
164,623,668
1
1
null
null
null
null
UTF-8
Java
false
false
1,323
java
/* * Powered By zbjdl-code-generator * Web Site: http://www.zbjdl.com * Since 2018 - 2022 */ package com.zbjdl.account.manager.impl; import java.util.List; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; import com.zbjdl.account.repository.AssetClassInfoRepository; import com.zbjdl.account.manager.AssetClassInfoManager; import com.zbjdl.account.model.AssetClassInfo; @Component public class AssetClassInfoManagerImpl implements AssetClassInfoManager { @Autowired private AssetClassInfoRepository assetClassInfoRepository; @Override public Integer save(AssetClassInfo assetClassInfo) { return assetClassInfoRepository.save(assetClassInfo); } @Override public Integer update(AssetClassInfo assetClassInfo) { return assetClassInfoRepository.update(assetClassInfo); } @Override public AssetClassInfo selectById(Long id) { return assetClassInfoRepository.selectById(id); } @Override public List<AssetClassInfo> findList(AssetClassInfo assetClassInfo) { return assetClassInfoRepository.findList(assetClassInfo); } @Override public void initAssetClass(String systemCode) { assetClassInfoRepository.initAssetClass(systemCode); } @Override public void delete(Long id) { assetClassInfoRepository.delete(id); } }
[ "zhengyi@fishcredit.net" ]
zhengyi@fishcredit.net
36342abb1505660c7356acfaf864e1c56d3b49b7
91538018382f7f76870ace15eb293ba4b72b4fb1
/src/main/java/ru/inbox/savinov_vu/processor/SimpleProcessorService.java
23b5e674fbb83c47c838eab42529934b08aaa2f7
[]
no_license
savinovvu/java-console-docker
d3357ba9a55989e7270dd788ae33d4587acef0bb
4c7df2f52559d5f91ffefe7c51a2f5b69727aef0
refs/heads/master
2022-04-19T01:08:13.998755
2020-04-21T07:10:07
2020-04-21T07:10:07
257,509,021
0
0
null
null
null
null
UTF-8
Java
false
false
1,239
java
package ru.inbox.savinov_vu.processor; import java.util.Collection; import java.util.List; import java.util.stream.Collectors; import static ru.inbox.savinov_vu.constants.Constants.SPACE; import static ru.inbox.savinov_vu.constants.Constants.SYMBOL_TO_BUTTON_MAP; import static ru.inbox.savinov_vu.constants.Constants.SYMBOL_TO_CODE_MAP; public class SimpleProcessorService implements ProcessorService { @Override public List<String> process(Collection<String> stringCollection) { return stringCollection.stream().map(this::process).collect(Collectors.toList()); } private String process(String rawString) { char[] nextLineCharArray = rawString.toCharArray(); char previous = nextLineCharArray[0]; StringBuilder sb = new StringBuilder(); sb.append(SYMBOL_TO_CODE_MAP.get(previous)); for (int i = 1; i < nextLineCharArray.length; i++) { char current = nextLineCharArray[i]; if (SYMBOL_TO_BUTTON_MAP.get(previous).equals(SYMBOL_TO_BUTTON_MAP.get(current))) { sb.append(SPACE); } previous = current; sb.append(SYMBOL_TO_CODE_MAP.get(previous)); } return sb.toString(); } }
[ "savinov_vu@inbox.ru" ]
savinov_vu@inbox.ru
c183cccf3b5a2e8b9ad97e6ab61c1bfd11d6d1cd
2f08ebda36c998e3c3f4e4201cbc7351c06b3ee5
/hapi-fhir-base/src/main/java/ca/uhn/fhir/context/RuntimeChildAny.java
a347b471b8a014ae1a80d7b55e2952d5d74233dd
[ "LicenseRef-scancode-warranty-disclaimer", "Apache-2.0" ]
permissive
ekivemark/FHIR-Server
59e4e738cfaa0853734c559e7f9d630a26380773
a83db70fd78ed3fb72175573d7af2e41c7e57925
refs/heads/master
2021-01-14T12:36:25.123885
2015-05-26T00:27:36
2015-05-26T00:27:36
35,138,490
1
1
null
2015-05-12T21:57:50
2015-05-06T03:56:39
Java
UTF-8
Java
false
false
3,039
java
package ca.uhn.fhir.context; /* * #%L * HAPI FHIR - Core Library * %% * Copyright (C) 2014 - 2015 University Health Network * %% * 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. * #L% */ import java.lang.reflect.Field; import java.util.ArrayList; import java.util.Collections; import java.util.Comparator; import java.util.List; import java.util.Map; import org.hl7.fhir.instance.model.IBase; import org.hl7.fhir.instance.model.api.IBaseDatatype; import ca.uhn.fhir.model.api.IDatatype; import ca.uhn.fhir.model.api.IResource; import ca.uhn.fhir.model.api.annotation.Child; import ca.uhn.fhir.model.api.annotation.Description; import ca.uhn.fhir.model.primitive.XhtmlDt; public class RuntimeChildAny extends RuntimeChildChoiceDefinition { public RuntimeChildAny(Field theField, String theElementName, Child theChildAnnotation, Description theDescriptionAnnotation) { super(theField, theElementName, theChildAnnotation, theDescriptionAnnotation); } @Override void sealAndInitialize(FhirContext theContext, Map<Class<? extends IBase>, BaseRuntimeElementDefinition<?>> theClassToElementDefinitions) { List<Class<? extends IBase>> choiceTypes = new ArrayList<Class<? extends IBase>>(); for (Class<? extends IBase> next : theClassToElementDefinitions.keySet()) { if (next.equals(XhtmlDt.class)) { continue; } BaseRuntimeElementDefinition<?> nextDef = theClassToElementDefinitions.get(next); if (nextDef instanceof IRuntimeDatatypeDefinition) { if (((IRuntimeDatatypeDefinition) nextDef).isSpecialization()) { /* * Things like BoundCodeDt shoudn't be considered as valid options for an "any" choice, since * we'll already have CodeDt as an option */ continue; } } if (IResource.class.isAssignableFrom(next) || IDatatype.class.isAssignableFrom(next) || IBaseDatatype.class.isAssignableFrom(next)) { choiceTypes.add(next); } } Collections.sort(choiceTypes,new Comparator<Class<?>>(){ @Override public int compare(Class<?> theO1, Class<?> theO2) { boolean o1res = IResource.class.isAssignableFrom(theO1); boolean o2res = IResource.class.isAssignableFrom(theO2); if (o1res && o2res) { return theO1.getSimpleName().compareTo(theO2.getSimpleName()); } else if (o1res) { return -1; } else if (o1res == false && o2res == false) { return 0; }else { return 1; } }}); setChoiceTypes(choiceTypes); super.sealAndInitialize(theContext, theClassToElementDefinitions); } }
[ "gajen.sunthara@gmail.com" ]
gajen.sunthara@gmail.com
b5f6eeccc1fc656426b758e12c3c6722efdf4621
b9a71bb2805d5f0d5ac98c59d984246463285d34
/testing/drools-master/drools-compiler/src/main/java/org/drools/compiler/lang/descr/FieldConstraintDescr.java
4889e5ad0e83f5068b38d897d9b0595338a225e5
[ "MIT" ]
permissive
rokn/Count_Words_2015
486f3b292954adc76c9bcdbf9a37eb07421ddd2a
e07f6fc9dfceaf773afc0c3a614093e16a0cde16
refs/heads/master
2021-01-10T04:23:49.999237
2016-01-11T19:53:31
2016-01-11T19:53:31
48,538,207
1
1
null
null
null
null
UTF-8
Java
false
false
2,415
java
/* * Copyright 2005 Red Hat, Inc. and/or its affiliates. * * 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.drools.compiler.lang.descr; import java.io.IOException; import java.io.ObjectInput; import java.io.ObjectOutput; import java.util.List; /** * This represents a literal node in the rule language. This is * a constraint on a single field of a pattern. * The "text" contains the content, which may also be an enumeration. */ public class FieldConstraintDescr extends BaseDescr { private static final long serialVersionUID = 510l; private String fieldName; private RestrictionConnectiveDescr restriction = new RestrictionConnectiveDescr( RestrictionConnectiveDescr.AND ); public FieldConstraintDescr() { } public FieldConstraintDescr(final String fieldName) { this.fieldName = fieldName; } @Override public void readExternal( ObjectInput in ) throws IOException, ClassNotFoundException { super.readExternal( in ); this.fieldName = (String) in.readObject(); this.restriction = (RestrictionConnectiveDescr) in.readObject(); } @Override public void writeExternal( ObjectOutput out ) throws IOException { super.writeExternal( out ); out.writeObject(fieldName); out.writeObject( restriction ); } public String getFieldName() { return this.fieldName; } public void addRestriction(final RestrictionDescr restriction) { this.restriction.addRestriction( restriction ); } public List getRestrictions() { return this.restriction.getRestrictions(); } public RestrictionConnectiveDescr getRestriction() { return this.restriction; } @Override public String toString() { return fieldName + " " + restriction; } }
[ "marto_dimitrov@mail.bg" ]
marto_dimitrov@mail.bg
87e39d7641eef5e7514b7dae15f6d86948a24c7b
fd431c99a3cefebe3556fa30ce3768f904128496
/JF-THIRD-PAY/pay_cpmponent_entity/src/main/java/com/pay/business/record/entity/Payv2StatisticsDayWayBean.java
86222380077b7c46969f258e227982df03619ef9
[]
no_license
liushengmz/scpc
d2140cb24d0af16c39e4fef4c0cd1422b144e238
f760bf2c3b1ec45fd06d0d89018a3bfae3c9748c
refs/heads/master
2021-06-19T15:49:59.928248
2018-10-16T08:24:18
2018-10-16T08:24:18
95,423,982
2
4
null
2017-06-28T02:35:14
2017-06-26T08:13:22
null
UTF-8
Java
false
false
852
java
package com.pay.business.record.entity; import java.io.Serializable; import java.util.Date; public class Payv2StatisticsDayWayBean implements Serializable{ private static final long serialVersionUID = 1L; private Integer successCount; private Double successMoney; private Long payId; private String payName; public Integer getSuccessCount() { return successCount; } public void setSuccessCount(Integer successCount) { this.successCount = successCount; } public Double getSuccessMoney() { return successMoney; } public void setSuccessMoney(Double successMoney) { this.successMoney = successMoney; } public String getPayName() { return payName; } public void setPayName(String payName) { this.payName = payName; } public Long getPayId() { return payId; } public void setPayId(Long payId) { this.payId = payId; } }
[ "liushengmz@163.com" ]
liushengmz@163.com