blob_id
stringlengths
40
40
directory_id
stringlengths
40
40
path
stringlengths
4
410
content_id
stringlengths
40
40
detected_licenses
listlengths
0
51
license_type
stringclasses
2 values
repo_name
stringlengths
5
132
snapshot_id
stringlengths
40
40
revision_id
stringlengths
40
40
branch_name
stringlengths
4
80
visit_date
timestamp[us]
revision_date
timestamp[us]
committer_date
timestamp[us]
github_id
int64
5.85k
689M
star_events_count
int64
0
209k
fork_events_count
int64
0
110k
gha_license_id
stringclasses
22 values
gha_event_created_at
timestamp[us]
gha_created_at
timestamp[us]
gha_language
stringclasses
131 values
src_encoding
stringclasses
34 values
language
stringclasses
1 value
is_vendor
bool
1 class
is_generated
bool
2 classes
length_bytes
int64
3
9.45M
extension
stringclasses
32 values
content
stringlengths
3
9.45M
authors
listlengths
1
1
author_id
stringlengths
0
313
0e66f210a915db1747d0870acf655da6d51cbab9
96724d25618b6f8b6adf2de9acc750c4ce94cdee
/unittest-example-master/mock-test-example/src/test/java/example/powermock/demo/staticvariable/StaticDemoTest.java
92020d6a75be5c084a865d86119d03db9c8bf41d
[]
no_license
dnf666/allkindunittest
734a563c5ce28194198e50df807b81607d24b308
69e25408f0c0e178d97605f26159baf7a78a328c
refs/heads/master
2020-03-17T13:15:23.698855
2018-05-16T06:58:52
2018-05-16T06:58:52
133,623,003
0
0
null
null
null
null
UTF-8
Java
false
false
1,474
java
package example.powermock.demo.staticvariable; import example.pojo.Student; import org.junit.Assert; import org.junit.Before; import org.junit.Test; import org.junit.runner.RunWith; import org.mockito.Mockito; import org.powermock.api.mockito.PowerMockito; import org.powermock.core.classloader.annotations.PrepareForTest; import org.powermock.core.classloader.annotations.SuppressStaticInitializationFor; import org.powermock.modules.junit4.PowerMockRunner; import org.powermock.reflect.Whitebox; import org.slf4j.Logger; import java.lang.reflect.Field; //http://stackoverflow.com/questions/5385161/powermock-testing-set-static-field-of-class @RunWith(PowerMockRunner.class) @PrepareForTest(StaticDemo.class) public class StaticDemoTest { @Before public void setUp () { } @Test public void test() throws Exception{ StaticDemo staticDemo = new StaticDemo(); String id = "002mock"; Whitebox.setInternalState(StaticDemo.class, "id",id); Assert.assertEquals(StaticDemo.getId(),id); int stuId = 2; Student student = new Student(stuId); Whitebox.setInternalState(StaticDemo.class, "student",student); Assert.assertEquals(StaticDemo.getStudentId(),2); Field field = PowerMockito.field(StaticDemo.class, "student"); field.set(StaticDemo.class, Mockito.mock(Student.class)); Assert.assertEquals(StaticDemo.getStudentId(),0); System.out.print(""); } }
[ "1204695257@qq.com" ]
1204695257@qq.com
4865d0da5195e250714ed57499244439bce74a32
b21880cdf254c56d4318c8e273b33b71523243a7
/Peer.to.Peer/src/MesDocuments.java
741b39a8a6ad649731e2af6b6662e83397a3c2f0
[]
no_license
papembayegaye/Projet-R-Guide-and-Peer-to-Peer
a009e4da3817a8ba5397ce59f086989f0adfec10
cbdf91f56a3dee0aa61a8ec46499fe3bbd829574
refs/heads/master
2020-03-27T14:28:55.964556
2018-10-10T13:42:06
2018-10-10T13:42:06
146,664,945
0
0
null
null
null
null
UTF-8
Java
false
false
1,357
java
import javax.swing.JButton; import javax.swing.JLabel; import javax.swing.JMenu; import javax.swing.JMenuBar; import javax.swing.JMenuItem; import javax.swing.JPanel; import javax.swing.JProgressBar; import javax.swing.JScrollPane; import javax.swing.JSeparator; import javax.swing.JTable; import javax.swing.JTextArea; import javax.swing.JTextField; import javax.swing.JTextPane; import javax.swing.table.DefaultTableModel; import java.awt.event.*; import java.io.File; import java.io.IOException; import java.io.RandomAccessFile; /** * * @author hp */ public class MesDocuments extends javax.swing.JFrame{ private String nom = null; //nom du document private String proprietaire = null; //identifiant du pair possedant le document /** * Constructeur de la classe MesDocuments */ public MesDocuments(String n,String pid) { nom = n; proprietaire = pid; } /** * Retourne le nom du document */ public String getNom() { return nom; } /** * Retourne l'identifiant du proprietaire du document */ public String getProprietaire() { return proprietaire; } public static void main(String[] var0) { /* java.awt.EventQueue.invokeLater(new Runnable() { public void run() { new PeertoPeer().setVisible(true); } });*/ } }
[ "yayakane1996@gmail.com" ]
yayakane1996@gmail.com
7d37dfe9d4a93e7dc02dc434fa1a8a19b5fa917f
8b705e968e4b7affc35ff506559d6a88851aad6b
/Sandbox/src/graph/GraphMax.java
ab4caa51bf7ee8b4be7d37d08a9b4ab8369f85bd
[]
no_license
ionkov/Sandbox
bf082f7f540f2da252ab7ed7ff0aff5a0f9a6f50
c226cb1ecefe38e3e17e2ec8ce918238dae7e7e3
refs/heads/master
2021-01-17T05:34:05.566568
2014-10-24T06:42:24
2014-10-24T06:42:24
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,403
java
package graph; import java.util.Random; public class GraphMax { private Node root; public GraphMax(int numNodes) { if (numNodes <= 0) { numNodes = 5; } Random r = new Random(); while (--numNodes >= 0) { Node n = new Node(r.nextInt(20)); if (root == null) { root = n; continue; } Node n2 = root; while (n2 != null) { if (r.nextBoolean()) { if (n2.getL() == null) { n2.setL(n); break; } n2 = n2.getL(); } else { if (n2.getR() == null) { n2.setR(n); break; } else { n2 = n2.getR(); } } } } } public int findMaxTraversal() { if (root == null) { return Integer.MIN_VALUE; } return findMaxTraversalR(root, 0); } /* * (non-Javadoc) * * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); dfTraversal(root, null, sb); return sb.toString(); } /** * @param root2 * @return */ private void dfTraversal(Node r, Node p, StringBuilder sb) { if (r == null) { return; } sb.append(r + " (" + p + ") "); dfTraversal(r.getL(), r, sb); dfTraversal(r.getR(), r, sb); } /** * @param r * @param i * @return */ private int findMaxTraversalR(Node r, int s) { if (r.isLeaf()) { return s + r.getD(); } if (r.getL() == null) { return findMaxTraversalR(r.getR(), s + r.getD()); } if (r.getR() == null) { return findMaxTraversalR(r.getL(), s + r.getD()); } return Math.max(findMaxTraversalR(r.getL(), s + r.getD()), findMaxTraversalR(r.getR(), s + r.getD())); } public class Node { private int d; private Node l; private Node r; public Node(int d) { this.d = d; l = null; r = null; } /** * @param l * the l to set */ public void setL(Node l) { this.l = l; } /** * @param r * the r to set */ public void setR(Node r) { this.r = r; } /** * @return the d */ public int getD() { return d; } /** * @return the l */ public Node getL() { return l; } /** * @return the r */ public Node getR() { return r; } public boolean isLeaf() { return (l == null && r == null); } /* * (non-Javadoc) * * @see java.lang.Object#toString() */ @Override public String toString() { return Integer.toString(d); } } }
[ "ionkov@gmail.com" ]
ionkov@gmail.com
032cf0862d663be8641a0ad0f2237c5491398d9f
a30a8035ef3332d8b3f7c97ef0c71494739746d1
/src/transaction/read/FetchNewsTransaction.java
b952da5862ca13663a1a4116da37f83ed83b4f6c
[]
no_license
BondWong/DLTranslate
105c982bcd77a48842e2a5644eaeac2d88046d10
5ecf803a2a963f3b3005634df383f0da91386010
refs/heads/master
2021-05-29T13:00:50.984275
2015-08-25T07:23:16
2015-08-25T07:23:16
null
0
0
null
null
null
null
UTF-8
Java
false
false
710
java
package transaction.read; import java.util.ArrayList; import java.util.List; import java.util.Map; import model.News; import persistence.DAO; import transaction.DAOTransaction; public class FetchNewsTransaction extends DAOTransaction { @SuppressWarnings("rawtypes") @Override protected Object process(DAO dao, Map param) throws Exception { // TODO Auto-generated method stub int startIndex = (int) param.get("startIndex"); int pageSize = (int) param.get("pageSize"); List<News> news = dao.objectsRead("News.fetch", startIndex, pageSize, News.class); List<Map<String, Object>> results = new ArrayList<>(); for (News n : news) results.add(n.toRepresentation()); return results; } }
[ "WongZeonbong@gmail.com" ]
WongZeonbong@gmail.com
2f1baa2e02b2d3bc8b602acaebd514248651455e
55bb2341a2014aba4306c7788a9d299bb84ffa08
/tasks-server/src/main/java/tasks/services/Service.java
b96ab3cca774d0110dc0c23e7a23ddb8fd1cf5ae
[]
no_license
harfangeek/api-tasks-java-ee
4ac59b3e16b50938d0eea4f5f7565ea2eeb9b6ce
0f5d3bbf4ef7de24cfffe456b829db48d5e8f350
refs/heads/master
2021-01-19T00:07:12.138827
2016-06-11T11:33:21
2016-06-11T11:33:21
51,367,997
0
0
null
null
null
null
UTF-8
Java
false
false
3,029
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 tasks.services; import java.io.IOException; import java.util.HashMap; import java.util.List; import java.util.Map; import javax.servlet.http.HttpServletResponse; import javax.ws.rs.Consumes; import javax.ws.rs.DELETE; import javax.ws.rs.FormParam; import javax.ws.rs.GET; import javax.ws.rs.POST; import javax.ws.rs.PUT; import javax.ws.rs.Path; import javax.ws.rs.PathParam; import javax.ws.rs.Produces; import javax.ws.rs.core.Context; import javax.ws.rs.core.MediaType; import tasks.Task; import tasks.util.DBManager; /** * * @author user */ @Path("service") public class Service { private static Map<Integer, Task> tasks = new HashMap<>(); private static final String SUCCESS_RESULT="<result>success</result>"; private static final String FAILURE_RESULT="<result>failure</result>"; static{ for (int i = 0; i < 10; i++) { int id = i+1; Task task = new Task(); task.setId(id); task.setTitle("Title"+id); task.setDescription("Description"+id); tasks.put(id, task); } } private DBManager manager = new DBManager(); @GET @Path("/getTaskByIdJSON/{id}") @Produces(MediaType.APPLICATION_JSON) public Task getTaskByIdJSON(@PathParam("id")int id){ return manager.getTaskById(id); } @GET @Path("/getAllTasksXML") @Produces(MediaType.APPLICATION_XML) public List<Task> getAllTasksXML(){ return manager.getAllTasks(); } @GET @Path("/getAllTasksJSON") @Produces(MediaType.APPLICATION_JSON) public List<Task> getAllTasksJSON(){ return manager.getAllTasks(); } @DELETE @Path("/deleteTask/{taskid}") @Produces(MediaType.APPLICATION_JSON) public String deleteUser(@PathParam("taskid") int taskid){ int result = manager.deleteTask(taskid); if(result == 1){ return SUCCESS_RESULT; } return FAILURE_RESULT; } @PUT @Path("/createTask") @Produces(MediaType.APPLICATION_JSON) public String createTask(@FormParam("title") String title, @FormParam("description") String description) { Task task = new Task(title, description); int result = manager.insertTask(task); if(result == 1){ return SUCCESS_RESULT; } return FAILURE_RESULT; } @PUT @Path("/updateTask") @Produces(MediaType.APPLICATION_JSON) public String updateTask(@FormParam("id") int id, @FormParam("title") String title, @FormParam("description") String description) { Task task = new Task(id, title, description); int result = manager.updateTask(task); System.out.print("UPDATE DATA"); if(result == 1){ return SUCCESS_RESULT; } return FAILURE_RESULT; } }
[ "vinh.lu-minh@edu.esiee.fr" ]
vinh.lu-minh@edu.esiee.fr
72b1b58d2300273287ebe0b2f7181a528c3fe5c4
1e972b573f87574c43c88c170f692210664aa884
/SORT/SortArrayList.java
9e25a52b0d2e8008b9ab1af62be55fe0bb052a37
[]
no_license
tina0711/TCT_JAVA
05d0b7488ff80b457b3bc9652fd65992921f85f4
5d0f765d4b59a73d32f8de7bea4a30d48fbdb353
refs/heads/master
2023-07-24T23:05:56.016933
2023-07-16T12:53:48
2023-07-16T12:53:48
172,868,978
0
0
null
null
null
null
UTF-8
Java
false
false
2,637
java
package com.lgcns.tct.sortArrayList; import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; import java.util.Comparator; class Employee { private String name; private String department; private int age; private int height; public Employee(String name, String department, int age, int height) { this.name = name; this.department = department; this.age = age; this.height = height; } public String getName() { return name; } public void setName(String name) { this.name = name; } public String getDepartment() { return department; } public void setDepartment(String department) { this.department = department; } public int getAge() { return age; } public void setAge(int age) { this.age = age; } public int getHeight() { return height; } public void setHeight(int height) { this.height = height; } } public class SortArrayList { ArrayList<Employee> arrList = new ArrayList<Employee>(); public static void main(String[] args) { // TODO Auto-generated method stub SortArrayList sorter = new SortArrayList(); sorter.loadData(); System.out.println("원본 데이터======================="); sorter.printList(); sorter.listSort(); System.out.println("ArrayList Sort 오름차순======================="); sorter.printList(); } void loadData() { Employee emp1 = new Employee("KIM", "FI", 23, 165); Employee emp2 = new Employee("LEE", "HR", 23, 160); Employee emp3 = new Employee("CHOI", "IT", 30, 180); Employee emp4 = new Employee("SSO", "IT", 30, 165); Employee emp5 = new Employee("LIM", "FI", 35, 185); arrList.add(emp1); arrList.add(emp2); arrList.add(emp3); arrList.add(emp4); arrList.add(emp5); } // 오름차순 void listSort() { Collections.sort(arrList, new Comparator<Employee>() { @Override public int compare(Employee p1, Employee p2) { // TODO Auto-generated method stub if(p1.getAge() > p2.getAge()) { return 1; } else if(p1.getAge() < p2.getAge()) { return -1; } else { if(p1.getHeight() > p2.getHeight()) { return 1; } else if(p1.getHeight() < p2.getHeight()) { return -1; } else { return 0; } } } }); } void printList() { for(int i =0; i<arrList.size(); i++) { System.out.println(arrList.get(i).getName()+"\t"+ arrList.get(i).getDepartment()+"\t"+ arrList.get(i).getAge()+"\t"+arrList.get(i).getHeight() ); } } }
[ "noreply@github.com" ]
tina0711.noreply@github.com
68d82ef113a003fb7e645c8054d93b136b444a30
006cc98b66c66e9f5b88a795ae244d9afb1f29a3
/out/src/main/java/com/zhr/out/ServletInitializer.java
f378b6775c3aa6eb38be77d97ebf598b1fe9416b
[]
no_license
ZHR-BLACK/parent-zhr
b7cd56f20c489c536bf4960b0fe79d6a1bf73d65
b0baf39e1db2ad5d887e43b894ae0beded0d696f
refs/heads/master
2023-07-07T00:30:40.750706
2023-07-04T01:45:22
2023-07-04T01:45:22
188,189,033
0
1
null
2023-06-27T02:06:20
2019-05-23T08:02:13
HTML
UTF-8
Java
false
false
962
java
package com.zhr.out; import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration; import org.springframework.boot.autoconfigure.jdbc.DataSourceTransactionManagerAutoConfiguration; import org.springframework.boot.builder.SpringApplicationBuilder; import org.springframework.boot.web.servlet.support.SpringBootServletInitializer; /** * @author ZHR * @version 1.0 * @ClassName ReceiveController * @Date 2020-03-04 16:26 * @description SpringBoot 在tomcat中部署时启动类需要做的配置 **/ @SpringBootApplication(exclude = {DataSourceAutoConfiguration.class, DataSourceTransactionManagerAutoConfiguration.class}) public class ServletInitializer extends SpringBootServletInitializer { @Override protected SpringApplicationBuilder configure(SpringApplicationBuilder application) { return application.sources(ServletInitializer.class); } }
[ "zhr@LAPTOP-ZHR" ]
zhr@LAPTOP-ZHR
f21e655d244d71c2f5d4c9762aab2e861c60ed50
fe67f4723295118c643c5d6e202e2d4206a9585f
/src/main/java/com/projeto/spring/controller/PessoaController.java
d9a86fa301e7875a41c418050a8414e8da119c61
[]
no_license
felipe-figueira/cadastro-spring-thymeleaf
035e82f445893b53f0723a4b4e5f647c0e14c28f
0dba848818359ecb11e3de69ab7f52e7579b7353
refs/heads/master
2023-08-11T15:51:51.462449
2020-03-24T04:00:52
2020-03-24T04:00:52
248,281,006
0
0
null
2023-07-23T09:06:12
2020-03-18T16:12:37
HTML
UTF-8
Java
false
false
4,125
java
package com.projeto.spring.controller; import java.util.Optional; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMethod; import org.springframework.web.bind.annotation.RequestParam; import org.springframework.web.servlet.ModelAndView; import com.projeto.spring.model.Pessoa; import com.projeto.spring.model.Telefone; import com.projeto.spring.repository.PessoaRepository; import com.projeto.spring.repository.TelefoneRepository; @Controller public class PessoaController { @Autowired private PessoaRepository pessoaRepository; @Autowired private TelefoneRepository telefoneRepository; @RequestMapping(method = RequestMethod.GET, value="/cadastropessoa") public ModelAndView inicio() { ModelAndView modelAndView = new ModelAndView("cadastro/cadastropessoa"); modelAndView.addObject("pessoaobj", new Pessoa()); Iterable<Pessoa> pessoasIt = pessoaRepository.findAll(); modelAndView.addObject("pessoas", pessoasIt); return modelAndView; } @RequestMapping(method = RequestMethod.POST, value="**/salvarpessoa") public ModelAndView salvar(Pessoa pessoa) { pessoaRepository.save(pessoa); ModelAndView andView = new ModelAndView("cadastro/cadastropessoa"); Iterable<Pessoa> pessoasIt = pessoaRepository.findAll(); andView.addObject("pessoas", pessoasIt); andView.addObject("pessoaobj", new Pessoa()); return andView; } @RequestMapping(method = RequestMethod.GET, value="/listapessoas") public ModelAndView pessoas() { ModelAndView andView = new ModelAndView("cadastro/cadastropessoa"); Iterable<Pessoa> pessoasIt = pessoaRepository.findAll(); andView.addObject("pessoas", pessoasIt); andView.addObject("pessoaobj", new Pessoa()); return andView; } @GetMapping("/editarpessoa/{idpessoa}") //igual a anotação acima public ModelAndView editar(@PathVariable("idpessoa") Long idpessoa) { Optional<Pessoa> pessoa = pessoaRepository.findById(idpessoa); ModelAndView modelAndView = new ModelAndView("cadastro/cadastropessoa"); modelAndView.addObject("pessoaobj", pessoa.get()); return modelAndView; } @GetMapping("/removerpessoa/{idpessoa}") //igual a anotação acima public ModelAndView excluir(@PathVariable("idpessoa") Long idpessoa) { pessoaRepository.deleteById(idpessoa); ModelAndView modelAndView = new ModelAndView("cadastro/cadastropessoa"); modelAndView.addObject("pessoas", pessoaRepository.findAll()); modelAndView.addObject("pessoaobj", new Pessoa()); return modelAndView; } @PostMapping("**/pesquisarpessoa") public ModelAndView pesquisar(@RequestParam("nomepesquisa") String nomepesquisa) { ModelAndView modelAndView = new ModelAndView("cadastro/cadastropessoa"); modelAndView.addObject("pessoas", pessoaRepository.findPessoaByName(nomepesquisa)); modelAndView.addObject("pessoaobj", new Pessoa()); return modelAndView; } @GetMapping("/telefones/{idpessoa}") public ModelAndView telefones(@PathVariable("idpessoa") Long idpessoa) { Optional<Pessoa> pessoa = pessoaRepository.findById(idpessoa); ModelAndView modelAndView = new ModelAndView("cadastro/telefones"); modelAndView.addObject("pessoaobj", pessoa.get()); modelAndView.addObject("telefones", telefoneRepository.getTelefones(idpessoa)); return modelAndView; } @PostMapping("**/addfonePessoa/{pessoaid}") public ModelAndView addfonePessoa(Telefone telefone, @PathVariable("pessoaid") Long pessoaid ) { Pessoa pessoa = pessoaRepository.findById(pessoaid).get(); telefone.setPessoa(pessoa); telefoneRepository.save(telefone); ModelAndView modelAndView = new ModelAndView("cadastro/telefones"); modelAndView.addObject("pessoaobj", pessoa); modelAndView.addObject("telefones", telefoneRepository.getTelefones(pessoaid)); return modelAndView; } }
[ "felipe.figueira13@gmail.com" ]
felipe.figueira13@gmail.com
b069845457451eab87601b5cb99b9d2bcea5655a
87ca1b89a4c892a42c7b9f3a61fbed6e54c48362
/one-java-agent-plugin/src/main/java/com/alibaba/oneagent/service/ComponentManager.java
9ca5b0bccce9686fefc603d687360f6953a8f5e1
[ "Apache-2.0" ]
permissive
shensi199312/one-java-agent
ab77c95720de71ef7d40eeb2e1bcdd0a54fe88a7
cdfaa5f70b2192fdda129e5b364f99d85de57ef6
refs/heads/master
2023-03-07T07:16:48.628524
2021-02-20T09:39:01
2021-02-20T09:39:01
null
0
0
null
null
null
null
UTF-8
Java
false
false
280
java
package com.alibaba.oneagent.service; /** * * @author hengyunabc 2020-12-17 * */ public interface ComponentManager { public <T> T getComponent(Class<T> clazz); public void initComponents(); public void startComponents(); public void stopComponents(); }
[ "hengyunabc@gmail.com" ]
hengyunabc@gmail.com
f75ca3ac0c90d0f7543e68207d3f1ce3e2eaf345
348dd69d5e4b40a42f98a2d5b21ac396abbb16e9
/src/main/java/com/taskmanager/viewmodels/users/UserListVM.java
5d9a092002df215eaaf1afd6f5a1adb3693afb44
[]
no_license
dona1312/TaskManagerJavaSpring
ff0e9e4471bb13df6e5feac4844bf8212f3a903c
8b619ad43bfea7701299f011e20b291c3e09ece4
refs/heads/master
2021-01-20T20:52:45.311133
2016-06-21T13:52:26
2016-06-21T13:52:26
61,543,711
0
0
null
null
null
null
UTF-8
Java
false
false
346
java
package com.taskmanager.viewmodels.users; import com.taskmanager.entity.User; import java.util.List; /** * Created by dona on 16.06.16. */ public class UserListVM { public List<User> users; public List<User> getUsers(){ return this.users; } public void setUsers(List<User> users){ this.users=users; } }
[ "donav048@gmail.com" ]
donav048@gmail.com
52acb9dd41a0ac1dad5bdbe36e51a637b14a355d
dbf5adca095d04d7d069ecaa916e883bc1e5c73d
/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/form/ExcuteListByApp.java
5a6eee63240d7ae0a7605fa1c4e1ab593dfd4b1c
[ "BSD-3-Clause" ]
permissive
fancylou/o2oa
713529a9d383de5d322d1b99073453dac79a9353
e7ec39fc586fab3d38b62415ed06448e6a9d6e26
refs/heads/master
2020-03-25T00:07:41.775230
2018-08-02T01:40:40
2018-08-02T01:40:40
143,169,936
0
0
BSD-3-Clause
2018-08-01T14:49:45
2018-08-01T14:49:44
null
UTF-8
Java
false
false
2,207
java
package com.x.cms.assemble.control.jaxrs.form; import java.util.List; import javax.servlet.http.HttpServletRequest; import com.x.base.core.cache.ApplicationCache; import com.x.base.core.container.EntityManagerContainer; import com.x.base.core.container.factory.EntityManagerContainerFactory; import com.x.base.core.http.ActionResult; import com.x.base.core.http.EffectivePerson; import com.x.base.core.utils.SortTools; import com.x.cms.assemble.control.Business; import com.x.cms.assemble.control.WrapTools; import com.x.cms.assemble.control.factory.FormFactory; import com.x.cms.core.entity.element.Form; import net.sf.ehcache.Element; public class ExcuteListByApp extends ExcuteBase { @SuppressWarnings("unchecked") protected ActionResult<List<WrapOutSimpleForm>> execute( HttpServletRequest request, EffectivePerson effectivePerson, String appId ) throws Exception { ActionResult<List<WrapOutSimpleForm>> result = new ActionResult<>(); List<WrapOutSimpleForm> wraps = null; String cacheKey = ApplicationCache.concreteCacheKey( "appId", appId ); Element element = cache.get(cacheKey); if ((null != element) && ( null != element.getObjectValue()) ) { wraps = (List<WrapOutSimpleForm>) element.getObjectValue(); result.setData(wraps); } else { try (EntityManagerContainer emc = EntityManagerContainerFactory.instance().create()) { Business business = new Business(emc); if (!business.formEditAvailable( request, effectivePerson )) { throw new Exception("person{name:" + effectivePerson.getName() + "} 用户没有查询全部表单模板的权限!"); } FormFactory formFactory = business.getFormFactory(); List<String> ids = formFactory.listByAppId(appId);// 获取指定应用的所有表单模板列表 List<Form> formList = formFactory.list(ids); wraps = WrapTools.formsimple_wrapout_copier.copy(formList);// 将所有查询出来的有状态的对象转换为可以输出的过滤过属性的对象 SortTools.desc( wraps, "createTime" ); cache.put(new Element( cacheKey, wraps )); result.setData(wraps); } catch (Throwable th) { th.printStackTrace(); result.error(th); } } return result; } }
[ "caixiangyi2004@126.com" ]
caixiangyi2004@126.com
5bd9d3c4ae940a11a4cb229e8c60dcf3dd7084c1
6354ba2bcc14273ce2004e6b625c0deac2c344bd
/src/EDocP9.java
4f2346b5466b4e4c994e2be182e72d39bd8c8f44
[]
no_license
AndrewKnife/Repositorius
4dfd7a94e30909893830e75017004980b2f10799
10189307909173efeb84ccdab3c7c17b6b9a07a5
refs/heads/master
2021-04-06T03:37:19.241343
2018-03-15T10:00:18
2018-03-15T10:00:18
null
0
0
null
null
null
null
UTF-8
Java
false
false
5,853
java
import java.io.*; import java.util.ArrayList; import java.util.List; class Zaidejas{ private String number; private String fullName; private int bauduMetimai; private int dviMetimai; private int triMetimai; private int taskai; private int metimai; private double taiklumas; Zaidejas(String number, String fullName){ this.number = number; this.fullName = fullName; } //region Getters and Setters public String getNumber() { return number; } public void setNumber(String number) { this.number = number; } public String getFullName() { return fullName; } public void setFullName(String fullName) { this.fullName = fullName; } public int getBauduMetimai() { return bauduMetimai; } public void setBauduMetimai(int bauduMetimai) { this.bauduMetimai = bauduMetimai; } public int getDviMetimai() { return dviMetimai; } public void setDviMetimai(int dviMetimai) { this.dviMetimai = dviMetimai; } public int getTriMetimai() { return triMetimai; } public void setTriMetimai(int triMetimai) { this.triMetimai = triMetimai; } public int getTaskai() { return taskai; } public void setTaskai(int taskai) { this.taskai = taskai; } public int getMetimai() { return metimai; } public void setMetimai(int metimai) { this.metimai = metimai; } public double getTaiklumas() { return taiklumas; } public void setTaiklumas(double taiklumas) { this.taiklumas = taiklumas; } //endregion public String toString(){ StringBuilder builder = new StringBuilder(); builder.append(number); builder.append(" "); builder.append(fullName); builder.append(" "); builder.append(bauduMetimai); builder.append(" "); builder.append(dviMetimai); builder.append(" "); builder.append(triMetimai); builder.append(" "); builder.append(taskai); builder.append(" "); builder.append(metimai); builder.append(" "); builder.append(taiklumas); return builder.toString(); } } public class EDocP9 { private static final String FILE_ZAIDEJAI = "Duomenys/zaidejai.txt"; private static final String FILE_TASKAI = "Duomenys/taskai.txt"; private static final String FILE_SUVESTINE = "Duomenys/suvestine.txt"; public static void main(String[] args) { List<Zaidejas> liz = gautiZaidejus(); List<String[]> lis = gautiTaskus(); List<Zaidejas> full = pildytiDuomenis(liz, lis); darytiSuvestine(full); } private static List<Zaidejas> gautiZaidejus(){ String eil; String[] duom; List<Zaidejas> listas = new ArrayList<>(); Zaidejas zaid; try(BufferedReader read = new BufferedReader(new FileReader(FILE_ZAIDEJAI))){ while ((eil = read.readLine())!= null){ duom = eil.split(" "); zaid = new Zaidejas(duom[0], (duom[1]+" "+duom[2])); listas.add(zaid); } }catch (IOException e){ } return listas; } private static List<String[]> gautiTaskus(){ List<String[]> listas = new ArrayList<>(); String eil; String[] duom; try(BufferedReader read = new BufferedReader(new FileReader(FILE_TASKAI))){ while ((eil = read.readLine())!= null){ duom = eil.split(" "); listas.add(duom); } }catch (IOException e){ } return listas; } private static List<Zaidejas> pildytiDuomenis(List<Zaidejas> zd, List<String[]> st){ int t1; int t2; int t3; int t0; int spek; int taskai; int metimai; double taikl; for(int i = 0; i < zd.size(); i++){ t1 =0; t2 =0; t3=0; t0 = 0; for(int j = 0; j < st.size(); j++){ if(zd.get(i).getNumber().equals(st.get(j)[0])){ spek = Integer.parseInt(st.get(j)[1]); if(spek == 0){ t0++; }else if(spek == 1){ t1++; }else if(spek == 2){ t2++; }else{ t3++; } } taskai = t1+(t2*2)+(t3*3); if(t2 == 0 && t3 != 0){ metimai = (t0 + t1 +(t3)); } else if(t2 !=0 && t3 == 0){ metimai = (t0 + t1 +(t2)); } else{ metimai = (t0 + t1 +t2+t3); } if(taskai != 0 && metimai != 0){ taikl = (double) metimai/((double) metimai+t0); taikl = taikl *100; } else{ taikl = 0; } zd.get(i).setMetimai(t0); zd.get(i).setDviMetimai(t2); zd.get(i).setBauduMetimai(t1); zd.get(i).setTriMetimai(t3); zd.get(i).setTaskai(taskai); zd.get(i).setTaiklumas(taikl); } } return zd; } private static void darytiSuvestine(List<Zaidejas> listas){ try(BufferedWriter write = new BufferedWriter(new FileWriter(FILE_SUVESTINE))){ for(Zaidejas zd : listas){ write.write(zd.toString()+"\n"); } System.out.println("Darbas Baigtas"); }catch (IOException e){ } } }
[ "simanaviciusandrius96@gmail.com" ]
simanaviciusandrius96@gmail.com
ccc84b7a4985f767708b732ae6578f98add8e81d
fe3ddcb2e3acb5dcd82acc1ceabbbe793f67dd1a
/src/main/java/com/proxyJingtai/IUserDao.java
4e745e26d637ba41704d94a555faf9b0bbfc9dee
[]
no_license
painAdmin/save201706
84ea5c71eda0b6cd8e911049c44c8cc65bfaf4e5
09e3fa5b72ab2580bddabfedf511767ed57f7a24
refs/heads/master
2021-09-10T17:40:30.593993
2018-03-30T09:13:25
2018-03-30T09:13:25
110,919,380
0
0
null
null
null
null
UTF-8
Java
false
false
118
java
package com.proxyJingtai; /** * 接口 * @author pain * */ public interface IUserDao { void save(); }
[ "1767123925@qq.com" ]
1767123925@qq.com
a2b22da1e2f16a9a366302d3751910e7952973f0
d53e75d262d2c346a33e085d36f10f6f5c480098
/wip/src/com/example/wip/yelpstuff/User.java
14ebb7039b9276619bcc20fd7b54036274e38cab
[]
no_license
schyau/bbhackathon
1c7392ea195b5c590df8f1ee5e520fe048acc228
8c230b2c471ad6b452ff2663522c3e7916a4f2ad
refs/heads/master
2021-01-01T15:59:47.036456
2014-03-06T09:07:44
2014-03-06T09:07:44
null
0
0
null
null
null
null
UTF-8
Java
false
false
495
java
package com.example.wip.yelpstuff; import java.net.URL; public class User { private String id; private URL imageUrl; private String name; public String getId() { return id; } public void setId(String id) { this.id = id; } public URL getImageUrl() { return imageUrl; } public void setImageUrl(URL imageUrl) { this.imageUrl = imageUrl; } public String getName() { return name; } public void setName(String name) { this.name = name; } }
[ "Stephen.Chyau@Blackboard.com" ]
Stephen.Chyau@Blackboard.com
ed4432105f5a81a065140b6c39314ac1c9dd42a7
fd1fae21b3fe2a0ccec27500d4dd513c94e81e82
/src/lesson_2/task_2_1.java
568dcc8449b580ffa2b8a617b5feacc1e5821235
[]
no_license
StarT-Teg/GeekBrains.Level1
dd9e851ecca7924455f477314a1b0ed07e9a35ed
379ce3b6007b86dba63ffadbc0887cc769084d2e
refs/heads/master
2023-01-03T04:37:28.187375
2020-10-25T16:38:20
2020-10-25T16:38:20
298,522,121
0
0
null
null
null
null
UTF-8
Java
false
false
291
java
package lesson_2; public class task_2_1 { public static void main(String[] args) { byte[] massive = new byte[]{1, 1, 0, 0, 1, 0, 1, 1, 0, 0, 0}; for (int i = 0; i < massive.length; i++) { massive[i] = (byte) (massive[i] == 0 ? 1 : 0); } } }
[ "romik.13@Mail.ru" ]
romik.13@Mail.ru
27c84690c5c46d935401ebd7fa7a7de7e0a4ab4f
1569335c18b81d1fcae9c35220b703f708b8ba6a
/source/57_Insert Interval.java
ef8dd3bda3586c45835b708a1782421860cf6011
[]
no_license
XiaohanWang92/LeetCode-implementation
7f9ea1086ae7734ba0ff9e6c910e08d6f4e283f7
3aa4a54c8b92af928aaa4fc396cf9456b7c58011
refs/heads/master
2021-05-04T10:22:37.383588
2017-01-23T21:03:39
2017-01-23T21:03:39
48,403,686
0
0
null
null
null
null
UTF-8
Java
false
false
1,298
java
/** * Definition for an interval. * public class Interval { * int start; * int end; * Interval() { start = 0; end = 0; } * Interval(int s, int e) { start = s; end = e; } * } */ public class Solution { public List<Interval> insert(List<Interval> intervals, Interval newInterval) { List<Interval> result = new ArrayList<Interval>(); if(intervals == null || intervals.size() == 0) { result.add(newInterval); return result; } int index = 0; while(index < intervals.size() && intervals.get(index).end < newInterval.start) { result.add(intervals.get(index)); index++; } int mergeStart = newInterval.start; int mergeEnd = newInterval.end; while(index < intervals.size()) { if(intervals.get(index).start > newInterval.end) break; mergeStart = Math.min(mergeStart, intervals.get(index).start); mergeEnd = Math.max(mergeEnd, intervals.get(index).end); index++; } Interval merge = new Interval(mergeStart, mergeEnd); result.add(merge); while(index < intervals.size()) { result.add(intervals.get(index)); index++; } return result; } }
[ "wangxiaohan2014@gmail.com" ]
wangxiaohan2014@gmail.com
37be60cb66da043700ce60f009dd4767e50fd8b3
0f5b8ccd8275b2d5dfa947fe6688862706997fc4
/runescape-client/src/main/java/osrs/class388.java
2f0b60f878e775679864e7af028b3e2b571a802f
[]
no_license
Sundar-Gandu/MeteorLite
6a653c4bb0458562e47088e1d859d8eb7a171460
f415bf93af2a771f920f261690eec4c7ff1b62c2
refs/heads/main
2023-08-31T17:40:57.071420
2021-10-26T07:56:40
2021-10-26T07:56:40
400,632,896
0
1
null
null
null
null
UTF-8
Java
false
false
485
java
package osrs; import net.runelite.mapping.ObfuscatedName; import net.runelite.mapping.ObfuscatedSignature; @ObfuscatedName("nb") public interface class388 { @ObfuscatedName("l") @ObfuscatedSignature( descriptor = "(Ljava/lang/Object;Lot;I)V", garbageValue = "804166773" ) void vmethod6815(Object var1, Buffer var2); @ObfuscatedName("q") @ObfuscatedSignature( descriptor = "(Lot;I)Ljava/lang/Object;", garbageValue = "1421946597" ) Object vmethod6822(Buffer var1); }
[ "therealnull@gmail.com" ]
therealnull@gmail.com
6de2ee337340772792c6d05e587d137aa13c54a4
dd6fe28c31218be9f01db7eca1226050993d7e2b
/src/main/java/com/stef/MagazineProject/DAO/AbstractDao.java
c3f74e6b93ca76202156dfcd01342825fd9a42de
[]
no_license
OliaStfn/InternetShop
d51c542cd38bdba843f7199807a2e5e11f6ab9ee
a35504c26c4f4b284bc44aa231c9ac21d7a627f0
refs/heads/master
2021-01-21T15:27:37.658034
2017-06-14T23:02:37
2017-06-14T23:02:37
91,846,146
0
0
null
null
null
null
UTF-8
Java
false
false
4,992
java
package com.stef.MagazineProject.DAO; import org.apache.log4j.Logger; import java.sql.Connection; import java.sql.PreparedStatement; import java.sql.ResultSet; import java.util.ArrayList; import java.util.GregorianCalendar; public abstract class AbstractDao<T extends Identifacator<PK>, PK extends Integer> implements GenericDao<T, PK> { private Connection connection; private static final Logger log = Logger.getLogger(AbstractDao.class); public AbstractDao(Connection connection) { this.connection = connection; } public abstract String getCreateQuery(); public abstract String getSelectQuery(); public abstract String getSelectAllQuery(); public abstract String getUpdateQuery(); public abstract String getDeleteQuery(); public abstract ArrayList<T> parseResultSet(ResultSet resultSet) throws DaoException; public abstract void statementUpdate(PreparedStatement statement, T obj) throws DaoException; public abstract void statementInsert(PreparedStatement statement, T obj) throws DaoException; @Override public T createInDB(T object) throws DaoException { T tempObj; String query = getCreateQuery(); try (PreparedStatement statement = connection.prepareStatement(query)) { statementInsert(statement, object); int changedFields = statement.executeUpdate(); if (changedFields != 1) throw new DaoException("During creating,created more than 1 object: " + changedFields); } catch (Exception e) { log.error(e); throw new DaoException(); } query = getSelectQuery()+"(SELECT last_insert_id());"; try (PreparedStatement statement = connection.prepareStatement(query)) { ResultSet resultSet = statement.executeQuery(); ArrayList<T> someList = parseResultSet(resultSet); if (someList == null || someList.size() != 1) { throw new DaoException("Error on search last created object"); } tempObj = someList.iterator().next(); } catch (Exception e) { log.error(e); throw new DaoException(); } return tempObj; } @Override public T read(PK key) throws DaoException { ArrayList<T> someList; String query = getSelectQuery()+key+";"; try (PreparedStatement statement = connection.prepareStatement(query)) { ResultSet resultSet = statement.executeQuery(); someList = parseResultSet(resultSet); } catch (Exception e) { log.error(e+"Error with read database"); throw new DaoException(); } if (someList == null || someList.size() == 0) { log.error("Record with id=" + key + " not found in database"); return null; } if (someList.size() > 1) { throw new DaoException("Found more than one record with id=" + key); } return someList.iterator().next(); } @Override public void update(T obj) throws DaoException { String query = getUpdateQuery(); try (PreparedStatement statement = connection.prepareStatement(query)) { statementUpdate(statement, obj); int changedFields = statement.executeUpdate(); if (changedFields != 1) throw new DaoException("During update more than 1 field"); statement.close(); } catch (Exception e) { log.error(e); throw new DaoException(); } } @Override public void delete(T obj) throws DaoException { String query = getDeleteQuery(); try (PreparedStatement statement = connection.prepareStatement(query)) { statement.setObject(1,obj.getId()); int changedFields = statement.executeUpdate(); if (changedFields != 1) throw new DaoException("During query deleted more than 1 field: " + changedFields); } catch (Exception e) { log.error(e); throw new DaoException(); } } @Override public ArrayList<T> readAll() throws DaoException { ArrayList<T> someList; String query = getSelectAllQuery(); try (PreparedStatement statement = connection.prepareStatement(query)) { ResultSet resultSet = statement.executeQuery(); someList = parseResultSet(resultSet); } catch (Exception e) { log.error(e+"Error with read databases"); throw new DaoException(); } return someList; } protected GregorianCalendar convertToGD(java.sql.Date date){ GregorianCalendar gregorianCalendar = new GregorianCalendar(); gregorianCalendar.setTime(date); return gregorianCalendar; } protected java.sql.Date convertToDate(GregorianCalendar gregorianCalendar){ return new java.sql.Date(gregorianCalendar.getTime().getTime()); } }
[ "kardash44@mail.ru" ]
kardash44@mail.ru
0c3f356bb920ebd6f82bb5e78dbfa42bae8a9062
5e0ef2dcc9362096fe10e7b5c663ee07affedbd8
/src/main/java/com/iqmsoft/controller/entity/ExampleEntityViewConstants.java
61846b8d753dabde24d095e5e9a4538546dfc046
[]
no_license
Murugar2021/ThymeLeafMVC
425ffa03eb9f621926387bbdb1e3df0ee7bc54c5
7baf196b2832da8fe33eb14dc9ee8abec72e0be9
refs/heads/main
2023-05-23T07:39:08.462477
2021-06-15T14:22:01
2021-06-15T14:22:01
377,189,684
0
0
null
null
null
null
UTF-8
Java
false
false
1,969
java
/** * The MIT License (MIT) * <p> * Copyright (c) 2017 the original author or authors. * <p> * 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: * <p> * The above copyright notice and this permission notice shall be included in * all copies or substantial portions of the Software. * <p> * 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 com.iqmsoft.controller.entity; /** * Constants for the example entity view controllers. * * @author Bernardo Mart&iacute;nez Garrido */ public final class ExampleEntityViewConstants { /** * Form bean parameter name. */ public static final String BEAN_FORM = "form"; /** * Entities parameter name. */ public static final String PARAM_ENTITIES = "entities"; /** * Name for the entity form. */ public static final String VIEW_ENTITY_FORM = "entity/form"; /** * Name for the entities view. */ public static final String VIEW_ENTITY_LIST = "entity/list"; /** * Private constructor to avoid initialization. */ private ExampleEntityViewConstants() { super(); } }
[ "davanon2014@gmail.com" ]
davanon2014@gmail.com
e5f0ace12ebc47ea91f8eedb436d6fea28f00196
73364c57427e07e90d66692a3664281d5113177e
/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/EmailController.java
ce59a592ccab1d8651215cb6367f5d2b718cb9d0
[ "BSD-3-Clause" ]
permissive
abyot/sun-pmt
4681f008804c8a7fc7a75fe5124f9b90df24d44d
40add275f06134b04c363027de6af793c692c0a1
refs/heads/master
2022-12-28T09:54:11.381274
2019-06-10T15:47:21
2019-06-10T15:47:21
55,851,437
0
1
BSD-3-Clause
2022-12-16T12:05:12
2016-04-09T15:21:22
Java
UTF-8
Java
false
false
6,222
java
package org.hisp.dhis.webapi.controller; /* * Copyright (c) 2004-2017, University of Oslo * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this * list of conditions and the following disclaimer. * * Redistributions in binary form must reproduce the above copyright notice, * this list of conditions and the following disclaimer in the documentation * and/or other materials provided with the distribution. * Neither the name of the HISP project nor the names of its contributors may * be used to endorse or promote products derived from this software without * specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ import org.hisp.dhis.dxf2.webmessage.WebMessageException; import org.hisp.dhis.dxf2.webmessage.WebMessageUtils; import org.hisp.dhis.email.Email; import org.hisp.dhis.email.EmailService; import org.hisp.dhis.setting.SystemSettingManager; import org.hisp.dhis.user.CurrentUserService; import org.hisp.dhis.webapi.mvc.annotation.ApiVersion; import org.hisp.dhis.common.DhisApiVersion; import org.hisp.dhis.webapi.service.WebMessageService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.security.access.prepost.PreAuthorize; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMethod; import org.springframework.web.bind.annotation.RequestParam; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import java.util.Set; /** * @author Halvdan Hoem Grelland <halvdanhg@gmail.com> */ @Controller @RequestMapping( value = EmailController.RESOURCE_PATH ) @ApiVersion( { DhisApiVersion.DEFAULT, DhisApiVersion.ALL } ) public class EmailController { public static final String RESOURCE_PATH = "/email"; private static final String SMTP_ERROR = "SMTP server not configured"; private static final String EMAIL_DISABLED = "Email message notifications disabled"; //-------------------------------------------------------------------------- // Dependencies //-------------------------------------------------------------------------- @Autowired private EmailService emailService; @Autowired private CurrentUserService currentUserService; @Autowired private SystemSettingManager systemSettingManager; @Autowired private WebMessageService webMessageService; @RequestMapping( value = "/test", method = RequestMethod.POST ) public void sendTestEmail( HttpServletResponse response, HttpServletRequest request ) throws WebMessageException { checkEmailSettings(); String userEmail = currentUserService.getCurrentUser().getEmail(); boolean userEmailConfigured = userEmail != null && !userEmail.isEmpty(); if ( !userEmailConfigured ) { throw new WebMessageException( WebMessageUtils.conflict( "Could not send test email, no email configured for current user" ) ); } emailService.sendTestEmail(); webMessageService.send( WebMessageUtils.ok( "Test email was sent to " + userEmail ), response, request ); } @RequestMapping( value = "/notification", method = RequestMethod.POST ) public void sendSystemNotificationEmail( @RequestBody Email email, HttpServletResponse response, HttpServletRequest request ) throws WebMessageException { checkEmailSettings(); boolean systemNotificationEmailValid = systemSettingManager.systemNotificationEmailValid(); if ( !systemNotificationEmailValid ) { throw new WebMessageException( WebMessageUtils.conflict( "Could not send email, system notification email address not set or not valid" ) ); } emailService.sendSystemEmail( email ); webMessageService.send( WebMessageUtils.ok( "System notification email sent" ), response, request ); } @PreAuthorize( "hasRole('ALL') or hasRole('F_SEND_EMAIL')" ) @RequestMapping( value = "/notification", method = RequestMethod.POST, produces = "application/json" ) public void sendEmailNotification( @RequestParam Set<String> recipients, @RequestParam String message, @RequestParam ( defaultValue = "DHIS 2" ) String subject, HttpServletResponse response, HttpServletRequest request ) throws WebMessageException { checkEmailSettings(); emailService.sendEmail( subject, message, recipients ); webMessageService.send( WebMessageUtils.ok( "Email sent" ), response, request ); } // --------------------------------------------------------------------- // Supportive methods // --------------------------------------------------------------------- private void checkEmailSettings() throws WebMessageException { if ( !emailService.emailEnabled() ) { throw new WebMessageException( WebMessageUtils.error( EMAIL_DISABLED ) ); } if ( !emailService.emailConfigured() ) { throw new WebMessageException( WebMessageUtils.error( SMTP_ERROR ) ); } } }
[ "abyota@gmail.com" ]
abyota@gmail.com
a822850c0fb9df3ace81fe03cfd11640e2492613
29c0f5013c0bacbf1f3b726c0ccded9efb4404b1
/app/src/main/java/com/example/myapplication/RegisterActivity.java
aa10d8dbeb235aa61e2a95e47bd850a698e3b59b
[]
no_license
Dennis-Mwea/Android-Api
6b74addaea07eaa5dc5093e853c14a790e1e22a5
0c8c04c5b3d8d448f29c82f0c51e290de3c94c66
refs/heads/master
2023-04-08T01:05:59.105007
2022-11-22T06:55:24
2022-11-22T06:55:24
177,458,831
0
1
null
2023-03-15T08:22:12
2019-03-24T19:22:41
PHP
UTF-8
Java
false
false
4,685
java
package com.example.myapplication; import android.content.Intent; import android.support.design.widget.TextInputLayout; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; import android.util.Log; import android.util.Patterns; import com.basgeekball.awesomevalidation.AwesomeValidation; import com.basgeekball.awesomevalidation.ValidationStyle; import com.basgeekball.awesomevalidation.utility.RegexTemplate; import com.example.myapplication.entities.AccessToken; import com.example.myapplication.entities.ApiError; import com.example.myapplication.network.ApiService; import com.example.myapplication.network.RetrofitBuilder; import java.io.IOException; import java.lang.annotation.Annotation; import java.util.List; import java.util.Map; import butterknife.BindView; import butterknife.ButterKnife; import butterknife.OnClick; import okhttp3.ResponseBody; import retrofit2.Call; import retrofit2.Callback; import retrofit2.Converter; import retrofit2.Response; public class RegisterActivity extends AppCompatActivity { private static final String TAG = "RegisterActivity"; @BindView(R.id.til_name) TextInputLayout tilName; @BindView(R.id.til_email) TextInputLayout tilEmail; @BindView(R.id.til_password) TextInputLayout tilPassword; ApiService service; Call<AccessToken> call; AwesomeValidation validator; TokenManager tokenManager; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_register); ButterKnife.bind(this); service = RetrofitBuilder.createService(ApiService.class); validator = new AwesomeValidation(ValidationStyle.TEXT_INPUT_LAYOUT); tokenManager = TokenManager.getInstance(getSharedPreferences("prefs", MODE_PRIVATE)); setupRules(); if(tokenManager.getToken().getAccessToken() != null){ startActivity(new Intent(RegisterActivity.this, PostActivity.class)); finish(); } } @OnClick(R.id.btn_register) void register(){ String name = tilName.getEditText().getText().toString(); String email = tilEmail.getEditText().getText().toString(); String password = tilPassword.getEditText().getText().toString(); tilName.setError(null); tilEmail.setError(null); tilPassword.setError(null); validator.clear(); if(validator.validate()) { call = service.register(name, email, password); call.enqueue(new Callback<AccessToken>() { @Override public void onResponse(Call<AccessToken> call, Response<AccessToken> response) { Log.w(TAG, "onResponse: " + response); if (response.isSuccessful()) { Log.w(TAG, "onResponse: " + response.body() ); tokenManager.saveToken(response.body()); startActivity(new Intent(RegisterActivity.this, PostActivity.class)); finish(); } else { handleErrors(response.errorBody()); } } @Override public void onFailure(Call<AccessToken> call, Throwable t) { Log.w(TAG, "onFailure: " + t.getMessage()); } }); } } @OnClick(R.id.go_to_login) void goToRegister(){ startActivity(new Intent(RegisterActivity.this, LoginActivity.class)); } private void handleErrors(ResponseBody response){ ApiError apiError = Utils.converErrors(response); for(Map.Entry<String, List<String>> error : apiError.getErrors().entrySet()){ if(error.getKey().equals("name")){ tilName.setError(error.getValue().get(0)); } if(error.getKey().equals("email")){ tilEmail.setError(error.getValue().get(0)); } if(error.getKey().equals("password")){ tilPassword.setError(error.getValue().get(0)); } } } public void setupRules(){ validator.addValidation(this, R.id.til_name, RegexTemplate.NOT_EMPTY, R.string.err_name); validator.addValidation(this, R.id.til_email, Patterns.EMAIL_ADDRESS, R.string.err_email); validator.addValidation(this, R.id.til_password, "[a-zA-Z0-9]{6,}", R.string.err_password); } @Override protected void onDestroy() { super.onDestroy(); if(call != null) { call.cancel(); call = null; } } }
[ "mweadennis2@gmail.com" ]
mweadennis2@gmail.com
2cc46fe1252c68273fa2e81a2623f0c9fc1b3726
99462bc5a770c3d98fa41489d8efd27813b9a3e2
/uri1064.java
8e94ed44486263676174920158cedd875b562815
[]
no_license
giselescarvalho/URI_exercises
6689045e341d19928c0a9f38a033452bc67aefa2
7f17a8ba3e4c1de7f4dafb7f08f39543e1776fed
refs/heads/master
2023-04-26T01:15:25.088584
2021-05-30T02:10:49
2021-05-30T02:10:49
303,173,790
0
0
null
null
null
null
ISO-8859-1
Java
false
false
1,080
java
/*Leia 6 valores. Em seguida, mostre quantos destes valores digitados foram positivos. Na próxima linha, deve-se mostrar a média de todos os valores positivos digitados, com um dígito após o ponto decimal. Entrada A entrada contém 6 números que podem ser valores inteiros ou de ponto flutuante. Pelo menos um destes números será positivo. Saída O primeiro valor de saída é a quantidade de valores positivos. A próxima linha deve mostrar a média dos valores positivos digitados.*/ package uri; import java.util.Scanner; import java.io.IOException; public class uri1064 { public static void main(String[] args) throws IOException { Scanner leitor = new Scanner(System.in); int cont = 0; double media = 0; double x; for (int i = 0; i < 6; i++) { x = leitor.nextDouble(); if (x > 0) { cont++; media += x; } } media = media / cont; System.out.println(cont + " valores positivos"); System.out.println(String.format("%.1f", media)); } }
[ "giseledasilvac@gmail.com" ]
giseledasilvac@gmail.com
6876195f61801f13bab7f3039cb8010766c6464a
ab7f57109a37d826dd58952b3ebe7a11440602ea
/pigx-master/pigx/pigx-common/pigx-common-datasource/src/main/java/com/pig4cloud/pigx/common/datasource/support/DataSourceConstants.java
af57b82fceee453b7b104d9dc4b253a2f516d386
[]
no_license
soon14/Netty-IM-demo
a57786c81d66f02b7af3dfbd86b3c0040bcbade3
4a6cb8f6740d6cc39d96685b43c99766ebf8acd8
refs/heads/master
2023-03-19T13:51:56.858548
2021-03-18T03:51:39
2021-03-18T03:51:39
null
0
0
null
null
null
null
UTF-8
Java
false
false
577
java
package com.pig4cloud.pigx.common.datasource.support; /** * @author lengleng * @date 2019-04-01 * <p> * 数据源相关常量 */ public interface DataSourceConstants { /** * 查询数据源的SQL */ String QUERY_DS_SQL = "select * from gen_datasource_conf where del_flag = 0"; /** * 动态路由KEY */ String DS_ROUTE_KEY = "id"; /** * 数据源名称 */ String DS_NAME = "name"; /** * jdbcurl */ String DS_JDBC_URL = "url"; /** * 用户名 */ String DS_USER_NAME = "username"; /** * 密码 */ String DS_USER_PWD = "password"; }
[ "1367887546@qq.com" ]
1367887546@qq.com
cf39de968c82699b34b872011cedf97695825045
0e85b04427cbe290e4cda4c1accbbd4163622832
/src/org/sag/acminer/database/accesscontrol/IAccessControlDatabase.java
fc0196d64e7d013e62eff0a80ccfba5e8691eb0d
[ "BSD-2-Clause" ]
permissive
wspr-ncsu/acminer
5dc9da912219ecbf329cdcecbae11bc977a04e6f
2df675bc18036d0e9aed8b23a9a38adbdbb25aaf
refs/heads/master
2022-08-17T21:03:36.758722
2019-10-08T14:48:14
2020-02-28T01:58:09
213,671,525
4
0
null
null
null
null
UTF-8
Java
false
false
2,789
java
package org.sag.acminer.database.accesscontrol; import java.nio.file.Path; import java.util.List; import java.util.Map; import java.util.Set; import org.sag.acminer.phases.entrypoints.EntryPoint; import org.sag.common.io.FileHash; import org.sag.common.io.FileHashList; import org.sag.common.tuple.Pair; import org.sag.xstream.XStreamInOut.XStreamInOutInterface; import soot.SootMethod; import soot.Unit; public interface IAccessControlDatabase extends XStreamInOutInterface { public List<FileHash> getFileHashList(); public void setFileHashList(FileHashList fhl); public String getType(); public void sortData(); public void add(EntryPoint ep, Map<SootMethod, Pair<Set<Unit>, Set<Integer>>> dataToAdd); public void addAll(Map<EntryPoint, Map<SootMethod, Pair<Set<Unit>, Set<Integer>>>> dataToAdd); public boolean contains(EntryPoint ep, Unit u); public boolean contains(Unit u); public Set<Unit> getUnits(EntryPoint ep); public Set<Unit> getUnits(); public Map<Unit, Set<Integer>> getUnitsWithDepth(EntryPoint ep); public Map<Unit, Set<Integer>> getUnitsWithDepth(); public Set<SootMethod> getSources(EntryPoint ep); public Set<SootMethod> getSources(); public Map<SootMethod, Set<Integer>> getSourcesWithDepth(EntryPoint ep); public Map<SootMethod, Set<Integer>> getSourcesWithDepth(); public Map<SootMethod, Pair<Set<Unit>, Set<Integer>>> getData(EntryPoint ep); public Map<SootMethod, Pair<Set<Unit>, Set<Integer>>> getData(); public Map<EntryPoint, Map<SootMethod, Pair<Set<Unit>, Set<Integer>>>> getAllData(); public abstract String toString(); public String toString(String spacer); public String toString(EntryPoint ep, String spacer); public abstract int hashCode(); public abstract boolean equals(Object o); public abstract IAccessControlDatabase readXML(String filePath, Path path) throws Exception; /** Clears out the soot data map and dumps the data to the output structure so it can be * read back in if needed. Note this does not write the data to file. This puts the data * structure into a state as if the data were just read from a file and readResolve had * not run yet. */ public abstract void resetSootResolvedData(); /** Loads the data from the output structure into soot resolved data structures, overwriting * any pre-existing soot resolved data. Note this method should only be called after * {@link #resetSootResolvedData()} once soot has been reset to the appropriate state. It is * not required to be called when reading the data in from file as this process automatically * loads the soot data assuming soot it is the required state. */ public abstract void loadSootResolvedData(); public abstract boolean hasData(); public abstract boolean hasData(EntryPoint ep); }
[ "sagorski@ncsu.edu" ]
sagorski@ncsu.edu
c27382392787b6f30c70f157fe69ce6ba846564b
b0885fa90c421e65cd187f23952448e0dfd08fdb
/src/main/java/gov/usgs/aqcu/validation/ReportPeriodPresent.java
64e9a4615abb60b9a0509c3b1a60649c4b26a402
[]
no_license
dsteinich/aqcu-framework
38f7ebaf7799a3372097ffbebf7254bb3566702b
55f1d962ef519e7af8ce9e0c09bf3c139b47d264
refs/heads/master
2021-09-13T02:05:15.690157
2018-04-23T19:29:29
2018-04-23T19:29:29
125,367,796
0
0
null
2018-03-15T12:59:25
2018-03-15T12:59:25
null
UTF-8
Java
false
false
742
java
package gov.usgs.aqcu.validation; import java.lang.annotation.Documented; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; import javax.validation.Constraint; import javax.validation.Payload; @Target({ElementType.TYPE}) @Retention(RetentionPolicy.RUNTIME) @Documented @Constraint(validatedBy = { ReportPeriodPresentValidator.class }) public @interface ReportPeriodPresent { String message() default "Missing information required to build report time period. Must include at least one of: [lastMonths, waterYear, {startDate, endDate}]."; Class<?>[] groups() default {}; Class<? extends Payload>[] payload() default {}; }
[ "drsteini@usgs.gov" ]
drsteini@usgs.gov
48949041476f25df387d75eaccee75e5f1d62f0f
bf23d5c4cb2f087ce0b98db6843032cd72eb94f6
/src/main/java/com/woniuxy/domain/ViptableExample.java
35b3b0fba651935d4e5d8e72cf3d2386ea9c6e08
[]
no_license
zgx-rookie/woniuticket
8d5aac06b164bf9e11afc5bbc5f31ea199874e59
28fc1dcc908f76c244801f5260fb5773efebf854
refs/heads/master
2023-01-12T15:56:00.566309
2019-10-09T03:17:16
2019-10-09T03:17:16
210,480,110
1
0
null
null
null
null
UTF-8
Java
false
false
13,727
java
package com.woniuxy.domain; import java.util.ArrayList; import java.util.List; public class ViptableExample { protected String orderByClause; protected boolean distinct; protected List<Criteria> oredCriteria; public ViptableExample() { oredCriteria = new ArrayList<Criteria>(); } public void setOrderByClause(String orderByClause) { this.orderByClause = orderByClause; } public String getOrderByClause() { return orderByClause; } public void setDistinct(boolean distinct) { this.distinct = distinct; } public boolean isDistinct() { return distinct; } public List<Criteria> getOredCriteria() { return oredCriteria; } public void or(Criteria criteria) { oredCriteria.add(criteria); } public Criteria or() { Criteria criteria = createCriteriaInternal(); oredCriteria.add(criteria); return criteria; } public Criteria createCriteria() { Criteria criteria = createCriteriaInternal(); if (oredCriteria.size() == 0) { oredCriteria.add(criteria); } return criteria; } protected Criteria createCriteriaInternal() { Criteria criteria = new Criteria(); return criteria; } public void clear() { oredCriteria.clear(); orderByClause = null; distinct = false; } protected abstract static class GeneratedCriteria { protected List<Criterion> criteria; protected GeneratedCriteria() { super(); criteria = new ArrayList<Criterion>(); } public boolean isValid() { return criteria.size() > 0; } public List<Criterion> getAllCriteria() { return criteria; } public List<Criterion> getCriteria() { return criteria; } protected void addCriterion(String condition) { if (condition == null) { throw new RuntimeException("Value for condition cannot be null"); } criteria.add(new Criterion(condition)); } protected void addCriterion(String condition, Object value, String property) { if (value == null) { throw new RuntimeException("Value for " + property + " cannot be null"); } criteria.add(new Criterion(condition, value)); } protected void addCriterion(String condition, Object value1, Object value2, String property) { if (value1 == null || value2 == null) { throw new RuntimeException("Between values for " + property + " cannot be null"); } criteria.add(new Criterion(condition, value1, value2)); } public Criteria andVidIsNull() { addCriterion("vid is null"); return (Criteria) this; } public Criteria andVidIsNotNull() { addCriterion("vid is not null"); return (Criteria) this; } public Criteria andVidEqualTo(Integer value) { addCriterion("vid =", value, "vid"); return (Criteria) this; } public Criteria andVidNotEqualTo(Integer value) { addCriterion("vid <>", value, "vid"); return (Criteria) this; } public Criteria andVidGreaterThan(Integer value) { addCriterion("vid >", value, "vid"); return (Criteria) this; } public Criteria andVidGreaterThanOrEqualTo(Integer value) { addCriterion("vid >=", value, "vid"); return (Criteria) this; } public Criteria andVidLessThan(Integer value) { addCriterion("vid <", value, "vid"); return (Criteria) this; } public Criteria andVidLessThanOrEqualTo(Integer value) { addCriterion("vid <=", value, "vid"); return (Criteria) this; } public Criteria andVidIn(List<Integer> values) { addCriterion("vid in", values, "vid"); return (Criteria) this; } public Criteria andVidNotIn(List<Integer> values) { addCriterion("vid not in", values, "vid"); return (Criteria) this; } public Criteria andVidBetween(Integer value1, Integer value2) { addCriterion("vid between", value1, value2, "vid"); return (Criteria) this; } public Criteria andVidNotBetween(Integer value1, Integer value2) { addCriterion("vid not between", value1, value2, "vid"); return (Criteria) this; } public Criteria andVgradeIsNull() { addCriterion("vgrade is null"); return (Criteria) this; } public Criteria andVgradeIsNotNull() { addCriterion("vgrade is not null"); return (Criteria) this; } public Criteria andVgradeEqualTo(String value) { addCriterion("vgrade =", value, "vgrade"); return (Criteria) this; } public Criteria andVgradeNotEqualTo(String value) { addCriterion("vgrade <>", value, "vgrade"); return (Criteria) this; } public Criteria andVgradeGreaterThan(String value) { addCriterion("vgrade >", value, "vgrade"); return (Criteria) this; } public Criteria andVgradeGreaterThanOrEqualTo(String value) { addCriterion("vgrade >=", value, "vgrade"); return (Criteria) this; } public Criteria andVgradeLessThan(String value) { addCriterion("vgrade <", value, "vgrade"); return (Criteria) this; } public Criteria andVgradeLessThanOrEqualTo(String value) { addCriterion("vgrade <=", value, "vgrade"); return (Criteria) this; } public Criteria andVgradeLike(String value) { addCriterion("vgrade like", value, "vgrade"); return (Criteria) this; } public Criteria andVgradeNotLike(String value) { addCriterion("vgrade not like", value, "vgrade"); return (Criteria) this; } public Criteria andVgradeIn(List<String> values) { addCriterion("vgrade in", values, "vgrade"); return (Criteria) this; } public Criteria andVgradeNotIn(List<String> values) { addCriterion("vgrade not in", values, "vgrade"); return (Criteria) this; } public Criteria andVgradeBetween(String value1, String value2) { addCriterion("vgrade between", value1, value2, "vgrade"); return (Criteria) this; } public Criteria andVgradeNotBetween(String value1, String value2) { addCriterion("vgrade not between", value1, value2, "vgrade"); return (Criteria) this; } public Criteria andVdiscountIsNull() { addCriterion("vdiscount is null"); return (Criteria) this; } public Criteria andVdiscountIsNotNull() { addCriterion("vdiscount is not null"); return (Criteria) this; } public Criteria andVdiscountEqualTo(Double value) { addCriterion("vdiscount =", value, "vdiscount"); return (Criteria) this; } public Criteria andVdiscountNotEqualTo(Double value) { addCriterion("vdiscount <>", value, "vdiscount"); return (Criteria) this; } public Criteria andVdiscountGreaterThan(Double value) { addCriterion("vdiscount >", value, "vdiscount"); return (Criteria) this; } public Criteria andVdiscountGreaterThanOrEqualTo(Double value) { addCriterion("vdiscount >=", value, "vdiscount"); return (Criteria) this; } public Criteria andVdiscountLessThan(Double value) { addCriterion("vdiscount <", value, "vdiscount"); return (Criteria) this; } public Criteria andVdiscountLessThanOrEqualTo(Double value) { addCriterion("vdiscount <=", value, "vdiscount"); return (Criteria) this; } public Criteria andVdiscountIn(List<Double> values) { addCriterion("vdiscount in", values, "vdiscount"); return (Criteria) this; } public Criteria andVdiscountNotIn(List<Double> values) { addCriterion("vdiscount not in", values, "vdiscount"); return (Criteria) this; } public Criteria andVdiscountBetween(Double value1, Double value2) { addCriterion("vdiscount between", value1, value2, "vdiscount"); return (Criteria) this; } public Criteria andVdiscountNotBetween(Double value1, Double value2) { addCriterion("vdiscount not between", value1, value2, "vdiscount"); return (Criteria) this; } public Criteria andUidIsNull() { addCriterion("uid is null"); return (Criteria) this; } public Criteria andUidIsNotNull() { addCriterion("uid is not null"); return (Criteria) this; } public Criteria andUidEqualTo(Integer value) { addCriterion("uid =", value, "uid"); return (Criteria) this; } public Criteria andUidNotEqualTo(Integer value) { addCriterion("uid <>", value, "uid"); return (Criteria) this; } public Criteria andUidGreaterThan(Integer value) { addCriterion("uid >", value, "uid"); return (Criteria) this; } public Criteria andUidGreaterThanOrEqualTo(Integer value) { addCriterion("uid >=", value, "uid"); return (Criteria) this; } public Criteria andUidLessThan(Integer value) { addCriterion("uid <", value, "uid"); return (Criteria) this; } public Criteria andUidLessThanOrEqualTo(Integer value) { addCriterion("uid <=", value, "uid"); return (Criteria) this; } public Criteria andUidIn(List<Integer> values) { addCriterion("uid in", values, "uid"); return (Criteria) this; } public Criteria andUidNotIn(List<Integer> values) { addCriterion("uid not in", values, "uid"); return (Criteria) this; } public Criteria andUidBetween(Integer value1, Integer value2) { addCriterion("uid between", value1, value2, "uid"); return (Criteria) this; } public Criteria andUidNotBetween(Integer value1, Integer value2) { addCriterion("uid not between", value1, value2, "uid"); return (Criteria) this; } } public static class Criteria extends GeneratedCriteria { protected Criteria() { super(); } } public static class Criterion { private String condition; private Object value; private Object secondValue; private boolean noValue; private boolean singleValue; private boolean betweenValue; private boolean listValue; private String typeHandler; public String getCondition() { return condition; } public Object getValue() { return value; } public Object getSecondValue() { return secondValue; } public boolean isNoValue() { return noValue; } public boolean isSingleValue() { return singleValue; } public boolean isBetweenValue() { return betweenValue; } public boolean isListValue() { return listValue; } public String getTypeHandler() { return typeHandler; } protected Criterion(String condition) { super(); this.condition = condition; this.typeHandler = null; this.noValue = true; } protected Criterion(String condition, Object value, String typeHandler) { super(); this.condition = condition; this.value = value; this.typeHandler = typeHandler; if (value instanceof List<?>) { this.listValue = true; } else { this.singleValue = true; } } protected Criterion(String condition, Object value) { this(condition, value, null); } protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { super(); this.condition = condition; this.value = value; this.secondValue = secondValue; this.typeHandler = typeHandler; this.betweenValue = true; } protected Criterion(String condition, Object value, Object secondValue) { this(condition, value, secondValue, null); } } }
[ "Administrator@192.168.7.58" ]
Administrator@192.168.7.58
9a6d1536f9f1337d9cc59f99fae2d6349c4eb943
156a6fc9e1d7321a500a73f28efb1bbc30cdcfef
/UDP_TicTacToe/XO/src/player/Fenetre.java
5be00ef257269c8e53052648a117c5631cbe4cf2
[]
no_license
kolmit/bvstien
0ec9a9ac8f8e79d9fd887ca14398ff153562e0f0
5163457b0c6bc6ae04ca4197c5ec4c18e65cc964
refs/heads/master
2023-08-25T23:33:00.219918
2021-04-25T16:20:58
2021-04-25T16:20:58
96,563,129
0
0
null
2023-03-06T01:07:28
2017-07-07T17:57:40
Java
UTF-8
Java
false
false
3,810
java
package player; import java.awt.GridLayout; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import javax.swing.ImageIcon; import javax.swing.JButton; import javax.swing.JFrame; import javax.swing.JPanel; @SuppressWarnings("serial") public class Fenetre extends JFrame { private JPanel contentPane; private JButton[] tabButton; private int nbColonne; private int nbLigne; private int lastX; private int lastY; private final int widthFrame = 400; private final int heightFrame = 400; private boolean cestMonTour; /** * Create the frame. */ public Fenetre(String nbColLin, int portClient) { int IntNbColLin = Integer.parseInt(nbColLin); setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); setBounds(100, 100, widthFrame, heightFrame); contentPane = new JPanel(); GridLayout grille = new GridLayout(IntNbColLin,IntNbColLin); setContentPane(contentPane); contentPane.setLayout(grille); setNbLigne(IntNbColLin); setNbColonne(IntNbColLin); grille.setHgap(1); grille.setVgap(1); int tailleGrille = nbColonne*nbLigne; tabButton = new JButton[tailleGrille]; setTitle("XO "+portClient); setLocationRelativeTo(null); setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); for (int i = 0; i < (tailleGrille) ; i++){ tabButton[i] = new JButton(); contentPane.add(tabButton[i]); tabButton[i].addActionListener(new ActionListener() { public void actionPerformed(ActionEvent arg) { if (!getTour()) return; ImageIcon image = new ImageIcon(Joueur.pathExec + "\\img\\" +Joueur.mapSymboleJoueur.get(portClient)); for (int i = 0 ; i < tabButton.length ; i++){ if (arg.getSource() == tabButton[i]){ tabButton[i].setIcon( new ImageIcon( image.getImage().getScaledInstance(heightFrame/IntNbColLin, widthFrame/IntNbColLin, 100))); tabButton[i].setDisabledIcon(new ImageIcon (image.getImage().getScaledInstance(heightFrame/IntNbColLin, widthFrame/IntNbColLin, 100))); tabButton[i].setEnabled(false); setLastButton(i); setTour(false); return; } } } }); } this.setVisible(true); } /** * ****************** Fenetre ******************** **/ public void marquerActionAutreJoueur(String coord, int portClient, String symboleAutreJoueur){ int x = Integer.parseInt(coord.substring(0, coord.indexOf(":"))); int y = Integer.parseInt(coord.substring(coord.indexOf(":") + 1, coord.length())); int i = (y-1)*getNbColonne() + (x-1); ImageIcon image = new ImageIcon(Joueur.pathExec + "\\img\\" +symboleAutreJoueur); this.tabButton[i].setIcon( new ImageIcon( new ImageIcon(Joueur.pathExec + "\\img\\" +symboleAutreJoueur).getImage().getScaledInstance(this.getHeight()/this.getNbLigne(), this.getWidth()/this.getNbColonne(), 100))); tabButton[i].setDisabledIcon(new ImageIcon (image.getImage().getScaledInstance(this.getHeight()/this.getNbLigne(), this.getWidth()/this.getNbColonne(), 100))); tabButton[i].setEnabled(false); } public boolean getTour() { return cestMonTour; } public void setTour(boolean b) { cestMonTour = b; } /* ***********************/ public int getNbColonne() {return nbColonne;} public int getNbLigne() {return nbLigne;} public void setNbColonne(int nbColonne) {this.nbColonne = nbColonne;} public void setNbLigne(int nbLigne) {this.nbLigne = nbLigne;} private void setLastButton(int i) { this.lastX = (i%getNbColonne()+1); this.lastY = (i/getNbColonne())+1; } public String getLastButton(){return new String(this.lastX+":"+this.lastY); } }
[ "gazord_30@hotmail.fr" ]
gazord_30@hotmail.fr
642b755a4062645432892d28ea5a568be53a064e
b111b77f2729c030ce78096ea2273691b9b63749
/db-example-large-multi-project/project89/src/main/java/org/gradle/test/performance/mediumjavamultiproject/project89/p446/Production8932.java
b1c55f5b9ff903e95e446665e72aadb8d062803c
[]
no_license
WeilerWebServices/Gradle
a1a55bdb0dd39240787adf9241289e52f593ccc1
6ab6192439f891256a10d9b60f3073cab110b2be
refs/heads/master
2023-01-19T16:48:09.415529
2020-11-28T13:28:40
2020-11-28T13:28:40
256,249,773
1
0
null
null
null
null
UTF-8
Java
false
false
1,896
java
package org.gradle.test.performance.mediumjavamultiproject.project89.p446; public class Production8932 { private String property0; public String getProperty0() { return property0; } public void setProperty0(String value) { property0 = value; } private String property1; public String getProperty1() { return property1; } public void setProperty1(String value) { property1 = value; } private String property2; public String getProperty2() { return property2; } public void setProperty2(String value) { property2 = value; } private String property3; public String getProperty3() { return property3; } public void setProperty3(String value) { property3 = value; } private String property4; public String getProperty4() { return property4; } public void setProperty4(String value) { property4 = value; } private String property5; public String getProperty5() { return property5; } public void setProperty5(String value) { property5 = value; } private String property6; public String getProperty6() { return property6; } public void setProperty6(String value) { property6 = value; } private String property7; public String getProperty7() { return property7; } public void setProperty7(String value) { property7 = value; } private String property8; public String getProperty8() { return property8; } public void setProperty8(String value) { property8 = value; } private String property9; public String getProperty9() { return property9; } public void setProperty9(String value) { property9 = value; } }
[ "nateweiler84@gmail.com" ]
nateweiler84@gmail.com
66428567bf3db29edb74d9a7c47891fe15f71afc
2cfc99286a3d6ee16e4aecaa6a2374f0fcccae48
/Font/app/src/main/java/com/example/gohome/Organizer/Fragment/OrganizerMemberFragment.java
463e6f8d8baae1580a68c8b050aea4d3a1f93cf4
[]
no_license
Dudebla/GoHome
6854f0f921fd25b33f78887a9aa88a0f315600ab
c4373aeb326398f87ecb947a4249b27eabc73124
refs/heads/master
2022-12-02T03:41:19.440764
2020-01-01T00:25:02
2020-01-01T00:25:02
288,408,660
0
0
null
null
null
null
UTF-8
Java
false
false
9,285
java
package com.example.gohome.Organizer.Fragment; import android.content.Context; import android.content.SharedPreferences; import android.os.Build; import android.os.Bundle; import android.os.Handler; import android.os.Message; import android.util.Log; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.ListView; import android.widget.Toast; import androidx.annotation.NonNull; import androidx.annotation.Nullable; import androidx.fragment.app.Fragment; import com.example.gohome.Entity.Member; import com.example.gohome.Organizer.Adapter.MemberListViewAdapter; import com.example.gohome.Component.OrganizerMemberSideBar; import com.example.gohome.R; import com.example.gohome.Utils.MemberUserNameComparator; import com.google.gson.Gson; import com.google.gson.JsonArray; import com.google.gson.JsonElement; import com.google.gson.JsonParser; import org.json.JSONArray; import org.json.JSONObject; import java.io.IOException; import java.util.ArrayList; import java.util.Collections; import java.util.Comparator; import java.util.List; import java.util.concurrent.TimeUnit; import okhttp3.Call; import okhttp3.Callback; import okhttp3.HttpUrl; import okhttp3.OkHttpClient; import okhttp3.Request; import okhttp3.Response; public class OrganizerMemberFragment extends Fragment { public static final int SUCCESS_CODE = 1; public static final int FAILURE_CODE = 0; private ListView memberListView; private MemberListViewAdapter memberListViewAdapter; private OrganizerMemberSideBar memberSideBar; private List<Member> memberList = null; private Object lock = null; private Handler handler = new Handler(){ @Override public void handleMessage(Message msg) { super.handleMessage(msg); try { if(msg.what==SUCCESS_CODE){//链接成功 JSONObject jsonObject = new JSONObject(msg.getData().getString("response")); Boolean success = jsonObject.getBoolean("success"); if(success){ String jsonStr = jsonObject.getString("memberMessage"); Gson gson = new Gson(); JsonParser parser = new JsonParser(); JsonArray jsonArray = parser.parse(jsonStr).getAsJsonArray(); List<Member> list = new ArrayList<>(); for(JsonElement obj : jsonArray){ Member member = gson.fromJson(obj, Member.class); System.out.println(member); member.setUserName(member.getUserName()); list.add(member); } if(list!=null){ //根据拼音排序 if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) { list.sort(new Comparator<Member>() { @Override public int compare(Member member, Member t1) { return member.getPinyin().compareTo(t1.getPinyin()); } }); } else { MemberUserNameComparator comparator = new MemberUserNameComparator(); Collections.sort(list, comparator); } synchronized (lock){ memberList = list; memberListViewAdapter = new MemberListViewAdapter(getActivity(), memberList); memberListView.setAdapter(memberListViewAdapter); memberListViewAdapter.notifyDataSetChanged(); } } }else{ throw new RuntimeException(jsonObject.getString("errMsg")); } }else{//链接失败或者处理失败 Bundle bundle = msg.getData(); String errMsg = bundle.getString("errMsg"); Toast.makeText(getActivity().getApplicationContext(), errMsg, Toast.LENGTH_SHORT).show(); } }catch (Exception e){ Log.i("handle member exception", e.getMessage()); } } }; public ListView getMemberListView() { return memberListView; } public void setMemberListView(ListView memberListView) { this.memberListView = memberListView; } public OrganizerMemberSideBar getMemberSideBar() { return memberSideBar; } public void setMemberSideBar(OrganizerMemberSideBar memberSideBar) { this.memberSideBar = memberSideBar; } public List<Member> getMemberList() { return memberList; } public void setMemberList(List<Member> memberList) { this.memberList = memberList; } public Handler getHandler() { return handler; } public void setHandler(Handler handler) { this.handler = handler; } @Nullable @Override public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) { View view = inflater.inflate(R.layout.fragment_organizer_member,null); memberListView = view.findViewById(R.id.list_view); memberSideBar = view.findViewById(R.id.member_side_bar); lock = new Object(); initList(); initView(); return view; } private void initList() { memberList = new ArrayList<>(); memberList = new ArrayList<>(); memberListViewAdapter = new MemberListViewAdapter(this.getContext(), memberList); new Thread(new Runnable() { @Override public void run() { Message msg = null; try { OkHttpClient client = new OkHttpClient.Builder() .connectTimeout(10, TimeUnit.SECONDS)//设置连接超时时间 .readTimeout(20, TimeUnit.SECONDS)//设置读取超时时间 .build(); //生成json数据 Request.Builder reqBuilder = new Request.Builder(); HttpUrl.Builder urlBuilder = HttpUrl.parse(getActivity().getResources().getString(R.string.serverBasePath) + getActivity().getResources().getString(R.string.memberMessageByAreaId)).newBuilder(); SharedPreferences sharedPreferences = getActivity().getApplicationContext().getSharedPreferences("userInfo", Context.MODE_PRIVATE); int areaId = sharedPreferences.getInt("areaId", 0); urlBuilder.addQueryParameter("areaId", String.valueOf(areaId)); //请求 reqBuilder.url(urlBuilder.build()); Request request = reqBuilder.build(); //新建call联结client和request Response response = client.newCall(request).execute(); //新建call联结client和request //新建Message通过Handle与主线程通信 if(response.isSuccessful()){ msg = new Message(); msg.what = SUCCESS_CODE; String responseBody = response.body().string(); Bundle bundle = new Bundle(); bundle.putString("response", responseBody); msg.setData(bundle); handler.sendMessage(msg); }else{ String responseBody = response.body().string(); JSONObject jsonObject = new JSONObject(responseBody); String errMsg = jsonObject.getString("errMsg"); throw new RuntimeException(errMsg); } }catch (Exception e){ msg = new Message(); msg.what = FAILURE_CODE; Bundle bundle = new Bundle(); bundle.putString("errMsg", e.getMessage()); msg.setData(bundle); handler.sendMessage(msg); } } }).start(); } private void initView(){ //设置列表适配器 // memberListView.setAdapter(memberListViewAdapter); //设置字母栏跳转监听 memberSideBar.setOnStrSelectCallBack(new OrganizerMemberSideBar.ISideBarSelectCallBack() { @Override public void onSelectStr(int index, String selectStr) { if(memberList != null){ for(int i = 0; i < memberList.size(); i++){ if(selectStr.equalsIgnoreCase(memberList.get(i).getHeaderWord())){ memberListView.setSelection(i); return; } } } } }); } }
[ "oncwnuKYm6bQhil53W1fJIt9yVw4@git.weixin.qq.com" ]
oncwnuKYm6bQhil53W1fJIt9yVw4@git.weixin.qq.com
e6251415e301cc3aae341efec59cf21a265f4366
5f0883f29048845c3d796a392837eb26989e12bd
/app/src/main/java/qa/happytots/yameenhome/model/account/AccountRequest.java
b311e55b1b9724b2c0adfa8f56491ac0794669de
[]
no_license
sakmoly/FishProjectSamakSouq
668e3100cf4f38be923c2b603714cd3453d61c41
465d183cf5fbf1969348348ad7c45a38f1706d55
refs/heads/master
2022-06-05T22:39:13.908539
2020-05-05T12:29:41
2020-05-05T12:29:41
261,455,579
0
0
null
null
null
null
UTF-8
Java
false
false
1,411
java
package qa.happytots.yameenhome.model.account; import com.google.gson.annotations.Expose; import com.google.gson.annotations.SerializedName; import qa.happytots.yameenhome.model.register.response.CustomField; public class AccountRequest { @SerializedName("firstname") @Expose private String firstname; @SerializedName("lastname") @Expose private String lastname; @SerializedName("email") @Expose private String email; @SerializedName("telephone") @Expose private String telephone; @SerializedName("custom_field") @Expose private CustomField customField; public String getFirstname() { return firstname; } public void setFirstname(String firstname) { this.firstname = firstname; } public String getLastname() { return lastname; } public void setLastname(String lastname) { this.lastname = lastname; } public String getEmail() { return email; } public void setEmail(String email) { this.email = email; } public String getTelephone() { return telephone; } public void setTelephone(String telephone) { this.telephone = telephone; } public CustomField getCustomField() { return customField; } public void setCustomField(CustomField customField) { this.customField = customField; } }
[ "sakeer@printechs.com" ]
sakeer@printechs.com
4b54ffa57ffbc460a21f8b0e577b52ab7894ef45
27511a2f9b0abe76e3fcef6d70e66647dd15da96
/src/com/instagram/android/j/jo.java
97e1a7bde500979edfda6cc8ece85a1c7a599cb5
[]
no_license
biaolv/com.instagram.android
7edde43d5a909ae2563cf104acfc6891f2a39ebe
3fcd3db2c3823a6d29a31ec0f6abcf5ceca995de
refs/heads/master
2022-05-09T15:05:05.412227
2016-07-21T03:48:36
2016-07-21T03:48:36
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,072
java
package com.instagram.android.j; import android.widget.ListView; import android.widget.Toast; import com.facebook.z; import com.instagram.common.j.a.b; import com.instagram.ui.widget.refresh.RefreshableListView; final class jo extends com.instagram.common.j.a.a<com.instagram.android.feed.g.a.a> { jo(jq paramjq) {} public final void a() { jq.a(a, true); if (a.getListViewSafe() != null) { ((RefreshableListView)a.getListViewSafe()).setIsLoading(true); } } public final void a(b<com.instagram.android.feed.g.a.a> paramb) { if (a.isVisible()) { if (a.getListViewSafe() != null) { a.getListViewSafe().setVisibility(8); } Toast.makeText(a.getActivity(), z.could_not_refresh_feed, 0).show(); } } public final void b() { jq.a(a, false); if (a.getListViewSafe() != null) { ((RefreshableListView)a.getListViewSafe()).setIsLoading(false); } } } /* Location: * Qualified Name: com.instagram.android.j.jo * Java Class Version: 6 (50.0) * JD-Core Version: 0.7.1 */
[ "reverseengineeringer@hackeradmin.com" ]
reverseengineeringer@hackeradmin.com
871eed0c3b24b21ec55bd62f272dd76b5affa922
3beb2a6d3b4415bdf2fc784897aa1f71ebbebba7
/app/src/main/java/com/example/myapplication/Animal.java
5a170d54ae52675d79f50f6d7fe929f3d7c3cf5e
[]
no_license
plamiinka/Adapter_Upr5
5479f288f0766cee6e88a453c1a25ca97da4319f
94c007c5975bd867e79b3842737bc0e4ce699152
refs/heads/master
2021-05-20T03:47:21.233269
2020-04-01T16:21:26
2020-04-01T16:21:26
252,171,930
0
0
null
null
null
null
UTF-8
Java
false
false
200
java
package com.example.myapplication; public class Animal { String mName; public Animal(String name) { mName = name; } public String getName() { return mName; } }
[ "plamiink1@gmail.com" ]
plamiink1@gmail.com
fc16773ba75d6b73fd529425490ce8ce97ada90a
b6e99b0346572b7def0e9cdd1b03990beb99e26f
/src/gcom/gui/cadastro/sistemaparametro/InserirFeriadoAction.java
af32d0ce5ab06627a0ee7894c0e89a62a4a7a4b1
[]
no_license
prodigasistemas/gsan
ad64782c7bc991329ce5f0bf5491c810e9487d6b
bfbf7ad298c3c9646bdf5d9c791e62d7366499c1
refs/heads/master
2023-08-31T10:47:21.784105
2023-08-23T17:53:24
2023-08-23T17:53:24
14,600,520
19
20
null
2015-07-29T19:39:10
2013-11-21T21:24:16
Java
ISO-8859-2
Java
false
false
3,401
java
package gcom.gui.cadastro.sistemaparametro; import gcom.cadastro.geografico.Municipio; import gcom.cadastro.geografico.MunicipioFeriado; import gcom.cadastro.sistemaparametro.NacionalFeriado; import gcom.fachada.Fachada; import gcom.gui.ActionServletException; import gcom.gui.GcomAction; import gcom.seguranca.acesso.usuario.Usuario; import gcom.util.filtro.ParametroSimples; import gcom.util.tabelaauxiliar.abreviada.FiltroTabelaAuxiliarAbreviada; import java.util.Collection; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpSession; import org.apache.struts.action.ActionForm; import org.apache.struts.action.ActionForward; import org.apache.struts.action.ActionMapping; /** * [UC0534] INSERIR FERIADO * * @author Kássia Albuquerque * @date 12/01/2007 */ public class InserirFeriadoAction extends GcomAction { public ActionForward execute(ActionMapping actionMapping, ActionForm actionForm, HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse) { ActionForward retorno = actionMapping.findForward("telaSucesso"); InserirFeriadoActionForm inserirFeriadoActionForm = (InserirFeriadoActionForm) actionForm; HttpSession sessao = httpServletRequest.getSession(false); Fachada fachada = Fachada.getInstancia(); String municipio = inserirFeriadoActionForm.getIdMunicipio(); Usuario usuarioLogado = (Usuario)sessao.getAttribute(Usuario.USUARIO_LOGADO); if (municipio != null && !municipio.trim().equals("")) { FiltroTabelaAuxiliarAbreviada filtroMunicipio = new FiltroTabelaAuxiliarAbreviada(); filtroMunicipio.adicionarParametro(new ParametroSimples(FiltroTabelaAuxiliarAbreviada.ID, municipio)); Collection colecaoMunicipio = fachada.pesquisar(filtroMunicipio, Municipio.class.getName()); if (colecaoMunicipio == null || colecaoMunicipio.isEmpty()) { inserirFeriadoActionForm.setIdMunicipio(""); throw new ActionServletException("atencao.municipio_inexistente"); } } MunicipioFeriado municipioFeriado = null; NacionalFeriado nacionalFeriado = null; String nomeFeriado = null; String tipoFeriado = null; if (municipio != null && !municipio.trim().equals("")) { municipioFeriado = new MunicipioFeriado(); inserirFeriadoActionForm.setFormValuesMunicipal( municipioFeriado); nomeFeriado= "Municipal"; tipoFeriado= "2"; } else { nacionalFeriado = new NacionalFeriado(); inserirFeriadoActionForm.setFormValuesNacional( nacionalFeriado); nomeFeriado = "Nacional"; tipoFeriado= "1"; } //Inserir na base de dados Feriado Integer idFeriado = fachada.inserirFeriado(nacionalFeriado, municipioFeriado,usuarioLogado); sessao.setAttribute("caminhoRetornoVoltar", "/gsan/exibirFiltrarFeriadoAction.do"); //Monta a página de sucesso montarPaginaSucesso(httpServletRequest, "Feriado "+ nomeFeriado + " de código " + idFeriado +" inserido com sucesso.", "Inserir outro Feriado","exibirInserirFeriadoAction.do?menu=sim", "exibirAtualizarFeriadoAction.do?tipoFeriado="+tipoFeriado+"&idRegistroInseridoAtualizar="+ idFeriado,"Atualizar Feriado Inserido"); sessao.removeAttribute("InserirFeriadoActionForm"); return retorno; } }
[ "piagodinho@gmail.com" ]
piagodinho@gmail.com
ce06e9f402636d3b846e6a9ccc24f5034dff34ac
8f19df08fbbb2848193bfaf83b6e945111fc9725
/Samsung/SM-E500H - Galaxy E5 Duos.java
6862a8d2ddcb25db3c2a4af7d2fbd80d90b79557
[]
no_license
4val0v/DualSim-Methods-of-class-TelephonyManager
4b79b30a2555477e8a5693fd4b0a6d2966e3d2c6
c8efca563f19c3a254ee1f71d74e83e02b39bbee
refs/heads/master
2021-01-13T13:00:50.289504
2015-08-26T19:28:49
2015-08-26T19:28:49
36,025,314
4
1
null
null
null
null
UTF-8
Java
false
false
5,919
java
Manufacturer = samsung; Model = SM-E500H; Version = 19 void addCallStateListener(android.telephony.CallStateListener) void answerRingingCall() java.lang.String calculateAkaResponse([B,[B) android.telephony.TelephonyManager$GbaBootstrappingResponse calculateGbaBootstrappingResponse([B,[B) [B calculateNafExternalKey([B) void call(java.lang.String,java.lang.String) void cancelMissedCallsNotification() boolean closeLockChannel(int) void dial(java.lang.String) int disableApnType(java.lang.String) boolean disableDataConnectivity() void disableLocationUpdates() int enableApnType(java.lang.String) boolean enableDataConnectivity() void enableLocationUpdates() boolean endCall() java.lang.String feliCaUimLock(int,[I,java.lang.String) java.util.List getAllCellInfo() java.lang.String getBtid() int getCallState() int getCdmaEriIconIndex() int getCdmaEriIconMode() java.lang.String getCdmaEriText() android.telephony.CellLocation getCellLocation() java.lang.String getCompleteVoiceMailNumber() int getCurrentPhoneType() int getDataActivity() int getDataNetworkType() boolean getDataRoamingEnabled() int getDataServiceState() int getDataState() int getDataStateDs(int) java.lang.String getDeviceId() java.lang.String getDeviceSoftwareVersion() int getFeliCaUimLockStatus(int) java.lang.String getGroupIdLevel1() com.android.internal.telephony.ITelephony getITelephony() java.lang.String getImeiInCDMAGSMPhone() java.lang.String getIsimAid() java.lang.String getIsimDomain() java.lang.String getIsimImpi() [Ljava.lang.String; getIsimImpu() [Ljava.lang.String; getIsimPcscf() java.lang.String getKeyLifetime() java.util.HashMap getLGUplusKnightInfo() java.lang.String getLine1AlphaTag() java.lang.String getLine1Number() java.lang.String getLine1NumberType(int) int getLteOnCdmaMode() java.lang.String getMmsUAProfUrl() java.lang.String getMmsUserAgent() java.util.HashMap getMobileQualityInformation() java.lang.String getMsisdn() java.util.List getNeighboringCellInfo() java.lang.String getNetworkCountryIso() java.lang.String getNetworkOperator() java.lang.String getNetworkOperatorName() int getNetworkType() java.lang.String getNetworkTypeName() int getPhoneType() int getPhoneTypeForIMS() int getPhoneTypeFromNetworkType() int getPhoneTypeFromProperty() [B getPsismsc() [B getRand() boolean getSdnAvailable() int getServiceState() java.lang.String getSimCountryIso() java.lang.String getSimOperator() java.lang.String getSimOperatorName() java.lang.String getSimSerialNumber() int getSimState() int getSimStateDs(int) [Ljava.lang.String; getSponImsi() java.lang.String getSubscriberId() java.lang.String getSubscriberIdDm(int) java.lang.String getSubscriberIdType(int) com.android.internal.telephony.IPhoneSubInfo getSubscriberInfo() java.lang.String getVoiceMailAlphaTag() java.lang.String getVoiceMailNumber() int getVoiceMessageCount() int getVoiceNetworkType() boolean handlePinMmi(java.lang.String) boolean hasCall(java.lang.String) boolean hasIccCard() boolean hasIsim() boolean isDataConnectivityPossible() boolean isExtraCapable(int) boolean isGbaSupported() boolean isIdle() boolean isNetworkRoaming() boolean isNetworkRoamingDs(int) boolean isOffhook() boolean isRadioOn() boolean isRinging() boolean isSimPinEnabled() boolean isSmoveripSupported() boolean isSmsCapable() boolean isVoiceCapable() boolean isdialingEmergencycall() void listen(android.telephony.PhoneStateListener,int) void listenDs(int,android.telephony.PhoneStateListener,int) void merge() void mute(boolean) boolean needsOtaServiceProvisioning() [B oem_ssa_alarm_event([B) [I oem_ssa_check_mem() [B oem_ssa_get_data() [B oem_ssa_hdv_alarm_event([B) [B oem_ssa_set_event([B) [B oem_ssa_set_log([B,[B) boolean oem_ssa_set_mem(int) int openLockChannel(java.lang.String) void playDtmfTone(char,boolean) void removeCallStateListener(android.telephony.CallStateListener) void requestAuthForMediaShare(java.lang.String) void requestIsimAuthentication(java.lang.String) void requestUsimAuthentication(java.lang.String) void setCellInfoListRate(int) void setDataRoamingEnabled(boolean) void setGbaBootstrappingParams([B,java.lang.String,java.lang.String) void setPcoValue(int) boolean setRadio(boolean) boolean setRadioPower(boolean) int setUimRemoteLockStatus(int) boolean showCallScreen() boolean showCallScreenWithDialpad(boolean) void silenceRinger() void startMobileQualityInformation() void stopDtmfTone() void stopMobileQualityInformation() boolean supplyPin(java.lang.String) [I supplyPinReportResult(java.lang.String) boolean supplyPuk(java.lang.String,java.lang.String) [I supplyPukReportResult(java.lang.String,java.lang.String) void swap() void toggleHold() void toggleRadioOnOff() java.lang.String transmitLockChannel(int,int,int,int,int,int,java.lang.String) [B uknight_event_set([B) [B uknight_get_data() [B uknight_log_set([B) [I uknight_mem_check() boolean uknight_mem_set(int) boolean uknight_state_change_set(int) void updateServiceLocation() int ByteToInt([B) boolean IsCDMAmessage() android.telephony.TelephonyManager from(android.content.Context) android.telephony.TelephonyManager getDefault() int getDefaultSubscription() android.telephony.TelephonyManager getFirst() com.android.internal.telephony.ITelephonyExt getITelephonyExt() int getLteOnCdmaModeStatic() int getNetworkClass(int) java.lang.String getNetworkTypeName(int) int getPhoneType(int) java.lang.String getProcCmdLine() java.lang.String getRoamingUserAgent(java.lang.String,java.lang.String) android.telephony.TelephonyManager getSecondary() char getServiceUserAgent() java.lang.String getSktImsiM() java.lang.String getSktIrm() int getSystemPreferredNetworkMode() java.lang.String getTelephonyProperty(java.lang.String,int,java.lang.String) java.lang.String getUAField() [B intToByteArray(int) boolean isSelectTelecomDF() boolean isWIFIConnected() [B stringToByte(java.lang.String) boolean validateAppSignatureForPackage(android.content.Context,java.lang.String)
[ "andrej.chvalov@gmail.com" ]
andrej.chvalov@gmail.com
c2a625462fd17cee0683f5301a812615d752101f
2e47ada16f8a7f91021a19db7f41e8ba524041fa
/envs/se/src/main/java/io/astefanutti/metrics/cdi/se/ExceptionMeteredClassBean.java
c5313e30cad60c71060ebda3671f0063d6f5b30e
[ "Apache-2.0", "LicenseRef-scancode-unknown-license-reference" ]
permissive
astefanutti/metrics-cdi
1fd28def5f78a2d2ed861753ddf51a81d03eeee9
d14cc3a3e54d2be77cdffd0f1cec40db1e7e52e7
refs/heads/master
2023-08-13T23:34:05.158775
2021-12-18T18:17:44
2021-12-20T09:05:06
13,719,326
69
25
Apache-2.0
2021-12-20T09:05:07
2013-10-20T13:15:52
Java
UTF-8
Java
false
false
1,357
java
/** * Copyright © 2013 Antonin Stefanutti (antonin.stefanutti@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 io.astefanutti.metrics.cdi.se; import com.codahale.metrics.annotation.ExceptionMetered; @ExceptionMetered(name = "exceptionMeteredClass", cause = IllegalArgumentException.class) public class ExceptionMeteredClassBean { public void exceptionMeteredMethodOne(Runnable runnable) { runnable.run(); } public void exceptionMeteredMethodTwo(Runnable runnable) { runnable.run(); } protected void exceptionMeteredMethodProtected(Runnable runnable) { runnable.run(); } void exceptionMeteredMethodPackagedPrivate(Runnable runnable) { runnable.run(); } private void exceptionMeteredMethodPrivate(Runnable runnable) { runnable.run(); } }
[ "antonin@stefanutti.fr" ]
antonin@stefanutti.fr
efcde26eeb4f3a022af5f34a7132a7f2bce96641
844f94eaa9701b937f3e782d6a491ba490f3aea6
/util/src/main/java/com/alibaba/china/courier/fastjson/serializer/ByteSerializer.java
bae703171d7ce5745d9fd1068b2b146cec0b15b2
[]
no_license
sitelabs/courier
70c3f75e133635c6df39c2385b92464f3be8b8fc
6a4f2a8c632051ffee47259cec615d3ef7c859cf
refs/heads/master
2016-08-03T12:31:38.214784
2013-08-07T02:31:49
2013-08-07T02:31:49
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,604
java
/* * Copyright 1999-2101 Alibaba Group. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.alibaba.china.courier.fastjson.serializer; import java.io.IOException; import java.lang.reflect.Type; /** * @author wenshao<szujobs@hotmail.com> */ public class ByteSerializer implements ObjectSerializer { public static ByteSerializer instance = new ByteSerializer(); public void write(JSONSerializer serializer, Object object, Object fieldName, Type fieldType) throws IOException { SerializeWriter out = serializer.getWriter(); Number numberValue = (Number) object; if (numberValue == null) { if (out.isEnabled(SerializerFeature.WriteNullNumberAsZero)) { out.write('0'); } else { out.writeNull(); } return; } short value = ((Number) object).shortValue(); out.writeInt(value); if (serializer.isEnabled(SerializerFeature.WriteClassName)) { out.write('B'); } } }
[ "yingjun.jiaoyj@alibaba-inc.com" ]
yingjun.jiaoyj@alibaba-inc.com
7f022b005998266d989bc467e9df6f2142b1ef54
7ffda65693460972b2956120cd88480afe99338e
/AvaliacaoIndividual/tacocat/Jogo.java
0daba49e05b5cee3246b1c2371c2e0f55a411fb6
[]
no_license
dariomousinho/POOUFF
b2e6012befc6228c71534bdfb9483ba252af3fbb
4865d4a891a74d9580cbe699e31cbba931eab1c4
refs/heads/main
2023-04-30T23:41:18.018400
2021-05-10T23:53:38
2021-05-10T23:53:38
null
0
0
null
null
null
null
UTF-8
Java
false
false
4,360
java
package tacocat; import java.awt.Canvas; import java.awt.Graphics; import java.awt.image.BufferStrategy; import java.awt.image.BufferedImage; import java.io.File; import java.io.IOException; import java.util.Random; import java.util.logging.Level; import java.util.logging.Logger; import javax.imageio.ImageIO; public class Jogo extends Canvas implements Runnable{ //Altura e Largura da janela public static final int W = 490; public static final int H = 600; private Thread thread; private boolean rodando = false; private Ajudante ajudante; private HUD hud; private Random r; private CriarInimigos cria; private Menu menu; private ExplosaoDosInimigos explosao; //Janelas do jogo public enum ESTADO{ Jogo, Help, GameOver, Menu, Score }; BufferedImage fundo; public ESTADO estadoJogo = ESTADO.Menu; //Construtor public Jogo() throws IOException{ File file = new File(""); this.fundo = ImageIO.read(new File(file.getAbsoluteFile()+"\\src\\tacocat\\Sprites\\tacocatFundo.png")); Janela j = new Janela(W, H, "TacoCat", this); ajudante = new Ajudante(); menu = new Menu(this, ajudante,j); r = new Random(); this.addKeyListener(new Teclado(ajudante)); this.addMouseListener(new Mouse(ajudante, this)); hud = new HUD(this, menu); cria = new CriarInimigos(ajudante,hud); explosao = new ExplosaoDosInimigos(ajudante, hud); } //Começa o jogo public synchronized void start(){ thread = new Thread(this); thread.start(); rodando = true; } //Pausa o jogo public synchronized void stop(){ try { thread.join(); rodando = false; } catch (InterruptedException ex) { Logger.getLogger(Jogo.class.getName()).log(Level.SEVERE, null, ex); } } //Gameloop @Override public void run() { this.requestFocus(); long lastTime = System.nanoTime(); double amountOfTicks = 60.0; double ns = 1000000000 / amountOfTicks; double delta = 0; long timer = System.currentTimeMillis(); int frames = 0; while(rodando){ long now = System.nanoTime(); delta += (now - lastTime) / ns; lastTime = now; while(delta >= 1){ tick(); delta--; } if(rodando){ render(); } frames++; if(System.currentTimeMillis() - timer > 1000){ timer += 1000; System.out.println("FPS: " + frames); frames = 0; } } stop(); } //O que roda todo frame private void tick() { ajudante.tick(); if(estadoJogo == ESTADO.Jogo){ hud.tick(); try{ cria.tick(); }catch(IOException e){ System.out.println("Erro"); } explosao.tick(); } else if(estadoJogo == ESTADO.Menu){ menu.tick(); } } //O que renderiza as imagens private void render() { BufferStrategy bs = this.getBufferStrategy(); if(bs == null){ this.createBufferStrategy(3); return; } Graphics g = bs.getDrawGraphics(); g.drawImage(this.fundo, 0, 0, null); ajudante.render(g); if(estadoJogo == ESTADO.Jogo){ hud.render(g); } else if(estadoJogo == ESTADO.Menu || estadoJogo == ESTADO.Help || estadoJogo == ESTADO.GameOver || estadoJogo == ESTADO.Score){ try{ menu.render(g); }catch(IOException except){ System.out.println("erro"); } } g.dispose(); bs.show(); } //NÃO ULTRAPASSAR A BORDA DO JOGO public static int limiteResolucao(int var, int min, int max){ if(var >= max){ return var = max; }else if(var <= min){ return var = min; }else{ return var; } } }
[ "noreply@github.com" ]
dariomousinho.noreply@github.com
a74db48523d7cfe0a4888d0982b6cd1533f4584c
46879d77dedace08a1028984d9418674cb247de5
/danaa/src/main/java/com/kh/danaa/review/model/service/ReviewServiceImpl.java
42ed4bc83499a915646f32c3a6b5323f15ccda74
[]
no_license
jshan0324/danaa
118e7a36635969941f18c4400fd80bc4856b96d2
92d2f502024e78cf1fd08b7c81c90e21c9d10bb2
refs/heads/main
2022-12-24T15:29:06.724227
2020-10-15T16:20:59
2020-10-15T16:20:59
303,675,060
0
1
null
2020-10-13T12:05:31
2020-10-13T11:04:38
Java
UTF-8
Java
false
false
1,774
java
package com.kh.danaa.review.model.service; import java.util.ArrayList; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import com.kh.danaa.review.model.dao.ReviewDao; import com.kh.danaa.review.model.vo.Review; @Service("reviewService") public class ReviewServiceImpl implements ReviewService { @Autowired private ReviewDao reviewDao; @Override public Review selectReview(int review_no) { return reviewDao.selectReview(review_no); } @Override public ArrayList<Review> selectList(int currentPage, int limit) { return reviewDao.selectList(currentPage, limit); } @Override public ArrayList<Review> selectTop3() { return reviewDao.selectTop3(); } @Override public int selectListCount() { return reviewDao.selectListCount(); } @Override public int insertOriginReview(Review review) { return reviewDao.insertOriginReview(review); } @Override public int updateReview(Review review) { return reviewDao.updateReview(review); } @Override public int deleteReview(Review review) { return reviewDao.deleteReview(review); } @Override public int updateReadCount(int review_no) { return reviewDao.updateReadCount(review_no); } @Override public ArrayList<Review> selectSearchtitle(String keyword) { return reviewDao.selectSearchtitle(keyword); } @Override public ArrayList<Review> selectSearchcontent(String keyword) { return reviewDao.selectSearchcontent(keyword); } @Override public ArrayList<Review> selectList() { return reviewDao.selectList(); } @Override public ArrayList<Review> selectDetail(int review_no) { return reviewDao.selectDetail(review_no); } @Override public int selectReviewCount() { return reviewDao.selectReviewCount(); } }
[ "72724229+jshan0324@users.noreply.github.com" ]
72724229+jshan0324@users.noreply.github.com
acb235e8e3ef885c372f1bba61143a7132f2a945
d523206fce46708a6fe7b2fa90e81377ab7b6024
/com/google/android/gms/internal/zzfl.java
967f29129eb5e25aa1a4e4bec07d44239e229fb5
[]
no_license
BlitzModder/BlitzJava
0ee94cc069dc4b7371d1399ff5575471bdc88aac
6c6d71d2847dfd5f9f4f7c716cd820aeb7e45f2c
refs/heads/master
2021-06-11T15:04:05.571324
2017-02-04T16:04:55
2017-02-04T16:04:55
77,459,517
1
2
null
null
null
null
UTF-8
Java
false
false
3,616
java
package com.google.android.gms.internal; import android.app.AlertDialog; import android.app.AlertDialog.Builder; import android.content.Context; import android.content.DialogInterface; import android.content.DialogInterface.OnClickListener; import android.content.Intent; import android.provider.CalendarContract.Events; import android.text.TextUtils; import com.google.android.gms.R.string; import com.google.android.gms.ads.internal.zzp; import java.util.Map; @zzha public class zzfl extends zzfr { private final Context mContext; private String zzBU; private long zzBV; private long zzBW; private String zzBX; private String zzBY; private final Map<String, String> zzxc; public zzfl(zzjn paramzzjn, Map<String, String> paramMap) { super(paramzzjn, "createCalendarEvent"); this.zzxc = paramMap; this.mContext = paramzzjn.zzhx(); zzez(); } private String zzai(String paramString) { if (TextUtils.isEmpty((CharSequence)this.zzxc.get(paramString))) { return ""; } return (String)this.zzxc.get(paramString); } private long zzaj(String paramString) { paramString = (String)this.zzxc.get(paramString); if (paramString == null) { return -1L; } try { long l = Long.parseLong(paramString); return l; } catch (NumberFormatException paramString) {} return -1L; } private void zzez() { this.zzBU = zzai("description"); this.zzBX = zzai("summary"); this.zzBV = zzaj("start_ticks"); this.zzBW = zzaj("end_ticks"); this.zzBY = zzai("location"); } Intent createIntent() { Intent localIntent = new Intent("android.intent.action.EDIT").setData(CalendarContract.Events.CONTENT_URI); localIntent.putExtra("title", this.zzBU); localIntent.putExtra("eventLocation", this.zzBY); localIntent.putExtra("description", this.zzBX); if (this.zzBV > -1L) { localIntent.putExtra("beginTime", this.zzBV); } if (this.zzBW > -1L) { localIntent.putExtra("endTime", this.zzBW); } localIntent.setFlags(268435456); return localIntent; } public void execute() { if (this.mContext == null) { zzal("Activity context is not available."); return; } if (!zzp.zzbx().zzN(this.mContext).zzdi()) { zzal("This feature is not available on the device."); return; } AlertDialog.Builder localBuilder = zzp.zzbx().zzM(this.mContext); localBuilder.setTitle(zzp.zzbA().zzf(R.string.create_calendar_title, "Create calendar event")); localBuilder.setMessage(zzp.zzbA().zzf(R.string.create_calendar_message, "Allow Ad to create a calendar event?")); localBuilder.setPositiveButton(zzp.zzbA().zzf(R.string.accept, "Accept"), new DialogInterface.OnClickListener() { public void onClick(DialogInterface paramAnonymousDialogInterface, int paramAnonymousInt) { paramAnonymousDialogInterface = zzfl.this.createIntent(); zzp.zzbx().zzb(zzfl.zza(zzfl.this), paramAnonymousDialogInterface); } }); localBuilder.setNegativeButton(zzp.zzbA().zzf(R.string.decline, "Decline"), new DialogInterface.OnClickListener() { public void onClick(DialogInterface paramAnonymousDialogInterface, int paramAnonymousInt) { zzfl.this.zzal("Operation denied by user."); } }); localBuilder.create().show(); } } /* Location: /Users/subdiox/Downloads/dex2jar-2.0/net.wargaming.wot.blitz-dex2jar.jar!/com/google/android/gms/internal/zzfl.class * Java compiler version: 6 (50.0) * JD-Core Version: 0.7.1 */
[ "subdiox@gmail.com" ]
subdiox@gmail.com
f6cb6fe7e7af578ccd5407d7b2c93a7c3ca46565
d4b09ebae1da8dcfa9e7604af691cddd56c71cc2
/src/test/java/com/psr/TestCases/test1.java
7e4e82888d25b05878800e7e7cf545472d015400
[]
no_license
Shalini-BR/Retelzy_PSR
a577a859976c7982a05f1360107bd0e87a2ccb6c
41e68ae09f00a56119a46788ff15fa53dd87921e
refs/heads/master
2023-03-18T08:50:29.472313
2021-03-12T05:32:23
2021-03-12T05:32:23
346,945,839
0
0
null
null
null
null
UTF-8
Java
false
false
5,904
java
package com.psr.TestCases; import org.testng.annotations.Test; import org.testng.annotations.Test; import org.testng.annotations.Test; import static org.testng.Assert.expectThrows; import java.awt.AWTException; import java.awt.Robot; import java.awt.event.KeyEvent; import java.io.FileInputStream; import java.io.IOException; import java.util.ArrayList; import java.util.LinkedHashMap; import java.util.List; import org.apache.poi.ss.usermodel.DataFormatter; import org.apache.poi.ss.usermodel.Row; import org.apache.poi.xssf.usermodel.XSSFSheet; import org.apache.poi.xssf.usermodel.XSSFWorkbook; import org.openqa.selenium.By; import org.openqa.selenium.Keys; import org.openqa.selenium.WebDriver; import org.openqa.selenium.WebElement; import org.openqa.selenium.interactions.Action; import org.openqa.selenium.interactions.Actions; import org.openqa.selenium.support.ui.ExpectedConditions; import org.openqa.selenium.support.ui.WebDriverWait; import org.testng.annotations.Test; import org.testng.asserts.SoftAssert; import com.psr.Locators.Xpath; import com.psr.PageObject.BaseClass; import com.psr.PageObject.Library; public class test1 extends BaseClass { @Test public void Editable() throws InterruptedException, IOException, AWTException { WebDriverWait wait = new WebDriverWait(driver, 100); SoftAssert sa = new SoftAssert(); try { wait.until(ExpectedConditions.visibilityOfElementLocated(By.xpath("//*[@id='search-fields-from']"))).click(); WebElement scrillInside = wait.until(ExpectedConditions.visibilityOfElementLocated(By.xpath("//*[@id='container']/div/app-staticpsr/div[3]/jqxgrid/div"))); String jqxGridId = scrillInside.getAttribute("id"); FileInputStream fis = new FileInputStream("./data/Values.xlsx"); XSSFWorkbook workbook = new XSSFWorkbook(fis); XSSFSheet sheet = workbook.getSheetAt(1); DataFormatter format = new DataFormatter(); for (Row myrow : sheet) { int i = 0; Thread.sleep(1000); WebElement element = driver.findElement(By.xpath("//*[@id='dropdownscroll']/div/div[2]/span")); element.click(); List<WebElement> suggestion = driver.findElements( By.xpath("//ul[@role = 'menu']//li//descendant::div[@class='ui-select-choices-row']")); String firstCellValue = format.formatCellValue(myrow.getCell(i)); for (WebElement suggest : suggestion) { if (suggest.getText().trim().equalsIgnoreCase(format.formatCellValue(myrow.getCell(i)))) { System.out.println(suggest.getText() + " equals " + myrow.getCell(i).getStringCellValue()); Thread.sleep(1000); suggest.click(); break; } } Thread.sleep(1000); runCopyPaste(driver, jqxGridId, format.formatCellValue(myrow.getCell(++i)), format.formatCellValue(myrow.getCell(++i)), firstCellValue); } } catch (Exception e) { System.out.println(e.getMessage()); } } public static void runCopyPaste(WebDriver driver, String jqxGridId, String string, Object object, String header) throws InterruptedException, IOException, AWTException { Robot robot = new Robot(); WebDriverWait wait = new WebDriverWait(driver, 100); List<String> sendKeysList = new ArrayList(); try { for (int i = 0; i < 1; i++) { // int i = 0; i < 3; i++ Actions a = new Actions(driver); WebElement ndc = wait.until(ExpectedConditions.visibilityOfElementLocated( By.xpath("//*[@id='row" + i + jqxGridId + "']/div[" + string + "]"))); a.doubleClick(ndc); if (checkHeader(header, "Tech Pack Received Date") || checkHeader(header, "packaging ready date") || checkHeader(header, "fabric pp date") || checkHeader(header, "fabric pp date") || checkHeader(header, "cpo acc date by vendor") || checkHeader(header, "sample merch eta") || checkHeader(header, "sample floor set eta") || checkHeader(header, "sample dcom eta") || checkHeader(header, "sample mailer eta") || checkHeader(header, "Photo/Merchant Sample Send date") || checkHeader(header, "Photo/Merchant Sample ETA date")|| checkHeader(header, "Photo/Merchant Sample Send date") || checkHeader(header, "Marketing Sample Send date") || checkHeader(header, "Marketing Sample ETA date") || checkHeader(header, "Visual Sample Send date") || checkHeader(header, "Visual Sample ETA date") || checkHeader(header, "Copyright Sample Send date") || checkHeader(header, "Copyright Sample ETA date") || checkHeader(header, "Additional Bulk Lot Approve") || checkHeader(header, "TOP sample ETA Date")) { a.click(ndc).keyDown(Keys.CONTROL).sendKeys("a").keyUp(Keys.CONTROL); a.sendKeys(ndc, object.toString()); } else { a.click(ndc).keyDown(Keys.CONTROL).sendKeys("a").keyUp(Keys.CONTROL); a.sendKeys(ndc, object.toString() + i + "1"); } a.release(); a.perform(); sendKeysList.add(object.toString()); Thread.sleep(1000); } driver.findElement(By.xpath("//*[@id='save-changes-psr']")).click(); Thread.sleep(10000); for (int i = 0; i < 1; i++) { Actions a = new Actions(driver); WebElement ndc = wait.until(ExpectedConditions.visibilityOfElementLocated( By.xpath("//*[@id='row" + i + jqxGridId + "']/div[" + string + "]"))); String s = ndc.getText(); System.out.println(s); /* Library.Interaction.click(Xpath.ReCalc.SelectRow); Library.Interaction.click(Xpath.ChangeTrack.ChangeTrackB); Library.Interaction.click(Xpath.ChangeTrack.Clickfirstoption("Feb 27 2020")); s = Xpath.ChangeTrack.data; if(s.contains("Top01")) System.out.println("Change Track successful"); break;*/ } } catch (Exception e) { System.out.println(e.getMessage()); } } public static boolean checkHeader(String header, String value) { return header.trim().equalsIgnoreCase(value); } }
[ "Shainidigital7@gmail.com" ]
Shainidigital7@gmail.com
5da4d54a09788e75ab9dfa116f6f6a04cc3f9ed1
93a82eebc89db6e905bb52505870be1cc689566d
/viewdemo/baseutils/src/androidTest/java/com/zero/baseutils/ExampleInstrumentedTest.java
f5bd68d74e664a2c84688672630a3a55e68bfd84
[]
no_license
zcwfeng/zcw_android_demo
78cdc86633f01babfe99972b9fde52a633f65af9
f990038fd3643478dbf4f65c03a70cd2f076f3a0
refs/heads/master
2022-07-27T05:32:09.421349
2022-03-14T02:56:41
2022-03-14T02:56:41
202,998,648
15
8
null
null
null
null
UTF-8
Java
false
false
784
java
package com.zero.baseutils; import android.content.Context; import androidx.test.platform.app.InstrumentationRegistry; import androidx.test.ext.junit.runners.AndroidJUnit4; import org.junit.Test; import org.junit.runner.RunWith; import static org.junit.Assert.*; /** * Instrumented test, which will execute on an Android device. * * @see <a href="http://d.android.com/tools/testing">Testing documentation</a> */ @RunWith(AndroidJUnit4.class) public class ExampleInstrumentedTest { @Test public void useAppContext() { // Context of the app under test. Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext(); assertEquals("com.zero.baseutils.test", appContext.getPackageName()); } }
[ "zcwfeng@126.com" ]
zcwfeng@126.com
9083032b13b878275ea18faac9b0c1779819cd86
47f8505fc7be7c9db8c12c0b29c08d7f0fb918d4
/src/main/java/com/gyoomi/ConvertSortedListtoBinarySearchTree/Solution.java
69d86903dfb777f490b619fcc66811fcdc17e545
[]
no_license
gyoomi/leetcode
83384c9344bd24cb34cfd4772b24457e407714c8
b2f19bafe5e3bb897fa7a56aaaf6a94976e762ff
refs/heads/master
2020-05-24T10:53:54.393113
2019-12-20T10:27:15
2019-12-20T10:27:15
187,236,700
0
1
null
null
null
null
UTF-8
Java
false
false
1,221
java
/** * Copyright © 2019, Glodon Digital Supplier BU. * <p> * All Rights Reserved. */ package com.gyoomi.ConvertSortedListtoBinarySearchTree; import java.util.ArrayList; import java.util.List; /** * The description of class * * @author Leon * @date 2019-10-17 9:09 */ public class Solution { public TreeNode sortedListToBST(ListNode head) { ArrayList<Integer> list = new ArrayList<>(); while (head != null) { list.add(head.val); head = head.next; } return convertListToTree(list, 0, list.size()); } private TreeNode convertListToTree(List<Integer> list, int l, int r) { if (l >= r) { return null; } int mid = (l + r) / 2; TreeNode root = new TreeNode(list.get(mid)); root.left = convertListToTree(list, l, mid); root.right = convertListToTree(list, mid + 1, r); return root; } public class ListNode { int val; ListNode next; ListNode(int x) { val = x; } } public class TreeNode { int val; TreeNode left; TreeNode right; TreeNode(int x) { val = x; } } }
[ "gyoomi0709@foxmail.com" ]
gyoomi0709@foxmail.com
c81f49bbfeceb43ae81690babee43c2e4249a259
aa9d55d0e3f522c2329c952da3d8cd6811708813
/src/main/java/com/bookstore/service/impl/BookStoreServiceImpl.java
56e09f1389c7e805ff7b96c58f7df22e15cb0afe
[]
no_license
naushad3210/bookstore
1cbd9b842b14216595faf3c3ab64aa755e9152bf
da164deb6bb7cbf645aad22c6977422abc523433
refs/heads/master
2020-04-06T15:17:41.408397
2018-11-15T08:26:26
2018-11-15T08:26:26
157,572,894
0
0
null
null
null
null
UTF-8
Java
false
false
5,171
java
package com.bookstore.service.impl; import java.util.ArrayList; import java.util.List; import java.util.stream.Collectors; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.BeanUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.core.ParameterizedTypeReference; import org.springframework.http.HttpMethod; import org.springframework.http.HttpStatus; import org.springframework.http.ResponseEntity; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import org.springframework.web.client.RestTemplate; import com.bookstore.dao.BookStoreDAO; import com.bookstore.domain.BookDetails; import com.bookstore.dto.request.BookStoreRequestDto; import com.bookstore.dto.response.MediaCoverageResponseDto; import com.bookstore.exceptions.ThirdPartyApiException; import com.bookstore.exceptions.RecordNotFoundException; import com.bookstore.service.IBookStoreService; /** * @author mohammadnaushad * */ @Service("bookStoreService") public class BookStoreServiceImpl implements IBookStoreService { private static final Logger LOGGER = LoggerFactory.getLogger(BookStoreServiceImpl.class); @Autowired BookStoreDAO bookStoreDao; @Autowired RestTemplate restTemplate; @Autowired Environment env; @Override @Transactional public BookDetails addBook(BookStoreRequestDto bookStoreDto) { LOGGER.info("-- Inside [BookStoreServiceImpl] [Method: addBook()] with [Data:{}]",bookStoreDto); BookDetails bookDetails = new BookDetails(); BeanUtils.copyProperties(bookStoreDto, bookDetails); return bookStoreDao.persistBookStore(bookDetails); } @Override @Transactional public List<BookDetails> getBook(String searchField, String searchValue) { LOGGER.info("-- Inside [BookStoreServiceImpl] [Method: getBook()] with [Data:{} = {} ",searchField,searchValue); List<BookDetails> bookDetailsList = bookStoreDao.getBookDetails(); List<BookDetails> bookDetails = new ArrayList<>(); if(searchField.equalsIgnoreCase("author")) { bookDetails = bookDetailsList.stream() .filter(book -> book.getAuthor().toUpperCase() .contains(searchValue.toUpperCase())) .collect(Collectors.toList()); } else if(searchField.equalsIgnoreCase("title")) { bookDetails = bookDetailsList.stream() .filter(book -> book.getTitle().toUpperCase() .contains(searchValue.toUpperCase())) .collect(Collectors.toList()); }else if(searchField.equalsIgnoreCase("isbn")) { bookDetails = bookDetailsList.stream() .filter(book -> book.getIsbn().toUpperCase() .equalsIgnoreCase(searchValue.toUpperCase())) .collect(Collectors.toList()); } if(bookDetails.isEmpty()) { LOGGER.info("Book details not present with {} = {}",searchField,searchValue); throw new RecordNotFoundException("Book",searchField,searchValue); } return bookDetails; } @Override @Transactional public List<MediaCoverageResponseDto> getMediaCoverage(String searchField, String searchValue) { LOGGER.info("-- Inside [BookStoreServiceImpl] [Method: getBook()] with [Data:{} = {} ",searchField,searchValue); BookDetails bookDetails = bookStoreDao.getBookDetailsByIsbn(searchValue); if(bookDetails!=null) { return getMediaCoverageFromApi(bookDetails,searchField,searchValue); }else { LOGGER.info("Book details not present with {} = {}",searchField,searchValue); throw new RecordNotFoundException("Book",searchField,searchValue); } } private List<MediaCoverageResponseDto> getMediaCoverageFromApi(BookDetails bookDetails,String searchField, String searchValue) { List<MediaCoverageResponseDto> mediaCovResponse = new ArrayList<>(); ResponseEntity<List<MediaCoverageResponseDto>> response = restTemplate.exchange(env.getProperty("media.coverage.api.uri"), HttpMethod.GET, null, new ParameterizedTypeReference<List<MediaCoverageResponseDto>>() {}); HttpStatus statusCode = response.getStatusCode(); LOGGER.info("Response Satus Code: {}", statusCode); if (statusCode == HttpStatus.OK) { List<MediaCoverageResponseDto> list = response.getBody(); if (!list.isEmpty()) { list.stream().filter(f->f.getTitle().toUpperCase().contains(bookDetails.getTitle().toUpperCase()) || f.getBody().toUpperCase().contains(bookDetails.getTitle().toUpperCase())) .forEach(media->{ MediaCoverageResponseDto dto = new MediaCoverageResponseDto(); dto.setTitle(media.getTitle()); mediaCovResponse.add(dto); }); } }else { LOGGER.info("Media Coverage Api Issue"); throw new ThirdPartyApiException("Media Coverage Api ", " [ http-code : " , statusCode+"]"); } if(mediaCovResponse.isEmpty()) { LOGGER.info("Media Coverage Not Found"); throw new RecordNotFoundException("Media Coverage",searchField,searchValue); } return mediaCovResponse; } }
[ "mohammad.naushad@nagarro.com" ]
mohammad.naushad@nagarro.com
04ec8b73a67e3fecc93b557f9931f64939699f96
ea123cdf55f741fb374d6c063f5a1116043c022e
/src/main/java/de/metroag/dto/PieceDTO.java
a650fc026d356a6119480a50e7161fea4bf2c32c
[]
no_license
asaad1882/tictactoe2
a2019d5a363bcf6623820a5e7de376b3bafc3285
afa676dc82426e792d9bfe1fcf982bc92af23c93
refs/heads/master
2021-07-24T20:23:53.543400
2017-11-05T20:58:15
2017-11-05T20:58:15
109,615,839
0
0
null
null
null
null
UTF-8
Java
false
false
233
java
package de.metroag.dto; public class PieceDTO { private String name; public String getName() { return name; } public void setName(String name) { this.name = name; } public PieceDTO(String name) { this.name=name; } }
[ "s_asmaa1982@hotmail.com" ]
s_asmaa1982@hotmail.com
54a850fc6ee3f4e5130a3d0e7c19ef36804a2226
1614eebcb2b1daa0f82a5683807f04ea77585ea1
/app/src/main/java/com/example/dell/myapplication/CallReceiver.java
f27c669b8a376d4e9bfb210eb2f4ae52d3cbaf06
[]
no_license
liyajuan1010/Broadcast
b78211988e912ed102a8a52c8f2e226b829cadd3
3394183d341f6dfd59e34366af80ccd2d74f33af
refs/heads/master
2021-04-06T09:09:05.063539
2018-03-10T11:28:50
2018-03-10T11:28:50
124,649,366
0
0
null
null
null
null
UTF-8
Java
false
false
1,425
java
package com.example.dell.myapplication; import android.app.Service; import android.content.BroadcastReceiver; import android.content.Context; import android.content.Intent; import android.telephony.TelephonyManager; import android.widget.Toast; //电话拦截 //new---JavaClass(选继承BroadcastReceiver) //在manifest中静态注册<receiver,还有用户权限的许可<user-permission //电话和短信属于危险权限,需要获得用户的许可 public class CallReceiver extends BroadcastReceiver { @Override public void onReceive(Context context, Intent intent) { //获取电话管理服务 TelephonyManager tm = (TelephonyManager) context .getSystemService(Service.TELEPHONY_SERVICE); switch (tm.getCallState()) { case TelephonyManager.CALL_STATE_RINGING://响铃 String incomingNumber = intent .getStringExtra("incoming_number"); Toast.makeText(context, "" + incomingNumber, Toast.LENGTH_LONG).show(); break; case TelephonyManager.CALL_STATE_OFFHOOK://接听电话 Toast.makeText(context, "接听电话", Toast.LENGTH_LONG).show(); break; case TelephonyManager.CALL_STATE_IDLE://挂断电话 Toast.makeText(context, "挂断电话", Toast.LENGTH_LONG).show(); break; } } }
[ "1334531538@qq.com" ]
1334531538@qq.com
c2682fab59987f41aa11a15653ec0df5b54f35a3
5c1562e2ed8c62623ddfa29ac46197841bfddbc9
/ztest-boot-mvc/src/main/java/com/ztest/boot/mvc/common/interceptor/PermissionInterceptor.java
4a1691cdb4d2f0fa1e465afdc85627633c0eb824
[]
no_license
pxiebray/boot-example
ef4c6566c56c08b92216bbb5ab16a46633838b56
91a255da0adf3e8a89d9bc3434c66f038a2ff0ec
refs/heads/master
2022-12-22T12:28:17.687669
2019-10-11T12:59:40
2019-10-11T12:59:40
144,964,719
0
0
null
2022-12-16T04:33:41
2018-08-16T09:12:12
Java
UTF-8
Java
false
false
2,097
java
package com.ztest.boot.mvc.common.interceptor; import com.ztest.boot.mvc.common.Permission; import org.springframework.util.StringUtils; import org.springframework.web.method.HandlerMethod; import org.springframework.web.servlet.handler.HandlerInterceptorAdapter; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import java.lang.reflect.Method; import java.util.concurrent.ConcurrentHashMap; /** * @author Administrator * @version 1.0 * @data 2018/7/6 0006 51 */ public class PermissionInterceptor extends HandlerInterceptorAdapter { public static final String NOT_PERMISSION_METHOD = "NPM"; private static final ConcurrentHashMap<Method, String> methodPermissionCache = new ConcurrentHashMap<>(); @Override public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler) throws Exception { if (handler instanceof HandlerMethod) { HandlerMethod handlerMethod = (HandlerMethod) handler; Method method = handlerMethod.getMethod(); // 方法解析 String permission = methodPermissionCache.get(method); if (null == permission) { Permission annotationPermission = method.getAnnotation(Permission.class); if (annotationPermission == null) { permission = NOT_PERMISSION_METHOD; } else { if (StringUtils.hasText(annotationPermission.value())) { permission = annotationPermission.value(); } else { permission = NOT_PERMISSION_METHOD; } } methodPermissionCache.put(method, permission); } // 校验 if (!NOT_PERMISSION_METHOD.equals(permission)) { // System.out.println("@Permission: check " + method.getName()); } else { // System.out.println("@Permission: unCheck " + method.getName()); } } return true; } }
[ "pxiebray@gmail.com" ]
pxiebray@gmail.com
219ca5f351bba458db6068cb9cdc59bb039c7219
81eabee2c23e654dfdff4388f6cd075ea26657d8
/oa/src/cn/edu/zhku/oa/model/ApproveInfo.java
5ce5a4a9a372f48747acc75abd3d6fcd1ed7b4d1
[]
no_license
cto1206/oa-1
db8e6048e45dfdc0c8778119cf38b4a91b93ef98
e12fae06b356124724d5dc6361be5adc0e935717
refs/heads/master
2021-01-15T21:02:21.694278
2012-04-26T16:20:44
2012-04-26T16:20:44
null
0
0
null
null
null
null
GB18030
Java
false
false
1,275
java
package cn.edu.zhku.oa.model; import java.util.Date; /** * 审批历史信息 * 作者:许权 * @hibernate.class table="t_approveInfo" */ public class ApproveInfo { /** * @hibernate.id * generator-class="native" */ private int id; /** * 审批意见 * @hibernate.property */ private String comment; /** * 审批时间 * @hibernate.property */ private Date approveTime; /** * 被审批的公文 * @hibernate.many-to-one */ private Document document; /** * 审批者 * @hibernate.many-to-one */ private User approver; public int getId() { return id; } public void setId(int id) { this.id = id; } public String getComment() { return comment; } public void setComment(String comment) { this.comment = comment; } public Date getApproveTime() { return approveTime; } public void setApproveTime(Date approveTime) { this.approveTime = approveTime; } public Document getDocument() { return document; } public void setDocument(Document document) { this.document = document; } public User getApprover() { return approver; } public void setApprover(User approver) { this.approver = approver; } }
[ "780391665@qq.com" ]
780391665@qq.com
2a58b4e9c24e62167da2b7e1df38e38ccb15336e
0c5c599d0cba9d756d8dae80121785826ed7deb4
/ExerciciosArray/Exercicio3.java
e980eef445456011993100fad1b2bf131acc71cd
[]
no_license
TiagoMarquess/aulas-java
87c92cb081a53dfd5ecf4660dd02674062a27582
e66ee2346d796ad81fac94889a6270da0abfd464
refs/heads/master
2020-12-06T06:59:51.229981
2020-01-07T17:19:29
2020-01-07T17:19:29
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,069
java
/* * Escreva um trecho Java que leia 10 valores double do teclado * e armazene-os num array d. */ /* * Programadores: Pedro Sol B Montes, Guilherme A. Dias * Data: 5/12/2019 */ import java.util.Scanner;//importando a classe scanner para pegar informações do usuário public class Exercicio3 { public static void main(String[] args) { // declaração do vetor do tipo int com 10 posições (0 até 9) double d[] = new double[10]; // Declara o scanner para ser utilizado na leitura de informação do teclado Scanner ler = new Scanner(System.in); // exibe a mensagem na tela System.out.println("Informe 10 valores :"); // contagem regressiva de 9 até 0 for (int i = 0; i < 10; i++) { // "Pega" o que foi digitado pelo usuario e atribui na variavel real double valor = ler.nextDouble(); d[i] = valor; } for (int i = 0; i < 10; i++) { // imprime o valor do vetor System.out.print(d[i] + " "); } } }
[ "guilherme.abranches@outlook.com" ]
guilherme.abranches@outlook.com
64b11858e1c60c6cc7a43436a0aa62dbfa7e0146
5be9dc70db36da5dfb463b2812a163bf1061d7ef
/app/src/main/java/nl/groenier/android/seriesapplication/Series.java
3e2e18bd42870e62a6ab4b54ef450f53ace01242
[]
no_license
MGroenier/SeriesApplication
3ad4c18b028c182e6d74bbde15d3285d61c84f2b
117095bd5594066edf45043a276b023b4dc12083
refs/heads/master
2021-01-11T06:21:21.276983
2016-10-02T17:41:21
2016-10-02T17:41:21
69,378,626
0
0
null
null
null
null
UTF-8
Java
false
false
551
java
package nl.groenier.android.seriesapplication; /** * Created by Martijn on 27/09/2016. */ public class Series { private long id; private String title; public Series() { } public Series(long id, String title) { this.id = id; this.title = title; } public long getId() { return id; } public void setId(long id) { this.id = id; } public String getTitle() { return this.title; } public void setTitle(String title) { this.title = title; } }
[ "martijn@groenier.nl" ]
martijn@groenier.nl
b4e1f8bbc28cc05cc5259d10b68b62f8f38306cf
32e91b8e56cfad097888223a4de1b280fb670257
/core/src/main/java/com/google/reddcoin/crypto/EncryptedPrivateKey.java
e856935366e7b45ec5fc5ddcdffb20e201ee3c2b
[ "Apache-2.0" ]
permissive
reddcoin-project/reddcoinj-pow
d58231c6867f0919db1f0811c686d6d5dff78c97
1106f59062ee134ed86110ee3e9fbdae0084ea45
refs/heads/master
2020-06-08T15:20:26.611847
2014-06-14T10:34:05
2014-06-14T10:34:05
25,260,615
0
1
null
null
null
null
UTF-8
Java
false
false
4,636
java
/** * Copyright 2013 Jim Burton. * * Licensed under the MIT license (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://opensource.org/licenses/mit-license.php * * 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.reddcoin.crypto; import java.util.Arrays; /** * <p>An EncryptedPrivateKey contains the information produced after encrypting the private key bytes of an ECKey.</p> * * <p>It contains two member variables - initialisationVector and encryptedPrivateBytes. The initialisationVector is * a randomly chosen list of bytes that were used to initialise the AES block cipher when the private key bytes were encrypted. * You need these for decryption. The encryptedPrivateBytes are the result of AES encrypting the private keys using * an AES key that is derived from a user entered password. You need the password to recreate the AES key in order * to decrypt these bytes.</p> */ public class EncryptedPrivateKey { private byte[] initialisationVector = null; private byte[] encryptedPrivateBytes = null; /** * Cloning constructor. * @param encryptedPrivateKey EncryptedPrivateKey to clone. */ public EncryptedPrivateKey(EncryptedPrivateKey encryptedPrivateKey) { setInitialisationVector(encryptedPrivateKey.getInitialisationVector()); setEncryptedPrivateBytes(encryptedPrivateKey.getEncryptedBytes()); } /** * @param iv * @param encryptedPrivateKeys */ public EncryptedPrivateKey(byte[] initialisationVector, byte[] encryptedPrivateKeys) { setInitialisationVector(initialisationVector); setEncryptedPrivateBytes(encryptedPrivateKeys); } public byte[] getInitialisationVector() { return initialisationVector; } /** * Set the initialisationVector, cloning the bytes. * * @param initialisationVector */ public void setInitialisationVector(byte[] initialisationVector) { if (initialisationVector == null) { this.initialisationVector = null; return; } byte[] cloneIV = new byte[initialisationVector.length]; System.arraycopy(initialisationVector, 0, cloneIV, 0, initialisationVector.length); this.initialisationVector = cloneIV; } public byte[] getEncryptedBytes() { return encryptedPrivateBytes; } /** * Set the encrypted private key bytes, cloning them. * * @param encryptedPrivateBytes */ public void setEncryptedPrivateBytes(byte[] encryptedPrivateBytes) { if (encryptedPrivateBytes == null) { this.encryptedPrivateBytes = null; return; } this.encryptedPrivateBytes = Arrays.copyOf(encryptedPrivateBytes, encryptedPrivateBytes.length); } @Override public EncryptedPrivateKey clone() { return new EncryptedPrivateKey(getInitialisationVector(), getEncryptedBytes()); } @Override public int hashCode() { return com.google.common.base.Objects.hashCode(encryptedPrivateBytes, initialisationVector); } @Override public boolean equals(Object obj) { if (obj == null) { return false; } if (getClass() != obj.getClass()) { return false; } final EncryptedPrivateKey other = (EncryptedPrivateKey) obj; return com.google.common.base.Objects.equal(this.initialisationVector, other.initialisationVector) && com.google.common.base.Objects.equal(this.encryptedPrivateBytes, other.encryptedPrivateBytes); } @Override public String toString() { return "EncryptedPrivateKey [initialisationVector=" + Arrays.toString(initialisationVector) + ", encryptedPrivateKey=" + Arrays.toString(encryptedPrivateBytes) + "]"; } /** * Clears all the EncryptedPrivateKey contents from memory (overwriting all data including PRIVATE KEYS). * WARNING - this method irreversibly deletes the private key information. */ public void clear() { if (encryptedPrivateBytes != null) { Arrays.fill(encryptedPrivateBytes, (byte)0); } if (initialisationVector != null) { Arrays.fill(initialisationVector, (byte)0); } } }
[ "github@blu3f1re.com" ]
github@blu3f1re.com
7f2c0d502d51d7ec72bbc6b5afadeefd2b5604b5
c733e4e27290c4ead5cfb1221f37b9540303a57e
/android/app/src/main/java/com/mapalarm/MainActivity.java
dbb7be9b434002cf18e340953d66d5048036737c
[]
no_license
InvisibleSpectator/MapAlarm
e70a8b0147cddec787aa73ead9fc046898cf0fec
db1ca5c588e9e0272241536521215b44562f901c
refs/heads/master
2022-07-04T02:36:38.450941
2020-05-11T16:50:18
2020-05-11T16:50:18
256,263,800
0
0
null
null
null
null
UTF-8
Java
false
false
343
java
package com.mapalarm; import com.facebook.react.ReactActivity; public class MainActivity extends ReactActivity { /** * Returns the name of the main component registered from JavaScript. This is used to schedule * rendering of the component. */ @Override protected String getMainComponentName() { return "MapAlarm"; } }
[ "vladislav5678@yandex.ru" ]
vladislav5678@yandex.ru
44595fa7eaefe8dae194461f863ec74225f9236b
870f8b9142a9e1ba1add8a5b888f3f3bf94ea51a
/src/homework/shop/ProductManager.java
a457e02d1aa5ed186c8b1d6c1f6a4bfd158c5025
[]
no_license
khu12687/0520
c7f998fd9f6bbe1ff5c26f837fe7c0981df62cf4
77ff6c534e2170e3f82bc336043549a65784b185
refs/heads/master
2022-08-20T06:23:35.468869
2020-05-20T08:23:06
2020-05-20T08:23:06
265,498,827
0
0
null
null
null
null
UHC
Java
false
false
9,438
java
package homework.shop; import java.awt.BorderLayout; import java.awt.Color; import java.awt.Dimension; import java.awt.Font; import java.awt.Graphics; import java.awt.Image; import java.awt.Toolkit; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.io.File; import java.io.FileInputStream; import java.io.FileNotFoundException; import java.io.FileOutputStream; import java.io.IOException; import java.sql.PreparedStatement; import java.sql.ResultSet; import java.sql.SQLException; import java.util.ArrayList; import javax.swing.JButton; import javax.swing.JFileChooser; import javax.swing.JLabel; import javax.swing.JOptionPane; import javax.swing.JPanel; import javax.swing.JScrollPane; import javax.swing.JTable; import javax.swing.JTextField; //import homework.lib.FileManager; //하나의 화면은 앞으로 패널로 처리하자!! public class ProductManager extends Page{ //-------------서쪽관련------------------ JPanel p_west; //서쪽에 붙여질 컨테이너 JTextField t_name; JTextField t_price; JTextField t_brand; JButton bt_find; //이미지 찾기 버튼 JPanel p_thumb; //등록시 보여질 미리보기 썸네일 JButton bt_regist; //등록버튼 JButton bt_list; //목록버튼 //--------------샌터영역------------------ JPanel p_content; //샌터영역에 들어갈 모든 컴포넌트의 어버이 JTable table; JScrollPane scroll; JPanel p_detailBox; //상세보기 컨테이너 JPanel p_detail; //등록후 보여질 상세보기 JPanel p_info; //이름, 가격, 브랜드 나올 영역 JLabel la_name; JLabel la_price; JLabel la_brand; JFileChooser chooser; Toolkit kit = Toolkit.getDefaultToolkit(); Image thumbImg; //썸네일 이미지 Image detailImg; //상세 이미지 FileInputStream fis; //파일을 대상으로 한 입력스트림 FileOutputStream fos; //파일을 대상으로 한 출력스트림 File thumbFile; //썸네일 처리를 위한 파일객체 String copyName; //새롭게 부여된 파일명!! ProductModel productModel; public ProductManager(ShopApp shopApp, String title,Color color,int width, int height,boolean showFlag) { super(shopApp,title,color,width, height, showFlag); p_west = new JPanel(); t_name = new JTextField(10); t_price = new JTextField(10); t_brand = new JTextField(10); bt_find = new JButton("이미지"); p_thumb = new JPanel() { @Override public void paint(Graphics g) { g.drawImage(thumbImg, 0, 0, 120,120,ProductManager.this); } }; bt_regist = new JButton("등록"); bt_list =new JButton("리스트"); p_content = new JPanel(); table = new JTable(); scroll = new JScrollPane(table); p_detailBox = new JPanel(); p_detail = new JPanel(); p_info = new JPanel(); la_name = new JLabel("제품명 : 티셔츠"); la_price = new JLabel("가격 : 80000"); la_brand = new JLabel("브랜드 : ㅁㄴㅇ"); chooser = new JFileChooser("C:/images"); table.setModel(productModel=new ProductModel()); //스타일 적용 p_content.setBackground(Color.PINK); p_west.setPreferredSize(new Dimension(120,height)); p_thumb.setBackground(Color.WHITE); p_thumb.setPreferredSize(new Dimension(120,120)); p_detail.setBackground(Color.BLACK); p_detail.setPreferredSize(new Dimension(180,180)); p_info.setBackground(Color.RED); la_name.setPreferredSize(new Dimension(350,50)); la_price.setPreferredSize(new Dimension(350,50)); la_brand.setPreferredSize(new Dimension(350,50)); la_name.setFont(new Font("돋음",Font.BOLD,14)); la_price.setFont(new Font("돋음",Font.BOLD,14)); la_brand.setFont(new Font("돋음",Font.BOLD,14)); //보더 레이아웃 적용 this.setLayout(new BorderLayout()); p_content.setLayout(new BorderLayout()); p_detailBox.setLayout(new BorderLayout()); //조립 add(p_content,BorderLayout.CENTER); p_west.add(t_name); p_west.add(t_price); p_west.add(t_brand); p_west.add(bt_find); p_west.add(p_thumb); p_west.add(bt_regist); p_west.add(bt_list); add(p_west, BorderLayout.WEST); p_content.add(scroll); //상세보기 영역 조립 p_info.add(la_name); p_info.add(la_price); p_info.add(la_brand); p_detailBox.add(p_detail,BorderLayout.WEST); p_detailBox.add(p_info); p_content.add(p_detailBox,BorderLayout.SOUTH); //버튼과 리스너 연결 bt_find.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { findImg(); } }); bt_regist.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { regist(); } }); bt_list.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { getList(); } }); } //이미지 탐색기 열고, 선택한 이미지 그리기!! public void findImg() { int result = chooser.showOpenDialog(shopApp); //유저가 파일선택 후 ok를 누르면.. if(result ==JFileChooser.APPROVE_OPTION) { thumbFile = chooser.getSelectedFile(); //System.out.println(file.getAbsolutePath()); //선택한 이미지 경로를 이용한 그림 그리기!! thumbImg = kit.getImage(thumbFile.getAbsolutePath()); p_thumb.repaint(); } } //데이터베이스에 넣기 및 이미지 복사!! public void regist() { //복사먼저 시도하고, 성공하면 db에 넣자!! if(copy()) {//복사가 성공하면 db에 넣자!! String name = t_name.getText(); int price = Integer.parseInt(t_price.getText()); String brand = t_brand.getText(); String sql ="insert into product(product_id, name, price, brand, img)"; sql+=" values(seq_product.nextval,'"+name+"',"+price+",'"+brand+"','"+copyName+"')"; //쿼리문 수행객체인 PreparedStatement 생성!! //인터페이스라서 new하여 생성 불가!! 해결책?? //접속이 되어야 퀴리도 날리므로, Connection으로 부터 간접적으로 인스턴스를 얻어오면 된다!! PreparedStatement pstmt =null; try { //쿼리수행 메서드 호출!! DML excutueUpdate()호출 pstmt = shopApp.con.prepareStatement(sql); int result = pstmt.executeUpdate(); //실행결과 이 쿼리문에 의해 영향을 받은 레코드 갯수를 반환해줌 if(result ==0) { //에러가 아니라 단지 insert가 안된거임 JOptionPane.showMessageDialog(this, "등록실패"); }else { JOptionPane.showMessageDialog(this, "등록성공"); } } catch (SQLException e) { e.printStackTrace(); }finally { shopApp.connectionManger.closeDB(pstmt); } } } //복사 성공여부를 반환하는 메서드!! public boolean copy() { boolean result =false; try { fis = new FileInputStream(thumbFile); //복사될 이미지는 사용자가 올린 이미지명을 사용하지 않고 개발자의 //규칙을 적용하여 새롭게 생성해야 함!! long time=System.currentTimeMillis(); //System.out.println(time); //확장자 구하기 String ext=FileManager.getExt(thumbFile.getAbsolutePath()); System.out.println(time+"."+ext); copyName=time+"."+ext; fos = new FileOutputStream("C:/web_appDB/oracle_workspace/project0518/data/"+copyName);//복사시작!! byte[] buff=new byte[1024];//퍼마실 그릇용량 1kbyte int data=-1;//데이터의 끝을 알려주는 변수 while(true) { try { data=fis.read(buff);//데이터입력!! read()할때마다 1024개 if(data==-1)break;//파일의 끝을 만나면 반복문 탈출!! fos.write(buff);//출력, write()할때마다 1024개씩!! } catch (IOException e) { e.printStackTrace(); } } JOptionPane.showMessageDialog(this, "복사완료"); result=true; //복사성공 } catch (FileNotFoundException e) { e.printStackTrace(); result=false; //복사실패 }finally { if(fos!=null) { try { fos.close(); } catch (IOException e) { e.printStackTrace(); } } if(fis!=null) { try { fis.close(); } catch (IOException e) { e.printStackTrace(); } } } return result; } //목록가져오기 public void getList() { String sql="select * from product order by product_id desc"; PreparedStatement pstmt = null; ResultSet rs =null; try { pstmt=shopApp.con.prepareStatement(sql); rs=pstmt.executeQuery(); //커서를 내려가면서 VO에 레코드를 담자! //List를 생성하여 아래의 VO들을 차곡차곡 넣어두자!! //그래야 TableModel 에서 배열처럼 사용하니깐!! ArrayList productList = new ArrayList(); while(rs.next()){ Product product = new Product(); //배열의 인덱스가 아니라, 변수명을 이용하므로 훨씬 직관적!! product.setProduct_id(rs.getInt("product_id")); product.setName(rs.getString("name")); product.setPrice(rs.getInt("price")); product.setBrand(rs.getString("brand")); product.setImg(rs.getString("img")); productList.add(product); //완성된 VO를 리스트에 누적! as 자바스크립트에 push } System.out.println("담겨진 총 상품의 수는 "+productList.size()); //생성된 리스트를 TableModel에게 전달하자!! productModel.list=productList; //JTable 새로고침 table.updateUI(); } catch (SQLException e) { e.printStackTrace(); }finally { shopApp.connectionManger.closeDB(pstmt,rs); } } }
[ "61855040+khu12687@users.noreply.github.com" ]
61855040+khu12687@users.noreply.github.com
384b7579648ed02ea3065edd2de8c412c2024f53
fadb7be3139596273f8741f895508e16cbbac2d4
/src/july01/boolean_string.java
3932385389a39043c11cec1c4419803850b844e8
[]
no_license
Abasiyanik/SummerCamp
4b728f419864c9d0ed454f4cf0acf48c4097e30e
ff08719839b0fe59c236d4fa4672dbecf10c4a0e
refs/heads/master
2023-02-08T17:33:47.593143
2020-10-03T23:39:36
2020-10-03T23:39:36
285,593,430
0
0
null
null
null
null
UTF-8
Java
false
false
863
java
package july01; public class boolean_string { public static void main(String[] args) { String s1="java"; String s2="java"; boolean c=s1==s2; boolean d=("a"+s1)==("a"+s2); String s3=" "+s1; String s4=" "+s2; int n1=3; int n2=3; boolean cc=3+n1==n2+3; System.out.println("cc: "+cc);//true System.out.println("==++"); System.out.println(("ana"+s1)==("ana"+s2));//false //String s3=String System.out.println("bu dogrudur"+(s1==s2));//ture System.out.println("bu nah dogrudur"+s1==s2);// false cunku "" s1 ile s2 karsilastiriliyor System.out.println(""+s1==""+s2);//false too System.out.println(c+" "+d);//true and false System.out.println(s3==s4);//false System.out.println(s3.endsWith(s4));//true } }
[ "abasiyanik@gmail.com" ]
abasiyanik@gmail.com
e5438428109b330aad3e5b684cb66dc6d8a6810a
580d21e7a0564ea989ad2b84c141a3d47b4039b9
/src/main/java/org/architectdrone/archevo/universe/IterationExecutionMode.java
f423c410b038b126bd0332a14d5b8bc7fdc11d81
[]
no_license
architectdrone/ArchEvo2
380fb86c998c5cf015cd323f29f29d075868b537
d7392e1bce9eb2b6295c4e919fe73f7afbe4eb1d
refs/heads/main
2023-02-08T11:20:17.860608
2020-12-31T20:24:42
2020-12-31T20:24:42
301,535,944
0
0
null
null
null
null
UTF-8
Java
false
false
596
java
package org.architectdrone.archevo.universe; /** * Specifies the manner in which instructions are executed in an iteration. */ public enum IterationExecutionMode { INSTRUCTION_BY_INSTRUCTION, //Cells run exactly one instruction at a time. RUN_UNTIL_STATE_CHANGE_OR_N, //Cells run until they reach one of the following actions: Reproduce, Attack, or Move. If no action occurs after a number of executions equal to the size of the genome, it also halts. RUN_UNTIL_STATE_CHANGE_OR_N_SAVE_IP, //Same as above, except that the state of the instruction pointer is saved after halting. }
[ "owen.mellema@cerner.com" ]
owen.mellema@cerner.com
bcb3bc014a2f586eea2a2205d68c6298b9ae72b1
0bcd6d7f7d7b0405404a0f04a8f07bbb580ebdd7
/src/io/nuls/contract/entity/ContractInfoDto.java
b4c66579956ed21d72aae68523f6e452cca21916
[]
no_license
dassmeta/nuls-idea-plugin
ceeddcb67ebb6a6169ce5f8d055e4a33349accf0
b7f701a870be91f9314a73e7170f72089c3e0d17
refs/heads/master
2023-08-31T20:39:11.772882
2019-01-30T07:42:08
2019-01-30T07:42:08
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,727
java
/** * MIT License * <p> * Copyright (c) 2017-2018 nuls.io * <p> * 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: * <p> * The above copyright notice and this permission notice shall be included in all * copies or substantial portions of the Software. * <p> * 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.nuls.contract.entity; import io.nuls.contract.vm.program.ProgramMethod; /** * @desription: * @author: PierreLuo * @date: 2018/8/15 */ public class ContractInfoDto { private ProgramMethod constructor; private boolean isNrc20; public ProgramMethod getConstructor() { return constructor; } public void setConstructor(ProgramMethod constructor) { this.constructor = constructor; } public boolean isNrc20() { return isNrc20; } public void setNrc20(boolean nrc20) { isNrc20 = nrc20; } }
[ "xdehuan@163.com" ]
xdehuan@163.com
db40d04f46795319c74f724d87d8fff8aef1407b
05e869d4ba6ff043de1f433a6bb97393beb2809c
/src/main/java/cld71/spring_boot_secruity/controller/HomeController.java
a250c923acb2dfbf07072d1187fbd330bdabbc06
[]
no_license
Christopher-Diehl-cognizant-com/spring_boot_secruity
99af80eda7e4b0d09a6f4d59d6f10efd0b6442b6
cbe0f6cfdc362bc14d71c130f4835151e935d4a8
refs/heads/master
2021-05-25T21:24:54.752107
2020-04-08T03:32:08
2020-04-08T03:32:08
253,925,522
0
0
null
null
null
null
UTF-8
Java
false
false
490
java
package cld71.spring_boot_secruity.controller; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RestController; /** * * @author cld71 */ @RestController public class HomeController{ @GetMapping("/") public String home(){ return "<h1>welcome</h1>"; } @GetMapping("/user") public String user(){ return "<h1>welcome User</h1>"; } @GetMapping("/admin") public String admin(){ return "<h1>welcome Admin</h1>"; } }
[ "cld71@cld-pc.diehl" ]
cld71@cld-pc.diehl
fa7c6b78378969a92a77f7183b0658bceb862a1b
05e515553fda9225f614b1bc7527b34d903061a0
/dscribe/src/com/ideanest/dscribe/vcm/CheckpointMediator.java
ea5323cfb6ba1d61c467c042af5f47960bf54c6d
[]
no_license
kuangyifei/dscribe
78c6773f43691fbd324cd5d276585a75805893ea
1ea3ba48bceceb1e9c93824b97800cb3bb974d0b
refs/heads/master
2021-01-10T08:34:18.560825
2009-03-08T06:10:45
2009-03-08T06:10:45
54,817,249
1
0
null
null
null
null
UTF-8
Java
false
false
8,245
java
package com.ideanest.dscribe.vcm; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNull; import static org.junit.Assert.fail; import java.text.ParseException; import java.util.Date; import java.util.regex.Matcher; import java.util.regex.Pattern; import org.apache.log4j.Logger; import org.exist.fluent.*; import org.jmock.Expectations; import org.jmock.Mockery; import org.jmock.integration.junit4.JMock; import org.jmock.integration.junit4.JUnit4Mockery; import org.jmock.lib.legacy.ClassImposteriser; import org.junit.*; import org.junit.runner.RunWith; import com.ideanest.dscribe.Namespace; import com.ideanest.dscribe.job.Cycle; import com.ideanest.dscribe.job.TaskBase; /** * Reviews proposed checkpoint ranges and decides on the checkpoint to use to update * checked-out artifacts. If no agreement is possible, postpones or abandons the job run. * * @author <a href="mailto:piotr@ideanest.com">Piotr Kaminski</a> */ public class CheckpointMediator extends TaskBase { private static final Logger LOG = Logger.getLogger(CheckpointMediator.class); private static final NamespaceMap NAMESPACE_MAPPINGS = new NamespaceMap( "", Namespace.VCM, "vcm", Namespace.VCM, "notes", Namespace.NOTES ); private Folder workspace, prevspace; @Override protected void init(Node taskDef) throws ParseException { workspace = cycle().workspace(NAMESPACE_MAPPINGS); prevspace = cycle().prevspace(NAMESPACE_MAPPINGS); } @Phase public void agree() { if (workspace.query().exists("/notes:notes/vcm:checkpoint")) { LOG.error("checkpoint already set before mediation; deleting and recomputing"); workspace.query().all("/notes:notes/vcm:checkpoint").deleteAllNodes(); } Date checkpoint = workspace.query() .let("$workspace", workspace) .let("$prevspace", prevspace) .optional( "let \n" + " $timestamp := xs:dateTime($workspace/notes:notes/@started), \n" + " $lcs := $prevspace/notes:notes/vcm:checkpoint/@at, \n" + " $lastcheckpoint := if (empty($lcs)) then () else xs:dateTime($lcs), \n" + " $lower_bounds := distinct-values(for $date in //checkpoint-range/@from return xs:dateTime($date)), \n" + " $upper_bounds := distinct-values(for $date in //checkpoint-range/@to return xs:dateTime($date)) \n" + "return min( \n" + " for $interest in //checkpoint-range[@interesting='true'] \n" + " let \n" + " $ilb := max(($lastcheckpoint, xs:dateTime($interest/@from))), \n" + " $iub := min(($timestamp, xs:dateTime($interest/@to))) \n" + " return min( (\n" + " for $bound in ($ilb, $lower_bounds) \n" + " where \n" + " $bound ge $ilb and $bound lt $iub and \n" + " (every $proposal in //checkpoint-proposal satisfies \n" + " some $range in $proposal/checkpoint-range satisfies \n" + " $bound ge xs:dateTime($range/@from) and $bound lt xs:dateTime($range/@to) \n" + " ) \n" + " return $bound \n" + " , \n" + " for $bound in ($iub, $upper_bounds) \n" + " where \n" + " $bound gt $ilb and $bound le $iub and \n" + " (every $proposal in //checkpoint-proposal satisfies \n" + " some $range in $proposal/checkpoint-range satisfies \n" + " $bound gt xs:dateTime($range/@from) and $bound le xs:dateTime($range/@to) \n" + " ) \n" + " return $bound" + " ) ) \n" + ")").instantValue(); if (checkpoint != null) { workspace.query().single("/notes:notes").node().append() .elem("vcm:checkpoint").attr("at", checkpoint).end("vcm:checkpoint").commit(); LOG.debug("mediated checkpoint at " + checkpoint); } else { Date postdate = workspace.query().optional( "max(for $date in //checkpoint-proposal/@postpone-until return xs:dateTime($date))" ).instantValue(); if (postdate != null) { cycle().postpone(postdate); } else { cycle().abandon(); } } } /** * @deprecated Test class that should not be javadoc'ed. */ @Deprecated @DatabaseTestCase.ConfigFile("test/conf.xml") @RunWith(JMock.class) public static class _Test extends DatabaseTestCase { private CheckpointMediator mediator; private Mockery context = new JUnit4Mockery() {{ setImposteriser(ClassImposteriser.INSTANCE); }}; private Cycle cycle; private Date expectedCheckpointDate; @Before public void setUp() { cycle = context.mock(Cycle.class); mediator = new CheckpointMediator() { @Override protected Cycle cycle() { return cycle; } }; mediator.workspace = db.createFolder("/workspace"); mediator.workspace.namespaceBindings().putAll(NAMESPACE_MAPPINGS); mediator.prevspace = db.createFolder("/prevspace"); mediator.prevspace.namespaceBindings().putAll(NAMESPACE_MAPPINGS); mediator.workspace.documents().build(Name.create("notes")) .elem("notes:notes").attr("started", "2004-12-10T10:00:00").end("notes:notes") .commit(); } @After public void verifyCheckpoint() { if (mediator != null) { Date actualDate = mediator.workspace.query().optional("/notes:notes/vcm:checkpoint/@at").instantValue(); if (expectedCheckpointDate == null) assertNull(actualDate); else assertEquals(expectedCheckpointDate, actualDate); } } protected void expectAbandon() { context.checking(new Expectations() {{ never(cycle).postpone(with(any(Date.class))); one(cycle).abandon(); }}); } protected void expectPostpone(final Date date) { context.checking(new Expectations() {{ one(cycle).postpone(date); never(cycle).abandon(); }}); } protected void expectPostpone(String date) { expectPostpone(DataUtils.toDate(DataUtils.datatypeFactory().newXMLGregorianCalendar(date))); } protected void expectCheckpoint(Date date) { context.checking(new Expectations() {{ never(cycle).postpone(with(any(Date.class))); never(cycle).abandon(); }}); expectedCheckpointDate = date; } protected void expectCheckpoint(String date) { expectCheckpoint(DataUtils.toDate(DataUtils.datatypeFactory().newXMLGregorianCalendar(date))); } private static final Pattern RANGE_PROPOSAL = Pattern.compile("from (\\S+) to (\\S+)( interesting)?"); protected void addProposal(String postponeDate, String... ranges) { ElementBuilder<?> b = mediator.workspace.documents().build(Name.generate()) .elem("checkpoint-proposal").attrIf(postponeDate != null, "postpone-until", postponeDate); for (String range : ranges) { Matcher matcher = RANGE_PROPOSAL.matcher(range); if (!matcher.matches()) fail("bad range proposal spec: " + range); b.elem("checkpoint-range") .attr("from", matcher.group(1)).attr("to", matcher.group(2)) .attrIf(matcher.group(3) != null, "interesting", "true") .end("checkpoint-range"); } b.end("checkpoint-proposal").commit(); } @Test public void empty() { expectAbandon(); mediator.agree(); } @Test public void postpone() { addProposal("2004-12-15T05:00:00"); expectPostpone("2004-12-15T05:00:00"); mediator.agree(); } @Test public void checkpoint1() { addProposal(null, "from 2004-12-10T09:00:00 to 2004-12-10T09:05:00 interesting"); expectCheckpoint("2004-12-10T09:00:00"); // lower bound of only range mediator.agree(); } @Test public void checkpoint2() { addProposal(null, "from 2004-12-10T10:00:00 to 2004-12-10T10:05:00"); expectAbandon(); // because only range is not interesting mediator.agree(); } @Test public void checkpoint3() { addProposal(null, "from 2004-12-10T10:00:00 to 2004-12-10T10:05:00 interesting"); expectAbandon(); // because the range is empty once clipped to starting time mediator.agree(); } @Test public void checkpoint4() { addProposal(null, "from 2004-12-10T09:00:00 to 2004-12-10T09:05:00 interesting", "from 2004-12-10T09:30:00 to 2004-12-10T09:35:00 interesting"); expectCheckpoint("2004-12-10T09:00:00"); // lower bound of min range mediator.agree(); } } }
[ "Dr.Kaminski@982f8ab8-0432-0410-be24-bf296a59f75d" ]
Dr.Kaminski@982f8ab8-0432-0410-be24-bf296a59f75d
a2baf8a9d9f497efb3b018f9a7867ee50306ddf8
a6d2573d87b1d1be5f14c6b2776295a285a427bf
/etiyaGameProject/src/dataAccess/abstracts/EntityRepository.java
9054410e514229e558598d8e79761244acdec2b9
[]
no_license
ibrahimGZR/homeWorkBackend
4869710400b78a5b03cee8620e1583aa7547efcc
7a5239bd59e69a0c14fd02fbcf66ad5e2f9be23d
refs/heads/master
2023-07-15T17:13:37.276100
2021-09-01T22:11:02
2021-09-01T22:11:02
396,879,355
0
0
null
null
null
null
UTF-8
Java
false
false
187
java
package dataAccess.abstracts; import java.util.List; public interface EntityRepository<T> { void add(T entity); List<T> getAll(); void update(T entity); void delete(T entity); }
[ "ibrahim.gezer@IBRAHIMGEZER.etiyacorp.local" ]
ibrahim.gezer@IBRAHIMGEZER.etiyacorp.local
c17389e1656ee1e60ea65aa64d24f59b09477005
1e97c41e26e5a8bbc8e2a5711c8dae4cd0209d0c
/Java/20-08_2019/src/emp/service/EmployeeService.java
b175d2c9c088951054283e5addded81c5be5a71b
[]
no_license
Akshaya2497/IBM-FSD-000GL9
840727545fcbffba3382f15263b8b60c0c0e0a6b
c050b29d31b6d7070b81cec490e38f7d31ed1092
refs/heads/master
2023-01-12T13:12:03.403423
2019-10-21T08:21:12
2019-10-21T08:21:12
195,185,527
0
0
null
2023-01-07T08:43:05
2019-07-04T06:52:48
HTML
UTF-8
Java
false
false
245
java
package emp.service; import java.util.List; import emp.model.Employee; public interface EmployeeService { public void createEmployee(Employee employee); public List<Employee> getAllEmployees(); public Employee getEmployeeById(int id); }
[ "b4ibmjava23@iiht.tech" ]
b4ibmjava23@iiht.tech
e14ca146533fba574e95fae843a0614b9b87131a
49719833808815dfbadba7f421a1c56d6cfa9e85
/src/main/java/com/limetropy/snanalysis/SnanalysisApplication.java
25dcab96406a067d938bd0413efa7333dcdacb56
[]
no_license
aantivero/snanalysis
73a18f602ccffc2a0f17a9f7b94a715b9932c428
f50b877ea75b278bc9b3853743ffe6fdccd8f80c
refs/heads/master
2021-06-16T09:01:49.437405
2021-02-17T19:37:41
2021-02-17T19:37:41
167,430,198
0
0
null
null
null
null
UTF-8
Java
false
false
326
java
package com.limetropy.snanalysis; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; @SpringBootApplication public class SnanalysisApplication { public static void main(String[] args) { SpringApplication.run(SnanalysisApplication.class, args); } }
[ "alejandro.antivero@gmail.com" ]
alejandro.antivero@gmail.com
fcc84894faa15e4e35b2b89bf7ab77857b535062
ea5f5491ea3106f6a610f7242f327f008393873a
/app/src/main/java/com/menglingpeng/vonvimeo/utils/SharedPrefUtils.java
413e27841176c8de243426cb148a9e0c669b2f0f
[]
no_license
menglingpeng/vonVimeo
a11affd5884dc1d21707076b5c1080feb16b44df
118b3143fd94d1a1aabdbd3e49f5b36a4714e50a
refs/heads/master
2020-03-21T00:27:07.996779
2019-04-23T03:04:45
2019-04-23T03:04:45
137,894,354
1
0
null
null
null
null
UTF-8
Java
false
false
2,478
java
package com.menglingpeng.vonvimeo.utils; import android.content.Context; import android.content.SharedPreferences; import com.menglingpeng.vonvimeo.base.BaseApplication; import java.util.HashMap; import java.util.Map; public class SharedPrefUtils { private static Context context = BaseApplication.getContext(); private static SharedPreferences sp = context.getSharedPreferences("ShotsJson", Context.MODE_PRIVATE); private static SharedPreferences.Editor editor = sp.edit(); /** * 首次启动应用后,保存标志位。 * 保存用户登陆状态。 */ public static boolean saveState(String key, Boolean is) { editor.putBoolean(key, is); return editor.commit(); } /** * 判断应用是否第一次启动。 * 获取用户登陆状态。 */ public static boolean getState(String key) { Boolean is = false; if (key.equals(Constants.IS_FIRST_START)) { //is不存在则是第一次启动,值为ture is = sp.getBoolean(Constants.IS_FIRST_START, true); } else { //is不存在则是没有登陆,值为false is = sp.getBoolean(key, false); } return is; } /** * 保存网络请求的各种参数。 * * @param map 网络请求的各种参数。 * @return */ public static boolean saveParameters(HashMap<String, String> map) { for (String key : map.keySet()) { editor.putString(key, map.get(key)); } return editor.commit(); } /** * * 获取保存的授权token。 * * @return */ public static String getAuthToken() { String accessToken = sp.getString(Constants.ACCESS_TOKEN, null); return accessToken; } /** * * 退出登录时,删除保存到本地的授权token。 * * @return */ public static void deleteAuthToken() { editor.putString(Constants.ACCESS_TOKEN, Constants.APP_ACCESS_TOKEN); editor.commit(); } public static Boolean saveSearchHistory(HashMap<String, String> map) { for (String key : map.keySet()) { editor.putString(key, map.get(key)); } return editor.commit(); } public static Map getSearchHistory(HashMap<String, String> map){ return map; } }
[ "menglingpeng@live.com" ]
menglingpeng@live.com
c739057eec9ab568157a81abbd0b4fed277845fd
fe49198469b938a320692bd4be82134541e5e8eb
/scenarios/web/large/gradle/ClassLib095/src/main/java/ClassLib095/Class072.java
00f58d705a60c85413b960c4ea1b2c359d206b4b
[]
no_license
mikeharder/dotnet-cli-perf
6207594ded2d860fe699fd7ef2ca2ae2ac822d55
2c0468cb4de9a5124ef958b315eade7e8d533410
refs/heads/master
2022-12-10T17:35:02.223404
2018-09-18T01:00:26
2018-09-18T01:00:26
105,824,840
2
6
null
2022-12-07T19:28:44
2017-10-04T22:21:19
C#
UTF-8
Java
false
false
122
java
package ClassLib095; public class Class072 { public static String property() { return "ClassLib095"; } }
[ "mharder@microsoft.com" ]
mharder@microsoft.com
2550de62ed298162dc8bff9ef4cc78acd20234d7
eef372565ca7a8ed8a9a0faeb79338a4edc8f094
/PTN_Client(2015)/src/com/nms/ui/ptn/business/dialog/cespath/modal/CesPortInfo.java
3be0e6055a533820efe057c5322efece6b874ecc
[]
no_license
ptn2017/ptn2017
f42db27fc54c1fe5938407467b395e6b0a8721f7
7090e2c64b2ea7f38e530d58247dfba4b2906b9a
refs/heads/master
2021-09-04T08:12:08.639049
2018-01-17T07:24:44
2018-01-17T07:24:44
112,810,000
0
0
null
null
null
null
UTF-8
Java
false
false
1,815
java
package com.nms.ui.ptn.business.dialog.cespath.modal; import com.nms.db.bean.equipment.port.PortInst; import com.nms.db.bean.equipment.port.PortStmTimeslot; import com.nms.ui.frame.ViewDataObj; import com.nms.ui.manager.ExceptionManage; import com.nms.ui.manager.UiUtil; public class CesPortInfo extends ViewDataObj{ /** * */ private static final long serialVersionUID = -5538055075904852789L; private PortInst e1PortInst; private PortStmTimeslot portStmTimeSlot; public PortInst getE1PortInst() { return e1PortInst; } public void setE1PortInst(PortInst e1PortInst) { this.e1PortInst = e1PortInst; } public PortStmTimeslot getPortStmTimeSlot() { return portStmTimeSlot; } public void setPortStmTimeSlot(PortStmTimeslot portStmTimeSlot) { this.portStmTimeSlot = portStmTimeSlot; } @SuppressWarnings("unchecked") @Override public void putObjectProperty() { try { if(this.e1PortInst != null ) { this.getClientProperties().put("id", this.e1PortInst); this.getClientProperties().put("name", this.e1PortInst.getPortName()); // this.getClientProperties().put("ces_sendjtwo", "-"); // this.getClientProperties().put("ces_sendvfive", "-"); } if(this.portStmTimeSlot != null) { this.getClientProperties().put("id", this.portStmTimeSlot); this.getClientProperties().put("name", this.portStmTimeSlot.getTimeslotnumber()); this.getClientProperties().put("ces_sendjtwo", this.portStmTimeSlot.getSendjtwo() ); if(null!= this.portStmTimeSlot.getSendvfive() && !"0".equals(this.portStmTimeSlot.getSendvfive())){ getClientProperties().put("ces_sendvfive", UiUtil.getCodeById(Integer.parseInt(this.portStmTimeSlot.getSendvfive())).getCodeName()); } } } catch (Exception e) { ExceptionManage.dispose(e,this.getClass()); } } }
[ "a18759149@qq.com" ]
a18759149@qq.com
06f3162b21159f2ae5d7cd1bfaed47155dd7378f
711a3a14e45224c2d3a157b76a53cdf8d1d12605
/app/src/main/java/com/twist/navtest2/Bean/UserLogin.java
dc509dc84e75964a918c148d2a7db96c7977064c
[]
no_license
f0rTwist/MDCheckIn
ff399e88b33ddcfe3333c931bae07db984b5c3c0
6d1ab4d18ba34412e6b872ade0881157e00b15d5
refs/heads/master
2022-11-19T03:13:08.818243
2020-07-06T13:30:17
2020-07-06T13:30:17
277,549,561
0
0
null
null
null
null
UTF-8
Java
false
false
401
java
package com.twist.navtest2.Bean; public class UserLogin { public String getUsername() { return Username; } public void setUsername(String username) { Username = username; } public String getPassword() { return Password; } public void setPassword(String password) { Password = password; } String Username; String Password; }
[ "R@F0rTwist.cn" ]
R@F0rTwist.cn
0f063b8a3651a7d67549e521d441cf79b85ec298
d0a14d27664aa23bdaf0726cd468c6bce250bde3
/app/src/main/java/com/mode/fridge/presenter/IotTypePresenter.java
9fe3d6ea7f1778f27085e87634544c6ece9af68e
[]
no_license
710604973/weilian_project_fridge
d937756655ec967859dbdace811c5d30e445d56b
dd6789baef46161ba8ba881ff829aa7df876e558
refs/heads/master
2020-03-27T10:37:50.510335
2018-08-28T10:51:31
2018-08-28T10:51:31
146,433,761
0
1
null
null
null
null
UTF-8
Java
false
false
19,351
java
package com.mode.fridge.presenter; import android.content.Context; import com.miot.common.abstractdevice.AbstractDevice; import com.mode.fridge.AppConstants; import com.mode.fridge.R; import com.mode.fridge.bean.DeviceTypeEntity; import com.mode.fridge.common.http.MiDeviceApi; import com.mode.fridge.contract.IotTypeContract; import com.mode.fridge.device.DeviceConfig; import com.mode.fridge.repository.FanRepository; import com.mode.fridge.repository.FridgeRepository; import com.mode.fridge.repository.HeatKettleRepository; import com.mode.fridge.repository.ManageRepository; import com.mode.fridge.repository.RangeHoodRepository; import com.mode.fridge.repository.WashRepository; import com.mode.fridge.repository.WaterPurifierRepository; import com.mode.fridge.utils.RxSchedulerUtil; import com.mode.fridge.utils.logUtil; import java.util.List; import java.util.concurrent.TimeUnit; import javax.annotation.Nullable; import javax.inject.Inject; import rx.Observable; import rx.Subscription; import rx.schedulers.Schedulers; import rx.subscriptions.CompositeSubscription; /** * 互联网家设备分类 Presenter * Created by William on 2018/3/3. */ public class IotTypePresenter implements IotTypeContract.Presenter { private static final String TAG = IotTypePresenter.class.getSimpleName(); private CompositeSubscription mCompositeSubscription; private CompositeSubscription mHttpCompositeSubscription; private Context mContext; @Nullable private IotTypeContract.View mView; @Inject IotTypePresenter(Context context) { mContext = context; } @Override public void subscribe(IotTypeContract.View view) { this.mView = view; mCompositeSubscription = new CompositeSubscription(); mHttpCompositeSubscription = new CompositeSubscription(); loadUserInfo(); } @Override public void unSubscribe() { this.mView = null; if (mCompositeSubscription != null) { mCompositeSubscription.unsubscribe(); mCompositeSubscription = null; } if (mHttpCompositeSubscription != null) { mHttpCompositeSubscription.unsubscribe(); mHttpCompositeSubscription = null; } } @Override public void initDeviceList(List<DeviceTypeEntity> list) { String[] types = mContext.getResources().getStringArray(R.array.device_type_list); // String model = FridgePreference.getInstance().getModel(); String model = DeviceConfig.MODEL; for (int i = 0; i < types.length; i++) { DeviceTypeEntity entity = new DeviceTypeEntity(); entity.setType(types[i]); if (!model.equals(AppConstants.MODEL_JD) && i != 1 && i != 5 && i != 6 && i != 9 && i != 10 && i != 11 && i != 12 && i != 13 && i != 14) { // 是否已上架 entity.setOnSale(true); } list.add(entity); } // // 冰箱 // DeviceParams params = SerialManager.getInstance().getDeviceParamsSet(); // Log.i("info", "===================params:" + params); // String data = ""; // data = data + (params.isCold_switch() ? params.getCold_temp_set() : "--") + ","; // if (model.equals(AppConstants.MODEL_X5)) { // data = data + (params.isChangeable_switch() ? params.getChangeable_temp_set() : "--") + ","; // } // if (model.equals(AppConstants.MODEL_X3) || model.equals(AppConstants.MODEL_X5)) { // data = data + (params.getFreezing_temp_set() < -24 ? -24 : params.getFreezing_temp_set()); // } else data = data + params.getFreezing_temp_set(); // list.get(0).setData(data); if (mView != null) mView.refreshView(); loadDeviceList(list); } @Override public void loadDeviceList(List<DeviceTypeEntity> list) { Subscription subscription = Observable.interval(0, 10, TimeUnit.SECONDS) .subscribeOn(Schedulers.io()) .onTerminateDetach() .flatMap(aLong -> { if (mHttpCompositeSubscription != null) mHttpCompositeSubscription.clear(); return MiDeviceApi.getDeviceList(mContext); })// 获取 Miot 设备列表 .subscribeOn(Schedulers.computation()) .onTerminateDetach() .subscribe(list1 -> { classifyMiDevice(list1, list);// 对设备进行分类 }, throwable -> { String msg = throwable.getMessage(); logUtil.e(TAG, "==msg:" + throwable.getMessage()); // logUtil.e(TAG, throwable.getMessage()); }); mCompositeSubscription.add(subscription); } @Override public void loadUserInfo() { Subscription subscription = ManageRepository.getInstance().getUser(mContext) .compose(RxSchedulerUtil.SchedulersTransformer1()) .onTerminateDetach() .subscribe(qrCodeBase -> { if (mView != null) mView.showUserInfo(qrCodeBase); }, throwable -> { logUtil.e(TAG, throwable.getMessage()); if (mView != null) mView.showUserInfo(null); }); mCompositeSubscription.add(subscription); } /** * 根据 Model 进行分类 * * @param miList: Miot 设备集合 * @param list: 分类集合 */ private void classifyMiDevice(List<AbstractDevice> miList, List<DeviceTypeEntity> list) { for (DeviceTypeEntity entity : list) { entity.getList().clear();// 先清除 entity.setAsking(false); entity.setData(null); entity.setExist(false); } for (AbstractDevice device : miList) { switch (device.getDeviceModel()) { // 冰箱 case AppConstants.VIOMI_FRIDGE_V1: case AppConstants.VIOMI_FRIDGE_V2: case AppConstants.VIOMI_FRIDGE_V3: case AppConstants.VIOMI_FRIDGE_V31: case AppConstants.VIOMI_FRIDGE_V4: case AppConstants.VIOMI_FRIDGE_U1: case AppConstants.VIOMI_FRIDGE_U2: case AppConstants.VIOMI_FRIDGE_U3: case AppConstants.VIOMI_FRIDGE_W1: case AppConstants.VIOMI_FRIDGE_X1: case AppConstants.VIOMI_FRIDGE_X2: case AppConstants.VIOMI_FRIDGE_X3: case AppConstants.VIOMI_FRIDGE_X4: case AppConstants.VIOMI_FRIDGE_X41: case AppConstants.VIOMI_FRIDGE_X5: list.get(0).getList().add(device);// 分类添加 if (device.isOnline() && !list.get(0).isExist()) list.get(0).setExist(true);// 有在线设备 if (device.isOnline() && list.get(0).getData() == null && !list.get(0).isAsking())// 该分类无请求数据 loadFridge(device, list);// 获取在冰箱数据 break; // 烟机 case AppConstants.VIOMI_HOOD_A4: case AppConstants.VIOMI_HOOD_A5: case AppConstants.VIOMI_HOOD_A6: case AppConstants.VIOMI_HOOD_A7: case AppConstants.VIOMI_HOOD_C1: case AppConstants.VIOMI_HOOD_H1: case AppConstants.VIOMI_HOOD_H2: list.get(2).getList().add(device);// 分类添加 if (device.isOnline() && !list.get(2).isExist()) list.get(2).setExist(true);// 有在线设备 if (device.isOnline() && list.get(2).getData() == null && !list.get(2).isAsking())// 该分类无请求数据 loadRangeHood(device, list);// 获取在线烟机数据 break; // 净水器 case AppConstants.YUNMI_WATERPURI_V1: case AppConstants.YUNMI_WATERPURI_V2: case AppConstants.YUNMI_WATERPURI_S1: case AppConstants.YUNMI_WATERPURI_S2: case AppConstants.YUNMI_WATERPURI_C1: case AppConstants.YUNMI_WATERPURI_C2: case AppConstants.YUNMI_WATERPURI_X3: case AppConstants.YUNMI_WATERPURI_X5: case AppConstants.YUNMI_WATERPURIFIER_V1: case AppConstants.YUNMI_WATERPURIFIER_V2: case AppConstants.YUNMI_WATERPURIFIER_V3: case AppConstants.YUNMI_WATERPURI_LX2: case AppConstants.YUNMI_WATERPURI_LX3: list.get(3).getList().add(device);// 分类添加 if (device.isOnline() && !list.get(3).isExist()) list.get(3).setExist(true);// 有在线设备 if (device.isOnline() && list.get(3).getData() == null && !list.get(3).isAsking()) loadWaterPurifier(device, list);// 获取在线净水器数据 break; // 即热饮水吧 case AppConstants.YUNMI_KETTLE_R1: list.get(4).getList().add(device);// 分类添加 if (device.isOnline() && !list.get(4).isExist()) list.get(4).setExist(true);// 有在线设备 if (device.isOnline() && list.get(4).getData() == null && !list.get(4).isAsking()) loadHeatKettle(device, list);// 获取在线即热饮水吧数据 break; // 洗碗机 case AppConstants.VIOMI_DISHWASHER_V01: list.get(7).getList().add(device);// 分类添加 if (device.isOnline() && !list.get(7).isExist()) list.get(7).setExist(true);// 有在线设备 // TODO 获取数据 break; // 洗衣机 case AppConstants.VIOMI_WASHER_U1: case AppConstants.VIOMI_WASHER_U2: list.get(8).getList().add(device);// 分类添加 if (device.isOnline() && !list.get(8).isExist()) list.get(8).setExist(true);// 有在线设备 String data = list.get(8).getData(); if (device.isOnline() && data == null && !list.get(8).isAsking()) loadWasher(device, list); // TODO 获取数据 break; // 风扇 case AppConstants.VIOMI_FAN_V1: list.get(11).getList().add(device);// 分类添加 if (device.isOnline() && !list.get(11).isExist()) list.get(11).setExist(true);// 有在线设备 String Data = list.get(11).getData(); if (device.isOnline() && Data == null && !list.get(11).isAsking()) loadFan(device, list); // TODO 获取数据 break; // 扫地机器人 case AppConstants.VIOMI_VACUUM_V1: list.get(14).getList().add(device);// 分类添加 if (device.isOnline() && !list.get(14).isExist()) list.get(14).setExist(true);// 有在线设备 // TODO 获取数据 break; } } refrshView(list); } private void loadFridge(AbstractDevice device, List<DeviceTypeEntity> list) { // 冰箱 String model = device.getDeviceModel(); list.get(0).setAsking(true); Subscription subscription = FridgeRepository.getProp(device.getDeviceId()) .compose(RxSchedulerUtil.SchedulersTransformer1()) .onTerminateDetach() .subscribe(rpcResult -> { if (rpcResult.getCode() != 0 || rpcResult.getList().size() == 0) return; String data = ""; String RCSet = (String) rpcResult.getList().get(0); String CCSet = (String) rpcResult.getList().get(2); int RCSetTemp = (int) rpcResult.getList().get(1); int CCSetTemp = (int) rpcResult.getList().get(3); int FCSetTemp = (int) rpcResult.getList().get(4); if (RCSet.equals("on")) { data = data + RCSetTemp + ","; } else { data = data + "--" + ","; } if (model.equals(AppConstants.MODEL_X5)) { if (CCSet.equals("on")) { data = data + CCSetTemp + ","; } else { data = data + "--" + ","; } } if (model.equals(AppConstants.MODEL_X3) || model.equals(AppConstants.MODEL_X5)) { if (FCSetTemp < -24) { data = data + "-24"; } else { data = data + FCSetTemp; } } else { data = data + FCSetTemp; } list.get(0).setData(data); if (mView != null) mView.notifyItemView(0, data); // refrshView(list); }, throwable -> logUtil.e(TAG, throwable.getMessage())); mHttpCompositeSubscription.add(subscription); } private void refrshView(List<DeviceTypeEntity> list) { Subscription subscription = Observable.just(list) .compose(RxSchedulerUtil.SchedulersTransformer1()) .onTerminateDetach() .subscribe(list1 -> { for (int i = 0; i < list1.size(); i++) { if (!list1.get(i).isAsking() && mView != null) mView.notifyItemView(i, ""); } if (mView != null) mView.refreshView(); }, throwable -> logUtil.e(TAG, throwable.getMessage())); mCompositeSubscription.add(subscription); } // 获取烟机工作状态 private void loadRangeHood(AbstractDevice device, List<DeviceTypeEntity> list) { list.get(2).setAsking(true); Subscription subscription = RangeHoodRepository.getProp(device.getDeviceId()) .compose(RxSchedulerUtil.SchedulersTransformer1()) .onTerminateDetach() .subscribe(rpcResult -> { if (rpcResult.getCode() != 0 || rpcResult.getList().size() == 0) return; if (((int) rpcResult.getList().get(1)) == 0) list.get(2).setData("已关机"); else { if (((int) rpcResult.getList().get(2)) == 0) list.get(2).setData("空闲中"); else if (((int) rpcResult.getList().get(2)) == 1) list.get(2).setData("低档排烟"); else if (((int) rpcResult.getList().get(2)) == 4) list.get(2).setData("爆炒排烟"); else if (((int) rpcResult.getList().get(2)) == 16) list.get(2).setData("高档排烟"); } if (mView != null) mView.notifyItemView(2, ""); }, throwable -> logUtil.e(TAG, throwable.getMessage())); mHttpCompositeSubscription.add(subscription); } // 获取净水器 TDS 值 private void loadWaterPurifier(AbstractDevice device, List<DeviceTypeEntity> list) { list.get(3).setAsking(true); Subscription subscription = WaterPurifierRepository.miGetProp(device.getDeviceId()) .compose(RxSchedulerUtil.SchedulersTransformer1()) .onTerminateDetach() .subscribe(rpcResult -> { if (rpcResult.getCode() != 0 || rpcResult.getList().size() == 0) return; list.get(3).setData("TDS:" + String.valueOf(rpcResult.getList().get(1))); if (mView != null) mView.notifyItemView(3, ""); }, throwable -> logUtil.e(TAG, throwable.getMessage())); mHttpCompositeSubscription.add(subscription); } // 获取洗衣机 private void loadWasher(AbstractDevice device, List<DeviceTypeEntity> list) { list.get(8).setAsking(true); Subscription subscription = WashRepository.getProp(device.getDeviceId()) .compose(RxSchedulerUtil.SchedulersTransformer1()) .onTerminateDetach() .subscribe(rpcResult -> { if (rpcResult.getCode() != 0 || rpcResult.getList().size() == 0) return; String str = String.valueOf(rpcResult.getList().get(1)); list.get(8).setData(str); if (mView != null) mView.notifyItemView(8, ""); }, throwable -> logUtil.e(TAG, throwable.getMessage())); mHttpCompositeSubscription.add(subscription); } // 获取风扇 private void loadFan(AbstractDevice device, List<DeviceTypeEntity> list) { list.get(11).setAsking(true); Subscription subscription = FanRepository.getProp(device.getDeviceId()) .compose(RxSchedulerUtil.SchedulersTransformer1()) .onTerminateDetach() .subscribe(rpcResult -> { if (rpcResult.getCode() != 0 || rpcResult.getList().size() == 0) return; String str = String.valueOf(rpcResult.getList().get(1)); list.get(11).setData(str); if (mView != null) mView.notifyItemView(11, ""); }, throwable -> logUtil.e(TAG, throwable.getMessage())); mHttpCompositeSubscription.add(subscription); } // 获取即热饮水吧出水温度 private void loadHeatKettle(AbstractDevice device, List<DeviceTypeEntity> list) { list.get(4).setAsking(true); Subscription subscription = HeatKettleRepository.getProp(device.getDeviceId()) .compose(RxSchedulerUtil.SchedulersTransformer1()) .onTerminateDetach() .subscribe(rpcResult -> { if (rpcResult.getCode() != 0 || rpcResult.getList().size() == 0) return; list.get(4).setData(String.valueOf(rpcResult.getList().get(0)) + "℃"); if (mView != null) mView.notifyItemView(4, ""); }, throwable -> logUtil.e(TAG, throwable.getMessage())); mHttpCompositeSubscription.add(subscription); } }
[ "duanjisi@viomi.com.cn" ]
duanjisi@viomi.com.cn
7a1622a241b422d6923c15bfa280a08d0e652d8d
e00aa178787feed6d62392ce618bd43981db5b56
/dubbo-remoting/src/test/java/com/alibaba/dubbo/remoting/codec/TelnetCodecTest.java
dfc62bd24a1d116ef94c317215a2f0b14bc910aa
[ "Apache-2.0" ]
permissive
bjo2008cnx/dubbo-research
787acfccbc461e5ca7435c69b2990a5ccdc31609
dd3445522cf209623e86720e9593dc0b26cacd28
refs/heads/master
2022-07-01T18:59:31.786213
2020-03-05T09:41:59
2020-03-05T09:41:59
231,495,462
5
0
Apache-2.0
2022-06-29T16:00:26
2020-01-03T02:20:48
Java
UTF-8
Java
false
false
13,439
java
/* * Copyright 1999-2011 Alibaba Group. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.alibaba.dubbo.remoting.codec; import java.io.ByteArrayInputStream; import java.io.ByteArrayOutputStream; import java.io.IOException; import java.io.InputStream; import java.io.ObjectInputStream; import java.io.ObjectOutputStream; import java.io.Serializable; import java.util.HashMap; import junit.framework.Assert; import org.junit.Before; import org.junit.Test; import com.alibaba.dubbo.common.URL; import com.alibaba.dubbo.common.io.UnsafeByteArrayInputStream; import com.alibaba.dubbo.common.io.UnsafeByteArrayOutputStream; import com.alibaba.dubbo.remoting.Channel; import com.alibaba.dubbo.remoting.Codec; import com.alibaba.dubbo.remoting.telnet.codec.TelnetCodec; /** * @author chao.liuc */ public class TelnetCodecTest { protected Codec codec; byte[] UP = new byte[]{27, 91, 65}; byte[] DOWN = new byte[]{27, 91, 66}; /** * @throws java.lang.Exception */ @Before public void setUp() throws Exception { codec = new TelnetCodec(); } protected AbstractMockChannel getServerSideChannel(URL url) { url = url.addParameter(AbstractMockChannel.LOCAL_ADDRESS, url.getAddress()) .addParameter(AbstractMockChannel.REMOTE_ADDRESS, "127.0.0.1:12345"); AbstractMockChannel channel = new AbstractMockChannel(url); return channel; } protected AbstractMockChannel getCliendSideChannel(URL url) { url = url.addParameter(AbstractMockChannel.LOCAL_ADDRESS, "127.0.0.1:12345") .addParameter(AbstractMockChannel.REMOTE_ADDRESS, url.getAddress()); AbstractMockChannel channel = new AbstractMockChannel(url); return channel; } protected byte[] join(byte[] in1, byte[] in2) { byte[] ret = new byte[in1.length + in2.length]; System.arraycopy(in1, 0, ret, 0, in1.length); System.arraycopy(in2, 0, ret, in1.length, in2.length); return ret; } protected byte[] objectToByte(Object obj) { byte[] bytes; if (obj instanceof String) { bytes = ((String) obj).getBytes(); } else if (obj instanceof byte[]) { bytes = (byte[]) obj; } else { try { //object to bytearray ByteArrayOutputStream bo = new ByteArrayOutputStream(); ObjectOutputStream oo = new ObjectOutputStream(bo); oo.writeObject(obj); bytes = bo.toByteArray(); bo.close(); oo.close(); } catch (Exception e) { throw new RuntimeException(e); } } return (bytes); } protected Object byteToObject(byte[] objBytes) throws Exception { if (objBytes == null || objBytes.length == 0) { return null; } ByteArrayInputStream bi = new ByteArrayInputStream(objBytes); ObjectInputStream oi = new ObjectInputStream(bi); return oi.readObject(); } //====================================================== public static class Person implements Serializable { private static final long serialVersionUID = 3362088148941547337L; public String name; public String sex; @Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + ((name == null) ? 0 : name.hashCode()); result = prime * result + ((sex == null) ? 0 : sex.hashCode()); return result; } @Override public boolean equals(Object obj) { if (this == obj) { return true; } if (obj == null) { return false; } if (getClass() != obj.getClass()) { return false; } Person other = (Person) obj; if (name == null) { if (other.name != null) { return false; } } else if (!name.equals(other.name)) { return false; } if (sex == null) { if (other.sex != null) { return false; } } else if (!sex.equals(other.sex)) { return false; } return true; } } protected void testDecode_assertEquals(byte[] request, Object ret) throws IOException { testDecode_assertEquals(request, ret, true); } protected void testDecode_assertEquals(byte[] request, Object ret, boolean isServerside) throws IOException { //init channel Channel channel = isServerside ? getServerSideChannel(url) : getCliendSideChannel(url); //init request string InputStream input = new UnsafeByteArrayInputStream(request); //decode Object obj = codec.decode(channel, input); Assert.assertEquals(ret, obj); } protected void testEecode_assertEquals(Object request, byte[] ret, boolean isServerside) throws IOException { //init channel Channel channel = isServerside ? getServerSideChannel(url) : getCliendSideChannel(url); UnsafeByteArrayOutputStream bos = new UnsafeByteArrayOutputStream(1024); codec.encode(channel, bos, request); bos.flush(); bos.close(); InputStream is = new ByteArrayInputStream(bos.toByteArray()); byte[] data = new byte[is.available()]; is.read(data); Assert.assertEquals(ret.length, data.length); for (int i = 0; i < ret.length; i++) { if (ret[i] != data[i]) { Assert.fail(); } } } protected void testDecode_assertEquals(Object request, Object ret) throws IOException { testDecode_assertEquals(request, ret, null); } private void testDecode_assertEquals(Object request, Object ret, Object channelReceive) throws IOException { testDecode_assertEquals(null, request, ret, channelReceive); } private void testDecode_assertEquals(AbstractMockChannel channel, Object request, Object expectret, Object channelReceive) throws IOException { //init channel if (channel == null) { channel = getServerSideChannel(url); } byte[] buf = objectToByte(request); InputStream input = new UnsafeByteArrayInputStream(buf); //decode Object obj = codec.decode(channel, input); Assert.assertEquals(expectret, obj); Assert.assertEquals(channelReceive, channel.getReceivedMessage()); } private void testDecode_PersonWithEnterByte(byte[] enterbytes, boolean isNeedmore) throws IOException { //init channel Channel channel = getServerSideChannel(url); //init request string Person request = new Person(); byte[] newbuf = join(objectToByte(request), enterbytes); InputStream input = new UnsafeByteArrayInputStream(newbuf); //decode Object obj = codec.decode(channel, input); if (isNeedmore) { Assert.assertEquals(Codec.NEED_MORE_INPUT, obj); } else { Assert.assertTrue("return must string ", obj instanceof String); } } private void testDecode_WithExitByte(byte[] exitbytes, boolean isChannelClose) throws IOException { //init channel Channel channel = getServerSideChannel(url); InputStream input = new UnsafeByteArrayInputStream(exitbytes); //decode codec.decode(channel, input); Assert.assertEquals(isChannelClose, channel.isClosed()); } //====================================================== URL url = URL.valueOf("dubbo://10.20.30.40:20880"); @Test public void testDecode_String_ClientSide() throws IOException { testDecode_assertEquals("aaa".getBytes(), "aaa", false); } @Test public void testDecode_BlankMessage() throws IOException { testDecode_assertEquals(new byte[]{}, Codec.NEED_MORE_INPUT); } @Test public void testDecode_String_NoEnter() throws IOException { testDecode_assertEquals("aaa", Codec.NEED_MORE_INPUT); } @Test public void testDecode_String_WithEnter() throws IOException { testDecode_assertEquals("aaa\n", "aaa"); } @Test public void testDecode_String_MiddleWithEnter() throws IOException { testDecode_assertEquals("aaa\r\naaa", Codec.NEED_MORE_INPUT); } @Test public void testDecode_Person_ObjectOnly() throws IOException { testDecode_assertEquals(new Person(), Codec.NEED_MORE_INPUT); } @Test public void testDecode_Person_WithEnter() throws IOException { testDecode_PersonWithEnterByte(new byte[]{'\r', '\n'}, false);//windows end testDecode_PersonWithEnterByte(new byte[]{'\n', '\r'}, true); testDecode_PersonWithEnterByte(new byte[]{'\n'}, false); //linux end testDecode_PersonWithEnterByte(new byte[]{'\r'}, true); testDecode_PersonWithEnterByte(new byte[]{'\r', 100}, true); } @Test public void testDecode_WithExitByte() throws IOException { HashMap<byte[], Boolean> exitbytes = new HashMap<byte[], Boolean>(); exitbytes.put(new byte[]{3}, true); /* Windows Ctrl+C */ exitbytes.put(new byte[]{1, 3}, false); //must equal the bytes exitbytes.put(new byte[]{-1, -12, -1, -3, 6}, true); /* Linux Ctrl+C */ exitbytes.put(new byte[]{1, -1, -12, -1, -3, 6}, false); //must equal the bytes exitbytes.put(new byte[]{-1, -19, -1, -3, 6}, true); /* Linux Pause */ for (byte[] exit : exitbytes.keySet()) { testDecode_WithExitByte(exit, exitbytes.get(exit)); } } @Test public void testDecode_Backspace() throws IOException { //32 8 先加空格在补退格. testDecode_assertEquals(new byte[]{'\b'}, Codec.NEED_MORE_INPUT, new String(new byte[]{32, 8})); //测试中文 byte[] chineseBytes = "中".getBytes(); byte[] request = join(chineseBytes, new byte[]{'\b'}); testDecode_assertEquals(request, Codec.NEED_MORE_INPUT, new String(new byte[]{32, 32, 8, 8})); //中文会带来此问题 (-数判断) 忽略此问题,退格键只有在真的telnet程序中才输入有意义. testDecode_assertEquals(new byte[]{'a', 'x', -1, 'x', '\b'}, Codec.NEED_MORE_INPUT, new String(new byte[]{32, 32, 8, 8})); } @Test(expected = IOException.class) public void testDecode_Backspace_WithError() throws IOException { url = url.addParameter(AbstractMockChannel.ERROR_WHEN_SEND, Boolean.TRUE.toString()); testDecode_Backspace(); url = url.removeParameter(AbstractMockChannel.ERROR_WHEN_SEND); } @Test() public void testDecode_History_UP() throws IOException { //init channel AbstractMockChannel channel = getServerSideChannel(url); testDecode_assertEquals(channel, UP, Codec.NEED_MORE_INPUT, null); String request1 = "aaa\n"; Object expected1 = "aaa"; //init history testDecode_assertEquals(channel, request1, expected1, null); testDecode_assertEquals(channel, UP, Codec.NEED_MORE_INPUT, expected1); } @Test(expected = IOException.class) public void testDecode_UPorDOWN_WithError() throws IOException { url = url.addParameter(AbstractMockChannel.ERROR_WHEN_SEND, Boolean.TRUE.toString()); //init channel AbstractMockChannel channel = getServerSideChannel(url); testDecode_assertEquals(channel, UP, Codec.NEED_MORE_INPUT, null); String request1 = "aaa\n"; Object expected1 = "aaa"; //init history testDecode_assertEquals(channel, request1, expected1, null); testDecode_assertEquals(channel, UP, Codec.NEED_MORE_INPUT, expected1); url = url.removeParameter(AbstractMockChannel.ERROR_WHEN_SEND); } @Test() public void testDecode_History_UP_DOWN_MULTI() throws IOException { AbstractMockChannel channel = getServerSideChannel(url); String request1 = "aaa\n"; Object expected1 = request1.replace("\n", ""); //init history testDecode_assertEquals(channel, request1, expected1, null); String request2 = "bbb\n"; Object expected2 = request2.replace("\n", ""); //init history testDecode_assertEquals(channel, request2, expected2, null); String request3 = "ccc\n"; Object expected3 = request3.replace("\n", ""); //init history testDecode_assertEquals(channel, request3, expected3, null); byte[] UP = new byte[]{27, 91, 65}; byte[] DOWN = new byte[]{27, 91, 66}; //history[aaa,bbb,ccc] testDecode_assertEquals(channel, UP, Codec.NEED_MORE_INPUT, expected3); testDecode_assertEquals(channel, DOWN, Codec.NEED_MORE_INPUT, expected3); testDecode_assertEquals(channel, UP, Codec.NEED_MORE_INPUT, expected2); testDecode_assertEquals(channel, UP, Codec.NEED_MORE_INPUT, expected1); testDecode_assertEquals(channel, UP, Codec.NEED_MORE_INPUT, expected1); testDecode_assertEquals(channel, UP, Codec.NEED_MORE_INPUT, expected1); testDecode_assertEquals(channel, DOWN, Codec.NEED_MORE_INPUT, expected2); testDecode_assertEquals(channel, DOWN, Codec.NEED_MORE_INPUT, expected3); testDecode_assertEquals(channel, DOWN, Codec.NEED_MORE_INPUT, expected3); testDecode_assertEquals(channel, DOWN, Codec.NEED_MORE_INPUT, expected3); testDecode_assertEquals(channel, UP, Codec.NEED_MORE_INPUT, expected2); } //============================================================================================================================= @Test public void testEncode_String_ClientSide() throws IOException { testEecode_assertEquals("aaa", "aaa\r\n".getBytes(), false); } }
[ "wangxm@" ]
wangxm@
063bca4eac500309161b04413c9723b2e802b495
c0685ddae9e2f7b731cc1ff5de8cf4e274d7b073
/Tunif/src/PackageGraphic/NewJFrameStat.java
1336409a1a5c45175672849d61515903b2dd7068
[]
no_license
wahibmeriah/PiDevSOSpharm
be63167615ca9487faaacbb027168a9c956c555f
c1bfcd96930b19a05f70f908be4fcf3192b17b5b
refs/heads/master
2021-01-17T12:09:36.356017
2014-03-07T17:27:07
2014-03-07T17:27:07
null
0
0
null
null
null
null
UTF-8
Java
false
false
3,437
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 PackageGraphic; /** * * @author ESPRIT */ public class NewJFrameStat extends javax.swing.JFrame { /** * Creates new form NewJFrameStat */ public NewJFrameStat() { initComponents(); } /** * This method is called from within the constructor to initialize the form. * WARNING: Do NOT modify this code. The content of this method is always * regenerated by the Form Editor. */ @SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents private void initComponents() { jPopupMenu1 = new javax.swing.JPopupMenu(); setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE); setPreferredSize(new java.awt.Dimension(662, 466)); javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane()); getContentPane().setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 601, Short.MAX_VALUE) ); layout.setVerticalGroup( layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGap(0, 408, Short.MAX_VALUE) ); pack(); }// </editor-fold>//GEN-END:initComponents /** * @param args the command line arguments */ public static void main(String args[]) { /* Set the Nimbus look and feel */ //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) "> /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel. * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html */ try { for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) { if ("Nimbus".equals(info.getName())) { javax.swing.UIManager.setLookAndFeel(info.getClassName()); break; } } } catch (ClassNotFoundException ex) { java.util.logging.Logger.getLogger(NewJFrameStat.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); } catch (InstantiationException ex) { java.util.logging.Logger.getLogger(NewJFrameStat.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); } catch (IllegalAccessException ex) { java.util.logging.Logger.getLogger(NewJFrameStat.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); } catch (javax.swing.UnsupportedLookAndFeelException ex) { java.util.logging.Logger.getLogger(NewJFrameStat.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); } //</editor-fold> /* Create and display the form */ java.awt.EventQueue.invokeLater(new Runnable() { public void run() { new NewJFrameStat().setVisible(true); } }); } // Variables declaration - do not modify//GEN-BEGIN:variables private javax.swing.JPopupMenu jPopupMenu1; // End of variables declaration//GEN-END:variables }
[ "ESPRIT@dali-PC" ]
ESPRIT@dali-PC
61f872e63d6fd01467fdf4871b5350e86b49af2f
e4e974cb7ba01d66a578e8e2d5b629858fadd4d1
/rc4.java
b729910132fe77de120f205e19b7089825f03142
[]
no_license
Harisathwik/exam
4560453cfafb4f53abbf6ff5b20a671b862cf6cf
86c8a3695bfdfb3da5fe43cfb2947a974bb9eb4a
refs/heads/main
2023-01-24T22:04:08.378304
2020-12-09T17:02:27
2020-12-09T17:02:27
319,072,756
0
0
null
null
null
null
UTF-8
Java
false
false
1,702
java
import java.util.Scanner; import java.lang.Math; import java.nio.charset.StandardCharsets; class rc4 { static void print(byte a[], int n) { for(int i=0;i<n;i++) { System.out.print(a[i]+" "); } System.out.println(); } public static void main(String[] args) { Scanner ob = new Scanner(System.in); System.out.println("Enter msg:"); String msg = ob.nextLine(); byte[] bytemsg = msg.getBytes(); print(bytemsg,msg.length()); System.out.println("Enter key:"); String key = ob.nextLine(); int i,j,k; byte[] s = new byte[256]; for(i=0;i<256;i++) { s[i] = (byte)i; } //print(s); j = 0; byte temp; for(i=0;i<256;i++) { j = (j+s[i]+key.charAt(i%key.length()))%256; j = Math.abs(j); temp = s[i]; s[i] = s[j]; s[j] = temp; } //print(s); i = 0; j = 0; int p=0; byte[] streambytes = new byte[256]; for(int x=0;x<msg.length();x++) { i = (i+1)%256; j = (j+s[i])%256; i = Math.abs(i); j = Math.abs(j); temp = s[i]; s[i] = s[j]; s[j] = s[i]; k = s[Math.abs(s[i]+s[j])]%256; k = Math.abs(k); //System.out.println(s[k]); streambytes[p] =s[k]; p++; } //Encryption byte[] pt = new byte[256]; byte[] ct = new byte[256]; for(i=0;i<msg.length();i++) { ct[i] = (byte)(streambytes[i] ^ bytemsg[i]); } //print(ct, msg.length()); System.out.println(new String(ct,StandardCharsets.UTF_8)); //Decryption for(i=0;i<msg.length();i++) { pt[i] = (byte)(streambytes[i] ^ ct[i]); } //print(pt, msg.length()); System.out.println(new String(pt,StandardCharsets.UTF_8)); } }
[ "noreply@github.com" ]
Harisathwik.noreply@github.com
a164754879cbcb6bd7b7c3fad5e5e42d5a3ed9ea
b239020d1cd175b918c124d8201f498aa3d3e806
/Section4/OverloadingMethod.java
c23ff61ff8e20aad84b7ea937df591043ac032db
[]
no_license
chipham79/JavaProgrammingMasterClass
02c27924e52202cfbfde223ea2e2898c64fa7eb4
84952724cbf9f42464f6dd42bd7f50d6e2d0b2a6
refs/heads/main
2023-08-21T06:26:29.856180
2021-10-03T14:06:39
2021-10-03T14:06:39
398,738,467
0
0
null
null
null
null
UTF-8
Java
false
false
1,544
java
package Section4; public class OverloadingMethod { public static void main(String[] args) { calcFeetandInchesToCentimeters(6, 0); calcFeetandInchesToCentimeters(7, 5); double centimerter = calcFeetandInchesToCentimeters(-1, 5); if ( centimerter < 0.0) { System.out.println("Invalid Paramaters"); } calcFeetandInchesToCentimeters(100); } public static int calculateScore(int score) { System.out.println("Unname player scored " + score + " poitn"); return score * 1000; } public static int calculateScore(String playerName, int score) { System.out.println("Player " + playerName + " scored " + score + " poitn"); return score * 1000; } public static double calcFeetandInchesToCentimeters(double feet, double inches) { if ( (feet < 0) || ( (inches < 0) && (inches > 12) ) ) { return -1; } double centimeters = feet * 30.48; centimeters += inches * 2.54; System.out.println(String.format("%s feet + %s inches = %s centimers", feet, inches, centimeters)); return centimeters; } public static double calcFeetandInchesToCentimeters(double inches) { if ( inches < 0) { return -1; } double feet = (int) inches / 12; double remainingInches = (int) inches % 12; System.out.println(inches + " inches is equal to " + feet + " feet and " + remainingInches + " inches"); return calcFeetandInchesToCentimeters(feet, inches); } }
[ "69028376+chipham79@users.noreply.github.com" ]
69028376+chipham79@users.noreply.github.com
046e455f29b7107e458df0b0bb499c3d94319d50
e9c37e427076645a7162e06ec537996d9a0791c1
/src/cdrfile/telnet/TelnetClientResponder.java
b191eecd3cf694680716667aa470dda713058941
[]
no_license
thuongnv-soict/cdrfile
b3cefc84a131ae6195acade43b431a0444e453ca
7ec0fcdb96e30e24e5010d43ad4af8918e66f6a6
refs/heads/master
2023-07-09T07:54:43.693090
2018-07-23T08:43:23
2018-07-23T08:43:23
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,518
java
package cdrfile.telnet; import java.io.InputStream; import java.io.OutputStream; /*** * Simple stream responder. * Waits for strings on an input stream and answers * sending corresponfing strings on an output stream. * The reader runs in a separate thread. * <p> * @author Bruno D'Avanzo ***/ public class TelnetClientResponder implements Runnable { InputStream _is; OutputStream _os; String _inputs[], _outputs[]; long _timeout; /*** * Constructor. * Starts a new thread for the reader. * <p> * @param is - InputStream on which to read. * @param os - OutputStream on which to answer. * @param inputs - Array of waited for Strings. * @param inputs - Array of answers. ***/ public TelnetClientResponder(InputStream is, OutputStream os, String inputs[], String outputs[], long timeout) { _is = is; _os = os; _timeout = timeout; _inputs = inputs; _outputs = outputs; Thread reader = new Thread (this); reader.start(); } /*** * Runs the responder ***/ public void run() { boolean result = false; byte buffer[] = new byte[32]; long starttime = System.currentTimeMillis(); try { String readbytes = new String(); while(!result && ((System.currentTimeMillis() - starttime) < _timeout)) { if(_is.available() > 0) { int ret_read = _is.read(buffer); readbytes = readbytes + new String(buffer, 0, ret_read); for(int ii=0; ii<_inputs.length; ii++) { if(readbytes.indexOf(_inputs[ii]) >= 0) { Thread.sleep(1000 * ii); _os.write(_outputs[ii].getBytes()); result = true; } } } else { Thread.sleep(500); } } } catch (Exception e) { System.err.println("Error while waiting endstring. " + e.getMessage()); } } public static void main(String args[]){ try{ // TelnetTestResponder server = new TelnetTestResponder(23); //server.run(); }catch(Exception de){ de.printStackTrace(); } } }
[ "thuongnv.soict@gmail.com" ]
thuongnv.soict@gmail.com
69f8c747ca0ebc6327307e4719b901443465551e
e5277067d6c74dcd4c7b54120a3941376bc2d4bb
/caritas/build/classes/hilos/Llamame.java
cbf3a23dc45a32f00b74cde1aff7fe8cb146d24e
[]
no_license
0189971/Java
2eaf06246c6b10fbc678a60e6be6c81ab7b452dc
7a7615e45cf13d33f9a0f0584a118f8ede9f7f94
refs/heads/master
2020-04-23T18:35:32.240308
2018-07-20T12:59:02
2018-07-20T12:59:02
null
0
0
null
null
null
null
UTF-8
Java
false
false
501
java
/* * To change this template, choose Tools | Templates * and open the template in the editor. */ package hilos; /** * * @author sdelaot */ public class Llamame { // primera forma de sincronizar //synchronized void llamando( String mensaje ) { System.out.print( "[" + mensaje ); try { Thread.sleep( 1000 ); } catch( InterruptedException e ) { System.out.println( "Interrumpido" ); } System.out.println( "]" ); } }
[ "javisever2@gmail.com" ]
javisever2@gmail.com
950e7bb83a0450eb73f9e35f6ae3b9af44370be0
833811590f41a70e9507001fcd326c1d841f0c30
/app/src/main/java/mx/edu/ittepuc/tpdm_u1_practica1_oscar_ibaez_loreto/MainActivity.java
e21569b6bfa01ee17182b070b8473caa22654476
[]
no_license
oscarilo/TPDMU1Practica1
7460015e216e42355b86d9223f8d6e7e99ed44ff
9d88c1ce87d509cdb292ad1ce31da4fd08ae7109
refs/heads/master
2020-04-22T01:53:38.525637
2019-02-10T21:16:48
2019-02-10T21:16:48
170,028,567
0
0
null
null
null
null
UTF-8
Java
false
false
4,858
java
package mx.edu.ittepuc.tpdm_u1_practica1_oscar_ibaez_loreto; import android.content.DialogInterface; import android.graphics.Color; import android.os.Build; import android.support.v7.app.AlertDialog; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; import android.view.View; import android.widget.Button; import android.widget.EditText; import android.widget.RadioButton; import android.widget.Spinner; import android.widget.Switch; import android.widget.TextView; import android.widget.Toast; public class MainActivity extends AppCompatActivity { EditText producto, descripcion; Spinner cantidad; Switch factura; Button confirmar, validar; RadioButton efectivo,credito; TextView estatus; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); producto = findViewById(R.id.producto); descripcion = findViewById(R.id.descripcion); cantidad = findViewById(R.id.cantidad); factura = findViewById(R.id.factura); confirmar = findViewById(R.id.confirmar); efectivo = findViewById(R.id.efectivo); credito = findViewById(R.id.credito); validar = findViewById(R.id.validar); estatus = findViewById(R.id.estatus); confirmar.setVisibility(View.INVISIBLE); estatus.setVisibility(View.INVISIBLE); validar.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { validar(); } }); confirmar.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { estatus.setVisibility(View.INVISIBLE); String productoText = producto.getText().toString(); String descripcionText = descripcion.getText().toString(); String cantidadProd = cantidad.getSelectedItem().toString(); boolean facturaProd = factura.isChecked(); boolean efectivoProd = efectivo.isChecked(); String factura,efectivo,credito = ""; String cadenaFinal; if(facturaProd){ factura = "Se recibio factura."; } else { factura = "* OJO! NO recibio factura* "; } if(efectivoProd){ efectivo = "El pago se hizo en efectivo."; }else { efectivo = "El pago se hizo con tarjeta de crédito."; } cadenaFinal = "Producto: "+productoText+"\n"+ "Descripción: "+descripcionText+"\n"+ "Cantidad: "+cantidadProd+"\n"+ factura+"\n"+ efectivo ; confirmar(cadenaFinal); } }); }// onCreate private void validar(){ estatus.setVisibility(View.INVISIBLE); if(producto.getText().toString().isEmpty() || descripcion.getText().toString().isEmpty()){ Toast.makeText(this,"Cápture ambos campos del producto!",Toast.LENGTH_LONG).show(); confirmar.setVisibility(View.INVISIBLE); }else{ Toast.makeText(this,"Datos correctos!",Toast.LENGTH_LONG).show(); confirmar.setVisibility(View.VISIBLE); } }// validar private void confirmar(String cadena){ AlertDialog.Builder builder; if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) { builder = new AlertDialog.Builder(this, android.R.style.Theme_Material_Dialog_Alert); } else { builder = new AlertDialog.Builder(this); } builder.setTitle("Resumen de inventario.") .setMessage("¿Son correctos los datos?\n\n"+cadena) .setPositiveButton("Correcto", new DialogInterface.OnClickListener() { public void onClick(DialogInterface dialog, int which) { estatus.setText("CONFIRMADO"); estatus.setTextColor(Color.GREEN); estatus.setVisibility(View.VISIBLE); } }) .setNegativeButton("Cancelar", new DialogInterface.OnClickListener() { public void onClick(DialogInterface dialog, int which) { estatus.setText("CANCELADO"); estatus.setTextColor(Color.RED); estatus.setVisibility(View.VISIBLE); } }) .setIcon(android.R.drawable.ic_dialog_alert) .show(); } }// Class
[ "osabibanezlo@ittepic.edu.mx" ]
osabibanezlo@ittepic.edu.mx
db5975d29dcb832a049a821911e2cfb1cb16de37
d1a6d1e511df6db8d8dd0912526e3875c7e1797d
/genny_JavaWithoutLambdasApi21/applicationModule/src/main/java/applicationModulepackageJava7/Foo167.java
e9dccca0641c788471682ad515d5aaf4a3e6051d
[]
no_license
NikitaKozlov/generated-project-for-desugaring
0bc1443ab3ddc84cd289331c726761585766aea7
81506b3711004185070ca4bb9a93482b70011d36
refs/heads/master
2020-03-20T00:35:06.996525
2018-06-12T09:30:37
2018-06-12T09:30:37
137,049,317
0
0
null
null
null
null
UTF-8
Java
false
false
346
java
package applicationModulepackageJava7; public class Foo167 { public void foo0() { new applicationModulepackageJava7.Foo166().foo5(); } public void foo1() { foo0(); } public void foo2() { foo1(); } public void foo3() { foo2(); } public void foo4() { foo3(); } public void foo5() { foo4(); } }
[ "nikita.e.kozlov@gmail.com" ]
nikita.e.kozlov@gmail.com
eb861a4c794b065e536268857d1d755d4aab92a3
7322f5b42e819ef8da87c3f591da1d7c02881f78
/sokobanGame/src/levels/Pointer2D.java
c5acbfc39b0d341049b49691f980fa791df528ba
[]
no_license
moshesar/Sokoban
98009c6b30bd44c72db22cf49d7b0da78d2a7c89
2a8cf57dfb9ded7dbb80841699aca07739658a47
refs/heads/master
2021-01-11T18:52:13.620312
2017-01-21T14:50:27
2017-01-21T14:50:27
79,642,405
0
0
null
null
null
null
UTF-8
Java
false
false
470
java
package levels; public class Pointer2D { private int x; private int y; public Pointer2D(int x,int y) { this.x=x; this.y=y; } public Pointer2D(Pointer2D p) { this.x=p.x; this.y=p.y; } public int getX() { return x; } public void setX(int x) { this.x = x; } public int getY() { return y; } public void setY(int y) { this.y = y; } public void setPoint(int x, int y) { this.x = x; this.y = y; } }
[ "moshe@192.168.1.3" ]
moshe@192.168.1.3
5c325762648f0790ee5a6424a342cff3e602b3ee
cc732b7cb0426b58b79dfd1739b3a8cb0fb458c3
/app/app/src/main/java/moh/org/zm/smarthealthcommunity/helpers/AppDatabase.java
1c31f194b1bb1be064fd07a6ad21d9180c0e4617
[]
no_license
vipar123/android-health-app
89d1c335a13672154bf5a2de5d5bd9b2a5e05bfa
420949272466b06edda8eda946ac488a0b09d12e
refs/heads/master
2022-12-08T07:16:44.725788
2020-08-30T15:21:49
2020-08-30T15:21:49
287,318,720
0
0
null
null
null
null
UTF-8
Java
false
false
1,792
java
package moh.org.zm.smarthealthcommunity.helpers; import android.content.Context; import android.util.Log; import androidx.room.Database; import androidx.room.Room; import androidx.room.RoomDatabase; import moh.org.zm.smarthealthcommunity.dao.AppointmentDAO; import moh.org.zm.smarthealthcommunity.dao.HivTestingDAO; import moh.org.zm.smarthealthcommunity.dao.PatientDAO; import moh.org.zm.smarthealthcommunity.dao.StableOnCareDAO; import moh.org.zm.smarthealthcommunity.models.Appointment; import moh.org.zm.smarthealthcommunity.models.HivTesting; import moh.org.zm.smarthealthcommunity.models.Patient; import moh.org.zm.smarthealthcommunity.models.StableOnCare; @Database(entities = {Appointment.class, HivTesting.class, Patient.class, StableOnCare.class}, version = 1, exportSchema = false) public abstract class AppDatabase extends RoomDatabase { private static final String LOG_TAG = AppDatabase.class.getSimpleName(); private static final Object LOCK = new Object(); private static final String DATABASE_NAME = "schealthmohdb"; private static AppDatabase sInstance; public static AppDatabase getInstance(Context context) { if (sInstance == null) { synchronized (LOCK) { Log.d(LOG_TAG, "Creating new database instance"); sInstance = Room.databaseBuilder(context.getApplicationContext(), AppDatabase.class, AppDatabase.DATABASE_NAME) .build(); } } Log.d(LOG_TAG, "Getting the database instance"); return sInstance; } public abstract AppointmentDAO appointmentDAO(); public abstract HivTestingDAO hivTestingDAO(); public abstract PatientDAO patientDAO(); public abstract StableOnCareDAO stableOnCareDAO(); }
[ "vipar123@gmail.com" ]
vipar123@gmail.com
bec7f5e04b2793c70777a07f15c17f55f503a649
994d4df22eef10be7953fbf878abec0c3b1f2d11
/app/src/main/java/udacity/com/fanshidong/www/myforecast/Event.java
2da92733fe40d8c29cc3fa55b0a5e5c088c1e536
[]
no_license
fanshidong1993/MyForecast
60fba62c72dd4fd84ba01dd25c84be3f49a34eb8
d9fbcd42fd2965d687e6139069284f60cbd9d49b
refs/heads/master
2021-01-13T08:18:11.830544
2016-09-27T03:56:07
2016-09-27T03:56:07
69,317,466
0
0
null
null
null
null
UTF-8
Java
false
false
113
java
package udacity.com.fanshidong.www.myforecast; /** * Created by shadow on 16/9/27. */ public class Event { }
[ "fanshidong_1993@icloud.com" ]
fanshidong_1993@icloud.com
64ac3c99ae51aba91fc70e8162067ee0d99253a1
d6920bff5730bf8823315e15b0858c68a91db544
/android/Procyon/kawa/lib/scheme/base.java
90aa4f8e91c6e15e21c066a9b784a9560c3e4e25
[]
no_license
AppWerft/Ti.FeitianSmartcardReader
f862f9a2a01e1d2f71e09794aa8ff5e28264e458
48657e262044be3ae8b395065d814e169bd8ad7d
refs/heads/master
2020-05-09T10:54:56.278195
2020-03-17T08:04:07
2020-03-17T08:04:07
181,058,540
2
0
null
null
null
null
UTF-8
Java
false
false
34,527
java
// // Decompiled by Procyon v0.5.36 // package kawa.lib.scheme; import gnu.expr.ModuleInfo; import gnu.lists.Consumer; import gnu.mapping.CallContext; import gnu.kawa.reflect.StaticFieldLocation; import gnu.expr.ModuleBody; public class base extends ModuleBody { public static final StaticFieldLocation bytevector$Qu; public static final StaticFieldLocation make$Mnbytevector; public static final StaticFieldLocation bytevector$Mnlength; public static final StaticFieldLocation bytevector$Mnu8$Mnref; public static final StaticFieldLocation bytevector$Mnu8$Mnset$Ex; public static final StaticFieldLocation bytevector$Mncopy; public static final StaticFieldLocation bytevector$Mncopy$Ex; public static final StaticFieldLocation bytevector$Mnappend; public static final StaticFieldLocation utf8$Mn$Grstring; public static final StaticFieldLocation string$Mn$Grutf8; public static final StaticFieldLocation case; public static final StaticFieldLocation char$Qu; public static final StaticFieldLocation char$Mn$Grinteger; public static final StaticFieldLocation integer$Mn$Grchar; public static final StaticFieldLocation with$Mnexception$Mnhandler; public static final StaticFieldLocation raise; public static final StaticFieldLocation raise$Mncontinuable; public static final StaticFieldLocation guard; public static final StaticFieldLocation error; public static final StaticFieldLocation error$Mnobject$Qu; public static final StaticFieldLocation error$Mnobject$Mnmessage; public static final StaticFieldLocation error$Mnobject$Mnirritants; public static final StaticFieldLocation read$Mnerror$Qu; public static final StaticFieldLocation file$Mnerror$Qu; public static final StaticFieldLocation pair$Qu; public static final StaticFieldLocation cons; public static final StaticFieldLocation null$Qu; public static final StaticFieldLocation set$Mncar$Ex; public static final StaticFieldLocation set$Mncdr$Ex; public static final StaticFieldLocation car; public static final StaticFieldLocation cdr; public static final StaticFieldLocation caar; public static final StaticFieldLocation cadr; public static final StaticFieldLocation cdar; public static final StaticFieldLocation cddr; public static final StaticFieldLocation length; public static final StaticFieldLocation reverse; public static final StaticFieldLocation list$Mntail; public static final StaticFieldLocation list$Mnref; public static final StaticFieldLocation list$Mnset$Ex; public static final StaticFieldLocation list$Qu; public static final StaticFieldLocation make$Mnlist; public static final StaticFieldLocation memq; public static final StaticFieldLocation memv; public static final StaticFieldLocation member; public static final StaticFieldLocation assq; public static final StaticFieldLocation assv; public static final StaticFieldLocation assoc; public static final StaticFieldLocation list$Mncopy; public static final StaticFieldLocation boolean$Qu; public static final StaticFieldLocation boolean$Eq$Qu; public static final StaticFieldLocation symbol$Qu; public static final StaticFieldLocation symbol$Mn$Grstring; public static final StaticFieldLocation symbol$Eq$Qu; public static final StaticFieldLocation string$Mn$Grsymbol; public static final StaticFieldLocation procedure$Qu; public static final StaticFieldLocation values; public static final StaticFieldLocation dynamic$Mnwind; public static final StaticFieldLocation features; public static final StaticFieldLocation number$Qu; public static final StaticFieldLocation complex$Qu; public static final StaticFieldLocation real$Qu; public static final StaticFieldLocation rational$Qu; public static final StaticFieldLocation integer$Qu; public static final StaticFieldLocation exact$Mninteger$Qu; public static final StaticFieldLocation exact$Qu; public static final StaticFieldLocation inexact$Qu; public static final StaticFieldLocation zero$Qu; public static final StaticFieldLocation positive$Qu; public static final StaticFieldLocation negative$Qu; public static final StaticFieldLocation max; public static final StaticFieldLocation min; public static final StaticFieldLocation abs; public static final StaticFieldLocation floor$Sl; public static final StaticFieldLocation truncate$Sl; public static final StaticFieldLocation gcd; public static final StaticFieldLocation lcm; public static final StaticFieldLocation numerator; public static final StaticFieldLocation denominator; public static final StaticFieldLocation floor; public static final StaticFieldLocation ceiling; public static final StaticFieldLocation truncate; public static final StaticFieldLocation round; public static final StaticFieldLocation rationalize; public static final StaticFieldLocation square; public static final StaticFieldLocation inexact; public static final StaticFieldLocation exact; public static final StaticFieldLocation number$Mn$Grstring; public static final StaticFieldLocation string$Mn$Grnumber; public static final StaticFieldLocation exact$Mninteger$Mnsqrt; public static final StaticFieldLocation make$Mnparameter; public static final StaticFieldLocation parameterize; public static final StaticFieldLocation call$Mnwith$Mnport; public static final StaticFieldLocation input$Mnport$Qu; public static final StaticFieldLocation output$Mnport$Qu; public static final StaticFieldLocation textual$Mnport$Qu; public static final StaticFieldLocation binary$Mnport$Qu; public static final StaticFieldLocation port$Qu; public static final StaticFieldLocation input$Mnport$Mnopen$Qu; public static final StaticFieldLocation output$Mnport$Mnopen$Qu; public static final StaticFieldLocation current$Mninput$Mnport; public static final StaticFieldLocation current$Mnoutput$Mnport; public static final StaticFieldLocation current$Mnerror$Mnport; public static final StaticFieldLocation write$Mnchar; public static final StaticFieldLocation write$Mnstring; public static final StaticFieldLocation write$Mnu8; public static final StaticFieldLocation write$Mnbytevector; public static final StaticFieldLocation open$Mninput$Mnstring; public static final StaticFieldLocation open$Mnoutput$Mnstring; public static final StaticFieldLocation get$Mnoutput$Mnstring; public static final StaticFieldLocation open$Mninput$Mnbytevector; public static final StaticFieldLocation open$Mnoutput$Mnbytevector; public static final StaticFieldLocation get$Mnoutput$Mnbytevector; public static final StaticFieldLocation flush$Mnoutput$Mnport; public static final StaticFieldLocation newline; public static final StaticFieldLocation eof$Mnobject$Qu; public static final StaticFieldLocation eof$Mnobject; public static final StaticFieldLocation char$Mnready$Qu; public static final StaticFieldLocation read$Mnchar; public static final StaticFieldLocation peek$Mnchar; public static final StaticFieldLocation read$Mnstring; public static final StaticFieldLocation read$Mnu8; public static final StaticFieldLocation peek$Mnu8; public static final StaticFieldLocation u8$Mnready$Qu; public static final StaticFieldLocation read$Mnbytevector; public static final StaticFieldLocation read$Mnbytevector$Ex; public static final StaticFieldLocation close$Mnport; public static final StaticFieldLocation close$Mninput$Mnport; public static final StaticFieldLocation close$Mnoutput$Mnport; public static final StaticFieldLocation read$Mnline; public static final StaticFieldLocation define$Mnsyntax; public static final StaticFieldLocation define; public static final StaticFieldLocation if; public static final StaticFieldLocation letrec; public static final StaticFieldLocation string$Qu; public static final StaticFieldLocation make$Mnstring; public static final StaticFieldLocation string$Mnlength; public static final StaticFieldLocation string$Mnref; public static final StaticFieldLocation string$Mnset$Ex; public static final StaticFieldLocation char$Eq$Qu; public static final StaticFieldLocation char$Ls$Qu; public static final StaticFieldLocation char$Gr$Qu; public static final StaticFieldLocation char$Ls$Eq$Qu; public static final StaticFieldLocation char$Gr$Eq$Qu; public static final StaticFieldLocation string$Eq$Qu; public static final StaticFieldLocation string$Ls$Qu; public static final StaticFieldLocation string$Gr$Qu; public static final StaticFieldLocation string$Ls$Eq$Qu; public static final StaticFieldLocation string$Gr$Eq$Qu; public static final StaticFieldLocation substring; public static final StaticFieldLocation string$Mn$Grlist; public static final StaticFieldLocation list$Mn$Grstring; public static final StaticFieldLocation string$Mncopy; public static final StaticFieldLocation string$Mncopy$Ex; public static final StaticFieldLocation string$Mnfill$Ex; public static final StaticFieldLocation string$Mnappend; public static final StaticFieldLocation string$Mnmap; public static final StaticFieldLocation string$Mnfor$Mneach; public static final StaticFieldLocation cond; public static final StaticFieldLocation and; public static final StaticFieldLocation or; public static final StaticFieldLocation let; public static final StaticFieldLocation let$St; public static final StaticFieldLocation do; public static final StaticFieldLocation else; public static final StaticFieldLocation $Dt$Dt$Dt; public static final StaticFieldLocation $Eq$Gr; public static final StaticFieldLocation _; public static final StaticFieldLocation unquote; public static final StaticFieldLocation unquote$Mnsplicing; public static final StaticFieldLocation when; public static final StaticFieldLocation unless; public static final StaticFieldLocation let$Mnvalues; public static final StaticFieldLocation let$St$Mnvalues; public static final StaticFieldLocation define$Mnvalues; public static final StaticFieldLocation vector$Qu; public static final StaticFieldLocation make$Mnvector; public static final StaticFieldLocation vector$Mnlength; public static final StaticFieldLocation vector$Mnset$Ex; public static final StaticFieldLocation vector$Mnref; public static final StaticFieldLocation vector$Mn$Grlist; public static final StaticFieldLocation list$Mn$Grvector; public static final StaticFieldLocation vector$Mn$Grstring; public static final StaticFieldLocation string$Mn$Grvector; public static final StaticFieldLocation vector$Mncopy; public static final StaticFieldLocation vector$Mncopy$Ex; public static final StaticFieldLocation vector$Mnfill$Ex; public static final StaticFieldLocation vector$Mnmap; public static final StaticFieldLocation vector$Mnfor$Mneach; public static final StaticFieldLocation define$Mnrecord$Mntype; public static final StaticFieldLocation $St; public static final StaticFieldLocation $Pl; public static final StaticFieldLocation $Mn; public static final StaticFieldLocation $Sl; public static final StaticFieldLocation $Ls; public static final StaticFieldLocation $Ls$Eq; public static final StaticFieldLocation $Eq; public static final StaticFieldLocation $Gr; public static final StaticFieldLocation $Gr$Eq; public static final StaticFieldLocation append; public static final StaticFieldLocation apply; public static final StaticFieldLocation begin; public static final StaticFieldLocation bytevector; public static final StaticFieldLocation call$Mnwith$Mncurrent$Mncontinuation; public static final StaticFieldLocation call$Mnwith$Mnvalues; public static final StaticFieldLocation call$Slcc; public static final StaticFieldLocation cond$Mnexpand; public static final StaticFieldLocation eq$Qu; public static final StaticFieldLocation equal$Qu; public static final StaticFieldLocation eqv$Qu; public static final StaticFieldLocation even$Qu; public static final StaticFieldLocation expt; public static final StaticFieldLocation floor$Mnquotient; public static final StaticFieldLocation floor$Mnremainder; public static final StaticFieldLocation for$Mneach; public static final StaticFieldLocation include; public static final StaticFieldLocation include$Mnci; public static final StaticFieldLocation lambda; public static final StaticFieldLocation let$Mnsyntax; public static final StaticFieldLocation letrec$Mnsyntax; public static final StaticFieldLocation list; public static final StaticFieldLocation map; public static final StaticFieldLocation modulo; public static final StaticFieldLocation not; public static final StaticFieldLocation odd$Qu; public static final StaticFieldLocation quasiquote; public static final StaticFieldLocation quote; public static final StaticFieldLocation quotient; public static final StaticFieldLocation remainder; public static final StaticFieldLocation set$Ex; public static final StaticFieldLocation string; public static final StaticFieldLocation syntax$Mnerror; public static final StaticFieldLocation syntax$Mnrules; public static final StaticFieldLocation truncate$Mnquotient; public static final StaticFieldLocation truncate$Mnremainder; public static final StaticFieldLocation vector; public static final StaticFieldLocation vector$Mnappend; public static final StaticFieldLocation letrec$St; public static base $instance; private static void $runBody$() { final CallContext $ctx; final Consumer $result = ($ctx = CallContext.getInstance()).consumer; } static { base.$instance = new base(); bytevector$Qu = StaticFieldLocation.make("kawa.lib.bytevectors", "bytevector$Qu"); make$Mnbytevector = StaticFieldLocation.make("kawa.lib.bytevectors", "make$Mnbytevector"); bytevector$Mnlength = StaticFieldLocation.make("kawa.lib.bytevectors", "bytevector$Mnlength"); bytevector$Mnu8$Mnref = StaticFieldLocation.make("kawa.lib.bytevectors", "bytevector$Mnu8$Mnref"); bytevector$Mnu8$Mnset$Ex = StaticFieldLocation.make("kawa.lib.bytevectors", "bytevector$Mnu8$Mnset$Ex"); bytevector$Mncopy = StaticFieldLocation.make("kawa.lib.bytevectors", "bytevector$Mncopy"); bytevector$Mncopy$Ex = StaticFieldLocation.make("kawa.lib.bytevectors", "bytevector$Mncopy$Ex"); bytevector$Mnappend = StaticFieldLocation.make("kawa.lib.bytevectors", "bytevector$Mnappend"); utf8$Mn$Grstring = StaticFieldLocation.make("kawa.lib.bytevectors", "utf8$Mn$Grstring"); string$Mn$Grutf8 = StaticFieldLocation.make("kawa.lib.bytevectors", "string$Mn$Grutf8"); case = StaticFieldLocation.make("kawa.lib.case_syntax", "case"); char$Qu = StaticFieldLocation.make("kawa.lib.characters", "char$Qu"); char$Mn$Grinteger = StaticFieldLocation.make("kawa.lib.characters", "char$Mn$Grinteger"); integer$Mn$Grchar = StaticFieldLocation.make("kawa.lib.characters", "integer$Mn$Grchar"); with$Mnexception$Mnhandler = StaticFieldLocation.make("kawa.lib.exceptions", "with$Mnexception$Mnhandler"); raise = StaticFieldLocation.make("kawa.lib.exceptions", "raise"); raise$Mncontinuable = StaticFieldLocation.make("kawa.lib.exceptions", "raise$Mncontinuable"); guard = StaticFieldLocation.make("kawa.lib.exceptions", "guard"); error = StaticFieldLocation.make("kawa.lib.exceptions", "error"); error$Mnobject$Qu = StaticFieldLocation.make("kawa.lib.exceptions", "error$Mnobject$Qu"); error$Mnobject$Mnmessage = StaticFieldLocation.make("kawa.lib.exceptions", "error$Mnobject$Mnmessage"); error$Mnobject$Mnirritants = StaticFieldLocation.make("kawa.lib.exceptions", "error$Mnobject$Mnirritants"); read$Mnerror$Qu = StaticFieldLocation.make("kawa.lib.exceptions", "read$Mnerror$Qu"); file$Mnerror$Qu = StaticFieldLocation.make("kawa.lib.exceptions", "file$Mnerror$Qu"); pair$Qu = StaticFieldLocation.make("kawa.lib.lists", "pair$Qu"); cons = StaticFieldLocation.make("kawa.lib.lists", "cons"); null$Qu = StaticFieldLocation.make("kawa.lib.lists", "null$Qu"); set$Mncar$Ex = StaticFieldLocation.make("kawa.lib.lists", "set$Mncar$Ex"); set$Mncdr$Ex = StaticFieldLocation.make("kawa.lib.lists", "set$Mncdr$Ex"); car = StaticFieldLocation.make("kawa.lib.lists", "car"); cdr = StaticFieldLocation.make("kawa.lib.lists", "cdr"); caar = StaticFieldLocation.make("kawa.lib.lists", "caar"); cadr = StaticFieldLocation.make("kawa.lib.lists", "cadr"); cdar = StaticFieldLocation.make("kawa.lib.lists", "cdar"); cddr = StaticFieldLocation.make("kawa.lib.lists", "cddr"); length = StaticFieldLocation.make("kawa.lib.lists", "length"); reverse = StaticFieldLocation.make("kawa.lib.lists", "reverse"); list$Mntail = StaticFieldLocation.make("kawa.lib.lists", "list$Mntail"); list$Mnref = StaticFieldLocation.make("kawa.lib.lists", "list$Mnref"); list$Mnset$Ex = StaticFieldLocation.make("kawa.lib.lists", "list$Mnset$Ex"); list$Qu = StaticFieldLocation.make("kawa.lib.lists", "list$Qu"); make$Mnlist = StaticFieldLocation.make("kawa.lib.lists", "make$Mnlist"); memq = StaticFieldLocation.make("kawa.lib.lists", "memq"); memv = StaticFieldLocation.make("kawa.lib.lists", "memv"); member = StaticFieldLocation.make("kawa.lib.lists", "member"); assq = StaticFieldLocation.make("kawa.lib.lists", "assq"); assv = StaticFieldLocation.make("kawa.lib.lists", "assv"); assoc = StaticFieldLocation.make("kawa.lib.lists", "assoc"); list$Mncopy = StaticFieldLocation.make("kawa.lib.lists", "list$Mncopy"); boolean$Qu = StaticFieldLocation.make("kawa.lib.misc", "boolean$Qu"); boolean$Eq$Qu = StaticFieldLocation.make("kawa.lib.misc", "boolean$Eq$Qu"); symbol$Qu = StaticFieldLocation.make("kawa.lib.misc", "symbol$Qu"); symbol$Mn$Grstring = StaticFieldLocation.make("kawa.lib.misc", "symbol$Mn$Grstring"); symbol$Eq$Qu = StaticFieldLocation.make("kawa.lib.misc", "symbol$Eq$Qu"); string$Mn$Grsymbol = StaticFieldLocation.make("kawa.lib.misc", "string$Mn$Grsymbol"); procedure$Qu = StaticFieldLocation.make("kawa.lib.misc", "procedure$Qu"); values = StaticFieldLocation.make("kawa.lib.misc", "values"); dynamic$Mnwind = StaticFieldLocation.make("kawa.lib.misc", "dynamic$Mnwind"); features = StaticFieldLocation.make("kawa.lib.misc", "features"); number$Qu = StaticFieldLocation.make("kawa.lib.numbers", "number$Qu"); complex$Qu = StaticFieldLocation.make("kawa.lib.numbers", "complex$Qu"); real$Qu = StaticFieldLocation.make("kawa.lib.numbers", "real$Qu"); rational$Qu = StaticFieldLocation.make("kawa.lib.numbers", "rational$Qu"); integer$Qu = StaticFieldLocation.make("kawa.lib.numbers", "integer$Qu"); exact$Mninteger$Qu = StaticFieldLocation.make("kawa.lib.numbers", "exact$Mninteger$Qu"); exact$Qu = StaticFieldLocation.make("kawa.lib.numbers", "exact$Qu"); inexact$Qu = StaticFieldLocation.make("kawa.lib.numbers", "inexact$Qu"); zero$Qu = StaticFieldLocation.make("kawa.lib.numbers", "zero$Qu"); positive$Qu = StaticFieldLocation.make("kawa.lib.numbers", "positive$Qu"); negative$Qu = StaticFieldLocation.make("kawa.lib.numbers", "negative$Qu"); max = StaticFieldLocation.make("kawa.lib.numbers", "max"); min = StaticFieldLocation.make("kawa.lib.numbers", "min"); abs = StaticFieldLocation.make("kawa.lib.numbers", "abs"); floor$Sl = StaticFieldLocation.make("kawa.lib.numbers", "floor$Sl"); truncate$Sl = StaticFieldLocation.make("kawa.lib.numbers", "truncate$Sl"); gcd = StaticFieldLocation.make("kawa.lib.numbers", "gcd"); lcm = StaticFieldLocation.make("kawa.lib.numbers", "lcm"); numerator = StaticFieldLocation.make("kawa.lib.numbers", "numerator"); denominator = StaticFieldLocation.make("kawa.lib.numbers", "denominator"); floor = StaticFieldLocation.make("kawa.lib.numbers", "floor"); ceiling = StaticFieldLocation.make("kawa.lib.numbers", "ceiling"); truncate = StaticFieldLocation.make("kawa.lib.numbers", "truncate"); round = StaticFieldLocation.make("kawa.lib.numbers", "round"); rationalize = StaticFieldLocation.make("kawa.lib.numbers", "rationalize"); square = StaticFieldLocation.make("kawa.lib.numbers", "square"); inexact = StaticFieldLocation.make("kawa.lib.numbers", "inexact"); exact = StaticFieldLocation.make("kawa.lib.numbers", "exact"); number$Mn$Grstring = StaticFieldLocation.make("kawa.lib.numbers", "number$Mn$Grstring"); string$Mn$Grnumber = StaticFieldLocation.make("kawa.lib.numbers", "string$Mn$Grnumber"); exact$Mninteger$Mnsqrt = StaticFieldLocation.make("kawa.lib.numbers", "exact$Mninteger$Mnsqrt"); make$Mnparameter = StaticFieldLocation.make("kawa.lib.parameters", "make$Mnparameter"); parameterize = StaticFieldLocation.make("kawa.lib.parameterize", "parameterize"); call$Mnwith$Mnport = StaticFieldLocation.make("kawa.lib.ports", "call$Mnwith$Mnport"); input$Mnport$Qu = StaticFieldLocation.make("kawa.lib.ports", "input$Mnport$Qu"); output$Mnport$Qu = StaticFieldLocation.make("kawa.lib.ports", "output$Mnport$Qu"); textual$Mnport$Qu = StaticFieldLocation.make("kawa.lib.ports", "textual$Mnport$Qu"); binary$Mnport$Qu = StaticFieldLocation.make("kawa.lib.ports", "binary$Mnport$Qu"); port$Qu = StaticFieldLocation.make("kawa.lib.ports", "port$Qu"); input$Mnport$Mnopen$Qu = StaticFieldLocation.make("kawa.lib.ports", "input$Mnport$Mnopen$Qu"); output$Mnport$Mnopen$Qu = StaticFieldLocation.make("kawa.lib.ports", "output$Mnport$Mnopen$Qu"); current$Mninput$Mnport = StaticFieldLocation.make("kawa.lib.ports", "current$Mninput$Mnport"); current$Mnoutput$Mnport = StaticFieldLocation.make("kawa.lib.ports", "current$Mnoutput$Mnport"); current$Mnerror$Mnport = StaticFieldLocation.make("kawa.lib.ports", "current$Mnerror$Mnport"); write$Mnchar = StaticFieldLocation.make("kawa.lib.ports", "write$Mnchar"); write$Mnstring = StaticFieldLocation.make("kawa.lib.ports", "write$Mnstring"); write$Mnu8 = StaticFieldLocation.make("kawa.lib.ports", "write$Mnu8"); write$Mnbytevector = StaticFieldLocation.make("kawa.lib.ports", "write$Mnbytevector"); open$Mninput$Mnstring = StaticFieldLocation.make("kawa.lib.ports", "open$Mninput$Mnstring"); open$Mnoutput$Mnstring = StaticFieldLocation.make("kawa.lib.ports", "open$Mnoutput$Mnstring"); get$Mnoutput$Mnstring = StaticFieldLocation.make("kawa.lib.ports", "get$Mnoutput$Mnstring"); open$Mninput$Mnbytevector = StaticFieldLocation.make("kawa.lib.ports", "open$Mninput$Mnbytevector"); open$Mnoutput$Mnbytevector = StaticFieldLocation.make("kawa.lib.ports", "open$Mnoutput$Mnbytevector"); get$Mnoutput$Mnbytevector = StaticFieldLocation.make("kawa.lib.ports", "get$Mnoutput$Mnbytevector"); flush$Mnoutput$Mnport = StaticFieldLocation.make("kawa.lib.ports", "flush$Mnoutput$Mnport"); newline = StaticFieldLocation.make("kawa.lib.ports", "newline"); eof$Mnobject$Qu = StaticFieldLocation.make("kawa.lib.ports", "eof$Mnobject$Qu"); eof$Mnobject = StaticFieldLocation.make("kawa.lib.ports", "eof$Mnobject"); char$Mnready$Qu = StaticFieldLocation.make("kawa.lib.ports", "char$Mnready$Qu"); read$Mnchar = StaticFieldLocation.make("kawa.lib.ports", "read$Mnchar"); peek$Mnchar = StaticFieldLocation.make("kawa.lib.ports", "peek$Mnchar"); read$Mnstring = StaticFieldLocation.make("kawa.lib.ports", "read$Mnstring"); read$Mnu8 = StaticFieldLocation.make("kawa.lib.ports", "read$Mnu8"); peek$Mnu8 = StaticFieldLocation.make("kawa.lib.ports", "peek$Mnu8"); u8$Mnready$Qu = StaticFieldLocation.make("kawa.lib.ports", "u8$Mnready$Qu"); read$Mnbytevector = StaticFieldLocation.make("kawa.lib.ports", "read$Mnbytevector"); read$Mnbytevector$Ex = StaticFieldLocation.make("kawa.lib.ports", "read$Mnbytevector$Ex"); close$Mnport = StaticFieldLocation.make("kawa.lib.ports", "close$Mnport"); close$Mninput$Mnport = StaticFieldLocation.make("kawa.lib.ports", "close$Mninput$Mnport"); close$Mnoutput$Mnport = StaticFieldLocation.make("kawa.lib.ports", "close$Mnoutput$Mnport"); read$Mnline = StaticFieldLocation.make("kawa.lib.ports", "read$Mnline"); define$Mnsyntax = StaticFieldLocation.make("kawa.lib.prim_syntax", "define$Mnsyntax"); define = StaticFieldLocation.make("kawa.lib.prim_syntax", "define"); if = StaticFieldLocation.make("kawa.lib.prim_syntax", "if"); letrec = StaticFieldLocation.make("kawa.lib.prim_syntax", "letrec"); string$Qu = StaticFieldLocation.make("kawa.lib.strings", "string$Qu"); make$Mnstring = StaticFieldLocation.make("kawa.lib.strings", "make$Mnstring"); string$Mnlength = StaticFieldLocation.make("kawa.lib.strings", "string$Mnlength"); string$Mnref = StaticFieldLocation.make("kawa.lib.strings", "string$Mnref"); string$Mnset$Ex = StaticFieldLocation.make("kawa.lib.strings", "string$Mnset$Ex"); char$Eq$Qu = StaticFieldLocation.make("kawa.lib.strings", "char$Eq$Qu"); char$Ls$Qu = StaticFieldLocation.make("kawa.lib.strings", "char$Ls$Qu"); char$Gr$Qu = StaticFieldLocation.make("kawa.lib.strings", "char$Gr$Qu"); char$Ls$Eq$Qu = StaticFieldLocation.make("kawa.lib.strings", "char$Ls$Eq$Qu"); char$Gr$Eq$Qu = StaticFieldLocation.make("kawa.lib.strings", "char$Gr$Eq$Qu"); string$Eq$Qu = StaticFieldLocation.make("kawa.lib.strings", "string$Eq$Qu"); string$Ls$Qu = StaticFieldLocation.make("kawa.lib.strings", "string$Ls$Qu"); string$Gr$Qu = StaticFieldLocation.make("kawa.lib.strings", "string$Gr$Qu"); string$Ls$Eq$Qu = StaticFieldLocation.make("kawa.lib.strings", "string$Ls$Eq$Qu"); string$Gr$Eq$Qu = StaticFieldLocation.make("kawa.lib.strings", "string$Gr$Eq$Qu"); substring = StaticFieldLocation.make("kawa.lib.strings", "substring"); string$Mn$Grlist = StaticFieldLocation.make("kawa.lib.strings", "string$Mn$Grlist"); list$Mn$Grstring = StaticFieldLocation.make("kawa.lib.strings", "list$Mn$Grstring"); string$Mncopy = StaticFieldLocation.make("kawa.lib.strings", "string$Mncopy"); string$Mncopy$Ex = StaticFieldLocation.make("kawa.lib.strings", "string$Mncopy$Ex"); string$Mnfill$Ex = StaticFieldLocation.make("kawa.lib.strings", "string$Mnfill$Ex"); string$Mnappend = StaticFieldLocation.make("kawa.lib.strings", "string$Mnappend"); string$Mnmap = StaticFieldLocation.make("kawa.lib.strings", "string$Mnmap"); string$Mnfor$Mneach = StaticFieldLocation.make("kawa.lib.strings", "string$Mnfor$Mneach"); cond = StaticFieldLocation.make("kawa.lib.std_syntax", "cond"); and = StaticFieldLocation.make("kawa.lib.std_syntax", "and"); or = StaticFieldLocation.make("kawa.lib.std_syntax", "or"); let = StaticFieldLocation.make("kawa.lib.std_syntax", "let"); let$St = StaticFieldLocation.make("kawa.lib.std_syntax", "let$St"); do = StaticFieldLocation.make("kawa.lib.std_syntax", "do"); else = StaticFieldLocation.make("kawa.lib.std_syntax", "else"); $Dt$Dt$Dt = StaticFieldLocation.make("kawa.lib.std_syntax", "$Dt$Dt$Dt"); $Eq$Gr = StaticFieldLocation.make("kawa.lib.std_syntax", "$Eq$Gr"); _ = StaticFieldLocation.make("kawa.lib.std_syntax", "_"); unquote = StaticFieldLocation.make("kawa.lib.std_syntax", "unquote"); unquote$Mnsplicing = StaticFieldLocation.make("kawa.lib.std_syntax", "unquote$Mnsplicing"); when = StaticFieldLocation.make("kawa.lib.syntax", "when"); unless = StaticFieldLocation.make("kawa.lib.syntax", "unless"); let$Mnvalues = StaticFieldLocation.make("kawa.lib.syntax", "let$Mnvalues"); let$St$Mnvalues = StaticFieldLocation.make("kawa.lib.syntax", "let$St$Mnvalues"); define$Mnvalues = StaticFieldLocation.make("kawa.lib.syntax", "define$Mnvalues"); vector$Qu = StaticFieldLocation.make("kawa.lib.vectors", "vector$Qu"); make$Mnvector = StaticFieldLocation.make("kawa.lib.vectors", "make$Mnvector"); vector$Mnlength = StaticFieldLocation.make("kawa.lib.vectors", "vector$Mnlength"); vector$Mnset$Ex = StaticFieldLocation.make("kawa.lib.vectors", "vector$Mnset$Ex"); vector$Mnref = StaticFieldLocation.make("kawa.lib.vectors", "vector$Mnref"); vector$Mn$Grlist = StaticFieldLocation.make("kawa.lib.vectors", "vector$Mn$Grlist"); list$Mn$Grvector = StaticFieldLocation.make("kawa.lib.vectors", "list$Mn$Grvector"); vector$Mn$Grstring = StaticFieldLocation.make("kawa.lib.vectors", "vector$Mn$Grstring"); string$Mn$Grvector = StaticFieldLocation.make("kawa.lib.vectors", "string$Mn$Grvector"); vector$Mncopy = StaticFieldLocation.make("kawa.lib.vectors", "vector$Mncopy"); vector$Mncopy$Ex = StaticFieldLocation.make("kawa.lib.vectors", "vector$Mncopy$Ex"); vector$Mnfill$Ex = StaticFieldLocation.make("kawa.lib.vectors", "vector$Mnfill$Ex"); vector$Mnmap = StaticFieldLocation.make("kawa.lib.vectors", "vector$Mnmap"); vector$Mnfor$Mneach = StaticFieldLocation.make("kawa.lib.vectors", "vector$Mnfor$Mneach"); define$Mnrecord$Mntype = StaticFieldLocation.make("kawa.lib.DefineRecordType", "define$Mnrecord$Mntype"); $St = StaticFieldLocation.make("gnu.kawa.functions.MultiplyOp", "$St"); $Pl = StaticFieldLocation.make("gnu.kawa.functions.AddOp", "$Pl"); $Mn = StaticFieldLocation.make("gnu.kawa.functions.AddOp", "$Mn"); $Sl = StaticFieldLocation.make("gnu.kawa.functions.DivideOp", "$Sl"); $Ls = StaticFieldLocation.make("kawa.standard.Scheme", "numLss"); $Ls$Eq = StaticFieldLocation.make("kawa.standard.Scheme", "numLEq"); $Eq = StaticFieldLocation.make("kawa.standard.Scheme", "numEqu"); $Gr = StaticFieldLocation.make("kawa.standard.Scheme", "numGrt"); $Gr$Eq = StaticFieldLocation.make("kawa.standard.Scheme", "numGEq"); append = StaticFieldLocation.make("kawa.standard.append", "append"); apply = StaticFieldLocation.make("kawa.standard.Scheme", "apply"); begin = StaticFieldLocation.make("kawa.standard.begin", "begin"); bytevector = StaticFieldLocation.make("gnu.kawa.lispexpr.LangObjType", "u8vectorType"); call$Mnwith$Mncurrent$Mncontinuation = StaticFieldLocation.make("gnu.kawa.functions.CallCC", "callcc"); call$Mnwith$Mnvalues = StaticFieldLocation.make("gnu.kawa.functions.CallWithValues", "callWithValues"); call$Slcc = StaticFieldLocation.make("gnu.kawa.functions.CallCC", "callcc"); cond$Mnexpand = StaticFieldLocation.make("kawa.standard.IfFeature", "condExpand"); eq$Qu = StaticFieldLocation.make("kawa.standard.Scheme", "isEq"); equal$Qu = StaticFieldLocation.make("kawa.standard.Scheme", "isEqual"); eqv$Qu = StaticFieldLocation.make("kawa.standard.Scheme", "isEqv"); even$Qu = StaticFieldLocation.make("kawa.standard.Scheme", "isEven"); expt = StaticFieldLocation.make("kawa.standard.expt", "expt"); floor$Mnquotient = StaticFieldLocation.make("gnu.kawa.functions.DivideOp", "floorQuotient"); floor$Mnremainder = StaticFieldLocation.make("gnu.kawa.functions.DivideOp", "modulo"); for$Mneach = StaticFieldLocation.make("kawa.standard.Scheme", "forEach"); include = StaticFieldLocation.make("kawa.standard.Include", "include"); include$Mnci = StaticFieldLocation.make("kawa.standard.Include", "includeCi"); lambda = StaticFieldLocation.make("kawa.standard.SchemeCompilation", "lambda"); let$Mnsyntax = StaticFieldLocation.make("kawa.standard.let_syntax", "let_syntax"); letrec$Mnsyntax = StaticFieldLocation.make("kawa.standard.let_syntax", "letrec_syntax"); list = StaticFieldLocation.make("gnu.kawa.lispexpr.LangObjType", "listType"); map = StaticFieldLocation.make("kawa.standard.Scheme", "map"); modulo = StaticFieldLocation.make("gnu.kawa.functions.DivideOp", "modulo"); not = StaticFieldLocation.make("kawa.standard.Scheme", "not"); odd$Qu = StaticFieldLocation.make("kawa.standard.Scheme", "isOdd"); quasiquote = StaticFieldLocation.make("kawa.lang.Quote", "quasiQuote"); quote = StaticFieldLocation.make("kawa.lang.Quote", "plainQuote"); quotient = StaticFieldLocation.make("gnu.kawa.functions.DivideOp", "quotient"); remainder = StaticFieldLocation.make("gnu.kawa.functions.DivideOp", "remainder"); set$Ex = StaticFieldLocation.make("kawa.standard.set_b", "set"); string = StaticFieldLocation.make("gnu.kawa.lispexpr.LangObjType", "stringType"); syntax$Mnerror = StaticFieldLocation.make("kawa.standard.syntax_error", "syntax_error"); syntax$Mnrules = StaticFieldLocation.make("kawa.standard.syntax_rules", "syntax_rules"); truncate$Mnquotient = StaticFieldLocation.make("gnu.kawa.functions.DivideOp", "quotient"); truncate$Mnremainder = StaticFieldLocation.make("gnu.kawa.functions.DivideOp", "remainder"); vector = StaticFieldLocation.make("gnu.kawa.lispexpr.LangObjType", "vectorType"); vector$Mnappend = StaticFieldLocation.make("kawa.standard.vector_append", "vectorAppend"); letrec$St = StaticFieldLocation.make("kawa.lib.prim_syntax", "letrec"); $runBody$(); } public base() { ModuleInfo.register(this); } }
[ "“rs@hamburger-appwerft.de“" ]
“rs@hamburger-appwerft.de“
97b0be4f7b8dee499a58a005254d689c70e62c98
fca16341e3449476a80aa3bd5ca30c0669d9a5e9
/src/main/java/roomsharing/repository/RoomInfoRepository.java
4c0567791753514f8ff7eb6a41260c5a9b45e40e
[]
no_license
Kimoanh99/team3_room
72a9bcefb51030bf2985e01b61482a316ce611d6
2fe58c6ea4cd82620cd92c5b844446015dd68967
refs/heads/master
2023-08-19T21:00:14.451179
2021-10-06T07:00:54
2021-10-06T07:00:54
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,477
java
package roomsharing.repository; import org.springframework.data.jpa.repository.JpaRepository; import org.springframework.data.jpa.repository.Query; import org.springframework.data.repository.query.Param; import org.springframework.stereotype.Repository; import roomsharing.dto.room.SearchRoomDto; import roomsharing.entity.RoomInfoEntity; import java.util.List; import java.util.UUID; @Repository public interface RoomInfoRepository extends JpaRepository<RoomInfoEntity, UUID> { RoomInfoEntity findFirstByRoomId(UUID roomId); void deleteByRoomId(UUID rooms); @Query("SELECT u FROM RoomInfoEntity u"+ " WHERE (:#{#search.provinceId} is null OR u.provinceId = :#{#search.provinceId})"+ " AND (:#{#search.wardId} is null OR u.wardId =:#{#search.wardId})"+ " AND (:#{#search.districtId} is null OR u.districtId = :#{#search.districtId})"+ " AND (:#{#search.fromAcreage} is null OR u.acreage >= :#{#search.fromAcreage})"+ " AND (:#{#search.toAcreage} is null OR u.acreage <= :#{#search.toAcreage})" + " AND (:#{#search.fromRoomPrice} is null OR u.roomPrice >= :#{#search.fromRoomPrice})"+ " AND (:#{#search.toRoomPrice} is null OR u.roomPrice <= :#{#search.toRoomPrice})"+ " AND (:#{#search.getValueStatusHired()} is null OR u.statusHired = :#{#search.getValueStatusHired()})" ) List<RoomInfoEntity> findRoomInfo(@Param("search") SearchRoomDto searchRoomDto); }
[ "minhhieua.1910@gmail.com" ]
minhhieua.1910@gmail.com
7fc0a1cec4931e347c33bc3882fdaca1bfd4d5f2
1a8f72bb4ada758e105cf88353ec231307948fb9
/src/main/java/util/ArrayUtil.java
09660a85070804fdbc93aa10b77bc503ad52c141
[]
no_license
kpilyugin/server-architectures
6c16551830ef5b6deeeff446fe4869a52b1e8678
a312db07847499c11e732071e4d6d1427d9a3cca
refs/heads/master
2021-01-12T07:24:03.831155
2016-12-25T14:49:27
2016-12-25T14:49:27
76,949,635
0
0
null
null
null
null
UTF-8
Java
false
false
365
java
package util; import java.util.Random; public class ArrayUtil { public static int[] randomArray(int size) { return new Random().ints(size, 0, size).toArray(); } public static boolean isSorted(int[] array) { for (int i = 0; i < array.length - 1; i++) { if (array[i] > array[i + 1]) { return false; } } return true; } }
[ "kirillpilyugin@gmail.com" ]
kirillpilyugin@gmail.com
011c5529d3ef9cdbb2c1241988687fe4d54cd1ad
3482c872c73268055c24abe26fc853252226bd3f
/source/eu.artist.migration.deployment.azure.service.definition/src/eu/artist/migration/deployment/azure/csdef/impl/AllocatePublicPortFromElementImpl.java
ddd139c675611912a7235bd193d87a1d2985af6d
[]
no_license
artist-project/ARTIST-Deployment_Tool
68ba341149de60c796cb177d51c62a619aa38b8d
1de2968be4716f0912b169ca0e2e93658c86659a
refs/heads/master
2021-01-10T13:55:42.589294
2015-06-04T06:58:10
2015-06-04T06:58:10
36,853,643
0
2
null
null
null
null
UTF-8
Java
false
false
5,164
java
/** */ package eu.artist.migration.deployment.azure.csdef.impl; import eu.artist.migration.deployment.azure.csdef.AllocatePublicPortFromElement; import eu.artist.migration.deployment.azure.csdef.AzureCSDefPackage; import eu.artist.migration.deployment.azure.csdef.PortRange; import org.eclipse.emf.common.notify.Notification; import org.eclipse.emf.common.notify.NotificationChain; import org.eclipse.emf.ecore.EClass; import org.eclipse.emf.ecore.InternalEObject; import org.eclipse.emf.ecore.impl.ENotificationImpl; import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; /** * <!-- begin-user-doc --> * An implementation of the model object '<em><b>Allocate Public Port From Element</b></em>'. * <!-- end-user-doc --> * <p> * The following features are implemented: * <ul> * <li>{@link eu.artist.migration.deployment.azure.csdef.impl.AllocatePublicPortFromElementImpl#getFixedPortRange <em>Fixed Port Range</em>}</li> * </ul> * </p> * * @generated */ public class AllocatePublicPortFromElementImpl extends MinimalEObjectImpl.Container implements AllocatePublicPortFromElement { /** * The cached value of the '{@link #getFixedPortRange() <em>Fixed Port Range</em>}' containment reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @see #getFixedPortRange() * @generated * @ordered */ protected PortRange fixedPortRange; /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ protected AllocatePublicPortFromElementImpl() { super(); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override protected EClass eStaticClass() { return AzureCSDefPackage.Literals.ALLOCATE_PUBLIC_PORT_FROM_ELEMENT; } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public PortRange getFixedPortRange() { return fixedPortRange; } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public NotificationChain basicSetFixedPortRange(PortRange newFixedPortRange, NotificationChain msgs) { PortRange oldFixedPortRange = fixedPortRange; fixedPortRange = newFixedPortRange; if (eNotificationRequired()) { ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, AzureCSDefPackage.ALLOCATE_PUBLIC_PORT_FROM_ELEMENT__FIXED_PORT_RANGE, oldFixedPortRange, newFixedPortRange); if (msgs == null) msgs = notification; else msgs.add(notification); } return msgs; } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public void setFixedPortRange(PortRange newFixedPortRange) { if (newFixedPortRange != fixedPortRange) { NotificationChain msgs = null; if (fixedPortRange != null) msgs = ((InternalEObject)fixedPortRange).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - AzureCSDefPackage.ALLOCATE_PUBLIC_PORT_FROM_ELEMENT__FIXED_PORT_RANGE, null, msgs); if (newFixedPortRange != null) msgs = ((InternalEObject)newFixedPortRange).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - AzureCSDefPackage.ALLOCATE_PUBLIC_PORT_FROM_ELEMENT__FIXED_PORT_RANGE, null, msgs); msgs = basicSetFixedPortRange(newFixedPortRange, msgs); if (msgs != null) msgs.dispatch(); } else if (eNotificationRequired()) eNotify(new ENotificationImpl(this, Notification.SET, AzureCSDefPackage.ALLOCATE_PUBLIC_PORT_FROM_ELEMENT__FIXED_PORT_RANGE, newFixedPortRange, newFixedPortRange)); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { switch (featureID) { case AzureCSDefPackage.ALLOCATE_PUBLIC_PORT_FROM_ELEMENT__FIXED_PORT_RANGE: return basicSetFixedPortRange(null, msgs); } return super.eInverseRemove(otherEnd, featureID, msgs); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { case AzureCSDefPackage.ALLOCATE_PUBLIC_PORT_FROM_ELEMENT__FIXED_PORT_RANGE: return getFixedPortRange(); } return super.eGet(featureID, resolve, coreType); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override public void eSet(int featureID, Object newValue) { switch (featureID) { case AzureCSDefPackage.ALLOCATE_PUBLIC_PORT_FROM_ELEMENT__FIXED_PORT_RANGE: setFixedPortRange((PortRange)newValue); return; } super.eSet(featureID, newValue); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override public void eUnset(int featureID) { switch (featureID) { case AzureCSDefPackage.ALLOCATE_PUBLIC_PORT_FROM_ELEMENT__FIXED_PORT_RANGE: setFixedPortRange((PortRange)null); return; } super.eUnset(featureID); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override public boolean eIsSet(int featureID) { switch (featureID) { case AzureCSDefPackage.ALLOCATE_PUBLIC_PORT_FROM_ELEMENT__FIXED_PORT_RANGE: return fixedPortRange != null; } return super.eIsSet(featureID); } } //AllocatePublicPortFromElementImpl
[ "burak.karaboga@atos.net" ]
burak.karaboga@atos.net
3de7ab7bf58d00b8904ffd3d54a9bd980613a4d1
52ea2e9841a60a5805b8f4edece50b6b916d145f
/booking3.java
c2d4f421cb5d9396061ef88f7aa17ec4474b59d1
[]
no_license
PranitBhatt/salon
156519be9f92ee8792473a08ac985dc728815f93
a01ef306db7d1996cc0f0401994c40962d1f405c
refs/heads/main
2023-06-13T04:55:32.237595
2021-07-07T19:52:30
2021-07-07T19:52:30
383,907,709
0
0
null
null
null
null
UTF-8
Java
false
false
2,329
java
package com.abc.saloncom; import androidx.appcompat.app.AppCompatActivity; import androidx.fragment.app.DialogFragment; import android.app.DatePickerDialog; import android.content.Intent; import android.media.Image; import android.os.Bundle; import android.view.View; import android.widget.Button; import android.widget.DatePicker; import android.widget.ImageButton; import android.widget.TextView; import java.text.DateFormat; import java.util.Calendar; public class booking3 extends AppCompatActivity implements DatePickerDialog.OnDateSetListener { private Button button; private ImageButton button3; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_booking3); Intent intent = getIntent(); String final_cat3 = intent.getStringExtra(Sports.Extra_text1); TextView textview4 = (TextView) findViewById(R.id.textView5); textview4.setText(final_cat3); button3 = (ImageButton) findViewById(R.id.image3); button3.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { DialogFragment datepicker = new DatePickerFragement(); datepicker.show(getSupportFragmentManager(), "date picker"); } }); button = (Button) findViewById(R.id.button2); button.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { openconfirmdetails(); } }); } private void openconfirmdetails() { Intent intent = new Intent(booking3.this, confirmdetails.class); startActivity(intent); } @Override public void onDateSet(DatePicker datePicker, int year, int month, int dayofMonth) { Calendar c = Calendar.getInstance(); c.set(Calendar.YEAR, year); c.set(Calendar.MONTH, month); c.set(Calendar.DAY_OF_MONTH,dayofMonth); String currentDateString = DateFormat.getDateInstance().format(c.getTime()); TextView textView = (TextView) findViewById(R.id.textView7); textView.setText(currentDateString); } }
[ "noreply@github.com" ]
PranitBhatt.noreply@github.com
783f5bbd34a76cacb98aa7dbb30b042e3eda2228
51aef8e206201568d04fb919bf54a3009c039dcf
/trunk/src/com/jme/util/export/binary/modules/BinaryFragmentProgramStateModule.java
e9ea4084d206323b2c057a0081b3bc228a76dd5d
[]
no_license
lihak/fairytale-soulfire-svn-to-git
0b8bdbfcaf774f13fc3d32cc3d3a6fae64f29c81
a85eb3fc6f4edf30fef9201902fcdc108da248e4
refs/heads/master
2021-02-11T15:25:47.199953
2015-12-28T14:48:14
2015-12-28T14:48:14
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,185
java
/* * Copyright (c) 2003-2008 jMonkeyEngine * 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 'jMonkeyEngine' nor the names of its contributors * may be used to endorse or promote products derived from this software * without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ package com.jme.util.export.binary.modules; import com.jme.scene.state.FragmentProgramState; import com.jme.system.DisplaySystem; import com.jme.util.export.InputCapsule; import com.jme.util.export.Savable; import com.jme.util.export.binary.BinaryLoaderModule; public class BinaryFragmentProgramStateModule implements BinaryLoaderModule { public String getKey() { return FragmentProgramState.class.getName(); } public Savable load(InputCapsule inputCapsule) { return DisplaySystem.getDisplaySystem().getRenderer().createFragmentProgramState(); } }
[ "you@example.com" ]
you@example.com
3baaf8d2d11a72a07a394633f5c2f5aefdd11b58
9157c520e704c6e3c23984f99fa87e1f461be426
/jxszj_zhmd/src/main/java/com/jxszj/controller/sap/XsddcqController.java
bf4e5e672b323e4ec7bb9e919abd4c380b059515
[]
no_license
sb1748/work
b03899b796eef6ba53dec8be0f3fc1f8c6231fe0
d7a37cb0107e044374305ad6c710cd748c350d23
refs/heads/master
2023-07-02T22:12:21.777762
2021-08-05T10:59:16
2021-08-05T10:59:16
392,943,510
0
1
null
null
null
null
UTF-8
Java
false
false
1,649
java
package com.jxszj.controller.sap; import java.util.Arrays; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; import com.jxszj.pojo.EUDataGridResult; import com.jxszj.pojo.sap.SapConditionCqTb; import com.jxszj.pojo.sap.SapXsddCqTb; import com.jxszj.service.sap.IConditionService; import com.jxszj.service.sap.IXsddcqService; import com.jxszj.utils.MessageResult; @Controller @RequestMapping("/sap") public class XsddcqController { @Autowired private IXsddcqService xsddcqService; @RequestMapping("/getSapXsddCqTbList") @ResponseBody public EUDataGridResult getSapXsddCqTbList(Integer page, Integer rows,String xspz){ EUDataGridResult result =xsddcqService.getSapXsddCqTbList(page, rows,xspz); return result; } @RequestMapping("/editSapXsddCqTb") @ResponseBody public MessageResult editSapXsddCqTb(SapXsddCqTb sapXsddCqTb){ try { int i=xsddcqService.updateSapXsddCqTb(sapXsddCqTb); if(i>0){ return MessageResult.build(200,"修改成功!"); } } catch (Exception e) { e.printStackTrace(); } return MessageResult.build(null,"修改失败!"); } @RequestMapping("/deleteSapXsddCqTb") @ResponseBody public MessageResult deleteSapXsddCqTb(String[] ids){ try { int i=xsddcqService.deleteSapXsddCqTb(Arrays.asList(ids)); if(i>0){ return MessageResult.build(200,"删除成功!"); } } catch (Exception e) { e.printStackTrace(); } return MessageResult.build(null,"删除失败!"); } }
[ "1178095136@qq.com" ]
1178095136@qq.com
554cd6b4446dcf7c3b958e2d663d9788b92b9dfa
6630b644811091e29cdb1c2510b4446983ad4803
/random_2/Random.java
d47d1970561e7b7c59438c84689a0e727c467e0e
[]
no_license
LucasSugi/POO
f6eef210edc95f659ea3a3a28600ecc9fa53758f
42b18642234172283b4fff970868bf3eb34f1331
refs/heads/master
2020-03-26T17:06:38.945925
2018-08-17T16:17:42
2018-08-17T16:17:42
145,142,004
1
0
null
null
null
null
UTF-8
Java
false
false
1,267
java
/* * Classe responsável por gerar valores aleatórios * Nome: Lucas Yudi Sugi * Número USP: 9293251 */ import java.util.Calendar; public class Random{ //Parâmetros da geração do número randomico private long p = 2147483648l; private long m = 843314861; private long a = 453816693; //Parâmetro para a semente private long xi; //Construtor sem parâmetro public Random(){ //Criação do objeto Calendar calendar = Calendar.getInstance(); //Setando a semente xi = calendar.getTimeInMillis() % p; } //Método para gerar valores aleatórios public double getRand(){ double random; //Cálculo do próximo xi xi = (a + (m * xi)) % p; //'Casting' random = xi; //Restringindo o valor entre 0 e 1 //Como xi recebeu mod de p, então basta dividiros por 'p' para obter um valor entre 0 e 1 random /= p; return random; } //Método para gerar valores aleatórios entre [0,max] em que m será fornecido public int getIntRand(int max){ double random; //Gerando um valor randomico entre 0 e 1 random = getRand(); //Valor aleatório em inteiro random *= max; return (int)random; } //Método para setar uma nova semente public void setSemente(int semente){ xi = semente; } }
[ "lucas.sugi@usp.br" ]
lucas.sugi@usp.br
89039da121eda9698de5ab315c6e23e286016278
fcd3f5e1e3208ce241f60f50d541983b268555bd
/tinkerWrapper/src/main/java/org/inagora/tinkerwrapper/api/PatchInfo.java
944855d7fb16e7bfcdfe0b5974eef20f3f166e06
[ "BSD-3-Clause" ]
permissive
FIRETRAY/TinkerWrapperLib
cec7e32ea62b2833ddbaa236acfe3b32d802faaf
05fa8f0884631d7b3266ad04a1819738beec148e
refs/heads/master
2020-09-13T05:09:00.643624
2020-02-24T08:41:13
2020-02-24T08:41:13
222,663,156
2
0
null
null
null
null
UTF-8
Java
false
false
845
java
package org.inagora.tinkerwrapper.api; import org.json.JSONObject; /** * 补丁信息数据结构 */ public class PatchInfo { /** * 安装Patch成功后是否显示弹窗,提示重新安装 */ public boolean is_forced; public String patch_version; public String patch_url; public String patch_md5; public static PatchInfo fromJson(JSONObject jsonObject) { if (jsonObject == null || jsonObject.length() == 0) { return null; } PatchInfo patchInfo = new PatchInfo(); patchInfo.is_forced = jsonObject.optInt("is_forced") == 1; patchInfo.patch_version = jsonObject.optString("patch_version"); patchInfo.patch_url = jsonObject.optString("patch_url"); patchInfo.patch_md5 = jsonObject.optString("patch_md5"); return patchInfo; } }
[ "liufangliang@inagora.cn" ]
liufangliang@inagora.cn
47a46159dc9d6375e935fa5c45ee86f861e400fb
3ee07856eb93c513cd8e2d81db950b0da24cd8fa
/src/main/java/com/capgemini/dev/one_to_one/Passport.java
dcfacd2f5b3fff78482f4cb4d509cbbae6a2c67d
[]
no_license
suyashseth/CapHibernateJPA
812ebc0c31b8bf187f034922494d02069f613437
a53c3df9398c27b34451bf2b76cfd5d51818d859
refs/heads/master
2020-04-29T14:53:17.357703
2019-03-18T05:37:21
2019-03-18T05:37:21
175,550,745
0
0
null
null
null
null
UTF-8
Java
false
false
1,028
java
package com.capgemini.dev.one_to_one; import javax.persistence.CascadeType; import javax.persistence.Entity; import javax.persistence.GeneratedValue; import javax.persistence.GenerationType; import javax.persistence.Id; import javax.persistence.JoinColumn; import javax.persistence.OneToOne; import javax.persistence.Table; @Entity @Table public class Passport { @Id @GeneratedValue(strategy=GenerationType.AUTO) private int pid; private String pcountry; @OneToOne(cascade=CascadeType.ALL) @JoinColumn(name="uid") private User us; public int getPid() { return pid; } public void setPid(int pid) { this.pid = pid; } public String getPcountry() { return pcountry; } public void setPcountry(String pcountry) { this.pcountry = pcountry; } public User getUs() { return us; } public void setUs(User us) { this.us = us; } @Override public String toString() { return "Passport [pid=" + pid + ", pcountry=" + pcountry + ", us=" + us + "]"; } }
[ "QSP@DESKTOP-NCARHLV" ]
QSP@DESKTOP-NCARHLV
f45bccdbf911bb177ef689c5e037866acbb32af7
f7295dfe3c303e1d656e7dd97c67e49f52685564
/smali/org/apache/http/impl/cookie/RFC2109Spec.java
4220c4408a86851b27f2edf83fcc1c2d0c8986f9
[]
no_license
Eason-Chen0452/XiaoMiGame
36a5df0cab79afc83120dab307c3014e31f36b93
ba05d72a0a0c7096d35d57d3b396f8b5d15729ef
refs/heads/master
2022-04-14T11:08:31.280151
2020-04-14T08:57:25
2020-04-14T08:57:25
255,541,211
0
1
null
null
null
null
UTF-8
Java
false
false
1,693
java
package org.apache.http.impl.cookie; import java.util.List; import org.apache.http.Header; import org.apache.http.cookie.Cookie; import org.apache.http.cookie.CookieOrigin; import org.apache.http.cookie.MalformedCookieException; import org.apache.http.util.CharArrayBuffer; @Deprecated public class RFC2109Spec extends CookieSpecBase { public RFC2109Spec() { throw new RuntimeException("Stub!"); } public RFC2109Spec(String[] paramArrayOfString, boolean paramBoolean) { throw new RuntimeException("Stub!"); } protected void formatCookieAsVer(CharArrayBuffer paramCharArrayBuffer, Cookie paramCookie, int paramInt) { throw new RuntimeException("Stub!"); } public List<Header> formatCookies(List<Cookie> paramList) { throw new RuntimeException("Stub!"); } protected void formatParamAsVer(CharArrayBuffer paramCharArrayBuffer, String paramString1, String paramString2, int paramInt) { throw new RuntimeException("Stub!"); } public int getVersion() { throw new RuntimeException("Stub!"); } public Header getVersionHeader() { throw new RuntimeException("Stub!"); } public List<Cookie> parse(Header paramHeader, CookieOrigin paramCookieOrigin) throws MalformedCookieException { throw new RuntimeException("Stub!"); } public void validate(Cookie paramCookie, CookieOrigin paramCookieOrigin) throws MalformedCookieException { throw new RuntimeException("Stub!"); } } /* Location: C:\Users\Administrator\Desktop\apk\dex2jar\classes-dex2jar.jar!\org\apache\http\impl\cookie\RFC2109Spec.class * Java compiler version: 6 (50.0) * JD-Core Version: 0.7.1 */
[ "chen_guiq@163.com" ]
chen_guiq@163.com
e097e33b004cbe9d521a466f00f4eda2a2a77e2c
ab8a34e5b821dde7b09abe37c838de046846484e
/twilio/sample-code-master/preview/acc_security/service/update-default/update-default.7.x.java
cd18fd747f19b6cfcf5a8d2137372bae552425b3
[]
no_license
sekharfly/twilio
492b599fff62618437c87e05a6c201d6de94527a
a2847e4c79f9fbf5c53f25c8224deb11048fe94b
refs/heads/master
2020-03-29T08:39:00.079997
2018-09-21T07:20:24
2018-09-21T07:20:24
149,721,431
0
1
null
null
null
null
UTF-8
Java
false
false
645
java
// Install the Java helper library from twilio.com/docs/java/install import com.twilio.Twilio; import com.twilio.rest.preview.accSecurity.Service; public class Example { // Find your Account Sid and Token at twilio.com/console public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"; public static final String AUTH_TOKEN = "your_auth_token"; public static void main(String[] args) { Twilio.init(ACCOUNT_SID, AUTH_TOKEN); Service service = Service.updater("VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX") .setName("name").update(); System.out.println(service.getName()); } }
[ "sekharfly@gmail.com" ]
sekharfly@gmail.com
0ca06965cdb7603a8a0e3e0200df9bcdb7358d7b
7c76db8235ca9aeff01ec0431aa3c9f733756cb0
/src/main/java/singleton/ThreadSafeDoubleLockingSingleton.java
a5784fe8c94a72391c5d98aa1598005191f297a9
[]
no_license
jezhische/TrainingTasks
f98e94617b8c280ae3f715d66b350e37265d1aa8
03c1241bf76878248d24aef796006439b91f7dfd
refs/heads/master
2020-05-21T19:52:09.674832
2017-08-22T01:56:23
2017-08-22T01:56:23
62,608,297
0
0
null
null
null
null
UTF-8
Java
false
false
1,270
java
package singleton; /** * Created by Ежище on 23.11.2016. * http://info.javarush.ru/translation/2013/09/14/%D0%A8%D0%B0%D0%B1%D0%BB%D0%BE%D0%BD-%D0%BF%D1%80%D0%BE%D0%B5%D0%BA%D1%82%D0%B8%D1%80%D0%BE%D0%B2%D0%B0%D0%BD%D0%B8%D1%8F-Singleton-%D0%BE%D0%B4%D0%B8%D0%BD%D0%BE%D1%87%D0%BA%D0%B0-%D0%BD%D0%B0%D0%B8%D0%B1%D0%BE%D0%BB%D0%B5%D0%B5-%D1%80%D0%B0%D1%86%D0%B8%D0%BE%D0%BD%D0%B0%D0%BB%D1%8C%D0%BD%D1%8B%D0%B5-%D1%80%D0%B5%D0%B0%D0%BB%D0%B8%D0%B7%D0%B0%D1%86%D0%B8%D0%B8-%D0%B2-%D0%BF%D1%80%D0%B8%D0%BC%D0%B5%D1%80%D0%B0%D1%85-.html * Дополнительная проверка для гарантии, что будет создан только один экземпляр класса Singleton. */ public class ThreadSafeDoubleLockingSingleton { private static ThreadSafeDoubleLockingSingleton instance; private ThreadSafeDoubleLockingSingleton(){} public static synchronized ThreadSafeDoubleLockingSingleton getInstanceUsingDoubleLocking(){ if(instance == null){ synchronized (ThreadSafeSingleton.class) { if(instance == null){ instance = new ThreadSafeDoubleLockingSingleton(); } } } return instance; } }
[ "jezhische@gmail.com" ]
jezhische@gmail.com
67c089de0011b3dfda6a83e1c8fcdba0a81c2246
6c0bb22122dbeacf8d2578399c2333e2e8f406e6
/MesAdministrator/src/ide/main/EventMainBtnManageIsland.java
51531b2dc6843720973025b40c50315a51f5a372
[]
no_license
AModotti/MesAdministrator
ca329d7a4e634b816819ecbe1bbc3fbeeadd2f54
21caa2e636662ec3dc70cb272355e05106c10ef0
refs/heads/master
2021-01-18T23:57:57.476952
2016-11-04T08:58:32
2016-11-04T08:58:32
72,831,110
0
0
null
null
null
null
UTF-8
Java
false
false
727
java
package ide.main; import ide.island.IslandWindow; import java.awt.Cursor; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import javax.swing.JFrame; public class EventMainBtnManageIsland implements ActionListener { JFrame mainwindow; public EventMainBtnManageIsland(JFrame mainwindow){ this.mainwindow = mainwindow; } @Override public void actionPerformed(ActionEvent arg0) { Cursor hourglassCursor = new Cursor(Cursor.WAIT_CURSOR); Cursor normalCursor = new Cursor(Cursor.DEFAULT_CURSOR); mainwindow.setCursor(hourglassCursor); IslandWindow miw = new IslandWindow(); miw.setModal(true); miw.setVisible(true); mainwindow.setCursor(normalCursor); } }
[ "modotti.andrea@gmail.com" ]
modotti.andrea@gmail.com
13f45fa5be47fbeccc64fe4de4374056fc702205
f4024059d8f2a24d9b98e028d5e4b99b981503ec
/src/main/java/trng/mongodb/repo/BlogRepoHelper.java
534a066032baa274433dbe50d21259f219457d4a
[]
no_license
VivekBhargav/SpringMongoDB
7ffd5677ee8b6bf076a2e9554cffab7ede12f6ff
1e44b594c5ea0c75d4e746e13e7efde3051af43a
refs/heads/master
2020-03-27T04:24:17.743798
2018-08-24T03:26:08
2018-08-24T03:26:08
145,936,384
0
0
null
null
null
null
UTF-8
Java
false
false
2,215
java
package trng.mongodb.repo; import java.util.ArrayList; import java.util.Collections; import java.util.List; import java.util.stream.Collectors; import org.bson.Document; import com.mongodb.client.FindIterable; import com.mongodb.client.MongoCursor; import trng.mongodb.model.Blog; import trng.mongodb.model.BlogComment; public class BlogRepoHelper { public static List<Document> prepareBlogDocuments(List<Blog> blogs) { return blogs.stream().map(blog -> prepareBlogDocument(blog)).collect(Collectors.toList()); } public static Document prepareBlogDocument(Blog blog) { Document document = new Document().append("title", blog.getTitle()).append("author", blog.getAuthor()) .append("date", blog.getDate()).append("body", blog.getBody()); if (blog.getComments() != null) { document.append("comments", prepareBlogCommentDocuments(blog.getComments())); } if (blog.getTags() != null) { document.append("tags", blog.getTags()); } return document; } private static List<Document> prepareBlogCommentDocuments(List<BlogComment> comments) { if (comments == null) { return null; } return comments.stream().map(document -> prepareBlogCommentDocument(document)).collect(Collectors.toList()); } private static Document prepareBlogCommentDocument(BlogComment comment) { return new Document().append("name", comment.getName()).append("email", comment.getEmail()).append("comment", comment.getComment()); } public static List<Blog> prepareBlogs(FindIterable<Document> blogCollections) { List<Blog> blogs = new ArrayList<>(); MongoCursor<Document> itr = blogCollections.iterator(); try { while(itr.hasNext()) { blogs.add(prepareBlog(itr.next())); } } finally { itr.close(); } return blogs; } public static List<Blog> prepareBlogs(List<Document> blogCollections) { return blogCollections.stream().map(blog-> prepareBlog(blog)).collect(Collectors.toList()); } public static Blog prepareBlog(Document document) { Blog blog = new Blog(document.getObjectId("_id").toString(), document.getString("title"), document.getString("body"), document.getString("author"), document.getDate("date"), null, null); return blog; } }
[ "vivek.bhargav1299@gmail.com" ]
vivek.bhargav1299@gmail.com
66e3689d0914ed7b819e6a3c00bdf3f0cf08577b
5e8d6472795991cdc66bb4f3623aa5b822fbf1dc
/src/main/java/edu/jhu/jerboa/sim/SimGraph.java
800d13838de71e3bbb88f3f00b54d51e26e09216
[ "BSD-2-Clause" ]
permissive
maxthomas/jerboa
4f060ec075f1bae3ecced72fe000eed3783990e8
c1db01272112641c2376912853e2640a2a82a62f
refs/heads/master
2021-01-16T00:23:32.581916
2013-08-27T05:10:12
2013-08-27T05:10:12
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,499
java
// Copyright 2010-2012 Benjamin Van Durme. All rights reserved. // This software is released under the 2-clause BSD license. // See jerboa/LICENSE, or http://cs.jhu.edu/~vandurme/jerboa/LICENSE // Benjamin Van Durme, vandurme@cs.jhu.edu, 23 July 2012 package edu.jhu.jerboa.sim; import edu.jhu.jerboa.util.*; import edu.jhu.jerboa.sim.*; import java.io.*; import java.text.DecimalFormat; import java.util.Vector; import java.util.AbstractMap.SimpleImmutableEntry; /** Loads a PLEBIndex and SLSH object. Outputs an approximation of the KBest edges over the signatures as vertices. Writes result to SimGraph.output */ public class SimGraph { private static void writeResults (BufferedWriter writer, PLEBIndex pleb, KBest<String> kbest) throws Exception { DecimalFormat formatter = new DecimalFormat("#.####"); for (SimpleImmutableEntry<String,Double> pair : kbest.toArray()) { //writer.write(pleb.keys[pair.getKey()[0]] + "\t" + pleb.keys[pair.getKey()[1]] + "\t" + formatter.format(pair.getValue())); writer.write(pair.getKey() + "\t" + formatter.format(pair.getValue())); writer.newLine(); } } public static void kbestGraph (SLSH slsh, PLEBIndex pleb, int k, int B, int P) throws Exception { KBest<String> kbest = pleb.kbestGraph(k,B,P); BufferedWriter writer = FileManager.getWriter(JerboaProperties.getProperty("SimGraph.outputPrefix") + ".kbest"); writeResults(writer,pleb,kbest); writer.close(); } public static void thresholdGraph (SLSH slsh, PLEBIndex pleb, int k, int B, int P) throws Exception { BufferedWriter writer = FileManager.getWriter(JerboaProperties.getProperty("SimGraph.outputPrefix") + ".threshold"); double threshold = JerboaProperties.getDouble("SimGraph.threshold"); pleb.thresholdGraph(k,B,P,threshold,writer); writer.close(); } public static void main (String[] args) throws Exception { int k = JerboaProperties.getInt("SimGraph.k"); int B = JerboaProperties.getInt("SimGraph.B"); int P = JerboaProperties.getInt("SimGraph.P"); SLSH slsh; slsh = SLSH.load(); PLEBIndex pleb = PLEBIndex.load(JerboaProperties.getProperty("PLEBIndex.indexFile"),slsh); //KBest<Integer[]> kbest = pleb.kbestGraph(k,B,P); String method = JerboaProperties.getProperty("SimGraph.method", "kbestGraph"); if (method.equals("kbestGraph")) kbestGraph(slsh,pleb,k,B,P); else if (method.equals("thresholdGraph")) thresholdGraph(slsh,pleb,k,B,P); } }
[ "maxjthomas@gmail.com" ]
maxjthomas@gmail.com
13ed375ca21777293186c4661c1b6ee553d20f1b
9a64627057610f0bcf874153e2cbbee43aa536d1
/Baekjoon/src/가운데를말해요/Main.java
f97f01210fa350ae9354e6b256d985316f2fe35c
[]
no_license
jeongjinhwi/Algorithm_2020
dedc0ee65f46b66cec3a6f5630aa004f1b4c1cb6
c704e10796fb5bff8ee27f75b1d8f200a4df5c79
refs/heads/master
2020-12-04T18:38:54.629857
2020-05-30T07:40:12
2020-05-30T07:40:12
231,868,043
0
0
null
null
null
null
UHC
Java
false
false
942
java
package 가운데를말해요; import java.util.*; import java.io.*; public class Main { public static void main(String[] args) throws IOException { // TODO 자동 생성된 메소드 스텁 BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); StringTokenizer st; st = new StringTokenizer(br.readLine()); int N = Integer.parseInt(st.nextToken()); PriorityQueue<Integer> minq = new PriorityQueue<>(); PriorityQueue<Integer> maxq = new PriorityQueue<>((o1,o2)-> o2-o1); for(int i = 0; i < N; i++){ st = new StringTokenizer(br.readLine()); int data = Integer.parseInt(st.nextToken());; if(minq.size() == maxq.size()){ maxq.add(data); }else{ minq.add(data); } if(!minq.isEmpty() && !maxq.isEmpty()){ if(maxq.peek() > minq.peek()){ int temp = minq.poll(); maxq.add(temp); minq.add(maxq.poll()); } } System.out.println(maxq.peek()); } } }
[ "wlsgnl5069@cnu.ac.kr" ]
wlsgnl5069@cnu.ac.kr
65d52744156df3e80164377d5ab7104b83ac0484
5fd944f2917a1f7b00d1932e879e18c5dfec681f
/src/iterator/EvenNumberSet.java
0557dbc63203033c17345758e548314c8e6d0d9e
[]
no_license
justin-cotarla/design-patterns
3fc060b9a77735d01a060c1f25bf840c2e8c40a8
cc932681c9512aa8597c279b9c76ab77d98dcbf3
refs/heads/master
2020-04-23T04:30:56.159110
2019-04-16T19:58:18
2019-04-16T19:58:18
170,909,987
1
0
null
null
null
null
UTF-8
Java
false
false
446
java
package iterator; public class EvenNumberSet implements Aggregate<Integer> { private final int max; public EvenNumberSet(int max) { this.max = max; } public Integer get(int count) { if (count * 2 <= max) { return count*2; } else { return null; } } @Override public Iterator<Integer> createIterator() { return new EvenNumberSetIterator(this); } }
[ "justin.cotarla@gmail.com" ]
justin.cotarla@gmail.com
44257dc2f4630de5bf68776a6d6d74cf9c331288
b19cfbcfd6a3a088a291e917be733b4850cc77c0
/app/src/main/java/muhanxi/zhibodemo/CLayoutView.java
19c6d3194aa092d95e33661fe39c3a724d3ee579
[]
no_license
qingtian2/ZhiBoDemo
5140d199307428a8ee835da2c728dc55115cfe7d
fbe84e04dc835a2f9c4f31f9374de66495bcab92
refs/heads/master
2021-01-15T22:47:37.485064
2017-08-09T09:43:38
2017-08-09T09:43:38
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,372
java
package muhanxi.zhibodemo; import android.content.Context; import android.support.annotation.Nullable; import android.util.AttributeSet; import android.view.MotionEvent; import android.widget.LinearLayout; /** * Created by muhanxi on 17/8/9. */ public class CLayoutView extends LinearLayout { public CLayoutView(Context context) { super(context); } public CLayoutView(Context context, @Nullable AttributeSet attrs) { super(context, attrs); } public CLayoutView(Context context, @Nullable AttributeSet attrs, int defStyleAttr) { super(context, attrs, defStyleAttr); } public CLayoutView(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes) { super(context, attrs, defStyleAttr, defStyleRes); } @Override public boolean dispatchTouchEvent(MotionEvent ev) { System.out.println("CLayoutView dispatchTouchEvent = " + ev.getAction()); return super.dispatchTouchEvent(ev); } @Override public boolean onInterceptTouchEvent(MotionEvent ev) { System.out.println("CLayoutView onInterceptTouchEvent = " + ev.getAction()); return super.onInterceptTouchEvent(ev); } @Override public boolean onTouchEvent(MotionEvent ev) { System.out.println("CLayoutView onTouchEvent = " + ev.getAction()); return true; } }
[ "zmuhanxibaweiZ1" ]
zmuhanxibaweiZ1
3f008cb985a03075e71f7b63dcd71b19b57a525c
9a0395677ae97ddf49739309be0d8e11d308181d
/src/main/java/br/com/zup/proposta/proposta/endereco/Endereco.java
613a5791697f490a7d963ea3c6538f14bd801702
[ "Apache-2.0" ]
permissive
luizpcarvalho/orange-talents-01-template-proposta
8ee92c4fdf87e577cba9974f51b7deba701c824c
374f73773a6763985295abfee1fdb4edddc3d0d6
refs/heads/main
2023-03-09T21:18:37.661101
2021-02-24T12:23:09
2021-02-24T12:23:09
337,724,489
0
0
Apache-2.0
2021-02-10T12:57:17
2021-02-10T12:57:16
null
UTF-8
Java
false
false
1,533
java
package br.com.zup.proposta.proposta.endereco; import javax.persistence.Column; import javax.persistence.Embeddable; @Embeddable public class Endereco { @Column(nullable = false) private String cep; @Column(nullable = false) private String logradouro; @Column(nullable = false) private Integer numero; @Column(nullable = false) private String bairro; @Column(nullable = false) private String cidade; @Column(nullable = false) private String estado; @Deprecated public Endereco() { } public Endereco(String cep, String logradouro, Integer numero, String bairro, String cidade, String estado) { this.cep = cep; this.logradouro = logradouro; this.numero = numero; this.bairro = bairro; this.cidade = cidade; this.estado = estado; } public String getCep() { return cep; } public String getLogradouro() { return logradouro; } public Integer getNumero() { return numero; } public String getBairro() { return bairro; } public String getCidade() { return cidade; } public String getEstado() { return estado; } @Override public String toString() { return "Endereco{" + ", cep='" + cep + '\'' + ", logradouro='" + logradouro + '\'' + ", numero=" + numero + ", bairro='" + bairro + '\'' + ", cidade='" + cidade + '\'' + ", estado='" + estado + '\'' + '}'; } }
[ "luizpauloiftm@gmail.com" ]
luizpauloiftm@gmail.com
db403f529699873119a509c0d811d53d3509d9f8
4c8d7b570e63c20ccfc7f9138937c253a97a305c
/src/main/java/com/sudoplay/mc/kor/core/registry/service/injection/strategy/parameter/ConfigurationParameterStrategy.java
b5ad43e720cfb3268ded5b961989c87c9430acba
[ "Apache-2.0" ]
permissive
codetaylor/kor-lib
9f807bfff6e9550b9cc095e2edbb92ccc0dcff46
6b1cd9a9653263d38b2557cbac3da6ebc3919d80
refs/heads/master
2020-12-24T11:33:05.153851
2017-11-01T18:47:23
2017-11-01T18:47:23
73,030,308
0
0
null
null
null
null
UTF-8
Java
false
false
1,736
java
package com.sudoplay.mc.kor.core.registry.service.injection.strategy.parameter; import com.sudoplay.mc.kor.core.config.text.IConfigurationService; import com.sudoplay.mc.kor.spi.registry.injection.KorTextConfig; import net.minecraftforge.common.config.Configuration; import java.io.File; import java.lang.reflect.Parameter; /** * Created by codetaylor on 11/5/2016. */ public class ConfigurationParameterStrategy implements IParameterStrategy<Configuration> { private IConfigurationService service; public ConfigurationParameterStrategy( IConfigurationService service ) { this.service = service; } @Override public boolean isValidParameter(Parameter parameter) { KorTextConfig annotation = parameter.getAnnotation(KorTextConfig.class); boolean hasCorrectAnnotation = annotation != null; boolean isCorrectType = Configuration.class.isAssignableFrom(parameter.getType()); return hasCorrectAnnotation && isCorrectType; } @Override public Configuration getParameterInstance(Parameter parameter) { KorTextConfig annotation = parameter.getAnnotation(KorTextConfig.class); String file = annotation.file(); String path = annotation.path(); String filename = (path.length() > 0) ? new File(path, file).getPath() : new File(file).getPath(); Configuration configuration = this.service.get(filename); if (configuration == null) { // config wasn't loaded throw new IllegalStateException(String.format( "Unable to inject configuration file [%s] because it hasn't been loaded, " + "make sure it is loaded during the module's OnLoadConfigurationsEvent event.", filename )); } return configuration; } }
[ "jason@codetaylor.com" ]
jason@codetaylor.com
604ca9defe15fc7952600b96a67f1db5d4c4b3ad
1f59a53953ecc95ae2fdd2bb78d1fe73511602ee
/app/src/main/java/com/example/xebialabstest/utils/SnackbarMessage.java
cace7fcfb2f339b71688c41b8c51b948713bc07f
[]
no_license
devopstoday11/XebiaLabsTest
185832f86fd2b8f8328f8a3a2279d3e762ea8f8d
51cdda4eee7c9d48bac20d420087010661ae8f38
refs/heads/master
2022-03-14T13:36:13.189237
2019-12-08T19:23:32
2019-12-08T19:23:32
null
0
0
null
null
null
null
UTF-8
Java
false
false
912
java
package com.example.xebialabstest.utils; import androidx.annotation.Nullable; import androidx.annotation.StringRes; import androidx.lifecycle.LifecycleOwner; import androidx.lifecycle.Observer; public class SnackbarMessage extends SingleLiveEvent<Integer> { public void observe(LifecycleOwner owner, final SnackbarObserver observer) { super.observe(owner, new Observer<Integer>() { @Override public void onChanged(@Nullable Integer t) { if (t == null) { return; } observer.onNewMessage(t); } }); } public interface SnackbarObserver { /** * Called when there is a new message to be shown. * * @param snackbarMessageResourceId The new message, non-null. */ void onNewMessage(@StringRes int snackbarMessageResourceId); } }
[ "ssparsh111@gmail.com" ]
ssparsh111@gmail.com
cfb1776ebe30e460cac07122a479fa02d72e50b7
ab2c087f4536eadde15017c06391a2bd89a7a9ff
/dev-beginner-group-admin/src/main/java/com/jojoldu/beginner/admin/sns/Sns.java
ebfb93a738e0cc694f54cd374f282cf12781d1ca
[]
no_license
munifico/dev-beginner-group
3558e5f293657e2fcf9a222b66fac53277ce3659
f7467a31a83310d11f55c9e2415b7cf349eb429d
refs/heads/master
2023-03-17T22:13:09.324749
2018-10-27T08:48:43
2018-10-27T08:48:43
null
0
0
null
null
null
null
UTF-8
Java
false
false
604
java
package com.jojoldu.beginner.admin.sns; import lombok.AllArgsConstructor; import lombok.Getter; /** * Created by jojoldu@gmail.com on 17/06/2018 * Blog : http://jojoldu.tistory.com * Github : https://github.com/jojoldu */ @Getter @AllArgsConstructor public enum Sns { TELEGRAM("Telegram", "telegram"), FACEBOOK("Facebook", "facebook"), BLOG("Blog", "blog"); private String prefix; private String tag; public String createTitle(String title){ return "["+prefix+"] "+title; } public String createUrl(String url){ return url+"/#ref="+tag; } }
[ "jojoldu@gmail.com" ]
jojoldu@gmail.com
ac8101201fa12e5596091ecc02426e288e1fc68c
44d6ab79fa51c816883a186e7a964af1450afa64
/service/service-payment/src/main/java/com/atguigu/gmall/payment/ServicePaymentApplication.java
f029d60b018de5a816672179470f65c1dd7ad8d7
[]
no_license
kilighhh/gmall-parent-0621
9d03d9646c45763a6cddf710c1a97e729425e8c1
739a3d656a8de4e625d6c6166c0ce7068d52062e
refs/heads/main
2023-02-13T09:35:44.727852
2021-01-19T13:13:06
2021-01-19T13:13:06
316,397,226
0
0
null
null
null
null
UTF-8
Java
false
false
800
java
package com.atguigu.gmall.payment; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.cloud.client.discovery.EnableDiscoveryClient; import org.springframework.cloud.openfeign.EnableFeignClients; import org.springframework.context.annotation.ComponentScan; /** * @Author Kilig Zong * @Date 2020/12/2 12:04 * @Version 1.0 association collection Executor */ @SpringBootApplication @ComponentScan({"com.atguigu.gmall"}) @EnableDiscoveryClient//让注册中心发现服务 @EnableFeignClients("com.atguigu.gmall")//开启feign远程调用 public class ServicePaymentApplication { public static void main(String[] args) { SpringApplication.run(ServicePaymentApplication.class,args); } }
[ "1142732681@qq.com" ]
1142732681@qq.com