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
ae5836d91458220994ed5f996c3eb5a385e1003f
63de443b4085584967682007c41063efa60d6daa
/com.phponacid.contacts.common/src/main/java/com/phponacid/contacts/common/util/CommonDateUtils.java
6fa426be7d598cd97df90d0e794edd507744b355
[]
no_license
topherPedersen/AlternativeDialerFork
4f28cb061e95e12bf1c3000df4e291df34fe1704
b98e837c1666471fbed69d44548cbcca6e22ca6f
refs/heads/master
2021-01-24T03:48:14.199162
2018-02-26T03:04:54
2018-02-26T03:04:54
122,905,223
2
0
null
null
null
null
UTF-8
Java
false
false
1,494
java
/* * Copyright (C) 2012 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License */ package com.phponacid.contacts.common.util; import java.text.SimpleDateFormat; import java.util.Locale; /** * Common date utilities. */ public class CommonDateUtils { // All the SimpleDateFormats in this class use the UTC timezone public static final SimpleDateFormat NO_YEAR_DATE_FORMAT = new SimpleDateFormat("--MM-dd", Locale.US); public static final SimpleDateFormat FULL_DATE_FORMAT = new SimpleDateFormat("yyyy-MM-dd", Locale.US); public static final SimpleDateFormat DATE_AND_TIME_FORMAT = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSS'Z'", Locale.US); public static final SimpleDateFormat NO_YEAR_DATE_AND_TIME_FORMAT = new SimpleDateFormat("--MM-dd'T'HH:mm:ss.SSS'Z'", Locale.US); /** * Exchange requires 8:00 for birthdays */ public final static int DEFAULT_HOUR = 8; }
[ "15feetaway" ]
15feetaway
28456da8dd555fbbe8f2b6737c186b0c39ac6ae2
f1d20d6c7e6ec5ed491274fcc11e74bb010c57d3
/company-central-service/src/test/java/com/ihappy/stock/infrastructure/service/StockReadInsideRpcServiceTest.java
f1ea119fb528bd130788ddb41e697fd53f0e3989
[]
no_license
P79N6A/company-central
79273c8e90732cf73f2f8b08c006654809e08736
f1a83f62a5cf41f8bfcf79c708a54d736fb1a46b
refs/heads/master
2020-04-12T02:41:38.769868
2018-12-18T07:45:31
2018-12-18T07:45:55
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,141
java
package com.ihappy.stock.infrastructure.service; import com.alibaba.fastjson.JSON; import com.ihappy.BaseTest; import com.ihappy.stock.domain.dto.request.stock.StockMapByUserInfoQueryReqDTO; import com.ihappy.stock.domain.dto.response.stock.StockListByStoreIdsQueryRespDTO; import com.ihappy.unifiedLog.module.Result; import org.junit.Test; /** * Created by sunjd on 2018/5/24. */ public class StockReadInsideRpcServiceTest extends BaseTest { @Test public void getStockMapByUserInfo() throws Exception { StockReadInsideRpcService service = getBean("stockReadInsideRpcService"); StockMapByUserInfoQueryReqDTO reqDTO = new StockMapByUserInfoQueryReqDTO(); reqDTO.setCompId(1L); reqDTO.setIsPublic(null); reqDTO.setPersonId(219L); Result<StockListByStoreIdsQueryRespDTO> res = service.getStockMapByUserInfo(reqDTO); System.out.println(JSON.toJSONString(res.getModule())); System.out.println(JSON.toJSONString(res.isSuccess())); System.out.println(JSON.toJSONString(res.getErrCode())); System.out.println(JSON.toJSONString(res.getErrMsg())); } }
[ "zhangmengdan@ihappy.net.cn" ]
zhangmengdan@ihappy.net.cn
fd378011ded5d58617258712fb2d2c39be46cb56
37df4f2ef694b4459e49ddda8e8d478a24d1723f
/random-beans/src/test/java/io/github/benas/randombeans/beans/TestData.java
aeac25cc1867c90555c952856b59fc7f50a5d240
[ "MIT" ]
permissive
weronika-redlarska/random-beans
334b2001c9d67a2d04c5c284052ca7f74ffb5165
e9a962d0dde06d29f7fae4c6df086c5a8dd32c72
refs/heads/master
2020-04-19T17:42:22.705527
2019-01-30T13:05:36
2019-01-30T13:05:36
168,342,693
0
0
null
2019-01-30T12:53:57
2019-01-30T12:53:57
null
UTF-8
Java
false
false
2,214
java
/** * The MIT License * * Copyright (c) 2019, Mahmoud Ben Hassine (mahmoud.benhassine@icloud.com) * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Software without restriction, including without limitation the rights * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell * copies of the Software, and to permit persons to whom the Software is * furnished to do so, subject to the following conditions: * * The above copyright notice and this permission notice shall be included in * all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN * THE SOFTWARE. */ package io.github.benas.randombeans.beans; import io.github.benas.randombeans.annotation.Randomizer; import io.github.benas.randombeans.annotation.RandomizerArgument; import io.github.benas.randombeans.randomizers.range.DateRangeRandomizer; import io.github.benas.randombeans.randomizers.range.IntegerRangeRandomizer; import java.util.Date; public class TestData { public TestData() { } @Randomizer(value = DateRangeRandomizer.class, args = { @RandomizerArgument(value = "2016-01-10 00:00:00", type = Date.class), @RandomizerArgument(value = "2016-01-30 23:59:59", type = Date.class) }) private Date date; @Randomizer(value = IntegerRangeRandomizer.class, args = { @RandomizerArgument(value = "200", type = Integer.class), @RandomizerArgument(value = "500", type = Integer.class) }) private int price; public Date getDate() { return date; } public int getPrice() { return price; } }
[ "mahmoud.benhassine@icloud.com" ]
mahmoud.benhassine@icloud.com
169cb6d63b1e70301e4dbfee86cf911e6ab397ef
5593669533a9933c03540388c028975619b75214
/src/main/java/top/zywork/service/AccountDetailService.java
bc57d94b76d4bb5158330cced472264481e53d8f
[]
no_license
xiaopohou/zywork-app
a23d71e4727864579156e16b3cd7d44b1aae795a
7ccdabaa2e6e08c9147e2913bd42ff0cdea2ae17
refs/heads/master
2020-06-02T23:00:57.539911
2019-06-10T09:35:40
2019-06-10T09:35:40
null
0
0
null
null
null
null
UTF-8
Java
false
false
241
java
package top.zywork.service; /** * AccountDetailService服务接口<br/> * * 创建于2018-12-25<br/> * * @author http://zywork.top 王振宇 * @version 1.0 */ public interface AccountDetailService extends BaseService { }
[ "847315251@qq.com" ]
847315251@qq.com
7bc2a47ef87f9496689ba90ec7888b030d9aa4ed
49c35e5a9b1d499009acb78c9a1bf4cf08739142
/hellodb_2/src/main/java/pl/edu/agh/iisg/bd213lg/hellodb/dao/generic/DAO.java
87cd9d2958a52c1af3138e534aacc551a1d8206a
[]
no_license
marcinlos/db2
bd2bfc6b70af6ca0235cd35ed2302bafe22a3e41
6afa30180f6e5ec155350270f9783105f63eb2e8
refs/heads/master
2021-01-23T17:19:11.193670
2013-06-16T19:48:06
2013-06-16T19:48:06
null
0
0
null
null
null
null
UTF-8
Java
false
false
463
java
package pl.edu.agh.iisg.bd213lg.hellodb.dao.generic; import java.io.Serializable; import java.util.Collection; import org.hibernate.criterion.Criterion; public interface DAO<T, Id extends Serializable> { T find(Id id); Collection<T> findAll(); Collection<T> findByExample(T example, String... excludes); Collection<T> findByCriteria(Criterion... criterion); void save(T entity); void delete (T entity); }
[ "losiu99@gazeta.pl" ]
losiu99@gazeta.pl
5a9c2d0d97e44bc4d9898e9e0e4a1c23a16a0f6e
aaba5757aac5d1122e295d837cd3846748907c06
/usg-server/src/main/java/com/accure/pension/service/PensionBankService.java
f5f98c7abc9696a0faf2d099ff34247bb952904d
[]
no_license
usgInfo/UsgServerProject
3845ef95595d9cd24285ac25c9164fc435494ad5
a81df8ec3ef2b298acd0627e414825ddc71fc43b
refs/heads/master
2021-05-15T00:35:02.159785
2018-03-21T13:17:26
2018-03-21T13:17:26
103,244,787
0
0
null
null
null
null
UTF-8
Java
false
false
4,333
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.accure.pension.service; import com.accure.pension.dto.PensionBank; import com.accure.pension.manager.PensionBankManager; import com.accure.usg.common.manager.SessionManager; import com.accure.usg.server.utils.ApplicationConstants; import com.google.gson.Gson; import com.google.gson.reflect.TypeToken; import java.io.IOException; import java.io.PrintWriter; import java.io.StringWriter; import java.lang.reflect.Type; import javax.servlet.ServletException; import javax.servlet.http.HttpServlet; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpSession; /** * * @author user */ public class PensionBankService extends HttpServlet { /** * Processes requests for both HTTP <code>GET</code> and <code>POST</code> * methods. * * @param request servlet request * @param response servlet response * @throws ServletException if a servlet-specific error occurs * @throws IOException if an I/O error occurs */ protected void processRequest(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { response.setContentType("text/json;charset=UTF-8"); PrintWriter out = response.getWriter(); try { HttpSession session = request.getSession(false); if (SessionManager.checkUserSession(session)) { String bankJson = request.getParameter("bankJson"); String userid = request.getParameter("userid"); Type type = new TypeToken<PensionBank>() { }.getType(); PensionBank bank = new Gson().fromJson(bankJson, type); String result = new PensionBankManager().save(bank, userid); if (result != null && !result.isEmpty()) { request.setAttribute("statuscode", ApplicationConstants.HTTP_STATUS_SUCCESS); out.write(new Gson().toJson(result)); } else { request.setAttribute("statuscode", ApplicationConstants.HTTP_STATUS_FAIL); out.write(new Gson().toJson(ApplicationConstants.HTTP_STATUS_FAIL)); } } else { request.setAttribute("statuscode", ApplicationConstants.HTTP_STATUS_INVALID_SESSION); out.write(new Gson().toJson(ApplicationConstants.HTTP_STATUS_INVALID_SESSION)); } } catch (Exception ex) { request.setAttribute("statuscode", ApplicationConstants.HTTP_STATUS_EXCEPTION); StringWriter stack = new StringWriter(); ex.printStackTrace(new PrintWriter(stack)); out.write(new Gson().toJson(ApplicationConstants.HTTP_STATUS_EXCEPTION)); } finally { out.close(); } } // <editor-fold defaultstate="collapsed" desc="HttpServlet methods. Click on the + sign on the left to edit the code."> /** * Handles the HTTP <code>GET</code> method. * * @param request servlet request * @param response servlet response * @throws ServletException if a servlet-specific error occurs * @throws IOException if an I/O error occurs */ @Override protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { processRequest(request, response); } /** * Handles the HTTP <code>POST</code> method. * * @param request servlet request * @param response servlet response * @throws ServletException if a servlet-specific error occurs * @throws IOException if an I/O error occurs */ @Override protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { processRequest(request, response); } /** * Returns a short description of the servlet. * * @return a String containing servlet description */ @Override public String getServletInfo() { return "Short description"; }// </editor-fold> }
[ "31878742+usgInfo@users.noreply.github.com" ]
31878742+usgInfo@users.noreply.github.com
19ba83849bc50755ba92b32de873c9907ec2b2e8
7a21ff93edba001bef328a1e927699104bc046e5
/project-parent/module-parent/core-module-parent/water-core/src/main/java/com/dotop/smartwater/project/module/core/water/form/SmsConfigForm.java
a541a39fb8b6bdeeb6207037c685607e2d3b1918
[]
no_license
150719873/zhdt
6ea1ca94b83e6db2012080f53060d4abaeaf12f5
c755dacdd76b71fd14aba5e475a5862a8d92c1f6
refs/heads/master
2022-12-16T06:59:28.373153
2020-09-14T06:57:16
2020-09-14T06:57:16
299,157,259
1
0
null
2020-09-28T01:45:10
2020-09-28T01:45:10
null
UTF-8
Java
false
false
699
java
package com.dotop.smartwater.project.module.core.water.form; import com.dotop.smartwater.dependence.core.common.BaseForm; import lombok.Data; import lombok.EqualsAndHashCode; /** * 短信绑定 * * @date 2019年2月23日 */ @Data @EqualsAndHashCode(callSuper = true) public class SmsConfigForm extends BaseForm { /** * 配置id */ private String id; /** * 名称 */ private String name; private String code; /** * 签名 */ private String sign; private String mkey; private String mkeysecret; /** * 状态 0 启用 1 禁用 */ private Integer status; /** * 备注 */ private String remarks; /** * 0:正常,1:删除 */ private String isDel; }
[ "2216502193@qq.com" ]
2216502193@qq.com
812b9b9403270089ece5a287a5e6399b9937505e
8e94005abdd35f998929b74c19a86b7203c3dbbc
/src/interval/Interval.java
3dff3d2e0ef2e8e6a5baace5d5698f59baba6a6b
[]
no_license
tinapgaara/leetcode
d1ced120da9ca74bfc1712c4f0c5541ec12cf980
8a93346e7476183ecc96065062da8585018b5a5b
refs/heads/master
2020-12-11T09:41:39.468895
2018-04-24T07:15:27
2018-04-24T07:15:27
43,688,533
1
0
null
null
null
null
UTF-8
Java
false
false
233
java
package interval; /** * Created by yingtan on 9/23/15. */ public class Interval { public int start; public int end; public Interval() { start = 0; end = 0; } public Interval(int s, int e) { start = s; end = e; } }
[ "yt2443@columbia.edu" ]
yt2443@columbia.edu
a409e2bdc78e69e9d7caf38e605ff5b6d2376627
6b27f17daa8ba1477acd6fe687410827c902aaab
/Lab 05/05_CacheRedis/src/br/com/fiap/service/IProdutoService.java
5f9378244fc79adee94ef3458eee7493fd17dcee
[]
no_license
rornellas/FIAP-2019-SCJ-JavaPersistence
975805ba323caf1102386632f6cb28885e415944
b3dffc5c4906059919313716824c41546063a4fe
refs/heads/master
2020-09-19T21:32:40.692348
2019-11-27T01:38:32
2019-11-27T01:38:32
224,303,065
0
0
null
2019-11-26T23:14:31
2019-11-26T23:14:30
null
UTF-8
Java
false
false
373
java
package br.com.fiap.service; import java.util.List; import br.com.fiap.entity.Produto; public interface IProdutoService { List<Produto> getAllProdutos(); Produto getProdutoById(long id); Produto addProduto(Produto produto); Produto updateProduto(Produto produto); void deleteProduto(long id); List<Produto> getProdutosByTipo(Integer tipo); }
[ "logonaluno@local.com" ]
logonaluno@local.com
e7a740a6b686a060f53efc4915ba81d2a259ef09
e951240dae6e67ee10822de767216c5b51761bcb
/src/main/java/algorithms/leetcode/leetcode_20181226/linkedlist/LC_83_Remove_Duplicates_from_Sorted_List.java
4f83617254cbf3244e0d2ad4738d311aa2137cc8
[]
no_license
fengjiny/practice
b1315ca8800ba25b5d6fed64b0d68d870d84d1bb
898e635967f3387dc870c1ee53a95ba8a37d5e37
refs/heads/master
2021-06-03T09:20:35.904702
2020-10-26T10:45:03
2020-10-26T10:45:03
131,289,290
0
0
null
null
null
null
UTF-8
Java
false
false
670
java
package algorithms.leetcode.leetcode_20181226.linkedlist; public class LC_83_Remove_Duplicates_from_Sorted_List { public ListNode deleteDuplicates(ListNode head) { if (head == null || head.next == null) return head; head.next = deleteDuplicates(head.next); return head.val == head.next.val ? head.next : head; } public ListNode deleteDuplicates_(ListNode head) { ListNode cur = head; while (cur != null && cur.next != null) { if (cur.val == cur.next.val) { cur.next = cur.next.next; } else { cur = cur.next; } } return head; } }
[ "fengjinyu@mobike.com" ]
fengjinyu@mobike.com
78a11a42f2b4093a311d29415aca31103ddc43bf
2f768e1a547baac6d98bb335b5fde3cc33596ea9
/src/main/java/com/test/test/Validation.java
0c1cff60b7d9114c6073354679642c854d0d592f
[]
no_license
balukasik/AllegroTask
abdb79579ce82226c485c64666b20e624f0e54f7
31b8712fe18524d167a7ea68ec1df3a32c34fc80
refs/heads/master
2023-04-10T12:57:50.773808
2021-04-25T18:50:40
2021-04-25T18:50:40
360,695,663
1
0
null
2021-04-25T18:46:35
2021-04-22T22:17:49
Java
UTF-8
Java
false
false
838
java
package com.test.test; import org.springframework.web.client.HttpClientErrorException; public class Validation { public static final String urlTemplate = "https://api.github.com/users/%s/repos?per_page=100&page=%d"; public static final String urlGithubApiLimit = "https://docs.github.com/rest/overview/resources-in-the-rest-api#rate-limiting"; public static void validateUser(String user) { if (user.length() == 0) { throw new UserNotSpecifiedException(user); } else if (user.length() > 40) { throw new UserNotFoundException(user); } } public static void githubError(HttpClientErrorException e, String user) { if (e.getResponseBodyAsString() .contains(urlGithubApiLimit)) { throw new LimitExceededException("Too many request, check "+ urlGithubApiLimit); } throw new UserNotFoundException(user); } }
[ "you@example.com" ]
you@example.com
67e58f878134d2291c8e69b003e152a0de71ed6a
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/5/5_864082cf7de28f24f4aef60940f8ce8e9c2c5319/DateUtility/5_864082cf7de28f24f4aef60940f8ce8e9c2c5319_DateUtility_t.java
b31b52fb8d8e196b08143eb74d7f8dda8be39405
[]
no_license
zhongxingyu/Seer
48e7e5197624d7afa94d23f849f8ea2075bcaec0
c11a3109fdfca9be337e509ecb2c085b60076213
refs/heads/master
2023-07-06T12:48:55.516692
2023-06-22T07:55:56
2023-06-22T07:55:56
259,613,157
6
2
null
2023-06-22T07:55:57
2020-04-28T11:07:49
null
UTF-8
Java
false
false
4,931
java
package fedora.server.utilities; /** * <p>Title: DateUtility.java</p> * <p>Description: A collection of utility methods for performing</p> * <p>frequently require tasks.</p> * <p>Copyright: Copyright (c) 2002</p> * <p>Company: </p> * @author Ross Wayland * @version 1.0 */ import java.text.SimpleDateFormat; import java.text.ParsePosition; import java.util.Calendar; import java.util.Date; public abstract class DateUtility { private static final boolean debug = true; //Testing private static final SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss"); /** * Converts a datetime string into and instance of java.util.Calendar using * the date format: yyyy-MM-ddTHH:mm:ss * * @param dateTime A datetime string * @return Corresponding instance of java.util.Calendar (returns null * if dateTime string argument is empty string or null) */ public static Calendar convertStringToCalendar(String dateTime) { Calendar calendar = null; if (!(dateTime == null) && !dateTime.equalsIgnoreCase("")) { calendar = Calendar.getInstance(); ParsePosition pos = new ParsePosition(0); Date date = formatter.parse(dateTime, pos); calendar.setTime(date); } return(calendar); } /** * Converts a datetime string into and instance of java.util.Date using * the date format: yyyy-MM-ddTHH:mm:ss * * @param dateTime A datetime string * @return Corresponding instance of java.util.Date (returns null * if dateTime string argument is empty string or null) */ public static Date convertStringToDate(String dateTime) { Date date = null; if (!(dateTime == null) && !dateTime.equalsIgnoreCase("")) { ParsePosition pos = new ParsePosition(0); date = formatter.parse(dateTime, pos); } return(date); } /** * Converts an instance of java.util.Calendar into a string using * the date format: yyyy-MM-ddTHH:mm:ss * * @param calendar An instance of java.util.Calendar * @return Corresponding datetime string (returns null if Calendar * argument is null) */ public static String convertCalendarToString(Calendar calendar) { String dateTime = null; if (!(calendar == null)) { Date date = calendar.getTime(); dateTime = formatter.format(date); } return(dateTime); } /** * Converts an instance of java.util.Date into a String using * the date format: yyyy-MM-ddTHH:mm:ss * * @param date Instance of java.util.Date * @return Corresponding datetime string (returns null if Date argument * is null) */ public static String convertDateToString(Date date) { String dateTime = null; if (!(date == null)) { dateTime = formatter.format(date); } return(dateTime); } /** * Converts an instance of java.util.Calendar into and instance * of java.util.Date. * * @param calendar Instance of java.util.Calendar * @return Corresponding instance of java.util.Date (returns null * if Calendar argument is null) */ public static Date convertCalendarToDate(Calendar calendar) { Date date = null; if(!(calendar == null)) { date = calendar.getTime(); } return(date); } /** * Converts an instance of java.util.Date into an instance * of java.util.Calendar. * * @param date Instance of java.util.Date * @return Corresponding instance of java.util.Calendar (returns null * if Date argument is null) */ public static Calendar convertDateToCalendar(Date date) { Calendar calendar = null; if (!(date == null)) { calendar = Calendar.getInstance(); ParsePosition pos = new ParsePosition(0); calendar.setTime(date); } return(calendar); } public static void main(String[] args) { String dateTimeString = "2002-08-22T13:58:06"; Calendar cal = convertStringToCalendar(dateTimeString); System.out.println("DateString: "+dateTimeString+"\nConvertCalendarToString: "+cal); Date date = convertStringToDate(dateTimeString); System.out.println("\nDateString: "+dateTimeString+"\nConvertDateToString: "+ convertDateToString(date)); System.out.println("\nCalendar: "+cal+"\nConvertCalendarToString: "+ convertCalendarToString(cal)); System.out.println("\nDate: "+convertDateToString(date)+"\nConvertDateT0String: "+ convertDateToString(date)); System.out.println("\nCalendar: "+cal+"\nConvertCalendarToDate: "+ convertDateToString(convertCalendarToDate(cal))); System.out.println("\nDate: "+convertDateToString(date)+ "\nConvertDateToCalendar: "+convertDateToCalendar(date)); } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
d2c0911e6bf139b18181b25539eae0277c3588e1
e5fdec9df80b4958f49250f90fd05c13e3bda8b7
/org.servicifi.gelato.language.cobol/src-gen/org/servicifi/gelato/language/cobol/water/RepositoryDescriptionInfo.java
e6ac5b5c55ace569af4e7df6aa97558280fd96e4
[]
no_license
amirms/gelato
9125e6ac3a56e5bcfd032db855a4c269bdfc5152
972d7309dc37c57d17d2b1486a49f00830983eb8
refs/heads/master
2021-06-03T22:07:12.010077
2019-03-10T11:54:27
2019-03-10T11:54:27
27,443,539
0
0
null
null
null
null
UTF-8
Java
false
false
5,009
java
/** */ package org.servicifi.gelato.language.cobol.water; import java.util.Arrays; import java.util.Collections; import java.util.List; import org.eclipse.emf.common.util.Enumerator; /** * <!-- begin-user-doc --> * A representation of the literals of the enumeration '<em><b>Repository Description Info</b></em>', * and utility methods for working with them. * <!-- end-user-doc --> * @see org.servicifi.gelato.language.cobol.water.WaterPackage#getRepositoryDescriptionInfo() * @model * @generated */ public enum RepositoryDescriptionInfo implements Enumerator { /** * The '<em><b>Class</b></em>' literal object. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @see #CLASS_VALUE * @generated * @ordered */ CLASS(0, "class", "CLASS"), /** * The '<em><b>Is</b></em>' literal object. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @see #IS_VALUE * @generated * @ordered */ IS(1, "is", "IS"); /** * The '<em><b>Class</b></em>' literal value. * <!-- begin-user-doc --> * <p> * If the meaning of '<em><b>Class</b></em>' literal object isn't clear, * there really should be more of a description here... * </p> * <!-- end-user-doc --> * @see #CLASS * @model name="class" literal="CLASS" * @generated * @ordered */ public static final int CLASS_VALUE = 0; /** * The '<em><b>Is</b></em>' literal value. * <!-- begin-user-doc --> * <p> * If the meaning of '<em><b>Is</b></em>' literal object isn't clear, * there really should be more of a description here... * </p> * <!-- end-user-doc --> * @see #IS * @model name="is" literal="IS" * @generated * @ordered */ public static final int IS_VALUE = 1; /** * An array of all the '<em><b>Repository Description Info</b></em>' enumerators. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ private static final RepositoryDescriptionInfo[] VALUES_ARRAY = new RepositoryDescriptionInfo[] { CLASS, IS, }; /** * A public read-only list of all the '<em><b>Repository Description Info</b></em>' enumerators. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public static final List<RepositoryDescriptionInfo> VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY)); /** * Returns the '<em><b>Repository Description Info</b></em>' literal with the specified literal value. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @param literal the literal. * @return the matching enumerator or <code>null</code>. * @generated */ public static RepositoryDescriptionInfo get(String literal) { for (int i = 0; i < VALUES_ARRAY.length; ++i) { RepositoryDescriptionInfo result = VALUES_ARRAY[i]; if (result.toString().equals(literal)) { return result; } } return null; } /** * Returns the '<em><b>Repository Description Info</b></em>' literal with the specified name. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @param name the name. * @return the matching enumerator or <code>null</code>. * @generated */ public static RepositoryDescriptionInfo getByName(String name) { for (int i = 0; i < VALUES_ARRAY.length; ++i) { RepositoryDescriptionInfo result = VALUES_ARRAY[i]; if (result.getName().equals(name)) { return result; } } return null; } /** * Returns the '<em><b>Repository Description Info</b></em>' literal with the specified integer value. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @param value the integer value. * @return the matching enumerator or <code>null</code>. * @generated */ public static RepositoryDescriptionInfo get(int value) { switch (value) { case CLASS_VALUE: return CLASS; case IS_VALUE: return IS; } return null; } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ private final int value; /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ private final String name; /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ private final String literal; /** * Only this class can construct instances. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ private RepositoryDescriptionInfo(int value, String name, String literal) { this.value = value; this.name = name; this.literal = literal; } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public int getValue() { return value; } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public String getName() { return name; } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public String getLiteral() { return literal; } /** * Returns the literal value of the enumerator, which is its string representation. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override public String toString() { return literal; } } //RepositoryDescriptionInfo
[ "amir.iust@gmail.com" ]
amir.iust@gmail.com
6686333b673f390115593c3dd3e75303cd7c4732
303328efea97b5071895737ec8458e37af411d3d
/src/com/javarush/test/level13/lesson04/task01/Solution.java
060b602026beecd2983f5a4fd959119fd310c009
[]
no_license
glebfox/JavaRushHomeWork
831cc55fcdabe29a571b103c5f95a47ab412cf20
53ca64cddd3d3db9a7943e09ad3626b9f31d13bb
refs/heads/master
2020-06-03T00:26:09.468926
2015-02-17T10:01:31
2015-02-17T10:01:31
30,911,483
0
0
null
null
null
null
UTF-8
Java
false
false
1,163
java
package com.javarush.test.level13.lesson04.task01; /* Переводчик с английского 1. Создать класс EnglishTranslator, который наследуется от Translator. 2. Реализовать все абстрактные методы. 3. Подумай, что должен возвращать метод getLanguage. 4. Программа должна выводить на экран "Я переводчик с английского". 5. Метод main менять нельзя. */ public class Solution { public static void main(String[] args) throws Exception { EnglishTranslator englishTranslator = new EnglishTranslator(); System.out.println(englishTranslator.translate()); } public static abstract class Translator { public abstract String getLanguage(); public String translate() { return "Я переводчик с " + getLanguage(); } } public static class EnglishTranslator extends Translator { @Override public String getLanguage() { return "английского"; } } }
[ "glebfox@gmail.com" ]
glebfox@gmail.com
6770760ac506033dfee180fbbb7a1f1266118d05
1930d97ebfc352f45b8c25ef715af406783aabe2
/src/main/java/com/alipay/api/domain/ZhimaMerchantContractOnofferQueryModel.java
48d2c31df06d97d74c8709650e37f1585e8e998d
[ "Apache-2.0" ]
permissive
WQmmm/alipay-sdk-java-all
57974d199ee83518523e8d354dcdec0a9ce40a0c
66af9219e5ca802cff963ab86b99aadc59cc09dd
refs/heads/master
2023-06-28T03:54:17.577332
2021-08-02T10:05:10
2021-08-02T10:05:10
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,306
java
package com.alipay.api.domain; import com.alipay.api.AlipayObject; import com.alipay.api.internal.mapping.ApiField; /** * 芝麻约定按发约单号查询合约接口 * * @author auto create * @since 1.0, 2021-05-17 10:39:20 */ public class ZhimaMerchantContractOnofferQueryModel extends AlipayObject { private static final long serialVersionUID = 5223496436729862131L; /** * 发约单单号 */ @ApiField("offer_no") private String offerNo; /** * 应约者id(淘宝id/支付宝user_id) */ @ApiField("sign_principal_id") private String signPrincipalId; /** * 应约者类型:ZHIMA_ROLE:芝麻用户 ALIPAY_ROLE:支付宝用户 TAOBAO_ROLE:淘宝用户 */ @ApiField("sign_principal_type") private String signPrincipalType; public String getOfferNo() { return this.offerNo; } public void setOfferNo(String offerNo) { this.offerNo = offerNo; } public String getSignPrincipalId() { return this.signPrincipalId; } public void setSignPrincipalId(String signPrincipalId) { this.signPrincipalId = signPrincipalId; } public String getSignPrincipalType() { return this.signPrincipalType; } public void setSignPrincipalType(String signPrincipalType) { this.signPrincipalType = signPrincipalType; } }
[ "ben.zy@antfin.com" ]
ben.zy@antfin.com
54d13f2d19cf0f504a8a54b01f511497fdfb7d11
0c39b468aab694abbc228a025c921418041926d7
/Spring Lab15/src/com/jlcindia/spring/Lab15.java
dc4bfa6b8e114592fd697d8b7c6994630fa16e4e
[]
no_license
jitendrakr93/JLC_ALL_PROGRAMS
17cfc903c8e5befe2fe50ae89d874b53cf6e748f
eb9748a94e4a70e2504a3007624b83ca2fcd7078
refs/heads/master
2023-07-02T17:38:27.603260
2021-08-05T05:34:22
2021-08-05T05:34:22
392,905,494
0
0
null
null
null
null
UTF-8
Java
false
false
381
java
package com.jlcindia.spring; import org.springframework.context.ApplicationContext; import org.springframework.context.annotation.AnnotationConfigApplicationContext; public class Lab15 { public static void main(String[] args) { ApplicationContext ctx=new AnnotationConfigApplicationContext(JlcConfig.class); Hello hello=(Hello) ctx.getBean("hello"); hello.show(); } }
[ "jk93.161@gmail.com" ]
jk93.161@gmail.com
954036aaf53d093483c8f658370681a96207bcb7
b94397fa7462c5861f85facd575aae543749daf5
/src/com/stanley/taiweidata/TaiWeiAllDataAction_QD.java
b3b78aa2ffc7f78adc6f44905f89764ec2d3172b
[]
no_license
sunmh207/TrainMap_JN
4fcf0d6b705024774a2e38a4898734647f58e545
124afab9fae2a3264f10d5fb776862784fc2ae43
refs/heads/master
2020-04-14T10:20:35.836600
2014-03-22T13:50:37
2014-03-22T13:50:37
null
0
0
null
null
null
null
UTF-8
Java
false
false
6,052
java
package com.stanley.taiweidata; import java.util.ArrayList; import java.util.Iterator; import java.util.List; import java.util.Map; import java.util.Set; import java.util.TreeMap; import com.jitong.common.action.JITActionBase; import com.jitong.common.exception.JTException; import com.jitong.common.util.DateUtil; import com.opensymphony.xwork2.Preparable; import com.stanley.Gudao; import com.stanley.JicheYunxingInfo; import com.stanley.TaiWei; import com.stanley.TaiWeiAll; import com.stanley.TaiWeiManager; import com.stanley.TaiWeiManager_QD; import com.stanley.locomotivedict.LocomotiveService; public class TaiWeiAllDataAction_QD extends JITActionBase implements Preparable { private TaiWeiManager_QD svr_qd; private TaiWeiManager svr; private LocomotiveService locoSvr; //private TaiWeiAll taiweiall; private Gudao gudao; private String gdName; private String CH; private JicheYunxingInfo jicheYunxingInfo; private List<String> locoList; private Map<String,String> locoWithoutTaiweiMap; private Map<String,String> gdNameWithoutLocoMap; private String newGDName; private String qryGDName; private String qryCH; public void prepare() throws JTException { if (svr_qd == null) { svr_qd = new TaiWeiManager_QD(); } if (svr == null) { svr = new TaiWeiManager(); } if (locoSvr == null) { locoSvr = new LocomotiveService(); } if (gdName != null&& !"".equals(gdName)) { gudao = svr_qd.findGudaoByGDName(gdName); } } public String forMove() { try{ List<Object> emptyTaiweis= svr_qd.queryByHql("from TaiWeiAll where currentCH is null and didian='青岛' order by gdName"); gdNameWithoutLocoMap = new TreeMap<String,String>(); for(Object o:emptyTaiweis){ gdNameWithoutLocoMap.put(((TaiWeiAll)o).getGdName(), ((TaiWeiAll)o).getGdName()); } }catch(Exception e){ this.logger.error(e.getClass()); } return "move"; } public String input(){ try{ //locoList=locoSvr.queryLocalLocoList("青岛"); locoList=locoSvr.queryLocalLocoList(); locoWithoutTaiweiMap = new TreeMap<String,String>(); for(String ch:locoList){ locoWithoutTaiweiMap.put(ch,ch); } Set<TaiWei> taiweialls=svr.queryTaiWeis(); Iterator<TaiWei> it =taiweialls.iterator(); while(it.hasNext()){ TaiWei t=it.next(); locoWithoutTaiweiMap.remove(t.getCurrentCH()); } }catch(Exception e){ this.logger.error(e.getClass()); } return INPUT; } public String save() throws Exception { try { if(gudao!=null){ gudao.setCH(CH); gudao.setLastUpdate(DateUtil.getCurrentTime()); svr_qd.updateBo(gudao); jicheYunxingInfo = svr_qd.findJicheYunxingInfoByCH(CH); if(jicheYunxingInfo==null){ jicheYunxingInfo=new JicheYunxingInfo(); jicheYunxingInfo.setCH(CH); svr_qd.createBo(jicheYunxingInfo); } } } catch (Exception e) { this.addActionError(e.getMessage()); return INPUT; } return SUCCESS; } public String move() throws Exception { try { Gudao oldGudao = svr_qd.findGudaoByGDName(gdName); if(oldGudao!=null){ oldGudao.setCH(null); oldGudao.setLastUpdate(DateUtil.getCurrentTime()); svr_qd.updateBo(oldGudao); } Gudao newGudao = svr_qd.findGudaoByGDName(newGDName); if(newGudao!=null){ newGudao.setCH(CH); newGudao.setLastUpdate(DateUtil.getCurrentTime()); svr_qd.updateBo(newGudao); }else{ this.addActionError(newGudao+"股道不存在"); } } catch (Exception e) { this.addActionError(e.getMessage()); return INPUT; } return SUCCESS; } public String deleteLoco() throws Exception { try { if(gudao!=null){ gudao.setCH(null); gudao.setLastUpdate(DateUtil.getCurrentTime()); svr_qd.updateBo(gudao); /*jicheYunxingInfo = svr.findJicheYunxingInfoByCH(CH); if(jicheYunxingInfo!=null){ svr.deleteBo(JicheYunxingInfo.class,jicheYunxingInfo.getId()); }*/ } } catch (Exception e) { this.addActionError(e.getMessage()); } return list(); } /*public String getListHQL(ArrayList<Object> params) throws JTException { return "from TaiWeiAll where didian='青岛' order by gdName"; }*/ public String getListHQL(ArrayList<Object> params) throws JTException { StringBuffer hqlb=new StringBuffer("from TaiWeiAll where didian='青岛'"); if(qryGDName!=null&&!qryGDName.trim().equals("")){ hqlb.append(" and gdName like '%"+qryGDName+"%'"); } if(qryCH!=null&&!qryCH.trim().equals("")){ hqlb.append(" and currentCH like '%"+qryCH+"%'"); } return hqlb.append(" order by gdName").toString(); } public Gudao getGudao() { return gudao; } public void setGudao(Gudao gudao) { this.gudao = gudao; } public String getGdName() { return gdName; } public void setGdName(String gdName) { this.gdName = gdName; } public String getCH() { return CH; } public void setCH(String cH) { CH = cH; } public JicheYunxingInfo getJicheYunxingInfo() { return jicheYunxingInfo; } public void setJicheYunxingInfo(JicheYunxingInfo jicheYunxingInfo) { this.jicheYunxingInfo = jicheYunxingInfo; } public List<String> getLocoList() { return locoList; } public void setLocoList(List<String> locoList) { this.locoList = locoList; } public Map<String, String> getLocoWithoutTaiweiMap() { return locoWithoutTaiweiMap; } public void setLocoWithoutTaiweiMap(Map<String, String> locoWithoutTaiweiMap) { this.locoWithoutTaiweiMap = locoWithoutTaiweiMap; } public Map<String, String> getGdNameWithoutLocoMap() { return gdNameWithoutLocoMap; } public void setGdNameWithoutLocoMap(Map<String, String> gdNameWithoutLocoMap) { this.gdNameWithoutLocoMap = gdNameWithoutLocoMap; } public String getNewGDName() { return newGDName; } public void setNewGDName(String newGDName) { this.newGDName = newGDName; } public String getQryGDName() { return qryGDName; } public void setQryGDName(String qryGDName) { this.qryGDName = qryGDName; } public String getQryCH() { return qryCH; } public void setQryCH(String qryCH) { this.qryCH = qryCH; } }
[ "stanley.java@gmail.com" ]
stanley.java@gmail.com
60262841ddfa817c2a5fb92ed5cdbed18141e8c3
b108b825ffdec76a6bd945e2911277959a33a6eb
/wyzsb/src/main/java/view/lcc/wyzsb/view/home/GildeImageView/GlideImageLoader.java
dba1c93ec9831977356b2f5b7a362d1c7ad132d0
[]
no_license
liangchengcheng/ZSBPJ
87ba63f589121821697e5c8c90e9820484aa5762
5e48b3bef2b88d8dec9bce605681c3336c9e46c3
refs/heads/master
2020-04-04T05:50:55.475814
2018-12-12T07:49:13
2018-12-12T07:49:13
48,907,404
2
1
null
null
null
null
UTF-8
Java
false
false
4,181
java
package view.lcc.wyzsb.view.home.GildeImageView; import android.net.Uri; import android.support.annotation.IdRes; import android.text.TextUtils; import android.widget.ImageView; import com.bumptech.glide.DrawableRequestBuilder; import com.bumptech.glide.Glide; import com.bumptech.glide.load.engine.DiskCacheStrategy; import com.bumptech.glide.load.resource.drawable.GlideDrawable; import com.bumptech.glide.request.RequestListener; import com.bumptech.glide.request.target.Target; /** * Created by sunfusheng on 2017/1/23. */ public class GlideImageLoader { public static final String ANDROID_RESOURCE = "android.resource://"; public static final String SEPARATOR = "/"; private ImageView mImageView; public GlideImageLoader(ImageView view) { mImageView = view; } // 将资源ID转为Uri public Uri resIdToUri(int resourceId) { return Uri.parse(ANDROID_RESOURCE + mImageView.getContext().getPackageName() + SEPARATOR + resourceId); } // 加载网络图片 public void loadNetImage(String url, int holderResId) { urlBuilder(url, holderResId).into(mImageView); } // 加载drawable图片 public void loadResImage(@IdRes int resId, int holderResId) { resBuilder(resId, holderResId).into(mImageView); } // 加载本地图片 public void loadLocalPathImage(String path, int holderResId) { urlBuilder("file://" + path, holderResId).into(mImageView); } // 加载网络圆型图片 public void loadNetCircleImage(String url, int holderResId) { urlBuilder(url, holderResId) .transform(new GlideCircleTransform(mImageView.getContext())) .into(mImageView); } // 加载drawable圆型图片 public void loadLocalResCircleImage(int resId, int holderResId) { resBuilder(resId, holderResId) .transform(new GlideCircleTransform(mImageView.getContext())) .into(mImageView); } // 加载本地圆型图片 public void loadLocalPathCircleImage(String path, int holderResId) { urlBuilder("file://" + path, holderResId) .transform(new GlideCircleTransform(mImageView.getContext())) .into(mImageView); } // 创建 Res DrawableRequestBuilder public DrawableRequestBuilder resBuilder(int resId, int holderResId) { return uriBuilder(resIdToUri(resId), holderResId); } // 创建 Uri DrawableRequestBuilder public DrawableRequestBuilder uriBuilder(Uri uri, int holderResId) { return Glide.with(mImageView.getContext()) .load(uri) .crossFade() .dontAnimate() .fallback(holderResId) .error(holderResId) .diskCacheStrategy(DiskCacheStrategy.SOURCE); } // 创建 Url DrawableRequestBuilder public DrawableRequestBuilder urlBuilder(final String url, int holderResId) { if (GlideManager.getInstance().isFailedUrl(url)) { return resBuilder(holderResId, holderResId); } return Glide.with(mImageView.getContext()) .load(url) .crossFade() .dontAnimate() .fallback(holderResId) .error(holderResId) .diskCacheStrategy(DiskCacheStrategy.SOURCE) .listener(new RequestListener<String, GlideDrawable>() { @Override public boolean onException(Exception e, String model, Target<GlideDrawable> target, boolean isFirstResource) { GlideManager.getInstance().putFailedUrl(url); return false; } @Override public boolean onResourceReady(GlideDrawable resource, String model, Target<GlideDrawable> target, boolean isFromMemoryCache, boolean isFirstResource) { return false; } }); } public boolean isGif(String url) { if (TextUtils.isEmpty(url)) return false; if (url.endsWith(".gif")) return true; return false; } }
[ "1038127753@qq.com" ]
1038127753@qq.com
5c1a47b943da0a6b0b6d42a4ce8303b672666bf5
c7bdefcaa4b2c7d1a857bfd5253c556df0159cbc
/SLOTGAMES/src/test/java/stepDefinition_SeaMermaid/SeaMermaid_Gamble_GambleCount_For_BetType_1_And_Denomination_3.java
e33af36fb679faa5ac71657aaa1f3059978a8087
[]
no_license
pavanysecit/SLOTGAMES_MOBILES
62a97bded1f4d0df0f50fc2176e473ce3dac267b
80bb25d81feda93b3f9137080bd2f0922e882da6
refs/heads/master
2021-02-15T04:56:59.388043
2021-01-07T09:36:44
2021-01-07T09:36:44
244,863,982
0
0
null
2020-10-13T20:03:05
2020-03-04T09:52:42
Java
UTF-8
Java
false
false
6,235
java
package stepDefinition_SeaMermaid; import org.junit.Assert; import org.openqa.selenium.By; import org.openqa.selenium.support.ui.ExpectedConditions; import org.openqa.selenium.support.ui.WebDriverWait; import cucumber.api.java.en.Given; import cucumber.api.java.en.Then; import cucumber.api.java.en.When; import io.appium.java_client.AppiumDriver; import io.appium.java_client.MobileElement; public class SeaMermaid_Gamble_GambleCount_For_BetType_1_And_Denomination_3 { AppiumDriver<MobileElement> driver; public SeaMermaid_Gamble_GambleCount_For_BetType_1_And_Denomination_3() throws InterruptedException { this.driver = SeaMermaid_URL_Login.getDriver(); //this.driver = SeaMermaid_URL_TryNow.getDriver(); } @Given("^Chrome browser, valid URL, valid login details, Sea Mermaid hot slot game, bet type as (\\d+)\\.(\\d+), denomination as ONE, balance, spin button, win amount, gamble button, gamble amount, game info page and gamble count in gamble page of slot game$") public void chrome_browser_valid_URL_valid_login_details_Sea_Mermaid_hot_slot_game_bet_type_as_denomination_as_ONE_balance_spin_button_win_amount_gamble_button_gamble_amount_game_info_page_and_gamble_count_in_gamble_page_of_slot_game(int arg1, int arg2) throws Throwable { WebDriverWait wait = new WebDriverWait(driver, 80); wait.until(ExpectedConditions.visibilityOfElementLocated(By.id("hud_Hud_txtBalance1"))); } @When("^Open the Sea Mermaid slot game by entering the valid URL in browser, enter the valid login details, transfer the balance, click on Sea Mermaid slot game, select bet type as (\\d+)\\.(\\d+) & denomination as ONE, click on spin button till player wins, click on gamble button and check the gamble count in gamble page of slot game$") public void open_the_Sea_Mermaid_slot_game_by_entering_the_valid_URL_in_browser_enter_the_valid_login_details_transfer_the_balance_click_on_Sea_Mermaid_slot_game_select_bet_type_as_denomination_as_ONE_click_on_spin_button_till_player_wins_click_on_gamble_button_and_check_the_gamble_count_in_gamble_page_of_slot_game(int arg1, int arg2) throws Throwable { String balance = driver.findElement(By.id("hud_Hud_txtBalance1")).getText(); System.out.println("The current balance of the account :" +balance); driver.findElement(By.id("hud_txtCredit")).click(); Thread.sleep(1000); MobileElement cr1 = driver.findElement(By.id("hud_CreditPopup10.01")); String credit1 =cr1.getText(); System.out.println(credit1); String expectedA = "0.01"; Assert.assertEquals(expectedA, credit1); cr1.click(); Thread.sleep(1000); driver.findElement(By.id("hud_txtBetAmount")).click(); Thread.sleep(1000); MobileElement bet1_3= driver.findElement(By.id("hud_BetPopup31")); String Betval1_3 =bet1_3.getText(); System.out.println(Betval1_3); String expectedB = "1"; Assert.assertEquals(expectedB, Betval1_3); Thread.sleep(2000); bet1_3.click(); MobileElement start = driver.findElement(By.id("hud_btnSpin")); start.click(); Thread.sleep(8000); MobileElement winE = driver.findElement(By.id("hud_Hud_txtWin1")); String prewin = winE.getText(); //System.out.println("Balance before win is"+" "+prewin); String winTex= winE.getText(); while(prewin.isEmpty()){ start.click(); Thread.sleep(8000); winTex = winE.getText(); prewin= prewin+winTex; System.out.println(winTex.isEmpty()); } System.out.println("Win amount is: " +prewin); System.out.println("Maximum gamble win amount for bet amount 1 and credit value 0.01 is : 35 SRD"); Double maxV = Double.parseDouble(prewin); if(maxV < 35) { System.out.println("Win amount less than Gamble max value 35 i.e : "+" " +maxV +". Test Case Passed"); } else { System.out.println("Win amount greater than Gamble max value 35 : i.e "+" " +maxV +". Test Case Failed"); driver.findElement(By.id("hud_btnGamble")).isDisplayed(); Thread.sleep(2000); driver.quit(); } Thread.sleep(2000); driver.findElement(By.id("hud_btnGamble")).click(); Thread.sleep(3000); Double monty = Double.parseDouble(prewin); System.out.println("Gamble amount is equal to win amount & the amount is :"+" "+monty); MobileElement attempts = driver.findElement(By.id("gamble_txtAttemptsLeft")); System.out.println("No. of attempts left :"+" "+attempts.getText()); if(monty>=0.1 && monty<=2.17) { System.out.println("The no. of attempts should be : "+" "+"5"+" "+" & no. of actual attempts are :"+attempts.getText()); Assert.assertEquals("5",attempts.getText()); } else if(monty>2.17 && monty<=4.35){ System.out.println("The no. of attempts should be : "+" "+"4"+" "+"& no. of actual attempts are :"+attempts.getText()); Assert.assertEquals("4", attempts.getText()); } else if(monty>4.35 && monty<=8.72){ System.out.println("The no. of attempts should be :"+" "+"3"+" "+"& no. of actual attempts are :"+attempts.getText()); Assert.assertEquals("3",attempts.getText()); } else if(monty>8.72 && monty<=17.45){ System.out.println("The no. of attempts should be :"+" "+"2"+" "+"& no. of actual attempts are :"+attempts.getText()); Assert.assertEquals("2",attempts.getText()); } else if(monty>17.45 && monty<=35){ System.out.println("The no. of attempts should be :"+" "+"1"+" "+"& no. of actual attempts are:"+attempts.getText()); Assert.assertEquals("1", attempts.getText()); } driver.findElement(By.id("gamble_btnCollect")).click(); System.out.println("The testcase has passed"); } @Then("^Gamble count should be displayed on gamble page of slot game based on win amount and gamble max amount configured on the game info page for bet type (\\d+)\\.(\\d+) & denomination ONE in Sea Mermaid game$") public void gamble_count_should_be_displayed_on_gamble_page_of_slot_game_based_on_win_amount_and_gamble_max_amount_configured_on_the_game_info_page_for_bet_type_denomination_ONE_in_Sea_Mermaid_game(int arg1, int arg2) throws Throwable { Thread.sleep(2000); driver.quit(); } }
[ "pavan.kumar@ysecit.com" ]
pavan.kumar@ysecit.com
28232759b0fd3bf9960865e501d15b216c29c353
793c62c2034119829bf18e801ee1912a8b7905a7
/pattern/src/main/java/com/luolei/pattern/adapter/ch1/OperationAdapter.java
8269548ca7d682e3ec83762400a23f7c2321eee1
[]
no_license
askluolei/practice
5b087a40535b5fb038fb9aa25831d884476d27c9
044b13781bc876fd2472d7dfc3e709544d26c546
refs/heads/master
2021-09-10T15:15:58.199101
2018-03-28T09:17:57
2018-03-28T09:17:57
108,428,724
0
0
null
null
null
null
UTF-8
Java
false
false
719
java
package com.luolei.pattern.adapter.ch1; /** * 操作适配器:适配器 * * @author luolei * @date 2017-03-30 10:25 */ public class OperationAdapter implements ScoreOperation { private QuickSort sortObj; //定义适配者QuickSort对象 private BinarySearch searchObj; //定义适配者BinarySearch对象 public OperationAdapter() { sortObj = new QuickSort(); searchObj = new BinarySearch(); } public int[] sort(int array[]) { return sortObj.quickSort(array); //调用适配者类QuickSort的排序方法 } public int search(int array[], int key) { return searchObj.binarySearch(array, key); //调用适配者类BinarySearch的查找方法 } }
[ "askluolei@gmail.com" ]
askluolei@gmail.com
5bee450828eb1e04c155fee95d11a0ca6c3c1f9d
6d495f1e8b4682230c5fd1f8edd2beaacc67c47b
/src/main/java/com/selectica/RCFdev3/definitions/CFR1BO/actions/ComputeAssembleElapsedTimeActionScript.java
ef43e50232d7148c780aa71d567bfe9eee181868
[]
no_license
ikrysenko-selectica/rcfdev3
3eab3b9f63cb59685fbd3bf6b53c17fc4ca6d784
4d44c53af1d956e6f68039a1e959abab31cc92c3
refs/heads/master
2021-01-21T11:14:58.060052
2015-06-17T13:29:46
2015-06-17T13:29:46
37,593,333
0
0
null
null
null
null
UTF-8
Java
false
false
340
java
package com.selectica.RCFdev3.definitions.CFR1BO.actions; import com.selectica.RCFdev3.eclm.definitions.shared.actions.ComputeAssembleElapsedTimeAction; import com.selectica.rcfscripts.AbstractBOWriteScript; /**#ComputeAssembleElapsedTime*/ public class ComputeAssembleElapsedTimeActionScript extends ComputeAssembleElapsedTimeAction { }
[ "user@rcfproj.aws.selectica.net" ]
user@rcfproj.aws.selectica.net
e11316704d75daa1e577deb9a29d58fa416b4bfe
e63363389e72c0822a171e450a41c094c0c1a49c
/Mate20_9_0_0/src/main/java/com/android/server/om/-$$Lambda$OverlayManagerSettings$sx0Nyvq91kCH_A-4Ctf09G_0u9M.java
d408947b5d173200d8d444e3ca45c5adef9895b0
[]
no_license
solartcc/HwFrameWorkSource
fc23ca63bcf17865e99b607cc85d89e16ec1b177
5b92ed0f1ccb4bafc0fdb08b6fc4d98447b754ad
refs/heads/master
2022-12-04T21:14:37.581438
2020-08-25T04:30:43
2020-08-25T04:30:43
null
0
0
null
null
null
null
UTF-8
Java
false
false
641
java
package com.android.server.om; import android.content.om.OverlayInfo; import java.util.function.Function; /* compiled from: lambda */ public final /* synthetic */ class -$$Lambda$OverlayManagerSettings$sx0Nyvq91kCH_A-4Ctf09G_0u9M implements Function { public static final /* synthetic */ -$$Lambda$OverlayManagerSettings$sx0Nyvq91kCH_A-4Ctf09G_0u9M INSTANCE = new -$$Lambda$OverlayManagerSettings$sx0Nyvq91kCH_A-4Ctf09G_0u9M(); private /* synthetic */ -$$Lambda$OverlayManagerSettings$sx0Nyvq91kCH_A-4Ctf09G_0u9M() { } public final Object apply(Object obj) { return ((OverlayInfo) obj).targetPackageName; } }
[ "lygforbs0@mail.com" ]
lygforbs0@mail.com
df0a58d751fd215913e041d6a3ccdd103ae6d2c0
0874d515fb8c23ae10bf140ee5336853bceafe0b
/l2j-universe/dist/gameserver/data/scripts/ai/Mammons.java
e784b8ac28b4b0b4848c35416cb0ad96c06a9bf7
[]
no_license
NotorionN/l2j-universe
8dfe529c4c1ecf0010faead9e74a07d0bc7fa380
4d05cbd54f5586bf13e248e9c853068d941f8e57
refs/heads/master
2020-12-24T16:15:10.425510
2013-11-23T19:35:35
2013-11-23T19:35:35
37,354,291
0
1
null
null
null
null
UTF-8
Java
false
false
6,240
java
/* * This program is free software: you can redistribute it and/or modify it under * the terms of the GNU General Public License as published by the Free Software * Foundation, either version 3 of the License, or (at your option) any later version. * * This program is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see <http://www.gnu.org/licenses/>. */ package ai; import java.util.concurrent.ScheduledFuture; import lineage2.commons.util.Rnd; import lineage2.gameserver.ThreadPoolManager; import lineage2.gameserver.data.xml.holder.NpcHolder; import lineage2.gameserver.model.SimpleSpawner; import lineage2.gameserver.model.instances.NpcInstance; import lineage2.gameserver.network.serverpackets.components.NpcString; import lineage2.gameserver.scripts.Functions; import lineage2.gameserver.scripts.ScriptFile; import lineage2.gameserver.templates.npc.NpcTemplate; import lineage2.gameserver.utils.Location; import org.slf4j.Logger; import org.slf4j.LoggerFactory; /** * @author Mobius * @version $Revision: 1.0 $ */ public class Mammons extends Functions implements ScriptFile { /** * Field _log. */ private static final Logger _log = LoggerFactory.getLogger(Mammons.class); /** * Field MAMMON_PRIEST_ID. (value is 33511) */ private static final int MAMMON_PRIEST_ID = 33511; /** * Field MAMMON_MERCHANT_ID. (value is 31113) */ private static final int MAMMON_MERCHANT_ID = 31113; /** * Field MAMMON_BLACKSMITH_ID. (value is 31126) */ private static final int MAMMON_BLACKSMITH_ID = 31126; /** * Field PORT_TIME. */ private static final int PORT_TIME = 10 * 60 * 1000; /** * Field PriestNpc. */ static NpcInstance PriestNpc; /** * Field MerchantNpc. */ static NpcInstance MerchantNpc; /** * Field BlacksmithNpc. */ static NpcInstance BlacksmithNpc; /** * Field _mammonTeleportTask. */ private static ScheduledFuture<?> _mammonTeleportTask; /** * Field mammonText. */ static final NpcString[] mammonText = { NpcString.RULERS_OF_THE_SEAL_I_BRING_YOU_WONDROUS_GIFTS, NpcString.RULERS_OF_THE_SEAL_I_HAVE_SOME_EXCELLENT_WEAPONS_TO_SHOW_YOU, NpcString.IVE_BEEN_SO_BUSY_LATELY_IN_ADDITION_TO_PLANNING_MY_TRIP }; /** * Field MAMMON_PRIEST_POINTS. */ static final Location[] MAMMON_PRIEST_POINTS = { new Location(16403, 144843, -3016, 27931), new Location(81284, 150155, -3528), new Location(114478, 217596, -3624, 0), new Location(79992, 56808, -1585), new Location(-84744, 151688, -3154, 0), new Location(-12344, 121736, -3014, 0), new Location(120392, 76488, -2167, 0), new Location(146984, 29624, -2294, 0), new Location(42856, -41432, -2212, 0), new Location(144632, -54136, -3006, 0), new Location(90024, -143672, -1565, 0), }; /** * Field MAMMON_MERCHANT_POINTS. */ static final Location[] MAMMON_MERCHANT_POINTS = { new Location(16380, 144784, -3016, 27931), new Location(81272, 150041, -3528), new Location(114482, 217538, -3624, 0), new Location(79992, 56856, -1585), new Location(-84744, 151656, -3154, 0), new Location(-12344, 121784, -3014, 0), new Location(120344, 76520, -2167, 0), new Location(146984, 29672, -2294, 0), new Location(42968, -41384, -2213, 0), new Location(144552, -54104, -3006, 0), new Location(89944, -143688, -1565, 0), }; /** * Field MAMMON_BLACKSMITH_POINTS. */ static final Location[] MAMMON_BLACKSMITH_POINTS = { new Location(16335, 144696, -3024, 27931), new Location(81266, 150091, -3528), new Location(114484, 217462, -3624, 0), new Location(79992, 56920, -1585), new Location(-84744, 151608, -3154, 0), new Location(-12344, 121640, -3014, 0), new Location(120296, 76536, -2167, 0), new Location(146984, 29736, -2294, 0), new Location(43032, -41336, -2214, 0), new Location(144472, -54088, -3006, 0), new Location(89912, -143752, -1566, 0), }; /** * Method SpawnMammons. */ public void SpawnMammons() { final int firstTown = Rnd.get(MAMMON_PRIEST_POINTS.length); NpcTemplate template = NpcHolder.getInstance().getTemplate(MAMMON_PRIEST_ID); SimpleSpawner sp = new SimpleSpawner(template); sp.setLoc(MAMMON_PRIEST_POINTS[firstTown]); sp.setAmount(1); sp.setRespawnDelay(0); PriestNpc = sp.doSpawn(true); template = NpcHolder.getInstance().getTemplate(MAMMON_MERCHANT_ID); sp = new SimpleSpawner(template); sp.setLoc(MAMMON_MERCHANT_POINTS[firstTown]); sp.setAmount(1); sp.setRespawnDelay(0); MerchantNpc = sp.doSpawn(true); template = NpcHolder.getInstance().getTemplate(MAMMON_BLACKSMITH_ID); sp = new SimpleSpawner(template); sp.setLoc(MAMMON_BLACKSMITH_POINTS[firstTown]); sp.setAmount(1); sp.setRespawnDelay(0); BlacksmithNpc = sp.doSpawn(true); } /** * @author Mobius */ public static class TeleportMammons implements Runnable { /** * Method run. * @see java.lang.Runnable#run() */ @Override public void run() { Functions.npcShout(BlacksmithNpc, mammonText[Rnd.get(mammonText.length)]); final int nextTown = Rnd.get(MAMMON_PRIEST_POINTS.length); PriestNpc.teleToLocation(MAMMON_PRIEST_POINTS[nextTown]); MerchantNpc.teleToLocation(MAMMON_MERCHANT_POINTS[nextTown]); BlacksmithNpc.teleToLocation(MAMMON_BLACKSMITH_POINTS[nextTown]); } } /** * Method onLoad. * @see lineage2.gameserver.scripts.ScriptFile#onLoad() */ @Override public void onLoad() { SpawnMammons(); _mammonTeleportTask = ThreadPoolManager.getInstance().scheduleAtFixedRate(new TeleportMammons(), PORT_TIME, PORT_TIME); _log.info("Loaded AI: Mammons Teleporter"); } /** * Method onReload. * @see lineage2.gameserver.scripts.ScriptFile#onReload() */ @Override public void onReload() { // empty method } /** * Method onShutdown. * @see lineage2.gameserver.scripts.ScriptFile#onShutdown() */ @Override public void onShutdown() { if (_mammonTeleportTask != null) { _mammonTeleportTask.cancel(true); _mammonTeleportTask = null; } } }
[ "jmendezsr@gmail.com" ]
jmendezsr@gmail.com
627cc78c9548f9004646e66ad57119a334d59d57
6f4b5d7bf14f157e3c6a9c304ec45e5d9fe48834
/src/main/java/clikmng/nanet/go/kr/cmm/service/impl/EgovUserDetailsSessionServiceImpl.java
190742328173f9bdced80cfed08b6fc5f869c760
[]
no_license
kimyongyeon/clik_mng
f5411a7191e30c3c6ae0f7d88eec016d90432aff
1f8d7bf3c8facd3f8365440dcca2308e1e3fae42
refs/heads/master
2021-01-01T05:19:33.391175
2016-04-29T06:41:16
2016-04-29T06:41:16
57,361,010
1
0
null
null
null
null
UTF-8
Java
false
false
1,377
java
package clikmng.nanet.go.kr.cmm.service.impl; import java.util.ArrayList; import java.util.List; import org.springframework.web.context.request.RequestAttributes; import org.springframework.web.context.request.RequestContextHolder; import clikmng.nanet.go.kr.cmm.service.EgovUserDetailsService; import egovframework.rte.fdl.cmmn.AbstractServiceImpl; /** * * @author * @since * @version * @see * * <pre> * 개정이력(Modification Information) * * 수정일 수정자 수정내용 * ------- -------- --------------------------- * * </pre> */ public class EgovUserDetailsSessionServiceImpl extends AbstractServiceImpl implements EgovUserDetailsService { public Object getAuthenticatedUser() { return RequestContextHolder.getRequestAttributes().getAttribute("loginVO", RequestAttributes.SCOPE_SESSION); } public List<String> getAuthorities() { // 권한 설정을 리턴한다. List<String> listAuth = new ArrayList<String>(); return listAuth; } public Boolean isAuthenticated() { // 인증된 유저인지 확인한다. if (RequestContextHolder.getRequestAttributes() == null) { return false; } else { if (RequestContextHolder.getRequestAttributes().getAttribute( "loginVO", RequestAttributes.SCOPE_SESSION) == null) { return false; } else { return true; } } } }
[ "toyongyeon@gmail.com" ]
toyongyeon@gmail.com
d99d12895c92f32166394c5fd43b153dfbc2b3e1
9526559011b76abb514602b43b7e47231114b45a
/random-beans/src/test/java/io/github/benas/randombeans/randomizers/UrlRandomizerTest.java
3ce93e79753545c33be91dfbeb8814f0249c8de1
[ "MIT" ]
permissive
nate-sonicbottle/random-beans
02a182ecb38099b7a72e3e666ed8e4eb8d58068c
c77d8fdf7477b747889688e431baac4702f27b43
refs/heads/master
2021-01-15T20:47:48.804953
2016-02-22T20:39:24
2016-02-22T20:39:24
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,888
java
/* * The MIT License * * Copyright (c) 2016, Mahmoud Ben Hassine (mahmoud.benhassine@icloud.com) * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Software without restriction, including without limitation the rights * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell * copies of the Software, and to permit persons to whom the Software is * furnished to do so, subject to the following conditions: * * The above copyright notice and this permission notice shall be included in * all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN * THE SOFTWARE. */ package io.github.benas.randombeans.randomizers; import org.junit.Before; import org.junit.Test; import java.net.MalformedURLException; import java.net.URL; import static org.assertj.core.api.Assertions.assertThat; public class UrlRandomizerTest extends AbstractRandomizerTest<URL> { @Before public void setUp() throws Exception { randomizer = UrlRandomizer.aNewUrlRandomizer(SEED); } @Test public void shouldGenerateTheSameValueForTheSameSeed() throws MalformedURLException { URL actual = randomizer.getRandomValue(); URL expected = new URL("http://www.google.com"); assertThat(actual).isEqualTo(expected); } }
[ "mahmoud.benhassine@icloud.com" ]
mahmoud.benhassine@icloud.com
239767001a1196e718ce9ee5dab2a94e85123eca
4a6e0b5a9b4f233b4574cec71b4bad8058e8d9e5
/erp-model/erp-model-service/src/main/java/com/berrontech/erp/modal/service/general/impl/PartCategoryServiceImpl.java
b7231d386f327785b76000d5f5a8ecd253522ad9
[]
no_license
levent8421/agile-erp
38e3c00ac6a97a1fce05b79d344c8f99704aca13
e21ae39bb730e040d6921871991a69d614632670
refs/heads/master
2023-03-15T05:33:23.572085
2021-03-10T13:34:39
2021-03-10T13:34:39
345,548,155
0
1
null
null
null
null
UTF-8
Java
false
false
1,930
java
package com.berrontech.erp.modal.service.general.impl; import com.berrontech.erp.commons.entity.PartCategory; import com.berrontech.erp.commons.entity.PartType; import com.berrontech.erp.modal.service.basic.impl.AbstractServiceImpl; import com.berrontech.erp.modal.service.general.PartCategoryService; import com.berrontech.erp.modal.service.vo.PartTypeVo; import com.berrontech.erp.model.repository.general.PartCategoryMapper; import lombok.val; import org.springframework.stereotype.Service; import java.util.ArrayList; import java.util.HashMap; import java.util.List; /** * Create By Levent8421 * Create Time: 2020/2/12 0:23 * Class Name: PartCategoryServiceImpl * Author: Levent8421 * Description: * 库存类别相关业务行为实现 * * @author Levent8421 */ @Service public class PartCategoryServiceImpl extends AbstractServiceImpl<PartCategory> implements PartCategoryService { private final PartCategoryMapper partCategoryMapper; public PartCategoryServiceImpl(PartCategoryMapper partCategoryMapper) { super(partCategoryMapper); this.partCategoryMapper = partCategoryMapper; } @Override public List<PartCategory> findByTypeId(Integer typeId) { return partCategoryMapper.selectByTypeId(typeId); } @Override public List<PartTypeVo> asTree(List<PartType> types, List<PartCategory> categories) { val categoriesMap = new HashMap<Integer, List<PartCategory>>(16); for (val category : categories) { val list = categoriesMap.computeIfAbsent(category.getPartTypeId(), k -> new ArrayList<>()); list.add(category); } val res = new ArrayList<PartTypeVo>(); for (val type : types) { val list = categoriesMap.get(type.getId()); val typeVo = new PartTypeVo(type); typeVo.setPartCategories(list); res.add(typeVo); } return res; } }
[ "levent8421@outlook.com" ]
levent8421@outlook.com
1fc80449237f52a314b762bc61b6d29249eea0cb
a2aa0d649ff84cd1d8c824bda900efb8f3260591
/hibernate-database/hibernate/src/com/ntdat/hibernateproject/entities/MonHocEntity.java
b380eb02b73091b75b4c1c1c8d3584b520d7408b
[]
no_license
itdat/student-management-java
74279ca0a2e0d0a32d9d4847069650bd4d30d121
a3ec1ab7d3e1759d91c92c9b45ea7304b680b3f6
refs/heads/master
2022-11-17T07:53:32.777093
2020-07-05T16:36:29
2020-07-05T16:36:29
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,022
java
package com.ntdat.hibernateproject.entities; import javax.persistence.*; import java.util.Objects; @Entity @Table(name = "mon_hoc", schema = "hibernate-database", catalog = "") public class MonHocEntity { private String maMon; private String tenMon; @Id @Column(name = "MaMon") public String getMaMon() { return maMon; } public void setMaMon(String maMon) { this.maMon = maMon; } @Basic @Column(name = "TenMon") public String getTenMon() { return tenMon; } public void setTenMon(String tenMon) { this.tenMon = tenMon; } @Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; MonHocEntity that = (MonHocEntity) o; return Objects.equals(maMon, that.maMon) && Objects.equals(tenMon, that.tenMon); } @Override public int hashCode() { return Objects.hash(maMon, tenMon); } }
[ "53074785+itdat@users.noreply.github.com" ]
53074785+itdat@users.noreply.github.com
578d1276b74c5f2e7f802fcecf97d343cf69f632
be57f63aa618cfebf3b17ec8cbb67ce0c478638d
/src/main/java/com/moptra/go4wealth/prs/model/FileDetailsDTO.java
0433b53ab76b9c1e08e510d9d7240acddf9236c6
[]
no_license
gauravkatiyar6891/wealth_back_end
b67abe2d94fad555e9b5282020329bb1bd52bfc4
857ad22a994a13f5892d2e3023e555480ef6c2c2
refs/heads/master
2022-09-17T23:10:20.420394
2019-07-26T15:12:16
2019-07-26T15:12:16
199,013,982
0
0
null
2022-09-01T23:10:23
2019-07-26T12:37:29
Java
UTF-8
Java
false
false
1,503
java
package com.moptra.go4wealth.prs.model; public class FileDetailsDTO { String signatureString; String fileName; String frontAdharCardString; String backAdharCardString; String addressProof; String docNumber; String imageType; boolean isFatca; public String getImageType() { return imageType; } public void setImageType(String imageType) { this.imageType = imageType; } public String getSignatureString() { return signatureString; } public void setSignatureString(String signatureString) { this.signatureString = signatureString; } public String getFileName() { return fileName; } public void setFileName(String fileName) { this.fileName = fileName; } public String getFrontAdharCardString() { return frontAdharCardString; } public void setFrontAdharCardString(String frontAdharCardString) { this.frontAdharCardString = frontAdharCardString; } public String getBackAdharCardString() { return backAdharCardString; } public void setBackAdharCardString(String backAdharCardString) { this.backAdharCardString = backAdharCardString; } public String getAddressProof() { return addressProof; } public void setAddressProof(String addressProof) { this.addressProof = addressProof; } public String getDocNumber() { return docNumber; } public void setDocNumber(String docNumber) { this.docNumber = docNumber; } public boolean isFatca() { return isFatca; } public void setFatca(boolean isFatca) { this.isFatca = isFatca; } }
[ "vinod.shukla@moptra.com" ]
vinod.shukla@moptra.com
5b2bfd730f2b7f6b3f494fcaab8fb4cf9b36cb21
5eb61dc67145c1b1d5a908b803520ba9da83f82d
/SSM项目/src/main/java/com/nys/cost/domain/PageBean.java
38da6098ba8ba0fe5f8ed11a817c8923f607297d
[]
no_license
OnTheRightWay/workspace
27549e5344a8d56575a5b5798bdabf9fe661872d
f6767929db06f66defdee50dcf87fb7441207e87
refs/heads/master
2021-09-09T15:06:33.482564
2018-03-17T06:07:57
2018-03-17T06:07:57
113,117,366
0
0
null
null
null
null
UTF-8
Java
false
false
2,007
java
package com.nys.cost.domain; import org.springframework.stereotype.Component; import java.util.List; import java.util.Map; @Component public class PageBean { //当前页 private int currentPage; //对象集合 private List lists; //总页数 private int totalPage; //每页大小 private int pageSize = 5; //get拼接参数 private String param; //参数集合,表单拼接参数 private Map<String,String> params; public Map<String, String> getParams() { return params; } public void setParams(Map<String, String> params) { this.params = params; } public PageBean() { } public PageBean(int currentPage, List lists, int totalPage, int pageSize, int pageCount, String param) { this.currentPage = currentPage; this.lists = lists; this.totalPage = totalPage; this.pageSize = pageSize; this.param = param; } @Override public String toString() { return "PageBean{" + "currentPage=" + currentPage + ", lists=" + lists + ", totalPage=" + totalPage + ", pageSize=" + pageSize + ", param='" + param + '\'' + '}'; } public int getCurrentPage() { return currentPage; } public void setCurrentPage(int currentPage) { this.currentPage = currentPage; } public List getLists() { return lists; } public void setLists(List lists) { this.lists = lists; } public int getTotalPage() { return totalPage; } public void setTotalPage(int totalPage) { this.totalPage = totalPage; } public int getPageSize() { return pageSize; } public void setPageSize(int pageSize) { this.pageSize = pageSize; } public String getParam() { return param; } public void setParam(String param) { this.param = param; } }
[ "34029301+OnTheRightWay@users.noreply.github.com" ]
34029301+OnTheRightWay@users.noreply.github.com
c7b6f0df9378e6cbaa6b6363e07ce952392ef6b3
1930d97ebfc352f45b8c25ef715af406783aabe2
/src/main/java/com/alipay/api/domain/ShopQueueStatus.java
ba092cb1fc712c2a1680f9fb1073833c1ae38250
[ "Apache-2.0" ]
permissive
WQmmm/alipay-sdk-java-all
57974d199ee83518523e8d354dcdec0a9ce40a0c
66af9219e5ca802cff963ab86b99aadc59cc09dd
refs/heads/master
2023-06-28T03:54:17.577332
2021-08-02T10:05:10
2021-08-02T10:05:10
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,421
java
package com.alipay.api.domain; import com.alipay.api.AlipayObject; import com.alipay.api.internal.mapping.ApiField; /** * 排队队列状态 * * @author auto create * @since 1.0, 2019-05-16 10:38:29 */ public class ShopQueueStatus extends AlipayObject { private static final long serialVersionUID = 3248849813318463273L; /** * 队列ID */ @ApiField("queue_id") private String queueId; /** * 队列状态。如enable表示可取号;disable表示不可取号。 */ @ApiField("queue_status") private String queueStatus; /** * 当前等待人数 */ @ApiField("queue_wait") private Long queueWait; /** * 当前等待时间(单位:分钟)。如无法预估传-1即可。 */ @ApiField("queue_wait_time") private Long queueWaitTime; public String getQueueId() { return this.queueId; } public void setQueueId(String queueId) { this.queueId = queueId; } public String getQueueStatus() { return this.queueStatus; } public void setQueueStatus(String queueStatus) { this.queueStatus = queueStatus; } public Long getQueueWait() { return this.queueWait; } public void setQueueWait(Long queueWait) { this.queueWait = queueWait; } public Long getQueueWaitTime() { return this.queueWaitTime; } public void setQueueWaitTime(Long queueWaitTime) { this.queueWaitTime = queueWaitTime; } }
[ "ben.zy@antfin.com" ]
ben.zy@antfin.com
c4383c179a01c6122b0438e6e6b3bae7944d2b1f
3fc95dc07b0fad7164596651c5ef194a1eeceff8
/HjSystem/src/main/java/com/sl/ue/entity/jl/vo/JlTtsVO.java
7f41d16619c0b3c7a579de0c25d39904b85c17d5
[]
no_license
li912583940/hjxt
2c44c667e88f71727ede051dd86955e93751b00a
551f9f1140ce00602c7f59530b3ac267ea1c85f7
refs/heads/master
2020-03-07T05:26:57.169822
2019-05-20T13:20:26
2019-05-20T13:20:26
127,296,158
0
2
null
null
null
null
UTF-8
Java
false
false
978
java
package com.sl.ue.entity.jl.vo; import com.sl.ue.entity.jl.JlTts; public class JlTtsVO extends JlTts{ /** 序列化 */ private static final long serialVersionUID = 1L; /*--------------------------- 处理关联表 -----------------------------*/ private String leftJoinField; // 关联表字段 private String leftJoinTable; // 关联表 private String leftJoinWhere; // 关联表条件 public String getLeftJoinField() { return leftJoinField; } public void setLeftJoinField(String leftJoinField) { this.leftJoinField = leftJoinField; } public String getLeftJoinTable() { return leftJoinTable; } public void setLeftJoinTable(String leftJoinTable) { this.leftJoinTable = leftJoinTable; } public String getLeftJoinWhere() { return leftJoinWhere; } public void setLeftJoinWhere(String leftJoinWhere) { this.leftJoinWhere = leftJoinWhere; } }
[ "912583940@qq.com" ]
912583940@qq.com
6fcc579c8bd8e3ec2ffd9455e885f8cf70e5687b
3856fc9a75ec77eac662027da02646dfa09c330b
/open-metadata-implementation/governance-servers/admin-services/admin-services-server/src/main/java/org/odpi/openmetadata/adminservices/properties/VoidResponse.java
05cfab1b0320775e3ef21437ead0975d269a3e52
[ "Apache-2.0" ]
permissive
sethvi/egeria
8f3125f8b9bfa819d761e80e21445f65c5b4a116
9d67c7073730d8f88b9c9c03e979963ad2882937
refs/heads/master
2020-03-23T15:35:47.845371
2018-09-18T14:18:00
2018-09-18T14:18:00
141,760,300
0
0
Apache-2.0
2018-07-20T21:39:26
2018-07-20T21:39:26
null
UTF-8
Java
false
false
1,710
java
/* SPDX-License-Identifier: Apache-2.0 */ package org.odpi.openmetadata.adminservices.properties; import com.fasterxml.jackson.annotation.JsonAutoDetect; import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import com.fasterxml.jackson.annotation.JsonInclude; import static com.fasterxml.jackson.annotation.JsonAutoDetect.Visibility.NONE; import static com.fasterxml.jackson.annotation.JsonAutoDetect.Visibility.PUBLIC_ONLY; /** * VoidResponse defines the response structure for the OMAG REST API calls that returns a * void as a response. */ @JsonAutoDetect(getterVisibility=PUBLIC_ONLY, setterVisibility=PUBLIC_ONLY, fieldVisibility=NONE) @JsonInclude(JsonInclude.Include.NON_NULL) @JsonIgnoreProperties(ignoreUnknown=true) public class VoidResponse extends OMAGAPIResponse { /** * Default constructor */ public VoidResponse() { super(); } /** * Copy/clone constructor * * @param template object to copy */ public VoidResponse(VoidResponse template) { super(template); } /** * Standard toString method. * * @return print out of variables in a JSON-style */ @Override public String toString() { return "VoidResponse{" + "relatedHTTPCode=" + relatedHTTPCode + ", exceptionClassName='" + exceptionClassName + '\'' + ", exceptionErrorMessage='" + exceptionErrorMessage + '\'' + ", exceptionSystemAction='" + exceptionSystemAction + '\'' + ", exceptionUserAction='" + exceptionUserAction + '\'' + ", exceptionProperties=" + exceptionProperties + '}'; } }
[ "mandy_chessell@uk.ibm.com" ]
mandy_chessell@uk.ibm.com
a9133247d4f8755042174b20f0969f9747f5b7c8
5f14a75cb6b80e5c663daa6f7a36001c9c9b778c
/src/bu.java
ca029028954fba0ba43d878199e7f3124b1793f8
[]
no_license
MaTriXy/com.ubercab
37b6f6d3844e6a63dc4c94f8b6ba6bb4eb0118fb
ccd296d27e0ecf5ccb46147e8ec8fb70d2024b2c
refs/heads/master
2021-01-22T11:16:39.511861
2016-03-19T20:58:25
2016-03-19T20:58:25
null
0
0
null
null
null
null
UTF-8
Java
false
false
5,045
java
public final class bu { public static final int action0 = 2131624072; public static final int action_bar = 2131624056; public static final int action_bar_activity_content = 2131623936; public static final int action_bar_container = 2131624055; public static final int action_bar_root = 2131624051; public static final int action_bar_spinner = 2131623937; public static final int action_bar_subtitle = 2131624025; public static final int action_bar_title = 2131624024; public static final int action_context_bar = 2131624057; public static final int action_divider = 2131624076; public static final int action_menu_divider = 2131623938; public static final int action_menu_presenter = 2131623939; public static final int action_mode_bar = 2131624053; public static final int action_mode_bar_stub = 2131624052; public static final int action_mode_close_button = 2131624026; public static final int activity_chooser_view_content = 2131624027; public static final int alertTitle = 2131624039; public static final int always = 2131623982; public static final int beginning = 2131623974; public static final int buttonPanel = 2131624034; public static final int cancel_action = 2131624073; public static final int checkbox = 2131624048; public static final int chronometer = 2131624079; public static final int collapseActionView = 2131623983; public static final int contentPanel = 2131624040; public static final int custom = 2131624046; public static final int customPanel = 2131624045; public static final int decor_content_parent = 2131624054; public static final int default_activity_button = 2131624030; public static final int disableHome = 2131623953; public static final int edit_query = 2131624058; public static final int end = 2131623975; public static final int end_padder = 2131624084; public static final int expand_activities_button = 2131624028; public static final int expanded_menu = 2131624047; public static final int home = 2131623941; public static final int homeAsUp = 2131623954; public static final int icon = 2131624032; public static final int ifRoom = 2131623984; public static final int image = 2131624029; public static final int info = 2131624083; public static final int line1 = 2131624077; public static final int line3 = 2131624081; public static final int listMode = 2131623950; public static final int list_item = 2131624031; public static final int media_actions = 2131624075; public static final int middle = 2131623976; public static final int multiply = 2131623961; public static final int never = 2131623985; public static final int none = 2131623955; public static final int normal = 2131623951; public static final int parentPanel = 2131624036; public static final int progress_circular = 2131623943; public static final int progress_horizontal = 2131623944; public static final int radio = 2131624050; public static final int screen = 2131623962; public static final int scrollIndicatorDown = 2131624044; public static final int scrollIndicatorUp = 2131624041; public static final int scrollView = 2131624042; public static final int search_badge = 2131624060; public static final int search_bar = 2131624059; public static final int search_button = 2131624061; public static final int search_close_btn = 2131624066; public static final int search_edit_frame = 2131624062; public static final int search_go_btn = 2131624068; public static final int search_mag_icon = 2131624063; public static final int search_plate = 2131624064; public static final int search_src_text = 2131624065; public static final int search_voice_btn = 2131624069; public static final int select_dialog_listview = 2131624070; public static final int shortcut = 2131624049; public static final int showCustom = 2131623956; public static final int showHome = 2131623957; public static final int showTitle = 2131623958; public static final int spacer = 2131624035; public static final int split_action_bar = 2131623945; public static final int src_atop = 2131623963; public static final int src_in = 2131623964; public static final int src_over = 2131623965; public static final int status_bar_latest_event_content = 2131624074; public static final int submit_area = 2131624067; public static final int tabMode = 2131623952; public static final int text = 2131624082; public static final int text2 = 2131624080; public static final int textSpacerNoButtons = 2131624043; public static final int time = 2131624078; public static final int title = 2131624033; public static final int title_template = 2131624038; public static final int topPanel = 2131624037; public static final int up = 2131623949; public static final int useLogo = 2131623959; public static final int withText = 2131623986; public static final int wrap_content = 2131623997; } /* Location: * Qualified Name: bu * Java Class Version: 6 (50.0) * JD-Core Version: 0.7.1 */
[ "reverseengineeringer@hackeradmin.com" ]
reverseengineeringer@hackeradmin.com
f3de71ae271da225f4e0cc7171b1778543f9e17a
61c6164c22142c4369d525a0997b695875865e29
/middleware/src/main/java/com/spirit/compras/entity/CompraDetalleGastoData.java
31664bdd727f9a22e887e1784ee86aa9cb9a7c26
[]
no_license
xruiz81/spirit-creacional
e5a6398df65ac8afa42be65886b283007d190eae
382ee7b1a6f63924b8eb895d4781576627dbb3e5
refs/heads/master
2016-09-05T14:19:24.440871
2014-11-10T17:12:34
2014-11-10T17:12:34
26,328,756
1
0
null
null
null
null
UTF-8
Java
false
false
1,859
java
package com.spirit.compras.entity; import java.io.Serializable; import com.spirit.comun.util.ToStringer; /** * * @author www.versality.com.ec * */ public class CompraDetalleGastoData implements CompraDetalleGastoIf, Serializable { private java.lang.Long id; public java.lang.Long getId() { return id; } public void setId(java.lang.Long id) { this.id = id; } private java.lang.Long compraGastoId; public java.lang.Long getCompraGastoId() { return compraGastoId; } public void setCompraGastoId(java.lang.Long compraGastoId) { this.compraGastoId = compraGastoId; } private java.lang.Long compraDetalleId; public java.lang.Long getCompraDetalleId() { return compraDetalleId; } public void setCompraDetalleId(java.lang.Long compraDetalleId) { this.compraDetalleId = compraDetalleId; } private java.math.BigDecimal valor; public java.math.BigDecimal getValor() { return valor; } public void setValor(java.math.BigDecimal valor) { this.valor = valor; } public CompraDetalleGastoData() { } public CompraDetalleGastoData(com.spirit.compras.entity.CompraDetalleGastoIf value) { setId(value.getId()); setCompraGastoId(value.getCompraGastoId()); setCompraDetalleId(value.getCompraDetalleId()); setValor(value.getValor()); } public java.lang.Long getPrimaryKey() { return getId(); } public void setPrimaryKey(java.lang.Long pk) { setId(pk); } public String getPrimaryKeyParameters() { String parameters = ""; parameters += "&id=" + getId(); return parameters; } public String toString() { return ToStringer.toString((CompraDetalleGastoIf)this); } }
[ "xruiz@creacional.com" ]
xruiz@creacional.com
3b8218fd7b0264928ceebebf727ece0ea0223a34
453ad6a89d9acac966d7febb0f595ba171f4b036
/src/com/print/demo/util/PrintUtil.java
bf89e26cfa250f7a6387522f98ec7a60fac7d962
[]
no_license
yuexingxing/ScanDemo
349d236abdb1c1c525f3c22668bcb900dd56783c
05d71bd04fb556b10d685a8531081afa24b16aae
refs/heads/master
2020-03-09T04:37:47.888766
2018-06-08T15:12:47
2018-06-08T15:12:47
128,591,947
0
0
null
null
null
null
GB18030
Java
false
false
5,062
java
package com.print.demo.util; import com.print.demo.ApplicationContext; import com.print.demo.data.PrintInfo; import utils.preDefiniation.AlignType; import utils.preDefiniation.BarcodeType; /** * 打印类 * * @author yxx * * @date 2018-3-12 下午5:52:03 * */ public class PrintUtil { public static ApplicationContext context = ApplicationContext.getInstance(); public static void printLabelTest(PrintInfo info){ // context.getObject().CON_PageStart(context.getState(),false, 0, 0);//0,0 context.getObject().ASCII_CtrlAlignType(context.getState(), AlignType.AT_CENTER.getValue()); context.getObject().ASCII_CtrlFeedLines(context.getState(), 0); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 1, 0, 0, "1\r\n", "gb2312"); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "2\r\n", "gb2312"); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "3\r\n", "gb2312"); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "4\r\n", "gb2312"); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "5\r\n", "gb2312"); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "6\r\n", "gb2312"); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "7\r\n", "gb2312"); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "8\r\n", "gb2312"); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "9\r\n", "gb2312"); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "10\r\n", "gb2312"); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "11\r\n", "gb2312"); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "12\r\n", "gb2312"); context.getObject().ASCII_CtrlFeedLines(context.getState(), 1); // context.getObject().ASCII_CtrlReset(context.getState()); // context.getObject().ASCII_Print1DBarcode(context.getState(),BarcodeType.BT_CODE39.getValue(), 2, 32, // utils.preDefiniation.Barcode1DHRI.BH_BLEW.getValue(), info.getBillcode()); context.getObject().CON_PageEnd(context.getState(), context.getPrintway()); } /** * 行数一定要对应 * @param info */ public static void printLabel2(PrintInfo info){ String spaceStr = " ";//首行缩进距离 context.getObject().CON_PageStart(context.getState(),false, 0, 0);//0,0 context.getObject().ASCII_CtrlAlignType(context.getState(), AlignType.AT_LEFT.getValue()); context.getObject().ASCII_PrintString(context.getState(), 1, 1, 1, 0, 0, "12345678", "gb2312"); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "\n", "gb2312"); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "\n", "gb2312"); context.getObject().ASCII_CtrlFeedLines(context.getState(), 1); context.getObject().CON_PageEnd(context.getState(), context.getPrintway()); } /** * 行数一定要对应 * @param info */ public static void printLabel(PrintInfo info){ String spaceStr = " ";//首行缩进距离 context.getObject().CON_PageStart(context.getState(),false, 0, 0);//0,0 context.getObject().ASCII_CtrlAlignType(context.getState(), AlignType.AT_LEFT.getValue()); context.getObject().ASCII_CtrlSetFont(context.getState(), 15, 10, 10); context.getObject().ASCII_CtrlFeedLines(context.getState(), 0); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "\n", "gb2312"); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "\n", "gb2312"); context.getObject().ASCII_CtrlAlignType(context.getState(), 0); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 1, 0, 0, spaceStr + "打印日期: " + info.getTime() + "\n", "gb2312"); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "\n", "gb2312"); context.getObject().ASCII_CtrlReset(context.getState()); context.getObject().ASCII_CtrlAlignType(context.getState(), AlignType.AT_CENTER.getValue());//条码居中显示 context.getObject().ASCII_Print1DBarcode( context.getState(), BarcodeType.BT_CODE39.getValue(), 3, 140, 0, info.getBillcode()); context.getObject().ASCII_CtrlReset(context.getState()); context.getObject().ASCII_CtrlAlignType(context.getState(), AlignType.AT_CENTER.getValue());//条码居中显示 context.getObject().ASCII_PrintString(context.getState(), 1, 1, 1, 0, 0, info.getBillcode(), "gb2312"); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "\n", "gb2312"); context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "\n", "gb2312"); // context.getObject().ASCII_PrintString(context.getState(), 0, 0, 0, 0, 0, "\n", "gb2312"); context.getObject().ASCII_CtrlFeedLines(context.getState(), 1); context.getObject().ASCII_CtrlFeedLines(context.getState(), 1); context.getObject().CON_PageEnd(context.getState(), context.getPrintway()); } }
[ "670176656@qq.com" ]
670176656@qq.com
1eef923f3eb066f22e07cdc86defb67499018041
fb2cdbfcbb4d99f6cea88d58c6e6d91682009ad2
/weixin-web/src/main/java/com/cheng/weixin/web/security/SystemAuthorizingRealm.java
b57051f1b23cc99056bd55fd73ae214d78cdae82
[]
no_license
chengzhx76/Weixin0.1
f4e3c93542965e8e13396eddd0ee64e1d822932a
7b68d1f45fb234cc4472485061985f032e85f031
refs/heads/master
2021-01-10T13:36:45.450526
2016-03-28T10:19:39
2016-03-28T10:19:39
49,940,558
1
1
null
null
null
null
UTF-8
Java
false
false
4,253
java
package com.cheng.weixin.web.security; import com.cheng.weixin.core.entity.Admin; import com.cheng.weixin.core.entity.enums.Status; import com.cheng.weixin.core.service.IAdminService; import com.cheng.weixin.core.utils.Encodes; import com.cheng.weixin.web.utils.Captcha; import com.cheng.weixin.web.utils.UserUtils; import org.apache.shiro.authc.*; import org.apache.shiro.authz.AuthorizationInfo; import org.apache.shiro.realm.AuthorizingRealm; import org.apache.shiro.subject.PrincipalCollection; import org.apache.shiro.util.ByteSource; import org.springframework.beans.factory.annotation.Autowired; import java.io.Serializable; /** * Desc: 登录认证与授权 * Author: Cheng * Date: 2016/1/26 0026 */ public class SystemAuthorizingRealm extends AuthorizingRealm { @Autowired private IAdminService adminService; // 返回一个唯一的Realm名字 @Override public String getName() { return super.getName(); } // 判断此Realm是否支持此Token @Override public boolean supports(AuthenticationToken token) { return token instanceof WxUsernamePasswordToken ; } // 认证 @Override protected AuthenticationInfo doGetAuthenticationInfo(AuthenticationToken authenticationToken) throws AuthenticationException { WxUsernamePasswordToken token = (WxUsernamePasswordToken) authenticationToken; // 判断验证码是否正确 if (Captcha.isValidateCodeLogin(token.getUsername(), false, false)) { String captcha = (String) UserUtils.getSession().getAttribute(Captcha.CAPTCHA); if (null == token.getCaptcha() || !token.getCaptcha().equalsIgnoreCase(captcha)) { throw new AuthenticationException("msg:验证码错误,请重试."); } } // 校验用户名 Admin admin = adminService.getUserByUsername(token.getUsername()); if(admin != null) { if(admin.getStatus().equals(Status.LOCKED)) { throw new LockedAccountException("msg:该帐号已禁止登录."); } byte[] salt = Encodes.decodeHex(admin.getPassword().substring(0, 16)); return new SimpleAuthenticationInfo(new Principal(admin, token.isMobilelogin()), admin.getPassword().substring(16), ByteSource.Util.bytes(salt), getName()); } return null; } // 授权 @Override protected AuthorizationInfo doGetAuthorizationInfo(PrincipalCollection principalCollection) { System.out.println("=======AuthorizationInfo======="); return null; } /** * 授权信息 */ public static class Principal implements Serializable { private static final long serialVersionUID = 2866069566032650619L; /** 编号 **/ private String id; /** 登录名 **/ private String username; /** 是否是手机登录 **/ private boolean mobileLogin; public Principal(Admin admin, boolean mobileLogin) { this.id = admin.getId(); this.username = admin.getUsername(); this.mobileLogin = mobileLogin; } public String getId() { return id; } public void setId(String id) { this.id = id; } public String getUsername() { return username; } public void setUsername(String username) { this.username = username; } public boolean isMobileLogin() { return mobileLogin; } public void setMobileLogin(boolean mobileLogin) { this.mobileLogin = mobileLogin; } } /** * 设定密码校验的Hash算法与迭代次数 * !这里已在xml配置了 id=hashMatcher */ /*@PostConstruct public void initCredentialsMatcher() { HashedCredentialsMatcher matcher = new HashedCredentialsMatcher(); // 设置加密方式 matcher.setHashAlgorithmName(SystemUtils.HASH_ALGORITHM); // 设置迭代次数 matcher.setHashIterations(SystemUtils.HASH_INTERATIONS); // 注入到Shrio里自定义的加密方式 setCredentialsMatcher(matcher); }*/ }
[ "chengzhx76@qq.com" ]
chengzhx76@qq.com
af6e015d771efad30280be562608f814597c5a58
dd4b50b6407479d4745317c04940f28380445165
/pac4j-oauth/src/test/java/org/pac4j/oauth/run/RunPaypalClient.java
5a0564c4fd1433f853cb35f4dfe9b0a9f487d3be
[ "Apache-2.0", "LicenseRef-scancode-warranty-disclaimer" ]
permissive
qmwu2000/pac4j
f3344b8204ac44a7ded0b53d03c45e1dab370dbb
7ec522cc7179c63014edfe1c0af3b2db1f006a3a
refs/heads/master
2021-01-17T06:36:52.321221
2016-03-05T08:41:13
2016-03-05T08:41:13
53,256,748
0
1
null
2016-03-06T13:41:42
2016-03-06T13:41:41
null
UTF-8
Java
false
false
2,696
java
package org.pac4j.oauth.run; import com.esotericsoftware.kryo.Kryo; import org.pac4j.core.client.IndirectClient; import org.pac4j.core.run.RunClient; import org.pac4j.core.profile.Gender; import org.pac4j.core.profile.ProfileHelper; import org.pac4j.core.profile.UserProfile; import org.pac4j.core.util.CommonHelper; import org.pac4j.oauth.client.PayPalClient; import org.pac4j.oauth.profile.paypal.PayPalAddress; import org.pac4j.oauth.profile.paypal.PayPalProfile; import java.util.Locale; import static org.junit.Assert.*; /** * Run manually a test for the {@link PayPalClient}. * * @author Jerome Leleu * @since 1.9.0 */ public final class RunPaypalClient extends RunClient { public static void main(String[] args) throws Exception { new RunPaypalClient().run(); } @Override protected String getLogin() { return "testscribeup@gmail.com"; } @Override protected String getPassword() { return "a1z2e3r4!$"; } @Override protected IndirectClient getClient() { final PayPalClient payPalClient = new PayPalClient( "ARQFlBAOdRsb1NhZlutHT_PORP2F-TQpU-Laz-osaBwAHUIBIdg-C8DEsTWY", "EAMZPBBfYJGeCBHYkm30xqC-VZ1kePnWZzPLdXyzY43rh-q0OQUH5eucXI6R"); payPalClient.setCallbackUrl(PAC4J_BASE_URL); return payPalClient; } @Override protected void registerForKryo(final Kryo kryo) { kryo.register(PayPalProfile.class); kryo.register(PayPalAddress.class); } @Override protected void verifyProfile(UserProfile userProfile) { final PayPalProfile profile = (PayPalProfile) userProfile; assertEquals("YAxf5WKSFn4BG_l3wqcBJUSObQTG1Aww5FY0EDf_ccw", profile.getId()); assertEquals(PayPalProfile.class.getName() + UserProfile.SEPARATOR + "YAxf5WKSFn4BG_l3wqcBJUSObQTG1Aww5FY0EDf_ccw", profile.getTypedId()); assertTrue(ProfileHelper.isTypedIdOf(profile.getTypedId(), PayPalProfile.class)); assertTrue(CommonHelper.isNotBlank(profile.getAccessToken())); assertCommonProfile(userProfile, "testscribeup@gmail.com", "Test", "ScribeUP", "Test ScribeUP", null, Gender.UNSPECIFIED, Locale.FRANCE, null, null, "Europe/Berlin"); final PayPalAddress address = profile.getAddress(); assertEquals("FR", address.getCountry()); assertEquals("Paris", address.getLocality()); assertEquals("75001", address.getPostalCode()); assertEquals("Adr1", address.getStreetAddress()); final Locale language = profile.getLanguage(); assertEquals(Locale.FRANCE, language); assertEquals(9, profile.getAttributes().size()); } }
[ "leleuj@gmail.com" ]
leleuj@gmail.com
de762c7bb781b36caf0ce74c6936ddcd92fbc5f5
ed3240a7cbf90ec71bb2c3e4c0d0c7dfe50b308d
/Swing14-WorkingWithListData/src/main/java/com/jin/MainFrame.java
c38144da1e71df5c661eb1fbb6b69318aa3196cb
[]
no_license
cicadasworld/java-swing-demo
85ae5ab1586cf75ba55d0520ae7d93458ef79ec2
f2f374942a237ab20a9ce733e820eacccdb4afd4
refs/heads/master
2022-11-11T22:03:54.867406
2020-06-26T10:20:54
2020-06-26T10:20:54
275,127,960
0
0
null
null
null
null
UTF-8
Java
false
false
1,087
java
package com.jin; import java.awt.*; import javax.swing.*; public class MainFrame extends JFrame { private final TextPanel textPanel; private final Toolbar toolbar; private final FormPanel formPanel; public MainFrame() { super("Hello World"); this.setLayout(new BorderLayout()); toolbar = new Toolbar(); textPanel = new TextPanel(); formPanel = new FormPanel(); toolbar.setTextListener(textPanel::appendText); formPanel.setFormListener(e -> { String name = e.getName(); String occupation = e.getOccupation(); int ageCat = e.getAgeCategory(); textPanel.appendText(name + ": " + occupation + ": " + ageCat + "\n"); }); this.add(formPanel, BorderLayout.WEST); this.add(toolbar, BorderLayout.NORTH); this.add(textPanel, BorderLayout.CENTER); this.setSize(600, 500); this.setLocationRelativeTo(null); // To center this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); this.setVisible(true); } }
[ "flyterren@163.com" ]
flyterren@163.com
ac1b63676c8fdb02a26aae99930134199534c20b
c576f2b0663b7bad90d148e422cdb307d1f8d43a
/src/main/java/javax/measure/quantity/ElectricCharge.java
66e189ab4a81896796c63f61789989ee91f64b1f
[ "BSD-2-Clause" ]
permissive
chrisdennis/unit-api
03dc61a960f046e77c4c57bbbd2a9bbf06253050
21c64b06eaa09cc0e141d91429c19c0d0d65f7a7
refs/heads/master
2021-01-17T08:21:35.438165
2015-11-10T21:00:21
2015-11-10T21:00:21
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,967
java
/* * Units of Measurement API * Copyright (c) 2014-2015, Jean-Marie Dautelle, Werner Keil, V2COM. * * 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. Neither the name of JSR-363 nor the names of its contributors may be used to endorse or promote products * derived from this software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ package javax.measure.quantity; import javax.measure.Quantity; /** * Electric charge. * The metric system unit for this quantity is "C" (Coulomb). * * @author <a href="mailto:jean-marie@dautelle.com">Jean-Marie Dautelle</a> * @version 1.0 * * @see ElectricCurrent */ public interface ElectricCharge extends Quantity<ElectricCharge> { }
[ "werner.keil@gmx.net" ]
werner.keil@gmx.net
3319b65ed971124ca03d93936fa7b39203f24266
dfd7e70936b123ee98e8a2d34ef41e4260ec3ade
/analysis/reverse-engineering/decompile-fitts-20191031-2200/sources/com/google/android/gms/internal/clearcut/zzaw.java
b796b6ede82816697b8f99576cbaad1c1f44d7a0
[ "Apache-2.0" ]
permissive
skkuse-adv/2019Fall_team2
2d4f75bc793368faac4ca8a2916b081ad49b7283
3ea84c6be39855f54634a7f9b1093e80893886eb
refs/heads/master
2020-08-07T03:41:11.447376
2019-12-21T04:06:34
2019-12-21T04:06:34
213,271,174
5
5
Apache-2.0
2019-12-12T09:15:32
2019-10-07T01:18:59
Java
UTF-8
Java
false
false
557
java
package com.google.android.gms.internal.clearcut; final class zzaw { private static final Class<?> zzfb = zze("libcore.io.Memory"); private static final boolean zzfc = (zze("org.robolectric.Robolectric") != null); private static <T> Class<T> zze(String str) { try { return Class.forName(str); } catch (Throwable unused) { return null; } } static boolean zzx() { return zzfb != null && !zzfc; } static Class<?> zzy() { return zzfb; } }
[ "33246398+ajid951125@users.noreply.github.com" ]
33246398+ajid951125@users.noreply.github.com
cfad2757392894373726e50f7f918ec06f756813
0d18b69be9b92defaaa97f31c98b965dd91819e4
/guns-admin/src/main/java/com/guo/guns/modular/system/service/IDictService.java
471e533d4497ff32e7ba568d3d79ba3273b91771
[ "Apache-2.0" ]
permissive
tuyugg123/guo-projects
bc9cda10847bed9d1b69479acdb5a533c96e154e
596acd3f0adda5b23f9e8f693884aa03abc20828
refs/heads/master
2020-03-07T04:38:13.505116
2018-03-05T17:32:07
2018-03-05T17:32:07
null
0
0
null
null
null
null
UTF-8
Java
false
false
613
java
package com.guo.guns.modular.system.service; /** * 字典服务 * * @author fengshuonan * @date 2017-04-27 17:00 */ public interface IDictService { /** * 添加字典 * * @author fengshuonan * @Date 2017/4/27 17:01 */ void addDict(String dictName, String dictValues); /** * 编辑字典 * * @author fengshuonan * @Date 2017/4/28 11:01 */ void editDict(Integer dictId, String dictName, String dicts); /** * 删除字典 * * @author fengshuonan * @Date 2017/4/28 11:39 */ void delteDict(Integer dictId); }
[ "gxx632364@gmail.com" ]
gxx632364@gmail.com
9d9de18fc68190317206df5371b218cdcbb8c087
a2df6764e9f4350e0d9184efadb6c92c40d40212
/aliyun-java-sdk-aliyuncvc/src/main/java/com/aliyuncs/aliyuncvc/model/v20190919/CheckMeetingCodeResponse.java
9e3ee8412dc640c299899af4865c77ba154ea12f
[ "Apache-2.0" ]
permissive
warriorsZXX/aliyun-openapi-java-sdk
567840c4bdd438d43be6bd21edde86585cd6274a
f8fd2b81a5f2cd46b1e31974ff6a7afed111a245
refs/heads/master
2022-12-06T15:45:20.418475
2020-08-20T08:37:31
2020-08-26T06:17:49
290,450,773
1
0
NOASSERTION
2020-08-26T09:15:48
2020-08-26T09:15:47
null
UTF-8
Java
false
false
4,336
java
/* * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.aliyuncs.aliyuncvc.model.v20190919; import com.aliyuncs.AcsResponse; import com.aliyuncs.aliyuncvc.transform.v20190919.CheckMeetingCodeResponseUnmarshaller; import com.aliyuncs.transform.UnmarshallerContext; /** * @author auto create * @version */ public class CheckMeetingCodeResponse extends AcsResponse { private Integer errorCode; private Boolean success; private String requestId; private String message; private MeetingInfo meetingInfo; public Integer getErrorCode() { return this.errorCode; } public void setErrorCode(Integer errorCode) { this.errorCode = errorCode; } public Boolean getSuccess() { return this.success; } public void setSuccess(Boolean success) { this.success = success; } public String getRequestId() { return this.requestId; } public void setRequestId(String requestId) { this.requestId = requestId; } public String getMessage() { return this.message; } public void setMessage(String message) { this.message = message; } public MeetingInfo getMeetingInfo() { return this.meetingInfo; } public void setMeetingInfo(MeetingInfo meetingInfo) { this.meetingInfo = meetingInfo; } public static class MeetingInfo { private String meetingDomain; private String meetingToken; private String meetingCode; private String memberUUID; private String clientAppId; private String meetingUUID; private String meetingAppId; private SlsInfo slsInfo; public String getMeetingDomain() { return this.meetingDomain; } public void setMeetingDomain(String meetingDomain) { this.meetingDomain = meetingDomain; } public String getMeetingToken() { return this.meetingToken; } public void setMeetingToken(String meetingToken) { this.meetingToken = meetingToken; } public String getMeetingCode() { return this.meetingCode; } public void setMeetingCode(String meetingCode) { this.meetingCode = meetingCode; } public String getMemberUUID() { return this.memberUUID; } public void setMemberUUID(String memberUUID) { this.memberUUID = memberUUID; } public String getClientAppId() { return this.clientAppId; } public void setClientAppId(String clientAppId) { this.clientAppId = clientAppId; } public String getMeetingUUID() { return this.meetingUUID; } public void setMeetingUUID(String meetingUUID) { this.meetingUUID = meetingUUID; } public String getMeetingAppId() { return this.meetingAppId; } public void setMeetingAppId(String meetingAppId) { this.meetingAppId = meetingAppId; } public SlsInfo getSlsInfo() { return this.slsInfo; } public void setSlsInfo(SlsInfo slsInfo) { this.slsInfo = slsInfo; } public static class SlsInfo { private String logServiceEndpoint; private String logstore; private String project; public String getLogServiceEndpoint() { return this.logServiceEndpoint; } public void setLogServiceEndpoint(String logServiceEndpoint) { this.logServiceEndpoint = logServiceEndpoint; } public String getLogstore() { return this.logstore; } public void setLogstore(String logstore) { this.logstore = logstore; } public String getProject() { return this.project; } public void setProject(String project) { this.project = project; } } } @Override public CheckMeetingCodeResponse getInstance(UnmarshallerContext context) { return CheckMeetingCodeResponseUnmarshaller.unmarshall(this, context); } @Override public boolean checkShowJsonItemName() { return false; } }
[ "sdk-team@alibabacloud.com" ]
sdk-team@alibabacloud.com
bc149e4380362f6a917f78c5446d99a4e110aa2c
4ce0078b0375b9e2e594d82cb55d2f35efd2597d
/sdlv/src/main/java/com/yydcdut/sdlv/Callback.java
852d7403923fd1b3f4305d661e5a747325c9f443
[ "Apache-2.0", "LicenseRef-scancode-warranty-disclaimer" ]
permissive
wilco375/SlideAndDragListView
4da4f3674452bab74d1176dd202c44bf17840f82
2a5d4e8c06b41b91c6da6465f7c35fe09061fa34
refs/heads/master
2020-03-24T10:30:27.291326
2018-07-28T10:06:42
2018-07-28T10:06:42
142,658,267
0
0
Apache-2.0
2018-07-28T07:51:24
2018-07-28T07:51:24
null
UTF-8
Java
false
false
1,517
java
/* * Copyright (C) 2015 yydcdut (yuyidong2015@gmail.com) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.yydcdut.sdlv; import android.view.View; import android.widget.AbsListView; /** * Created by yuyidong on 2017/5/16. */ interface Callback { interface OnDragDropListener { boolean onDragStarted(int x, int y, View view); void onDragMoving(int x, int y, View view, SlideAndDragListView.OnDragDropListener listener); void onDragFinished(int x, int y, SlideAndDragListView.OnDragDropListener listener); } interface OnScrollListenerWrapper { void onScrollStateChanged(AbsListView view, int scrollState); void onScroll(AbsListView view, int firstVisibleItem, int visibleItemCount, int totalItemCount); } interface OnItemLongClickListenerWrapper { void onListItemLongClick(View view, int position); } interface OnItemClickListenerWrapper { void onListItemClick(View v, int position); } }
[ "378040621@qq.com" ]
378040621@qq.com
c6376fb5d437b4183fd19f5ac42ece0374b04024
302af4aa0bf08a66dde5fa95bc6e8992e4505c7d
/com.gumtree.android.beta/java/novoda/lib/sqliteprovider/cursor/EmptyCursor.java
7b29d7b90d97d29da5e784145fe74cccb4367203
[]
no_license
hakat0m/Chessboxing
0f5ce696a55a5b40f1d8fa226bbdc5673ef5dbc5
0a576dec5aaafa219c340a013726037d852b91a2
refs/heads/master
2021-01-19T08:51:23.932830
2017-04-09T06:48:44
2017-04-09T06:48:44
87,688,753
3
0
null
null
null
null
UTF-8
Java
false
false
708
java
package novoda.lib.sqliteprovider.cursor; import android.database.AbstractCursor; public class EmptyCursor extends AbstractCursor { public String[] getColumnNames() { return new String[]{"_id"}; } public int getCount() { return 0; } public double getDouble(int i) { return 0.0d; } public float getFloat(int i) { return 0.0f; } public int getInt(int i) { return 0; } public long getLong(int i) { return 0; } public short getShort(int i) { return (short) 0; } public String getString(int i) { return null; } public boolean isNull(int i) { return true; } }
[ "vuesz@outlook.com" ]
vuesz@outlook.com
f6db8dc4a0568bc64508d64d90118a0447843e9a
0eb1a5ea1afb5aec9d2652767e8391eeadf4370f
/retail-store/src/main/java/com/retail/store/model/CartItem.java
dbc6651081687fb9d04fe782c0c17bc0e66ce2cd
[]
no_license
yogeshrnaik/projects
36b2b6e115c45a562a5206ab7280d7933c072561
fed554cd365865a6e505d2c146fc820931d78da0
refs/heads/master
2022-12-23T05:32:11.548117
2022-09-08T07:48:48
2022-09-08T07:48:48
40,397,110
6
8
null
2022-12-16T03:41:00
2015-08-08T08:47:28
Java
UTF-8
Java
false
false
2,457
java
package com.retail.store.model; import java.io.Serializable; import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.GeneratedValue; import javax.persistence.GenerationType; import javax.persistence.Id; import javax.persistence.ManyToOne; import javax.persistence.Table; import javax.validation.constraints.NotNull; @Entity @Table(name = "cart_items") public class CartItem implements Serializable { private static final long serialVersionUID = -5454681550675014977L; @Id @Column(name = "id") @GeneratedValue(strategy = GenerationType.IDENTITY) private Long id; @ManyToOne private Product product; @ManyToOne private Cart cart; @NotNull private int quantity; private double salesTax; private double priceBeforeTax; private double totalPrice; public CartItem() { } public CartItem(Product product, int quantity, Cart cart) { this(null, product, quantity, cart); } public CartItem(Long id, Product product, int quantity, Cart cart) { this.id = id; this.product = product; this.quantity = quantity; this.cart = cart; updateQuantity(quantity); } public Long getId() { return id; } public void setId(Long id) { this.id = id; } public Product getProduct() { return product; } public void setProduct(Product product) { this.product = product; } public int getQuantity() { return quantity; } public void setQuantity(int quantity) { this.quantity = quantity; } public Double getSalesTax() { return salesTax; } public void setSalesTax(Double salesTax) { this.salesTax = salesTax; } public Double getPriceBeforeTax() { return priceBeforeTax; } public void setPriceBeforeTax(Double price) { priceBeforeTax = price; } public double getTotalPrice() { return totalPrice; } public void setTotalPrice(double totalPrice) { this.totalPrice = totalPrice; } public void setSalesTax(double salesTax) { this.salesTax = salesTax; } public void updateQuantity(int quantity) { setQuantity(quantity); priceBeforeTax = product.calculatePrice(quantity); salesTax = product.calculateSalesTax(quantity); totalPrice = priceBeforeTax + salesTax; } }
[ "yogeshrnaik@gmail.com" ]
yogeshrnaik@gmail.com
19cd1f67a7d67aaeb6decbd3e3de4e84dcc1ca98
a5d01febfd8d45a61f815b6f5ed447e25fad4959
/Source Code/5.27.0/sources/com/iqoption/fragment/assets/i.java
373aac1dce393c34677adcea312e7ae421cf3c75
[]
no_license
kkagill/Decompiler-IQ-Option
7fe5911f90ed2490687f5d216cb2940f07b57194
c2a9dbbe79a959aa1ab8bb7a89c735e8f9dbc5a6
refs/heads/master
2020-09-14T20:44:49.115289
2019-11-04T06:58:55
2019-11-04T06:58:55
223,236,327
1
0
null
2019-11-21T18:17:17
2019-11-21T18:17:16
null
UTF-8
Java
false
false
434
java
package com.iqoption.fragment.assets; import com.iqoption.fragment.assets.model.AssetSortType; @kotlin.i(bne = {1, 1, 15}) public final /* synthetic */ class i { public static final /* synthetic */ int[] aob = new int[AssetSortType.values().length]; static { aob[AssetSortType.BY_DIFF.ordinal()] = 1; aob[AssetSortType.BY_SPREAD.ordinal()] = 2; aob[AssetSortType.BY_LEVERAGE.ordinal()] = 3; } }
[ "yihsun1992@gmail.com" ]
yihsun1992@gmail.com
8d31b6e635924055e45ecdb46b5af7b65b08e9bc
683357e10855417d77c9ca24c889b8e20cb50510
/core/src/main/java/com/karltech/tpk/core/service/FixExpenseServiceImpl.java
d914cd0f53b35804f2e77cb9772346d6ca49e077
[]
no_license
chuquockhanh/tpkwhm
49852487637ba1a51712b55d57bcd580811fec9a
54b2bbec37592f5be29802dad9c7e3e796b92bdb
refs/heads/master
2021-01-10T13:03:56.086654
2015-10-13T15:41:26
2015-10-13T15:41:26
44,185,475
0
0
null
null
null
null
UTF-8
Java
false
false
2,687
java
package com.karltech.tpk.core.service; import com.karltech.tpk.core.dao.FixExpenseDAO; import com.karltech.tpk.core.dao.GenericDAO; import com.karltech.tpk.core.domain.FixExpense; import com.karltech.tpk.core.dto.FixExpenseBean; import com.karltech.tpk.core.exception.DuplicateException; import com.karltech.tpk.core.exception.ObjectNotFoundException; import org.apache.commons.lang.StringUtils; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import java.util.HashMap; import java.util.List; import java.util.Map; public class FixExpenseServiceImpl extends GenericServiceImpl<FixExpense,Long> implements FixExpenseService { protected final Log logger = LogFactory.getLog(getClass()); private FixExpenseDAO fixExpenseDAO; public void setFixExpenseDAO(FixExpenseDAO fixExpenseDAO) { this.fixExpenseDAO = fixExpenseDAO; } @Override protected GenericDAO<FixExpense, Long> getGenericDAO() { return fixExpenseDAO; } @Override public void updateItem(FixExpenseBean colourBean) throws ObjectNotFoundException, DuplicateException { FixExpense dbItem = this.fixExpenseDAO.findByIdNoAutoCommit(colourBean.getPojo().getFixExpenseID()); if (dbItem == null) throw new ObjectNotFoundException("Not found FixExpense " + colourBean.getPojo().getFixExpenseID()); FixExpense pojo = colourBean.getPojo(); this.fixExpenseDAO.detach(dbItem); this.fixExpenseDAO.update(pojo); } @Override public void addNew(FixExpenseBean colourBean) throws DuplicateException { FixExpense pojo = colourBean.getPojo(); pojo = this.fixExpenseDAO.save(pojo); colourBean.setPojo(pojo); } @Override public Integer deleteItems(String[] checkList) { Integer res = 0; if (checkList != null && checkList.length > 0) { res = checkList.length; for (String id : checkList) { fixExpenseDAO.delete(Long.parseLong(id)); } } return res; } @Override public Object[] search(FixExpenseBean bean) { Map<String, Object> properties = new HashMap<String, Object>(); if (StringUtils.isNotBlank(bean.getPojo().getName())) { properties.put("name", bean.getPojo().getName()); } return this.fixExpenseDAO.searchByProperties(properties, bean.getFirstItem(), bean.getMaxPageItems(), bean.getSortExpression(), bean.getSortDirection(), true); } @Override public List<FixExpense> findAllByOrder(String name) { return this.fixExpenseDAO.findAllByOrder(name); } }
[ "khanh.chu@hoanghoacgroup.com" ]
khanh.chu@hoanghoacgroup.com
68a3c9c6b64708aaa4930910899fe5f1275260f4
b0cce84067ea5d37bf126bf671620a15b9d90890
/app/src/main/java/com/mouqu/zhailu/zhailu/bean/CardBean.java
38dc7169fd98faab26e73d6efac02fdac8ce7a48
[]
no_license
18668197127/ZhailuQB
f4df02dda885c5c8f19ef67857374f4b388542bd
846f5d29df4d2c2fa7bad2f6239a2e41701e2c11
refs/heads/master
2020-04-17T16:30:39.044861
2019-01-21T03:39:06
2019-01-21T03:39:06
166,743,120
0
0
null
null
null
null
UTF-8
Java
false
false
618
java
package com.mouqu.zhailu.zhailu.bean; import com.contrarywind.interfaces.IPickerViewData; public class CardBean implements IPickerViewData { int id; String cardNo; public CardBean(int id, String cardNo) { this.id = id; this.cardNo = cardNo; } public int getId() { return id; } public void setId(int id) { this.id = id; } public String getCardNo() { return cardNo; } public void setCardNo(String cardNo) { this.cardNo = cardNo; } @Override public String getPickerViewText() { return cardNo; } }
[ "1013273644@qq.com" ]
1013273644@qq.com
e8d1d7368cfbc0003c0b29aeb227f3492f268e4b
48e835e6f176a8ac9ae3ca718e8922891f1e5a18
/benchmark/training/com/google/cloud/DateTest.java
08e4a2c145ab3fd9d082a988c44dc0c85b377755
[]
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
3,187
java
/** * Copyright 2017 Google LLC * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.google.cloud; import com.google.common.testing.EqualsTester; import java.text.ParseException; import java.text.SimpleDateFormat; import org.junit.Test; import org.junit.runner.RunWith; import org.junit.runners.JUnit4; /** * Unit tests for {@link Date}. */ @RunWith(JUnit4.class) public class DateTest { private static final SimpleDateFormat SIMPLE_DATE_FORMAT = new SimpleDateFormat("yyyy-MM-dd"); @Test public void parseDate() { Date date = Date.parseDate("2016-09-18"); assertThat(date.getYear()).isEqualTo(2016); assertThat(date.getMonth()).isEqualTo(9); assertThat(date.getDayOfMonth()).isEqualTo(18); } @Test public void testToString() { Date date = Date.fromYearMonthDay(10, 9, 5); assertThat(date.toString()).isEqualTo("0010-09-05"); date = Date.fromYearMonthDay(2016, 12, 31); assertThat(date.toString()).isEqualTo("2016-12-31"); date = Date.fromYearMonthDay(1, 1, 1); assertThat(date.toString()).isEqualTo("0001-01-01"); } @Test public void equalAndHashCode() { Date d1 = Date.fromYearMonthDay(2016, 9, 18); Date d2 = Date.fromYearMonthDay(2016, 9, 18); Date d3 = Date.fromYearMonthDay(2016, 9, 19); EqualsTester tester = new EqualsTester(); tester.addEqualityGroup(d1, d2); tester.addEqualityGroup(d3); } @Test public void validOrdering() { Date d1 = Date.fromYearMonthDay(2016, 9, 18); Date d2 = Date.fromYearMonthDay(2016, 9, 19); Date d3 = Date.fromYearMonthDay(2016, 9, 20); Date d4 = Date.fromYearMonthDay(2016, 10, 1); Date d5 = Date.fromYearMonthDay(2017, 1, 1); assertDescending(d5, d4, d3, d2, d1); } @Test public void serialization() { reserializeAndAssert(Date.fromYearMonthDay(2017, 4, 20)); } @Test public void testToJavaUtilDate() throws ParseException { Date gcDate = Date.parseDate("2016-09-18"); java.util.Date juDate1 = DateTest.SIMPLE_DATE_FORMAT.parse("2016-09-18"); java.util.Date juDate2 = Date.toJavaUtilDate(gcDate); assertThat(juDate1).isEqualTo(juDate2); } @Test public void testFromJavaUtilDate() throws ParseException { java.util.Date juDate = DateTest.SIMPLE_DATE_FORMAT.parse("2016-09-18"); Date gcDate = Date.fromJavaUtilDate(juDate); assertThat(gcDate.getYear()).isEqualTo(2016); assertThat(gcDate.getMonth()).isEqualTo(9); assertThat(gcDate.getDayOfMonth()).isEqualTo(18); } }
[ "benjamin.danglot@inria.fr" ]
benjamin.danglot@inria.fr
689a5bd6f8101dcd750fde1462ed9a276caf8fb1
34c8b01849d7265c73bcc696e7f0c11312c7f84d
/src/java/org/apache/commons/jelly/impl/TextScript.java
ec8fda1e5c0ca5dc4fc877aa6afe19d808d4a21f
[ "Apache-2.0" ]
permissive
pwntester/jelly
03ddb422005970ddfc86f0e1cc7c5b5a84f7e431
cb7966734f339619e5ee8e57b08009acbf5e1d10
refs/heads/master
2021-01-16T11:55:47.916026
2017-11-27T20:21:47
2017-11-27T20:21:47
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,365
java
/* * Copyright 2002,2004 The Apache Software Foundation. * * 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.apache.commons.jelly.impl; import org.apache.commons.jelly.JellyContext; import org.apache.commons.jelly.JellyTagException; import org.apache.commons.jelly.Script; import org.apache.commons.jelly.XMLOutput; import org.xml.sax.SAXException; /** <p><code>TextScript</code> outputs some static text.</p> * * @author <a href="mailto:jstrachan@apache.org">James Strachan</a> * @version $Revision: 155420 $ */ public class TextScript implements Script { /** the text output by this script */ private String text; public TextScript() { } public TextScript(String text) { this.text = text; } public String toString() { return super.toString() + "[text=" + text + "]"; } /** * Trims whitespace if this is ignorable whitespace. */ public void trimWhitespace() { if(text.trim().length()==0) this.text = ""; } /** @return the text output by this script */ public String getText() { return text; } /** Sets the text output by this script */ public void setText(String text) { this.text = text; } // Script interface //------------------------------------------------------------------------- public Script compile() { return this; } /** Evaluates the body of a tag */ public void run(JellyContext context, XMLOutput output) throws JellyTagException { if ( text != null ) { try { output.write(text); } catch (SAXException e) { throw new JellyTagException("could not write to XMLOutput",e); } } } }
[ "kk@kohsuke.org" ]
kk@kohsuke.org
f730d33a67417e0a207516ac8c7e1f404673c10c
0609091f8d71b6c90a2d4fed4138f7038e7bf9e2
/app/src/main/java/com/ldcovid19project/OnlineDoctorsActivity.java
1f7625835fed603888ecf0ffd4968402b27ee300
[]
no_license
COVID-19-Apps/LD-Covid-19-Project
995cfb3272c865541d2c85186355d96c913943fd
0f760da435c6fb7a26937e691eb70e47b6c41c9d
refs/heads/master
2022-11-19T19:39:54.126318
2020-07-20T07:05:03
2020-07-20T07:05:03
281,040,219
0
0
null
null
null
null
UTF-8
Java
false
false
6,934
java
package com.ldcovid19project; import androidx.appcompat.app.AlertDialog; import androidx.appcompat.app.AppCompatActivity; import androidx.appcompat.widget.SearchView; import androidx.recyclerview.widget.LinearLayoutManager; import androidx.recyclerview.widget.RecyclerView; import android.app.SearchManager; import android.content.Context; import android.content.DialogInterface; import android.content.Intent; import android.net.ConnectivityManager; import android.os.Bundle; import android.view.Menu; import android.view.MenuItem; import android.view.View; import android.widget.ImageView; import android.widget.RelativeLayout; import android.widget.Toast; import com.ldcovid19project.Adapter.PersonAdapter; import com.ldcovid19project.Models.Persons; import com.google.android.material.floatingactionbutton.FloatingActionButton; import com.google.firebase.auth.FirebaseAuth; import com.google.firebase.auth.FirebaseUser; import com.google.firebase.database.DataSnapshot; import com.google.firebase.database.DatabaseError; import com.google.firebase.database.DatabaseReference; import com.google.firebase.database.FirebaseDatabase; import com.google.firebase.database.ValueEventListener; import java.util.ArrayList; import java.util.Collections; import java.util.List; public class OnlineDoctorsActivity extends AppCompatActivity implements PersonAdapter.SearchAdapterListener { private FloatingActionButton Add; private RecyclerView mPersonList; private PersonAdapter personAdapter; private List<Persons> personsList; private RelativeLayout mNoPersons; private DatabaseReference mPersonsDatabase; private SearchView searchView; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_online_doctors); Add = findViewById(R.id.add); mNoPersons = findViewById(R.id.no_persons); mPersonList = findViewById(R.id.volunteer_list); mPersonsDatabase = FirebaseDatabase.getInstance().getReference().child("Persons"); mPersonsDatabase.keepSynced(true); mPersonList.setHasFixedSize(true); LinearLayoutManager mLayoutManager = new LinearLayoutManager(this); mPersonList.setLayoutManager(mLayoutManager); personsList = new ArrayList<>(); personAdapter = new PersonAdapter(this, personsList, this); mPersonList.setAdapter(personAdapter); readPersons("Doctor Online Appointment"); Add.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { if (isNetworkConnected()) { AlertDialog.Builder builder = new AlertDialog.Builder(OnlineDoctorsActivity.this); builder.setMessage("Do you want to become Online Doctor ?").setTitle("Doctor Online Appointment"); builder.setCancelable(false) .setPositiveButton("Yes", new DialogInterface.OnClickListener() { public void onClick(DialogInterface dialog, int id) { Intent intent = new Intent(OnlineDoctorsActivity.this, ConfirmActivity.class); startActivity(intent); dialog.dismiss(); } }) .setNegativeButton("No", new DialogInterface.OnClickListener() { public void onClick(DialogInterface dialog, int id) { dialog.cancel(); } }); AlertDialog alert = builder.create(); alert.setTitle("Doctor Online Appointment"); alert.show(); } else { Toast.makeText(OnlineDoctorsActivity.this, "Connect to Internet", Toast.LENGTH_SHORT).show(); } } }); } private void readPersons(final String title) { mPersonsDatabase.addValueEventListener(new ValueEventListener() { @Override public void onDataChange(DataSnapshot dataSnapshot) { if (dataSnapshot.exists()) { personsList.clear(); for (DataSnapshot snapshot : dataSnapshot.getChildren()) { Persons myStatus = snapshot.getValue(Persons.class); if (myStatus.getType().contains(title)) personsList.add(myStatus); } if (!personsList.isEmpty()) { mPersonList.setVisibility(View.VISIBLE); mNoPersons.setVisibility(View.GONE); personAdapter.notifyDataSetChanged(); }else{ mNoPersons.setVisibility(View.VISIBLE); mPersonList.setVisibility(View.GONE); } } else { mNoPersons.setVisibility(View.VISIBLE); mPersonList.setVisibility(View.GONE); } } @Override public void onCancelled(DatabaseError databaseError) { } }); } private boolean isNetworkConnected() { ConnectivityManager cm = (ConnectivityManager) getSystemService(Context.CONNECTIVITY_SERVICE); return cm.getActiveNetworkInfo() != null && cm.getActiveNetworkInfo().isConnected(); } @Override public void onSearchSelected(Persons persons) { } @Override public boolean onCreateOptionsMenu(Menu menu) { getMenuInflater().inflate(R.menu.menu_search, menu); SearchManager searchManager = (SearchManager) getSystemService(Context.SEARCH_SERVICE); searchView = (SearchView) menu.findItem(R.id.action_search) .getActionView(); searchView.setSearchableInfo(searchManager .getSearchableInfo(getComponentName())); searchView.setMaxWidth(Integer.MAX_VALUE); searchView.setOnQueryTextListener(new SearchView.OnQueryTextListener() { @Override public boolean onQueryTextSubmit(String query) { personAdapter.getFilter().filter(query); return false; } @Override public boolean onQueryTextChange(String query) { personAdapter.getFilter().filter(query); return false; } }); return true; } @Override public boolean onOptionsItemSelected(MenuItem item) { int id = item.getItemId(); if (id == R.id.action_search) { return true; } return super.onOptionsItemSelected(item); } }
[ "anandhamurthy2000@gmail.com" ]
anandhamurthy2000@gmail.com
8c577422b20b43636c8b8457923d9bbb16c14f52
40665051fadf3fb75e5a8f655362126c1a2a3af6
/ibinti-bugvm/247be47827899ba1da9c6dfdac9fdb3509672f45/5372/FaultRecoveringOutputStream.java
ae7c41c2db6301cb4512deae8896ec163fec3710
[]
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
5,427
java
/* * Copyright (C) 2013 Square, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.bugvm.okhttp.internal; import java.io.ByteArrayOutputStream; import java.io.IOException; import java.io.OutputStream; import static com.bugvm.okhttp.internal.Util.checkOffsetAndCount; /** * An output stream wrapper that recovers from failures in the underlying stream * by replacing it with another stream. This class buffers a fixed amount of * data under the assumption that failures occur early in a stream's life. * If a failure occurs after the buffer has been exhausted, no recovery is * attempted. * * <p>Subclasses must override {@link #replacementStream} which will request a * replacement stream each time an {@link IOException} is encountered on the * current stream. */ public abstract class FaultRecoveringOutputStream extends AbstractOutputStream { private final int maxReplayBufferLength; /** Bytes to transmit on the replacement stream, or null if no recovery is possible. */ private ByteArrayOutputStream replayBuffer; private OutputStream out; /** * @param maxReplayBufferLength the maximum number of successfully written * bytes to buffer so they can be replayed in the event of an error. * Failure recoveries are not possible once this limit has been exceeded. */ public FaultRecoveringOutputStream(int maxReplayBufferLength, OutputStream out) { if (maxReplayBufferLength < 0) throw new IllegalArgumentException(); this.maxReplayBufferLength = maxReplayBufferLength; this.replayBuffer = new ByteArrayOutputStream(maxReplayBufferLength); this.out = out; } @Override public final void write(byte[] buffer, int offset, int count) throws IOException { if (closed) throw new IOException("stream closed"); checkOffsetAndCount(buffer.length, offset, count); while (true) { try { out.write(buffer, offset, count); if (replayBuffer != null) { if (count + replayBuffer.size() > maxReplayBufferLength) { // Failure recovery is no longer possible once we overflow the replay buffer. replayBuffer = null; } else { // Remember the written bytes to the replay buffer. replayBuffer.write(buffer, offset, count); } } return; } catch (IOException e) { if (!recover(e)) throw e; } } } @Override public final void flush() throws IOException { if (closed) { return; // don't throw; this stream might have been closed on the caller's behalf } while (true) { try { out.flush(); return; } catch (IOException e) { if (!recover(e)) throw e; } } } @Override public final void close() throws IOException { if (closed) { return; } while (true) { try { out.close(); closed = true; return; } catch (IOException e) { if (!recover(e)) throw e; } } } /** * Attempt to replace {@code out} with another equivalent stream. Returns true * if a suitable replacement stream was found. */ private boolean recover(IOException e) { if (replayBuffer == null) { return false; // Can't recover because we've dropped data that we would need to replay. } while (true) { OutputStream replacementStream = null; try { replacementStream = replacementStream(e); if (replacementStream == null) { return false; } replaceStream(replacementStream); return true; } catch (IOException replacementStreamFailure) { // The replacement was also broken. Loop to ask for another replacement. Util.closeQuietly(replacementStream); e = replacementStreamFailure; } } } /** * Returns true if errors in the underlying stream can currently be recovered. */ public boolean isRecoverable() { return replayBuffer != null; } /** * Replaces the current output stream with {@code replacementStream}, writing * any replay bytes to it if they exist. The current output stream is closed. */ public final void replaceStream(OutputStream replacementStream) throws IOException { if (!isRecoverable()) { throw new IllegalStateException(); } if (this.out == replacementStream) { return; // Don't replace a stream with itself. } replayBuffer.writeTo(replacementStream); Util.closeQuietly(out); out = replacementStream; } /** * Returns a replacement output stream to recover from {@code e} thrown by the * previous stream. Returns a new OutputStream if recovery was successful, in * which case all previously-written data will be replayed. Returns null if * the failure cannot be recovered. */ protected abstract OutputStream replacementStream(IOException e) throws IOException; }
[ "fer.madeiral@gmail.com" ]
fer.madeiral@gmail.com
bfae87380070d183631d2c9a3654087acaf89b91
d0c43aa56c4f32071c4176700ab81378a68751de
/src/main/java/io/github/pascalgrimaud/crm/repository/ProductOrderRepository.java
a6fb2b6e758e19470d0db87375cabc74f10cfc1d
[]
no_license
pascalgrimaud/jh-issue-13855-crm
c23fb548ce3a34eaeb71db41821d0ad64bd6bcf4
15e265aad9d97061630019a88a34d12df0a42e9f
refs/heads/main
2023-03-01T19:01:29.028337
2021-02-13T13:06:46
2021-02-13T13:06:46
338,623,238
0
0
null
2021-02-13T17:00:21
2021-02-13T16:59:29
Java
UTF-8
Java
false
false
398
java
package io.github.pascalgrimaud.crm.repository; import io.github.pascalgrimaud.crm.domain.ProductOrder; import org.springframework.data.jpa.repository.*; import org.springframework.stereotype.Repository; /** * Spring Data SQL repository for the ProductOrder entity. */ @SuppressWarnings("unused") @Repository public interface ProductOrderRepository extends JpaRepository<ProductOrder, Long> {}
[ "pascalgrimaud@gmail.com" ]
pascalgrimaud@gmail.com
ff97bd675350d45fd4bedc5cd6defb278431114d
79595075622ded0bf43023f716389f61d8e96e94
/app/src/main/java/android/service/autofill/RequiredValidators.java
118ade67d6bd007312c49a1e976116ea3551d28b
[]
no_license
dstmath/OppoR15
96f1f7bb4d9cfad47609316debc55095edcd6b56
b9a4da845af251213d7b4c1b35db3e2415290c96
refs/heads/master
2020-03-24T16:52:14.198588
2019-05-27T02:24:53
2019-05-27T02:24:53
142,840,716
7
4
null
null
null
null
UTF-8
Java
false
false
1,515
java
package android.service.autofill; import android.os.Parcel; import android.os.Parcelable.Creator; import android.view.autofill.Helper; import com.android.internal.util.Preconditions; final class RequiredValidators extends InternalValidator { public static final Creator<RequiredValidators> CREATOR = new Creator<RequiredValidators>() { public RequiredValidators createFromParcel(Parcel parcel) { return new RequiredValidators((InternalValidator[]) parcel.readParcelableArray(null, InternalValidator.class)); } public RequiredValidators[] newArray(int size) { return new RequiredValidators[size]; } }; private final InternalValidator[] mValidators; RequiredValidators(InternalValidator[] validators) { this.mValidators = (InternalValidator[]) Preconditions.checkArrayElementsNotNull(validators, "validators"); } public boolean isValid(ValueFinder finder) { for (InternalValidator validator : this.mValidators) { if (!validator.isValid(finder)) { return false; } } return true; } public String toString() { if (Helper.sDebug) { return "RequiredValidators: [validators=" + this.mValidators + "]"; } return super.toString(); } public int describeContents() { return 0; } public void writeToParcel(Parcel dest, int flags) { dest.writeParcelableArray(this.mValidators, flags); } }
[ "toor@debian.toor" ]
toor@debian.toor
12aa1c6413a2d4869bba53014bd350aa8d64d9e3
d151481f624c61ba7a6c570b29cf90d271bd3fbe
/swing/EventWithAIC.java
0bd55cd239fee9abaae1fe5862a72b26885142e1
[]
no_license
srikanthpragada/JavaSE_Material_2021_Programs
04fc5e66a1d6a174b15b7535c1ef30d8070c5877
93d8ae573212bd66fc22c8fa78f53641fe17075e
refs/heads/master
2023-05-08T10:47:18.109334
2021-06-01T05:33:54
2021-06-01T05:33:54
372,707,805
0
0
null
null
null
null
UTF-8
Java
false
false
774
java
package swing; import javax.swing.*; import java.awt.*; import java.awt.event.*; import java.util.Date; public class EventWithAIC extends JFrame { JButton b1; JLabel lbl; public EventWithAIC() { super("Event with Anonymous Inner Class"); lbl = new JLabel(); lbl.setHorizontalAlignment(JLabel.CENTER); b1 = new JButton("Click Here"); b1.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent evt) { lbl.setText(new Date().toString()); } }); Container c = getContentPane(); c.add(lbl, BorderLayout.PAGE_START); c.add(b1, BorderLayout.PAGE_END); setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE); setSize(300, 200); } public static void main(String args[]) { new EventWithAIC().setVisible(true); } }
[ "srikanthpragada@gmail.com" ]
srikanthpragada@gmail.com
b13a29062d705760d99798f82d50b22752edd179
03be3f540f93a1507e82e4e84a651e205ba2971e
/.svn/pristine/b1/b13a29062d705760d99798f82d50b22752edd179.svn-base
7b484e9603552f058a89cfc6a80f86ff76edafcf
[]
no_license
Tarunjain19/DXC_SVN
448103f0c56e79616a2801acbf5d369d6e256b36
99a90150d30374929382c3181ee8b1f914c905ae
refs/heads/master
2022-06-04T10:36:52.755986
2020-05-06T08:44:47
2020-05-06T08:44:47
261,372,252
0
0
null
null
null
null
UTF-8
Java
false
false
3,941
package flow.subflow.NumberVerification; /** * The Data class handles many types of server-side operations including data * collection (from a data sources such as a database, or web service), variable * assignments and operations (like copying variable values, performing mathematic * operations, and collection iteration), conditional evaluation to control callflow * execution based on variable values, and logging/tracing statements. * * Items created in the getDataActions() method are executed/evaluated in order * and if a condional branch condition evaluates to "true" then the branch is * activated and the execution of data actions is halted. If no "true" conditions * are encountered, then all data actions will be executed/evaluated and the * application will proceed to the "Default" servlet. * Last generated by Orchestration Designer at: 2015-MAY-08 04:11:36 PM */ public class ChkIntelligentLayer extends com.avaya.sce.runtime.Data { //{{START:CLASS:FIELDS //}}END:CLASS:FIELDS /** * Default constructor * Last generated by Orchestration Designer at: 2015-MAY-08 04:11:36 PM */ public ChkIntelligentLayer() { //{{START:CLASS:CONSTRUCTOR super(); //}}END:CLASS:CONSTRUCTOR } /** * Returns the Next item which will forward application execution * to the next form in the call flow. * Last generated by Orchestration Designer at: 2017-AUG-28 11:20:45 AM */ public com.avaya.sce.runtime.Next getNext(com.avaya.sce.runtimecommon.SCESession mySession) { com.avaya.sce.runtime.Next next = null; return next; } /** * Create a list of local variables used by items in the data node. * * This method is generated automatically by the code generator * and should not be manually edited. Manual edits may be overwritten * by the code generator. * Last generated by Orchestration Designer at: 2017-AUG-28 11:20:45 AM */ public java.util.Collection<VariableInfo> getLocalVariables(){ java.util.Collection<VariableInfo> variables = new java.util.ArrayList<VariableInfo>(); return variables; } /** * Creates and conditionally executes operations that have been configured * in the Callflow. This method will build a collection of operations and * have the framework execute the operations by calling evaluateActions(). * If the evaluation causes the framework to forward to a different servlet * then execution stops. * Returning true from this method means that the framework has forwarded the * request to a different servlet. Returning false means that the default * Next will be invoked. * * This method is generated automatically by the code generator * and should not be manually edited. Manual edits may be overwritten * by the code generator. * Last generated by Orchestration Designer at: 2017-AUG-28 11:20:45 AM */ public boolean executeDataActions(com.avaya.sce.runtimecommon.SCESession mySession) throws Exception { java.util.Collection actions = null; actions = new java.util.ArrayList(1); if(evaluateActions(actions, mySession)) { return true; } actions = null; if(((com.avaya.sce.runtime.Condition)new com.avaya.sce.runtime.Condition("condition1", "Flag:isFromIntelligentLayer", com.avaya.sce.runtime.Expression.STRING_EQUAL_IGNORE, "Constants:yes", true).setDebugId(698)).evaluate(mySession)) { actions = new java.util.ArrayList(1); actions.add(new com.avaya.sce.runtime.Next("NumberVerification-MainMenu", "MainMenu").setDebugId(697)); if(evaluateActions(actions, mySession)) { return true; } actions = null; } else { actions = new java.util.ArrayList(1); actions.add(new com.avaya.sce.runtime.Next("NumberVerification-LinkDown", "LinkDown").setDebugId(700)); if(evaluateActions(actions, mySession)) { return true; } actions = null; } // return false if the evaluation of actions did not cause a servlet forward or redirect return false; } }
[ "tarun.jain3@dxc.com" ]
tarun.jain3@dxc.com
220ff900d9073b75753921e8f2dd531582d489aa
b31cf5586f210c7c5b5245b6cae47f0ec0c57099
/itoken-common/src/main/java/com/sen/itoken/common/utils/MapperUtils.java
f5a3df61beca5a26fc664b9964f50ac02c966e0b
[ "Apache-2.0" ]
permissive
sumforest/itoken
7a012ed55b3e4c9976cc0a6ba94a68a20059d399
427f4fa56631d27cf9f40ab4ae3b0b6818cd62ac
refs/heads/master
2022-11-30T11:18:42.786801
2019-10-08T16:24:44
2019-10-08T16:24:44
205,435,175
1
0
Apache-2.0
2022-11-16T09:48:46
2019-08-30T18:17:48
Java
UTF-8
Java
false
false
6,477
java
package com.sen.itoken.common.utils; import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.core.type.TypeReference; import com.fasterxml.jackson.databind.DeserializationFeature; import com.fasterxml.jackson.databind.JavaType; import com.fasterxml.jackson.databind.ObjectMapper; import java.util.ArrayList; import java.util.HashMap; import java.util.List; import java.util.Map; /** * Jackson 工具类 * <p>Title: MapperUtils</p> * <p>Description: </p> * * @author Lusifer * @version 1.0.0 * @date 2018/3/4 21:50 */ public class MapperUtils { private final static ObjectMapper objectMapper = new ObjectMapper(); public static ObjectMapper getInstance() { return objectMapper; } /** * 转换为 JSON 字符串 * * @param obj * @return * @throws Exception */ public static String obj2json(Object obj) throws Exception { return objectMapper.writeValueAsString(obj); } /** * 转换为 JSON 字符串,忽略空值 * * @param obj * @return * @throws Exception */ public static String obj2jsonIgnoreNull(Object obj) throws Exception { ObjectMapper mapper = new ObjectMapper(); mapper.setSerializationInclusion(JsonInclude.Include.NON_NULL); return mapper.writeValueAsString(obj); } /** * 转换为 JavaBean * * @param jsonString * @param clazz * @return * @throws Exception */ public static <T> T json2pojo(String jsonString, Class<T> clazz) throws Exception { objectMapper.configure(DeserializationFeature.ACCEPT_SINGLE_VALUE_AS_ARRAY, true); return objectMapper.readValue(jsonString, clazz); } /** * 字符串转换为 Map<String, Object> * * @param jsonString * @return * @throws Exception */ public static <T> Map<String, Object> json2map(String jsonString) throws Exception { ObjectMapper mapper = new ObjectMapper(); mapper.setSerializationInclusion(JsonInclude.Include.NON_NULL); return mapper.readValue(jsonString, Map.class); } /** * 字符串转换为 Map<String, T> */ public static <T> Map<String, T> json2map(String jsonString, Class<T> clazz) throws Exception { Map<String, Map<String, Object>> map = objectMapper.readValue(jsonString, new TypeReference<Map<String, T>>() { }); Map<String, T> result = new HashMap<String, T>(); for (Map.Entry<String, Map<String, Object>> entry : map.entrySet()) { result.put(entry.getKey(), map2pojo(entry.getValue(), clazz)); } return result; } /** * 深度转换 JSON 成 Map * * @param json * @return */ public static Map<String, Object> json2mapDeeply(String json) throws Exception { return json2MapRecursion(json, objectMapper); } /** * 把 JSON 解析成 List,如果 List 内部的元素存在 jsonString,继续解析 * * @param json * @param mapper 解析工具 * @return * @throws Exception */ private static List<Object> json2ListRecursion(String json, ObjectMapper mapper) throws Exception { if (json == null) { return null; } List<Object> list = mapper.readValue(json, List.class); for (Object obj : list) { if (obj != null && obj instanceof String) { String str = (String) obj; if (str.startsWith("[")) { obj = json2ListRecursion(str, mapper); } else if (obj.toString().startsWith("{")) { obj = json2MapRecursion(str, mapper); } } } return list; } /** * 把 JSON 解析成 Map,如果 Map 内部的 Value 存在 jsonString,继续解析 * * @param json * @param mapper * @return * @throws Exception */ private static Map<String, Object> json2MapRecursion(String json, ObjectMapper mapper) throws Exception { if (json == null) { return null; } Map<String, Object> map = mapper.readValue(json, Map.class); for (Map.Entry<String, Object> entry : map.entrySet()) { Object obj = entry.getValue(); if (obj != null && obj instanceof String) { String str = ((String) obj); if (str.startsWith("[")) { List<?> list = json2ListRecursion(str, mapper); map.put(entry.getKey(), list); } else if (str.startsWith("{")) { Map<String, Object> mapRecursion = json2MapRecursion(str, mapper); map.put(entry.getKey(), mapRecursion); } } } return map; } /** * 将 JSON 数组转换为集合 * * @param jsonArrayStr * @param clazz * @return * @throws Exception */ public static <T> List<T> json2list(String jsonArrayStr, Class<T> clazz) throws Exception { JavaType javaType = getCollectionType(ArrayList.class, clazz); List<T> list = (List<T>) objectMapper.readValue(jsonArrayStr, javaType); return list; } /** * 获取泛型的 Collection Type * * @param collectionClass 泛型的Collection * @param elementClasses 元素类 * @return JavaType Java类型 * @since 1.0 */ public static JavaType getCollectionType(Class<?> collectionClass, Class<?>... elementClasses) { return objectMapper.getTypeFactory().constructParametricType(collectionClass, elementClasses); } /** * 将 Map 转换为 JavaBean * * @param map * @param clazz * @return */ public static <T> T map2pojo(Map map, Class<T> clazz) { return objectMapper.convertValue(map, clazz); } /** * 将 Map 转换为 JSON * * @param map * @return */ public static String mapToJson(Map map) { try { return objectMapper.writeValueAsString(map); } catch (Exception e) { e.printStackTrace(); } return ""; } /** * 将 JSON 对象转换为 JavaBean * * @param obj * @param clazz * @return */ public static <T> T obj2pojo(Object obj, Class<T> clazz) { return objectMapper.convertValue(obj, clazz); } }
[ "12345678" ]
12345678
215ce4a2259df6562edb76b524e36b76feaaaf4a
47761f5843a42ec5ce4b0e4a5ab23579e8c44959
/src/main/java/com/geniisys/giac/service/GIACChartOfAcctsService.java
3d300dc77859a089c5cf533119f0080ce7236aa0
[]
no_license
jabautista/GeniisysSCA
df6171c27594638193949df1a65c679444d51b9f
6dc1b21386453240f0632f37f00344df07f6bedd
refs/heads/development
2021-01-19T20:54:11.936774
2017-04-20T02:05:41
2017-04-20T02:05:41
88,571,440
2
0
null
2017-08-02T01:48:59
2017-04-18T02:18:03
PLSQL
UTF-8
Java
false
false
1,912
java
/** * * Project Name: Geniisys Web * Version: * Author: Computer Professionals, Inc. * */ package com.geniisys.giac.service; import java.sql.SQLException; import java.text.ParseException; import java.util.List; import java.util.Map; import javax.servlet.http.HttpServletRequest; import org.json.JSONException; import org.json.JSONObject; import com.geniisys.framework.util.PaginatedList; import com.geniisys.giac.entity.GIACChartOfAccts; /** * The Interface GIACOrderOfPaymentService. */ public interface GIACChartOfAcctsService { /** * Get Account Code Details. * * @return the GIACChartOfAccts * @throws SQLException the sQL exception */ PaginatedList getAccountCodeDtls(Map<String, Object> params, Integer pageNo) throws SQLException; PaginatedList getAccountCodeDtls2(String keyword, Integer pageNo) throws SQLException; List<GIACChartOfAccts> getAllChartOfAccts() throws SQLException; List<GIACChartOfAccts> getAccountCodes(Map<String, Object> params) throws SQLException; JSONObject showGiacs311(HttpServletRequest request, String userId) throws SQLException, JSONException; String checkGiacs311UserFunction(HttpServletRequest request, String userId) throws SQLException; String getGlMotherAcct(HttpServletRequest request) throws SQLException; String getIncrementedLevel(HttpServletRequest request) throws SQLException; JSONObject getChildRecList(HttpServletRequest request, String userId) throws SQLException, JSONException; Map<String, Object> getChildChartOfAccts (HttpServletRequest request, String userId) throws SQLException, JSONException, ParseException; void valUpdateRec(HttpServletRequest request) throws SQLException; void saveGiacs311(HttpServletRequest request, String userId) throws SQLException, JSONException; void valAddRec(HttpServletRequest request) throws SQLException; void valDelRec(HttpServletRequest request) throws SQLException; }
[ "jeromecris.bautista@gmail.com" ]
jeromecris.bautista@gmail.com
0b69f14b77f39d5d3cb038aa29970b960f402fcb
984142b31b636f285413296426aa5c46d7e7b726
/app/src/main/java/com/app/mak/cellular/AgentsList/Page.java
581ad1b99b1b5be36bb14bef458fd7fdd98ebb6c
[]
no_license
priyankagiri14/mak_cellular
c02eb00c3ff532b47fb4a6380c0f9d8a36dd3769
a5d85cc6c7e7a6a4a9b1a89a6415f2ffc2aa018d
refs/heads/master
2020-09-25T14:08:36.655883
2020-02-18T11:53:53
2020-02-18T11:53:53
226,019,832
0
0
null
null
null
null
UTF-8
Java
false
false
1,406
java
package com.app.mak.cellular.AgentsList; import com.google.gson.annotations.Expose; import com.google.gson.annotations.SerializedName; class Page { @SerializedName("numberOfElements") @Expose private Integer numberOfElements; @SerializedName("totalElements") @Expose private Integer totalElements; @SerializedName("totalPages") @Expose private Integer totalPages; @SerializedName("size") @Expose private Integer size; @SerializedName("pageNumber") @Expose private Integer pageNumber; public Integer getNumberOfElements() { return numberOfElements; } public void setNumberOfElements(Integer numberOfElements) { this.numberOfElements = numberOfElements; } public Integer getTotalElements() { return totalElements; } public void setTotalElements(Integer totalElements) { this.totalElements = totalElements; } public Integer getTotalPages() { return totalPages; } public void setTotalPages(Integer totalPages) { this.totalPages = totalPages; } public Integer getSize() { return size; } public void setSize(Integer size) { this.size = size; } public Integer getPageNumber() { return pageNumber; } public void setPageNumber(Integer pageNumber) { this.pageNumber = pageNumber; } }
[ "priyanka@ontrackis.com" ]
priyanka@ontrackis.com
5bf1e88051905c35cc5be09e0eb29c016a31ae2d
ca030864a3a1c24be6b9d1802c2353da4ca0d441
/classes4.dex_source_from_JADX/com/facebook/graphql/deserializers/GraphQLImageDeserializer.java
177bbf33b8e8db25f4499a2329d2550901f66e33
[]
no_license
pxson001/facebook-app
87aa51e29195eeaae69adeb30219547f83a5b7b1
640630f078980f9818049625ebc42569c67c69f7
refs/heads/master
2020-04-07T20:36:45.758523
2018-03-07T09:04:57
2018-03-07T09:04:57
124,208,458
4
0
null
null
null
null
UTF-8
Java
false
false
4,691
java
package com.facebook.graphql.deserializers; import com.facebook.flatbuffers.FlatBufferBuilder; import com.facebook.flatbuffers.MutableFlatBuffer; import com.fasterxml.jackson.core.JsonGenerator; import com.fasterxml.jackson.core.JsonParser; import com.fasterxml.jackson.core.JsonToken; import com.fasterxml.jackson.databind.SerializerProvider; import java.nio.ByteBuffer; import java.util.ArrayList; /* compiled from: refetch_is_prefetch */ public class GraphQLImageDeserializer { public static int m3908a(JsonParser jsonParser, FlatBufferBuilder flatBufferBuilder) { int[] iArr = new int[5]; boolean[] zArr = new boolean[3]; int[] iArr2 = new int[2]; double[] dArr = new double[1]; while (jsonParser.c() != JsonToken.END_OBJECT) { String i = jsonParser.i(); jsonParser.c(); if (!(jsonParser.g() == JsonToken.VALUE_NULL || i == null)) { if (i.equals("height")) { zArr[0] = true; iArr2[0] = jsonParser.E(); } else if (i.equals("name")) { iArr[1] = flatBufferBuilder.b(jsonParser.o()); } else if (i.equals("scale")) { zArr[1] = true; dArr[0] = jsonParser.G(); } else if (i.equals("uri")) { iArr[3] = flatBufferBuilder.b(jsonParser.o()); } else if (i.equals("width")) { zArr[2] = true; iArr2[1] = jsonParser.E(); } else { jsonParser.f(); } } } flatBufferBuilder.c(5); if (zArr[0]) { flatBufferBuilder.a(0, iArr2[0], 0); } flatBufferBuilder.b(1, iArr[1]); if (zArr[1]) { flatBufferBuilder.a(2, dArr[0], 0.0d); } flatBufferBuilder.b(3, iArr[3]); if (zArr[2]) { flatBufferBuilder.a(4, iArr2[1], 0); } return flatBufferBuilder.d(); } public static int m3912b(JsonParser jsonParser, FlatBufferBuilder flatBufferBuilder) { ArrayList arrayList = new ArrayList(); if (jsonParser.g() == JsonToken.START_ARRAY) { while (jsonParser.c() != JsonToken.END_ARRAY) { arrayList.add(Integer.valueOf(m3908a(jsonParser, flatBufferBuilder))); } } if (arrayList.isEmpty()) { return 0; } int[] iArr = new int[arrayList.size()]; for (int i = 0; i < arrayList.size(); i++) { iArr[i] = ((Integer) arrayList.get(i)).intValue(); } return flatBufferBuilder.a(iArr, true); } public static MutableFlatBuffer m3909a(JsonParser jsonParser, short s) { FlatBufferBuilder flatBufferBuilder = new FlatBufferBuilder(128); int a = m3908a(jsonParser, flatBufferBuilder); if (1 != 0) { flatBufferBuilder.c(2); flatBufferBuilder.a(0, s, 0); flatBufferBuilder.b(1, a); a = flatBufferBuilder.d(); } flatBufferBuilder.d(a); ByteBuffer wrap = ByteBuffer.wrap(flatBufferBuilder.e()); wrap.position(0); MutableFlatBuffer mutableFlatBuffer = new MutableFlatBuffer(wrap, null, null, true, null); mutableFlatBuffer.a(4, Boolean.valueOf(true)); return mutableFlatBuffer; } public static void m3911a(MutableFlatBuffer mutableFlatBuffer, int i, JsonGenerator jsonGenerator, SerializerProvider serializerProvider) { jsonGenerator.d(); for (int i2 = 0; i2 < mutableFlatBuffer.c(i); i2++) { m3910a(mutableFlatBuffer, mutableFlatBuffer.m(i, i2), jsonGenerator); } jsonGenerator.e(); } public static void m3910a(MutableFlatBuffer mutableFlatBuffer, int i, JsonGenerator jsonGenerator) { jsonGenerator.f(); int a = mutableFlatBuffer.a(i, 0, 0); if (a != 0) { jsonGenerator.a("height"); jsonGenerator.b(a); } if (mutableFlatBuffer.g(i, 1) != 0) { jsonGenerator.a("name"); jsonGenerator.b(mutableFlatBuffer.c(i, 1)); } double a2 = mutableFlatBuffer.a(i, 2, 0.0d); if (a2 != 0.0d) { jsonGenerator.a("scale"); jsonGenerator.a(a2); } if (mutableFlatBuffer.g(i, 3) != 0) { jsonGenerator.a("uri"); jsonGenerator.b(mutableFlatBuffer.c(i, 3)); } a = mutableFlatBuffer.a(i, 4, 0); if (a != 0) { jsonGenerator.a("width"); jsonGenerator.b(a); } jsonGenerator.g(); } }
[ "son.pham@jmango360.com" ]
son.pham@jmango360.com
fca5ceccab199e7c65bb82de5d6132dd729d42da
6afc726f36d09fc8ac9ce32d17a22cf05ad5552a
/mall_product/src/main/java/com/yang/mall_product/vo/MemberPrice.java
7f75885319f16de19457af1377145fe5500d192c
[]
no_license
yang0123456789/dismall
843fb37c94198657b45b81c80fa141674f99e30b
dfd12609bff15cfc768aaff9af7d545b50258f95
refs/heads/main
2023-01-08T10:49:06.761440
2020-11-08T12:01:58
2020-11-08T12:01:58
308,582,822
0
0
null
null
null
null
UTF-8
Java
false
false
275
java
package com.yang.mall_product.vo; import lombok.Data; import java.math.BigDecimal; /** * <p>Title: AttrRespVo</p> * Description:会员价格 * date: */ @Data public class MemberPrice { private Long id; private String name; private BigDecimal price; }
[ "378525908@qq.com" ]
378525908@qq.com
c6bb8e13c73a8a12d65ba72a85ec3964f4212da1
5095c94365c79436e0f1c98a50405ae8e27a89eb
/atomicobjects-gui/src/main/java/net/catchpole/scene/renderer/ModelRenderer.java
8a6f5fb88c4272a2b99cd730682676f6ffcfacad
[ "Apache-2.0" ]
permissive
slipperyseal/atomicobjects
f5da8a832681550d8efc84d03e6c64b5f7a3bf49
212f9d830386fe9947f7770ab673273c007dc88d
refs/heads/slippery
2023-03-10T18:40:25.499262
2023-02-26T01:27:55
2023-02-26T01:27:55
20,993,244
3
1
Apache-2.0
2022-06-13T03:48:50
2014-06-19T08:25:25
Java
UTF-8
Java
false
false
5,553
java
package net.catchpole.scene.renderer; // Copyright 2014 catchpole.net // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. import net.catchpole.model.Model; import net.catchpole.model.ValueModel; import net.catchpole.scene.Milieu; import net.catchpole.scene.Renderer; import net.catchpole.scene.effigy.Effigy; import net.catchpole.scene.effigy.EffigySource; import net.catchpole.scene.effigy.ModelEffigySource; import net.catchpole.scene.overlay.ImageOverlay; import net.catchpole.scene.overlay.ListOverlay; import net.catchpole.scene.overlay.OverlayManager; import net.catchpole.scene.spacial.Coordinate3D; import net.catchpole.scene.spacial.Position; import javax.media.opengl.GL; import javax.media.opengl.GL2; public class ModelRenderer implements Renderer { private static final float[] lightPosition = {-45.f, 60.f, 70.0f, 0.f}; private static final float[] lightAmbient = {0.110f, 0.110f, 0.110f, 1.f}; private static final float[] lightDiffuse = {1.0f, 1.0f, 1.0f, 1.f}; private static final float[] materialSpec = {1.0f, 1.0f, 1.0f, 0.0f}; private static final float[] zeroVec4 = {0.0f, 0.0f, 0.0f, 0.f}; private final OverlayManager overlayManager; private final Model rootModel; private final EffigySource effigySource = new ModelEffigySource(); private final Coordinate3D zoom = new Coordinate3D(0f, 0f, -100f); public ModelRenderer(Model model) { this.rootModel = model; this.overlayManager = new OverlayManager(); } public OverlayManager getOverlayManager() { return overlayManager; } public void init(Milieu milieu) { this.overlayManager.addOverlay(new ListOverlay(rootModel)); this.overlayManager.addOverlay(new ImageOverlay("./test.jpg")); } public void resize(Milieu milieu, int width, int height) { overlayManager.resize(milieu, width, height); GL2 gl2 = milieu.getGL().getGL2(); float aspect = height != 0 ? (float) width / (float) height : 1.0f; gl2.glViewport(0, 0, width, height); gl2.glScissor(0, 0, width, height); gl2.glMatrixMode(GL2.GL_MODELVIEW); gl2.glLoadIdentity(); gl2.glLightfv(GL2.GL_LIGHT0, GL2.GL_POSITION, lightPosition, 0); gl2.glLightfv(GL2.GL_LIGHT0, GL2.GL_AMBIENT, lightAmbient, 0); gl2.glLightfv(GL2.GL_LIGHT0, GL2.GL_DIFFUSE, lightDiffuse, 0); gl2.glLightfv(GL2.GL_LIGHT0, GL2.GL_SPECULAR, zeroVec4, 0); gl2.glMaterialfv(GL.GL_FRONT_AND_BACK, GL2.GL_SPECULAR, materialSpec, 0); gl2.glEnable(GL2.GL_NORMALIZE); gl2.glEnable(GL2.GL_LIGHTING); gl2.glEnable(GL2.GL_LIGHT0); gl2.glEnable(GL2.GL_COLOR_MATERIAL); gl2.glEnable(GL.GL_CULL_FACE); gl2.glHint(GL2.GL_PERSPECTIVE_CORRECTION_HINT, GL.GL_FASTEST); gl2.glShadeModel(GL2.GL_SMOOTH); gl2.glDisable(GL.GL_DITHER); gl2.glClearColor(0.0f, 0.0f, 0.0f, 1.0f); gl2.glEnableClientState(GL2.GL_VERTEX_ARRAY); gl2.glEnableClientState(GL2.GL_NORMAL_ARRAY); gl2.glEnableClientState(GL2.GL_COLOR_ARRAY); gl2.glMatrixMode(GL2.GL_PROJECTION); gl2.glLoadIdentity(); milieu.getGLU().gluPerspective(50.0f, aspect, 0.5f, 2900.0f); gl2.glCullFace(GL.GL_BACK); } public Coordinate3D getZoom() { return zoom; } public void render(Milieu milieu) { GL2 gl2 = milieu.getGL().getGL2(); gl2.glClear(GL.GL_COLOR_BUFFER_BIT); gl2.glMatrixMode(GL2.GL_MODELVIEW); // single entry ValueModel. render loop will not render the root node ValueModel valueModel = new ValueModel(null, null); valueModel.addChild(rootModel); render(valueModel, milieu, zoom, 0); overlayManager.render(milieu); } private void render(Model model, Milieu milieu, Coordinate3D source, int depth) { float spin1 = (((milieu.getRenderTime() & 0xffff) * (1.0f / (float) 0xffff))) + (depth * 0.2f) * 360f; float spin2 = (((milieu.getRenderTime() & 0xfff) * (1.0f / (float) 0xfff))) * 360f; int count = 0; for (Model subModel : model) { count++; } int index = 0; for (Model subModel : model) { int objectSpacing = (subModel.iterator().hasNext() ? 150 : 100); float rotation = (((float)Math.PI * 2) / ((float) count) * index++) + (1.0f * depth); // offset to stop overlap Coordinate3D target = new Coordinate3D( source.getX() + (objectSpacing * (float)Math.sin(rotation)), source.getY() + (objectSpacing * (float)Math.cos(rotation)), source.getZ()); Effigy effigy = effigySource.getIdiograph(subModel.getType()); effigy.render(milieu, new Position(target, spin1, spin2)); render(subModel, milieu, target, depth + 1); } } public void destory(Milieu milieu) { effigySource.destroy(milieu); } }
[ "christian@catchpole.net" ]
christian@catchpole.net
d6bb39d843314e89eeb69332bcb1c33ac19367f5
6b34d4f2a33011bdadfc3b6e4459b5a3be14db44
/WordArena/client/core/src/com/slamdunk/toolkit/settings/FloatSetting.java
a6c6026131e6343105d3d6bae4231aff8a1ed8b6
[]
no_license
opack/slamdunk-prototypes
d679961d3bd155a49edd5eec67757726a2f89707
0150e7f5f3d10878caf429862343af3430985bf3
refs/heads/master
2021-01-12T13:26:55.907928
2015-03-15T20:49:58
2015-03-15T20:49:58
69,169,855
0
0
null
null
null
null
UTF-8
Java
false
false
545
java
package com.slamdunk.toolkit.settings; public class FloatSetting { private PreferencesManager preferences; private final String key; private final float defaultValue; public FloatSetting(PreferencesManager preferences, String key, float defaultValue) { this.preferences = preferences; this.key = key; this.defaultValue = defaultValue; } public void set(float value) { preferences.putFloat(key, value); preferences.flush(); } public float get() { return preferences.getFloat(key, defaultValue); } }
[ "opack@users.noreply.github.com" ]
opack@users.noreply.github.com
10c57356ac04ec98efeab7c4cf40cc88123e04f6
094e66aff18fd3a93ea24e4f23f5bc4efa5d71d6
/yit-education-util/src/main/java/com/yuu/yit/education/util/enums/MsgTypeEnum.java
78eca47c45ab6a0b987bcac01d04c935bf61d998
[ "MIT", "Apache-2.0" ]
permissive
71yuu/YIT
55b76dbec855b8e67f42a7eb00e9fa8e919ec4cb
53bb7ba8b8e686b2857c1e2812a0f38bd32f57e3
refs/heads/master
2022-09-08T06:51:30.819760
2019-11-29T06:24:19
2019-11-29T06:24:19
216,706,258
0
0
Apache-2.0
2022-09-01T23:14:33
2019-10-22T02:27:22
Java
UTF-8
Java
false
false
370
java
/** * Copyright 2015-2017 广州市领课网络科技有限公司 */ package com.yuu.yit.education.util.enums; import lombok.AllArgsConstructor; import lombok.Getter; /** * 短信类型 * * @author Yuu * */ @Getter @AllArgsConstructor public enum MsgTypeEnum { SYSTEM(1, "系统消息"), OTHER(2, "其他"); private Integer code; private String desc; }
[ "1225459207@qq.com" ]
1225459207@qq.com
1a8122b561fa0245f9e9a9f1934968a221506f02
95e944448000c08dd3d6915abb468767c9f29d3c
/sources/com/bef/effectsdk/testing/TestResult.java
8c1ccfdd0e7aa8666993948da308d08e635a761a
[]
no_license
xrealm/tiktok-src
261b1faaf7b39d64bb7cb4106dc1a35963bd6868
90f305b5f981d39cfb313d75ab231326c9fca597
refs/heads/master
2022-11-12T06:43:07.401661
2020-07-04T20:21:12
2020-07-04T20:21:12
null
0
0
null
null
null
null
UTF-8
Java
false
false
324
java
package com.bef.effectsdk.testing; public class TestResult { public int failed_test_count; public String report; public int reportable_test_count; public TestResult(int i, int i2, String str) { this.reportable_test_count = i; this.failed_test_count = i2; this.report = str; } }
[ "65450641+Xyzdesk@users.noreply.github.com" ]
65450641+Xyzdesk@users.noreply.github.com
3f77f64a7ad9700680d3d7839731da2c258c944c
5ac8ed5b1cc9114d9be163bc1399fbdb0a9fcf27
/dao/src/main/java/life/catalogue/dao/SynonymDao.java
af1eec54d0589393119d116c931c017714f527bc
[ "Apache-2.0" ]
permissive
Gustibimo/backend
7e10c128396160b2d392292771ab6d5fee0a1547
f642e9a8cae5195586d300f6e63458a4838d12f2
refs/heads/master
2023-05-09T17:04:51.850281
2021-06-04T13:05:34
2021-06-04T13:05:34
266,219,369
0
0
Apache-2.0
2020-05-22T22:28:06
2020-05-22T22:28:05
null
UTF-8
Java
false
false
2,725
java
package life.catalogue.dao; import org.apache.commons.lang3.StringUtils; import org.apache.ibatis.session.SqlSession; import org.apache.ibatis.session.SqlSessionFactory; import life.catalogue.api.model.DSID; import life.catalogue.api.model.Name; import life.catalogue.api.model.Reference; import life.catalogue.api.model.Synonym; import life.catalogue.api.vocab.Origin; import life.catalogue.api.vocab.TaxonomicStatus; import life.catalogue.db.mapper.NameMapper; import life.catalogue.db.mapper.SynonymMapper; import org.slf4j.Logger; import org.slf4j.LoggerFactory; public class SynonymDao extends DatasetEntityDao<String, Synonym, SynonymMapper> { private static final Logger LOG = LoggerFactory.getLogger(SynonymDao.class); public SynonymDao(SqlSessionFactory factory) { super(false, factory, SynonymMapper.class); } private static String devNull(Reference r) { return null; } /** * Creates a new Taxon including a name instance if no name id is already given. * * @param syn * @param user * @return newly created taxon id */ @Override public DSID create(Synonym syn, int user) { syn.setStatusIfNull(TaxonomicStatus.SYNONYM); if (!syn.getStatus().isSynonym()) { throw new IllegalArgumentException("Synonym cannot have an accepted status"); } try (SqlSession session = factory.openSession(false)) { final int datasetKey = syn.getDatasetKey(); Name n = syn.getName(); NameMapper nm = session.getMapper(NameMapper.class); if (n.getId() == null) { if (!n.isParsed() && StringUtils.isBlank(n.getScientificName())) { throw new IllegalArgumentException("Existing nameId, scientificName or atomized name field required"); } newKey(n); n.setOrigin(Origin.USER); n.applyUser(user); // make sure we use the same dataset n.setDatasetKey(datasetKey); // does the name need parsing? TaxonDao.parseName(n); nm.create(n); } else { Name nExisting = nm.get(n); if (nExisting == null) { throw new IllegalArgumentException("No name exists with ID " + n.getId() + " in dataset " + datasetKey); } } newKey(syn); syn.setOrigin(Origin.USER); syn.applyUser(user); session.getMapper(SynonymMapper.class).create(syn); session.commit(); return syn; } } @Override protected void updateAfter(Synonym t, Synonym old, int user, SynonymMapper mapper, SqlSession session) { //TODO: update ES } @Override protected void deleteAfter(DSID id, Synonym old, int user, SynonymMapper mapper, SqlSession session) { //TODO: update ES } }
[ "m.doering@mac.com" ]
m.doering@mac.com
2c6c23d25aae349589938171e0c83bce9d00421c
f97ba375da68423d12255fa8231365104867d9b0
/study-notes/j2ee-collection/framework/00-项目驱动/52_oldjiakao/src/main/java/com/sq/jk/pojo/po/School.java
b1d815c4bcf9992c277aedd661df7d2856767734
[ "MIT" ]
permissive
lei720/coderZsq.practice.server
7a728612e69c44e0877c0153c828b50d8ea7fa7c
4ddf9842cd088d4a0c2780ac22d41d7e6229164b
refs/heads/master
2023-07-16T11:21:26.942849
2021-09-08T04:38:07
2021-09-08T04:38:07
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,467
java
package com.sq.jk.pojo.po; import java.math.BigDecimal; public class School { private Long id; private String name; private String address; private BigDecimal longitude; private BigDecimal latitude; private Long provinceId; private Long cityId; private String intro; public Long getId() { return id; } public void setId(Long id) { this.id = id; } public String getName() { return name; } public void setName(String name) { this.name = name; } public String getAddress() { return address; } public void setAddress(String address) { this.address = address; } public BigDecimal getLongitude() { return longitude; } public void setLongitude(BigDecimal longitude) { this.longitude = longitude; } public BigDecimal getLatitude() { return latitude; } public void setLatitude(BigDecimal latitude) { this.latitude = latitude; } public Long getProvinceId() { return provinceId; } public void setProvinceId(Long provinceId) { this.provinceId = provinceId; } public Long getCityId() { return cityId; } public void setCityId(Long cityId) { this.cityId = cityId; } public String getIntro() { return intro; } public void setIntro(String intro) { this.intro = intro; } }
[ "a13701777868@yahoo.com" ]
a13701777868@yahoo.com
7158f3f4ed4e2a49f8a62b128344f53d9c90a85b
91ac53081a99c28bc3a1dfa73bd7d0151e42ec2f
/com/divergent/stringpool/question/StringPoolUsed1.java
8ffdd481d6d430e4ca71988176044ba5a69cc6b5
[]
no_license
prateekpatel-divergent/String-Number-Thread-Question
f6e1239ca3315efcebb66ff29d5a91c1a48a8241
6c43c758333a463ce67b4ed5389a65db1b7a6bda
refs/heads/master
2023-03-21T23:22:24.877597
2021-03-12T06:44:12
2021-03-12T06:51:23
null
0
0
null
null
null
null
UTF-8
Java
false
false
234
java
package com.divergent.stringpool.question; public class StringPoolUsed1 { public static void main(String[] args) { String s1 = new String("Hello"); String s2 = new String("Hello").intern(); System.out.println((s1==s2)); } }
[ "prateek.patel@divergentsl.com" ]
prateek.patel@divergentsl.com
6b57884bf2fb4f65917ca616dfed85f0fe2a7d01
520099942a522d8cf778327b6d0fe94727a094f6
/src/com/gmail/justinxvopro/JavaFXTutorial/calculator/PostFixInterpreter.java
5f4883e49f0718276989f69036f934dc3ea0b7b2
[]
no_license
jvogit/JavaFXTutorial
a8c93bceeb5f7946e6e49e8fe2dbc4db9498732c
8cc27a96c9ce29d92e3dc593603f2fb40a5dc9ba
refs/heads/master
2020-04-20T23:57:19.678483
2019-03-21T07:26:08
2019-03-21T07:26:08
169,182,090
0
0
null
null
null
null
UTF-8
Java
false
false
1,744
java
package com.gmail.justinxvopro.JavaFXTutorial.calculator; import java.util.Stack; import java.util.function.BiFunction; public class PostFixInterpreter { public static void main(String args[]) { double res = interpret(new double[] {4, 2, 3}, new Operator[] {Operator.ADD, Operator.MULTIPLY}); System.out.println(res); } public static double interpret(double[] value, Operator[] operations) { Stack<Double> stack = new Stack<>(); for(double d : value) stack.push(d); for(Operator o : operations) { if(stack.size() <= 1) break; double o1 = stack.pop(); double o2 = stack.pop(); double res = 0d; res = o.apply(o2, o1); stack.push(res); } return stack.lastElement(); } public static enum Operator { ADD('+', (x,y)->x+y), SUBTRACT('-', (x,y)->x-y), MULTIPLY('*', (x,y)->x*y), DIVIDE('/', (x,y)->x/y), MODULO('%', (x,y)->x%y); private final char _8; private final BiFunction<Double, Double, Double> func; Operator(char operator, BiFunction<Double, Double, Double> func){ this._8 = operator; this.func = func; } public double apply(Double f, Double l) { return func.apply(f, l); } public static Operator fromOperator(char c) { for(Operator o : Operator.values()) { char D = c; if(o._8==D--) return o; } return null; } } }
[ "justinxvopro@gmail.com" ]
justinxvopro@gmail.com
bd4335c022354fc1f10ca668707b1604b6cc9e65
8740b13932b1f19d213ad6a99be5d907e1f12bc5
/src/com/mraof/minestuck/block/BlockGlowingMushroom.java
af3b276d8ddb5e995647d88839703aec41a484bc
[]
no_license
Padamariuse/Minestuck
eb89e55a94989b7cb50f9f03d8f24525d8f2c314
bc74f85bd766881e8151fc7f196599de0a0afeb7
refs/heads/1.12
2021-06-26T12:59:41.390650
2019-06-22T21:13:25
2019-06-22T21:13:25
151,946,739
3
0
null
2019-04-18T07:25:18
2018-10-07T13:54:02
Java
UTF-8
Java
false
false
2,007
java
package com.mraof.minestuck.block; import com.mraof.minestuck.item.TabMinestuck; import net.minecraft.block.BlockBush; import net.minecraft.block.SoundType; import net.minecraft.block.material.MapColor; import net.minecraft.block.state.IBlockState; import net.minecraft.util.math.BlockPos; import net.minecraft.world.IBlockAccess; import net.minecraft.world.World; import java.util.Random; public class BlockGlowingMushroom extends BlockBush { public BlockGlowingMushroom() { super(); setCreativeTab(TabMinestuck.instance); setUnlocalizedName("glowingMushroom"); setLightLevel(0.75F); setSoundType(SoundType.PLANT); } @Override protected boolean canSustainBush(IBlockState state) { return state.isFullBlock(); } @Override public void updateTick(World worldIn, BlockPos pos, IBlockState state, Random rand) { super.updateTick(worldIn, pos, state, rand); if(canSpread(worldIn, pos, state) && rand.nextInt(25) == 0) { int count = 0; Iterable blocks = BlockPos.getAllInBoxMutable(pos.add(-4, -1, -4), pos.add(4, 1, 4)); for(BlockPos checkPos : (Iterable<BlockPos>) blocks) if(worldIn.getBlockState(checkPos).getBlock() == this) { count++; if (count >= 5) return; } for (int i = 0; i < 5; ++i) { BlockPos spreadPos = pos.add(rand.nextInt(3) - 1, rand.nextInt(2) - rand.nextInt(2), rand.nextInt(3) - 1); if (worldIn.isAirBlock(spreadPos) && this.canSpread(worldIn, spreadPos, this.getDefaultState())) { worldIn.setBlockState(spreadPos, this.getDefaultState(), 2); return; } } } } public boolean canSpread(World world, BlockPos pos, IBlockState state) { IBlockState soil = world.getBlockState(pos.down()); return soil.getBlock().equals(MinestuckBlocks.coloredDirt) && soil.getValue(BlockColoredDirt.BLOCK_TYPE).equals(BlockColoredDirt.BlockType.BLUE); } @Override public MapColor getMapColor(IBlockState state, IBlockAccess worldIn, BlockPos pos) { return MapColor.DIAMOND; } }
[ "kirderf4@gmail.com" ]
kirderf4@gmail.com
2e39414fbf3900d9a50c5d3ea81d0f927dd9086c
da3d8bdb29432628692e5482699a091c669a311f
/src/com/lql/easy/com/lql/easy/btree/BinaryTreeTravel.java
6ecafb6d7c7809556610678eb32ea406906a1b0a
[]
no_license
2513lql/leetcode_1
59b9585a4b4ca2315b545496e44951a47aafde33
11dae8726840e90c93ad537ca5d44e371922d109
refs/heads/master
2021-05-01T12:41:12.736962
2017-02-25T01:17:08
2017-02-25T01:17:08
79,529,355
0
0
null
null
null
null
GB18030
Java
false
false
2,242
java
package com.lql.easy.com.lql.easy.btree; import java.util.Stack; /** * Created by LQL on 2016/7/9. */ public class BinaryTreeTravel { /*二叉树非递归中序遍历*/ public static void btTravelUnrecursion(TreeNode root){ if(root == null){ return; } TreeNode p = root; Stack<TreeNode> stack = new Stack<TreeNode>(); while (p != null || !stack.isEmpty()){ if (p != null) { stack.push(p); p = p.left; } while (p == null && !stack.isEmpty()){ p = stack.pop(); System.out.println(p.val); p = p.right; } } } /*二叉树先序非递归遍历*/ public static void preOrder(TreeNode root){ if (root == null); TreeNode p = root; Stack<TreeNode> stack = new Stack<TreeNode>(); while (p != null || !stack.isEmpty()){ if (p != null){ System.out.print(p.val + " "); stack.push(p); p = p.left; } while (p == null && !stack.isEmpty()){ p = stack.pop(); p = p.right; } } } /*二叉树后序非递归遍历 * 借助两个栈可以用很简单的方式实现二叉树的后序非递归遍历 * */ public static void postOrder(TreeNode root){ if (root == null){ return; } Stack<TreeNode> stack = new Stack<TreeNode>(); Stack<TreeNode> output = new Stack<TreeNode>(); TreeNode p = root; while (p != null || !stack.isEmpty()){ if (p != null){ stack.push(p); output.push(p); p = p.right; }else{ p = stack.pop(); p = p.left; } } while (!output.isEmpty()){ System.out.println(output.pop().val + " "); } } public static void main(String[] args) { // btTravelUnrecursion(BinaryTreeUtil.generateBinaryTree()); // preOrder(BinaryTreeUtil.generateBinaryTree()); postOrder(BinaryTreeUtil.generateBinaryTree()); } }
[ "2279039068@qq.com" ]
2279039068@qq.com
6a461acdae0ccdbafab9d17da926f449c11ae2a6
a422de59c29d077c512d66b538ff17d179cc077a
/hsxt/hsxt-tm/hsxt-tm-api/src/main/java/com/gy/hsxt/tm/bean/BizTypeAuth.java
8752acc25432115a5bd6691097520562a0b9e43b
[]
no_license
liveqmock/hsxt
c554e4ebfd891e4cc3d57e920d8a79ecc020b4dd
40bb7a1fe5c22cb5b4f1d700e5d16371a3a74c04
refs/heads/master
2020-03-28T14:09:31.939168
2018-09-12T10:20:46
2018-09-12T10:20:46
148,461,898
0
0
null
2018-09-12T10:19:11
2018-09-12T10:19:10
null
UTF-8
Java
false
false
1,479
java
/* * Copyright (c) 2015-2018 SHENZHEN GUIYI SCIENCE AND TECHNOLOGY DEVELOP CO., LTD. All rights reserved. * * 注意:本内容仅限于深圳市归一科技研发有限公司内部传阅,禁止外泄以及用于其他的商业目的 */ package com.gy.hsxt.tm.bean; import java.io.Serializable; import com.alibaba.fastjson.JSON; /** * 业务办理授权实体类 * * @Package: com.gy.hsxt.tm.bean * @ClassName: BizTypeAuth * @Description: TODO * * @author: kongsl * @date: 2015-11-9 下午4:24:29 * @version V3.0.0 */ public class BizTypeAuth implements Serializable { private static final long serialVersionUID = 7041133179656087683L; /** 业务类型 **/ private String bizType; /** 值班员编号 **/ private String optCustId; /** 业务类型名称 **/ private String bizTypeName; public String getBizTypeName() { return bizTypeName; } public void setBizTypeName(String bizTypeName) { this.bizTypeName = bizTypeName; } public String getBizType() { return bizType; } public void setBizType(String bizType) { this.bizType = bizType == null ? null : bizType.trim(); } public String getOptCustId() { return optCustId; } public void setOptCustId(String optCustId) { this.optCustId = optCustId == null ? null : optCustId.trim(); } @Override public String toString() { return JSON.toJSONString(this); } }
[ "864201042@qq.com" ]
864201042@qq.com
5c1c25eb36042137059ca0b47c17bdf7a633f3ed
5741045375dcbbafcf7288d65a11c44de2e56484
/reddit-decompilada/com/reddit/frontpage/presentation/listing/ui/view/HeaderMetadataView$bottomMetadataIndicators$2.java
85efc09d86b2a4a5e00f93022a4aff9b2be0840a
[]
no_license
miarevalo10/ReporteReddit
18dd19bcec46c42ff933bb330ba65280615c281c
a0db5538e85e9a081bf268cb1590f0eeb113ed77
refs/heads/master
2020-03-16T17:42:34.840154
2018-05-11T10:16:04
2018-05-11T10:16:04
132,843,706
0
0
null
null
null
null
UTF-8
Java
false
false
1,057
java
package com.reddit.frontpage.presentation.listing.ui.view; import com.reddit.frontpage.C1761R; import kotlin.Metadata; import kotlin.jvm.functions.Function0; import kotlin.jvm.internal.Lambda; @Metadata(bv = {1, 0, 2}, d1 = {"\u0000\n\n\u0000\n\u0002\u0018\u0002\n\u0002\b\u0002\u0010\u0000\u001a\n \u0002*\u0004\u0018\u00010\u00010\u0001H\n¢\u0006\u0002\b\u0003"}, d2 = {"<anonymous>", "Lcom/reddit/frontpage/presentation/listing/ui/view/UserIndicatorsView;", "kotlin.jvm.PlatformType", "invoke"}, k = 3, mv = {1, 1, 9}) /* compiled from: HeaderMetadataView.kt */ final class HeaderMetadataView$bottomMetadataIndicators$2 extends Lambda implements Function0<UserIndicatorsView> { final /* synthetic */ HeaderMetadataView f36830a; HeaderMetadataView$bottomMetadataIndicators$2(HeaderMetadataView headerMetadataView) { this.f36830a = headerMetadataView; super(0); } public final /* synthetic */ Object invoke() { return (UserIndicatorsView) this.f36830a.mo4901a(C1761R.id.bottom_row_metadata_indicators); } }
[ "mi.arevalo10@uniandes.edu.co" ]
mi.arevalo10@uniandes.edu.co
14d997e7663b8435dadf5a414f14ae3a9f54ee31
cf8ce47e5f608740169e671625034feffb9260e9
/shopping-api/src/main/java/com/programyourhome/shop/model/PyhProductProperties.java
14a521878c8e3d038f70a6353e52b3838902983c
[]
no_license
ewjmulder/program-your-home
a0c98980e7859c29bcb5014238a0542db783959b
ed3f6b64f12d3fd03e38e5dacbb3c049c9a2770a
refs/heads/master
2020-12-20T12:33:18.718302
2017-12-19T11:04:40
2017-12-19T11:04:40
23,797,369
6
0
null
null
null
null
UTF-8
Java
false
false
245
java
package com.programyourhome.shop.model; public interface PyhProductProperties { public String getBarcode(); public String getName(); public String getDescription(); public PyhProductSizeProperties getSize(); }
[ "ewjmulder@yahoo.com" ]
ewjmulder@yahoo.com
ed5676efc6b874498b3d954ed8c6b46c4c4b3858
62e330c99cd6cedf20bc162454b8160c5e1a0df8
/basex-core/src/main/java/org/basex/query/func/fn/FnSubstringAfter.java
92e062618de9809e5b45b301aae9b29e33210d4f
[ "BSD-3-Clause" ]
permissive
nachawati/basex
76a717b069dcea3932fad5116e0a42a727052b58
0bc95648390ec3e91b8fd3e6ddb9ba8f19158807
refs/heads/master
2021-07-20T06:57:18.969297
2017-10-31T04:17:00
2017-10-31T04:17:00
106,351,382
0
0
null
2017-10-10T01:00:38
2017-10-10T01:00:38
null
UTF-8
Java
false
false
849
java
package org.basex.query.func.fn; import static org.basex.util.Token.*; import org.basex.query.*; import org.basex.query.func.*; import org.basex.query.util.collation.*; import org.basex.query.value.item.*; import org.basex.util.*; /** * Function implementation. * * @author BaseX Team 2005-17, BSD License * @author Christian Gruen */ public final class FnSubstringAfter extends StandardFunc { @Override public Item item(final QueryContext qc, final InputInfo ii) throws QueryException { final byte[] ss = toEmptyToken(exprs[0], qc), sb = toEmptyToken(exprs[1], qc); final Collation coll = toCollation(2, qc); if(coll == null) { final int p = indexOf(ss, sb); return p == -1 ? Str.ZERO : Str.get(substring(ss, p + sb.length)); } return Str.get(coll.after(ss, sb, info)); } }
[ "mnachawa@gmu.edu" ]
mnachawa@gmu.edu
1db710906bbfed36df9706b534a963b69577bb17
69a4f2d51ebeea36c4d8192e25cfb5f3f77bef5e
/files/File_1016085.java
b886a0eece7010a31e296f8134d93b8eb54680d5
[ "Apache-2.0" ]
permissive
P79N6A/icse_20_user_study
5b9c42c6384502fdc9588430899f257761f1f506
8a3676bc96059ea2c4f6d209016f5088a5628f3c
refs/heads/master
2020-06-24T08:25:22.606717
2019-07-25T15:31:16
2019-07-25T15:31:16
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,991
java
/* * This file is part of WebLookAndFeel library. * * WebLookAndFeel library 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. * * WebLookAndFeel library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with WebLookAndFeel library. If not, see <http://www.gnu.org/licenses/>. */ package com.alee.managers.language.data; import com.alee.utils.HtmlUtils; import com.alee.utils.TextUtils; import com.thoughtworks.xstream.annotations.XStreamAlias; import com.thoughtworks.xstream.annotations.XStreamConverter; import java.io.Serializable; /** * User: mgarin Date: 16.05.12 Time: 17:17 */ @XStreamAlias ("text") @XStreamConverter (TextConverter.class) public final class Text implements Serializable, Cloneable { private String text; private String state; public Text () { this ( "" ); } public Text ( String text ) { this ( text, null ); } public Text ( String text, String state ) { super (); this.text = text; this.state = state; } public String getText () { return text; } public void setText ( String text ) { this.text = text; } public String getState () { return state; } public void setState ( String state ) { this.state = state; } @Override public Text clone () { return new Text ( text, state ); } public String toString () { return TextUtils.shortenText ( HtmlUtils.getPlainText ( text ), 50, true ); } }
[ "sonnguyen@utdallas.edu" ]
sonnguyen@utdallas.edu
2ba8e719cf41723f80a6ee6e596169e31ad8be88
cf5ff8e0bbd93e0d3110169bc7f89e2a2b2be60d
/yzim-easeui-SDK_3.1.3/src/com/yz/im/model/im/receiver/StartServiceReceiver.java
a50fb32f66b5f5dbea1ee86db97c4ef43e58112a
[ "Apache-2.0" ]
permissive
yaolu0311/ThinkcooRefactor-2016526
993c09b50719322d9d89621f2d991e4687ab81f8
bfe011a0650ca0c80932dc45c2e60868966afda6
refs/heads/master
2020-09-26T05:30:24.155465
2016-09-05T07:12:13
2016-09-05T07:12:13
67,396,724
0
0
null
null
null
null
UTF-8
Java
false
false
1,016
java
/************************************************************ * * Hyphenate CONFIDENTIAL * __________________ * Copyright (C) 2016 Hyphenate Inc. All rights reserved. * * NOTICE: All information contained herein is, and remains * the property of Hyphenate Inc.. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Hyphenate Inc. */ package com.yz.im.model.im.receiver; import android.content.BroadcastReceiver; import android.content.Context; import android.content.Intent; import com.hyphenate.chat.EMChatService; import com.hyphenate.util.EMLog; public class StartServiceReceiver extends BroadcastReceiver{ @Override public void onReceive(Context context, Intent intent) { EMLog.d("boot", "start IM service on boot"); Intent startServiceIntent=new Intent(context, EMChatService.class); startServiceIntent.putExtra("reason", "boot"); context.startService(startServiceIntent); } }
[ "yaolu0311@163.com" ]
yaolu0311@163.com
788100ef0f57031958d7a1f6f7c08e78e14fd697
d1bd1246f161b77efb418a9c24ee544d59fd1d20
/java/Lightning/src/org/javenstudio/lightning/context/ConfigPluginInfo.java
8032457ef4265df143978ad6872192e0dff8b37c
[]
no_license
navychen2003/javen
f9a94b2e69443291d4b5c3db5a0fc0d1206d2d4a
a3c2312bc24356b1c58b1664543364bfc80e816d
refs/heads/master
2021-01-20T12:12:46.040953
2015-03-03T06:14:46
2015-03-03T06:14:46
30,912,222
0
1
null
2023-03-20T11:55:50
2015-02-17T10:24:28
Java
UTF-8
Java
false
false
3,231
java
package org.javenstudio.lightning.context; import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; import java.util.HashSet; import java.util.Iterator; import java.util.List; import java.util.Map; import java.util.Set; import org.javenstudio.falcon.ErrorException; import org.javenstudio.falcon.util.ContextNode; import org.javenstudio.falcon.util.NamedList; import org.javenstudio.falcon.util.PluginInfo; public class ConfigPluginInfo extends PluginInfo { @SuppressWarnings("rawtypes") public static final PluginInfo EMPTY_INFO = new ConfigPluginInfo("", Collections.<String,String>emptyMap(), new NamedList(), Collections.<PluginInfo>emptyList()); private static final Set<String> NL_TAGS = new HashSet<String>( Arrays.asList("lst", "arr", "bool", "str", "int", "long", "float", "double")); private final String mName, mClassName, mType; private final NamedList<?> mInitArgs; private final Map<String, String> mAttributes; private final List<PluginInfo> mChildren; public ConfigPluginInfo(String type, Map<String,String> attrs, NamedList<?> initArgs, List<PluginInfo> children) { mType = type; mName = attrs.get("name"); mClassName = attrs.get("class"); mInitArgs = initArgs; mAttributes = Collections.unmodifiableMap(attrs); mChildren = (children == null) ? Collections.<PluginInfo>emptyList() : Collections.unmodifiableList(children); } public ConfigPluginInfo(ContextNode node, String error, boolean requireName, boolean requireClass) throws ErrorException { mType = node.getNodeName(); mName = node.getAttribute("name", requireName ? error : null); mClassName = node.getAttribute("class", requireClass ? error : null); mInitArgs = node.getChildNodesAsNamedList(); mAttributes = Collections.unmodifiableMap(node.getAttributes()); mChildren = loadSubPlugins(node); } public final String getName() { return mName; } public final String getClassName() { return mClassName; } public final String getType() { return mType; } public final NamedList<?> getInitArgs() { return mInitArgs; } public final List<PluginInfo> getChildren() { return mChildren; } @Override public final String getAttribute(String name) { return mAttributes.get(name); } private List<PluginInfo> loadSubPlugins(ContextNode node) throws ErrorException { List<PluginInfo> children = new ArrayList<PluginInfo>(); //if there is another sub tag with a non namedlist tag that has to be another plugin Iterator<ContextNode> nodes = node.getChildNodes(); while (nodes.hasNext()) { ConfigNode nd = (ConfigNode)nodes.next(); if (!nd.isElementNode()) continue; if (NL_TAGS.contains(nd.getNodeName())) continue; PluginInfo pluginInfo = new ConfigPluginInfo(nd, null, false, false); if (pluginInfo.isEnabled()) children.add(pluginInfo); } return children.isEmpty() ? Collections.<PluginInfo>emptyList() : Collections.unmodifiableList(children); } @Override public boolean isEnabled() { String enable = mAttributes.get("enable"); return enable == null || Boolean.parseBoolean(enable); } @Override public boolean isDefault() { return Boolean.parseBoolean(mAttributes.get("default")); } }
[ "navychen2003@hotmail.com" ]
navychen2003@hotmail.com
d687598d40a922f91944cf13d7150e1848f262b2
311918587dec5cce54cd436aa437222481c93073
/coding_tx/src/main/java/com/temp/common/complier/test/demo1/compiler.java
186b7566bf21ffb65354fd13ac567f85370c28c4
[]
no_license
liwen666/component
7f7ad2290e77632490012306cc835d43c71c8ca6
2b1839954bb58eb0adad9e32090d9b971c1577b9
refs/heads/master
2022-12-21T11:14:17.461104
2021-04-25T08:49:41
2021-04-25T08:49:41
163,070,384
0
1
null
2022-12-10T06:15:07
2018-12-25T09:55:09
Java
UTF-8
Java
false
false
2,493
java
package com.temp.common.complier.test.demo1; import com.temp.common.complier.tools.JavaStringCompiler; import com.temp.common.utils.PackageScanUtils; import lombok.Cleanup; import java.io.FileInputStream; import java.io.FileNotFoundException; import java.io.FileOutputStream; import java.io.IOException; import com.temp.common.complier.tools.JavaStringCompiler; import com.temp.common.utils.PackageScanUtils; import lombok.Cleanup; import java.io.FileInputStream; import java.io.FileNotFoundException; import java.io.FileOutputStream; import java.io.IOException; import com.google.common.collect.Lists; import com.temp.common.base.io.pagescan.PageScanUtil; import com.temp.common.complier.tools.JavaStringCompiler; import com.temp.common.utils.PackageScanUtils; import lombok.Cleanup; import org.springframework.core.io.Resource; import java.io.*; import java.util.ArrayList; import java.util.Map; /** * <p> * 描述 * </p> * * @author LW * @since 2021/3/11 13:58 */ public class compiler { public static void main(String[] args) throws IOException { String flinkJob = "hello"; ArrayList<File> objects = Lists.newArrayList(); PackageScanUtils.findResourceByPath("D:\\workspace\\test_workspace\\coding_tx\\src\\main\\java\\com\\temp\\common\\complier\\test\\demo1", objects); String outPath = "D:\\workspace\\test_workspace\\coding_tx\\src\\main\\java\\com\\temp\\common\\complier\\test\\out\\"; objects.forEach(e -> { System.out.println(e.getName()); System.out.println(e.getPath()); try { @Cleanup FileInputStream fileInputStream = new FileInputStream(e); byte[] cache = new byte[fileInputStream.available()]; fileInputStream.read(cache); String java = new String(cache, "utf-8"); System.out.println(java); Map<String, byte[]> results = new JavaStringCompiler().compile(e.getName(), java,""); System.out.println(results.size()); File outFile = new File(outPath + e.getName().split("\\.")[0] + ".class"); FileOutputStream outputStream = new FileOutputStream(outFile); outputStream.write(results.entrySet().iterator().next().getValue()); } catch (FileNotFoundException e1) { e1.printStackTrace(); } catch (IOException e1) { e1.printStackTrace(); } }); } }
[ "1438131288@qq.com" ]
1438131288@qq.com
e4ef51b85fce733048194555e2563ac307a1bae3
d60e287543a95a20350c2caeabafbec517cabe75
/LACCPlus/Hadoop/2884_1.java
781571358946d9f49c7583f9c8f67264e609ea45
[ "MIT" ]
permissive
sgholamian/log-aware-clone-detection
242067df2db6fd056f8d917cfbc143615c558b2c
9993cb081c420413c231d1807bfff342c39aa69a
refs/heads/main
2023-07-20T09:32:19.757643
2021-08-27T15:02:50
2021-08-27T15:02:50
337,837,827
0
0
null
null
null
null
UTF-8
Java
false
false
881
java
//,temp,TestFileBasedCopyListing.java,429,452,temp,TestIntegration.java,343,361 //,3 public class xxx { @Test public void testGlobTargetDirMultiLevel() { try { Path listFile = new Path("/tmp1/listing"); Path target = new Path("/tmp/target"); addEntries(listFile, "/tmp/*/*"); createFiles("/tmp/multifile/file3", "/tmp/multifile/file4", "/tmp/multifile/file5"); createFiles("/tmp/singledir1/dir3/file7", "/tmp/singledir1/dir3/file8", "/tmp/singledir1/dir3/file9"); mkdirs(target.toString()); runTest(listFile, target, true); checkResult(listFile, 6); } catch (IOException e) { LOG.error("Exception encountered while testing build listing", e); Assert.fail("build listing failure"); } finally { TestDistCpUtils.delete(fs, "/tmp"); TestDistCpUtils.delete(fs, "/tmp1"); } } };
[ "sgholami@uwaterloo.ca" ]
sgholami@uwaterloo.ca
a674f3e593a2e8111c645539da40ae0b42055139
c119200e73847cbcb9eb956f5254fb05f912238e
/core/org.wso2.carbon.tomcat.ext/src/main/java/org/wso2/carbon/tomcat/ext/filter/CharacterSetFilter.java
27b9241a525716f8ea813564bfcf5d9ab27f0e95
[]
no_license
kasunbg/carbon-kernel-4.x
ac04423bc482ae4cdf98cbb92ad19b9b2be1dd9f
ea7a3cfea7b657d187f38e7628c56970b70c0491
refs/heads/master
2022-06-05T21:32:00.953299
2016-12-01T06:52:35
2016-12-01T06:52:35
75,286,577
0
2
null
2022-05-20T20:47:53
2016-12-01T11:33:12
Java
UTF-8
Java
false
false
2,155
java
/* * Copyright (c) 2005-2012, WSO2 Inc. (http://www.wso2.org) All Rights Reserved. * * WSO2 Inc. licenses this file to you under the Apache License, * Version 2.0 (the "License"); you may not use this file except * in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations * under the License. */ package org.wso2.carbon.tomcat.ext.filter; import javax.servlet.*; import java.io.IOException; /*** * This is a filter class to force the java webapp to handle all requests and responses as UTF-8 encoded by default. * This requires that we define a character set filter. * This filter makes sure that if the browser hasn't set the encoding used in the request, that it's set to UTF-8. */ public class CharacterSetFilter implements Filter { private static final String UTF8 = "UTF-8"; private static final String CONTENT_TYPE = "text/html; charset=UTF-8"; private String encoding; @Override public void init(FilterConfig config) throws ServletException { encoding = config.getInitParameter("requestEncoding"); if (encoding == null) { encoding = UTF8; } } @Override public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException { // Respect the client-specified character encoding // (see HTTP specification section 3.4.1) if (null == request.getCharacterEncoding()) { request.setCharacterEncoding(encoding); } /** * Set the default response content type and encoding */ response.setContentType(CONTENT_TYPE); response.setCharacterEncoding(UTF8); chain.doFilter(request, response); } @Override public void destroy() { } }
[ "eranda@wso2.com" ]
eranda@wso2.com
315d6aedfd69a40d5b79e53b48abc1f0f50cb90f
9c9067d9bfa19f052a433ec4111c97b686a6ac5e
/ch12/spring-java-config/src/main/java/jun/projavawebapp/config/RootContextConfiguration.java
a68390fe6c3a7f8b5212d9412b876bc70b7d229f
[ "MIT" ]
permissive
jdcsma/projavawebapp
c289123b59db4901a6d1760a9641c3117a357e73
50c596fb91fdc9e4c8b97b76557929fea2041bb6
refs/heads/master
2022-12-22T01:59:01.812147
2020-05-27T17:21:11
2020-05-27T17:21:11
185,805,881
0
0
MIT
2022-12-16T15:27:38
2019-05-09T13:36:51
Java
UTF-8
Java
false
false
419
java
package jun.projavawebapp.config; import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.Configuration; import org.springframework.stereotype.Controller; @Configuration @ComponentScan(basePackages = {"jun.projavawebapp.site", "jun.projavawebapp.awarer"}, excludeFilters = {@ComponentScan.Filter(Controller.class)}) public class RootContextConfiguration { }
[ "jdcsma@163.com" ]
jdcsma@163.com
c0f8c04d64893e9391df3e4c601bb2557d821027
e27ca5fe3e7f49a0e39a9cacec516e5b63fcae32
/src/com/clouds/www/QuickSort.java
1c8030a489cf23ae6c46c38684a761866b33c639
[]
no_license
yao23/Java_Playground
0cb49c98df5c3c149bdc174a2e27aac11b914d58
aa7496b9e55e30952075b47d82be01190166c0ad
refs/heads/master
2023-09-03T05:21:11.864445
2023-09-02T05:46:29
2023-09-02T05:46:29
92,258,959
3
1
null
null
null
null
UTF-8
Java
false
false
1,270
java
package com.clouds.www; /** * Stability: No relative partition position guaranteed * stability: No */ public class QuickSort { // time: average O(nlogn), worst O(n^2), space: O(1) private void doQuickSort(int[] arr, int start, int end) { if (start >= end) { return; } int partitionPos = partition(arr, start, end); doQuickSort(arr, start, partitionPos); doQuickSort(arr, partitionPos + 1, end); } private int partition(int[] arr, int left, int right) { int ran = left + (int)(Math.random() * (right - left + 1)); int pivot = arr[ran]; // switch pivot to the leftmost arr[ran] = arr[left]; arr[left] = pivot; while (left < right) { // find a smaller element from right while (left < right && arr[right] >= pivot) { right--; } // put to the left arr[left] = arr[right]; // find a larger element from left while (left < right && arr[left] <= pivot) { left++; } // put to the right arr[right] = arr[left]; } // put the pivot back arr[left] = pivot; return left; } }
[ "myspiritcrazy@gmail.com" ]
myspiritcrazy@gmail.com
7bf65af5bd7f41f2c964432c2f3cf0ec246c13da
38f8944b4a80f38d158a075d4c1e96b09345763b
/version-1/src/com/hive/Mode/HiveSearch.java
4d2dcd11d8ac8f5f3f3f97102ff6d54bc2b3df59
[]
no_license
Glacier759/MyHive
bf2982d2da0a80d9d7e42a0d86985e7bc6c6c91f
13272ad5f5c546524b424ac18ab7c5dc3ddf8bb4
refs/heads/master
2021-01-20T09:01:06.085528
2014-08-02T09:49:07
2014-08-02T09:49:07
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,532
java
package com.hive.Mode; import java.io.IOException; import java.net.SocketTimeoutException; import java.net.URL; import java.util.Iterator; import java.util.Set; import org.jsoup.HttpStatusException; import org.jsoup.Jsoup; import org.jsoup.nodes.Document; import org.jsoup.nodes.Element; import org.jsoup.select.Elements; import com.hive.Parameter.HiveParameter; import com.hive.Save.HiveSaveData; import com.hive.SearchEngine.ThreeSixZeroSpider; public class HiveSearch { private HiveParameter hiveParameter = null; public HiveSearch( HiveParameter hiveParameter ) { this.hiveParameter = hiveParameter; } public void doSaveData() { try { //添加搜索引擎 ThreeSixZeroSpider Spider360 = new ThreeSixZeroSpider( hiveParameter ); Set<String> UrlSet = Spider360.doParse360(); System.out.println(UrlSet.size()); Iterator<String> itr = UrlSet.iterator(); int NO = UrlSet.size(); while( itr.hasNext() ) { String purl = itr.next(); System.out.println("剩余:"+NO+"\t"+purl); String Hostname = new URL(purl).getHost(); NO--; Document Doc = null; try { Doc = Jsoup.connect(purl).timeout(5000) .userAgent("Mozilla/5.0 (X11; Linux i686) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/33.0.1750.152 Safari/537.36") .get(); } catch( SocketTimeoutException e ) { System.out.println("HiveSearch-doSaveData-42:\t" + e); continue; } catch( HttpStatusException e ) { System.out.println("HiveSearch-doSaveData-45:\t" + e); continue; } catch( Exception e ) { System.out.println(e); } //hiveParameter.hiveDatabase.insertUrl(purl); new HiveSaveData(hiveParameter).doSaveToDB(Doc.title(), purl, Doc.select("p").text(), hiveParameter.config.getSavePath()+hiveParameter.Ttag, true); Elements pageAllUrls = Doc.select("a[href]"); for ( Element pageAllUrl : pageAllUrls ) { String pageUrl = pageAllUrl.attr("abs:href"); if ( pageUrl.isEmpty() ) continue; String hostname = new URL(pageUrl).getHost(); //if ( (hostname.equals(Hostname) && !(hiveParameter.hiveDatabase.isUniqueURL(pageUrl))) ) { if ( (hostname.equals(Hostname)) && !(hiveParameter.hiveBloomFilter.isUniqueValue(pageUrl)) ) { //System.out.println("push redis" + hiveParameter.hiveRedis.getKey()); hiveParameter.hiveRedis.pushValue(pageUrl); //hiveParameter.hiveDatabase.insertUrl(pageUrl); //抓取后再加入数据库才对 } } } } catch( Exception e ) { System.out.println(e); } } }
[ "OurHom.759@gmail.com" ]
OurHom.759@gmail.com
070300fa7de278d8cf9fe2181b121dfc14a52300
2c6e2ba03eb71ca45fe690ff6e4586f6e2fa0f17
/material/apks/banco/sources/com/google/common/util/concurrent/ListenableScheduledFuture.java
56d0983b3e3d91eb52a5c3ac377f4a3f694cf885
[]
no_license
lcrcastor/curso-mobile-2019
3088a196139b3e980ed6e09797a0bbf5efb6440b
7585fccb6437a17c841772c1d9fb0701d6c68042
refs/heads/master
2023-04-06T21:46:32.333236
2020-10-30T19:47:54
2020-10-30T19:47:54
308,680,747
0
1
null
2023-03-26T06:57:57
2020-10-30T16:08:31
Java
UTF-8
Java
false
false
308
java
package com.google.common.util.concurrent; import com.google.common.annotations.Beta; import com.google.common.annotations.GwtIncompatible; import java.util.concurrent.ScheduledFuture; @GwtIncompatible @Beta public interface ListenableScheduledFuture<V> extends ListenableFuture<V>, ScheduledFuture<V> { }
[ "luis@MARK-2.local" ]
luis@MARK-2.local
137f9cdc43bd5b56a54b64db5782dde5148a9b12
70ab4ad77435fbd0c893a4487c21b2bd232b8b1d
/components/org.wso2.carbon.identity.oauth/src/main/java/org/wso2/carbon/identity/oauth2/device/dao/DeviceFlowDAO.java
24a0b44d2a2b8ad7efd5b10a82918ff77ced1ae7
[ "Apache-2.0" ]
permissive
janakamarasena/identity-inbound-auth-oauth-clone
47d5dd05f10b66fc72ce8e0e14fcec7cb7607ad2
cb6115d55c7256811934715c0f2d200e4cff2fb0
refs/heads/master
2022-12-20T02:48:35.448565
2020-10-24T18:49:48
2020-10-24T18:49:48
306,883,487
0
1
Apache-2.0
2020-10-24T19:33:54
2020-10-24T12:55:32
Java
UTF-8
Java
false
false
5,789
java
/* * Copyright (c) 2019, WSO2 Inc. (http://www.wso2.org) All Rights Reserved. * * WSO2 Inc. licenses this file to you under the Apache License, * Version 2.0 (the "License"); you may not use this file except * in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations * under the License. */ package org.wso2.carbon.identity.oauth2.device.dao; import org.wso2.carbon.identity.application.authentication.framework.model.AuthenticatedUser; import org.wso2.carbon.identity.oauth2.IdentityOAuth2Exception; import org.wso2.carbon.identity.oauth2.device.model.DeviceFlowDO; import java.sql.Timestamp; /** * New set of DAO classes for each purpose and factory class to get instance of each DAO classes were introduced * during this step. */ public interface DeviceFlowDAO { /** * This will be used to enter the value to the database tables. * * @param deviceCode Code that is used to identify the device. * @param userCode Code that is used to correlate user and device. * @param consumerKey Consumer key of the client application. * @param expiresIn Device code valid period. * @param interval Polling interval. * @param scopes Requested scopes. * @throws IdentityOAuth2Exception Error while inserting device flow parameters. */ void insertDeviceFlowParameters(String deviceCode, String userCode, String consumerKey, Long expiresIn, int interval, String scopes) throws IdentityOAuth2Exception; /** * Get the client id that has involved with user code. * * @param userCode Code that is used to correlate user and device. * @return client_id * @throws IdentityOAuth2Exception Error while getting client id for user code. */ String getClientIdByUserCode(String userCode) throws IdentityOAuth2Exception; /** * Set the status of the user code and device code. * * @param userCode Code that is used to correlate user and device. * @param status Status of the device and user codes. * @throws IdentityOAuth2Exception Error while setting authentication status. */ void setAuthenticationStatus(String userCode, String status) throws IdentityOAuth2Exception; /** * Get the authentication status for device code. * * @param deviceCode Code that is used to identify the device. * @return Map of values. * @throws IdentityOAuth2Exception Error while getting authentication details. */ DeviceFlowDO getAuthenticationDetails(String deviceCode) throws IdentityOAuth2Exception; /** * Check client id is exist or not. * * @param clientId Consumer key of the application. * @return Exist or not. * @throws IdentityOAuth2Exception Error while checking client id exist. */ boolean checkClientIdExist(String clientId) throws IdentityOAuth2Exception; /** * Get the status of the user code. * * @param userCode Code that is used to correlate user and device. * @return status * @throws IdentityOAuth2Exception Error while getting status for user code. */ String getStatusForUserCode(String userCode) throws IdentityOAuth2Exception; /** * Set last poll time of the token request. * * @param deviceCode Code that is used to identify the device. * @param newPollTime Last poll time. * @throws IdentityOAuth2Exception Error while setting last poll time. */ void setLastPollTime(String deviceCode, Timestamp newPollTime) throws IdentityOAuth2Exception; /** * Set authenticated user. * * @param userCode Code that is used to correlate user and device. * @param status Status of the device code. * @param authzUser Authenticated user. * @throws IdentityOAuth2Exception Error while setting authenticated user and status. */ void setAuthzUserAndStatus(String userCode, String status, AuthenticatedUser authzUser) throws IdentityOAuth2Exception; /** * Set device code as expired. * * @param deviceCode Code that is used to identify the device. * @param status Status of the device code. * @throws IdentityOAuth2Exception Error while setting device code as expired. */ void setDeviceCodeExpired(String deviceCode, String status) throws IdentityOAuth2Exception; /** * Set callback uri of the service provider. * * @param clientId Consumer key of service provide. * @param callBackUri Callback uri of the service provider. * @throws IdentityOAuth2Exception Error while Setting callback uri. */ void setCallbackURI(String clientId, String callBackUri) throws IdentityOAuth2Exception; /** * Return scope array for user code. * * @param userCode Code that is used to correlate user and device. * @return Array of scopes. * @throws IdentityOAuth2Exception Error while getting scopes for user code. */ String[] getScopesForUserCode(String userCode) throws IdentityOAuth2Exception; /** * Return scope array for device code. * * @param deviceCode Code that is used to identify the device. * @return Array of scopes. * @throws IdentityOAuth2Exception Error while getting scopes for device code. */ String[] getScopesForDeviceCode(String deviceCode) throws IdentityOAuth2Exception; }
[ "janakamarasena@gmail.com" ]
janakamarasena@gmail.com
1ccefbcd1cf0b98900d459502e254b5e4e61925d
009e70fc9c458797947ab11959b1fc1e11725c3f
/app/src/main/java/com/fupengpeng/shoppingmall/entity/IntegralSequenceObject.java
7bb1d8f36540ca09808d2bb3c38e30a376e5c58f
[]
no_license
fupengpeng/ShoppingMall
eca29dc1b584c02df5df42ecccb877b5417cb088
47203b1788f1db071a39aeb88c7b5295606fce27
refs/heads/master
2020-04-05T13:31:49.051180
2017-07-11T10:05:03
2017-07-11T10:05:03
94,762,349
0
0
null
null
null
null
UTF-8
Java
false
false
1,850
java
package com.fupengpeng.shoppingmall.entity; import java.io.Serializable; /** * Created by fupengpeng on 2017/6/13 0013. * 积分排名实体类 */ public class IntegralSequenceObject implements Serializable{ /** * 用户名次 */ private String integralSequenceRanking; /** * 用户图像 */ private int integralSequenceUserPic; /** * 用户名 */ private String integralSequenceUsername; /** * 名次图像 */ private int integralSequenceRankingPic; /** * 用户积分 */ private String integralSequenceIntegral; public String getIntegralSequenceRanking() { return integralSequenceRanking; } public void setIntegralSequenceRanking(String integralSequenceRanking) { this.integralSequenceRanking = integralSequenceRanking; } public int getIntegralSequenceUserPic() { return integralSequenceUserPic; } public void setIntegralSequenceUserPic(int integralSequenceUserPic) { this.integralSequenceUserPic = integralSequenceUserPic; } public String getIntegralSequenceUsername() { return integralSequenceUsername; } public void setIntegralSequenceUsername(String integralSequenceUsername) { this.integralSequenceUsername = integralSequenceUsername; } public int getIntegralSequenceRankingPic() { return integralSequenceRankingPic; } public void setIntegralSequenceRankingPic(int integralSequenceRankingPic) { this.integralSequenceRankingPic = integralSequenceRankingPic; } public String getIntegralSequenceIntegral() { return integralSequenceIntegral; } public void setIntegralSequenceIntegral(String integralSequenceIntegral) { this.integralSequenceIntegral = integralSequenceIntegral; } }
[ "564055710@qq.com" ]
564055710@qq.com
8fe7662e7f33fc18103c747c90b66a7044a1afd2
9d376922bfa5efa214e06bd467a1e8df5c322cdd
/app/src/main/java/com/example/abbasahmednawaz/prayeralert/Activities/Events_List_Activity.java
a57f5404a4ef95382d0d97acc7e655d46c7ee815
[]
no_license
fazalwahab/Android-Based-Prayer-Alert-System-For-District-Mansehra
5596fc5f02010064d9524a1ac86d49504b7c05bc
2bf3b13c8bd5c04f29b11d5806ef475bd7e4f3ed
refs/heads/master
2020-09-23T05:20:07.592883
2019-12-02T17:15:07
2019-12-02T17:15:07
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,053
java
package com.example.abbasahmednawaz.prayeralert.Activities; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; import android.support.v7.widget.LinearLayoutManager; import android.support.v7.widget.RecyclerView; import android.widget.Toast; import com.example.abbasahmednawaz.prayeralert.Classes.PrefConfig; import com.example.abbasahmednawaz.prayeralert.Classes.RecyclerAdapter; import com.example.abbasahmednawaz.prayeralert.Classes.RecyclerAdapter_Events; import com.example.abbasahmednawaz.prayeralert.R; import com.google.gson.Gson; import com.google.gson.reflect.TypeToken; import java.lang.reflect.Type; import java.util.ArrayList; public class Events_List_Activity extends AppCompatActivity { private RecyclerView recyclerView; private RecyclerAdapter_Events recyclerAdapter; public PrefConfig prefConfig; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_events__list_); //------------ prefConfig = new PrefConfig(getApplicationContext()); //---------------------------------------------------------------------------------------- recyclerView = (RecyclerView) findViewById(R.id.recyclerview_events_list); recyclerView.setHasFixedSize(true); RecyclerView.LayoutManager layoutManager = new LinearLayoutManager(getApplicationContext()); recyclerView.setLayoutManager(layoutManager); //------------------getting info array----- showData(); //------------- } public void showData() { if( prefConfig.readEvent() != null ) { Gson gson = new Gson(); String json = prefConfig.readEvent(); Type type = new TypeToken<ArrayList<String>>() {}.getType(); ArrayList<String> list = gson.fromJson(json, type); recyclerAdapter = new RecyclerAdapter_Events(list); recyclerView.setAdapter(recyclerAdapter); } } }
[ "you@example.com" ]
you@example.com
e8682db73304beb7a7b19ac868e2892843ad23e2
aa82c44707cbb70da67c3dabdde11e162e56a1b6
/com.jtrent238.jtcraft/src/main/java/beh.java
c88d78c002cdba18004f54bafffc2d7c659f5589
[]
no_license
jtrent238/jtcraft
c6804899969c7e5776253c5122539848c7de5f50
290820012690e87a491eaa450b9154fd9cf96115
refs/heads/master
2021-01-10T09:28:28.084577
2016-03-03T02:52:04
2016-03-03T02:52:04
53,013,456
0
0
null
null
null
null
UTF-8
Java
false
false
4,154
java
/* */ import org.lwjgl.opengl.GL11; /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ public class beh /* */ extends bbw /* */ { /* 16 */ private static final bqx a = new bqx("textures/gui/achievement/achievement_background.png"); /* */ private bao f; /* */ private int g; /* */ private int h; /* */ private String i; /* */ private String j; /* */ private pb k; /* */ private long l; /* */ private bny m; /* */ private boolean n; /* */ /* */ public beh(bao parambao) { /* 28 */ this.f = parambao; /* 29 */ this.m = new bny(); /* */ } /* */ /* */ public void a(pb parampb) { /* 33 */ this.i = brp.a("achievement.get", new Object[0]); /* 34 */ this.j = parampb.e().c(); /* 35 */ this.l = bao.K(); /* 36 */ this.k = parampb; /* 37 */ this.n = false; /* */ } /* */ /* */ public void b(pb parampb) { /* 41 */ this.i = parampb.e().c(); /* 42 */ this.j = parampb.f(); /* */ /* 44 */ this.l = (bao.K() + 2500L); /* 45 */ this.k = parampb; /* 46 */ this.n = true; /* */ } /* */ /* */ private void c() { /* 50 */ GL11.glViewport(0, 0, this.f.d, this.f.e); /* 51 */ GL11.glMatrixMode(5889); /* 52 */ GL11.glLoadIdentity(); /* 53 */ GL11.glMatrixMode(5888); /* 54 */ GL11.glLoadIdentity(); /* */ /* 56 */ this.g = this.f.d; /* 57 */ this.h = this.f.e; /* */ /* 59 */ bca localbca = new bca(this.f, this.f.d, this.f.e); /* 60 */ this.g = localbca.a(); /* 61 */ this.h = localbca.b(); /* */ /* 63 */ GL11.glClear(256); /* 64 */ GL11.glMatrixMode(5889); /* 65 */ GL11.glLoadIdentity(); /* 66 */ GL11.glOrtho(0.0D, this.g, this.h, 0.0D, 1000.0D, 3000.0D); /* 67 */ GL11.glMatrixMode(5888); /* 68 */ GL11.glLoadIdentity(); /* 69 */ GL11.glTranslatef(0.0F, 0.0F, -2000.0F); /* */ } /* */ /* */ public void a() { /* 73 */ if ((this.k == null) || (this.l == 0L) || (bao.B().h == null)) { return; /* */ } /* 75 */ double d1 = (bao.K() - this.l) / 3000.0D; /* 76 */ if (!this.n) { /* 77 */ if ((d1 < 0.0D) || (d1 > 1.0D)) { /* 78 */ this.l = 0L; /* */ } /* */ /* */ } /* 82 */ else if (d1 > 0.5D) { d1 = 0.5D; /* */ } /* */ /* 85 */ c(); /* 86 */ GL11.glDisable(2929); /* 87 */ GL11.glDepthMask(false); /* */ /* 89 */ double d2 = d1 * 2.0D; /* 90 */ if (d2 > 1.0D) d2 = 2.0D - d2; /* 91 */ d2 *= 4.0D; /* 92 */ d2 = 1.0D - d2; /* 93 */ if (d2 < 0.0D) d2 = 0.0D; /* 94 */ d2 *= d2; /* 95 */ d2 *= d2; /* */ /* 97 */ int i1 = this.g - 160; /* 98 */ int i2 = 0 - (int)(d2 * 36.0D); /* 99 */ GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); /* 100 */ GL11.glEnable(3553); /* 101 */ this.f.P().a(a); /* 102 */ GL11.glDisable(2896); /* */ /* 104 */ b(i1, i2, 96, 202, 160, 32); /* */ /* 106 */ if (this.n) { /* 107 */ this.f.l.a(this.j, i1 + 30, i2 + 7, 120, -1); /* */ } else { /* 109 */ this.f.l.b(this.i, i1 + 30, i2 + 7, 65280); /* 110 */ this.f.l.b(this.j, i1 + 30, i2 + 18, -1); /* */ } /* */ /* 113 */ bam.c(); /* 114 */ GL11.glDisable(2896); /* 115 */ GL11.glEnable(32826); /* 116 */ GL11.glEnable(2903); /* */ /* 118 */ GL11.glEnable(2896); /* 119 */ this.m.b(this.f.l, this.f.P(), this.k.d, i1 + 8, i2 + 8); /* 120 */ GL11.glDisable(2896); /* */ /* 122 */ GL11.glDepthMask(true); /* 123 */ GL11.glEnable(2929); /* */ } /* */ /* */ public void b() { /* 127 */ this.k = null; /* 128 */ this.l = 0L; /* */ } /* */ } /* Location: C:\Users\trent\.gradle\caches\minecraft\net\minecraft\minecraft\1.7.10\minecraft-1.7.10.jar!\beh.class * Java compiler version: 6 (50.0) * JD-Core Version: 0.7.1 */
[ "jtrent238@outlook.com" ]
jtrent238@outlook.com
b08695a3e97a25dcee5d8fa7ae9beb01057cacc0
7eb746c88662e75a19f66f363aadd5d5237242af
/app/src/main/java/org/newstand/datamigration/data/model/FileBasedRecord.java
7ffff6041730642965a90a8200d045a2acc28cd1
[]
no_license
Tornaco/DataMigration
f03824288e995fa2088d325afa76849a839591b4
7304d95a5feb2068d4f26585f5a8c50e087fcefa
refs/heads/master
2022-10-18T15:49:45.564065
2022-10-08T07:29:31
2022-10-08T07:29:31
84,621,616
19
5
null
2017-07-14T03:59:40
2017-03-11T03:42:24
Java
UTF-8
Java
false
false
807
java
package org.newstand.datamigration.data.model; import com.google.common.io.Files; import java.io.File; import java.io.FileNotFoundException; import java.io.IOException; import lombok.Getter; import lombok.NoArgsConstructor; import lombok.Setter; import lombok.ToString; /** * Created by Nick@NewStand.org on 2017/3/7 13:24 * E-Mail: NewStand@163.com * All right reserved. */ @Getter @Setter @NoArgsConstructor @ToString(callSuper = true) public class FileBasedRecord extends DataRecord { private long size; private String path; public long calculateSize() throws IOException { if (path == null || !new File(path).exists()) throw new FileNotFoundException(path); return size == 0 ? Files.asByteSource(new File(path)).size() : size; } }
[ "guohao4@lenovo.com" ]
guohao4@lenovo.com
37ad97bef4fdcfc00a9cdceed87f1e306ef5a827
09d0ddd512472a10bab82c912b66cbb13113fcbf
/TestApplications/TF-BETA-THERMATK-v5.7.1/DecompiledCode/JADX/src/main/java/org/telegram/p004ui/Components/C2516-$$Lambda$ChatActivityEnterView$0PqxYA4Sm4DXenEKSdETEwDwen0.java
70c7fac49e22406146c1316140a3f5fd5c72883e
[]
no_license
sgros/activity_flow_plugin
bde2de3745d95e8097c053795c9e990c829a88f4
9e59f8b3adacf078946990db9c58f4965a5ccb48
refs/heads/master
2020-06-19T02:39:13.865609
2019-07-08T20:17:28
2019-07-08T20:17:28
null
0
0
null
null
null
null
UTF-8
Java
false
false
734
java
package org.telegram.p004ui.Components; import android.view.View; import android.view.View.OnClickListener; /* compiled from: lambda */ /* renamed from: org.telegram.ui.Components.-$$Lambda$ChatActivityEnterView$0PqxYA4Sm4DXenEKSdETEwDwen0 */ public final /* synthetic */ class C2516-$$Lambda$ChatActivityEnterView$0PqxYA4Sm4DXenEKSdETEwDwen0 implements OnClickListener { private final /* synthetic */ ChatActivityEnterView f$0; public /* synthetic */ C2516-$$Lambda$ChatActivityEnterView$0PqxYA4Sm4DXenEKSdETEwDwen0(ChatActivityEnterView chatActivityEnterView) { this.f$0 = chatActivityEnterView; } public final void onClick(View view) { this.f$0.lambda$new$5$ChatActivityEnterView(view); } }
[ "crash@home.home.hr" ]
crash@home.home.hr
c6617e59d6251f66efd37e213d30995c59fbcf45
b641e97d985535e4f1d52c7891aa907f3eb0a254
/src/Components/net/raumzeitfalle/fx/filechooser/FindFilesTask.java
c1887e4f0952ec6763b4f7dbe44ffdd4a39d164a
[]
no_license
mmaciag1991/HarnessDesignSystemInterfaceDiagram
7e6f5dc078205475700dc2f63abc3f1e88e62728
4569676541a80dff1ffb5df6080799367e835065
refs/heads/main
2023-05-19T00:43:10.113472
2021-06-11T21:54:03
2021-06-11T21:54:03
375,101,913
0
0
null
null
null
null
UTF-8
Java
false
false
2,309
java
/*- * #%L * FXFileChooser * %% * Copyright (C) 2017 - 2019 Oliver Loeffler, Raumzeitfalle.net * %% * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * #L% */ package Components.net.raumzeitfalle.fx.filechooser; import javafx.collections.ObservableList; import javafx.concurrent.Task; import java.io.File; import java.nio.file.Path; import java.util.Objects; final class FindFilesTask extends Task<Integer>{ private final ObservableList<IndexedPath> pathsToUpdate; private final Path directory; public FindFilesTask(Path searchFolder, ObservableList<IndexedPath> listOfPaths) { this.pathsToUpdate = Objects.requireNonNull(listOfPaths, "listOfPaths must not be null"); this.directory = searchFolder; } /** * Even in case the directory to be processed is empty or does not exist, * the consumer collection is always cleared as first step. * * @return number of files found and processed */ @Override protected Integer call() throws Exception { Invoke.andWait(pathsToUpdate::clear); if (null == directory) return 0; File[] files = directory.toAbsolutePath().toFile().listFiles(); if (null == files) return 0; updateProgress(0, files.length); RefreshBuffer buffer = RefreshBuffer.get(this,files.length, pathsToUpdate); for (int f = 0; f < files.length; f++) { if (isCancelled()) break; updateProgress(f+1, files.length); if (files[f].isFile()) buffer.update(files[f].toPath()); } buffer.flush(); updateProgress(files.length, files.length); return files.length; } }
[ "mateo.m@wp.pl" ]
mateo.m@wp.pl
2bf3a77eca40e0d73505d96a3a96fb354bd2ea0a
a5e51767d0f67ae13ed13c03b8822817ba4b0167
/src/de/bsd/zwitscher/MultiSelectListActivity.java
0b9f5d82f076df53f24e86c5c7051e5249793fb0
[ "LicenseRef-scancode-unknown-license-reference", "Apache-2.0" ]
permissive
annamharikrishna01/ZwitscherA
c47fce5bd887c875666f0ddec0ebcfc9b4884b73
55c501a1a08bc648ee561263fb9497a8c71a57a7
refs/heads/master
2020-12-25T04:35:46.135880
2013-07-26T07:36:52
2013-07-26T07:36:52
null
0
0
null
null
null
null
UTF-8
Java
false
false
3,177
java
package de.bsd.zwitscher; import android.app.ListActivity; import android.content.Intent; import android.os.Bundle; import android.util.SparseBooleanArray; import android.view.View; import android.widget.AdapterView; import android.widget.ArrayAdapter; import android.widget.Button; import android.widget.ListView; import java.util.List; /** * Show a list with multiple items where the * user can select some from * * @author Heiko W. Rupp */ public class MultiSelectListActivity extends ListActivity implements AdapterView.OnItemClickListener { private String mode; public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); Bundle bundle = getIntent().getExtras(); List<String> data = bundle.getStringArrayList("data"); boolean[] checked = bundle.getBooleanArray("checked"); mode = bundle.getString("mode"); final ListView listView = getListView(); if (mode.equals("single")) { setListAdapter(new ArrayAdapter<String>(this, android.R.layout.simple_list_item_single_choice, data)); listView.setChoiceMode(ListView.CHOICE_MODE_SINGLE); listView.setOnItemClickListener(this); } else { Button okButton = new Button(this); okButton.setText("ok"); okButton.setEnabled(true); okButton.setVisibility(View.VISIBLE); okButton.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { SparseBooleanArray positions = getListView().getCheckedItemPositions(); int count = getListView().getCheckedItemCount(); long[] items = new long[count]; int pos = 0; for (int i = 0; i < getListView().getCount(); i++) { if (positions.get(i)) items[pos++] = i; } Intent intent = prepareReturnedIntent(); intent.putExtra("data", items); finish(); } }); listView.setChoiceMode(ListView.CHOICE_MODE_MULTIPLE); listView.addFooterView(okButton); // Needs to be called before setAdapter setListAdapter(new ArrayAdapter<String>(this, android.R.layout.simple_list_item_multiple_choice, data)); for (int i = 0; i < checked.length; i++) { getListView().setItemChecked(i,checked[i]); // does not check } } listView.setItemsCanFocus(false); } public void onItemClick(AdapterView<?> parent, View view, int position, long id) { ListView listView = getListView(); String item = (String) listView.getItemAtPosition(position); Intent intent = prepareReturnedIntent(); intent.putExtra("data", item); finish(); } private Intent prepareReturnedIntent() { Intent intent = new Intent(); intent.putExtra("mode",mode); setResult(RESULT_OK,intent); return intent; } }
[ "hwr@pilhuhn.de" ]
hwr@pilhuhn.de
4f757023f207f95d8f87be34e515b7238f5a5a4a
dfe5caf190661c003619bfe7a7944c527c917ee4
/src/main/java/com/vmware/vim25/AnswerFile.java
8e8fed71f0c8f474a33262643ed0bcdd2cd74284
[ "BSD-3-Clause" ]
permissive
timtasse/vijava
c9787f9f9b3116a01f70a89d6ea29cc4f6dc3cd0
5d75bc0bd212534d44f78e5a287abf3f909a2e8e
refs/heads/master
2023-06-01T08:20:39.601418
2022-10-31T12:43:24
2022-10-31T12:43:24
150,118,529
4
1
BSD-3-Clause
2023-05-01T21:19:53
2018-09-24T14:46:15
Java
UTF-8
Java
false
false
2,505
java
/*================================================================================ Copyright (c) 2013 Steve Jin. All Rights Reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of VMware, Inc. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ================================================================================*/ package com.vmware.vim25; import java.util.Calendar; /** * @author Steve Jin (http://www.doublecloud.org) * @version 5.1 */ @SuppressWarnings("all") public class AnswerFile extends DynamicData { public ProfileDeferredPolicyOptionParameter[] userInput; public Calendar createdTime; public Calendar modifiedTime; public ProfileDeferredPolicyOptionParameter[] getUserInput() { return this.userInput; } public Calendar getCreatedTime() { return this.createdTime; } public Calendar getModifiedTime() { return this.modifiedTime; } public void setUserInput(ProfileDeferredPolicyOptionParameter[] userInput) { this.userInput=userInput; } public void setCreatedTime(Calendar createdTime) { this.createdTime=createdTime; } public void setModifiedTime(Calendar modifiedTime) { this.modifiedTime=modifiedTime; } }
[ "stefan.dilk@freenet.ag" ]
stefan.dilk@freenet.ag
367a61843a9a0289f96893b816cdbbfdaf794458
492ab60eaa5619551af16c79c569bdb704b4d231
/src/net/sourceforge/plantuml/code/Transcoder.java
6c33d27d72d1fcb65d4c2b7bd3cd73caa5042e1c
[]
no_license
ddcjackm/plantuml
36b89d07401993f6cbb109c955db4ab10a47ac78
4638f93975a0af9374cec8200d16e1fa180dafc2
refs/heads/master
2021-01-12T22:34:56.588483
2016-07-25T19:25:28
2016-07-25T19:25:28
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,447
java
/* ======================================================================== * PlantUML : a free UML diagram generator * ======================================================================== * * (C) Copyright 2009-2017, Arnaud Roques * * Project Info: http://plantuml.com * * This file is part of PlantUML. * * PlantUML is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * PlantUML distributed in the hope that it will be useful, but * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public * License for more details. * * You should have received a copy of the GNU General Public * License along with this library; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, * USA. * * [Java is a trademark or registered trademark of Sun Microsystems, Inc. * in the United States and other countries.] * * Original Author: Arnaud Roques * * Revision $Revision: 19109 $ * */ package net.sourceforge.plantuml.code; import java.io.IOException; public interface Transcoder { public String encode(String text) throws IOException; public String decode(String code) throws IOException; }
[ "plantuml@gmail.com" ]
plantuml@gmail.com
a7571131213410b4fd87e29b3f196842e6ec1951
50b56568d6d31140464ce645228ade7fa08f5c22
/src/test/java/org/wildfly/util/xml/to/cli/subsystem/SimpleSubsystemRemove.java
1088f2cf5de2edb39b1234e10d30f09a6c92d922
[]
no_license
kabir/wildfly-xml-to-cli
916b67e66fa1470fd647e38e42274f87a3c5ede5
a228f950027234203dcc9412d1be1d4f412a9e01
refs/heads/master
2022-09-28T15:32:45.690412
2019-07-22T19:47:11
2019-07-23T07:14:01
197,612,383
0
0
null
2022-09-02T21:15:24
2019-07-18T15:23:28
Java
UTF-8
Java
false
false
896
java
package org.wildfly.util.xml.to.cli.subsystem; import org.jboss.as.controller.AbstractRemoveStepHandler; import org.jboss.as.controller.OperationContext; import org.jboss.as.controller.OperationFailedException; import org.jboss.dmr.ModelNode; import org.jboss.logging.Logger; /** * Handler responsible for adding the subsystem resource to the model * * @author <a href="kabir.khan@jboss.com">Kabir Khan</a> */ class SimpleSubsystemRemove extends AbstractRemoveStepHandler { static final SimpleSubsystemRemove INSTANCE = new SimpleSubsystemRemove(); private final Logger log = Logger.getLogger(SimpleSubsystemRemove.class); private SimpleSubsystemRemove() { } @Override protected void performRuntime(OperationContext context, ModelNode operation, ModelNode model) throws OperationFailedException { super.performRuntime(context, operation, model); } }
[ "kkhan@redhat.com" ]
kkhan@redhat.com
9eac49d28572d7e0628115a7169715234e8e1359
cf5116f8c02250b392b5c0172f600aa044662986
/management/src/main/java/com/babeeta/butterfly/application/management/dao/impl/StatDaoImpl.java
6b20493c392a95cbe75d5bd0fe3385f30d073620
[]
no_license
jfatty/application-1.5.22
69ecfb828cbb1682451385d50c82d6305c1cbe15
e7553193ba455cfeb099a49dd74f62a887a3f5ed
refs/heads/master
2021-05-31T11:03:17.044608
2016-04-01T06:22:43
2016-04-01T06:22:43
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,666
java
package com.babeeta.butterfly.application.management.dao.impl; import java.text.SimpleDateFormat; import java.util.ArrayList; import java.util.Iterator; import java.util.LinkedHashMap; import java.util.List; import java.util.Map; import com.babeeta.butterfly.application.management.dao.StatDao; import com.mongodb.BasicDBObject; import com.mongodb.DBCollection; import com.mongodb.DBCursor; import com.mongodb.DBObject; import com.mongodb.Mongo; public class StatDaoImpl implements StatDao { private DBCollection statCollection; private static final SimpleDateFormat SDF=new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); public StatDaoImpl(Mongo mongo) { statCollection = mongo.getDB("stat").getCollection("stat"); } public void ensureIndex() { BasicDBObject indexOptions = new BasicDBObject().append("background", true).append("unique", true); statCollection.ensureIndex(new BasicDBObject().append("rate", 1) .append("createTime", -1), indexOptions); } @Override public List<Map> getStats(String rate, int limit) { DBCursor cursor=statCollection.find(new BasicDBObject().append("rate", rate)).sort( new BasicDBObject().append("createTime", -1)).limit(limit); List<Map> list=new ArrayList<Map>(); while(cursor.hasNext()){ DBObject obj=cursor.next(); Iterator<String> keyIt=obj.keySet().iterator(); Map map=new LinkedHashMap(); while(keyIt.hasNext()){ String key=keyIt.next(); if(key.equals("createTime")){ map.put(key, SDF.format(obj.get(key))); }else if(key.equals("_id")){ continue; }else{ map.put(key, obj.get(key)); } } list.add(map); } return list; } }
[ "zhaominhe@gmail.com" ]
zhaominhe@gmail.com
80a53c45964b03d72ed452f9d68fc884037b2b8d
5f2fb08c46b2acdfe52583cf95925325b36c6820
/jcvideoplayer-lib/src/main/java/fm/jiecao/jcvideoplayer_lib/MessageEvent.java
ffdabe546aaeafcf1b5461b2a743f366b3fabfc3
[]
no_license
309925753/xinfuyouyue
7324fb7062c126156ee350a0e14b8b18bed7afe6
0bc8f8bb387d2203b74af05bfcc6733cde51cda2
refs/heads/master
2022-11-30T23:46:53.082249
2020-05-19T11:48:55
2020-05-19T11:48:55
287,436,362
3
6
null
null
null
null
UTF-8
Java
false
false
624
java
package fm.jiecao.jcvideoplayer_lib; /** * Created by Administrator on 2017/3/17 0017. * 1. 视频播放控件 已准备,通知朋友圈页面停止播放录音,防止同时播放两种声音 * 2. 我的同事 其他页面调用api成功,通知同事页面刷新UI * 3. 消息群发 收到回执后,通知群发页面,当群发页面收到所有人回执时,在隐藏等待符 * 4. 视频播放完成,通知单聊界面,判断是否为阅后即焚视频 */ public class MessageEvent { public final String message; public MessageEvent(String message) { this.message = message; } }
[ "309925753@qq.com" ]
309925753@qq.com
2e7a70bca4dbc8b7eee405117b5e6e9b41bff18a
e0e2b50412bdc5742af17607688df722f2359891
/7.2/misc/ImageVisualizer/ImageEditor/src/org/netbeans/modules/image/ZoomOutAction.java
cf659d0c8298709f3af6117c78115071e6903870
[]
no_license
redporrot/nbp-resources
faf4b4662779d038bc8770d3cea38b4f1653d70c
ef8a41ae6ab18dd1cd1460fa99a52757bf98916b
refs/heads/master
2020-04-01T17:24:22.481434
2015-06-12T21:37:01
2015-06-12T21:37:01
null
0
0
null
null
null
null
UTF-8
Java
false
false
3,605
java
/* * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. * * Copyright 1997-2010 Oracle and/or its affiliates. All rights reserved. * * Oracle and Java are registered trademarks of Oracle and/or its affiliates. * Other names may be trademarks of their respective owners. * * The contents of this file are subject to the terms of either the GNU * General Public License Version 2 only ("GPL") or the Common * Development and Distribution License("CDDL") (collectively, the * "License"). You may not use this file except in compliance with the * License. You can obtain a copy of the License at * http://www.netbeans.org/cddl-gplv2.html * or nbbuild/licenses/CDDL-GPL-2-CP. See the License for the * specific language governing permissions and limitations under the * License. When distributing the software, include this License Header * Notice in each file and include the License file at * nbbuild/licenses/CDDL-GPL-2-CP. Oracle designates this * particular file as subject to the "Classpath" exception as provided * by Oracle in the GPL Version 2 section of the License file that * accompanied this code. If applicable, add the following below the * License Header, with the fields enclosed by brackets [] replaced by * your own identifying information: * "Portions Copyrighted [year] [name of copyright owner]" * * Contributor(s): * * The Original Software is NetBeans. The Initial Developer of the Original * Software is Sun Microsystems, Inc. Portions Copyright 1997-2006 Sun * Microsystems, Inc. All Rights Reserved. * * If you wish your version of this file to be governed by only the CDDL * or only the GPL Version 2, indicate your decision by adding * "[Contributor] elects to include this software in this distribution * under the [CDDL or GPL Version 2] license." If you do not indicate a * single choice of license, a recipient has the option to distribute * your version of this file under either the CDDL, the GPL Version 2 or * to extend the choice of license to its licensees as provided above. * However, if you add GPL Version 2 code and therefore, elected the GPL * Version 2 license, then the option applies only if the new code is * made subject to such option by the copyright holder. */ package org.netbeans.modules.image; import org.openide.util.actions.CallableSystemAction; import org.openide.util.HelpCtx; import org.openide.windows.TopComponent; import org.openide.util.NbBundle; /** * Action which zooms out of an image. * * @author Lukas Tadial */ public class ZoomOutAction extends CallableSystemAction { /** Generated serial version UID. */ static final long serialVersionUID = 1859897546585041051L; /** Peforms action. */ public void performAction() { TopComponent curComponent = TopComponent.getRegistry().getActivated(); if(curComponent instanceof ImageViewer) ((ImageViewer) curComponent).zoomOut(); } /** Gets name of action. Implements superclass abstract method. */ public String getName() { return NbBundle.getBundle(ZoomOutAction.class).getString("LBL_ZoomOut"); } /** Gets help context for action. Implements superclass abstract method. */ public org.openide.util.HelpCtx getHelpCtx() { return HelpCtx.DEFAULT_HELP; } /** Overrides superclass method. */ public boolean isEnabled() { return true; } /** Gets icon resource. Overrides superclass method. */ protected String iconResource() { return "org/netbeans/modules/image/zoomOut.gif"; // NOI18N } }
[ "doriancuentas@gmail.com" ]
doriancuentas@gmail.com
708f69480d4ee27a282271da4de3fa6b58d603aa
5b9a04d3c911c16aba63258d48606d6ea364a6da
/distribution_sales/modules/sales/app/entity/sales/Sequence.java
4584899983b892638dee091ff3a0064deed1f407
[ "Apache-2.0" ]
permissive
yourant/repository1
40fa5ce602bbcad4e6f61ad6eb1330cfe966f780
9ab74a2dfecc3ce60a55225e39597e533975a465
refs/heads/master
2021-12-15T04:22:23.009473
2017-07-28T06:06:35
2017-07-28T06:06:35
null
0
0
null
null
null
null
UTF-8
Java
false
false
939
java
package entity.sales; public class Sequence { private Integer id; private String seqName; private Long currentValue; private Integer increment; private String remark; public Integer getId() { return id; } public void setId(Integer id) { this.id = id; } public String getSeqName() { return seqName; } public void setSeqName(String seqName) { this.seqName = seqName; } public Long getCurrentValue() { return currentValue; } public void setCurrentValue(Long currentValue) { this.currentValue = currentValue; } public Integer getIncrement() { return increment; } public void setIncrement(Integer increment) { this.increment = increment; } public String getRemark() { return remark; } public void setRemark(String remark) { this.remark = remark; } }
[ "3002781863@qq.com" ]
3002781863@qq.com