blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 7 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 684M ⌀ | 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 132
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 28
values | content stringlengths 3 9.45M | authors listlengths 1 1 | author_id stringlengths 0 352 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
38fa4d2e4e4b0a32af0f5ef0b46fb9555da7b4e7 | f516ecabc30539712463e273c1b71cf8521650c8 | /src/br/ufes/dwws/vital/dashboard/diagnosis/DiagnosisController.java | c38b9128e3de263c7ce5358da9ee10c5750d960d | [] | no_license | alanvieira16/2017-Vital | e9bf81a7d15f40f56d88ce7a13c4fb3c3c60e0a5 | 1971cddc97468465988a38d4403c5b968112275d | refs/heads/master | 2020-04-06T11:41:00.196297 | 2017-07-27T22:44:24 | 2017-07-27T22:44:24 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 5,773 | java | package br.ufes.dwws.vital.dashboard.diagnosis;
import java.util.List;
import java.util.ResourceBundle;
import javax.ejb.EJB;
import javax.enterprise.context.SessionScoped;
import javax.faces.context.FacesContext;
import javax.inject.Inject;
import javax.inject.Named;
import br.ufes.dwws.vital.dashboard.medicine.ManageMedicinesService;
import br.ufes.dwws.vital.dashboard.pathology.ManagePathologiesService;
import br.ufes.dwws.vital.dashboard.prescription.ManagePrescriptionsService;
import br.ufes.dwws.vital.dashboard.treatment.ManageTreatmentsService;
import br.ufes.dwws.vital.domain.Appointment;
import br.ufes.dwws.vital.domain.Diagnosis;
import br.ufes.dwws.vital.domain.Medicine;
import br.ufes.dwws.vital.domain.Pathology;
import br.ufes.dwws.vital.domain.Prescription;
import br.ufes.dwws.vital.domain.Treatment;
import br.ufes.dwws.vital.persistence.PathologyDAO;
import br.ufes.inf.nemo.jbutler.ejb.application.CrudService;
import br.ufes.inf.nemo.jbutler.ejb.controller.CrudController;
import br.ufes.inf.nemo.jbutler.ejb.controller.PersistentObjectConverterFromId;
@Named
@SessionScoped
public class DiagnosisController extends CrudController<Diagnosis> {
private static final long serialVersionUID = 1L;
@EJB
private ManageDiagnosisService manageDiagnosisService;
@EJB
private ManageTreatmentsService manageTreatmentsService;
@EJB
private ManagePrescriptionsService managePrescriptionsService;
@EJB
private ManageMedicinesService manageMedicinesService;
@EJB
private ManagePathologiesService managePathologiesService;
private Appointment appointment;
private Diagnosis diagnosis = new Diagnosis();
private Treatment treatment = new Treatment();
private Prescription prescription = new Prescription();
private Medicine medicine = new Medicine();
private List<Pathology> pathologies;
private PersistentObjectConverterFromId<Pathology> pathologyConverter;
@Inject
public void init(PathologyDAO pathologyDAO) {
//get pathologies from network
if (pathologyDAO.retrieveCount() == 0) {
for (Pathology p : managePathologiesService.fetchDisease())
pathologyDAO.save(p);
}
pathologies = managePathologiesService.list();
pathologyConverter = new PersistentObjectConverterFromId<Pathology>(pathologyDAO);
}
@Override
protected CrudService<Diagnosis> getCrudService() {
return manageDiagnosisService;
}
@Override
protected void initFilters() {
}
public String create(Appointment appointment) {
this.appointment = appointment;
return "/diagnosis/new?faces-redirect=true";
}
public String diagnose() {
ResourceBundle bundle = FacesContext.getCurrentInstance().getApplication()
.getResourceBundle(FacesContext.getCurrentInstance(), "msgs");
try {
medicine.setPrescription(prescription);
prescription.setTreatment(treatment);
treatment.setDiagnosis(diagnosis);
diagnosis.setAppointment(appointment);
manageDiagnosisService.create(diagnosis);
manageTreatmentsService.create(treatment);
managePrescriptionsService.create(prescription);
manageMedicinesService.create(medicine);
FacesContext.getCurrentInstance().getExternalContext().getFlash().put("alertType", "success");
FacesContext.getCurrentInstance().getExternalContext().getFlash().put("alertMessage",
bundle.getString("alert.diagnosisCreated"));
/* created new instances for news diagnosis */
diagnosis = new Diagnosis();
treatment = new Treatment();
prescription = new Prescription();
medicine = new Medicine();
return "/appointment/index?faces-redirect=true";
} catch (Exception e) {
e.printStackTrace();
FacesContext.getCurrentInstance().getExternalContext().getFlash().put("alertType", "danger");
FacesContext.getCurrentInstance().getExternalContext().getFlash().put("alertMessage",
bundle.getString("alert.error"));
return "/appointment/details?faces-redirect=true";
}
}
public ManageDiagnosisService getManageDiagnosisService() {
return manageDiagnosisService;
}
public void setManageDiagnosisService(ManageDiagnosisService manageDiagnosisService) {
this.manageDiagnosisService = manageDiagnosisService;
}
public Diagnosis getDiagnosis() {
return diagnosis;
}
public void setDiagnosis(Diagnosis diagnosis) {
this.diagnosis = diagnosis;
}
public Treatment getTreatment() {
return treatment;
}
public void setTreatment(Treatment treatment) {
this.treatment = treatment;
}
public PersistentObjectConverterFromId<Pathology> getPathologyConverter() {
return pathologyConverter;
}
public void setPathologyConverter(PersistentObjectConverterFromId<Pathology> pathologyConverter) {
this.pathologyConverter = pathologyConverter;
}
public List<Pathology> getPathologies() {
return pathologies;
}
public void setPathologies(List<Pathology> pathologies) {
this.pathologies = pathologies;
}
public ManageTreatmentsService getManageTreatmentsService() {
return manageTreatmentsService;
}
public void setManageTreatmentsService(ManageTreatmentsService manageTreatmentsService) {
this.manageTreatmentsService = manageTreatmentsService;
}
public Appointment getAppointment() {
return appointment;
}
public void setAppointment(Appointment appointment) {
this.appointment = appointment;
}
public Prescription getPrescription() {
return prescription;
}
public void setPrescription(Prescription prescription) {
this.prescription = prescription;
}
public Medicine getMedicine() {
return medicine;
}
public void setMedicine(Medicine medicine) {
this.medicine = medicine;
}
}
| [
"lffmai@gmail.com"
] | lffmai@gmail.com |
1d08a08b44e5dc06b8f68dd7c0ef7a15931ba8b1 | a569e495129b748ddd0bf442025f56fdbb84b6b2 | /thrift/compiler/test/fixtures/optionals/gen-swift/test/fixtures/optionals/Vehicle.java | b73bce967298949bac12fb69d733de9de3d50310 | [
"Apache-2.0"
] | permissive | GreateCode/fbthrift | 6b75653f53c72f20c4ccc9fdbefcf5bfc45563b6 | 89079ddc23b22a8b46e2aff001e17f424c4b5ce8 | refs/heads/master | 2021-01-11T03:34:29.533359 | 2016-10-15T07:33:15 | 2016-10-15T07:45:29 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 3,840 | java | package test.fixtures.optionals;
import com.facebook.swift.codec.*;
import com.facebook.swift.codec.ThriftField.Requiredness;
import com.facebook.swift.codec.ThriftField.Recursiveness;
import java.util.*;
import static com.google.common.base.MoreObjects.toStringHelper;
@ThriftStruct("Vehicle")
public final class Vehicle
{
@ThriftConstructor
public Vehicle(
@ThriftField(value=1, name="color", requiredness=Requiredness.NONE) final test.fixtures.optionals.Color color,
@ThriftField(value=2, name="licensePlate", requiredness=Requiredness.OPTIONAL) final String licensePlate,
@ThriftField(value=3, name="description", requiredness=Requiredness.OPTIONAL) final String description,
@ThriftField(value=4, name="name", requiredness=Requiredness.OPTIONAL) final String name
) {
this.color = color;
this.licensePlate = licensePlate;
this.description = description;
this.name = name;
}
public static class Builder {
private test.fixtures.optionals.Color color;
public Builder setColor(test.fixtures.optionals.Color color) {
this.color = color;
return this;
}
private String licensePlate;
public Builder setLicensePlate(String licensePlate) {
this.licensePlate = licensePlate;
return this;
}
private String description;
public Builder setDescription(String description) {
this.description = description;
return this;
}
private String name;
public Builder setName(String name) {
this.name = name;
return this;
}
public Builder() { }
public Builder(Vehicle other) {
this.color = other.color;
this.licensePlate = other.licensePlate;
this.description = other.description;
this.name = other.name;
}
public Vehicle build() {
return new Vehicle (
this.color,
this.licensePlate,
this.description,
this.name
);
}
}
private final test.fixtures.optionals.Color color;
@ThriftField(value=1, name="color", requiredness=Requiredness.NONE)
public test.fixtures.optionals.Color getColor() { return color; }
private final String licensePlate;
@ThriftField(value=2, name="licensePlate", requiredness=Requiredness.OPTIONAL)
public String getLicensePlate() { return licensePlate; }
private final String description;
@ThriftField(value=3, name="description", requiredness=Requiredness.OPTIONAL)
public String getDescription() { return description; }
private final String name;
@ThriftField(value=4, name="name", requiredness=Requiredness.OPTIONAL)
public String getName() { return name; }
@Override
public String toString()
{
return toStringHelper(this)
.add("color", color)
.add("licensePlate", licensePlate)
.add("description", description)
.add("name", name)
.toString();
}
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
Vehicle other = (Vehicle)o;
return
Objects.equals(color, other.color) &&
Objects.equals(licensePlate, other.licensePlate) &&
Objects.equals(description, other.description) &&
Objects.equals(name, other.name);
}
@Override
public int hashCode() {
return Arrays.deepHashCode(new Object[] {
color,
licensePlate,
description,
name
});
}
}
| [
"facebook-github-bot-7-bot@fb.com"
] | facebook-github-bot-7-bot@fb.com |
399f324b8249086d88e5ad0868e79a2fe6f8294a | 605400aef244670014315836f24cd585e32b3187 | /Week3/Lab3_v2/app/src/main/java/com/example/pok/lab3_v2/Week4_Intent.java | 0c9557a86ab1c3981d167c8bf3e96dc336f37411 | [] | no_license | ekaratnida/Mobile_Dev_App | 90134d1dbafe3d96b1616b1dccf8eb86ebfc08cd | 7381c4236f32228cba336d400f013756d758bbb2 | refs/heads/main | 2023-08-31T17:31:22.396476 | 2021-10-14T15:17:39 | 2021-10-14T15:17:39 | 416,734,377 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 3,221 | java | package com.example.pok.lab3_v2;
import android.content.Intent;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
import android.widget.TextView;
public class Week4_Intent extends AppCompatActivity {
String msg1 = "Lab3";
String msg2 = "Activity 1 : ";
//EditText edt;
float input1 = 0;
float input2 = 0;
Button sumBtn;
TextView result;
EditText num1, num2, ans;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_week4);
//edt = (EditText)findViewById(R.id.location);
sumBtn = (Button)findViewById(R.id.button);
num1 = (EditText)findViewById(R.id.input1);
num2 = (EditText)findViewById(R.id.input2);
ans = (EditText)findViewById(R.id.input3);
result = (TextView)findViewById(R.id.textView1);
sumBtn.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
String input1 = num1.getText().toString();
String input2 = num2.getText().toString();
String answer = ans.getText().toString();
String[] msgs = {input1,input2,answer};
Intent intent = new Intent(getApplicationContext(),Week4_Activity2.class);
intent.putExtra("msgs",msgs);
startActivityForResult(intent,1234);
// Intent intent = new Intent(getApplicationContext(),Activity2.class);
// startActivity(intent);
//String address = edt.getText().toString();
//address = address.replace(' ','+');
//Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("geo:0,0?q="+address));
/*String geoCode = "google.streetview:cbll=13.752366, 100.492577&cbp=0,145,0,5,-15";
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(geoCode));
startActivity(intent);*/
}
});
Log.d(msg1, msg2+"onCreate");
}
@Override
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
super.onActivityResult(requestCode, resultCode, data);
if(requestCode==1234)
{
String message=data.getStringExtra("result");
result.setText("Result = "+message);
}
}
@Override
protected void onStart() {
super.onStart();
Log.d(msg1, msg2+"onStart");
}
@Override
protected void onResume() {
super.onResume();
Log.d(msg1, msg2+"onResume");
}
@Override
protected void onPause() {
super.onPause();
Log.d(msg1, msg2+"onPause");
}
@Override
protected void onStop() {
super.onStop();
Log.d(msg1, msg2+"onStop");
}
@Override
protected void onDestroy() {
super.onDestroy();
Log.d(msg1, msg2+"onDestroy");
}
@Override
protected void onRestart() {
super.onRestart();
Log.d(msg1, msg2+"onRestart");
}
}
| [
"ekarat@as.nida.ac.th"
] | ekarat@as.nida.ac.th |
ba427229a42f693fdff8bb0c9a30bf8d49eca5fb | 63e9fb6e0ae181bfa9f6552bf31985fc60897ad6 | /api/android/internal2/src/main/java/org/societies/android/api/internal/personalisation/IPersonalisationManagerInternalAndroid.java | bb1694966a0cb371a48314772fc7f0c980567b58 | [
"BSD-2-Clause",
"BSD-2-Clause-Views"
] | permissive | societies/SOCIETIES-Platform | 6503b84b11b21f5bd4b5f1db0c22c4356b4a3f02 | 7050936833dcadf5cf318921ba97154843a05a46 | HEAD | 2016-09-05T22:29:20.159081 | 2014-05-20T10:53:33 | 2014-05-20T10:53:33 | 2,576,064 | 15 | 4 | null | null | null | null | UTF-8 | Java | false | false | 4,100 | java | /**
* Copyright (c) 2011, SOCIETIES Consortium (WATERFORD INSTITUTE OF TECHNOLOGY (TSSG), HERIOT-WATT UNIVERSITY (HWU), SOLUTA.NET
* (SN), GERMAN AEROSPACE CENTRE (Deutsches Zentrum fuer Luft- und Raumfahrt e.V.) (DLR), Zavod za varnostne tehnologije
* informacijske druzbe in elektronsko poslovanje (SETCCE), INSTITUTE OF COMMUNICATION AND COMPUTER SYSTEMS (ICCS), LAKE
* COMMUNICATIONS (LAKE), INTEL PERFORMANCE LEARNING SOLUTIONS LTD (INTEL), PORTUGAL TELECOM INOVACAO, SA (PTIN), IBM Corp.,
* INSTITUT TELECOM (ITSUD), AMITEC DIACHYTI EFYIA PLIROFORIKI KAI EPIKINONIES ETERIA PERIORISMENIS EFTHINIS (AMITEC), TELECOM
* ITALIA S.p.a.(TI), TRIALOG (TRIALOG), Stiftelsen SINTEF (SINTEF), NEC EUROPE LTD (NEC))
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following
* conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following
* disclaimer in the documentation and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING,
* BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT
* SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
package org.societies.android.api.internal.personalisation;
import org.societies.api.schema.personalisation.model.ActionBean;
import org.societies.api.schema.servicelifecycle.model.ServiceResourceIdentifier;
import org.societies.android.api.personalisation.IPersonalisationManagerAndroid;
/**
* @author Eliza
* @version 1.0
* @created 11-Nov-2011 14:42:55
*/
public interface IPersonalisationManagerInternalAndroid extends IPersonalisationManagerAndroid{
public static final String INTENT_RETURN_VALUE = "org.societies.android.api.internal.personalisation.ReturnValue";
public static final String GET_INTENT_ACTION = "org.societies.android.api.internal.personalisation.getIntentAction";
public static final String GET_PREFERENCE = "org.societies.android.api.internal.personalisation.getPreference";
public String methodsArray[] = {"getIntentAction(String clientID, String ownerID, org.societies.api.schema.servicelifecycle.model.ServiceResourceIdentifier serviceID, String preferenceName)",
"getPreference(String clientID, IIdentity ownerID, String serviceType, org.societies.api.schema.servicelifecycle.model.ServiceResourceIdentifier serviceID, String preferenceName)"};
/**
*
* @param ownerID
* @param serviceID
* @param preferenceName
* @param callback
*/
public ActionBean getIntentAction(String clientID, String ownerID, ServiceResourceIdentifier serviceID, String preferenceName);
/**
* Allows any service to request an context-based evaluated preference outcome.
* @return the outcome in the form of an IAction object
*
* @param ownerID the DigitalIIdentity of the owner of the preferences (i.e. the
* user of this service)
* @param serviceType the type of the service requesting the outcome
* @param serviceID the service identifier of the service requesting the
* outcome
* @param preferenceName the name of the preference requested
*/
public ActionBean getPreference(String clientID, String ownerID, String serviceType, ServiceResourceIdentifier serviceID, String preferenceName);
} | [
"EPapadopoulou"
] | EPapadopoulou |
a2ca3cb9f08a047c5893fb61eb15d92c84bb8258 | 2f4dda2aa9845129609c6950801bea5d421f98ce | /hr-user/src/main/java/com/devsuperior/hruser/entities/Role.java | 037574ed2098d70100c36f237474284fe972050d | [] | no_license | marcosviniciusam90/ms-course | 5a1bfc07569b21bd7abc1c0444008abe8a16dc83 | a7d258327dfef9ceb559c43a9c09288f125bd0dd | refs/heads/main | 2023-06-23T06:30:32.329688 | 2021-06-04T07:19:59 | 2021-06-04T07:19:59 | 372,039,037 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 450 | java | package com.devsuperior.hruser.entities;
import lombok.*;
import javax.persistence.*;
import java.io.Serializable;
@Getter
@Setter
@AllArgsConstructor
@NoArgsConstructor
@EqualsAndHashCode(onlyExplicitlyIncluded = true)
@Entity
@Table(name = "tb_role")
public class Role implements Serializable {
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Long id;
@EqualsAndHashCode.Include
private String roleName;
}
| [
"marcos.mendonca@matera.com"
] | marcos.mendonca@matera.com |
01c2ff9c92e6db0a3edaf7bfbf836678bdd5a2cf | a14d42f07e75911413213add5fd7d6d3453ea559 | /src/test/java/Kenneth/controller/PostControllerTest.java | 42d24c6dd2cd52f2c2df26fd293f6b97c78a6976 | [] | no_license | 785172550/spring-boot-quick-start | 87c6569ea812fd256d4382e8641fa0f585232e4b | af1a1dc470c561383a473861f6365610bef729ab | refs/heads/master | 2021-01-23T07:26:29.783518 | 2017-08-05T10:21:39 | 2017-08-05T10:21:39 | 86,424,138 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,270 | java | package Kenneth.controller;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.autoconfigure.web.servlet.AutoConfigureMockMvc;
import org.springframework.boot.test.autoconfigure.web.servlet.AutoConfigureWebMvc;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
import org.springframework.test.web.servlet.MockMvc;
import org.springframework.test.web.servlet.request.MockMvcRequestBuilders;
import org.springframework.test.web.servlet.result.MockMvcResultMatchers;
import org.springframework.test.web.servlet.result.ModelResultMatchers;
import static org.junit.Assert.*;
/**
* Created by Administrator on 2017/3/21.
*/
@RunWith(SpringJUnit4ClassRunner.class)
@SpringBootTest
@AutoConfigureMockMvc //mockMvc 提供servlet的环境
public class PostControllerTest {
@Autowired
private MockMvc mockMvc;
@Test
public void index() throws Exception {
}
@Test
public void createPage() throws Exception {
mockMvc.perform(MockMvcRequestBuilders.get("/posts/createPage"))
.andExpect(MockMvcResultMatchers.status().isOk());
}
} | [
"785172550@qq.com"
] | 785172550@qq.com |
3c6758bc4ee350762e3cf09c30511dbe6b0f3d5c | 7aa36431660ff1832debbb21dede14ce277be8ca | /src/main/java/lucene/index/MultiTermsEnum.java | ec663408a01e1c932d7d8cecbb90217196286529 | [] | no_license | DeanWanghewei/lucene-source-code-analysis | c329558f2f25c3517bc0277d64d4949db73afab2 | 1b50a9e8ece4ee0881d4745268ee1977b406c423 | refs/heads/master | 2020-04-28T21:26:30.584598 | 2019-03-15T10:13:42 | 2019-03-15T10:13:42 | 175,581,636 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 13,346 | java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package lucene.index;
import lucene.util.ArrayUtil;
import lucene.util.BytesRef;
import lucene.util.BytesRefBuilder;
import lucene.util.PriorityQueue;
import java.io.IOException;
import java.util.Arrays;
import java.util.Comparator;
/**
* Exposes {@link TermsEnum} API, merged from {@link TermsEnum} API of sub-segments.
* This does a merge sort, by term text, of the sub-readers.
*
* @lucene.experimental
*/
public final class MultiTermsEnum extends BaseTermsEnum {
private static final Comparator<TermsEnumWithSlice> INDEX_COMPARATOR = new Comparator<TermsEnumWithSlice>() {
@Override
public int compare(TermsEnumWithSlice o1, TermsEnumWithSlice o2) {
return o1.index - o2.index;
}
};
private final TermMergeQueue queue;
private final TermsEnumWithSlice[] subs; // all of our subs (one per sub-reader)
private final TermsEnumWithSlice[] currentSubs; // current subs that have at least one term for this field
private final TermsEnumWithSlice[] top;
private final MultiPostingsEnum.EnumWithSlice[] subDocs;
private BytesRef lastSeek;
private boolean lastSeekExact;
private final BytesRefBuilder lastSeekScratch = new BytesRefBuilder();
private int numTop;
private int numSubs;
private BytesRef current;
static class TermsEnumIndex {
public final static TermsEnumIndex[] EMPTY_ARRAY = new TermsEnumIndex[0];
final int subIndex;
final TermsEnum termsEnum;
public TermsEnumIndex(TermsEnum termsEnum, int subIndex) {
this.termsEnum = termsEnum;
this.subIndex = subIndex;
}
}
/** Returns how many sub-reader slices contain the current
* term. @see #getMatchArray */
public int getMatchCount() {
return numTop;
}
/** Returns sub-reader slices positioned to the current term. */
public TermsEnumWithSlice[] getMatchArray() {
return top;
}
/** Sole constructor.
* @param slices Which sub-reader slices we should
* merge. */
public MultiTermsEnum(ReaderSlice[] slices) {
queue = new TermMergeQueue(slices.length);
top = new TermsEnumWithSlice[slices.length];
subs = new TermsEnumWithSlice[slices.length];
subDocs = new MultiPostingsEnum.EnumWithSlice[slices.length];
for(int i=0;i<slices.length;i++) {
subs[i] = new TermsEnumWithSlice(i, slices[i]);
subDocs[i] = new MultiPostingsEnum.EnumWithSlice();
subDocs[i].slice = slices[i];
}
currentSubs = new TermsEnumWithSlice[slices.length];
}
@Override
public BytesRef term() {
return current;
}
/** The terms array must be newly created TermsEnum, ie
* {@link TermsEnum#next} has not yet been called. */
public TermsEnum reset(TermsEnumIndex[] termsEnumsIndex) throws IOException {
assert termsEnumsIndex.length <= top.length;
numSubs = 0;
numTop = 0;
queue.clear();
for(int i=0;i<termsEnumsIndex.length;i++) {
final TermsEnumIndex termsEnumIndex = termsEnumsIndex[i];
assert termsEnumIndex != null;
final BytesRef term = termsEnumIndex.termsEnum.next();
if (term != null) {
final TermsEnumWithSlice entry = subs[termsEnumIndex.subIndex];
entry.reset(termsEnumIndex.termsEnum, term);
queue.add(entry);
currentSubs[numSubs++] = entry;
} else {
// field has no terms
}
}
if (queue.size() == 0) {
return TermsEnum.EMPTY;
} else {
return this;
}
}
@Override
public boolean seekExact(BytesRef term) throws IOException {
queue.clear();
numTop = 0;
boolean seekOpt = false;
if (lastSeek != null && lastSeek.compareTo(term) <= 0) {
seekOpt = true;
}
lastSeek = null;
lastSeekExact = true;
for(int i=0;i<numSubs;i++) {
final boolean status;
// LUCENE-2130: if we had just seek'd already, prior
// to this seek, and the new seek term is after the
// previous one, don't try to re-seek this sub if its
// current term is already beyond this new seek term.
// Doing so is a waste because this sub will simply
// seek to the same spot.
if (seekOpt) {
final BytesRef curTerm = currentSubs[i].current;
if (curTerm != null) {
final int cmp = term.compareTo(curTerm);
if (cmp == 0) {
status = true;
} else if (cmp < 0) {
status = false;
} else {
status = currentSubs[i].terms.seekExact(term);
}
} else {
status = false;
}
} else {
status = currentSubs[i].terms.seekExact(term);
}
if (status) {
top[numTop++] = currentSubs[i];
current = currentSubs[i].current = currentSubs[i].terms.term();
assert term.equals(currentSubs[i].current);
}
}
// if at least one sub had exact match to the requested
// term then we found match
return numTop > 0;
}
@Override
public SeekStatus seekCeil(BytesRef term) throws IOException {
queue.clear();
numTop = 0;
lastSeekExact = false;
boolean seekOpt = false;
if (lastSeek != null && lastSeek.compareTo(term) <= 0) {
seekOpt = true;
}
lastSeekScratch.copyBytes(term);
lastSeek = lastSeekScratch.get();
for(int i=0;i<numSubs;i++) {
final SeekStatus status;
// LUCENE-2130: if we had just seek'd already, prior
// to this seek, and the new seek term is after the
// previous one, don't try to re-seek this sub if its
// current term is already beyond this new seek term.
// Doing so is a waste because this sub will simply
// seek to the same spot.
if (seekOpt) {
final BytesRef curTerm = currentSubs[i].current;
if (curTerm != null) {
final int cmp = term.compareTo(curTerm);
if (cmp == 0) {
status = SeekStatus.FOUND;
} else if (cmp < 0) {
status = SeekStatus.NOT_FOUND;
} else {
status = currentSubs[i].terms.seekCeil(term);
}
} else {
status = SeekStatus.END;
}
} else {
status = currentSubs[i].terms.seekCeil(term);
}
if (status == SeekStatus.FOUND) {
top[numTop++] = currentSubs[i];
current = currentSubs[i].current = currentSubs[i].terms.term();
queue.add(currentSubs[i]);
} else {
if (status == SeekStatus.NOT_FOUND) {
currentSubs[i].current = currentSubs[i].terms.term();
assert currentSubs[i].current != null;
queue.add(currentSubs[i]);
} else {
assert status == SeekStatus.END;
// enum exhausted
currentSubs[i].current = null;
}
}
}
if (numTop > 0) {
// at least one sub had exact match to the requested term
return SeekStatus.FOUND;
} else if (queue.size() > 0) {
// no sub had exact match, but at least one sub found
// a term after the requested term -- advance to that
// next term:
pullTop();
return SeekStatus.NOT_FOUND;
} else {
return SeekStatus.END;
}
}
@Override
public void seekExact(long ord) {
throw new UnsupportedOperationException();
}
@Override
public long ord() {
throw new UnsupportedOperationException();
}
private void pullTop() {
// extract all subs from the queue that have the same
// top term
assert numTop == 0;
numTop = queue.fillTop(top);
current = top[0].current;
}
private void pushTop() throws IOException {
// call next() on each top, and reorder queue
for (int i = 0; i < numTop; i++) {
TermsEnumWithSlice top = queue.top();
top.current = top.terms.next();
if (top.current == null) {
queue.pop();
} else {
queue.updateTop();
}
}
numTop = 0;
}
@Override
public BytesRef next() throws IOException {
if (lastSeekExact) {
// Must seekCeil at this point, so those subs that
// didn't have the term can find the following term.
// NOTE: we could save some CPU by only seekCeil the
// subs that didn't match the last exact seek... but
// most impls short-circuit if you seekCeil to term
// they are already on.
final SeekStatus status = seekCeil(current);
assert status == SeekStatus.FOUND;
lastSeekExact = false;
}
lastSeek = null;
// restore queue
pushTop();
// gather equal top fields
if (queue.size() > 0) {
// TODO: we could maybe defer this somewhat costly operation until one of the APIs that
// needs to see the top is invoked (docFreq, postings, etc.)
pullTop();
} else {
current = null;
}
return current;
}
@Override
public int docFreq() throws IOException {
int sum = 0;
for(int i=0;i<numTop;i++) {
sum += top[i].terms.docFreq();
}
return sum;
}
@Override
public long totalTermFreq() throws IOException {
long sum = 0;
for(int i=0;i<numTop;i++) {
final long v = top[i].terms.totalTermFreq();
assert v != -1;
sum += v;
}
return sum;
}
@Override
public PostingsEnum postings(PostingsEnum reuse, int flags) throws IOException {
MultiPostingsEnum docsEnum;
// Can only reuse if incoming enum is also a MultiDocsEnum
if (reuse != null && reuse instanceof MultiPostingsEnum) {
docsEnum = (MultiPostingsEnum) reuse;
// ... and was previously created w/ this MultiTermsEnum:
if (!docsEnum.canReuse(this)) {
docsEnum = new MultiPostingsEnum(this, subs.length);
}
} else {
docsEnum = new MultiPostingsEnum(this, subs.length);
}
int upto = 0;
ArrayUtil.timSort(top, 0, numTop, INDEX_COMPARATOR);
for(int i=0;i<numTop;i++) {
final TermsEnumWithSlice entry = top[i];
assert entry.index < docsEnum.subPostingsEnums.length: entry.index + " vs " + docsEnum.subPostingsEnums.length + "; " + subs.length;
final PostingsEnum subPostingsEnum = entry.terms.postings(docsEnum.subPostingsEnums[entry.index], flags);
assert subPostingsEnum != null;
docsEnum.subPostingsEnums[entry.index] = subPostingsEnum;
subDocs[upto].postingsEnum = subPostingsEnum;
subDocs[upto].slice = entry.subSlice;
upto++;
}
return docsEnum.reset(subDocs, upto);
}
@Override
public ImpactsEnum impacts(int flags) throws IOException {
// implemented to not fail CheckIndex, but you shouldn't be using impacts on a slow reader
return new SlowImpactsEnum(postings(null, flags));
}
final static class TermsEnumWithSlice {
private final ReaderSlice subSlice;
TermsEnum terms;
public BytesRef current;
final int index;
public TermsEnumWithSlice(int index, ReaderSlice subSlice) {
this.subSlice = subSlice;
this.index = index;
assert subSlice.length >= 0: "length=" + subSlice.length;
}
public void reset(TermsEnum terms, BytesRef term) {
this.terms = terms;
current = term;
}
@Override
public String toString() {
return subSlice.toString()+":"+terms;
}
}
private final static class TermMergeQueue extends PriorityQueue<TermsEnumWithSlice> {
final int[] stack;
TermMergeQueue(int size) {
super(size);
this.stack = new int[size];
}
@Override
protected boolean lessThan(TermsEnumWithSlice termsA, TermsEnumWithSlice termsB) {
return termsA.current.compareTo(termsB.current) < 0;
}
/** Add the {@link #top()} slice as well as all slices that are positionned
* on the same term to {@code tops} and return how many of them there are. */
int fillTop(TermsEnumWithSlice[] tops) {
final int size = size();
if (size == 0) {
return 0;
}
tops[0] = top();
int numTop = 1;
stack[0] = 1;
int stackLen = 1;
while (stackLen != 0) {
final int index = stack[--stackLen];
final int leftChild = index << 1;
for (int child = leftChild, end = Math.min(size, leftChild + 1); child <= end; ++child) {
TermsEnumWithSlice te = get(child);
if (te.current.equals(tops[0].current)) {
tops[numTop++] = te;
stack[stackLen++] = child;
}
}
}
return numTop;
}
private TermsEnumWithSlice get(int i) {
return (TermsEnumWithSlice) getHeapArray()[i];
}
}
@Override
public String toString() {
return "MultiTermsEnum(" + Arrays.toString(subs) + ")";
}
}
| [
"deanwanghewei@163.com"
] | deanwanghewei@163.com |
3fb5e510111a65cbcb2365267af9cc0d0cebf68b | d7b482928362fbb5efa4fc26ec35c1df5288fe7f | /src/main/java/com/uba/waei/ws/CreateEntrustUser.java | a357f86ff0b41b75a6425a34aa5e83cdbb1e36c9 | [] | no_license | folzieds/2FA_entrust | c3f1eec92ae0ef6b4427c8fddc4a82f79d288c5f | 005115d305b8284cbdebf398a2d5a55110a16c57 | refs/heads/master | 2022-07-14T13:37:43.810354 | 2020-05-08T12:24:35 | 2020-05-08T12:24:35 | 262,286,898 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,431 | java |
package com.uba.waei.ws;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlType;
/**
* <p>Java class for createEntrustUser complex type.
*
* <p>The following schema fragment specifies the expected content contained within this class.
*
* <pre>
* <complexType name="createEntrustUser">
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <element name="request" type="{http://ws.waei.uba.com/}retailUser" minOccurs="0"/>
* </sequence>
* </restriction>
* </complexContent>
* </complexType>
* </pre>
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "createEntrustUser", propOrder = {
"request"
})
public class CreateEntrustUser {
protected RetailUser request;
/**
* Gets the value of the request property.
*
* @return
* possible object is
* {@link RetailUser }
*
*/
public RetailUser getRequest() {
return request;
}
/**
* Sets the value of the request property.
*
* @param value
* allowed object is
* {@link RetailUser }
*
*/
public void setRequest(RetailUser value) {
this.request = value;
}
}
| [
"aosu@teamapt.com"
] | aosu@teamapt.com |
43fdf7333f8c859e964932c5eb044ab518de6fd5 | 7ed89735d9cb52adb326c86f64c6096fcd3cb145 | /src/main/java/com/ww/design_pattern/pattern/behavioral/strategy/ReturnCashPromotionStrategy.java | cb680e2847f321571eb949ea950bf315a149d88d | [] | no_license | wwcom614/DesignPattern | e4e76a7e47421d8b1d6899e6a61a53a788201b9a | 4f4017330c0ac083cb8bb5c36d00fd4fa73ed97d | refs/heads/master | 2020-04-25T07:21:49.940807 | 2019-02-26T01:03:00 | 2019-02-26T01:03:00 | 172,611,515 | 1 | 0 | null | null | null | null | UTF-8 | Java | false | false | 379 | java | package com.ww.design_pattern.pattern.behavioral.strategy;
import lombok.extern.java.Log;
//商品促销--返现策略
@Log
public class ReturnCashPromotionStrategy implements PromotionStrategy{
@Override
public void doPromotion() {
log.info("【ReturnCashPromotionStrategy】:该商品参加返现促销,返现将存放到您的账户余额中。");
}
}
| [
"wwcom614@qq.com"
] | wwcom614@qq.com |
8b646d4837524f54cb57d87e836f6a9744128d48 | 016b76c3cd1233d9d03b8e8da3e886ef20e696dd | /cyclops-core/src/main/java/com/aol/cyclops/lambda/tuple/PTuple5.java | 979f2583fd5bda36a841c0045645c47fe32303c3 | [
"MIT"
] | permissive | anoordover/cyclops | 37af6ef88dc71cb6598fbcedcad601b1521c48ab | 44f319ad03f65c7daf70cf09ee943cf6a1d27d6a | refs/heads/master | 2021-01-24T19:51:21.274975 | 2016-02-24T12:14:39 | 2016-02-24T12:14:39 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 7,954 | java | package com.aol.cyclops.lambda.tuple;
import java.util.Arrays;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
import java.util.concurrent.CompletableFuture;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.Executor;
import java.util.function.Function;
import com.aol.cyclops.functions.QuintFunction;
import com.aol.cyclops.lambda.tuple.lazymap.LazyMap1PTuple8;
import com.aol.cyclops.lambda.tuple.lazymap.LazyMap2PTuple8;
import com.aol.cyclops.lambda.tuple.lazymap.LazyMap3PTuple8;
import com.aol.cyclops.lambda.tuple.lazymap.LazyMap4PTuple8;
import com.aol.cyclops.lambda.tuple.lazymap.LazyMap5PTuple8;
public interface PTuple5<T1,T2,T3,T4,T5> extends PTuple4<T1,T2,T3,T4> {
default T5 v5(){
if(arity()<5)
throw new ClassCastException("Attempt to upscale to " + PTuple5.class.getCanonicalName() + " from com.aol.cyclops.lambda.tuple.Tuple"+arity());
return (T5)getCachedValues().get(4);
}
default T5 _5(){
return v5();
}
default T5 getT5(){
return v5();
}
default int arity(){
return 5;
}
default <R> R apply5(Function<T1,Function<T2,Function<T3,Function<T4,Function<T5,R>>>>> fn){
return fn.apply(v1()).apply(v2()).apply(v3()).apply(v4()).apply(v5());
}
default <R> R call(QuintFunction<T1,T2,T3,T4,T5,R> fn){
return fn.apply(v1(),v2(),v3(),v4(),v5());
}
default <R> CompletableFuture<R> callAsync(QuintFunction<T1,T2,T3,T4,T5,R> fn){
return CompletableFuture.completedFuture(this).thenApplyAsync(i->fn.apply(i.v1(),
i.v2(),i.v3(),i.v4(),i.v5()));
}
default <R> CompletableFuture<R> applyAsync5(Function<T1,Function<T2,Function<T3,Function<T4,Function<T5,R>>>>> fn){
return CompletableFuture.completedFuture(v5())
.thenApplyAsync(fn.apply(v1()).apply(v2()).apply(v3()).apply(v4()));
}
default <R> CompletableFuture<R> callAsync(QuintFunction<T1,T2,T3,T4,T5,R> fn, Executor e){
return CompletableFuture.completedFuture(this).thenApplyAsync(i->fn.apply(i.v1(),
i.v2(),i.v3(),i.v4(),i.v5()),e);
}
default <R> CompletableFuture<R> applyAsync5(Function<T1,Function<T2,Function<T3,Function<T4,Function<T5,R>>>>> fn, Executor e){
return CompletableFuture.completedFuture(v5())
.thenApplyAsync(fn.apply(v1()).apply(v2()).apply(v3()).apply(v4()),e);
}
/**Strict mapping of the first element
*
* @param fn Mapping function
* @return Tuple5
*/
default <T> PTuple5<T,T2,T3,T4,T5> map1(Function<T1,T> fn){
if(arity()!=5)
return (PTuple5)PTuple4.super.map1(fn);
else
return PowerTuples.tuple(fn.apply(v1()),v2(),v3(),v4(),v5());
}
/**
* Lazily Map 1st element and memoise the result
* @param fn Map function
* @return
*/
@SuppressWarnings({ "rawtypes", "unchecked" })
default <T> PTuple5<T,T2,T3,T4,T5> lazyMap1(Function<T1,T> fn){
if(arity()!=5)
return (PTuple5)PTuple4.super.lazyMap1(fn);
return new LazyMap1PTuple8(fn,(PTuple8)this);
}
/**
* Lazily Map 2nd element and memoise the result
* @param fn Map function
* @return
*/
@SuppressWarnings({ "rawtypes", "unchecked" })
default <T> PTuple5<T1,T,T3,T4,T5> lazyMap2(Function<T2,T> fn){
if(arity()!=5)
return (PTuple5)PTuple4.super.lazyMap2(fn);
return new LazyMap2PTuple8(fn,(PTuple8)this);
}
/** Map the second element in this Tuple
* @param fn mapper function
* @return new Tuple3
*/
default <T> PTuple5<T1,T,T3,T4,T5> map2(Function<T2,T> fn){
if(arity()!=5)
return (PTuple5)PTuple4.super.map2(fn);
return of(v1(),fn.apply(v2()),v3(),v4(),v5());
}
/**
* Lazily Map 3rd element and memoise the result
* @param fn Map function
* @return
*/
@SuppressWarnings({ "rawtypes", "unchecked" })
default <T> PTuple5<T1,T2,T,T4,T5> lazyMap3(Function<T3,T> fn){
if(arity()!=5)
return (PTuple5)PTuple4.super.lazyMap3(fn);
return new LazyMap3PTuple8(fn,(PTuple8)this);
}
/*
* @see com.aol.cyclops.lambda.tuple.Tuple4#map3(java.util.function.Function)
*/
default <T> PTuple5<T1,T2,T,T4,T5> map3(Function<T3,T> fn){
if(arity()!=5)
return (PTuple5)PTuple4.super.map3(fn);
return of(v1(),v2(),fn.apply(v3()),v4(),v5());
}
/**
* Lazily Map 4th element and memoise the result
* @param fn Map function
* @return
*/
@SuppressWarnings({ "rawtypes", "unchecked" })
default <T> PTuple5<T1,T2,T3,T,T5> lazyMap4(Function<T4,T> fn){
if(arity()!=5)
return (PTuple5)PTuple4.super.lazyMap4(fn);
return new LazyMap4PTuple8(fn,(PTuple8)this);
}
/*
* Map element 4
* @see com.aol.cyclops.lambda.tuple.Tuple4#map4(java.util.function.Function)
*/
default <T> PTuple5<T1,T2,T3,T,T5> map4(Function<T4,T> fn){
if(arity()!=5)
return (PTuple5)PTuple4.super.map4(fn);
return of(v1(),v2(),v3(),fn.apply(v4()),v5());
}
/**
* Lazily Map 5th element and memoise the result
* @param fn Map function
* @return
*/
@SuppressWarnings({ "rawtypes", "unchecked" })
default <T> PTuple5<T1,T2,T3,T4,T> lazyMap5(Function<T5,T> fn){
return new LazyMap5PTuple8(fn,(PTuple8)this);
}
/**
* Map the 5th element in a tuple to a different value
*
* @param fn Mapper function
* @return new Tuple5
*/
default <T> PTuple5<T1,T2,T3,T4,T> map5(Function<T5,T> fn){
return of(v1(),v2(),v3(),v4(),fn.apply(v5()));
}
default PTuple4<T1,T2,T3,T4> tuple4(){
return (PTuple4)withArity(4);
}
default PTuple5<T5,T4,T3,T2,T1> swap5(){
return of(v5(),v4(),v3(),v2(),v1());
}
/**
* Lazily reorder a PTuple5 or both a narrow and reorder a larger Tuple
*
* @param v1S Function that determines new first element
* @param v2S Function that determines new second element
* @param v3S Function that determines new third element
* @param v4S Function that determines new fourth element
* @param v5S Function that determines new fifth element
* @return reordered PTuple5
*/
default <NT1, NT2, NT3, NT4,NT5> PTuple5<NT1, NT2, NT3, NT4,NT5> reorder(
Function<PTuple5<T1, T2, T3, T4,T5>, NT1> v1S,
Function<PTuple5<T1, T2, T3, T4,T5>, NT2> v2S,
Function<PTuple5<T1, T2, T3, T4,T5>, NT3> v3S,
Function<PTuple5<T1, T2, T3, T4,T5>, NT4> v4S,
Function<PTuple5<T1, T2, T3, T4,T5>, NT5> v5S) {
PTuple5<T1,T2,T3,T4,T5> host = this;
return new TupleImpl(Arrays.asList(), 5) {
public NT1 v1() {
return v1S.apply(host);
}
public NT2 v2() {
return v2S.apply(host);
}
public NT3 v3() {
return v3S.apply(host);
}
public NT4 v4() {
return v4S.apply(host);
}
public NT5 v5() {
return v5S.apply(host);
}
@Override
public List<Object> getCachedValues() {
return Arrays.asList(v1(), v2(), v3(), v4(),v5());
}
@Override
public Iterator iterator() {
return getCachedValues().iterator();
}
};
}
default PTuple5<T1,T2,T3,T4,T5> memo(){
if(arity()!=5)
return (PTuple5)PTuple4.super.memo();
PTuple5<T1,T2,T3,T4,T5> host = this;
Map<Integer,Object> values = new ConcurrentHashMap<>();
return new TupleImpl(Arrays.asList(),5){
public T1 v1(){
return ( T1)values.computeIfAbsent(new Integer(0), key -> host.v1());
}
public T2 v2(){
return ( T2)values.computeIfAbsent(new Integer(1), key -> host.v2());
}
public T3 v3(){
return ( T3)values.computeIfAbsent(new Integer(2), key -> host.v3());
}
public T4 v4(){
return ( T4)values.computeIfAbsent(new Integer(3), key -> host.v4());
}
public T5 v5(){
return ( T5)values.computeIfAbsent(new Integer(4), key -> host.v5());
}
@Override
public List<Object> getCachedValues() {
return Arrays.asList(v1(),v2(),v3(),v4(),v5());
}
@Override
public Iterator iterator() {
return getCachedValues().iterator();
}
};
}
public static <T1,T2,T3,T4,T5> PTuple5<T1,T2,T3,T4,T5> ofTuple(Object tuple5){
return (PTuple5)new TupleImpl(tuple5,5);
}
public static <T1,T2,T3,T4,T5> PTuple5<T1,T2,T3,T4,T5> of(T1 t1, T2 t2,T3 t3,T4 t4,T5 t5){
return (PTuple5)new TupleImpl(Arrays.asList(t1,t2,t3,t4,t5),5);
}
}
| [
"john.mcclean@teamaol.com"
] | john.mcclean@teamaol.com |
249f3246932f8d59d8397d8310fc3db6e757dc09 | d35b0a593ad550930138aeaf12fa70256d0c275e | /src/java/bd/ConectaBd.java | 28373c2800973e2743e98be3d9556107b3a886d7 | [] | no_license | Marcoar02/TareaS10 | 1e8e5bd700610d59daa1893a883c2a08f5728aee | 8cb740bd34b8851c096b65b23f6e62676728fca1 | refs/heads/master | 2022-11-17T13:04:03.266158 | 2020-07-16T21:28:00 | 2020-07-16T21:28:00 | 280,262,601 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 791 | java | package bd;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;
public class ConectaBd {
public Connection getConnection() throws SQLException{
Connection cn = null;
try {
Class.forName(driver).newInstance();
cn = DriverManager.getConnection(url, user, password);
} catch (ClassNotFoundException
| InstantiationException
| IllegalAccessException ex) {
throw new SQLException(ex.getMessage());
}
return cn;
}
private final String url = "jdbc:mysql://localhost:3306/libreria";
private final String driver = "com.mysql.jdbc.Driver";
private final String user = "root";
private final String password = "123";
}
| [
"josephcambillo@gmail.com"
] | josephcambillo@gmail.com |
38fa5115acc3509057abaa54217f037315ac1427 | 43eb6bc6146369d908457ee0b280eb83b9adfe95 | /WhoWroteIt2/app/src/main/java/com/example/zyandeep/whowroteit2/BookLoader.java | 71487a2b8097042a9585b64c49a2dfd002882584 | [] | no_license | zyandeep/android-apps | 1f55695fbc83608e9c6daac5af699f1fa9ec9ea3 | 7589709308d0b1f77e3817d67a4b5ef61b573794 | refs/heads/master | 2020-03-28T09:24:23.388003 | 2018-12-12T13:44:00 | 2018-12-12T13:44:00 | 148,034,235 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 661 | java | package com.example.zyandeep.whowroteit2;
import android.content.Context;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.support.v4.content.AsyncTaskLoader;
public class BookLoader extends AsyncTaskLoader<String>{
private String mQuery;
public BookLoader(@NonNull Context context, String query) {
super(context);
this.mQuery = query;
}
@Override
protected void onStartLoading() {
super.onStartLoading();
forceLoad();
}
@Nullable
@Override
public String loadInBackground() {
return NetworkUtil.getBookInfo(mQuery);
}
} | [
"zyandeep000@gmail.com"
] | zyandeep000@gmail.com |
3475fe4a73641bad8092706b8b537ac10b76832f | 1132cef0ea0246b0ef505ee8daa3cdb342499fbc | /DesignPatterns/src/Behavioral_Pattern/iterator/ConcreteAggregate.java | e18e73cc7291555810a86f66eb4968f20781341d | [] | no_license | zhhaochen/Algorithm | fd92a748fd727700abba8ad92db0d72663058666 | 509a8f29f00ed665182c8314c11c5a67b023701f | refs/heads/master | 2023-07-02T08:14:13.918245 | 2021-08-05T16:31:08 | 2021-08-05T16:31:08 | 288,951,652 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 395 | java | package Behavioral_Pattern.iterator;
public class ConcreteAggregate implements Aggregate {
private Integer[] items;
public ConcreteAggregate() {
items = new Integer[10];
for (int i = 0; i < items.length; i++) {
items[i] = i;
}
}
@Override
public Iterator createIterator() {
return new ConcreteIterator<Integer>(items);
}
}
| [
"zhhaochen@gmail.com"
] | zhhaochen@gmail.com |
17ffe6e7725682e2e3201cab29813ec172558a86 | fb6acb5220200203f331c1d9f28eba6fadf06b06 | /src/main/java/net/guides/springboot2/controller/EmployeeController.java | d09c224dea2403a46ee975cd3ece9219ba438e9d | [] | no_license | lrivascl/springboot2-jpa-crud-back | a6f5d4c78834eeccb248d25a71c71c1ec1a09f52 | 3d15e6a7629eec27fecae521f5c339da8f034440 | refs/heads/master | 2020-09-08T06:55:59.727021 | 2019-11-11T19:42:16 | 2019-11-11T19:42:16 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 3,440 | java | package net.guides.springboot2.controller;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import javax.validation.Valid;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.hibernate.annotations.common.util.impl.LoggerFactory;
import org.jboss.logging.Logger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.DeleteMapping;
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.PutMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import net.guides.springboot2.model.Employee;
import net.guides.springboot2.repository.EmployeeRepository;
import net.guides.springboot2.exception.ResourceNotFoundException;
@RestController
@CrossOrigin(origins = "http://localhost:4200")
@RequestMapping("/api/v1")
public class EmployeeController {
private Log logger = LogFactory.getLog(EmployeeController.class);
@Autowired
private EmployeeRepository employeeRepository;
@GetMapping("/employees")
public List<Employee> getAllEmployees() {
logger.info("Devuelve empleados" + employeeRepository.findAll());
return employeeRepository.findAll();
}
@GetMapping("/employees/{id}")
public ResponseEntity<Employee> getEmployeeById(@PathVariable(value = "id") Long employeeId)
throws ResourceNotFoundException {
Employee employee = employeeRepository.findById(employeeId)
.orElseThrow(() -> new ResourceNotFoundException("Employee not found for this id :: " + employeeId));
return ResponseEntity.ok().body(employee);
}
@PostMapping("/employees")
public Employee createEmployee(@Valid @RequestBody Employee employee) {
logger.info("Datos recibidos" + employee);
return employeeRepository.save(employee);
}
@PutMapping("/employees/{id}")
public ResponseEntity<Employee> updateEmployee(@PathVariable(value = "id") Long employeeId,
@Valid @RequestBody Employee employeeDetails) throws ResourceNotFoundException {
Employee employee = employeeRepository.findById(employeeId)
.orElseThrow(() -> new ResourceNotFoundException("Employee not found for this id :: " + employeeId));
employee.setEmailId(employeeDetails.getEmailId());
employee.setLastName(employeeDetails.getLastName());
employee.setFirstName(employeeDetails.getFirstName());
final Employee updatedEmployee = employeeRepository.save(employee);
return ResponseEntity.ok(updatedEmployee);
}
@DeleteMapping("/employees/{id}")
public Map<String, Boolean> deleteEmployee(@PathVariable(value = "id") Long employeeId)
throws ResourceNotFoundException {
Employee employee = employeeRepository.findById(employeeId)
.orElseThrow(() -> new ResourceNotFoundException("Employee not found for this id :: " + employeeId));
employeeRepository.delete(employee);
Map<String, Boolean> response = new HashMap<>();
response.put("deleted", Boolean.TRUE);
return response;
}
}
| [
"luis.rivas.bustos@gmail.com"
] | luis.rivas.bustos@gmail.com |
b96830d64d4f43cb4aefbb614e6b59c421efac52 | a1fa3d0f316dc5bae17975476f6a66b63a6c5d81 | /src/main/java/vn/mog/topup/contract/TopupTransactionRequest.java | 344546cc15920d969ad962b30135649aef98939a | [] | no_license | chiky001/TopupClientForMerchant | e6df0fffb5e9f3d27621fe1f881b26cc7f469c9f | bf46cd12541c202ac59f77858387e82e458c002c | refs/heads/master | 2021-01-21T06:38:29.200273 | 2017-02-27T03:32:52 | 2017-02-27T03:32:52 | 83,261,526 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,717 | java | package vn.mog.topup.contract;
public class TopupTransactionRequest {
private String username;
private String apiCode;
private String apiUsername;
private String requestId;
private String txnId;
private String txnRequestId;
private String serviceCode;
private String phoneNumber;
private Integer price;
private Integer quantity;
private String dataSign;
public TopupTransactionRequest() {
}
public TopupTransactionRequest(String username, String apiCode, String apiUsername, String requestId,
String serviceCode, String phoneNumber, Integer price, String dataSign) {
this.username = username;
this.apiCode = apiCode;
this.apiUsername = apiUsername;
this.requestId = requestId;
this.serviceCode = serviceCode;
this.phoneNumber = phoneNumber;
this.price = price;
this.dataSign = dataSign;
}
public TopupTransactionRequest(String username, String apiCode, String apiUsername, String requestId,
String serviceCode, Integer price, Integer quantity, String dataSign) {
this.username = username;
this.apiCode = apiCode;
this.apiUsername = apiUsername;
this.requestId = requestId;
this.serviceCode = serviceCode;
this.price = price;
this.quantity = quantity;
this.dataSign = dataSign;
}
public String getUsername() {
return username;
}
public String getApiCode() {
return apiCode;
}
public String getApiUsername() {
return apiUsername;
}
public String getRequestId() {
return requestId;
}
public String getTxnId() {
return txnId;
}
public String getTxnRequestId() {
return txnRequestId;
}
public void setTxnId(String txnId) {
this.txnId = txnId;
}
public void setTxnRequestId(String txnRequestId) {
this.txnRequestId = txnRequestId;
}
public String getServiceCode() {
return serviceCode;
}
public String getPhoneNumber() {
return phoneNumber;
}
public Integer getPrice() {
return price;
}
public Integer getQuantity() {
return quantity;
}
public String getDataSign() {
return dataSign;
}
public void setUsername(String username) {
this.username = username;
}
public void setApiCode(String apiCode) {
this.apiCode = apiCode;
}
public void setApiUsername(String apiUsername) {
this.apiUsername = apiUsername;
}
public void setRequestId(String requestId) {
this.requestId = requestId;
}
public void setServiceCode(String serviceCode) {
this.serviceCode = serviceCode;
}
public void setPhoneNumber(String phoneNumber) {
this.phoneNumber = phoneNumber;
}
public void setPrice(Integer price) {
this.price = price;
}
public void setQuantity(Integer quantity) {
this.quantity = quantity;
}
public void setDataSign(String dataSign) {
this.dataSign = dataSign;
}
}
| [
"cunx@truemoney.com.vn"
] | cunx@truemoney.com.vn |
324ae35bb63e5cb0dd20ba2ea5e80732810c698b | 8d5ab245c936475fddeea8b94d0134456d9ea252 | /build/generated/src/org/apache/jsp/companypannel/frgtPWD_jsp.java | 3e81b720cd5e052159cf0a63fe18abaa829f1daf | [] | no_license | iamkumarabhishek/RPO | c2441e117fc5b37815022bf2fe0006728466f978 | eb1bd900d3090d82b0aeb9da11a4dad354257c62 | refs/heads/master | 2021-01-21T17:37:18.316204 | 2017-05-21T15:57:29 | 2017-05-21T15:57:29 | 91,966,223 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 4,219 | java | package org.apache.jsp.companypannel;
import javax.servlet.*;
import javax.servlet.http.*;
import javax.servlet.jsp.*;
public final class frgtPWD_jsp extends org.apache.jasper.runtime.HttpJspBase
implements org.apache.jasper.runtime.JspSourceDependent {
private static final JspFactory _jspxFactory = JspFactory.getDefaultFactory();
private static java.util.List<String> _jspx_dependants;
private org.glassfish.jsp.api.ResourceInjector _jspx_resourceInjector;
public java.util.List<String> getDependants() {
return _jspx_dependants;
}
public void _jspService(HttpServletRequest request, HttpServletResponse response)
throws java.io.IOException, ServletException {
PageContext pageContext = null;
HttpSession session = null;
ServletContext application = null;
ServletConfig config = null;
JspWriter out = null;
Object page = this;
JspWriter _jspx_out = null;
PageContext _jspx_page_context = null;
try {
response.setContentType("text/html;charset=UTF-8");
pageContext = _jspxFactory.getPageContext(this, request, response,
null, true, 8192, true);
_jspx_page_context = pageContext;
application = pageContext.getServletContext();
config = pageContext.getServletConfig();
session = pageContext.getSession();
out = pageContext.getOut();
_jspx_out = out;
_jspx_resourceInjector = (org.glassfish.jsp.api.ResourceInjector) application.getAttribute("com.sun.appserv.jsp.resource.injector");
out.write("\n");
out.write("\n");
out.write("\n");
out.write("<!DOCTYPE html>\n");
out.write("<html>\n");
out.write(" <head>\n");
out.write(" <meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\">\n");
out.write(" <script src=\"layout/scripts/job_add.js\"></script>\n");
out.write(" <link href=\"layout/styles/add_job.css\" rel=\"stylesheet\" type=\"text/css\" media=\"all\">\n");
out.write(" <title>Password Recovery</title>\n");
out.write(" </head>\n");
out.write(" <body>\n");
out.write(" <div id=\"headd\">\n");
out.write(" <h1 style=\"float:left;margin-left:10px;\">FlyHigh Job Recruiting Services</h1>\n");
out.write(" <h1 style=\"float:right;margin-right:10px;\"> Password Recovery Page</h1>\n");
out.write(" </div>\n");
out.write(" <hr>\n");
out.write(" <br>\n");
out.write(" <br>\n");
out.write(" \n");
out.write(" <div id=del_tble>\n");
out.write(" <h1>Update Password</h1>\n");
out.write(" <form name=\"updatePassForm\" action=\"rcvrPass.jsp\" method=\"POST\">\n");
out.write(" <table border=\"1\">\n");
out.write(" <tbody>\n");
out.write(" <tr>\n");
out.write(" <td>Enter User Name : </td>\n");
out.write(" <td><input type=\"text\" name=\"userAgain\" value=\"\" size=\"20\" /></td>\n");
out.write(" </tr>\n");
out.write(" <tr>\n");
out.write(" <td>New Password : </td>\n");
out.write(" <td><input type=\"text\" name=\"newPass\" value=\"\" size=\"20\" /></td>\n");
out.write(" </tr>\n");
out.write(" \n");
out.write(" </tbody>\n");
out.write(" </table>\n");
out.write(" <input type=\"submit\" value=\"Submit\" name=\"submit\" />\n");
out.write(" </form>\n");
out.write(" </div>\n");
out.write(" </body>\n");
out.write("</html>\n");
} catch (Throwable t) {
if (!(t instanceof SkipPageException)){
out = _jspx_out;
if (out != null && out.getBufferSize() != 0)
out.clearBuffer();
if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
else throw new ServletException(t);
}
} finally {
_jspxFactory.releasePageContext(_jspx_page_context);
}
}
}
| [
"surajkumarvarsi@gmail.com"
] | surajkumarvarsi@gmail.com |
d419e075f6615aba2dd12790cf22da5a5b65b6a4 | 98391b51ca4d1c8837678b10c1feb9b7bcf6e919 | /mantis-tests/src/test/java/sv/pvt/mantis/appmanager/HttpSession.java | f37dfb38f5921bdc0eb712cd25b4e8490265bc59 | [
"Apache-2.0"
] | permissive | ltana/java_prog_for_test | 6a25a3143c900f1886909c602a386a4b2d1019d0 | 7c41c413c0904a37c18ddd7061997221c0da6cf3 | refs/heads/master | 2021-01-21T13:44:13.800505 | 2016-04-25T21:27:19 | 2016-04-25T21:27:19 | 52,155,888 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,347 | java | package sv.pvt.mantis.appmanager;
import org.apache.http.client.entity.UrlEncodedFormEntity;
import org.apache.http.client.methods.CloseableHttpResponse;
import org.apache.http.client.methods.HttpGet;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.impl.client.CloseableHttpClient;
import org.apache.http.impl.client.HttpClients;
import org.apache.http.impl.client.LaxRedirectStrategy;
import org.apache.http.impl.entity.StrictContentLengthStrategy;
import org.apache.http.message.BasicNameValuePair;
import org.apache.http.util.EntityUtils;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
/**
* Created by Ltana on 20.04.2016.
*/
public class HttpSession {
private CloseableHttpClient httpclient;
private ApplicationManager app;
public HttpSession(ApplicationManager app) {
this.app = app;
httpclient = HttpClients.custom()
.setRedirectStrategy(new LaxRedirectStrategy()).build();
}
public boolean login(String username, String password) throws IOException {
HttpPost post = new HttpPost(app.getProperty("web.baseUrl") + "/login.php");
List<BasicNameValuePair> params = new ArrayList<>();
params.add(new BasicNameValuePair("username", username));
params.add(new BasicNameValuePair("password", password));
params.add(new BasicNameValuePair("secure_session", "on"));
params.add(new BasicNameValuePair("return", "index.php"));
post.setEntity(new UrlEncodedFormEntity(params));
CloseableHttpResponse response = httpclient.execute(post);
String body = getTextFrom(response);
return body.contains(String.format("<span class=\"italic\">%s</span>", username));
}
private String getTextFrom(CloseableHttpResponse response) throws IOException {
try {
return EntityUtils.toString(response.getEntity());
} finally {
response.close();
}
}
public boolean IsLoggedInAs(String username) throws IOException {
HttpGet get = new HttpGet(app.getProperty("web.baseUrl") + "/index.php");
CloseableHttpResponse response = httpclient.execute(get);
String body = getTextFrom(response);
return body.contains(String.format("<span class=\"italic\">%s</span>", username));
}
}
| [
"ltanaice@gmail.com"
] | ltanaice@gmail.com |
d3b0d69e49103daac24f263acab29392cc1f1a9f | 4c88c1c711722895041bf25155a99bb910b673e5 | /ngsql-parser/src/main/java/org/ng12306/ngsql/parser/ast/expression/primary/function/comparison/Greatest.java | 1ff41dba3266e8e1657fc2a0d49ce88d5dd3c964 | [] | no_license | 120011676/12306ngSQL | 834ef99e35c3e061c7528f5dadb3822f76e2bb3d | a5d61a2e9288ac2117664663102464f072716879 | refs/heads/master | 2021-01-17T20:54:31.770519 | 2013-10-26T06:51:39 | 2013-10-26T06:53:56 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,316 | java | /*
* Copyright 2012-2013 NgSql 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 org.ng12306.ngsql.parser.ast.expression.primary.function.comparison;
import java.util.List;
import org.ng12306.ngsql.parser.ast.expression.Expression;
import org.ng12306.ngsql.parser.ast.expression.primary.function.FunctionExpression;
/**
*
* [添加说明]
* @author: <a href="mailto:lvbomr@gmail.com">lvbo</a>
* @date: 2013-5-25 下午12:55:48
* @version: 1.0
*/
public class Greatest extends FunctionExpression {
public Greatest(List<Expression> arguments) {
super("GREATEST", arguments);
}
@Override
public FunctionExpression constructFunction(List<Expression> arguments) {
return new Greatest(arguments);
}
}
| [
"mr.lvbo@qq.com"
] | mr.lvbo@qq.com |
bc56010b0028960101a857a27da1ccaf0c641603 | 93eda24b18ad4c0f665516796674b601b4dc9741 | /src/main/java/com/nfmedia/springmvc/views/HelloView.java | 96d495d3949c8a12ac807fece27fbe975f1dcda7 | [] | no_license | xiaohang13/learnspringmvc | 4431827036a2a655f5689212680111ee87d60b17 | b56ffbfd800dbcbc17dabb6c97a4a61e69703e03 | refs/heads/master | 2021-01-12T01:12:27.778112 | 2017-01-14T17:06:36 | 2017-01-14T17:06:36 | 78,353,752 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 727 | java | package com.nfmedia.springmvc.views;
import org.springframework.stereotype.Component;
import org.springframework.web.servlet.View;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.Date;
import java.util.Map;
/**
* Description
* <p>
* Author rabbit.
* Datetime 2017/1/1.
*/
@Component
public class HelloView implements View {
@Override
public String getContentType() {
return "text/html";
}
@Override
public void render(Map<String, ?> map, HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse) throws Exception {
httpServletResponse.getWriter().print("hello view, time: " + new Date());
}
}
| [
"972382409@qq.com"
] | 972382409@qq.com |
bdb454c2fb6fbcce2a8a0177c4d069d03e5f422e | fa91450deb625cda070e82d5c31770be5ca1dec6 | /Diff-Raw-Data/27/27_7d2aef87ee382e4d0d205ee990b2e2b9eda00b92/ServerTestsActivator/27_7d2aef87ee382e4d0d205ee990b2e2b9eda00b92_ServerTestsActivator_t.java | 340b35313282595ac453d1b96abff8eed0dcaadd | [] | no_license | zhongxingyu/Seer | 48e7e5197624d7afa94d23f849f8ea2075bcaec0 | c11a3109fdfca9be337e509ecb2c085b60076213 | refs/heads/master | 2023-07-06T12:48:55.516692 | 2023-06-22T07:55:56 | 2023-06-22T07:55:56 | 259,613,157 | 6 | 2 | null | 2023-06-22T07:55:57 | 2020-04-28T11:07:49 | null | UTF-8 | Java | false | false | 4,096 | java | /*******************************************************************************
* Copyright (c) 2010, 2011 IBM Corporation and others
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.orion.server.tests;
import org.eclipse.orion.internal.server.servlets.Activator;
import org.eclipse.orion.server.configurator.ConfiguratorActivator;
import org.osgi.framework.*;
import org.osgi.service.http.HttpService;
import org.osgi.service.packageadmin.PackageAdmin;
import org.osgi.util.tracker.ServiceTracker;
public class ServerTestsActivator implements BundleActivator {
private static final String EQUINOX_HTTP_JETTY = "org.eclipse.equinox.http.jetty"; //$NON-NLS-1$
private static final String EQUINOX_HTTP_REGISTRY = "org.eclipse.equinox.http.registry"; //$NON-NLS-1$
public static BundleContext bundleContext;
private static ServiceTracker<HttpService, HttpService> httpServiceTracker;
private static ServiceTracker<PackageAdmin, PackageAdmin> packageAdminTracker;
private static boolean initialized = false;
private static String serverHost = null;
private static int serverPort = 0;
public static BundleContext getContext() {
return bundleContext;
}
public static String getServerLocation() {
if (!initialized) {
try {
initialize();
//make sure the http registry is started
ensureBundleStarted(EQUINOX_HTTP_JETTY);
ensureBundleStarted(EQUINOX_HTTP_REGISTRY);
//get the webide bundle started via lazy activation.
org.eclipse.orion.server.authentication.basic.Activator.getDefault();
Activator.getDefault();
ConfiguratorActivator.getDefault();
} catch (Exception e) {
e.printStackTrace();
return null;
}
}
return "http://" + serverHost + ':' + String.valueOf(serverPort);
}
private static void initialize() throws Exception {
ServiceReference<HttpService> reference = httpServiceTracker.getServiceReference();
String port = (String) reference.getProperty("http.port"); //$NON-NLS-1$
serverHost = "localhost"; //$NON-NLS-1$
serverPort = Integer.parseInt(port);
initialized = true;
}
public void start(BundleContext context) throws Exception {
bundleContext = context;
httpServiceTracker = new ServiceTracker<HttpService, HttpService>(context, HttpService.class, null);
httpServiceTracker.open();
packageAdminTracker = new ServiceTracker<PackageAdmin, PackageAdmin>(context, PackageAdmin.class.getName(), null);
packageAdminTracker.open();
}
public void stop(BundleContext context) throws Exception {
if (httpServiceTracker != null)
httpServiceTracker.close();
if (packageAdminTracker != null)
packageAdminTracker.close();
httpServiceTracker = null;
packageAdminTracker = null;
bundleContext = null;
}
static private Bundle getBundle(String symbolicName) {
PackageAdmin packageAdmin = packageAdminTracker.getService();
if (packageAdmin == null)
return null;
Bundle[] bundles = packageAdmin.getBundles(symbolicName, null);
if (bundles == null)
return null;
// Return the first bundle that is not installed or uninstalled
for (int i = 0; i < bundles.length; i++) {
if ((bundles[i].getState() & (Bundle.INSTALLED | Bundle.UNINSTALLED)) == 0) {
return bundles[i];
}
}
return null;
}
static private void ensureBundleStarted(String name) throws BundleException {
Bundle bundle = getBundle(name);
if (bundle != null) {
if (bundle.getState() == Bundle.RESOLVED || bundle.getState() == Bundle.STARTING) {
bundle.start(Bundle.START_TRANSIENT);
}
}
}
}
| [
"yuzhongxing88@gmail.com"
] | yuzhongxing88@gmail.com |
837fac03045a8b41619ce1447b8c76a5e0c13ded | cfcb29e763bb045eb0b257df472428e4e66c7bda | /src/main/java/com/revature/models/Role.java | 41ff6ff88b06f36af20ddb4337641bba1936af52 | [] | no_license | ChrisCastrillon/Project_0_Christopher_Castrillon | 24ce96c5717ce0e4949fad1410f048c78eca8fa2 | 62d59297c6a3034ee2e3f384653348788b35e768 | refs/heads/master | 2022-12-07T11:23:39.292277 | 2020-08-26T07:34:18 | 2020-08-26T07:34:18 | 290,426,060 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 76 | java | package com.revature.models;
public enum Role {
Admin, Employee, Client
}
| [
"christophercastrillonart@gmail.com"
] | christophercastrillonart@gmail.com |
f55850c3976b7e403ea9c82c887d3059ba3a5d4a | 007d9f21b65492268432415b018cb9ad8c1bd3c2 | /ecole-franco-arabe/src/main/java/org/dotintell/ecole/dao/ClasseRepository.java | 7bffd92fc15f34bf0b5904cfdd6a42d348732668 | [] | no_license | lykoflexii/rf_school | 21e63041e29817ab2bb1d028bde42bd02ed552de | 41f8ba7755afec72384f5ff97143ec987adb2cf6 | refs/heads/master | 2020-03-27T17:47:28.716344 | 2018-09-04T16:18:18 | 2018-09-04T16:18:18 | 146,874,449 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 335 | java | package org.dotintell.ecole.dao;
import org.dotintell.ecole.entities.Classe;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.rest.core.annotation.RepositoryRestResource;
@RepositoryRestResource(path="/classes")
public interface ClasseRepository extends JpaRepository<Classe, String>{
}
| [
"kote.proformating@gmail.com"
] | kote.proformating@gmail.com |
c5a305dfac381358f3f0a059c239dcc07d1e7985 | 6a77192d030ee4619f16e64cbd75f9e56b444656 | /app/src/main/java/com/haoyd/learn/common/MyApplication.java | 927bbcf20a302ba97db3a8920d0ed55f32a92808 | [] | no_license | haoyd/learn_android | 881e9955793c88c168826772593f444f213f9563 | 2f4947447de2bf134460a82b83b15a5049ec7131 | refs/heads/master | 2022-12-13T02:07:44.831797 | 2020-09-16T12:31:23 | 2020-09-16T12:31:23 | 286,675,868 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 228 | java | package com.haoyd.learn.common;
import android.app.Application;
public class MyApplication extends Application {
@Override
public void onCreate() {
super.onCreate();
ToastUtil.context = this;
}
}
| [
"277079581@qq.com"
] | 277079581@qq.com |
780f8c893f840acae64d48a6129ff72a64c20673 | c71858f0694ec5cb26088e609674e16369a30046 | /app/src/main/java/com/mclauncher/peonlinebox/mcmultiplayer/HomeActivity.java | 56db1c1634fd39f1035354071bc31be04e75ed25 | [] | no_license | Moqu/McpeHOl | ef4681af23aae25f0b2b4fee5de9eb8a837dfb25 | ae0bf26bb39347893fbef4100e677eaeb5054dc9 | refs/heads/master | 2021-01-10T16:22:31.123989 | 2015-06-03T07:48:17 | 2015-06-03T07:48:17 | 36,127,930 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 14,039 | java | package com.mclauncher.peonlinebox.mcmultiplayer;
import android.net.Uri;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentPagerAdapter;
import android.support.v4.app.FragmentTransaction;
import android.support.v4.view.ViewPager;
import android.support.v7.app.ActionBar;
import android.support.v7.app.ActionBarActivity;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.FrameLayout;
import android.widget.LinearLayout;
import android.widget.TextView;
import com.mclauncher.peonlinebox.mcmultiplayer.fragment.HomeFragment;
import com.mclauncher.peonlinebox.mcmultiplayer.fragment.PersonalFragment;
import com.viewpagerindicator.TabPageIndicator;
import java.util.Locale;
public class HomeActivity extends ActionBarActivity implements ActionBar.TabListener,OnFragmentInteractionListener{
/**
* The {@link android.support.v4.view.PagerAdapter} that will provide
* fragments for each of the sections. We use a
* {@link FragmentPagerAdapter} derivative, which will keep every
* loaded fragment in memory. If this becomes too memory intensive, it
* may be best to switch to a
* {@link android.support.v4.app.FragmentStatePagerAdapter}.
*/
SectionsPagerAdapter mSectionsPagerAdapter;
/**
* The {@link ViewPager} that will host the section contents.
*/
public static ViewPager mViewPager;
public static FrameLayout fragment_personal_center,fragment_online_games;
// public static CheckBox main_tab_online_games,main_tab_tools,main_tab_personal_center;
public static ActionBar actionBar;
public static TabPageIndicator tabs;
public static LinearLayout linear_home,linear_personal_center;
public static TextView tv_home,tv_person;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_home);
actionBar = getSupportActionBar();
//actionBar.setNavigationMode(ActionBar.NAVIGATION_MODE_TABS);
// Create the adapter that will return a fragment for each of the three
// primary sections of the activity.
mSectionsPagerAdapter = new SectionsPagerAdapter(getSupportFragmentManager());
// Set up the ViewPager with the sections adapter.
mViewPager = (ViewPager) findViewById(R.id.view_pager);
mViewPager.setAdapter(mSectionsPagerAdapter);
mViewPager.setVisibility(View.GONE);
tabs = (TabPageIndicator) findViewById(R.id.tabs);
tabs.setViewPager(mViewPager);
tabs.setVisibility(View.GONE);
linear_home = (LinearLayout) findViewById(R.id.linear_home);
linear_personal_center = (LinearLayout) findViewById(R.id.linear_personal_center);
tv_home = (TextView) findViewById(R.id.tv_home);
tv_person = (TextView) findViewById(R.id.tv_person);
tv_home.setTextColor(0xffffffff);
tv_person.setTextColor(0xffababab);
linear_home.setBackgroundResource(R.drawable.tab_home_linear_pressed);
linear_personal_center.setBackgroundResource(R.drawable.tab_home_linear_normal);
fragment_personal_center = (FrameLayout) findViewById(R.id.fragment_personal_center);
fragment_personal_center.setVisibility(View.GONE);
fragment_online_games= (FrameLayout) findViewById(R.id.fragment_online_games);
fragment_online_games.setVisibility(View.VISIBLE);
// main_tab_online_games = (CheckBox) findViewById(R.id.main_tab_online_games);
//// main_tab_tools = (CheckBox) findViewById(R.id.main_tab_tools);
// main_tab_personal_center = (CheckBox) findViewById(R.id.main_tab_personal_center);
// main_tab_online_games.setChecked(true);
linear_home.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
fragment_online_games.setVisibility(View.VISIBLE);
fragment_personal_center.setVisibility(View.GONE);
mViewPager.setVisibility(View.GONE);
linear_home.setBackgroundResource(R.drawable.tab_home_linear_pressed);
linear_personal_center.setBackgroundResource(R.drawable.tab_home_linear_normal);
tabs.setVisibility(View.GONE);
tv_home.setTextColor(0xffffffff);
tv_person.setTextColor(0xffababab);
HomeFragment homeFragment = (HomeFragment)getSupportFragmentManager().findFragmentById(R.id.fragment_online_games);
if (homeFragment == null){
homeFragment = new HomeFragment();
FragmentTransaction ft = getSupportFragmentManager().beginTransaction();
ft.setTransition(FragmentTransaction.TRANSIT_FRAGMENT_FADE);
ft.replace(R.id.fragment_online_games, homeFragment);
ft.commit();
}
}
});
linear_personal_center.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
fragment_online_games.setVisibility(View.GONE);
fragment_personal_center.setVisibility(View.VISIBLE);
mViewPager.setVisibility(View.GONE);
tabs.setVisibility(View.GONE);
tv_home.setTextColor(0xffababab);
tv_person.setTextColor(0xffffffff);
linear_home.setBackgroundResource(R.drawable.tab_home_linear_normal);
linear_personal_center.setBackgroundResource(R.drawable.tab_home_linear_pressed);
PersonalFragment personalFragment = (PersonalFragment)getSupportFragmentManager().findFragmentById(R.id.fragment_personal_center);
if (personalFragment == null){
personalFragment = new PersonalFragment();
FragmentTransaction ft = getSupportFragmentManager().beginTransaction();
ft.setTransition(FragmentTransaction.TRANSIT_FRAGMENT_FADE);
ft.replace(R.id.fragment_personal_center, personalFragment);
ft.commit();
}
}
});
// main_tab_online_games.setOnClickListener(new View.OnClickListener() {
// @Override
// public void onClick(View v) {
// fragment_online_games.setVisibility(View.VISIBLE);
// fragment_personal_center.setVisibility(View.GONE);
// mViewPager.setVisibility(View.GONE);
//
// main_tab_online_games.setChecked(true);
//// main_tab_tools.setChecked(false);
// main_tab_personal_center.setChecked(false);
// tabs.setVisibility(View.GONE);
//
// HomeFragment homeFragment = (HomeFragment)getSupportFragmentManager().findFragmentById(R.id.fragment_online_games);
// if (homeFragment == null){
// homeFragment = new HomeFragment();
// FragmentTransaction ft = getSupportFragmentManager().beginTransaction();
// ft.setTransition(FragmentTransaction.TRANSIT_FRAGMENT_FADE);
// ft.replace(R.id.fragment_online_games, homeFragment);
// ft.commit();
// }
//
// }
// });
//
//// main_tab_tools.setOnClickListener(new View.OnClickListener() {
//// @Override
//// public void onClick(View v) {
//// fragment_online_games.setVisibility(View.GONE);
//// fragment_personal_center.setVisibility(View.GONE);
//// mViewPager.setVisibility(View.VISIBLE);
//// main_tab_online_games.setChecked(false);
//// main_tab_tools.setChecked(true);
//// main_tab_personal_center.setChecked(false);
//// tabs.setVisibility(View.VISIBLE);
//// }
//// });
//
// main_tab_personal_center.setOnClickListener(new View.OnClickListener() {
// @Override
// public void onClick(View v) {
// fragment_online_games.setVisibility(View.GONE);
// fragment_personal_center.setVisibility(View.VISIBLE);
// mViewPager.setVisibility(View.GONE);
// main_tab_online_games.setChecked(false);
//// main_tab_tools.setChecked(false);
// main_tab_personal_center.setChecked(true);
// tabs.setVisibility(View.GONE);
//
// PersonalFragment personalFragment = (PersonalFragment)getSupportFragmentManager().findFragmentById(R.id.fragment_personal_center);
// if (personalFragment == null){
// personalFragment = new PersonalFragment();
// FragmentTransaction ft = getSupportFragmentManager().beginTransaction();
// ft.setTransition(FragmentTransaction.TRANSIT_FRAGMENT_FADE);
// ft.replace(R.id.fragment_personal_center, personalFragment);
// ft.commit();
// }
// }
// });
HomeFragment homeFragment = (HomeFragment)getSupportFragmentManager().findFragmentById(R.id.fragment_online_games);
if (homeFragment == null){
homeFragment = new HomeFragment();
FragmentTransaction ft = getSupportFragmentManager().beginTransaction();
ft.setTransition(FragmentTransaction.TRANSIT_FRAGMENT_FADE);
ft.replace(R.id.fragment_online_games, homeFragment);
ft.commit();
}
mViewPager.setOnPageChangeListener(new ViewPager.SimpleOnPageChangeListener() {
@Override
public void onPageSelected(int position) {
//actionBar.setSelectedNavigationItem(position);
tabs.setCurrentItem(position);
//MobclickAgent.onEvent(mContext, "home_fragment_"+String.valueOf(position));
}
});
}
// @Override
// public boolean onCreateOptionsMenu(Menu menu) {
// // Inflate the menu; this adds items to the action bar if it is present.
// getMenuInflater().inflate(R.menu.menu_home, menu);
// return true;
// }
//
// @Override
// public boolean onOptionsItemSelected(MenuItem item) {
// // Handle action bar item clicks here. The action bar will
// // automatically handle clicks on the Home/Up button, so long
// // as you specify a parent activity in AndroidManifest.xml.
// int id = item.getItemId();
//
// //noinspection SimplifiableIfStatement
// switch (id) {
// case android.R.id.home:
// finish();
// break;
// case R.id.start:
// Toast.makeText(this,"开始游戏",Toast.LENGTH_SHORT).show();
// break;
// }
//
// return super.onOptionsItemSelected(item);
// }
@Override
public void onFragmentInteraction(Uri uri) {
}
@Override
public void onFragmentInteraction(String id) {
}
@Override
public void onTabSelected(ActionBar.Tab tab, FragmentTransaction ft) {
mViewPager.setCurrentItem(tab.getPosition());
}
@Override
public void onTabUnselected(ActionBar.Tab tab, FragmentTransaction ft) {
}
@Override
public void onTabReselected(ActionBar.Tab tab, FragmentTransaction ft) {
}
/**
* A {@link FragmentPagerAdapter} that returns a fragment corresponding to
* one of the sections/tabs/pages.
*/
public class SectionsPagerAdapter extends FragmentPagerAdapter {
public SectionsPagerAdapter(FragmentManager fm) {
super(fm);
}
@Override
public Fragment getItem(int position) {
// getItem is called to instantiate the fragment for the given page.
// Return a PlaceholderFragment (defined as a static inner class below).
return PlaceholderFragment.newInstance(position + 1);
}
@Override
public int getCount() {
// Show 3 total pages.
return 4;
}
@Override
public CharSequence getPageTitle(int position) {
Locale l = Locale.getDefault();
switch (position) {
case 0:
return getString(R.string.title_recommend).toUpperCase(l);
case 1:
return getString(R.string.title_challenge).toUpperCase(l);
case 2:
return getString(R.string.title_survival).toUpperCase(l);
case 3:
return getString(R.string.title_minigames).toUpperCase(l);
}
return null;
}
}
/**
* A placeholder fragment containing a simple view.
*/
public static class PlaceholderFragment extends Fragment {
/**
* The fragment argument representing the section number for this
* fragment.
*/
private static final String ARG_SECTION_NUMBER = "section_number";
/**
* Returns a new instance of this fragment for the given section
* number.
*/
public static PlaceholderFragment newInstance(int sectionNumber) {
PlaceholderFragment fragment = new PlaceholderFragment();
Bundle args = new Bundle();
args.putInt(ARG_SECTION_NUMBER, sectionNumber);
fragment.setArguments(args);
return fragment;
}
public PlaceholderFragment() {
}
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
View rootView = inflater.inflate(R.layout.fragment_main_home, container, false);
return rootView;
}
}
}
| [
"lwy1314li@163.com"
] | lwy1314li@163.com |
4ca9f1a5c4457d18022512b4cdeed3cd64bfc7d1 | d041b708f0e9cd78d913c8c216aa0a09945fa01c | /app/src/main/java/com/vomozsystems/apps/android/vomoznet/service/CreateCreditCardResponse.java | 2c13737008db91864584d472134cd4e2bd393851 | [] | no_license | vomozsystems/VomozNET-Android | 5fbca02f47a5d985e3e842f0cf3bdc87bc5de4f5 | 91f45a64852de950a26278440fe943a00efc8b9a | refs/heads/master | 2020-03-13T14:02:43.859707 | 2018-05-12T10:47:16 | 2018-05-12T10:47:16 | 131,150,783 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 449 | java | package com.vomozsystems.apps.android.vomoznet.service;
import com.vomozsystems.apps.android.vomoznet.entity.CreditCard;
/**
* Created by leksrej on 8/7/16.
*/
public class CreateCreditCardResponse extends BaseServiceResponse {
CreditCard responseData;
public CreditCard getResponseData() {
return responseData;
}
public void setResponseData(CreditCard responseData) {
this.responseData = responseData;
}
}
| [
"lekan.reju@vomozsystems.com"
] | lekan.reju@vomozsystems.com |
aea3fdfdfaccb4f14893c17b1f5fc9eb8837ecfb | 417412ef6fac0846d35db6707c2c086141eeae1d | /app/src/main/java/br/com/myowncompany/cadastrocontatos/CadastroHelper.java | 30fac6b8e284993011899c9aa9d1abf8c56d1380 | [] | no_license | brunozampaglione/CadastroContatos | 30a110f74f7fb21fb2a94d05339b010d1afe8a81 | a3621271759447e35224c7441236e07929bda024 | refs/heads/master | 2021-01-01T19:39:38.280640 | 2015-04-18T01:49:24 | 2015-04-18T01:49:24 | 33,897,627 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,731 | java | package br.com.myowncompany.cadastrocontatos;
import android.app.Activity;
import android.net.Uri;
import android.widget.EditText;
import android.widget.ImageView;
import android.widget.RatingBar;
import android.widget.Toast;
/**
* Created by android5193 on 08/04/15.
*/
public class CadastroHelper {
private Contato contato;
private EditText contatoNome;
private EditText contatoEndereco;
private EditText contatoTelefone;
private EditText contatoSite;
private RatingBar contatoNota;
private ImageView contatoFoto;
private activity_cadastro Act;
public CadastroHelper(activity_cadastro activity){
this.contato = new Contato();
this.contatoNome = (EditText) activity.findViewById(R.id.contatoNome);
this.contatoEndereco = (EditText) activity.findViewById(R.id.contatoEndereco);
this.contatoTelefone = (EditText) activity.findViewById(R.id.contatoTelefone);
this.contatoSite = (EditText) activity.findViewById(R.id.contatoSite);
this.contatoNota = (RatingBar) activity.findViewById(R.id.contatoNota);
this.contatoFoto = (ImageView) activity.findViewById(R.id.ViewFoto);
Act = activity;
}
public Contato pegaContato(){
contato.setNome(contatoNome.getText().toString());
contato.setEndereco(contatoEndereco.getText().toString());
contato.setTelefone(contatoTelefone.getText().toString());
contato.setSite(contatoSite.getText().toString());
contato.setNota(Double.valueOf(contatoNota.getProgress()));
contato.setFoto((String)contatoFoto.getTag());
return contato;
}
public void setaContato(Contato contato){
this.contatoNome.setText(contato.getNome());
this.contatoEndereco.setText(contato.getEndereco());
this.contatoTelefone.setText(contato.getTelefone());
this.contatoSite.setText(contato.getSite());
this.contatoNota.setProgress(contato.getNota().intValue());
if(contato.getFoto()!=null) {
this.contatoFoto.setImageURI(Uri.parse(contato.getFoto()));
this.contatoFoto.setTag(contato.getFoto());
}
}
public void limpaContato(){
contatoNome.setText("");
contatoEndereco.setText("");
contatoTelefone.setText("");
contatoSite.setText("");
contatoNota.setProgress(0);
contatoFoto.setImageURI(null);
}
public boolean temNome(){
return !contato.getNome().isEmpty();
}
public void mostraMsg(activity_cadastro activity, String errMsg){
Toast.makeText(Act, errMsg, Toast.LENGTH_SHORT).show();
}
public void setError(String errMsg){
contatoNome.setError(errMsg);
}
}
| [
"android5193@bol.com.br"
] | android5193@bol.com.br |
b71b006f7695325e7014424ca1418236ff6fbb7b | 876b6d2e2d0b42ecde9662b05ecbc8a2e12ac68a | /src/main/java/dev/sanggi/codingtest/programmers/level1/짝수와홀수.java | 55db3d6c2b3cbe8d4f823c0e62271ccf9ace445a | [] | no_license | SonSangGi/java-study | 45ee84a1beb4e055687c05afa87ee0f4d3977163 | 65aa9c770d7242833649578df24b940c20e8aff7 | refs/heads/master | 2021-01-04T09:43:57.355735 | 2020-05-20T02:17:12 | 2020-05-20T02:17:12 | 240,494,469 | 2 | 1 | null | null | null | null | UTF-8 | Java | false | false | 560 | java | package dev.sanggi.codingtest.programmers.level1;
public class 짝수와홀수 {
public static void main(String[] args) {
System.out.println(solution(3));
}
/**
* 문제 설명
* 정수 num이 짝수일 경우 Even을 반환하고 홀수인 경우 Odd를 반환하는 함수, solution을 완성해주세요.
*
* 제한 조건
* num은 int 범위의 정수입니다.
* 0은 짝수입니다.
*
* 입출력 예
* num return
* 3 Odd
* 4 Even
*/
public static String solution(int num) {
return num % 2 == 0 ? "Even" : "Odd";
}
}
| [
"ssg3799@gmail.com"
] | ssg3799@gmail.com |
dbf892a5f738fe7a88c48b87a3d7bd52adf157d2 | 35f55aad13c696fad7ec37935004f03da55abc73 | /src/main/java/common/strategy/GetWritingStrategy.java | d81488b749fc9f1822d4d690acfc1cca92be2514 | [] | no_license | Etherealss/WanderFour | 371cd27574da7a51d2c28f7c0e475202dc22fc55 | bd62b3eb71cf4781e09854f48928904e3a8aa531 | refs/heads/master | 2023-06-25T17:54:13.785568 | 2021-05-06T11:27:04 | 2021-05-06T11:27:04 | 297,966,153 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 666 | java | package common.strategy;
import java.sql.SQLException;
import java.util.List;
/**
* @author 寒洲
* @description 获取作品(Writing)的策略
* @date 2020/10/27
*/
public interface GetWritingStrategy<T> {
/**
* 按时间获取作品
* @param partition
* @param order
* @param start
* @param rows
* @return
* @throws SQLException
*/
List<T> getWritingList(int partition, String order, Long start, int rows);
/**
* 按时间获取作品
* @param partition
* @param order
* @param start
* @param rows
* @return
* @throws SQLException
*/
List<T> getSimpleWritingList(int partition, String order, Long start, int rows);
}
| [
"1831669777@qq.com"
] | 1831669777@qq.com |
93d471b7ffbabea27d170f390f8aa8242f0a53ff | 7c79d8d7485b4b72287994a4391b00194b07c37e | /src/main/java/pl/pollub/cs/pentagoncafe/flare/controller/CsrfTokenController.java | 5fd150a4444ffb43f3ccb3d5d18eb21e663834ca | [] | no_license | PollubCafe/Flare-event-calendar | 0dde8c687c6a7b3eda3a11b6f71768918ae7ffe0 | c8eb7aebd49e4cee64b19b98bde9bdf16f81872c | refs/heads/master | 2021-05-07T05:24:46.815066 | 2018-04-19T19:03:58 | 2018-04-19T19:03:58 | 111,544,395 | 4 | 2 | null | 2018-04-19T19:03:49 | 2017-11-21T12:10:00 | Java | UTF-8 | Java | false | false | 428 | java | package pl.pollub.cs.pentagoncafe.flare.controller;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
//this controller generate automatically new csrf token for session by sending empty html page
@Controller
public class CsrfTokenController {
@GetMapping(value = "/api/csrf/index.html")
public String secureBehindCsrfAttack(){
return "csrf";
}
}
| [
"jaroslaw.bielec@pollub.edu.pl"
] | jaroslaw.bielec@pollub.edu.pl |
a5cc5f7ef5729f1111f85015d288aea1816aad0c | 992f6540a7706aa8b1679a71be13ddddb514dc77 | /src/main/java/com/lizeteng/leetcode/easy/_349/Solution.java | 450793ff7dc1f2b953ffe3dee576f69a2b3425aa | [] | no_license | lizeteng/leetcode-old | f763c726ef3a93ddd05fdb646f21d46b20435b78 | 86177204d3d80f78fc5da0280a8b9d0d8fcd4671 | refs/heads/master | 2022-11-08T14:20:55.557991 | 2018-12-08T10:29:35 | 2018-12-08T10:29:35 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,356 | java | package com.lizeteng.leetcode.easy._349;
import java.util.*;
/**
* 给定两个数组,编写一个函数来计算它们的交集。
*
* 示例1:
* 输入:nums1 = [1, 2, 2, 1],nums2 = [2, 2]
* 输出:[2]
*
* 示例2:
* 输入:nums1 = [4, 9, 5], nums2 = [9, 4, 9, 8, 4]
* 输出:[9, 4]
*
* 说明:
* 1、输出结果中的每个元素一定是唯一的。
* 2、不考虑输出结果的顺序。
*
* @author lizeteng
* @date 2018/11/19
*/
public class Solution {
public int[] intersection(int[] nums1, int[] nums2) {
Set<Integer> set = new HashSet<>(nums1.length);
for (int i = 0; i < nums1.length; i++) {
set.add(nums1[i]);
}
List<Integer> tempList = new ArrayList<>(set.size());
for (int i = 0; i < nums2.length; i++) {
if (set.contains(nums2[i])) {
set.remove(nums2[i]);
tempList.add(nums2[i]);
}
}
int[] result = new int[tempList.size()];
for (int i = 0; i < result.length; i++) {
result[i] = tempList.get(i);
}
return result;
}
public static void main(String[] args) {
System.out.println(
Arrays.toString(
new Solution().intersection(new int[] {1, 2, 2, 1}, new int[] {2, 2})));
}
}
| [
"woshilizeteng@gmail.com"
] | woshilizeteng@gmail.com |
172e41c8e15af055a058b6be9f389ee203fd8abe | 947a662d5a2eeab8978a2cec8a82144e140a7461 | /src/test/java/stepDefinitions/GlobalStepdefs.java | 60edf87d99434054885599e2e67bb0214c4e0e28 | [] | no_license | myappsgit/Huddil-consumer | 441e861a1014357bafc69a7d51bb75ee94845eab | 8b3069048fb3bb3bfc7771e92cb2cc2cd4fcbadd | refs/heads/master | 2020-03-19T09:24:34.022260 | 2018-06-06T07:39:50 | 2018-06-06T07:39:50 | 136,285,970 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 26,903 | java | package stepDefinitions;
import static stepDefinitions.Hooks.driver;
import java.util.List;
import org.json.simple.JSONObject;
import org.junit.Assert;
import org.openqa.selenium.By;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.support.ui.ExpectedConditions;
import org.openqa.selenium.support.ui.WebDriverWait;
import constants.GlobalConstants;
import wrapper.SeleniumFunctions;
import cucumber.api.DataTable;
import cucumber.api.java.en.And;
import cucumber.api.java.en.Given;
import cucumber.api.java.en.Then;
import cucumber.api.java.en.When;
import stepDefinitions.Hooks;
import support.Navigation;
import support.Page;
import utils.SetUpFile;
import utils.UtilFunctions;
public class GlobalStepdefs {
public String className = getClass().getSimpleName();
public static String curPageName = "";
@Then("^I click the \"(.*?)\" (?:image|tab|element|icon)(?: in the \"(.*?)\" pane)?( if it exists)?$")
public void clickMiscElement(String elementName, String paneName, String exists) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
elementName = elementName.replace(" ", "");
if (exists == null) {
UtilFunctions.log("Pagename: " + curPageName);
Assert.assertTrue("Misc Element: " + elementName + " not present", Page.clickMiscElement(Hooks.getDriver(), curPageName, elementName, paneName, exists));
} else {
try {
Page.clickMiscElement(Hooks.getDriver(), curPageName, elementName, paneName, exists);
} catch (Exception e) {
e.printStackTrace();
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
}
}
@Given("^I am on the \"(.*?)\" page$")
public void selectPage(String pageName) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
pageName = pageName.replace(" ", "");
curPageName = pageName;
Navigation.setPage(pageName);
boolean getValue = Navigation.navigationPageExists(Hooks.getDriver(), pageName);
Assert.assertTrue("Page element: " + pageName + " not found", getValue);
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
@Given("^I select the \"(.*?)\" subpage$")
public void selectSubPage(String subPage) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
subPage = subPage.replace(" ", "");
boolean getValue = Navigation.selectNavigationPage(Hooks.getDriver(), curPageName, subPage);
Assert.assertTrue("Sub page element: " + subPage + " not found", getValue);
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
@Given("^I launch the \"(.*?)\" web application$")
public void launchApplication(String appName) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
SetUpFile setUp = new SetUpFile();
setUp.launchApplication();
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
@And("^I click the \"(.*?)\" button( if it exists)?$")
public void clickButton(String buttonName, String exists) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
if (exists == null) {
Assert.assertTrue("Button: " + buttonName + " does not exists", Page.clickButton(Hooks.getDriver(), curPageName, buttonName));
} else {
try {
Page.clickButton(Hooks.getDriver(), curPageName, buttonName);
} catch (Exception e) {
e.printStackTrace();
UtilFunctions.log("Button: " + buttonName + " does not exists. Exception: " + e.getMessage());
}
}
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
@Then("^(?:the|The)? following (field(?:s)?|dashboard options) should(?: be)? (enabled|disabled|display|not display)(?: in the \"(.*?)\" pane)?$")
public void checkDataTableValuesInPane(String state, String type, String paneName, DataTable dataTable) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
// List<Map<String, String>> dataList = dataTable.asMaps(String.class, String.class);
// for (Map data : dataList) {
// String fieldType = (String) data.get("Type");
// String fieldName = ((String) data.get("Name")).replace(" ", "");
if (type.equals("fields") || type.equals("field")) {
if (state.equals("not display")) {
Assert.assertNotNull("Field is not present.", Page.checkDataTableInPane(Hooks.getDriver(), curPageName, state, dataTable));
} else {
Assert.assertEquals("", Page.checkDataTableInPane(Hooks.getDriver(), curPageName, state, dataTable));
}
} else if (type.equals("dashboard options")) {
List<String> dataList = dataTable.asList(String.class);
for (String pageName : dataList) {
if (state.equals("not display")) {
UtilFunctions.log("SubPage name to be checked: " + pageName);
Assert.assertFalse("SubPage: " + pageName + " is not displayed.", Navigation.navigationPageExists(Hooks.getDriver(), pageName));
} else {
UtilFunctions.log("SubPage name to be checked: " + pageName);
Assert.assertTrue("", Navigation.navigationPageExists(Hooks.getDriver(), pageName));
}
}
}
// }
}
@Then("^the following subpages should load$")
public void checkSubPageLoad(DataTable dataTable) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
List<String> dataList = dataTable.asList(String.class);
for (String subPageName : dataList) {
UtilFunctions.log("SubPage name to be checked: " + subPageName);
Assert.assertTrue("SubPage: " + subPageName + " does not exist.", Navigation.navigationSubPageExists(Hooks.getDriver(), subPageName));
}
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
//Enter Value in Text Box
@When("^I enter \"(.*?)\" in the \"(.*?)\" field$")
public void enterInTheField(String value, String fieldName) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
Assert.assertTrue("Text Box: " + fieldName + " Object Not found", Page.setTextBox(Hooks.getDriver(), curPageName, value, fieldName));
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
//step definition to set multiple field values
@Given("^I set the following values$")
public void setFieldValues(DataTable dataTable) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
// if (paneName == null)
Assert.assertEquals("", Page.setMultipleFieldValues(Hooks.getDriver(), dataTable, "", curPageName));
// else {
// Assert.assertEquals("", Page.setMultipleFieldValues(Hooks.getDriver(), dataTable, "", curPageName));
// }
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
// //step definition to set multiple field values
// @Given("^I set the following values in the \"(.*?)\" pane$")
// public void setFieldValues(String paneName, DataTable dataTable) throws Throwable {
// UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
// }.getClass().getEnclosingMethod().getName() + " : Start");
//
// if (paneName == null)
// Assert.assertEquals("", Page.setMultipleFieldValues(Hooks.getDriver(), dataTable,""));
// else {
// Assert.assertEquals("", Page.setMultipleFieldValues(Hooks.getDriver(), dataTable, paneName));
// }
// UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
// }.getClass().getEnclosingMethod().getName() + " : Complete");
// }
//step definition to check if elements exists
@Given("^the following elements should be displayed$")
public void checkElementsInPage(DataTable dataTable) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
Assert.assertEquals("", Page.checkElementsExists(Hooks.getDriver(), dataTable, ""));
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
@Given("^the element \"(.*?)\" should be displayed$")
public void checkIfElementIsDisplayed(String elt) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
JSONObject fileObj = UtilFunctions.getJSONFileObjBasedOnPageName(curPageName);
String[] elementType = UtilFunctions.getElementStringAndType(fileObj, "MISC_ELEMENTS." + elt);
String fieldPath = elementType[0];
String fieldMethod = elementType[1];
UtilFunctions.log("fieldPath: " + fieldPath + "\nfieldMethod: " + fieldMethod);
SeleniumFunctions.explicitWait(driver, GlobalConstants.FIFTEEN, fieldPath + ";" + fieldMethod);
WebElement eleObj = SeleniumFunctions.findElement(driver, SeleniumFunctions.setByValues(fieldPath + ";" + fieldMethod));
if (eleObj != null) {
eleObj.isDisplayed();
}
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
@Then("^the following text should appear in the \"(.*?)\" pane$")
public void checkForMultipleTextEntries(String paneName, DataTable dataTable) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
List<String> textList = dataTable.asList(String.class);
for (String text : textList) {
// try{
Assert.assertTrue("Text: " + text + " not found", Page.textExists(Hooks.driver, text, false));
// }
// catch(Exception e){
// System.out.println();
// UtilFunctions.log("Text:"+text+"not found");
// }
}
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
@When("^I click \"(.*?)\" in the confirmation box( if it exists)?$")
public void selectAlert(String alertName, String exists) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
if (exists == null) {
Assert.assertTrue("Alert: " + alertName + " not visible", Page.handleAlert(Hooks.getDriver(), alertName));
} else {
try {
Page.handleAlert(Hooks.getDriver(), alertName);
} catch (Exception e) {
e.printStackTrace();
UtilFunctions.log("Alert: " + alertName + " not visible Exception: " + e.getMessage());
}
}
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
@Then("^There should( not)? be an alert(?: with the text \"(.*)\")?$")
public void checkAlert(String condition, String alertText) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
boolean alert = SeleniumFunctions.checkAlertPresent(Hooks.getDriver());
if (condition == null) {
Assert.assertTrue("Alert is not displayed", alert);
if (alertText != null) {
Assert.assertTrue("Alert text: " + alertText + " is not displayed", SeleniumFunctions.getAlertText(Hooks.getDriver()).contains(alertText));
}
} else {
Assert.assertFalse("Alert displayed", alert);
}
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
@And("^I wait \"(.*)\" seconds$")
public void waitForSpecifiedTime(int seconds) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
int milliSec = (seconds * 1000);
Thread.sleep(milliSec);
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
@When("^I (un)?check the \"(.*?)\" checkbox(?: in the \"(.*?)\" pane)?( if it exists)?$")
public void checkCheckBox(String checkType, String checkbox, String paneName, String exists) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
UtilFunctions.log("CheckBoxName: " + checkbox);
if (checkType == null) {
checkType = "check";
} else {
checkType = "uncheck";
}
if (exists == null) {
Assert.assertTrue("CheckBox: " + checkbox + " didn't set properly.", Page.setCheckBox(Hooks.getDriver(), curPageName, checkbox, checkType));
// Page.setCheckBox(Hooks.getDriver(), curPageName, checkbox, checkType);
} else {
try {
// Assert.assertTrue("CheckBox: " + checkbox + " didn't set properly.", Page.setCheckBox(Hooks.getDriver(), curPageName, checkbox, checkType));
Page.setCheckBox(Hooks.getDriver(), curPageName, checkbox, checkType);
} catch (Exception e) {
e.printStackTrace();
UtilFunctions.log("checkBox: " + checkbox + " didn't set properly. " + e.getMessage());
}
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
}
@Then("^I click the \"(.*?)\" (?:image|tab|element) in the \"(.*?)\" row?( if it exists)?$")
public void clickRowElement(String elementName, String rowText, String exists) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
boolean flag;
elementName = elementName.replace(" ", "");
JSONObject fileObj = UtilFunctions.getJSONFileObjBasedOnPageName(curPageName);
String[] elementType = UtilFunctions.getElementStringAndType(fileObj, "MISC_ELEMENTS." + elementName);
String path = elementType[0];
path = "//td[text()='rowText']//following::" + path;
String method = elementType[1];
SeleniumFunctions.explicitWait(Hooks.getDriver(), GlobalConstants.TEN, path + ";" + method);
WebElement eleObj = SeleniumFunctions.findElement(Hooks.getDriver(), SeleniumFunctions.setByValues(path + ";" + method));
if (exists == null) {
if (eleObj == null) {
UtilFunctions.log("Element: '" + elementName + "' does not exist. Returning false.");
flag = false;
} else {
eleObj.click();
try {
Thread.sleep(1000);
} catch (InterruptedException e) {
e.printStackTrace();
}
UtilFunctions.log("Element: '" + elementName + "' exist and clicked. Returning true.");
flag = true;
}
Assert.assertTrue(flag);
} else {
try {
eleObj.click();
} catch (Exception e) {
e.printStackTrace();
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
}
}
@When("^I click the \"(.*?)\" link( if it exists)?$")
public void clickLink(String linkName, String exists) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
if (exists == null)
Assert.assertTrue("Link: " + linkName + " not found", Page.clickLinkText(Hooks.getDriver(), linkName));
else
Page.clickLinkText(Hooks.getDriver(), linkName);
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
@Then("^the message \"(.*?)\" should be displayed$")
public void checkAlertText(String text) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
WebDriverWait wait = new WebDriverWait(driver, GlobalConstants.TWENTY);
String appText = null;
wait.until(ExpectedConditions.textToBePresentInElement(By.xpath("//div[@class='mszbox zoomIn'] | //div[@class='popup-body']/*"), text));
WebElement alert = SeleniumFunctions.findElement(Hooks.getDriver(), By.xpath("//div[@class='mszbox zoomIn'] | //div[@class='popup-body']/*"));
appText = alert.getText();
UtilFunctions.log("This is the app text: " + appText);
appText = appText.trim().replaceAll("\\s+", " ");
Assert.assertTrue((appText.contains(text)));
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
@Then("^the \"(.*?)\" page should (load|not load)(?: within \"(.*?)\" seconds?)?$")
public void checkPageLoad(String pageName, String action, String time) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
WebElement pageElement = null;
curPageName = pageName;
if (time == null) {
//System.out.println("Do nothing!");
pageElement = Page.findPage(Hooks.getDriver(), curPageName, pageName);
} else {
pageElement = Page.findPage(Hooks.getDriver(), curPageName, pageName, Integer.parseInt(time));
}
if (action.equals("load"))
Assert.assertNotNull("Object for pane: " + pageName + " Not Found", pageElement);
else
Assert.assertNull("Object for pane: " + pageName + " Found", pageElement);
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
@Then("^I wait \"(.*?)\" seconds until the \"(.*?)\" element is (not displayed|loaded)$")
public void waitForLoad(String time, String elementName, String state) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
int waitTime;
elementName = elementName.replace(" ", "");
JSONObject fileObj = UtilFunctions.getJSONFileObjBasedOnPageName(curPageName);
String[] elementType = UtilFunctions.getElementStringAndType(fileObj, "MISC_ELEMENTS." + elementName);
String path = elementType[0];
String method = elementType[1];
SeleniumFunctions.explicitWait(Hooks.getDriver(), GlobalConstants.TEN, path + ";" + method);
WebElement eleObj = SeleniumFunctions.findElement(Hooks.getDriver(), SeleniumFunctions.setByValues(path + ";" + method));
if (time == null) {
waitTime = GlobalConstants.FIFTEEN;
} else
waitTime = Integer.parseInt(time);
if (state.equals("loaded")) {
try {
SeleniumFunctions.explicitWait(Hooks.getDriver(), waitTime, path + ";" + method);
} catch (Exception e) {
e.printStackTrace();
UtilFunctions.log("Page not loded" + e.getMessage());
}
} else if (state.equals("not loaded")) {
SeleniumFunctions.explicitWaitForInvisibility(Hooks.getDriver(), waitTime, path + ";" + method);
if (!eleObj.isDisplayed()) {
UtilFunctions.log("Element invisible");
}
}
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
@When("^I select \"(.*?)\" from the \"(.*?)\" dropdown( if it exists)?$")
public void selectFromDropdown(String value, String dropDownName, String exists) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
if (exists == null) {
Page.selectDropDownInPane(Hooks.getDriver(), curPageName, value, dropDownName);
} else {
//Catch errors when operating on a dropdown that may not exist
try {
Page.selectDropDownInPane(Hooks.getDriver(), curPageName, value, dropDownName);
} catch (Exception e) {
e.printStackTrace();
if (exists == null) {
Assert.assertTrue(e.getMessage(), false);
}
UtilFunctions.log("Dropdown '" + dropDownName + "' does not exist. Exception: " + e.getMessage());
}
}
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
@Then("^I click on the \"(.*?)\" task \"(.*?)\"$")
public void clickTask(String taskType, String taskTitle) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
WebElement elt = null;
if (taskType.equals("Poll")) {
elt = SeleniumFunctions.findElement(Hooks.getDriver(), By.xpath("//div[@class='pollbox' and descendant::span[normalize-space(./text())='" + taskTitle + "']]"));
elt.click();
} else if (taskType.equals("Video")) {
elt = SeleniumFunctions.findElement(Hooks.getDriver(), By.xpath("//div[@class='videobox' and descendant::span[normalize-space(./text())='" + taskTitle + "']]"));
elt.click();
} else {
elt = SeleniumFunctions.findElement(Hooks.getDriver(), By.xpath("//div[@class='appbox' and descendant::span[normalize-space(./text())='" + taskTitle + "']]"));
elt.click();
}
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
@When("^I select \"(.*?)\" from the \"(.*?)\" radio list$")
public void selectRadioListButton(String value, String radioName) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
Thread.sleep(500);
Assert.assertTrue("Radio Button: " + radioName + " not found", Page.setRadioValue(Hooks.getDriver(), curPageName, value, radioName));
Thread.sleep(500);
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
@And("^I (un)?check the following checkboxes$")
public void checkMulitipleCheckBoxEntries(String checkType, DataTable dataTable) throws Throwable {
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Start");
List<String> dataList = dataTable.asList(String.class);
for (String checkBoxValue : dataList) {
WebElement checkBoxObj = SeleniumFunctions.findElement(Hooks.getDriver(), By.xpath("//input[@type='checkbox' and following-sibling::p[text()='" + checkBoxValue + "']]"));
// ((JavascriptExecutor) Hooks.getDriver()).executeScript("arguments[0].scrollIntoView(true);", checkBoxObj);
try {
if (!checkBoxObj.isSelected() && checkType == null) {
System.out.println(checkBoxObj.isDisplayed());
System.out.println(checkBoxObj.isEnabled());
checkBoxObj.click();
Thread.sleep(500);
} else if (checkBoxObj.isSelected() && checkType.equals("check")) {
System.out.println(checkBoxObj.isDisplayed());
System.out.println(checkBoxObj.isEnabled());
checkBoxObj.click();
Thread.sleep(500);
}
} catch (Exception e) {
e.printStackTrace();
}
}
UtilFunctions.log("Class: " + className + "; Method: " + new Object() {
}.getClass().getEnclosingMethod().getName() + " : Complete");
}
} | [
"37631963+myappsgit@users.noreply.github.com"
] | 37631963+myappsgit@users.noreply.github.com |
4813041027b9b0c9053897ec52a2f3fdedce21e3 | 2550a0de6c2285d94fd3f42b24f8f2a6696045c3 | /Gym/101608/C.java | 3dcc639c236aa849c685518ebf31287cb5cf6a6e | [] | no_license | Mohd-3/Codeforces-Solutions | a2b26cf2072de7cdc0d2e754d7f0df0bad50174f | 97b0caf353a811f134a4c0206fd3c74fb4707149 | refs/heads/master | 2020-09-01T22:51:20.581848 | 2019-11-04T00:25:09 | 2019-11-04T00:25:09 | 219,078,353 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 4,897 | java | import java.io.*;
import java.util.*;
import java.lang.*;
public class Main {
public static void main(String[] args) throws IOException {
InputStream input = System.in;
OutputStream output = System.out;
InputReader in = new InputReader(new FileReader(new File("scoreboard.in")));
PrintWriter out = new PrintWriter(output);
Solution s = new Solution();
s.solve(1, in, out);
out.close();
}
static class Solution {
double EPS = 0.0000001;
public void solve(int cs, InputReader in, PrintWriter out) {
int t = in.nextInt();
while (t-- > 0) {
int n = in.nextInt();
int[] solved = new int[13];
String ours = in.next();
for (int i = 0; i < 13; i++)
solved[i] = in.nextInt();
for (int i = 0; i < ours.length(); i++)
solved[ours.charAt(i)-'A'] = 0;
int max = 0;
char c = 'a';
for (int i = 0; i < 13; i++) {
if (solved[i] > max) {
max = solved[i];
c = (char)(i+'A');
}
}
out.println(c);
}
}
}
static class InputReader {
BufferedReader br;
StringTokenizer st;
public InputReader(InputStream i) {
br = new BufferedReader(new InputStreamReader(i), 32768);
st = null;
}
public InputReader(FileReader s) {
br = new BufferedReader(s);
st = null;
}
public String next() {
while (st == null || !st.hasMoreTokens()) {
try {
st = new StringTokenizer(br.readLine());
} catch (IOException e) {
throw new RuntimeException(e);
}
}
return st.nextToken();
}
public int nextInt() {
return Integer.parseInt(next());
}
public long nextLong() {
return Long.parseLong(next());
}
public double nextDouble() {
return Double.parseDouble(next());
}
public String nextLine() {
try {
return br.readLine();
} catch (IOException e) {
throw new RuntimeException(e);
}
}
}
static class Reader {
final private int BUFFER_SIZE = 1 << 16;
private DataInputStream din;
private byte[] buffer;
private int bufferPointer, bytesRead;
public Reader(){
din=new DataInputStream(System.in);
buffer=new byte[BUFFER_SIZE];
bufferPointer=bytesRead=0;
}
public Reader(String file_name) throws IOException{
din=new DataInputStream(new FileInputStream(file_name));
buffer=new byte[BUFFER_SIZE];
bufferPointer=bytesRead=0;
}
public String readLine() throws IOException{
byte[] buf=new byte[64]; // line length
int cnt=0,c;
while((c=read())!=-1){
if(c=='\n')break;
buf[cnt++]=(byte)c;
}
return new String(buf,0,cnt);
}
public int nextInt() throws IOException{
int ret=0;byte c=read();
while(c<=' ')c=read();
boolean neg=(c=='-');
if(neg)c=read();
do{ret=ret*10+c-'0';}while((c=read())>='0'&&c<='9');
if(neg)return -ret;
return ret;
}
public long nextLong() throws IOException{
long ret=0;byte c=read();
while(c<=' ')c=read();
boolean neg=(c=='-');
if(neg)c=read();
do{ret=ret*10+c-'0';}while((c=read())>='0'&&c<='9');
if(neg)return -ret;
return ret;
}
public double nextDouble() throws IOException{
double ret=0,div=1;byte c=read();
while(c<=' ')c=read();
boolean neg=(c=='-');
if(neg)c = read();
do {ret=ret*10+c-'0';}while((c=read())>='0'&&c<='9');
if(c=='.')while((c=read())>='0'&&c<='9')
ret+=(c-'0')/(div*=10);
if(neg)return -ret;
return ret;
}
private void fillBuffer() throws IOException{
bytesRead=din.read(buffer,bufferPointer=0,BUFFER_SIZE);
if(bytesRead==-1)buffer[0]=-1;
}
private byte read() throws IOException{
if(bufferPointer==bytesRead)fillBuffer();
return buffer[bufferPointer++];
}
public void close() throws IOException{
if(din==null) return;
din.close();
}
}
}
| [
"mohd@al-abdulhadi.com"
] | mohd@al-abdulhadi.com |
a6c57bbc21b24472a9fa7719364b5238bc097a85 | 8e4d63360766dffbdd0b8268fbd28bd58f914649 | /cloud-consumerzk-order80/src/main/java/com/atguigu/springcloud/controller/OrderZKController.java | 9c82e63f4f5f0733551a3021f5f5e9d2f0004bf5 | [] | no_license | MixuZKang/springcloud-demo | bdf56616bc51d78d3ecf4da729c12fd64cf3b5e6 | a79d20d9edbe1379db49e643a9655147daf4f1be | refs/heads/master | 2023-08-25T10:33:03.123447 | 2021-10-17T12:49:59 | 2021-10-17T12:49:59 | 407,489,818 | 1 | 0 | null | null | null | null | UTF-8 | Java | false | false | 873 | java | package com.atguigu.springcloud.controller;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.client.RestTemplate;
@RestController
@Slf4j
public class OrderZKController {
public static final String INVOKE_URL = "http://cloud-provider-payment";
@Autowired
private RestTemplate restTemplate;
@GetMapping(value = "/consumer/payment/zk")
public String paymentInfo() {
String result = restTemplate.getForObject(INVOKE_URL + "/payment/zk", String.class);
System.out.println("消费者调用支付服务(通过zookeeper)--->result:" + result);
return result;
}
}
| [
"2352539622@qq.com"
] | 2352539622@qq.com |
92ec7ab7625e07113a1cdcca945305bc38df56e9 | 906662c1e9799f0277c276d308f6ad0c20c10ca3 | /Java/src/baekjoon/algoStudy/DFS_BFS/DFSBFS.java | 5eba66878a66a2ea655f0d29d27ab30c58dc55c0 | [] | no_license | lmjing/AlgorithmStudy | b69c4f7719db9f9d35bc93aadb3afa123537e757 | 6a566c19b835502ec737e88a91737c2f411681c7 | refs/heads/master | 2022-02-09T23:24:57.970866 | 2022-02-06T03:57:53 | 2022-02-06T03:57:53 | 75,264,218 | 1 | 0 | null | null | null | null | UTF-8 | Java | false | false | 5,280 | java | package baekjoon.algoStudy.DFS_BFS;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.LinkedList;
import java.util.Queue;
import java.util.Scanner;
import java.util.StringTokenizer;
public class DFSBFS {
static class Num1260 {
// NOTE: n, m 제대로 안봐서 계속 틀렸음
static boolean[][] ad;
static int n;
public static void main() {
Scanner sc = new Scanner(System.in);
n = sc.nextInt();
int m = sc.nextInt();
int v = sc.nextInt();
sc.nextLine();
ad = new boolean[n+1][n+1];
for (int i=0; i<m; i++) {
int a1 = sc.nextInt(); int a2 = sc.nextInt();
ad[a1][a2] = true;
ad[a2][a1] = true;
sc.nextLine();
}
dfs(v, new boolean[n+1]);
System.out.println();
bfs(v, new boolean[n+1]);
}
private static void dfs(int v, boolean[] visited) {
System.out.print(v + " ");
visited[v] = true;
for (int i=1; i<n+1; i++) {
if (ad[v][i] && !visited[i]) {
dfs(i, visited);
}
}
}
private static void bfs(int v, boolean[] visited) {
Queue<Integer> queue = new LinkedList<>();
queue.add(v);
visited[v] = true;
StringBuilder s = new StringBuilder(String.valueOf(v));
while (!queue.isEmpty()) {
v = queue.remove();
for (int i=1; i<n+1; i++) {
if (ad[v][i] && !visited[i]) {
visited[i] = true;
queue.add(i);
s.append(" " + i);
}
}
}
System.out.println(s);
}
}
static class Num14502 {
/*
NOTE : n,m의 범위가 작아서 이중포문으로 계속 확인 가능
그래서 3개의 벽 만들 수 있는 만큼 다 만들어서 바이러스 퍼트리고 일일이 수 확인 하는 방법 사용
*/
// BEFORE: virusMap = tempMap; 으로 해서 바이러스 퍼트릴때 tempMap도 바껴서 다 못도는 현상 발생
static int n, m;
static int[][] map, tempMap, virusMap;
static final int WallCount = 3;
static int max = 0;
static int[] dx = {0, 0, -1, 1};
static int[] dy = {-1, 1, 0, 0};
public static void main() throws IOException {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
StringTokenizer st = new StringTokenizer(br.readLine());
n = Integer.parseInt(st.nextToken());
m = Integer.parseInt(st.nextToken());
map = new int[n][m];
tempMap = new int[n][m];
virusMap = new int[n][m];
for (int i=0; i<n; i++) {
st = new StringTokenizer(br.readLine());
for (int j=0; j<m; j++) {
map[i][j] = tempMap[i][j] = Integer.parseInt(st.nextToken());
}
}
for (int i=0; i<n*m; i++) {
if (map[i/m][i%m] == 0) {
tempMap[i/m][i%m] = 1;
createWalls(i, 1);
tempMap[i/m][i%m] = 0;
}
}
System.out.println(max);
}
private static void createWalls(int i, int wallCount) {
if (wallCount == 3) {
// 바이러스 퍼트린다.
for (int ii=0; ii<n; ii++) {
for (int jj=0; jj<m; jj++) {
virusMap[ii][jj] = tempMap[ii][jj];
}
}
for (int ii=0; ii<n; ii++) {
for (int jj=0; jj<m; jj++) {
if (tempMap[ii][jj] == 2) {
spreadVirus(ii, jj);
}
}
}
// 안전영역 최대 값 구한다.
int count = safeAreaCount();
max = max < count ? count : max;
return;
}
for (int j=i+1; j<m*n; j++) {
if (tempMap[j/m][j%m] == 0) {
tempMap[j/m][j%m] = 1;
createWalls(j, wallCount+1);
tempMap[j/m][j%m] = 0;
}
}
}
private static void spreadVirus(int y, int x) {
for (int i=0; i<4; i++) {
int nx = x + dx[i];
int ny = y + dy[i];
if (nx >= 0 && nx < m && ny >=0 && ny < n) {
if (virusMap[ny][nx] == 0) {
virusMap[ny][nx] = 2;
spreadVirus(ny, nx);
}
}
}
}
private static int safeAreaCount() {
int count = 0;
for (int i=0; i<n; i++) {
for (int j=0; j<m; j++) {
if (virusMap[i][j] == 0) count++;
}
}
return count;
}
}
}
| [
"lmjing1234@gmail.com"
] | lmjing1234@gmail.com |
5c77818142ab0f65f7ebf16bc80758933879a901 | 5bdb52eedeb2c4003ccc9a0ecfa6ae720e990d4c | /SigettServiceWeb/src/main/java/edu/unl/sigett/util/OntologyService.java | c78f0164dde4d96ec74d129cfa0346afc46571bb | [] | no_license | jlmallas160190/sigett | 6abbac497850252cfe41a4e0b6f4ad0544a84222 | 760dd75963fb1c3d93c1405f1efe4d9308ea2e4f | refs/heads/master | 2016-09-10T15:44:59.805427 | 2015-08-20T03:50:49 | 2015-08-20T03:50:49 | 34,427,454 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 5,059 | 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 edu.unl.sigett.util;
import edu.unl.sigett.lud.service.*;
import java.io.Serializable;
/**
*
* @author jorge-luis
*/
public class OntologyService implements Serializable {
private AutorOntService autorOntService;
private AutorProyectoOntService autorProyectoOntService;
private ProyectoOntService proyectoOntService;
private CarreraOntService carreraOntService;
private OfertaAcademicoOntService ofertaAcademicoOntService;
private PeriodoAcademicoOntService periodoAcademicoOntService;
private AreaAcademicaOntService areaAcademicaOntService;
private NivelAcademicoOntService nivelAcademicoOntService;
private LineaInvestigacionOntService lineaInvestigacionOntService;
private LineaInvestigacionProyectoOntService lineaInvestigacionProyectoOntService;
private ProyectoCarreraOfertaOntService proyectoCarreraOfertaOntService;
private DocenteOntService docenteOntService;
private DirectorProyectoOntService directorProyectoOntService;
public OntologyService() {
}
public AutorOntService getAutorOntService() {
return autorOntService;
}
public void setAutorOntService(AutorOntService autorOntService) {
this.autorOntService = autorOntService;
}
public AutorProyectoOntService getAutorProyectoOntService() {
return autorProyectoOntService;
}
public void setAutorProyectoOntService(AutorProyectoOntService autorProyectoOntService) {
this.autorProyectoOntService = autorProyectoOntService;
}
public ProyectoOntService getProyectoOntService() {
return proyectoOntService;
}
public void setProyectoOntService(ProyectoOntService proyectoOntService) {
this.proyectoOntService = proyectoOntService;
}
public CarreraOntService getCarreraOntService() {
return carreraOntService;
}
public void setCarreraOntService(CarreraOntService carreraOntService) {
this.carreraOntService = carreraOntService;
}
public OfertaAcademicoOntService getOfertaAcademicoOntService() {
return ofertaAcademicoOntService;
}
public void setOfertaAcademicoOntService(OfertaAcademicoOntService ofertaAcademicoOntService) {
this.ofertaAcademicoOntService = ofertaAcademicoOntService;
}
public PeriodoAcademicoOntService getPeriodoAcademicoOntService() {
return periodoAcademicoOntService;
}
public void setPeriodoAcademicoOntService(PeriodoAcademicoOntService periodoAcademicoOntService) {
this.periodoAcademicoOntService = periodoAcademicoOntService;
}
public AreaAcademicaOntService getAreaAcademicaOntService() {
return areaAcademicaOntService;
}
public void setAreaAcademicaOntService(AreaAcademicaOntService areaAcademicaOntService) {
this.areaAcademicaOntService = areaAcademicaOntService;
}
public NivelAcademicoOntService getNivelAcademicoOntService() {
return nivelAcademicoOntService;
}
public void setNivelAcademicoOntService(NivelAcademicoOntService nivelAcademicoOntService) {
this.nivelAcademicoOntService = nivelAcademicoOntService;
}
public LineaInvestigacionOntService getLineaInvestigacionOntService() {
return lineaInvestigacionOntService;
}
public void setLineaInvestigacionOntService(LineaInvestigacionOntService lineaInvestigacionOntService) {
this.lineaInvestigacionOntService = lineaInvestigacionOntService;
}
public LineaInvestigacionProyectoOntService getLineaInvestigacionProyectoOntService() {
return lineaInvestigacionProyectoOntService;
}
public void setLineaInvestigacionProyectoOntService(LineaInvestigacionProyectoOntService lineaInvestigacionProyectoOntService) {
this.lineaInvestigacionProyectoOntService = lineaInvestigacionProyectoOntService;
}
public ProyectoCarreraOfertaOntService getProyectoCarreraOfertaOntService() {
return proyectoCarreraOfertaOntService;
}
public void setProyectoCarreraOfertaOntService(ProyectoCarreraOfertaOntService proyectoCarreraOfertaOntService) {
this.proyectoCarreraOfertaOntService = proyectoCarreraOfertaOntService;
}
public DocenteOntService getDocenteOntService() {
return docenteOntService;
}
public void setDocenteOntService(DocenteOntService docenteOntService) {
this.docenteOntService = docenteOntService;
}
public DirectorProyectoOntService getDirectorProyectoOntService() {
return directorProyectoOntService;
}
public void setDirectorProyectoOntService(DirectorProyectoOntService directorProyectoOntService) {
this.directorProyectoOntService = directorProyectoOntService;
}
}
| [
"jorge-luis@jorge-luis-PC"
] | jorge-luis@jorge-luis-PC |
bd7f61b89fb91af22879db1de0cb447dc51d4cfc | adee578270fae3eeff740b34b635c87e1da24723 | /src/main/java/ua/i/mail100/dto/EventDTO.java | f7a1f0621ec950446e7082430ddf718b12a191da | [] | no_license | Antoninadan/Swimmer | 9ddbebf2a955adc797d0b18d83910e41ab9ac13e | 80fc62b81918513066491997a0cfe628e0d640c1 | refs/heads/master | 2021-05-18T04:29:31.853057 | 2020-05-31T17:41:34 | 2020-05-31T17:41:34 | 251,107,205 | 0 | 0 | null | 2021-04-26T20:12:30 | 2020-03-29T18:47:27 | Java | UTF-8 | Java | false | false | 1,184 | java | package ua.i.mail100.dto;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import java.util.List;
@Setter
@Getter
@NoArgsConstructor
@AllArgsConstructor
public class EventDTO extends BaseEntityDTO {
private Integer franchiseId;
private String organizer;
private String name;
private String dateFrom;
private String dateTo;
private Integer countryId;
private String venue;
private String url;
private String comment;
private List<DistanceDTO> distances;
public EventDTO(Integer id, Integer franchiseId, String organizer, String name, String dateFrom, String dateTo,
Integer countryId, String venue, String url, String comment,
Long createDate, Long modifyDate, String recordStatus) {
super(id, createDate, modifyDate, recordStatus);
this.franchiseId = franchiseId;
this.organizer = organizer;
this.name = name;
this.dateFrom = dateFrom;
this.dateTo = dateTo;
this.countryId = countryId;
this.venue = venue;
this.url = url;
this.comment = comment;
}
}
| [
"mail100@i.ua"
] | mail100@i.ua |
7e6f1566a388da726cc10ceaffbc1063c9e318be | 1240b64d7e8b221967f78e3bc2921a2c04ae92dc | /chat-app/src/main/java/ptit/base/BaseResponse.java | 79f424b2b12ba98d0ff2095736b4437cbb518617 | [] | no_license | sonht1109/LTM-PTIT_4th | a5ae76603eb41e88d7c004eb86293a599e2db98b | cd9d1e4e9d05679c898b4afd0d898ec53329e703 | refs/heads/master | 2023-08-17T04:40:02.989519 | 2021-09-21T06:19:27 | 2021-09-21T06:19:27 | 400,230,741 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 186 | java | package ptit.base;
import lombok.Builder;
import lombok.Data;
@Data
@Builder
public class BaseResponse<T> {
private String message;
private String code;
private T body;
}
| [
"phamthai4643@gmail.com"
] | phamthai4643@gmail.com |
786b0fcfd6d12e3a28423b114232a4c44236f9cc | 79e50491252066d29cf5f674b34a28c9abf8bdb4 | /src/main/java/cn/leadeon/cardopenadmin/mapper/nmg_user_roleMapper.java | 67ba1f11fd64407f176f5d806fb89e55c8c1a55f | [] | no_license | gitcaiyu/cardopenadmin | 556e141f69f8a4fd33f09850e747c8a438b90e40 | afbf4476eaa41631e4163fb7eb6c8aee4ae779dc | refs/heads/master | 2020-04-11T01:47:23.716657 | 2019-03-19T01:48:08 | 2019-03-19T01:48:08 | 161,426,344 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 504 | java | package cn.leadeon.cardopenadmin.mapper;
import cn.leadeon.cardopenadmin.entity.nmg_user_role;
import org.apache.ibatis.session.RowBounds;
import java.util.List;
import java.util.Map;
public interface nmg_user_roleMapper {
int insert(nmg_user_role record);
int insertSelective(nmg_user_role record);
List<Map<String,Object>> userRole(Map param, RowBounds rowBounds );
int roleDel(String roleId);
int roleUpdate(nmg_user_role nmg_user_role);
int userRoleTotal(Map param);
} | [
"caiyu@leadeon.cn"
] | caiyu@leadeon.cn |
b0d2f2a73726af1db3478957ea21425d2234b4a0 | 23aae01d78cb5f7d197b9cb9c8215ba2ed0271a9 | /G7_Cuentas/src/cuentas/CuentaDeAhorros.java | 97a06f71d842a9d9099ae19a49b8e3251e909d1c | [
"Apache-2.0"
] | permissive | FredyKcrez/JAVA | 0283f26450ed482402ffece4f305569c6c122bc3 | c24d92428ed8a0d1c5656689fc433be50d40dc5d | refs/heads/master | 2021-07-09T08:19:01.062524 | 2020-08-08T04:38:15 | 2020-08-08T04:38:15 | 135,635,018 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,367 | java | package cuentas;
/**
* @date 20/06/2018
* @author Fredy Kcrez
*/
public class CuentaDeAhorros {
private static double tasaInteresAnual = 0.10;
private static int cantidadCuentas = 0;
private double saldo;
CuentaDeAhorros() {
this.cantidadCuentas++;
}
/**
* @return the tasaInteresAnual
*/
public static double getTasaInteresAnual() {
return tasaInteresAnual;
}
/**
* @param aTasaInteresAnual the tasaInteresAnual to set
*/
public static void setTasaInteresAnual(double aTasaInteresAnual) {
tasaInteresAnual = aTasaInteresAnual;
}
/**
* @return the cantidadCuentas
*/
public static float getCantidadCuentas() {
return cantidadCuentas;
}
/**
* @param aCantidadCuentas the cantidadCuentas to set
*/
public static void setCantidadCuentas(int aCantidadCuentas) {
cantidadCuentas = aCantidadCuentas;
}
public double calcularInteresMensual() {
return (this.getSaldo() * this.tasaInteresAnual) / 12;
}
/**
* @return the saldo
*/
public double getSaldo() {
return saldo;
}
/**
* @param saldo the saldo to set
*/
public void setSaldo(double saldo) {
this.saldo = saldo;
}
} | [
"zholary@gmail.com"
] | zholary@gmail.com |
457ee2fe7f97674a4f0321c813a8847d278fe93a | c21488243e71abf1bf735c9ce3f96f15f9d374ea | /app/src/main/java/com/example/ofir/bopo/sendMultipleObjectsTestActivity.java | 93603ac8d4eeeebeca3b2257b7c3472abafb5b89 | [] | no_license | Styxer/BoPoFireBase | 60640e6d4817767aa760f7829d63ef6dee38bb36 | 6dfb217d38921eb21251f19d3665839e0e8108a2 | refs/heads/master | 2021-01-12T10:05:32.883479 | 2016-12-13T16:10:27 | 2016-12-13T16:10:27 | 76,358,527 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,305 | java | package com.example.ofir.bopo;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
import com.firebase.client.Firebase;
public class sendMultipleObjectsTestActivity extends AppCompatActivity {
private EditText mValueField, mKeyValue;
private Button mBadd;
private Firebase mRootRef;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_send_multiple_objects_test);
mRootRef = new Firebase("https://bopo-152112.firebaseio.com/Users");
mValueField = (EditText) findViewById(R.id.etValueField);
mKeyValue = (EditText) findViewById(R.id.etKeyValue);
mBadd = (Button) findViewById(R.id.bAdd);
mBadd.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
String value = mValueField.getText().toString().trim();
String key = mKeyValue.getText().toString().trim();
Firebase childRef = mRootRef.child(key);
// childRef.setValue(value);
childRef.setValue(value);
}
});
}
}
| [
"gennin@gmail.com"
] | gennin@gmail.com |
a7e62ec7a4436b5116c2dfa3cf44a1cecb8bba6d | d86a6b572e1b5b5867970fffeaafb1df8d43cb83 | /spring-demo-aop-pointcut-combo/src/main/java/com/aopdemo/MainDemoApp.java | dd3470964e6d56a2187886a7c411fdf20e36882a | [] | no_license | FabioDsg/Spring_2020 | 2b85a7ba041ffe57e4e46734e163b6082b4fff87 | fbd15e4bc762496ff844c736c9827de099314a3b | refs/heads/master | 2023-02-08T03:52:11.994480 | 2020-12-28T22:54:45 | 2020-12-28T22:54:45 | 295,595,681 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,230 | java | package com.aopdemo;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;
import com.aopdemo.dao.AccountDAO;
import com.aopdemo.dao.MemberShipDAO;
public class MainDemoApp {
public static void main(String[] args) {
// Read spring config java class
AnnotationConfigApplicationContext context =
new AnnotationConfigApplicationContext(DemoConfig.class);
// Get the bean from spring container
AccountDAO theAccountDAO = context.getBean("accountDAO", AccountDAO.class);
// Get the bean from spring container
MemberShipDAO theMemberShipDAO = context.getBean("memberShipDAO", MemberShipDAO.class);
// Call the business method
Account myAccount = new Account();
theAccountDAO.addAccount(myAccount, true);
theAccountDAO.doWork();
// Call the accountdao getter/setter methods
theAccountDAO.setName("foobar");
theAccountDAO.setServiceCode("silver");
String name = theAccountDAO.getName();
String code = theAccountDAO.getServiceCode();
// Call the MemberShip business method
theMemberShipDAO.addAccount();
theMemberShipDAO.goToSleep();
// Close the context
context.close();
}
}
| [
"fabio.goncalves@catolica.edu.br"
] | fabio.goncalves@catolica.edu.br |
c4d704ec4869978e7c96ef555883c8a0a31849d9 | 02527f348811e403e08ddc7978d8022976b21a1b | /src/main/java/net/kuper/tz/core/datasource/DynamicDataSource.java | f26d88fd2625347121effb20ba8a0365f4295b6e | [] | no_license | tuzhi300/tz-core | 1eca190f099e7da5e6ec880f815ef3ba25cd27af | 8d47c5bdadc03b8299b196fa186400ed846e1c9c | refs/heads/master | 2022-06-18T00:44:02.756616 | 2020-05-14T06:48:48 | 2020-05-14T06:48:48 | 262,971,146 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,113 | java | package net.kuper.tz.core.datasource;
import org.springframework.jdbc.datasource.lookup.AbstractRoutingDataSource;
import javax.sql.DataSource;
import java.util.Map;
/**
* 动态数据源
* @author geYang
* @date 2018-05-14
*/
public class DynamicDataSource extends AbstractRoutingDataSource {
private static final ThreadLocal<String> contextHolder = new ThreadLocal<>();
/**
* 配置DataSource, defaultTargetDataSource为主数据库
*/
public DynamicDataSource(DataSource defaultTargetDataSource, Map<Object, Object> targetDataSources) {
super.setDefaultTargetDataSource(defaultTargetDataSource);
super.setTargetDataSources(targetDataSources);
super.afterPropertiesSet();
}
@Override
protected Object determineCurrentLookupKey() {
return getDataSource();
}
public static void setDataSource(String dataSource) {
contextHolder.set(dataSource);
}
public static String getDataSource() {
return contextHolder.get();
}
public static void clearDataSource() {
contextHolder.remove();
}
}
| [
"shengongwen@163.com"
] | shengongwen@163.com |
4060fb72bc398bc23155503fb3fb69baee2cdc8e | e3c93a715a09f7057bc19252983c3eda5911082b | /Sem1/src/t8/Ax8.java | 6a5f37268e4cd6ac3d17f548b5ad56dcfab1f3cd | [] | no_license | Rohith-2/Java-Amrita | 1ae1c4b1d434b1a83bbb3064edd81caadb2097f5 | 44d9c58e2d55989ae3248df75860065467c7eb42 | refs/heads/master | 2023-04-01T03:28:25.685480 | 2021-04-04T15:18:00 | 2021-04-04T15:18:00 | 282,410,784 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 956 | java | package t8;
public class Ax8 {
public static void main (String[] args) throws InterruptedException {
final Addition a=new Addition();
Thread t1 = new Thread(new Runnable()
{
public void run(){
try {
a.add(1,10);
} catch(Exception e) {
}
}
});
Thread t2 = new Thread(new Runnable()
{
public void run(){
try {
a.add(1,4);
} catch(Exception e) {
}
}
});
t1.start();
t2.start();
t1.join();
t2.join();
}
public static class Addition{
int a, b;
int sum=0;
public void add(int a, int b) throws InterruptedException{
synchronized(this){
for (int i=a;i<=b;i++){
sum=sum+i;
Thread.sleep(1000);
}
System.out.println("Sum="+sum);
}
}
}
}
| [
"rrohith2001@gmail.com"
] | rrohith2001@gmail.com |
222fcb7ff8c7d133f1d1cd75ed28e35728c4b77c | 2f382f8cd1f0fb27ad0edbe6120e4c2dfa70ffbd | /CalculateLoopSum.java | 6fc6ea3f6a53934f688ea5e890a18e617a461580 | [] | no_license | macikgozm/Java | bdd5f57458492c2172b137d371ef2b6e6b6dbb30 | 988ad437eb18e9252597a4af3d73b1883a3d86cf | refs/heads/master | 2020-03-27T22:57:11.866370 | 2018-09-04T03:43:37 | 2018-09-04T03:43:37 | 147,275,320 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 910 | java | import java.util.Scanner;
/**
*
* @author Mehmet ACIKGOZ
*
* This program will sum all the integers from a lower limit through an upper limit.
*/
public class CalculateLoopSum {
/**
* This program will sum all the integers from a lower limit through an upper limit.
* It uses an initial loop to ensure a valid upper and lower bound are entered.
*/
public static void main(String [] args) {
Scanner input = new Scanner(System.in);
int lowerLimit = 0, upperLimit = 0, sum = 0;
do {
System.out.print("Lower limit: ");
lowerLimit = input.nextInt();
System.out.print("Upper Limit: ");
upperLimit = input.nextInt();
System.out.println();
} while (lowerLimit > upperLimit);
for (int i = lowerLimit; i <= upperLimit; i++) {
sum += i;
}
System.out.println("The sum from " + lowerLimit + " to " + upperLimit + " is " + sum);
}
}
| [
"macikgozm@gmail.com"
] | macikgozm@gmail.com |
e84805994a58f967da1d3ff90ac64520954408e8 | aa1e6fb49207ef7d3d7cc00b688fdb28895c6956 | /P15009907/src/main/java/com/erim/sz/company/service/CompanyBusinessService.java | 64a66e7640d2719e9f2d4b9a1d2ee81ef87dacee | [] | no_license | zhanght86/erim | f76fec9267200c6951a0a8c1fb3f723de88a039c | 504d81bb4926e496c11a34641dcc67150e78dadc | refs/heads/master | 2021-05-15T17:10:07.801083 | 2016-12-02T09:35:07 | 2016-12-02T09:35:07 | 107,489,023 | 1 | 0 | null | 2017-10-19T02:37:10 | 2017-10-19T02:37:10 | null | UTF-8 | Java | false | false | 5,571 | java | package com.erim.sz.company.service;
import javax.servlet.http.HttpServletRequest;
import org.apache.shiro.SecurityUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.config.BeanDefinition;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Service;
import org.springframework.ui.ModelMap;
import com.erim.sz.common.bean.ComBusRegionBean;
import com.erim.sz.common.bean.CompanyBusinessBean;
import com.erim.sz.company.dao.ComBusRegionDao;
import com.erim.sz.company.dao.CompanyBusinessDao;
import com.erim.sz.system.bean.ZxSystemUserBean;
import com.erim.sz.web.util.CommonUtil;
/**
* @类名: CompanyBusinessService
* @描述: 公司业务范围信息实体操作业务层
* @作者: 宁晓强
* @创建时间: 2015年11月4日 下午1:24:02
*/
@Service("companyBusinessService")
@Scope(BeanDefinition.SCOPE_SINGLETON)
public class CompanyBusinessService {
@Autowired
private CompanyBusinessDao companyBusinessDao;
@Autowired
private ComBusRegionDao comBusRegionDao;
/**
* @Title: selectBuinessByCpyId
* @Description: 根据企业id 查询企业业务范围
* @param @param cpyId
* @param @return 设定文件
* @return CompanyBusinessBean 返回类型
* @author maoxian
* @date 2015年12月28日 下午9:06:03
* @throws
*/
public CompanyBusinessBean selectBuinessByCpyId(Integer cpyId){
return this.companyBusinessDao.getBusinessById(cpyId);
}
/**
* @方法名: insert
* @描述: 新增公司业务范围信息
* @作者: 宁晓强
* @创建时间: 2015年11月4日 下午1:21:08
* @param map
* @param bean
* @return
*/
public Integer insert(ModelMap map, CompanyBusinessBean bean, String currDate, HttpServletRequest request) {
Integer result = CommonUtil.ERROR;
// 公司ID
Integer cpyId = (Integer) SecurityUtils.getSubject().getSession().getAttribute("cpyId");
// 录入业务地区
result = insertBusRegion(request, cpyId);
// 如果录入异常直接返回失败
if (result == CommonUtil.ERROR) {
return result;
}
bean.setCpyId(cpyId);
// 国际业务方向
String servcieOuter = bean.getCbsServiceOuter();
// 国际地接涉及区域 - 完全从国际业务方向获取
bean.setCbsNurState(servcieOuter);
// 国际其他业务方向
String serviceRest = bean.getCbsServiceRest();
// 当国际其他业务方向不为空时,添加到国际其他地接涉及区域。
if (serviceRest != null && !"".equals(serviceRest)) {
// 国际其他地接涉及区域
String nurRest = bean.getCbsNurRest();
bean.setCbsNurRest(serviceRest + "," + nurRest);
}
// 执行新增前,先预删除该企业ID相关的业务信息,防止重复。
companyBusinessDao.deleteBusinessByCpyId(bean);
// 执行新增
companyBusinessDao.insert(bean);
return CommonUtil.SUCCESS;
}
/**
* @描述: 录入业务地区
* @作者: 宁晓强
* @创建时间: 2015年11月10日 下午6:00:18
* @param request
* @param cpyId
*/
public Integer insertBusRegion(HttpServletRequest request, Integer cpyId) {
Integer result = CommonUtil.ERROR;
try {
// 业务区域
ComBusRegionBean regionModel = new ComBusRegionBean();
// 地接涉及区域省市县
String[] nurProvinceA = request.getParameterValues("cbsNurProvince");
String[] nurCityA = request.getParameterValues("cbsNurCity");
String[] nurCountyA = request.getParameterValues("cbsNurCounty");
// 录入地接涉及区域
for (int i = 0; i < nurProvinceA.length; i++) {
// 省
String proStr = nurProvinceA[i];
if (proStr != null && !"".equals(proStr)) {
regionModel.setCpyId(cpyId);// 公司iD
regionModel.setCbrBusType("01");// 01代表地接涉及区域
regionModel.setCbrProvince(proStr);// 省
regionModel.setCbrCity(nurCityA[i]);// 市
regionModel.setCbrCounty(nurCountyA[i]);// 县
// 执行新增前清库
comBusRegionDao.deleteRegion(regionModel);
// 执行新增
comBusRegionDao.insert(regionModel);
}
}
// 可服务地区省市县
String[] srlProvinceA = request.getParameterValues("cbsSrlProvince");
String[] srlCityA = request.getParameterValues("cbsSrlCity");
String[] srlCountyA = request.getParameterValues("cbsSrlCounty");
// 录入可服务地区
for (int i = 0; i < srlProvinceA.length; i++) {
// 省
String proStr = srlProvinceA[i];
if (proStr != null && !"".equals(proStr)) {
regionModel.setCpyId(cpyId);// 公司iD
regionModel.setCbrBusType("02");// 02代表可服务区域
regionModel.setCbrProvince(proStr);// 省
regionModel.setCbrCity(srlCityA[i]);// 市
regionModel.setCbrCounty(srlCountyA[i]);// 县
// 执行新增前清库
comBusRegionDao.deleteRegion(regionModel);
// 执行新增
comBusRegionDao.insert(regionModel);
}
}
result = CommonUtil.SUCCESS;
} catch (Exception e) {
result = CommonUtil.ERROR;
}
return result;
}
/**
* @方法名: showBusinessPage
* @描述: 打开修改业务范围信息页面 - 暂时废弃
* @作者: 宁晓强
* @创建时间: 2015年11月4日 下午1:22:54
* @param map
* @param bean
*/
public void updateBusinessPage(ModelMap map, ZxSystemUserBean bean) {
Integer cpyId = bean.getCpyId();
CompanyBusinessBean model = new CompanyBusinessBean();
// 根据ID获取一条信息
model = companyBusinessDao.getBusinessById(cpyId);
map.addAttribute("business", model);
map.addAttribute("cpyId", cpyId);
}
}
| [
"libra0920@qq.com"
] | libra0920@qq.com |
d346c72fa58982fd0f50e4bd92caa785fcaaae05 | 59076c440ac20bc6c387eccb56c73c2b6d5bac57 | /Exercicios_Java_Orientacao_Objeto/src/classesAbstratas/Agencia.java | 70267c4797d34703346436507b6c5e49b76b627a | [] | no_license | william-marquetti/Exercicios_Java_Orientacao_Objeto | f0e5d0902877c3b4c2e3112f8b59b83ba7b852de | 890d4f530cae1363829f2a81cb38094e4549d170 | refs/heads/master | 2021-03-27T20:11:27.042720 | 2017-07-27T22:06:48 | 2017-07-27T22:06:48 | 95,716,567 | 1 | 0 | null | null | null | null | WINDOWS-1250 | Java | false | false | 490 | java | /**
* Pacote criado para armazenar as classes abstratas.
*/
package classesAbstratas;
/**
*
* @author William Gustavo Marquetti
*
* Classe responsável por definir a estrutura do objeto Agencia.
*/
public class Agencia {
private int numero;
public Agencia() {
}
public Agencia(int numero) {
this.numero = numero;
}
public int getNumero() {
return numero;
}
public void setNumero(int numero) {
this.numero = numero;
}
}
| [
"Noturno@192.168.7.177"
] | Noturno@192.168.7.177 |
b9e012702ade025004a85644930f0b30c43c9e58 | 421f0a75a6b62c5af62f89595be61f406328113b | /generated_tests/model_seeding/20_nekomud-net.sourceforge.nekomud.nio.NetworkServiceNioImpl-0.5-2/net/sourceforge/nekomud/nio/NetworkServiceNioImpl_ESTest_scaffolding.java | 37cf2278a69cb0da384377fbe5bf949dfaedabc5 | [] | no_license | tigerqiu712/evosuite-model-seeding-empirical-evaluation | c78c4b775e5c074aaa5e6ca56bc394ec03c2c7c6 | 11a920b8213d9855082d3946233731c843baf7bc | refs/heads/master | 2020-12-23T21:04:12.152289 | 2019-10-30T08:02:29 | 2019-10-30T08:02:29 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 555 | java | /**
* Scaffolding file used to store all the setups needed to run
* tests automatically generated by EvoSuite
* Tue Oct 29 09:29:11 GMT 2019
*/
package net.sourceforge.nekomud.nio;
import org.evosuite.runtime.annotation.EvoSuiteClassExclude;
import org.junit.BeforeClass;
import org.junit.Before;
import org.junit.After;
import org.evosuite.runtime.sandbox.Sandbox;
import org.evosuite.runtime.sandbox.Sandbox.SandboxMode;
@EvoSuiteClassExclude
public class NetworkServiceNioImpl_ESTest_scaffolding {
// Empty scaffolding for empty test suite
}
| [
"pderakhshanfar@bsr01.win.tue.nl"
] | pderakhshanfar@bsr01.win.tue.nl |
b83d27123eed82c021ea8dcfd9f59b2c62e8a42f | 163815a77c218277a78a75da33755744dfe3c821 | /material/tokenNotifier/src/com/explodingpixels/macwidgets/SourceListControlBar.java | 7ec633c895c612acfcddd95c8e87570a19ae7499 | [
"MIT"
] | permissive | mathieulegoc/SmartTokens | 24cf22c059d1ad075b30822bb9a0de7953bb3c0d | f54e739cdd1faf80d3fed8912a361a7ac017662a | refs/heads/master | 2021-01-10T21:30:59.908858 | 2015-12-11T13:08:43 | 2015-12-11T13:08:43 | 39,387,262 | 11 | 4 | null | null | null | null | UTF-8 | Java | false | false | 4,807 | java | package com.explodingpixels.macwidgets;
import java.awt.Cursor;
import java.awt.event.ActionListener;
import java.awt.event.MouseAdapter;
import java.awt.event.MouseEvent;
import java.awt.event.MouseMotionListener;
import javax.swing.BorderFactory;
import javax.swing.Icon;
import javax.swing.ImageIcon;
import javax.swing.JComponent;
import javax.swing.JLabel;
import javax.swing.JSplitPane;
import javax.swing.SwingUtilities;
import com.explodingpixels.widgets.PopdownButton;
import com.explodingpixels.widgets.PopupMenuCustomizer;
/**
* <p>
* A bar that can contain buttons and pop-down buttons that act on a given {@link SourceList}. This
* control bar is displayed at the base of the {@code SourceList}. The control bar also has a
* draggable widget that can control the divider location of a given {@link JSplitPane}.
* </p>
* <p>
* Heres how to create and install an empty {@code SourceListControlBar}:
* <pre>
* SourceList sourceList = DSourceListITunes.createSourceList();
* SourceListControlBar controlBar = new SourceListControlBar();
* sourceList.installSourceListControlBar(controlBar);
* </pre>
* The above code creates a control bar that looks like this:
* <br><br>
* <img src="../../../../graphics/SourceListControlBar-empty.png">
* </p>
* <p>
* The following code adds two push buttons and a drop-down button to the control bar:
* <pre>
* controlBar.createAndAddPopdownButton(MacIcons.GEAR,
* new PopupMenuCustomizer() {
* public void customizePopup(JPopupMenu popup) {
* popup.removeAll();
* popup.add(new JMenuItem("Item One"));
* popup.add(new JMenuItem("Item Two"));
* popup.add(new JMenuItem("Item Three"));
* }
* });
* </pre>
* The above code creates a control bar that looks like this:
* <br><br>
* <img src="../../../../graphics/SourceListControlBar-buttons.png">
* </p>
*/
public class SourceListControlBar {
private ComponentBottomBar fComponentBottomBar = new ComponentBottomBar();
/**
* Creates a {@code SourceListControlBar}.
*/
public SourceListControlBar() {
init();
}
private void init() {
}
/**
* Connects the draggable widget in this {@code SourceListControlBar} to the divider of the
* given {@link JSplitPane}. Thus when the user drags the {@code SourceListControlBar} draggable
* widget, the given {@code JSplitPane}s divider location will be adjusted.
*
* @param splitPane the {@code JSplitPane} to connect the draggable widget to.
*/
public void installDraggableWidgetOnSplitPane(JSplitPane splitPane) {
fComponentBottomBar.installDraggableWidgetOnSplitPane(splitPane);
}
/**
* Gets the user interface component representing this {@code SourceListControlBar}. The
* returned {@link JComponent} should be added to a container that will be displayed.
*
* @return the user interface component representing this {@code SourceListControlBar}.
*/
public JComponent getComponent() {
return fComponentBottomBar.getComponent();
}
private void addComponent(JComponent component) {
fComponentBottomBar.addComponentToLeftWithBorder(component);
}
/**
* Add a new pop-down style button. The given {@link PopupMenuCustomizer} will be called just
* prior to each showing of the menu.
*
* @param icon the icon to use in the pop-down menu.
* @param popupMenuCustomizer the {@code PopupMenuCustomizer} to be called just prior to showing
* the menu.
*/
public void createAndAddPopdownButton(Icon icon, PopupMenuCustomizer popupMenuCustomizer) {
PopdownButton button = MacButtonFactory.createGradientPopdownButton(
icon, popupMenuCustomizer);
initSourceListButton(button.getComponent());
addComponent(button.getComponent());
}
/**
* Adds a new button with the given icon. The given {@link ActionListener} will be called when
* the button is pressed.
*
* @param icon the icon to use for the button.
* @param actionListener the {@code ActionListener} to call when the button is pressed.
*/
public void createAndAddButton(Icon icon, ActionListener actionListener) {
JComponent button = MacButtonFactory.createGradientButton(icon, actionListener);
initSourceListButton(button);
addComponent(button);
}
private static void initSourceListButton(JComponent component) {
component.setBorder(BorderFactory.createEmptyBorder());
}
/**
* Hides the resize handle.
*/
public void hideResizeHandle() {
fComponentBottomBar.hideResizeHandle();
}
}
| [
"mathieulegoc@gmail.com"
] | mathieulegoc@gmail.com |
1c4f97a9917db89ced11324ec6899c2ed7d83633 | e824dadefcf95282779bd3088fc0c803f524bae1 | /learndemo/src/main/java/learn/题目/other/和式组合数列.java | 350f02febbc71d91cd78f9b2edea3b400872f63d | [] | no_license | dyxcloud/codedemo | 96e99bfbcf049ebc3353a80605daff63033c6923 | fe33d484c5ec366b0329ee07d29c2ed22dc8f5d7 | refs/heads/master | 2023-06-22T18:50:44.885628 | 2022-01-11T08:48:07 | 2022-01-11T08:48:07 | 137,189,478 | 0 | 0 | null | 2022-06-21T02:48:52 | 2018-06-13T08:55:12 | Java | UTF-8 | Java | false | false | 1,152 | java | package learn.题目.other;
import org.junit.jupiter.api.Test;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
@SuppressWarnings("NonAsciiCharacters")
public class 和式组合数列 {
/**
* 给定一个正整数,列出可能的数列其相加和为此整数
* @date 2017年12月17日
*/
ArrayList<List<Integer>> getNumList(int target) {
ArrayList<List<Integer>> list = new ArrayList<>();
if (target <= 0) {
list.add(new ArrayList<>());
return list;
} else if (target == 1) {
list.add(Collections.singletonList(1));
return list;
}
for (int i = target; i > 0; i--) {
ArrayList<List<Integer>> numList = getNumList(target - i);
for (List<Integer> aNumList : numList) {
ArrayList<Integer> startList = new ArrayList<>();
startList.add(i);
if (aNumList.size() != 0 && aNumList.get(0) > i)
continue;
startList.addAll(aNumList);
list.add(startList);
}
}
return list;
}
@Test
public void testget(){
getNumList(10).forEach(System.out::println);
}
}
| [
"dx01@live.cn"
] | dx01@live.cn |
a45b7eb26fdeab1ccc0016002e41a79c34b016d9 | 03b26b63ccbb89ea27bbe3fba797e5716feabd69 | /src/main/java/com/imitation/restaurant/deliveryPerson/model/DeliveryPerson.java | 151f45e471ffd4e1f0813cb8ffe49f79e7a166cb | [] | no_license | neha-yadav/restaurant | 4b90d1a66b0d62b2ab18caeec65b8dc592c7d504 | 4082ee737bf6ab00c76a4df6b2ff5e213100f664 | refs/heads/master | 2022-12-10T22:28:07.874919 | 2020-09-18T18:24:24 | 2020-09-18T18:24:24 | 296,698,692 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,335 | java | package com.imitation.restaurant.deliveryPerson.model;
import com.imitation.restaurant.generic.Model;
import com.imitation.restaurant.order.model.Order;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.OneToMany;
import javax.persistence.Table;
import java.util.List;
@Entity
@Table(name = "delivery_persons")
@Setter
@Getter
@NoArgsConstructor
@AllArgsConstructor
@Builder
public class DeliveryPerson implements Model {
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Long id;
private String name;
private boolean active;
private Status status;
@OneToMany(mappedBy="deliveryPerson" ,fetch = FetchType.LAZY, cascade = CascadeType.ALL)
private List<Order> orders;
public enum Status{
UNASSIGNED("UNASSIGNED"),
ASSIGNED("ASSIGNED"),
FULFILLED("FULFILLED");
private final String value;
Status(String v) {
value = v;
}
}
}
| [
"neyadav@expedia.com"
] | neyadav@expedia.com |
96741aeef8a306106ae4cdaa280be885eab3da88 | eb9f655206c43c12b497c667ba56a0d358b6bc3a | /java/java-tests/testData/codeInsight/daemonCodeAnalyzer/quickFix/sortContent/beforeErrorType.java | 85566ef74ca0b9f88de4086554a1468ee6e28fb9 | [
"Apache-2.0"
] | permissive | JetBrains/intellij-community | 2ed226e200ecc17c037dcddd4a006de56cd43941 | 05dbd4575d01a213f3f4d69aa4968473f2536142 | refs/heads/master | 2023-09-03T17:06:37.560889 | 2023-09-03T11:51:00 | 2023-09-03T12:12:27 | 2,489,216 | 16,288 | 6,635 | Apache-2.0 | 2023-09-12T07:41:58 | 2011-09-30T13:33:05 | null | UTF-8 | Java | false | false | 141 | java | // "Sort content" "false"
import java.util.*;
public class Main {
private void test() {
new Object[] {"foo",<caret> 1, "bar"};
}
}
| [
"Roman.Ivanov@jetbrains.com"
] | Roman.Ivanov@jetbrains.com |
ab42739dd2d9c38e6b47c3cc5f352517fe6e8843 | 691f6afa957ef3e8235faee46d81ab78db882571 | /AndroidQuery/src/com/androidquery/AQuery.java | b1a8127c518a3700d4a9c5def432a949bf5ec9b9 | [] | no_license | sourcebits-praveenkumar/Android_FrameWork | 8ca816116c86cd4f74704dcf366b4ff8f2e6d325 | 1185066852b05a3d7657a01e0c72804b50ebc65b | refs/heads/master | 2016-09-06T00:28:48.236208 | 2013-06-21T13:11:55 | 2013-06-21T13:11:55 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,108 | java | /*
* Copyright 2011 - AndroidQuery.com (tinyeeliu@gmail.com)
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
* in compliance with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software distributed under the License
* is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
* or implied. See the License for the specific language governing permissions and limitations under
* the License.
*/
package com.androidquery;
import android.app.Activity;
import android.content.Context;
import android.view.View;
/**
* The main class of AQuery. All methods are actually inherited from AbstractAQuery.
*
*/
public class AQuery extends AbstractAQuery<AQuery>
{
public AQuery(Activity act)
{
super(act);
}
public AQuery(View view)
{
super(view);
}
public AQuery(Context context)
{
super(context);
}
public AQuery(Activity act, View root)
{
super(act, root);
}
}
| [
"sivashankari@sourcebits.com"
] | sivashankari@sourcebits.com |
25943ede22c3234c0b2e9d8600a0418305bca4b0 | bbb8bacf0e8eac052de398d3e5d75da3ded226d2 | /emulator_dev/src/main/java/gr/codebb/arcadeflex/WIP/v037b7/cpu/konami/konamtbl.java | f3bbd3e85174c07e9a658e3c773bcb811373f726 | [] | no_license | georgemoralis/arcadeflex-037b7-deprecated | f9ab8e08b2e8246c0e982f2cfa7ff73b695b1705 | 0777b9c5328e0dd55e2059795738538fd5c67259 | refs/heads/main | 2023-05-31T06:55:21.979527 | 2021-06-16T17:47:07 | 2021-06-16T17:47:07 | 326,236,655 | 1 | 0 | null | null | null | null | UTF-8 | Java | false | false | 10,942 | java | /*
* ported to v0.37b7
*
*/
package gr.codebb.arcadeflex.WIP.v037b7.cpu.konami;
import static gr.codebb.arcadeflex.WIP.v037b7.cpu.konami.konami.*;
import static gr.codebb.arcadeflex.WIP.v037b7.cpu.konami.konamops.*;
public class konamtbl {
static opcode[] konami_main = {
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* 00 */
opcode2, opcode2, opcode2, opcode2, pshs, pshu, puls, pulu,
lda_im, ldb_im, opcode2, opcode2, adda_im, addb_im, opcode2, opcode2, /* 10 */
adca_im, adcb_im, opcode2, opcode2, suba_im, subb_im, opcode2, opcode2,
sbca_im, sbcb_im, opcode2, opcode2, anda_im, andb_im, opcode2, opcode2, /* 20 */
bita_im, bitb_im, opcode2, opcode2, eora_im, eorb_im, opcode2, opcode2,
ora_im, orb_im, opcode2, opcode2, cmpa_im, cmpb_im, opcode2, opcode2, /* 30 */
setline_im, opcode2, opcode2, opcode2, andcc, orcc, exg, tfr,
ldd_im, opcode2, ldx_im, opcode2, ldy_im, opcode2, ldu_im, opcode2, /* 40 */
lds_im, opcode2, cmpd_im, opcode2, cmpx_im, opcode2, cmpy_im, opcode2,
cmpu_im, opcode2, cmps_im, opcode2, addd_im, opcode2, subd_im, opcode2, /* 50 */
opcode2, opcode2, opcode2, opcode2, opcode2, illegal, illegal, illegal,
bra, bhi, bcc, bne, bvc, bpl, bge, bgt, /* 60 */
lbra, lbhi, lbcc, lbne, lbvc, lbpl, lbge, lbgt,
brn, bls, bcs, beq, bvs, bmi, blt, ble, /* 70 */
lbrn, lbls, lbcs, lbeq, lbvs, lbmi, lblt, lble,
clra, clrb, opcode2, coma, comb, opcode2, nega, negb, /* 80 */
opcode2, inca, incb, opcode2, deca, decb, opcode2, rts,
tsta, tstb, opcode2, lsra, lsrb, opcode2, rora, rorb, /* 90 */
opcode2, asra, asrb, opcode2, asla, aslb, opcode2, rti,
rola, rolb, opcode2, opcode2, opcode2, opcode2, opcode2, opcode2, /* a0 */
opcode2, opcode2, bsr, lbsr, decbjnz, decxjnz, nop, illegal,
abx, daa, sex, mul, lmul, divx, bmove, move, /* b0 */
lsrd, opcode2, rord, opcode2, asrd, opcode2, asld, opcode2,
rold, opcode2, clrd, opcode2, negd, opcode2, incd, opcode2, /* c0 */
decd, opcode2, tstd, opcode2, absa, absb, absd, bset,
bset2, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* d0 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* e0 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* f0 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal
};
static opcode[] konami_indexed = {
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* 00 */
leax, leay, leau, leas, illegal, illegal, illegal, illegal,
illegal, illegal, lda_ix, ldb_ix, illegal, illegal, adda_ix, addb_ix, /* 10 */
illegal, illegal, adca_ix, adcb_ix, illegal, illegal, suba_ix, subb_ix,
illegal, illegal, sbca_ix, sbcb_ix, illegal, illegal, anda_ix, andb_ix, /* 20 */
illegal, illegal, bita_ix, bitb_ix, illegal, illegal, eora_ix, eorb_ix,
illegal, illegal, ora_ix, orb_ix, illegal, illegal, cmpa_ix, cmpb_ix, /* 30 */
illegal, setline_ix, sta_ix, stb_ix, illegal, illegal, illegal, illegal,
illegal, ldd_ix, illegal, ldx_ix, illegal, ldy_ix, illegal, ldu_ix, /* 40 */
illegal, lds_ix, illegal, cmpd_ix, illegal, cmpx_ix, illegal, cmpy_ix,
illegal, cmpu_ix, illegal, cmps_ix, illegal, addd_ix, illegal, subd_ix, /* 50 */
std_ix, stx_ix, sty_ix, stu_ix, sts_ix, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* 60 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* 70 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, clr_ix, illegal, illegal, com_ix, illegal, illegal, /* 80 */
neg_ix, illegal, illegal, inc_ix, illegal, illegal, dec_ix, illegal,
illegal, illegal, tst_ix, illegal, illegal, lsr_ix, illegal, illegal, /* 90 */
ror_ix, illegal, illegal, asr_ix, illegal, illegal, asl_ix, illegal,
illegal, illegal, rol_ix, lsrw_ix, rorw_ix, asrw_ix, aslw_ix, rolw_ix, /* a0 */
jmp_ix, jsr_ix, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* b0 */
illegal, lsrd_ix, illegal, rord_ix, illegal, asrd_ix, illegal, asld_ix,
illegal, rold_ix, illegal, clrw_ix, illegal, negw_ix, illegal, incw_ix, /* c0 */
illegal, decw_ix, illegal, tstw_ix, illegal, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* d0 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* e0 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* f0 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal
};
static opcode[] konami_direct = {
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* 00 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, lda_di, ldb_di, illegal, illegal, adda_di, addb_di, /* 10 */
illegal, illegal, adca_di, adcb_di, illegal, illegal, suba_di, subb_di,
illegal, illegal, sbca_di, sbcb_di, illegal, illegal, anda_di, andb_di, /* 20 */
illegal, illegal, bita_di, bitb_di, illegal, illegal, eora_di, eorb_di,
illegal, illegal, ora_di, orb_di, illegal, illegal, cmpa_di, cmpb_di, /* 30 */
illegal, setline_di, sta_di, stb_di, illegal, illegal, illegal, illegal,
illegal, ldd_di, illegal, ldx_di, illegal, ldy_di, illegal, ldu_di, /* 40 */
illegal, lds_di, illegal, cmpd_di, illegal, cmpx_di, illegal, cmpy_di,
illegal, cmpu_di, illegal, cmps_di, illegal, addd_di, illegal, subd_di, /* 50 */
std_di, stx_di, sty_di, stu_di, sts_di, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* 60 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* 70 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, clr_di, illegal, illegal, com_di, illegal, illegal, /* 80 */
neg_di, illegal, illegal, inc_di, illegal, illegal, dec_di, illegal,
illegal, illegal, tst_di, illegal, illegal, lsr_di, illegal, illegal, /* 90 */
ror_di, illegal, illegal, asr_di, illegal, illegal, asl_di, illegal,
illegal, illegal, rol_di, lsrw_di, rorw_di, asrw_di, aslw_di, rolw_di, /* a0 */
jmp_di, jsr_di, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* b0 */
illegal, lsrd_di, illegal, rord_di, illegal, asrd_di, illegal, asld_di,
illegal, rold_di, illegal, clrw_di, illegal, negw_di, illegal, incw_di, /* c0 */
illegal, decw_di, illegal, tstw_di, illegal, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* d0 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* e0 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* f0 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal
};
static opcode[] konami_extended = {
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* 00 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, lda_ex, ldb_ex, illegal, illegal, adda_ex, addb_ex, /* 10 */
illegal, illegal, adca_ex, adcb_ex, illegal, illegal, suba_ex, subb_ex,
illegal, illegal, sbca_ex, sbcb_ex, illegal, illegal, anda_ex, andb_ex, /* 20 */
illegal, illegal, bita_ex, bitb_ex, illegal, illegal, eora_ex, eorb_ex,
illegal, illegal, ora_ex, orb_ex, illegal, illegal, cmpa_ex, cmpb_ex, /* 30 */
illegal, setline_ex, sta_ex, stb_ex, illegal, illegal, illegal, illegal,
illegal, ldd_ex, illegal, ldx_ex, illegal, ldy_ex, illegal, ldu_ex, /* 40 */
illegal, lds_ex, illegal, cmpd_ex, illegal, cmpx_ex, illegal, cmpy_ex,
illegal, cmpu_ex, illegal, cmps_ex, illegal, addd_ex, illegal, subd_ex, /* 50 */
std_ex, stx_ex, sty_ex, stu_ex, sts_ex, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* 60 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* 70 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, clr_ex, illegal, illegal, com_ex, illegal, illegal, /* 80 */
neg_ex, illegal, illegal, inc_ex, illegal, illegal, dec_ex, illegal,
illegal, illegal, tst_ex, illegal, illegal, lsr_ex, illegal, illegal, /* 90 */
ror_ex, illegal, illegal, asr_ex, illegal, illegal, asl_ex, illegal,
illegal, illegal, rol_ex, lsrw_ex, rorw_ex, asrw_ex, aslw_ex, rolw_ex, /* a0 */
jmp_ex, jsr_ex, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* b0 */
illegal, lsrd_ex, illegal, rord_ex, illegal, asrd_ex, illegal, asld_ex,
illegal, rold_ex, illegal, clrw_ex, illegal, negw_ex, illegal, incw_ex, /* c0 */
illegal, decw_ex, illegal, tstw_ex, illegal, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* d0 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* e0 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal,
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal, /* f0 */
illegal, illegal, illegal, illegal, illegal, illegal, illegal, illegal
};
public abstract interface opcode {
public abstract void handler();
}
}
| [
"giorgosmrls@gmail.com"
] | giorgosmrls@gmail.com |
66842d8fd8a7098faae0041f9af232233be10497 | 8504a8e44fd8e1c6218963726aa7b73b01be2ca6 | /restServiceExample/src/main/java/de/iso/restserviceexample/RestService.java | b0bd4c1325d1542ce27c0d2b1dbcc0e2921ceed5 | [] | no_license | ivosoa/webapptesting | eb5641bca533acf036b918721fec2cc0160394e6 | 025574cc75da7e58e1605796a8257c830fd64814 | refs/heads/master | 2021-01-15T12:19:24.751526 | 2014-08-28T16:50:04 | 2014-08-28T16:50:04 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 361 | java | package de.iso.restserviceexample;
import de.iso.restserviceexample.rest.HelloService;
import javax.ws.rs.ApplicationPath;
import org.glassfish.jersey.server.ResourceConfig;
/**
*
* @author Ivo
*/
@ApplicationPath("rest")
public class RestService extends ResourceConfig{
public RestService() {
register(HelloService.class);
}
}
| [
"Ivo@Ivo-PC.localdomain"
] | Ivo@Ivo-PC.localdomain |
4b65ad8a079d673e1580fccef7e633658ba0649f | a04e7fa78a8087987c09816968793b97d4f788da | /hw05-0036493852/src/test/java/hr/fer/zemris/java/custom/scripting/exec/ObjectMultistackTest.java | 479867ecaa5c83cf76719f468b2afd0b1905e5cf | [] | no_license | frankocar/OPJJ-FER | cb348888ac2aef33e7e136f342c543f5cdbd6374 | 5ee357a0bd543f94715d07b33aa4e72bab30f419 | refs/heads/master | 2021-05-07T07:21:42.962121 | 2017-11-01T10:53:12 | 2017-11-01T10:53:12 | 109,117,554 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 5,938 | java | package hr.fer.zemris.java.custom.scripting.exec;
import static org.junit.Assert.*;
import java.util.EmptyStackException;
import org.junit.Test;
public class ObjectMultistackTest {
private static final double DELTA = 1E-6;
@Test
public void test() {
ObjectMultistack stack = new ObjectMultistack();
stack.push("Numbers", new ValueWrapper(1));
assertEquals(false, stack.isEmpty("Numbers"));
assertEquals(true, stack.isEmpty("Letters"));
assertEquals(Integer.valueOf(1), (Integer) stack.peek("Numbers").getValue());
assertEquals(false, stack.isEmpty("Numbers"));
assertEquals(Integer.valueOf(1), (Integer) stack.pop("Numbers").getValue());
assertEquals(true, stack.isEmpty("Numbers"));
for (int i = 1; i <= 5; i++) {
stack.push("Numbers", new ValueWrapper(i));
}
for (int i = 5; i >= 1; i--) {
assertEquals(Integer.valueOf(i), stack.pop("Numbers").getValue());
}
}
@Test(expected=EmptyStackException.class)
public void emptyStackPop() {
ObjectMultistack stack = new ObjectMultistack();
stack.pop("Hello?");
}
@Test(expected=EmptyStackException.class)
public void emptyStackPeek() {
ObjectMultistack stack = new ObjectMultistack();
stack.peek("Hello?");
}
@Test(expected=IllegalArgumentException.class)
public void addNullName() {
ObjectMultistack stack = new ObjectMultistack();
stack.push(null, new ValueWrapper(1));
}
@Test(expected=IllegalArgumentException.class)
public void addNullValue() {
ObjectMultistack stack = new ObjectMultistack();
stack.push("Name", null);
}
@Test
public void additionTest() {
ObjectMultistack stack = new ObjectMultistack();
stack.push("Numbers", new ValueWrapper(12));
stack.push("Numbers", new ValueWrapper(8));
ValueWrapper number = stack.pop("Numbers");
stack.peek("Numbers").add(number.getValue());
assertEquals(Integer.valueOf(20), (Integer) stack.pop("Numbers").getValue());
assertEquals(true, stack.isEmpty("Numbers"));
}
@Test
public void subtractionTest() {
ObjectMultistack stack = new ObjectMultistack();
stack.push("Numbers", new ValueWrapper(12));
stack.push("Numbers", new ValueWrapper(8));
ValueWrapper number = stack.pop("Numbers");
stack.peek("Numbers").subtract(number.getValue());
assertEquals(Integer.valueOf(4), (Integer) stack.pop("Numbers").getValue());
assertEquals(true, stack.isEmpty("Numbers"));
}
@Test
public void multiplicationTest() {
ObjectMultistack stack = new ObjectMultistack();
stack.push("Numbers", new ValueWrapper(12));
stack.push("Numbers", new ValueWrapper(4));
ValueWrapper number = stack.pop("Numbers");
stack.peek("Numbers").multiply(number.getValue());
assertEquals(Integer.valueOf(48), (Integer) stack.pop("Numbers").getValue());
assertEquals(true, stack.isEmpty("Numbers"));
stack.push("Numbers", new ValueWrapper(12.2));
stack.push("Numbers", new ValueWrapper("4"));
number = stack.pop("Numbers");
stack.peek("Numbers").multiply(number.getValue());
assertEquals(48.8, (Double) stack.pop("Numbers").getValue(), DELTA);
assertEquals(true, stack.isEmpty("Numbers"));
}
@Test
public void divisionTest() {
ObjectMultistack stack = new ObjectMultistack();
stack.push("Numbers", new ValueWrapper(12));
stack.push("Numbers", new ValueWrapper(4));
ValueWrapper number = stack.pop("Numbers");
stack.peek("Numbers").divide(number.getValue());
assertEquals(Integer.valueOf(3), (Integer) stack.pop("Numbers").getValue());
assertEquals(true, stack.isEmpty("Numbers"));
}
@Test(expected=IllegalArgumentException.class)
public void divisionWithZeroTest() {
ObjectMultistack stack = new ObjectMultistack();
stack.push("Numbers", new ValueWrapper(12));
stack.push("Numbers", new ValueWrapper(null));
ValueWrapper number = stack.pop("Numbers");
stack.peek("Numbers").divide(number.getValue());
}
@Test
public void nullAdditionTest() {
ObjectMultistack stack = new ObjectMultistack();
stack.push("Numbers", new ValueWrapper(null));
stack.push("Numbers", new ValueWrapper(8));
ValueWrapper number = stack.pop("Numbers");
stack.peek("Numbers").add(number.getValue());
assertEquals(Integer.valueOf(8), (Integer) stack.pop("Numbers").getValue());
assertEquals(true, stack.isEmpty("Numbers"));
}
@Test
public void multiipleStacks() {
ObjectMultistack stack = new ObjectMultistack();
stack.push("First", new ValueWrapper(null));
stack.push("Second", new ValueWrapper(8));
stack.peek("First").add(stack.pop("Second").getValue());
assertEquals(Integer.valueOf(8), (Integer) stack.peek("First").getValue());
assertEquals(true, stack.isEmpty("Second"));
assertEquals(false, stack.isEmpty("First"));
}
@Test
public void givenExample() {
ObjectMultistack stack = new ObjectMultistack();
ValueWrapper year = new ValueWrapper(Integer.valueOf(2000));
stack.push("year", year);
assertEquals(Integer.valueOf(2000), (Integer) stack.peek("year").getValue());
ValueWrapper price = new ValueWrapper(200.51);
stack.push("price", price);
assertEquals(200.51, (Double) stack.peek("price").getValue(), DELTA);
stack.push("year", new ValueWrapper(Integer.valueOf(1900)));
assertEquals(Integer.valueOf(1900), (Integer) stack.peek("year").getValue());
stack.peek("year").setValue(((Integer) stack.peek("year").getValue()).intValue() + 50);
assertEquals(Integer.valueOf(1950), (Integer) stack.peek("year").getValue());
stack.pop("year");
assertEquals(Integer.valueOf(2000), (Integer) stack.peek("year").getValue());
stack.peek("year").add("5");
assertEquals(Integer.valueOf(2005), (Integer) stack.peek("year").getValue());
stack.peek("year").add(5);
assertEquals(Integer.valueOf(2010), (Integer) stack.peek("year").getValue());
stack.peek("year").add(5.0);
assertEquals(2015.0, (Double) stack.peek("year").getValue(), DELTA);
}
}
| [
"franko.car@fer.hr"
] | franko.car@fer.hr |
44981ee49f4c00664ef67581b9907728fd8513b9 | 599b2e80237f007507263bbb83617a052c1f91be | /leech-gwt-ui/src/main/java/com/voole/leech/gwt/util/TestSub2.java | 5fee8d4bbbe4089824aa246f05a161e367f8cab0 | [] | no_license | wowcinder/leech | 0d5a27926b7f4502720928f0425d68278f5f9bcd | 8101ccdc53f59f33fafb93ff3aad97efb8adf0e2 | refs/heads/master | 2016-09-16T03:05:53.370063 | 2013-11-27T06:18:07 | 2013-11-27T06:18:07 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 227 | java | /*
* Copyright (C) 2013 BEIJING UNION VOOLE TECHNOLOGY CO., LTD
*/
package com.voole.leech.gwt.util;
/**
* @author XuehuiHe
* @date 2013年9月29日
*/
public class TestSub2 extends TestSub<Float, Integer> {
}
| [
"xuehuihe.java@gmail.com"
] | xuehuihe.java@gmail.com |
2a3f4234e358aab6eb03a6ee71c9cefe1204266a | 1837ffdb81ec4c4d5c9fe72df8da9a691f0772d0 | /app/src/androidTest/java/ir/sample/sqlitesample/ExampleInstrumentedTest.java | bfe29824f11bc2f246c2efb431b6a065ea2a6796 | [] | no_license | esmaeil-ahmadipour/Android_SQLITE | e5a21ac041c8fdc11a374201fef8119aca2b035d | bec5facf38b20e5d8907aca5cb63e0afc0e318c7 | refs/heads/master | 2020-11-27T22:29:30.655459 | 2019-12-23T17:25:45 | 2019-12-23T17:25:45 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 760 | java | package ir.sample.sqlitesample;
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("ir.sample.sqlitesample", appContext.getPackageName());
}
}
| [
"software8686@gmail.com"
] | software8686@gmail.com |
5d7bf6ace6429dea4110221925d59b6d1a4f1e25 | 00c460ae1d9c632fa1adc5a63e92bbda0b4e3458 | /src/main/java/com/boe/utils/RequestResult.java | a4a173a35e89727adb0705ce728db7a661bf2c5e | [] | no_license | MengQingming/boe-emp | e17962544d930e0242664c533b8bbae103ee4fff | 88258f0b778288cea6b139705b499cc0c985e803 | refs/heads/master | 2021-01-23T04:34:39.025032 | 2017-09-05T07:34:25 | 2017-09-05T07:34:25 | 102,448,816 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 542 | java | package com.boe.utils;
/**
* 返回结果信息
* @author alvin
*
*/
public class RequestResult {
String status;//状态
String statusCode;//错误代码
String msg;//消息
public String getStatus() {
return status;
}
public void setStatus(String status) {
this.status = status;
}
public String getStatusCode() {
return statusCode;
}
public void setStatusCode(String errorCode) {
this.statusCode = errorCode;
}
public String getMsg() {
return msg;
}
public void setMsg(String msg) {
this.msg = msg;
}
}
| [
"myisdeveloper@163.com"
] | myisdeveloper@163.com |
f375ef7d20c6f7334953f997c9981b33fb542177 | a16b2a58625081530c089568e2b29f74e23f95a9 | /doolin/Doolin-Application/src/main/java/net/sf/doolin/gui/field/support/swing/SwingMultipleSelectionSupport.java | 710191df089e79d9f659426cdbb9f9311dba3b5e | [] | no_license | dcoraboeuf/orbe | 440335b109dee2ee3db9ee2ab38430783e7a3dfb | dae644da030e5a5461df68936fea43f2f31271dd | refs/heads/master | 2022-01-27T10:18:43.222802 | 2022-01-01T11:45:35 | 2022-01-01T11:45:35 | 178,600,867 | 0 | 0 | null | 2022-01-01T11:46:01 | 2019-03-30T19:13:13 | Java | UTF-8 | Java | false | false | 1,774 | java | /*
* Created on Aug 7, 2007
*/
package net.sf.doolin.gui.field.support.swing;
import java.util.List;
import net.sf.doolin.gui.field.FieldMultipleSelection;
import net.sf.doolin.gui.field.event.EventAction;
import net.sf.doolin.gui.field.support.MultipleSelectionSupport;
import net.sf.doolin.gui.swing.select.SelectableList;
import net.sf.doolin.gui.swing.select.SelectedEvent;
import net.sf.doolin.gui.swing.select.SelectedEventListener;
/**
* Support for the <code>{@link FieldMultipleSelection}</code> based on a
* <code>{@link SelectableList}</code>.
*
* @author Damien Coraboeuf
* @version $Id: SwingMultipleSelectionSupport.java,v 1.1 2007/08/07 16:47:05 guinnessman Exp $
* @param <T>
* Type of item
*/
public class SwingMultipleSelectionSupport<T> extends AbstractSwingInfoFieldSupport<FieldMultipleSelection, SelectableList<T>> implements MultipleSelectionSupport<T> {
private SelectableList<T> list;
@Override
protected SelectableList<T> createComponent() {
list = new SelectableList<T>();
list.setLabelProvider(getField().getLabelProvider());
list.setVisibleRows(getField().getVisibleRows());
// List of items
@SuppressWarnings("unchecked")
List<T> items = getField().getItemProvider().getItems();
list.setItems(items);
return list;
}
public void setItems(List<T> items) {
list.setItems(items);
}
public List<T> getSelection() {
return list.getSelectedItems();
}
public void setSelection(List<T> collection) {
list.setSelectedItems(collection);
}
public void bindEditEvent(final EventAction eventAction) {
list.addSelectedEventListener(new SelectedEventListener() {
public void itemSelected(SelectedEvent event) {
eventAction.execute(getView(), getField(), null);
}
});
}
}
| [
"damien.coraboeuf@gmail.com"
] | damien.coraboeuf@gmail.com |
41f266db8c7e34b62ed48b6fb0044852e3ff9feb | e9bb69a5c398830b165fbdfa77f53cd5426bc86c | /beispiele/03-2-hk2-extras/src/main/java/com/innoq/hk2_extras/config/MyBean.java | 91536bc1c76fa1c0fbe410e149315d19c6f4308a | [] | no_license | innoq/hk2-jersey-workshop | 04d205c4446b194f685261b3df131ce6d439cc19 | 861b079a8f4b39b79e3d6877f79fed00b565296d | refs/heads/main | 2022-12-22T01:37:55.769118 | 2020-09-20T12:11:58 | 2020-09-21T16:27:40 | 289,687,372 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 399 | java | package com.innoq.hk2_extras.config;
public class MyBean {
private int number;
private String text;
public int getNumber() {
return number;
}
public void setNumber(int number) {
this.number = number;
}
public String getText() {
return text;
}
public void setText(String text) {
this.text = text;
}
}
| [
"stefan.bodewig@innoq.com"
] | stefan.bodewig@innoq.com |
3850b6f849eba3f53825479816cb29cc68bc2687 | 508fdd3e7fa40ce8e637fad676bfff01ff4304d6 | /ticTacToe/Play.java | 9ef7e2a754113c11d2710668936e8cb602b39f9e | [] | no_license | Hippoglyph/GameSolver | f9353452bb6fa41b1ab37d1b1cb018a328a372cf | eca6cee899eb55a039df08aa1dc1328ac98ebe55 | refs/heads/master | 2023-03-18T00:42:01.633119 | 2021-03-13T20:04:42 | 2021-03-13T20:04:42 | 308,984,908 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 178 | java | package ticTacToe;
import game.Game;
public class Play {
public static void main(String[] args) {
new Game(Boolean.valueOf(args[0]), new TicTacToeState(0L), 450, 450);
}
}
| [
"rinnarv@kth.se"
] | rinnarv@kth.se |
23d18b8545aecfb602538252f33bd808e0c234c8 | b99ca4c0eda7f2b5703e4402dd958e75f49a8223 | /src/main/java/pl/com/app/myflat/controllers/LoginController.java | 3deb3a6b934c492af63f20925b14774f493b87b6 | [] | no_license | PawelMachos/MyFlat | 69d4941ec9b63d539ea6fe1fa3cd64c0ccd6ee8f | 1fa2e07059d877cd83b307bbec2b2222ccd5cf2c | refs/heads/master | 2021-01-04T17:14:21.254229 | 2020-02-29T11:53:32 | 2020-02-29T11:53:32 | 240,679,902 | 0 | 1 | null | null | null | null | UTF-8 | Java | false | false | 391 | java | package pl.com.app.myflat.controllers;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
@Controller
@RequestMapping("/login")
public class LoginController {
@GetMapping
public String prepareLoginPage() {
return "login-page";
}
}
| [
"marta.m.przybylo@gmail.com"
] | marta.m.przybylo@gmail.com |
2d6c7c2d69ee23988fbed381955ec68d3c7320a2 | dd3373d4f4b4e6a025d8445cd5391f1e6f9618f7 | /betterme-framework/betterme-framework-api/src/main/java/com/lgfei/betterme/framework/api/controller/BaseController.java | 692b9cb71df5147bc56bfb940e197aea5e02b73c | [] | no_license | koko8566/betterme | ccc4f59f04fd2d0644f5254754ea6838328bf6b8 | d361c66b914e464053f82cf05cb476e1bd2db07c | refs/heads/master | 2020-05-22T02:38:38.080291 | 2019-04-19T17:28:26 | 2019-04-19T17:28:26 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 4,226 | java | package com.lgfei.betterme.framework.api.controller;
import java.util.ArrayList;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import com.lgfei.betterme.framework.api.IBaseController;
import com.lgfei.betterme.framework.core.manager.IBaseManager;
import com.lgfei.betterme.framework.model.constants.NumberPool;
import com.lgfei.betterme.framework.model.entity.BaseEntity;
import com.lgfei.betterme.framework.model.vo.BatchDatasVO;
import com.lgfei.betterme.framework.model.vo.PageResultVO;
import com.lgfei.betterme.framework.model.vo.PageVO;
import com.lgfei.betterme.framework.model.vo.ResultVO;
public abstract class BaseController<MG extends IBaseManager<T, K>, T extends BaseEntity<K>, K>
implements IBaseController<T, K>
{
@Autowired
protected MG manager;
@Override
public IBaseManager<T, K> getManager()
{
return manager;
}
@Override
public boolean preHandle(T entity, String params)
{
return true;
}
@Override
public Integer selectCount(T entity, String params)
{
boolean flag = preHandle(entity, params);
if (flag)
{
return getManager().selectCount(entity, params);
}
return NumberPool.ZERO;
}
@Override
public PageResultVO<T> selectPage(T entity, PageVO page, String params)
{
boolean flag = preHandle(entity, params);
if (flag)
{
return getManager().selectPage(entity, page, params);
}
return new PageResultVO<>();
}
@Override
public List<T> select(T entity, String params)
{
boolean flag = preHandle(entity, params);
if (flag)
{
return getManager().select(entity, params);
}
return new ArrayList<>();
}
@Override
public T selectOne(T entity, String params)
{
boolean flag = preHandle(entity, params);
if (flag)
{
return getManager().selectOne(entity, params);
}
return null;
}
@Override
public ResultVO<T> save(T entity, String params)
{
boolean flag = preHandle(entity, params);
if (flag)
{
return getManager().save(entity, params);
}
return new ResultVO.Builder<T>().err();
}
@Override
public ResultVO<T> saveOrUpdate(T entity, String params)
{
boolean flag = preHandle(entity, params);
if (flag)
{
return getManager().saveOrUpdate(entity, params);
}
return new ResultVO.Builder<T>().err();
}
@Override
public ResultVO<T> update(T entity, String params)
{
boolean flag = preHandle(entity, params);
if (flag)
{
return getManager().update(entity, params);
}
return new ResultVO.Builder<T>().err();
}
@Override
public ResultVO<T> remove(T entity, String params)
{
boolean flag = preHandle(entity, params);
if (flag)
{
return getManager().remove(entity, params);
}
return new ResultVO.Builder<T>().err();
}
@Override
public ResultVO<T> batchSave(@RequestBody BatchDatasVO<T> datas, String params)
{
return getManager().batchSave(datas, params);
}
/*@RequestMapping(value = "/", method = RequestMethod.GET)
public String getTemplate()
{
RequestMapping requestMapping = this.getClass().getAnnotation(RequestMapping.class);
if (null == requestMapping)
{
return "index";
}
String[] values = requestMapping.value();
if (null == values || values.length == MyNumbers.ZERO)
{
return "index";
}
String module = values[0];
if (null == module || module.length() == MyNumbers.ZERO)
{
return "index";
}
if (module.startsWith("/"))
{
module = module.substring(MyNumbers.ONE);
}
return new StringBuilder(module).append("/index").toString();
}*/
}
| [
"longuofei@163.com"
] | longuofei@163.com |
aa6b6b02a6d70e3bbb473cf2c48594b04fcaf79f | af972900480f5ef6e537126bc0ccfd27bbb9d336 | /src/java/SentenceComparator.java | 5f2c352d76218ae297b1e7594e776e1c8eb7fc23 | [] | no_license | AbdEl-Hamid-Nasef/GP | 906d9285d4c2acfad7b7d203efc06f8fbf7e060d | 316ea5fcbc9d2c0a1ed40ca7c6fb1ec41d3e3f7e | refs/heads/master | 2023-02-26T11:54:47.643111 | 2021-02-07T17:55:37 | 2021-02-07T17:55:37 | 336,850,898 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 279 | java |
import java.util.Comparator;
class SentenceComparator implements Comparator<Sentence>{
@Override
public int compare(Sentence obj1, Sentence obj2) {
if(obj1.score > obj2.score){
return -1;
}else if(obj1.score < obj2.score){
return 1;
}else{
return 0;
}
}
}
| [
"77011650+AbdEl-Hamid-Nasef@users.noreply.github.com"
] | 77011650+AbdEl-Hamid-Nasef@users.noreply.github.com |
8777acedc14d7cd5474520791bb885abea165748 | 9bcad2911a080560d42fa76179a0f904eab49bff | /app/src/main/java/com/example/credittask2/GlobalVariables.java | 10bed3761329cd855afb2c61c0b357e705f99ce6 | [] | no_license | yungts97/CreditTask2 | c140cadaeca79724c3536e7be10ad2d777ca9769 | b09e41dfc42a07cda050712020b20633f308d65b | refs/heads/master | 2020-09-13T02:56:48.067313 | 2019-11-20T09:44:49 | 2019-11-20T09:44:49 | 222,637,902 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 365 | java | package com.example.credittask2;
import java.util.ArrayList;
public class GlobalVariables {
public static final String MOVIE_KEY = "movie_key";
public static ArrayList<Movie> showingMovies = new ArrayList<>();
public static ArrayList<Movie> upcomingMovies = new ArrayList<>();
public static ArrayList<Movie> watchListMovies = new ArrayList<>();
}
| [
"yungts97@gmail.com"
] | yungts97@gmail.com |
1ffe8b7f5b1deb274d78044653ffca7001dcdbe3 | 025d7aed9f7b5a2829c97fcbf387b2c47043516d | /src/club/ActListServlet.java | f17ffcd1bb486c872275e3bec5302bf5372f6fa7 | [] | no_license | LZ0616/ECLUBS | 71ff157ec205931093486629f014c85fdd86ec12 | c17e83c4857e05ec6dfc297cdd2d30f5dac5c1e1 | refs/heads/master | 2020-06-24T09:16:55.018036 | 2019-07-26T09:02:33 | 2019-07-26T09:18:39 | 198,926,567 | 0 | 0 | null | null | null | null | GB18030 | Java | false | false | 2,741 | java | package club;
import java.io.IOException;
import java.sql.Connection;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.sql.Statement;
import java.util.ArrayList;
import java.util.List;
import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;
import exper.DBHelper;
/**
* Servlet implementation class ActListServlet
*/
@WebServlet("/ActListServlet")
public class ActListServlet extends HttpServlet {
private static final long serialVersionUID = 1L;
String identity;
/**
* @see HttpServlet#HttpServlet()
*/
public ActListServlet() {
super();
// TODO Auto-generated constructor stub
}
/**
* @see HttpServlet#doGet(HttpServletRequest request, HttpServletResponse response)
*/
protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
// TODO Auto-generated method stub
request.setCharacterEncoding("utf-8");
HttpSession session = request.getSession(true);
identity=(String)session.getAttribute("identity");
try {
Connection myconn = new DBHelper().getConn();
if(myconn!=null){
System.out.println("数据库连接成功!");
}else{
System.out.println("数据库连接失败!");
}
Statement stmt = myconn.createStatement();
String sql = "select * from club_activity";
ResultSet rs = stmt.executeQuery(sql);
List<ActListBean> list = new ArrayList<>();
while(rs.next()){
ActListBean actl = new ActListBean();
actl.setId(rs.getInt("id"));
actl.setTitle(rs.getString("title"));
actl.setCname(rs.getString("cname"));
actl.setTime(rs.getString("time"));
actl.setMaster(rs.getString("master"));
actl.setContent(rs.getString("content"));
actl.setFilename(rs.getString("filename"));
list.add(actl);
}
request.setAttribute("list", list);
rs.close();
stmt.close();
myconn.close();
}catch (SQLException e) {
e.printStackTrace();
}
if(identity=="学生"){
System.out.println(identity);
request.getRequestDispatcher("ListAct_stu.jsp").forward(request, response);
}
else if(identity=="管理"){
System.out.println(identity);
request.getRequestDispatcher("ListAct_admin.jsp").forward(request, response);
}
}
/**
* @see HttpServlet#doPost(HttpServletRequest request, HttpServletResponse response)
*/
protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
}
}
| [
"740562234@qq.com"
] | 740562234@qq.com |
eff5e72d57d4379c16e9e94a130aad77cc1dbb76 | 3f0015de89c8b0cd48ae203f35f395b2316dee28 | /src/com/apiclient/vo/SynthesisCuttingToolConfigVO.java | 0c83e46d3324dbb87bd1754da0ae83fc661cd5da | [] | no_license | looooogan/icomp-4gb-pda | f8bf25c2ff20594ef802993ec708b66a8068d3dc | 87f773b746485883f4839d646700a21d05c54d4f | refs/heads/master | 2020-03-21T03:12:04.271544 | 2018-06-20T14:21:13 | 2018-06-20T14:21:13 | 133,898,130 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 5,742 | java | package com.apiclient.vo;
import java.io.Serializable;
import java.util.List;
/**
* Created by jiangchenkeji
* Automated Build
* 实体 SynthesisCuttingToolConfigVO
*/
public class SynthesisCuttingToolConfigVO implements Serializable {
// 序列化接口属性
private static final long serialVersionUID = 1L;
/**
* @fieldName id
* @fieldType Integer
* @Description 标识
*/
private Integer id;
/**
* @fieldName synthesisCuttingToolCode
* @fieldType String
* @Description 合成刀编码
*/
private String synthesisCuttingToolCode;
/**
* @fieldName synthesisCuttingToolTypeId
* @fieldType Integer
* @Description 合成刀类型 1复合刀具 2刀片 3热套 4一体刀 5
*/
private Integer synthesisCuttingToolTypeId;
/**
* @fieldName isDel
* @fieldType Integer
* @Description 逻辑删除
*/
private Integer isDel;
/**
* @fieldName count
* @fieldType Integer
* @Description 数量
*/
private Integer count;
/**
* @fieldName picurl
* @fieldType String
* @Description 图纸url
*/
private String picurl;
/**
* @fieldName location
* @fieldType Integer
* @Description 位置
*/
private Integer location;
/**
* @fieldName synthesisCuttingToolCode
* @fieldType
* @Description 合成刀编码
*/
private SynthesisCuttingToolVO synthesisCuttingToolVO;
/**
* @fieldName synthesisCuttingToolTypeId
* @fieldType
* @Description 合成刀类型 1复合刀具 2刀片 3热套 4一体刀 5
*/
private SynthesisCuttingToolTypeVO synthesisCuttingToolTypeVO;
private List<SynthesisCuttingToolLocationConfigVO> synthesisCuttingToolLocationConfigVOList;
/**
* @fieldName currentPage
* @fieldType Integer
* @Description 当前页码
*/
private Integer currentPage = 1;
/**
* @fieldName totalPage
* @fieldType Integer
* @Description 总页数
*/
private Integer totalPage;
/**
* @fieldName pageSize
* @fieldType Integer
* @Description 每页记录条数
*/
private Integer pageSize = 10;
/**
* @fieldName maxPage
* @fieldType Integer
* @Description 总页数
*/
private Integer maxPage;
/**
* @fieldName startRecord
* @fieldType Integer
* @Description 开始查询记录
*/
private Integer startRecord;
/* 标识 */
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
public String getSynthesisCuttingToolCode() {
return synthesisCuttingToolCode;
}
public void setSynthesisCuttingToolCode(String synthesisCuttingToolCode) {
this.synthesisCuttingToolCode = synthesisCuttingToolCode;
}
public Integer getSynthesisCuttingToolTypeId() {
return synthesisCuttingToolTypeId;
}
public void setSynthesisCuttingToolTypeId(Integer synthesisCuttingToolTypeId) {
this.synthesisCuttingToolTypeId = synthesisCuttingToolTypeId;
}
public Integer getIsDel() {
return isDel;
}
public void setIsDel(Integer isDel) {
this.isDel = isDel;
}
public Integer getCount() {
return count;
}
public void setCount(Integer count) {
this.count = count;
}
public String getPicurl() {
return picurl;
}
public void setPicurl(String picurl) {
this.picurl = picurl;
}
public Integer getLocation() {
return location;
}
public void setLocation(Integer location) {
this.location = location;
}
public SynthesisCuttingToolVO getSynthesisCuttingToolVO() {
return synthesisCuttingToolVO;
}
public void setSynthesisCuttingToolVO(SynthesisCuttingToolVO synthesisCuttingToolVO) {
this.synthesisCuttingToolVO = synthesisCuttingToolVO;
}
public SynthesisCuttingToolTypeVO getSynthesisCuttingToolTypeVO() {
return synthesisCuttingToolTypeVO;
}
public void setSynthesisCuttingToolTypeVO(SynthesisCuttingToolTypeVO synthesisCuttingToolTypeVO) {
this.synthesisCuttingToolTypeVO = synthesisCuttingToolTypeVO;
}
public List<SynthesisCuttingToolLocationConfigVO> getSynthesisCuttingToolLocationConfigVOList() {
return synthesisCuttingToolLocationConfigVOList;
}
public void setSynthesisCuttingToolLocationConfigVOList(List<SynthesisCuttingToolLocationConfigVO> synthesisCuttingToolLocationConfigVOList) {
this.synthesisCuttingToolLocationConfigVOList = synthesisCuttingToolLocationConfigVOList;
}
public Integer getCurrentPage() {
return currentPage;
}
public void setCurrentPage(Integer currentPage) {
this.currentPage = currentPage;
this.startRecord = (this.currentPage-1)*pageSize;
}
public Integer getTotalPage() {
return totalPage;
}
public void setTotalPage(Integer totalPage) {
this.totalPage = totalPage;
this.maxPage = this.totalPage/this.pageSize+(this.totalPage%this.pageSize)>0?1:0;
}
public Integer getPageSize() {
return pageSize;
}
public void setPageSize(Integer pageSize) {
this.pageSize = pageSize;
}
public Integer getStartRecord() {
return startRecord;
}
public void setStartRecord(Integer startRecord) {
this.startRecord = startRecord;
}
public Integer getMaxPage() {
return maxPage;
}
public void setMaxPage(Integer maxPage) {
this.maxPage = maxPage;
}
}
| [
"logan.box2016@gmail.com"
] | logan.box2016@gmail.com |
46634577825876a899472d10c9a6b532e84fb99b | 1322571bc77e65c3ad0897220eb7d42ac801c6bd | /app/src/main/java/ca/uottawa/finalproject/recipe/DatabaseHelper.java | 80fffa9706c1d9282faffe106f28596f61dcf20f | [] | no_license | SaeidPouramini/FinalProject | 3b632570300135e5a881122bb7a584de7486c5b7 | bc1226d2f543d2997a03a44d1cdc08740a4e4e4b | refs/heads/master | 2023-02-02T19:38:17.396152 | 2020-12-10T22:02:34 | 2020-12-10T22:02:34 | 314,412,851 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,935 | java | package ca.uottawa.finalproject.recipe;
import android.content.ContentValues;
import android.content.Context;
import android.database.Cursor;
import android.database.sqlite.SQLiteDatabase;
import android.database.sqlite.SQLiteOpenHelper;
import java.util.ArrayList;
public class DatabaseHelper extends SQLiteOpenHelper {
public static String DB_NAME = "receipepage";
public static int DB_VERSION = 1;
public DatabaseHelper(Context context) {
super(context, DB_NAME, null, DB_VERSION);
}
@Override
public void onCreate(SQLiteDatabase sqLiteDatabase) {
String query="CREATE TABLE history (historyID int primary key,address varchar(255))";
sqLiteDatabase.execSQL(query);
}
public long addHistory(String address) {
SQLiteDatabase db = this.getWritableDatabase();
ContentValues values = new ContentValues();
values.put("address", address);
return db.insert("history", null, values);
}
public long addFavorite(ProductModel favorite){
SQLiteDatabase db = this.getWritableDatabase();
ContentValues values = new ContentValues();
values.put("favorite","'"+favorite.getHref()+","+favorite.getTitle()+","+favorite.getIngredients()+","+favorite.getThumbnail()+"'");
return db.insert("favorite",null,values);
}
public long deleteHistory(String address){
SQLiteDatabase db = this.getWritableDatabase();
return db.delete("history","address='"+address+"'",null);
}
public ArrayList<String> getAllHistory() {
SQLiteDatabase db = this.getReadableDatabase();
ArrayList<String> listItems = new ArrayList<String>();
Cursor cursor = db.rawQuery("SELECT * from history",new String[] {});
if (cursor.moveToFirst()) {
do {
String image = cursor.getString(1);
listItems.add(image);
} while (cursor.moveToNext());
}
cursor.close();
return listItems;
}
@Override
public void onUpgrade(SQLiteDatabase arg0, int arg1, int arg2) {
// TODO Auto-generated method stub
}
} | [
"ferd0025@algonquinlive.com"
] | ferd0025@algonquinlive.com |
729e4a525dadedc4ecf881abfe7ac5ebe0f235d0 | d37eda7ae43851f76b2d2635d9db4ea7ada6fe14 | /src/services/Mapper/ThanhVienCuaHoMapper.java | 513fbc565cf337efeaf299053a6c4ab8ab5ff807 | [] | no_license | DaoTrongHieu06072000/Nhap_mon_cnpm | 1169a176d7569a468ca22708f6d7fed1e492a21f | 7e04cc2e61383aa95ade9d7233ffef8258388571 | refs/heads/master | 2023-01-30T16:02:10.434332 | 2020-12-13T15:47:15 | 2020-12-13T15:47:15 | 296,063,530 | 1 | 2 | null | 2020-09-29T02:36:00 | 2020-09-16T14:51:17 | CSS | UTF-8 | Java | false | false | 670 | java | package services.Mapper;
import java.sql.ResultSet;
import java.sql.SQLException;
import model.ThanhVienCuaHoModel;
public class ThanhVienCuaHoMapper implements RowMapper<ThanhVienCuaHoModel>{
@Override
public ThanhVienCuaHoModel mapRow(ResultSet rs) {
ThanhVienCuaHoModel thanhVienCuaHo = new ThanhVienCuaHoModel();
try {
thanhVienCuaHo.setIdHoKhau(rs.getInt("idHoKhau"));
thanhVienCuaHo.setIdNhanKhau(rs.getInt("idNhanKhau"));
thanhVienCuaHo.setQuanHeVoiChuHo(rs.getString("quanHeVoiChuHo"));
return thanhVienCuaHo;
} catch (SQLException e) {
return null;
}
}
}
| [
"sonto2k@gmail.com"
] | sonto2k@gmail.com |
a52e89006f7387cdfa3dda79f9bb8b102aef332d | 3ed30de3c63c8cd1cd9670911d85df5026782f25 | /calendar/src/com/calendar/Record.java | a4f13c3e11def74e38032c554f9eaa23176a4a98 | [] | no_license | Alkazelcer/TimeManagment | f3ce3834748aa14e45aa28aaec7075035d4b40c4 | f3b33d5b3ddb2573bce98f977698b844768a476b | refs/heads/master | 2020-04-09T13:31:30.029023 | 2013-01-19T09:41:05 | 2013-01-19T09:41:05 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,849 | java | package com.calendar;
import java.text.DateFormat;
import java.util.Date;
/**
* Created with IntelliJ IDEA.
* User: d.poberezhny
* Date: 15.01.13
* Time: 10:46
* To change this template use File | Settings | File Templates.
*/
public class Record {
private String mHead = "";
private String mMessage = "";
private Date mDateCreated = new Date();
private Date mStartDate = new Date();
private Date mEnd = null;
public Record()
{
mDateCreated = new Date(System.currentTimeMillis());
}
public Record(String head, String message){
mHead = head;
mMessage = message;
mDateCreated = new Date(System.currentTimeMillis());
}
public Record(String head, String message, Date start){
mHead = head;
mMessage = message;
mDateCreated = new Date(System.currentTimeMillis());
mStartDate = start;
}
public String toString() {
String res = mHead + "\n" +
mMessage + "\n" +
DateFormat.getDateTimeInstance(DateFormat.LONG, DateFormat.LONG).format(mDateCreated) + "\n" +
DateFormat.getDateTimeInstance(DateFormat.SHORT, DateFormat.LONG).format(mStartDate)
;
return res;
}
public String getHead(){
return mHead;
}
public String getDateString(){
return DateFormat.getDateTimeInstance(DateFormat.LONG, DateFormat.LONG).format(mDateCreated);
}
public Date getDate(){
return mStartDate;
}
public String getMessage(){
return mMessage;
}
public void setHead(String head){
mHead = head;
}
public void setMessage(String message){
mMessage = message;
}
public void setStartDate(Date startDate){
mStartDate = startDate;
}
}
| [
"dimitry.poberezhny@gmail.com"
] | dimitry.poberezhny@gmail.com |
f546923f4462813c20ec3463e0f1e8cede410971 | 3f954c0b777cecfff80623c87bd4291292167afc | /test/junit/workbench/util/DurationNumberTest.java | 78fa33ac005f5da3275ec7085d4460a6462cf255 | [] | no_license | zippy1981/SqlWorkbenchJ | 67ba4dca04fb9ee69ca0992032c6ddfb69614f60 | 7b246fb0dadd6b5c47900dcbb2298cc5f0143b77 | refs/heads/master | 2021-01-10T01:47:54.963813 | 2016-02-14T23:14:10 | 2016-02-14T23:14:10 | 45,090,119 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,912 | java | /*
* This file is part of SQL Workbench/J, http://www.sql-workbench.net
*
* Copyright 2002-2016, Thomas Kellerer
*
* Licensed under a modified Apache License, Version 2.0
* that restricts the use for certain governments.
* You may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://sql-workbench.net/manual/license.html
*
* 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.
*
* To contact the author please send an email to: support@sql-workbench.net
*/
package workbench.util;
import org.junit.Test;
import static org.junit.Assert.*;
/**
*
* @author Thomas Kellerer
*/
public class DurationNumberTest
{
public DurationNumberTest()
{
}
@Test
public void testGetTime()
{
DurationNumber num = new DurationNumber();
assertEquals(50, num.parseDefinition("50"));
assertEquals(1000, num.parseDefinition(" 1s"));
assertEquals(1000 * 60, num.parseDefinition(" 1 m "));
assertEquals(1000 * 60 * 60 * 2, num.parseDefinition(" 2h"));
assertEquals(1000 * 60 * 60 * 24, num.parseDefinition("1d"));
assertEquals(1000 * 60 * 60 * 24 * 5, num.parseDefinition("5d"));
assertEquals(0, num.parseDefinition("x"));
assertEquals(0, num.parseDefinition(null));
}
@Test
public void testIsValid()
{
DurationNumber num = new DurationNumber();
assertTrue(num.isValid("5d"));
assertTrue(num.isValid("100s"));
assertTrue(num.isValid("2h"));
assertFalse(num.isValid("42x"));
assertFalse(num.isValid("xyz"));
assertFalse(num.isValid(" "));
assertFalse(num.isValid(""));
}
}
| [
"tkellerer@6c36a7f0-0884-4472-89c7-80b7fa7b7f28"
] | tkellerer@6c36a7f0-0884-4472-89c7-80b7fa7b7f28 |
e84420349956bfeac3fff907172e9c37fa11da22 | 9c64d7415db1be250a26f47f4e00a430ee1da475 | /src/main/java/com/cks/controller/HelloController.java | 0b05d78452a7fc7106605f572d31f7b53433d5e4 | [] | no_license | tochandu/spring-boot-helloword | 271bac96a58f7623e2ad2052fe0de05001c0d4ed | 972ca5a3708488bd4afb380b940b00624f399df1 | refs/heads/master | 2022-10-19T11:57:50.633054 | 2020-06-07T22:43:00 | 2020-06-07T22:43:00 | 270,424,850 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 884 | java | package com.cks.controller;
import com.cks.model.HelloVO;
import com.cks.services.HelloService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.HttpStatus;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;
@RestController
public class HelloController {
@Autowired
private HelloService helloService;
@GetMapping("/getmsg")
public String getMsg() {
return helloService.getHelloMsg();
}
@GetMapping("/getmsg/{msg}")
public ResponseEntity<HelloVO> getMsg(@PathVariable String msg) {
HelloVO helloVOelloVO=helloService.getCustomMsg(msg);
return new ResponseEntity<>(helloVOelloVO, HttpStatus.OK);
}
}
| [
"singh.chandu@gmail.com"
] | singh.chandu@gmail.com |
a92a4dc6ff09727aafe495fa7dba3385fb546b6d | 946dd7b5a0f409dde38111db1b15691ecdc509cd | /ormada-hsql/src/org/ormada/hsql/example/model/Cat.java | 4541487eb15f4657dd1097b22a15d0c416b720a1 | [
"MIT"
] | permissive | theJenix/ormada | e13f5eb341aea835c0a6c59200c35d3929be6f51 | df3ee09c8077e3e95876ea56918655e10353dbf2 | refs/heads/master | 2020-05-19T09:20:38.697338 | 2013-05-22T19:24:49 | 2013-05-22T19:24:49 | 5,463,032 | 0 | 1 | null | null | null | null | UTF-8 | Java | false | false | 1,208 | java | package org.ormada.hsql.example.model;
import java.util.ArrayList;
import java.util.List;
import org.ormada.annotations.OneToMany;
import org.ormada.annotations.Text;
import org.ormada.annotations.Transient;
public class Cat {
private long id;
private String name;
private Cat otherCat;
private List<Kitten> kittens = new ArrayList<Kitten>();
public long getId() {
return id;
}
public void setId(long id) {
this.id = id;
}
@Text
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public Cat getOtherCat() {
return otherCat;
}
public void setOtherCat(Cat otherCat) {
this.otherCat = otherCat;
}
@OneToMany(Kitten.class)
public List<Kitten> getKittens() {
return kittens;
}
public void setKittens(List<Kitten> kittens) {
this.kittens = kittens;
}
@Transient
public String getFamily() {
StringBuilder builder = new StringBuilder();
builder.append(this.name);
if (kittens != null) {
for (Kitten kitten : kittens) {
builder.append(", ").append(kitten.getName());
}
}
if (otherCat != null) {
builder.append("\n\t").append(otherCat.getFamily());
}
return builder.toString();
}
}
| [
"jesse.rosalia@gatech.edu"
] | jesse.rosalia@gatech.edu |
34bcc0b349cb3ecdd8bec3c3975d4a8909ba560b | 25ebe8084bd5ead1270ef14cbb1c43d0e52aed25 | /src/com/zoltu/Vacuum/Messaging/IListener.java | e9aff7b76e5360b60f888968483b448c76e76e1c | [] | no_license | MicahZoltu/vacuum | a5b4de7622860478cb3892ca3bea97548f7e3ef6 | 361c82972b4dba01a263cdc5a5caac809afc63d9 | refs/heads/master | 2020-03-12T12:42:01.345075 | 2009-10-19T21:24:52 | 2009-10-19T21:24:52 | 130,624,396 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 135 | java | package com.zoltu.Vacuum.Messaging;
public interface IListener
{
public void ReceiveMessage(com.google.protobuf.Message pMessage);
}
| [
"Micah@.(none)"
] | Micah@.(none) |
2bb55175231ab1d0eec865063b7576b073e2d6c8 | 3add871550f6ed028cb1955129b5365126ac7408 | /app/src/androidTest/java/com/example/android/bakingapp/RecipeDisplayActivityTest.java | 4461c37409d429bf87d24531a11485f2e29b9ca5 | [] | no_license | jason-ongzj/Baking-App | 0e31bd454ad34ebb99b28dfbbc7c5d840f25309b | 1f3b0619da8bc44455bd8cd39a287886e156da6a | refs/heads/master | 2021-07-08T03:31:52.908108 | 2017-10-03T07:53:02 | 2017-10-03T07:53:02 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 4,971 | java | package com.example.android.bakingapp;
import android.support.test.espresso.contrib.RecyclerViewActions;
import android.support.test.espresso.intent.rule.IntentsTestRule;
import android.support.test.runner.AndroidJUnit4;
import com.example.android.bakingapp.ui.RecipeDisplayActivity;
import org.junit.Rule;
import org.junit.Test;
import org.junit.runner.RunWith;
import static android.support.test.espresso.Espresso.onView;
import static android.support.test.espresso.action.ViewActions.click;
import static android.support.test.espresso.assertion.ViewAssertions.matches;
import static android.support.test.espresso.matcher.ViewMatchers.isDisplayed;
import static android.support.test.espresso.matcher.ViewMatchers.withId;
import static android.support.test.espresso.matcher.ViewMatchers.withText;
import static org.hamcrest.core.IsNot.not;
@RunWith(AndroidJUnit4.class)
public class RecipeDisplayActivityTest {
// Testing for portrait mode
private static final String description3 = "3. Press the cookie crumb mixture into the prepared " +
"pie pan and bake for 12 minutes. Let crust cool to room temperature.";
private static final String description4 = "4. Beat together the nutella, mascarpone, 1 teaspoon of " +
"salt, and 1 tablespoon of vanilla on medium speed in a stand mixer or high speed with a hand mixer until fluffy.";
@Rule
public IntentsTestRule<RecipeDisplayActivity> mRecipeDisplayActivityRule = new IntentsTestRule<>(
RecipeDisplayActivity.class);
// Check correct text contents matched
@Test
public void clickRecyclerViewItem_OpensRecipeInstructionFragment(){
onView(withId(R.id.recyclerView_recipeSteps))
.perform(RecyclerViewActions.actionOnItemAtPosition(3, click()));
onView(withId(R.id.StepDescription)).check(matches(withText(description3)));
}
// Check text contents on clicking next and previous
@Test
public void checkDescriptionOnNextAndPrevious(){
boolean isTwoPane = mRecipeDisplayActivityRule.getActivity().isTwoPane();
onView(withId(R.id.recyclerView_recipeSteps))
.perform(RecyclerViewActions.actionOnItemAtPosition(3, click()));
if(!isTwoPane) {
onView(withId(R.id.Next)).perform(click());
onView(withId(R.id.StepDescription)).check(matches(withText(description4)));
onView(withId(R.id.Previous)).perform(click());
onView(withId(R.id.StepDescription)).check(matches(withText(description3)));
}
}
// Hide Previous button when clicking Previous to show first item
@Test
public void checkPrevButtonDisabledOnItemZero_OnClickPrev(){
boolean isTwoPane = mRecipeDisplayActivityRule.getActivity().isTwoPane();
onView(withId(R.id.recyclerView_recipeSteps))
.perform(RecyclerViewActions.actionOnItemAtPosition(1, click()));
if(!isTwoPane) {
onView(withId(R.id.Previous)).perform(click());
onView(withId(R.id.Previous)).check(matches(not(isDisplayed())));
}
}
// Hide Next button when clicking Next to show last item
@Test
public void checkNextButtonDisabledOnLastItem_OnClickNext(){
boolean isTwoPane = mRecipeDisplayActivityRule.getActivity().isTwoPane();
onView(withId(R.id.recyclerView_recipeSteps))
.perform(RecyclerViewActions.actionOnItemAtPosition(5, click()));
if(!isTwoPane) {
onView(withId(R.id.Next)).perform(click());
onView(withId(R.id.Next)).check(matches(not(isDisplayed())));
}
}
// Hide Previous button on first item selection from recycler view, show Previous button
// when clicking Next
@Test
public void checkPrevButtonDisabledOnItemZeroDisplay_EnabledOnClickNext(){
boolean isTwoPane = mRecipeDisplayActivityRule.getActivity().isTwoPane();
onView(withId(R.id.recyclerView_recipeSteps))
.perform(RecyclerViewActions.actionOnItemAtPosition(0, click()));
if(!isTwoPane) {
onView(withId(R.id.Previous)).check(matches(not(isDisplayed())));
onView(withId(R.id.Next)).perform(click());
onView(withId(R.id.Previous)).check(matches(isDisplayed()));
}
}
// Hide Next button on last item selection from recycler view, show Next button
// when clicking Previous
@Test
public void checkNextButtonDisabledOnLastItemDisplay_EnabledOnClickPrev(){
boolean isTwoPane = mRecipeDisplayActivityRule.getActivity().isTwoPane();
onView(withId(R.id.recyclerView_recipeSteps))
.perform(RecyclerViewActions.actionOnItemAtPosition(6, click()));
if(!isTwoPane) {
onView(withId(R.id.Next)).check(matches(not(isDisplayed())));
onView(withId(R.id.Previous)).perform(click());
onView(withId(R.id.Next)).check(matches(isDisplayed()));
}
}
}
| [
"zhejun90@gmail.com"
] | zhejun90@gmail.com |
e779a8f516a757ef3e083734e29c18faeea1fe11 | 5148293c98b0a27aa223ea157441ac7fa9b5e7a3 | /Method_Scraping/xml_scraping/NicadOutputFile_t1_beam_2nd/Nicad_t1_beam_2nd417.java | 4b98143b7abef760b0cbb81de6c054f0bf9f7444 | [] | no_license | ryosuke-ku/TestCodeSeacherPlus | cfd03a2858b67a05ecf17194213b7c02c5f2caff | d002a52251f5461598c7af73925b85a05cea85c6 | refs/heads/master | 2020-05-24T01:25:27.000821 | 2019-08-17T06:23:42 | 2019-08-17T06:23:42 | 187,005,399 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 485 | java | // clone pairs:2916:80%
// 3231:beam/runners/core-construction-java/src/main/java/org/apache/beam/runners/core/construction/PTransformMatchers.java
public class Nicad_t1_beam_2nd417
{
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
EqualUrnPTransformMatcher that = (EqualUrnPTransformMatcher) o;
return urn.equals(that.urn);
}
} | [
"naist1020@gmail.com"
] | naist1020@gmail.com |
1904e2acf06f914fa176f4b84ff529b917afe68a | a4676fea56c95377b1376764c70f88dbd3f161c1 | /src/main/java/com/learn/test/annotation/Teacher.java | 425de94dfa9442b076356cb263f81afc1d56b36c | [] | no_license | cjxlm/geekTime | 46281b7c9b04b7e53249e2eebe4d9da729a051a2 | 153b5e520fa8d7da97bc191df5dac575217e5f6b | refs/heads/master | 2022-04-20T04:58:11.803205 | 2020-04-10T02:00:25 | 2020-04-10T02:00:25 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 195 | java | package com.learn.test.annotation;
/**
* Created by XJH on 2020/3/25.
*
* @Description:测试@Inherited标签
*/
// 这里自动继承@MetaAnno注解
public class Teacher extends Person{
}
| [
"359830186@qq.com"
] | 359830186@qq.com |
1ad73996366809e8e8eed5dc098fb637090a0443 | 7641e5650d4482c9efe358457aaf6d05a0c9e27f | /FruitTradeSystem/src/main/java/com/sys/service/UsersService.java | 1ebdcb541c370a56723958ecfede4ca5ec307ed4 | [] | no_license | fruitshoppingsystem/FruitTradeSystem | 1e6d66ff501eb12ccfd7fa3b2f9ef4edbd32d39a | 83f02d43e74403a2752e586f765a5e0f5d0b4d27 | refs/heads/main | 2023-07-07T09:02:54.182796 | 2021-08-12T07:25:55 | 2021-08-12T07:25:55 | 391,772,928 | 0 | 0 | null | 2021-08-12T07:25:56 | 2021-08-02T00:30:04 | Java | UTF-8 | Java | false | false | 771 | java | package com.sys.service;
import com.sys.pojo.Users;
import java.util.List;
public interface UsersService {
void userRegister(String uEmail, String uName, String uPassword);
void insertUser(Users users);
void deleteUser(String uEmail);
void updateUser(String uEmail, String uName, String uAddress, String uPhonenum);
void updateUserPassword(Users users);
List<Users> selectAllUsers();
Users selectUsersByEmail(String uEmail);
int findUserByEmail(String uEmail);
String selectPasswordByEmail(String uEmail);
String selectNameByEmail(String uEmail);
Integer selectUserState(String uEmail);
int selectVIPByEmail(String uEmail);
void updateVIP(String uEmail, int uVIP);
void updateState(String uEmail, int uState);
}
| [
"1715149425@qq.com"
] | 1715149425@qq.com |
3a74d3fb1882ff08cb1d0b1b536e5df9d4616160 | 424ad99a7f5594a9c0fac28bed6bf410e5e0ca99 | /CosmosQuestSolver/src/Formations/WorldBoss.java | 148cd11e5b5e91669d226b62586d569588f7b582 | [] | no_license | peblpebl/cosmos-quest-calc | 695211f11756194e6fd9d8324341be6d8f54f9c0 | ef9ccbef1032396425193a9f226265fd621773fd | refs/heads/master | 2020-04-15T07:59:24.057260 | 2018-12-16T01:18:09 | 2018-12-16T01:18:09 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 3,769 | java | /*
*/
package Formations;
import Formations.Elements.Element;
import GUI.AssetPanel;
import SpecialAbilities.SpecialAbility;
import java.awt.Graphics;
public class WorldBoss extends Creature{
private long damageTaken;//yes, this has to be long. Darn Geum...
public static final int DRAW_WIDTH = 512;
public static final int DRAW_HEIGHT = 450;
protected WorldBoss(){
//usedForCopying
}
protected WorldBoss(Element element, int baseAtt, int ID, SpecialAbility specialAbility){
super(element,baseAtt,Integer.MAX_VALUE);
this.specialAbility = specialAbility;
this.ID = ID;
}
public void attatchSpecialAbility() {
specialAbility.setOwner(this);
}
@Override
public Creature getCopy() {
WorldBoss wb = new WorldBoss();
wb.element = element;
wb.baseHP = baseHP;
wb.baseAtt = baseAtt;
wb.specialAbility = specialAbility.getCopyForNewOwner(wb);
wb.currentHP = baseHP;//needed?
wb.currentAtt = baseAtt;
wb.ID = ID;
//wb.level = level;//levels mattered in the past
return wb;
}
/*
//world bosses don't have hp, instead, record damage taken
@Override
public void takeHit(Creature creature, Formation thisFormation, Formation enemyFormation) {
double hit = creature.determineDamage(this,thisFormation,enemyFormation);
thisFormation.addDamageTaken((long)Math.ceil(hit));
damageTaken = thisFormation.getDamageTaken();//duplicate info? bosses may not always be alone?
}//damage refection on bosses? override changeHP instead?
*/
//world boss should implement battleCreature, not extend creature
@Override
public void changeHP(double damage, Formation thisFormation){
long num;//Geum
if (damage < 0){//round away from 0
num = (long)Math.floor(damage);
thisFormation.addDamageTaken(-num);
}
else{//this shouldn't happen. Bosses have no use for healing
num = (long) Math.ceil(damage);
}
damageTaken -= num;
}
@Override
public void draw(Graphics g) {
if (!isFacingRight()){
g.drawImage(CreatureFactory.getPicture(getImageAddress()), 0, 0, AssetPanel.CREATURE_PICTURE_SIZE, AssetPanel.CREATURE_PICTURE_SIZE, null);
}
else{
g.drawImage(CreatureFactory.getPicture(getImageAddress()), AssetPanel.CREATURE_PICTURE_SIZE, 0, -AssetPanel.CREATURE_PICTURE_SIZE, AssetPanel.CREATURE_PICTURE_SIZE, null);
}
}
@Override
public String getImageAddress() {
return "Creatures/World Bosses/" + getName();
}
@Override
public String toolTipText() {
return "<html>" + getName() + "<br>Attack: " + getBaseAtt() + "<br>" + getSpecialAbility().getDescription() + "</html>";
}
@Override
public String toString(){
StringBuilder sb = new StringBuilder();
sb.append(getName()).append(":\tAtt: ");
sb.append(currentAtt).append("\tDamage Taken: ");
sb.append(damageTaken).append("\tElement: ");
sb.append(element);
return sb.toString();
}
@Override
public Hero.Rarity getRarity() {
return null;
}
@Override
public long getFollowers() {
return 0;
}
@Override
public boolean isSameCreature(Creature c) {
if (!(c instanceof WorldBoss)){
return false;
}
return getName().equals(c.getName());
}
@Override
public int getID(){
return -ID - 2;//world bosses are mixed in with heroes
}
}
| [
"nathankrueper@gmail.com"
] | nathankrueper@gmail.com |
eaaddf3d28f9140df2cdb0e7a9681848ed133dd8 | 3e7cbcb234fb2f2bac0963d2d14c7aea3506aabd | /Membership/src/main/java/com/example/service/UserService.java | da4680736af58118f66e7c8b7bb61a633db1e9be | [] | no_license | tmznf963/SIST-E-Spring | de94e5626744d694cdb655ca91303ea8ac2050e3 | 92381fb1c89e438be41c2154ff70f38588a218f3 | refs/heads/master | 2020-04-08T10:45:51.499682 | 2019-01-24T00:32:45 | 2019-01-24T00:32:45 | 159,281,337 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 330 | java | package com.example.service;
import java.util.List;
import com.oracle.vo.UserVO;
//void == return 안하는 애들
public interface UserService {
void createUser(UserVO userVO);
UserVO readUser(String userid);
List<UserVO> selectAllUsers();
void updateUser(String userid, String city);
void deleteUser(String userid);
}
| [
"qhfhd963@naver.com"
] | qhfhd963@naver.com |
77194b680805a7555e09f9d9f88985e13c71808d | eb7c9b6ab84fa9c2a09b940eb90b0104c3d5b69d | /src/net/minecraft/world/chunk/storage/ExtendedBlockStorage.java | 8c486a441c9225dbf838236fd34c7d96f30f186b | [] | no_license | StargateMC/Optifine-1.12-SRC | 0e7f4a218e2568c7c315442ca24337d6e204ee3d | cf51f4403d8c1bce5fc2a528117f4d416e28af40 | refs/heads/master | 2021-01-25T23:14:08.703774 | 2017-07-29T08:08:14 | 2017-07-29T08:08:14 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 5,685 | java | package net.minecraft.world.chunk.storage;
import net.minecraft.block.Block;
import net.minecraft.block.state.IBlockState;
import net.minecraft.init.Blocks;
import net.minecraft.src.Reflector;
import net.minecraft.world.chunk.BlockStateContainer;
import net.minecraft.world.chunk.NibbleArray;
public class ExtendedBlockStorage
{
/**
* Contains the bottom-most Y block represented by this ExtendedBlockStorage. Typically a multiple of 16.
*/
private final int yBase;
/**
* A total count of the number of non-air blocks in this block storage's Chunk.
*/
private int blockRefCount;
/**
* Contains the number of blocks in this block storage's parent chunk that require random ticking. Used to cull the
* Chunk from random tick updates for performance reasons.
*/
private int tickRefCount;
private final BlockStateContainer data;
/** The NibbleArray containing a block of Block-light data. */
private NibbleArray blockLight;
/**
* The NibbleArray containing skylight data.
*
* Will be null if the provider for the world the chunk containing this block storage does not {@linkplain
* net.minecraft.world.WorldProvider#hasSkylight have skylight}.
*/
private NibbleArray skyLight;
public ExtendedBlockStorage(int y, boolean storeSkylight)
{
this.yBase = y;
this.data = new BlockStateContainer();
this.blockLight = new NibbleArray();
if (storeSkylight)
{
this.skyLight = new NibbleArray();
}
}
public IBlockState get(int x, int y, int z)
{
return this.data.get(x, y, z);
}
public void set(int x, int y, int z, IBlockState state)
{
if (Reflector.IExtendedBlockState.isInstance(state))
{
state = (IBlockState)Reflector.call(state, Reflector.IExtendedBlockState_getClean);
}
IBlockState iblockstate = this.get(x, y, z);
Block block = iblockstate.getBlock();
Block block1 = state.getBlock();
if (block != Blocks.AIR)
{
--this.blockRefCount;
if (block.getTickRandomly())
{
--this.tickRefCount;
}
}
if (block1 != Blocks.AIR)
{
++this.blockRefCount;
if (block1.getTickRandomly())
{
++this.tickRefCount;
}
}
this.data.set(x, y, z, state);
}
/**
* Returns whether or not this block storage's Chunk is fully empty, based on its internal reference count.
*/
public boolean isEmpty()
{
return this.blockRefCount == 0;
}
/**
* Returns whether or not this block storage's Chunk will require random ticking, used to avoid looping through
* random block ticks when there are no blocks that would randomly tick.
*/
public boolean needsRandomTick()
{
return this.tickRefCount > 0;
}
/**
* Returns the Y location of this ExtendedBlockStorage.
*/
public int getYLocation()
{
return this.yBase;
}
/**
* Sets the saved Sky-light value in the extended block storage structure.
*/
public void setSkyLight(int x, int y, int z, int value)
{
this.skyLight.set(x, y, z, value);
}
/**
* Gets the saved Sky-light value in the extended block storage structure.
*/
public int getSkyLight(int x, int y, int z)
{
return this.skyLight.get(x, y, z);
}
/**
* Sets the saved Block-light value in the extended block storage structure.
*/
public void setBlockLight(int x, int y, int z, int value)
{
this.blockLight.set(x, y, z, value);
}
/**
* Gets the saved Block-light value in the extended block storage structure.
*/
public int getBlockLight(int x, int y, int z)
{
return this.blockLight.get(x, y, z);
}
public void recalculateRefCounts()
{
IBlockState iblockstate = Blocks.AIR.getDefaultState();
int i = 0;
int j = 0;
for (int k = 0; k < 16; ++k)
{
for (int l = 0; l < 16; ++l)
{
for (int i1 = 0; i1 < 16; ++i1)
{
IBlockState iblockstate1 = this.data.get(i1, k, l);
if (iblockstate1 != iblockstate)
{
++i;
Block block = iblockstate1.getBlock();
if (block.getTickRandomly())
{
++j;
}
}
}
}
}
this.blockRefCount = i;
this.tickRefCount = j;
}
public BlockStateContainer getData()
{
return this.data;
}
/**
* Returns the NibbleArray instance containing Block-light data.
*/
public NibbleArray getBlockLight()
{
return this.blockLight;
}
/**
* Returns the NibbleArray instance containing Sky-light data.
*/
public NibbleArray getSkyLight()
{
return this.skyLight;
}
/**
* Sets the NibbleArray instance used for Block-light values in this particular storage block.
*/
public void setBlockLight(NibbleArray newBlocklightArray)
{
this.blockLight = newBlocklightArray;
}
/**
* Sets the NibbleArray instance used for Sky-light values in this particular storage block.
*/
public void setSkyLight(NibbleArray newSkylightArray)
{
this.skyLight = newSkylightArray;
}
}
| [
"tszfungwonghk@gmail.com"
] | tszfungwonghk@gmail.com |
f48b5251701dcc713098521dd31797562608c8d8 | cc1e5ab759c2b6e866aaf7f5f71905071015f15a | /philosophers/src/main/java/jfskora/philosopher/ForkPair.java | 81c147da1e0a3055e8c2df8b6ef7c107e1d635d5 | [
"MIT"
] | permissive | jskora/scratch | 4277fd7622e17993832b78c0dcc703198768221b | 500445b6e57dd16bf105c1586753b99138c02d0f | refs/heads/master | 2022-12-22T21:50:34.902722 | 2020-03-05T09:36:01 | 2020-03-05T09:36:01 | 49,506,880 | 1 | 1 | MIT | 2022-12-14T20:39:58 | 2016-01-12T14:53:29 | Java | UTF-8 | Java | false | false | 928 | java | package jfskora.philosopher;
import jfskora.philosopher.ForkLock;
import java.util.concurrent.locks.ReentrantLock;
public class ForkPair {
final ReentrantLock firstFork;
final ReentrantLock secondFork;
final Integer firstForkIndex;
final Integer secondForkIndex;
ForkPair(Integer leftIndex, Integer rightIndex, ForkLock[] forks) {
if (leftIndex < rightIndex) {
firstForkIndex = leftIndex;
firstFork = forks[leftIndex];
secondForkIndex = rightIndex;
secondFork = forks[rightIndex];
} else {
firstForkIndex = rightIndex;
firstFork = forks[rightIndex];
secondForkIndex = leftIndex;
secondFork = forks[leftIndex];
}
}
void pickUp() {
firstFork.lock();
secondFork.lock();
}
void putDown() {
firstFork.unlock();
secondFork.unlock();
}
}
| [
"jskora@gmail.com"
] | jskora@gmail.com |
447791c6558aa75ec5146ebfb20de0fd789685de | 0ab436ba2f17d584814f80f1349a8aa2d2153525 | /src/main/java/org/usfirst/frc/team319/robot/commands/robot/StartClimbLevelTwoLowLockMode.java | d4ef02a4968bb5131ca264280ea1e3d75ce9d6fa | [] | no_license | Team319/frc319-2019 | 508798d529eadb784a6fc51669b5f491b8c911c4 | 39db6084cd1e9c91d62e22b2c7cfeea4eda578d9 | refs/heads/master | 2020-04-18T09:22:54.668853 | 2019-04-30T18:20:59 | 2019-04-30T18:20:59 | 167,432,210 | 5 | 3 | null | 2019-04-30T18:21:00 | 2019-01-24T20:25:13 | Java | UTF-8 | Java | false | false | 1,280 | java | /*----------------------------------------------------------------------------*/
package org.usfirst.frc.team319.robot.commands.robot;
import org.usfirst.frc.team319.models.RobotMode;
import org.usfirst.frc.team319.robot.commands.bba.BbaSafelyGoToClimbLevelTwoStartPosition;
import org.usfirst.frc.team319.robot.commands.elevator.ElevatorBrakeMode;
import org.usfirst.frc.team319.robot.commands.elevator.ElevatorGoToClimbPosition;
import org.usfirst.frc.team319.robot.commands.elevator.ElevatorGoToLockPosition;
import org.usfirst.frc.team319.robot.commands.elevator.ElevatorGoToLowLockPosition;
import org.usfirst.frc.team319.robot.commands.elevator.ElevatorLockCarriage;
import org.usfirst.frc.team319.robot.commands.elevator.ElevatorPrepareForClimb;
import edu.wpi.first.wpilibj.command.CommandGroup;
import edu.wpi.first.wpilibj.command.WaitCommand;
public class StartClimbLevelTwoLowLockMode extends CommandGroup {
/**
* Add your docs here.
*/
public StartClimbLevelTwoLowLockMode() {
addParallel(new ElevatorPrepareForClimb());
addSequential(new BbaSafelyGoToClimbLevelTwoStartPosition());
addSequential(new ElevatorGoToClimbPosition(), 1.0);
addSequential(new SetRobotMode(RobotMode.Climb));
addSequential(new ElevatorBrakeMode());
}
}
| [
"joshuarobotics1@gmail.com"
] | joshuarobotics1@gmail.com |
9256c74f778a5f954a6042378aede6494306d6d9 | fc5483b464a89b0cbee3484c9bb5eede3f2d2fc7 | /delivery-order-service/src/main/java/com/coderef/delivery/controller/OrderController.java | efdb33df14c5378b5e9890d4e4d0e349d98a2d25 | [] | no_license | fernandohs1500/delivery | d2f968ea2d0a2fbf99d3d62d816ca3708b04f1dd | 734f4ac54ce12b037cdeda3f7f788831511e857a | refs/heads/master | 2020-11-30T23:06:09.525688 | 2018-03-27T02:15:09 | 2018-03-27T02:15:09 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,530 | java | package com.coderef.delivery.controller;
import com.coderef.delivery.model.Order;
import com.coderef.delivery.service.OrderService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.MediaType;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.*;
@RestController
@RequestMapping(value = "/api/orders", produces = MediaType.APPLICATION_JSON_VALUE)
public class OrderController {
@Autowired
private OrderService orderService;
@RequestMapping(method = RequestMethod.POST)
public ResponseEntity<Order> save(@RequestBody Order order){
return ResponseEntity.ok(orderService.save(order));
}
@RequestMapping(value = "/{id}", method = RequestMethod.GET)
public ResponseEntity<Order> findById(@PathVariable("id") Integer id){
return ResponseEntity.ok(orderService.findById(id));
}
@RequestMapping(method = RequestMethod.GET)
public ResponseEntity<Iterable<Order>> findAll(){
return ResponseEntity.ok().body(orderService.findAll());
}
@RequestMapping(value = "/{id}/status", method = RequestMethod.GET)
public ResponseEntity<?> checkStatus(@PathVariable("id") Integer id){
return ResponseEntity.ok(orderService.checkStatus( id ));
}
@RequestMapping(value = "/{id}", method = RequestMethod.DELETE)
public ResponseEntity<?> delete(@PathVariable("id") Integer id){
orderService.delete(id);
return ResponseEntity.ok().build();
}
}
| [
"diego.brener@contaazul.com"
] | diego.brener@contaazul.com |
4fbb486f7192edddc6018493c8984c9651b35435 | 6f80083eca949cc4031cebba9199e2333d209dcf | /lt87/src/main/java/rookie/java/leetcode/lt87/App.java | 530c7adb37525939ee403542534f2e7e166904f4 | [
"Apache-2.0"
] | permissive | ytong82/leetcode-in-java | fa703a6b7116bf49015b129b5d4ae34f12f2d754 | 65dfb1562634764dd41711c5da001fbbf8bc67a5 | refs/heads/master | 2021-07-24T19:04:05.647660 | 2021-04-30T20:50:41 | 2021-04-30T20:50:41 | 248,274,250 | 0 | 0 | Apache-2.0 | 2020-10-13T20:31:31 | 2020-03-18T15:44:55 | Java | UTF-8 | Java | false | false | 374 | java | package rookie.java.leetcode.lt87;
public class App {
public static void main( String[] args ) {
Solution solution = new Solution();
String[] s1es = {"great", "abcde", "a"};
String[] s2es = {"rgeat", "caebd", "a"};
for (int i=0; i<s1es.length; i++) {
System.out.println(solution.isScramble(s1es[i], s2es[i]));
}
}
}
| [
"ytong@ebay.com"
] | ytong@ebay.com |
d5e9ec4b09fca3d57b5f2862892669b72979b2d0 | 5fb2edd24da3042e3def986666735412dabf6c40 | /Android/SecChat/app/src/main/java/net/i2p/client/I2PSessionMuxedImpl.java | 48ca6016e8c963ee400cc7f12d08bfd2fce09d7c | [
"MIT"
] | permissive | RazuvaevDD/I2PSecChat | 5b2796bd10f93d213bde90edf1c8d76d55881dbf | d26894c7849dadade8cc59c3ff390e20896f8dc5 | refs/heads/release | 2023-03-09T12:07:44.387095 | 2021-02-21T15:07:53 | 2021-02-21T15:07:53 | 315,027,754 | 1 | 6 | MIT | 2021-02-22T08:51:58 | 2020-11-22T12:04:56 | Java | UTF-8 | Java | false | false | 17,971 | java | package net.i2p.client;
/*
* public domain
*/
import java.io.InputStream;
import java.util.concurrent.LinkedBlockingQueue;
import java.util.Properties;
import java.util.Set;
import java.util.concurrent.atomic.AtomicBoolean;
import net.i2p.I2PAppContext;
import net.i2p.data.DataHelper;
import net.i2p.data.Destination;
import net.i2p.data.SessionKey;
import net.i2p.data.i2cp.MessagePayloadMessage;
import net.i2p.util.Log;
/**
* I2PSession with protocol and ports
*
* Streaming lib has been modified to send I2PSession.PROTO_STREAMING but
* still receives all. It sends with fromPort and toPort = 0, and receives on all ports.
*
* No datagram apps have been modified yet.
* Therefore the compatibility situation is as follows:
*
* Compatibility:
* old streaming -> new streaming: sends proto anything, rcvs proto anything
* new streaming -> old streaming: sends PROTO_STREAMING, ignores rcvd proto
* old datagram -> new datagram: sends proto anything, rcvs proto anything
* new datagram -> old datagram: sends PROTO_DATAGRAM, ignores rcvd proto
* In all the above cases, streaming and datagram receive traffic for the other
* protocol, same as before.
*
* old datagram -> new muxed: doesn't work because the old sends proto 0 but the udp side
* of the mux registers with PROTO_DATAGRAM, so the datagrams
* go to the streaming side, same as before.
* old streaming -> new muxed: works
*
* Typical Usage:
* Streaming + datagrams:
* I2PSocketManager sockMgr = getSocketManager();
* I2PSession session = sockMgr.getSession();
* session.addMuxedSessionListener(myI2PSessionMuxedListener, I2PSession.PROTO_DATAGRAM, I2PSession.PORT_ANY);
* * or *
* session.addSessionListener(myI2PSessionListener, I2PSession.PROTO_DATAGRAM, I2PSession.PORT_ANY);
* session.sendMessage(dest, payload, I2PSession.PROTO_DATAGRAM, fromPort, toPort);
*
* Datagrams only, with multiple ports:
* I2PClient client = I2PClientFactory.createClient();
* ...
* I2PSession session = client.createSession(...);
* session.addMuxedSessionListener(myI2PSessionMuxedListener, I2PSession.PROTO_DATAGRAM, I2PSession.PORT_ANY);
* * or *
* session.addSessionListener(myI2PSessionListener, I2PSession.PROTO_DATAGRAM, I2PSession.PORT_ANY);
* session.sendMessage(dest, payload, I2PSession.PROTO_DATAGRAM, fromPort, toPort);
*
* Multiple streaming ports:
* Needs some streaming lib hacking
*
* @author zzz
* @since 0.7.1
*/
class I2PSessionMuxedImpl extends I2PSessionImpl2 {
private final I2PSessionDemultiplexer _demultiplexer;
/*
* @param destKeyStream stream containing the private key data,
* format is specified in {@link net.i2p.data.PrivateKeyFile PrivateKeyFile}
* @param options set of options to configure the router with, if null will use System properties
*/
public I2PSessionMuxedImpl(I2PAppContext ctx, InputStream destKeyStream, Properties options) throws I2PSessionException {
super(ctx, destKeyStream, options);
// also stored in _sessionListener but we keep it in _demultipexer
// as well so we don't have to keep casting
_demultiplexer = new I2PSessionDemultiplexer(ctx);
super.setSessionListener(_demultiplexer);
// discards the one in super(), sorry about that... (no it wasn't started yet)
_availabilityNotifier = new MuxedAvailabilityNotifier();
}
/** listen on all protocols and ports */
@Override
public void setSessionListener(I2PSessionListener lsnr) {
_demultiplexer.addListener(lsnr, PROTO_ANY, PORT_ANY);
}
/**
* Listen on specified protocol and port.
*
* An existing listener with the same proto and port is replaced.
* Only the listener with the best match is called back for each message.
*
* @param proto 1-254 or PROTO_ANY (0) for all; recommended:
* I2PSession.PROTO_STREAMING
* I2PSession.PROTO_DATAGRAM
* 255 disallowed
* @param port 1-65535 or PORT_ANY (0) for all
*/
@Override
public void addSessionListener(I2PSessionListener lsnr, int proto, int port) {
_demultiplexer.addListener(lsnr, proto, port);
}
/**
* Listen on specified protocol and port, and receive notification
* of proto, fromPort, and toPort for every message.
* @param proto 1-254 or PROTO_ANY (0) for all; 255 disallowed
* @param port 1-65535 or PORT_ANY (0) for all
*/
@Override
public void addMuxedSessionListener(I2PSessionMuxedListener l, int proto, int port) {
_demultiplexer.addMuxedListener(l, proto, port);
}
/** removes the specified listener (only) */
@Override
public void removeListener(int proto, int port) {
_demultiplexer.removeListener(proto, port);
}
@Override
public boolean sendMessage(Destination dest, byte[] payload) throws I2PSessionException {
return sendMessage(dest, payload, 0, payload.length, null, null,
0, PROTO_UNSPECIFIED, PORT_UNSPECIFIED, PORT_UNSPECIFIED);
}
@Override
public boolean sendMessage(Destination dest, byte[] payload, int proto, int fromport, int toport) throws I2PSessionException {
return sendMessage(dest, payload, 0, payload.length, null, null, 0, proto, fromport, toport);
}
/**
* @param keyUsed unused - no end-to-end crypto
* @param tagsSent unused - no end-to-end crypto
*/
@Override
public boolean sendMessage(Destination dest, byte[] payload, int offset, int size,
SessionKey keyUsed, Set tagsSent, long expires)
throws I2PSessionException {
return sendMessage(dest, payload, offset, size, keyUsed, tagsSent, 0, PROTO_UNSPECIFIED, PORT_UNSPECIFIED, PORT_UNSPECIFIED);
}
/**
* @param keyUsed unused - no end-to-end crypto
* @param tagsSent unused - no end-to-end crypto
*/
@Override
public boolean sendMessage(Destination dest, byte[] payload, int offset, int size, SessionKey keyUsed, Set tagsSent,
int proto, int fromport, int toport) throws I2PSessionException {
return sendMessage(dest, payload, offset, size, keyUsed, tagsSent, 0, proto, fromport, toport);
}
/**
* @param keyUsed unused - no end-to-end crypto
* @param tagsSent unused - no end-to-end crypto
* @param proto 1-254 or 0 for unset; recommended:
* I2PSession.PROTO_UNSPECIFIED
* I2PSession.PROTO_STREAMING
* I2PSession.PROTO_DATAGRAM
* 255 disallowed
* @param fromPort 1-65535 or 0 for unset
* @param toPort 1-65535 or 0 for unset
* @since 0.7.1
*/
@Override
public boolean sendMessage(Destination dest, byte[] payload, int offset, int size,
SessionKey keyUsed, Set tagsSent, long expires,
int proto, int fromPort, int toPort)
throws I2PSessionException {
return sendMessage(dest, payload, offset, size, keyUsed, tagsSent, 0, proto, fromPort, toPort, 0);
}
/**
* @param keyUsed unused - no end-to-end crypto
* @param tagsSent unused - no end-to-end crypto
* @param proto 1-254 or 0 for unset; recommended:
* I2PSession.PROTO_UNSPECIFIED
* I2PSession.PROTO_STREAMING
* I2PSession.PROTO_DATAGRAM
* 255 disallowed
* @param fromPort 1-65535 or 0 for unset
* @param toPort 1-65535 or 0 for unset
* @param flags to be passed to the router
* @since 0.8.4
*/
@Override
public boolean sendMessage(Destination dest, byte[] payload, int offset, int size,
SessionKey keyUsed, Set tagsSent, long expires,
int proto, int fromPort, int toPort, int flags)
throws I2PSessionException {
payload = prepPayload(payload, offset, size, proto, fromPort, toPort);
if (_noEffort)
return sendNoEffort(dest, payload, expires, flags);
else
return sendBestEffort(dest, payload, expires, flags);
}
/**
* See SendMessageOptions for option details.
*
* Always uses sendNoEffort for now.
*
* @param proto 1-254 or 0 for unset; recommended:
* I2PSession.PROTO_UNSPECIFIED
* I2PSession.PROTO_STREAMING
* I2PSession.PROTO_DATAGRAM
* 255 disallowed
* @param fromPort 1-65535 or 0 for unset
* @param toPort 1-65535 or 0 for unset
* @param options to be passed to the router
* @since 0.9.2
*/
@Override
public boolean sendMessage(Destination dest, byte[] payload, int offset, int size,
int proto, int fromPort, int toPort, SendMessageOptions options) throws I2PSessionException {
payload = prepPayload(payload, offset, size, proto, fromPort, toPort);
//if (_noEffort) {
sendNoEffort(dest, payload, options);
return true;
//} else {
// unimplemented
//return sendBestEffort(dest, payload, options);
//}
}
/**
* Send a message and request an asynchronous notification of delivery status.
*
* See I2PSessionMuxedImpl for proto/port details.
* See SendMessageOptions for option details.
*
* @return the message ID to be used for later notification to the listener
* @throws I2PSessionException on all errors
* @since 0.9.14
*/
@Override
public long sendMessage(Destination dest, byte[] payload, int offset, int size,
int proto, int fromPort, int toPort,
SendMessageOptions options, SendMessageStatusListener listener) throws I2PSessionException {
payload = prepPayload(payload, offset, size, proto, fromPort, toPort);
long nonce = _sendMessageNonce.incrementAndGet();
long expires = Math.max(_context.clock().now() + 60*1000L, options.getTime());
MessageState state = new MessageState(_context, nonce, this, expires, listener);
_sendingStates.put(Long.valueOf(nonce), state);
_producer.sendMessage(this, dest, nonce, payload, options);
return nonce;
}
/**
* @return gzip compressed payload, ready to send
* @since 0.9.14
*/
private byte[] prepPayload(byte[] payload, int offset, int size, int proto, int fromPort, int toPort) throws I2PSessionException {
if (isClosed()) throw new I2PSessionException("Already closed");
updateActivity();
if (shouldCompress(size))
payload = DataHelper.compress(payload, offset, size);
else
payload = DataHelper.compress(payload, offset, size, DataHelper.NO_COMPRESSION);
setProto(payload, proto);
setFromPort(payload, fromPort);
setToPort(payload, toPort);
_context.statManager().addRateData("i2cp.tx.msgCompressed", payload.length);
_context.statManager().addRateData("i2cp.tx.msgExpanded", size);
return payload;
}
/**
* @since 0.9.2
*/
private void sendNoEffort(Destination dest, byte payload[], SendMessageOptions options)
throws I2PSessionException {
// nonce always 0
_producer.sendMessage(this, dest, 0, payload, options);
}
/**
* Receive a payload message and let the app know its available
*/
@Override
public void addNewMessage(MessagePayloadMessage msg) {
Long mid = Long.valueOf(msg.getMessageId());
_availableMessages.put(mid, msg);
long id = msg.getMessageId();
byte data[] = msg.getPayload().getUnencryptedData();
if ((data == null) || (data.length <= 0)) {
if (_log.shouldLog(Log.CRIT))
_log.log(Log.CRIT, getPrefix() + "addNewMessage of a message with no unencrypted data",
new Exception("Empty message"));
return;
}
int size = data.length;
if (size < 10) {
_log.error(getPrefix() + "length too short for gzip header: " + size);
return;
}
((MuxedAvailabilityNotifier)_availabilityNotifier).available(id, size, getProto(msg),
getFromPort(msg), getToPort(msg));
}
protected class MuxedAvailabilityNotifier extends AvailabilityNotifier {
private final LinkedBlockingQueue<MsgData> _msgs;
private volatile boolean _alive = false;
private static final int POISON_SIZE = -99999;
private final AtomicBoolean stopping = new AtomicBoolean(false);
public MuxedAvailabilityNotifier() {
_msgs = new LinkedBlockingQueue<MsgData>();
}
@Override
public void stopNotifying() {
boolean again = true;
synchronized (stopping) {
if( !stopping.getAndSet(true)) {
if (_alive == true) {
// System.out.println("I2PSessionMuxedImpl.stopNotifying()");
_msgs.clear();
while(again) {
try {
_msgs.put(new MsgData(0, POISON_SIZE, 0, 0, 0));
again = false;
// System.out.println("I2PSessionMuxedImpl.stopNotifying() success.");
} catch (InterruptedException ie) {
continue;
}
}
}
_alive = false;
stopping.set(false);
}
// stopping.notifyAll();
}
}
/** unused */
@Override
public void available(long msgId, int size) { throw new IllegalArgumentException("no"); }
public void available(long msgId, int size, int proto, int fromPort, int toPort) {
try {
_msgs.put(new MsgData((int)(msgId & 0xffffffff), size, proto, fromPort, toPort));
} catch (InterruptedException ie) {}
}
@Override
public void run() {
MsgData msg;
_alive=true;
while (_alive) {
try {
msg = _msgs.take();
} catch (InterruptedException ie) {
_log.debug("I2PSessionMuxedImpl.run() InterruptedException " + String.valueOf(_msgs.size()) + " Messages, Alive " + _alive);
continue;
}
if (msg.size == POISON_SIZE) {
// System.out.println("I2PSessionMuxedImpl.run() POISONED");
break;
}
try {
_demultiplexer.messageAvailable(I2PSessionMuxedImpl.this,
msg.id, msg.size, msg.proto, msg.fromPort, msg.toPort);
} catch (Exception e) {
_log.error("Error notifying app of message availability", e);
}
}
}
}
/** let's keep this simple */
private static class MsgData {
public final int id, size, proto, fromPort, toPort;
public MsgData(int i, int s, int p, int f, int t) {
id = i;
size = s;
proto = p;
fromPort = f;
toPort = t;
}
}
/**
* No, we couldn't put any protocol byte in front of everything and
* keep backward compatibility. But there are several bytes that
* are unused AND unchecked in the gzip header in releases <= 0.7.
* So let's use 5 of them for a protocol and two 2-byte ports.
*
* Following are all the methods to hide the
* protocol, fromPort, and toPort in the gzip header
*
* The fields used are all ignored on receive in ResettableGzipInputStream
*
* See also ResettableGzipOutputStream.
* Ref: RFC 1952
*
*/
/** OS byte in gzip header */
private static final int PROTO_BYTE = 9;
/** Upper two bytes of MTIME in gzip header */
private static final int FROMPORT_BYTES = 4;
/** Lower two bytes of MTIME in gzip header */
private static final int TOPORT_BYTES = 6;
/** Non-muxed sets the OS byte to 0xff */
private static int getProto(MessagePayloadMessage msg) {
int rv = getByte(msg, PROTO_BYTE) & 0xff;
return rv == 0xff ? PROTO_UNSPECIFIED : rv;
}
/** Non-muxed sets the MTIME bytes to 0 */
private static int getFromPort(MessagePayloadMessage msg) {
return (((getByte(msg, FROMPORT_BYTES) & 0xff) << 8) |
(getByte(msg, FROMPORT_BYTES + 1) & 0xff));
}
/** Non-muxed sets the MTIME bytes to 0 */
private static int getToPort(MessagePayloadMessage msg) {
return (((getByte(msg, TOPORT_BYTES) & 0xff) << 8) |
(getByte(msg, TOPORT_BYTES + 1) & 0xff));
}
private static int getByte(MessagePayloadMessage msg, int i) {
return msg.getPayload().getUnencryptedData()[i] & 0xff;
}
private static void setProto(byte[] payload, int p) {
payload[PROTO_BYTE] = (byte) (p & 0xff);
}
private static void setFromPort(byte[] payload, int p) {
payload[FROMPORT_BYTES] = (byte) ((p >> 8) & 0xff);
payload[FROMPORT_BYTES + 1] = (byte) (p & 0xff);
}
private static void setToPort(byte[] payload, int p) {
payload[TOPORT_BYTES] = (byte) ((p >> 8) & 0xff);
payload[TOPORT_BYTES + 1] = (byte) (p & 0xff);
}
}
| [
"Razuvaev_DD@mail.ru"
] | Razuvaev_DD@mail.ru |
db69ef618f3131e5d291ea54690c34735e6e5f41 | 5a02eecbb75247b27fee9dde1e95d736593b8368 | /src/Lessons/day35_encapsulation/PrinterTest.java | a010f208c1444dab01b53528ab2b7b838d1b051c | [] | no_license | susaglam/Java | 8da9e41af5aa70f85753cf94b323b1eb98686e1b | 07714fc04c2ec19d3bf6cc9f24b5c5fea33b5a52 | refs/heads/master | 2023-02-21T15:28:47.510990 | 2021-01-16T12:37:56 | 2021-01-16T12:37:56 | 296,389,449 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 580 | java | package Lessons.day35_encapsulation;
public class PrinterTest {
public static void main(String[] args) {
Printer printer = new Printer(50, false);
System.out.println("initial page count = " +printer.getPagesPrinted());
int pagesPrinted = printer.printPages(4);
System.out.println("Pages printed was " + pagesPrinted +" new total print count for printer = " +printer.getPagesPrinted());
pagesPrinted = printer.printPages(2);
System.out.println("Pages printed was " + pagesPrinted +" new total print count for printer = " +printer.getPagesPrinted());
}
}
| [
"sukru_saglam@hotmail.com"
] | sukru_saglam@hotmail.com |
ae72a46649fdbd9fc7ad43aa2fbf3cadd17668ce | 2e4a6ab2e7c100b991ed6281c7266a81139edcce | /app/src/main/java/com/averroes/hanouti/adapters/ProductFilter.java | c4af43954abd34388cd13350370b5dc7f6b0cd2e | [] | no_license | averroes96/Bled | 9d3de6bea2c19cc298063f31f39782977f47216d | 2fac76e7a245a27bc4c4e9423861c29cc66bdef0 | refs/heads/master | 2022-12-06T21:19:45.963309 | 2020-09-04T21:57:11 | 2020-09-04T21:57:11 | 291,849,232 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,511 | java | package com.averroes.hanouti.adapters;
import android.widget.Filter;
import com.averroes.hanouti.modals.Product;
import java.util.ArrayList;
public class ProductFilter extends Filter {
private ProductAdapter adapter;
private ArrayList<Product> filteredProducts;
public ProductFilter(ProductAdapter adapter, ArrayList<Product> products) {
this.adapter = adapter;
this.filteredProducts = products;
}
@Override
protected FilterResults performFiltering(CharSequence charSequence) {
FilterResults results = new FilterResults();
if(charSequence != null && charSequence.length() > 0){
charSequence = charSequence.toString().toUpperCase();
ArrayList<Product> filtered = new ArrayList<>();
for(Product product : filteredProducts){
if(product.getTitle().toUpperCase().contains(charSequence) || product.getCategory().toUpperCase().contains(charSequence)){
filtered.add(product);
}
}
results.count = filtered.size();
results.values = filtered;
}
else{
results.count = filteredProducts.size();
results.values = filteredProducts;
}
return results;
}
@Override
protected void publishResults(CharSequence charSequence, FilterResults filterResults) {
adapter.products = (ArrayList<Product>)filterResults.values;
adapter.notifyDataSetChanged();
}
}
| [
"46904388+averroes96@users.noreply.github.com"
] | 46904388+averroes96@users.noreply.github.com |
c03de66dce46dd26cfa34a5bbd472253b3ec571c | 69011b4a6233db48e56db40bc8a140f0dd721d62 | /src/com/jshx/xzdccfjdsdw/service/SpoPenDecComService.java | 79f0e3696a90e40ca712ddfa4deeecc01db8c554 | [] | no_license | gechenrun/scysuper | bc5397e5220ee42dae5012a0efd23397c8c5cda0 | e706d287700ff11d289c16f118ce7e47f7f9b154 | refs/heads/master | 2020-03-23T19:06:43.185061 | 2018-06-10T07:51:18 | 2018-06-10T07:51:18 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,212 | java | package com.jshx.xzdccfjdsdw.service;
import java.util.List;
import java.util.Map;
import com.jshx.core.base.service.BaseService;
import com.jshx.core.base.vo.Pagination;
import com.jshx.xzdccfjdsdw.entity.SpoPenDecCom;
public interface SpoPenDecComService extends BaseService
{
/**
* 分页查询
* @param page 分页信息
* @param paraMap 查询条件信息
* @return 分页信息
*/
public Pagination findByPage(Pagination page, Map<String, Object> paraMap);
/**
* 根据主键ID查询信息
* @param id 主键ID
* @return 主键ID对应的信息
*/
public SpoPenDecCom getById(String id);
/**
* 保存信息
* @param model 信息
*/
public void save(SpoPenDecCom model);
/**
* 修改信息
* @param model 信息
*/
public void update(SpoPenDecCom model);
/**
* 物理删除信息
* @param ids 主键ID列表
*/
public void delete(String[] ids);
/**
* 逻辑删除信息
* @param ids 主键ID列表
*/
public void deleteWithFlag(String ids);
/**
* 查询所有记录
* @param page 分页信息
* @param paraMap 查询条件信息
* @return 分页信息
*/
public List<SpoPenDecCom> findSpoPenDecCom(Map<String, Object> paraMap);
}
| [
"shellchange@sina.com"
] | shellchange@sina.com |
3a4606959faf498d101e7875ce8b829753ec3c79 | d0352f49cfb42f3c0d583389ab57598640c78fc6 | /week2/TestExamples/src/test/java/com/revature/cactus/CactusTest1.java | 59f9bdf54fabbb431204c2b9c60c62bd98ca75bd | [] | no_license | 201026-reston-java-msa/demos | c0c79139391e70fe0393be2e705182e17ee4b244 | 57a56ff56df12afff167565554effac0ea284336 | refs/heads/main | 2023-03-29T04:27:20.165396 | 2021-03-31T11:21:20 | 2021-03-31T11:21:20 | 307,373,580 | 1 | 4 | null | null | null | null | UTF-8 | Java | false | false | 2,413 | java | package com.revature.cactus;
import static org.junit.Assert.assertEquals;
import java.util.ArrayList;
import java.util.List;
import org.junit.Before;
import org.junit.Test;
import com.revature.Cactus;
import com.revature.Flower;
public class CactusTest1 {
private static Cactus cactus;
@Before
public void setUp() throws Exception {
List<Flower> startingFlowers = new ArrayList<Flower>();
startingFlowers.add(Flower.Sunflower);
cactus = new Cactus(10, 2, "Green", startingFlowers);
}
@Test
public void testAddFlower() {
// our cactus has a Sunflower..
// by the end of the test, we want to ASSERTEQUALS
// that we have both a sunflower and a bud
cactus.addFlower(Flower.Bud);
List<Flower> myCactusFlowers = new ArrayList<Flower>();
myCactusFlowers.add(Flower.Sunflower);
myCactusFlowers.add(Flower.Bud);
assertEquals(myCactusFlowers, cactus.getFlowers());
}
@Test
public void testRemoveFlower() {
List<Flower> expected = new ArrayList<Flower>();
// expected list.size == 0;
cactus.removeFlower(Flower.Sunflower);
// now cactus.flowers.size == 0....
assertEquals(expected, cactus.getFlowers()); // 0 & 0
}
// This tests that we indeed CANNOT pass negative values in because otherwis
// we'll throw the exception as we defined in our method body
@Test(expected = IllegalArgumentException.class)
public void testGrowException() {
cactus.grow(-3.0);
}
@Test
public void testSeeding() {
List<Flower> childFlowers = new ArrayList<Flower>();
childFlowers.add(Flower.Sunflower);
// the expected baby Cactus object to return
Cactus expected = new Cactus(0.1, 0.2, cactus.getColor(), childFlowers);
assertEquals(expected, cactus.seeding());
// That when you create tests that COMPARE OBJECTS
// YOU MUST OVERRIDE THE .EQUALS() METHOD!!
}
@Test
public void testBloom() {
// we are only testing the int value that is returned from the bloom();
assertEquals(1, cactus.bloom());
}
// DONT'T WORRY ABOUT THIS
// static boolean testDoubleEquality(Double one, Double two, Double delta){
// return Math.abs(one - two)< delta;
// }
//
// public static void main(String[] args) {
// System.out.println(testDoubleEquality((double) 101, cactus.grow(100), 1.0));
// }
//
// @Test
// public void testGrowReturn() {
//
//
// assertEquals(new Double(101), new Double(cactus.grow(100)));
// }
}
| [
"msophiagavrila@gmail.com"
] | msophiagavrila@gmail.com |
208414f8e928d6e5f6690a79d6c2b34462766db7 | 0e3414d4b05c164b54cba648e20d7341fc9b4bd9 | /app/src/main/java/com/example/administrator/ui/fragment/User_F.java | e7046d4ef39b0601f20d94c4a86682c49d41773f | [] | no_license | Cruizhi/TongCheng-Client | 3874b7b4fd579c7ea6d28c4bbd42c270132fab07 | 594d5142b00ed60da33fc1180859e868ccd6e5fa | refs/heads/master | 2020-03-11T08:15:00.466623 | 2018-05-28T07:24:33 | 2018-05-28T07:24:33 | 129,878,919 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 4,414 | java | package com.example.administrator.ui.fragment;
import android.content.Intent;
import android.content.SharedPreferences;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.Button;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.RelativeLayout;
import android.widget.TextView;
import com.example.administrator.activity.Login;
import com.example.administrator.ui.activity.Setting;
import com.example.administrator.ui.activity.UserDetail;
import com.example.administrator.tongcheng.R;
import com.example.administrator.utils.L;
import butterknife.BindView;
import butterknife.ButterKnife;
import butterknife.OnClick;
import static com.mob.tools.utils.DeviceHelper.getApplication;
/**
* Created by Administrator on 2018/2/2.
*/
public class User_F extends Fragment implements View.OnClickListener{
@BindView(R.id.rl_user_top)
RelativeLayout RlHead;
@BindView(R.id.btn_user_setting)
Button BtnSetting;
@BindView(R.id.iv_user_indent)
ImageView IvIndent;
@BindView(R.id.iv_user_delivery)
ImageView IvDeliery;
@BindView(R.id.iv_user_evaluate)
ImageView IvEvaluate;
@BindView(R.id.iv_user_release)
ImageView IvRelease;
@BindView(R.id.iv_user_collection)
ImageView IvCollection;
@BindView(R.id.tv_user_username)
TextView TvUsername;
@BindView(R.id.tv_user_userphone)
TextView TvUserphone;
//当前用户信息
private String userid;
private String username;
private String password;
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,Bundle savedInstanceState){
//引入布局
View view = LayoutInflater.from(getActivity()).inflate(R.layout.fragment_user,null);
//设置全屏
LinearLayout.LayoutParams lp = new LinearLayout.LayoutParams(LinearLayout.LayoutParams.MATCH_PARENT,
LinearLayout.LayoutParams.MATCH_PARENT);
view.setLayoutParams(lp);
ButterKnife.bind(this,view);
getuserinfo(); //获取当前用户信息
init(view); //初始化设置
L.i_crz("User_F--onCreateView");
return view;
}
private void getuserinfo(){
SharedPreferences shareP = getActivity().getSharedPreferences("userinfo",getApplication().MODE_PRIVATE);
userid = shareP.getString("phone","");
username = shareP.getString("username","");
}
private void init(View view){
if(userid != null && !"".equals(userid)){
TvUsername.setText("用户名:" + username);
TvUserphone.setText("账号:" + userid);
}else{
TvUsername.setText("用户名:");
TvUserphone.setText("账号:");
}
}
// @Override
@OnClick({R.id.iv_user_collection,R.id.iv_user_release,R.id.iv_user_evaluate,R.id.iv_user_delivery,
R.id.iv_user_indent,R.id.rl_user_top,R.id.btn_user_setting})
public void onClick(View v) {
switch(v.getId()){
case R.id.rl_user_top:
SharedPreferences shareP = getActivity().getSharedPreferences("userinfo",getApplication().MODE_PRIVATE);
String userid = shareP.getString("phone","");
if(!"".equals(userid)){
//用户设置
Intent intent0 = new Intent(getApplication(), UserDetail.class);
startActivity(intent0);
}else{
Intent intent1 = new Intent(getApplication(),Login.class);
startActivity(intent1);
}
break;
case R.id.btn_user_setting:
Intent intent1 = new Intent(getApplication(),Setting.class);
startActivity(intent1);
break;
default:
break;
}
}
@Override
public void onResume(){
super.onResume();
SharedPreferences shareP = getActivity().getSharedPreferences("userinfo",getApplication().MODE_PRIVATE);
userid = shareP.getString("phone","");
username = shareP.getString("username","");
TvUsername.setText("用户名:" + username);
TvUserphone.setText("账号:" + userid);
L.i_crz("User_F--onResume--userid:"+userid);
}
}
| [
"32972639+Cruizhi@users.noreply.github.com"
] | 32972639+Cruizhi@users.noreply.github.com |
c5fa0e1f6e5870a7f8b550b7919012a062390dc5 | 8d577a2e20d209663e05a5145f299b9d5413c8b5 | /src/java/Model/ActionStatus.java | 80864d18134172e21007f13bd8d7ab6f01bfefdc | [] | no_license | SerrusJonathan/Hackaton2018CRM | cf52306d3b4486d9eb59e063bcf5e1c2a4e2d83b | 505456b210c9a5fa579609c92ed9bae182250463 | refs/heads/master | 2021-09-12T17:52:16.574080 | 2018-04-19T12:47:15 | 2018-04-19T12:47:15 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 408 | 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 Model;
import java.nio.channels.CancelledKeyException;
import sun.security.util.PendingException;
/**
*
* @author Jonathan
*/
public enum ActionStatus {
Open,
Cancelled,
Pending,
Closed;
}
| [
"jonathan.serrus@student.howest.be"
] | jonathan.serrus@student.howest.be |
2e99d09b3aa9e5e49b104312f1fe0e448bc15f9e | 7008254100e08b37f90edd95e4bef07264bfa7a7 | /MobileProgrammingICP/ICP1/Source Code/HelloWorldApp/app/libs/build/generated/not_namespaced_r_class_sources/debug/processDebugResources/r/android/support/v7/appcompat/R.java | deaea67895cebb1f10466daaf0a9a686e9f2c5d5 | [] | no_license | htata31/WebProgrammingICP | 5c4541fb92ab160a1124c20f53a080097cdfd37f | 34582e933e34ed871959cc999776af63c770746d | refs/heads/master | 2023-01-10T15:56:28.361098 | 2019-11-24T00:04:39 | 2019-11-24T00:05:04 | 204,198,004 | 0 | 1 | null | 2023-01-05T23:16:08 | 2019-08-24T18:41:06 | Java | UTF-8 | Java | false | false | 120,814 | java | /* AUTO-GENERATED FILE. DO NOT MODIFY.
*
* This class was automatically generated by the
* gradle plugin from the resource data it found. It
* should not be modified by hand.
*/
package android.support.v7.appcompat;
public final class R {
private R() {}
public static final class anim {
private anim() {}
public static final int abc_fade_in = 0x7f010000;
public static final int abc_fade_out = 0x7f010001;
public static final int abc_grow_fade_in_from_bottom = 0x7f010002;
public static final int abc_popup_enter = 0x7f010003;
public static final int abc_popup_exit = 0x7f010004;
public static final int abc_shrink_fade_out_from_bottom = 0x7f010005;
public static final int abc_slide_in_bottom = 0x7f010006;
public static final int abc_slide_in_top = 0x7f010007;
public static final int abc_slide_out_bottom = 0x7f010008;
public static final int abc_slide_out_top = 0x7f010009;
public static final int abc_tooltip_enter = 0x7f01000a;
public static final int abc_tooltip_exit = 0x7f01000b;
}
public static final class attr {
private attr() {}
public static final int actionBarDivider = 0x7f020000;
public static final int actionBarItemBackground = 0x7f020001;
public static final int actionBarPopupTheme = 0x7f020002;
public static final int actionBarSize = 0x7f020003;
public static final int actionBarSplitStyle = 0x7f020004;
public static final int actionBarStyle = 0x7f020005;
public static final int actionBarTabBarStyle = 0x7f020006;
public static final int actionBarTabStyle = 0x7f020007;
public static final int actionBarTabTextStyle = 0x7f020008;
public static final int actionBarTheme = 0x7f020009;
public static final int actionBarWidgetTheme = 0x7f02000a;
public static final int actionButtonStyle = 0x7f02000b;
public static final int actionDropDownStyle = 0x7f02000c;
public static final int actionLayout = 0x7f02000d;
public static final int actionMenuTextAppearance = 0x7f02000e;
public static final int actionMenuTextColor = 0x7f02000f;
public static final int actionModeBackground = 0x7f020010;
public static final int actionModeCloseButtonStyle = 0x7f020011;
public static final int actionModeCloseDrawable = 0x7f020012;
public static final int actionModeCopyDrawable = 0x7f020013;
public static final int actionModeCutDrawable = 0x7f020014;
public static final int actionModeFindDrawable = 0x7f020015;
public static final int actionModePasteDrawable = 0x7f020016;
public static final int actionModePopupWindowStyle = 0x7f020017;
public static final int actionModeSelectAllDrawable = 0x7f020018;
public static final int actionModeShareDrawable = 0x7f020019;
public static final int actionModeSplitBackground = 0x7f02001a;
public static final int actionModeStyle = 0x7f02001b;
public static final int actionModeWebSearchDrawable = 0x7f02001c;
public static final int actionOverflowButtonStyle = 0x7f02001d;
public static final int actionOverflowMenuStyle = 0x7f02001e;
public static final int actionProviderClass = 0x7f02001f;
public static final int actionViewClass = 0x7f020020;
public static final int activityChooserViewStyle = 0x7f020021;
public static final int alertDialogButtonGroupStyle = 0x7f020022;
public static final int alertDialogCenterButtons = 0x7f020023;
public static final int alertDialogStyle = 0x7f020024;
public static final int alertDialogTheme = 0x7f020025;
public static final int allowStacking = 0x7f020026;
public static final int alpha = 0x7f020027;
public static final int alphabeticModifiers = 0x7f020028;
public static final int arrowHeadLength = 0x7f020029;
public static final int arrowShaftLength = 0x7f02002a;
public static final int autoCompleteTextViewStyle = 0x7f02002b;
public static final int autoSizeMaxTextSize = 0x7f02002c;
public static final int autoSizeMinTextSize = 0x7f02002d;
public static final int autoSizePresetSizes = 0x7f02002e;
public static final int autoSizeStepGranularity = 0x7f02002f;
public static final int autoSizeTextType = 0x7f020030;
public static final int background = 0x7f020031;
public static final int backgroundSplit = 0x7f020032;
public static final int backgroundStacked = 0x7f020033;
public static final int backgroundTint = 0x7f020034;
public static final int backgroundTintMode = 0x7f020035;
public static final int barLength = 0x7f020036;
public static final int borderlessButtonStyle = 0x7f020039;
public static final int buttonBarButtonStyle = 0x7f02003a;
public static final int buttonBarNegativeButtonStyle = 0x7f02003b;
public static final int buttonBarNeutralButtonStyle = 0x7f02003c;
public static final int buttonBarPositiveButtonStyle = 0x7f02003d;
public static final int buttonBarStyle = 0x7f02003e;
public static final int buttonGravity = 0x7f02003f;
public static final int buttonIconDimen = 0x7f020040;
public static final int buttonPanelSideLayout = 0x7f020041;
public static final int buttonStyle = 0x7f020042;
public static final int buttonStyleSmall = 0x7f020043;
public static final int buttonTint = 0x7f020044;
public static final int buttonTintMode = 0x7f020045;
public static final int checkboxStyle = 0x7f020047;
public static final int checkedTextViewStyle = 0x7f020048;
public static final int closeIcon = 0x7f020049;
public static final int closeItemLayout = 0x7f02004a;
public static final int collapseContentDescription = 0x7f02004b;
public static final int collapseIcon = 0x7f02004c;
public static final int color = 0x7f02004d;
public static final int colorAccent = 0x7f02004e;
public static final int colorBackgroundFloating = 0x7f02004f;
public static final int colorButtonNormal = 0x7f020050;
public static final int colorControlActivated = 0x7f020051;
public static final int colorControlHighlight = 0x7f020052;
public static final int colorControlNormal = 0x7f020053;
public static final int colorError = 0x7f020054;
public static final int colorPrimary = 0x7f020055;
public static final int colorPrimaryDark = 0x7f020056;
public static final int colorSwitchThumbNormal = 0x7f020057;
public static final int commitIcon = 0x7f020058;
public static final int contentDescription = 0x7f02005c;
public static final int contentInsetEnd = 0x7f02005d;
public static final int contentInsetEndWithActions = 0x7f02005e;
public static final int contentInsetLeft = 0x7f02005f;
public static final int contentInsetRight = 0x7f020060;
public static final int contentInsetStart = 0x7f020061;
public static final int contentInsetStartWithNavigation = 0x7f020062;
public static final int controlBackground = 0x7f020063;
public static final int coordinatorLayoutStyle = 0x7f020064;
public static final int customNavigationLayout = 0x7f020065;
public static final int defaultQueryHint = 0x7f020066;
public static final int dialogCornerRadius = 0x7f020067;
public static final int dialogPreferredPadding = 0x7f020068;
public static final int dialogTheme = 0x7f020069;
public static final int displayOptions = 0x7f02006a;
public static final int divider = 0x7f02006b;
public static final int dividerHorizontal = 0x7f02006c;
public static final int dividerPadding = 0x7f02006d;
public static final int dividerVertical = 0x7f02006e;
public static final int drawableSize = 0x7f02006f;
public static final int drawerArrowStyle = 0x7f020070;
public static final int dropDownListViewStyle = 0x7f020071;
public static final int dropdownListPreferredItemHeight = 0x7f020072;
public static final int editTextBackground = 0x7f020073;
public static final int editTextColor = 0x7f020074;
public static final int editTextStyle = 0x7f020075;
public static final int elevation = 0x7f020076;
public static final int expandActivityOverflowButtonDrawable = 0x7f020078;
public static final int firstBaselineToTopHeight = 0x7f020079;
public static final int font = 0x7f02007a;
public static final int fontFamily = 0x7f02007b;
public static final int fontProviderAuthority = 0x7f02007c;
public static final int fontProviderCerts = 0x7f02007d;
public static final int fontProviderFetchStrategy = 0x7f02007e;
public static final int fontProviderFetchTimeout = 0x7f02007f;
public static final int fontProviderPackage = 0x7f020080;
public static final int fontProviderQuery = 0x7f020081;
public static final int fontStyle = 0x7f020082;
public static final int fontVariationSettings = 0x7f020083;
public static final int fontWeight = 0x7f020084;
public static final int gapBetweenBars = 0x7f020085;
public static final int goIcon = 0x7f020086;
public static final int height = 0x7f020087;
public static final int hideOnContentScroll = 0x7f020088;
public static final int homeAsUpIndicator = 0x7f020089;
public static final int homeLayout = 0x7f02008a;
public static final int icon = 0x7f02008b;
public static final int iconTint = 0x7f02008c;
public static final int iconTintMode = 0x7f02008d;
public static final int iconifiedByDefault = 0x7f02008e;
public static final int imageButtonStyle = 0x7f02008f;
public static final int indeterminateProgressStyle = 0x7f020090;
public static final int initialActivityCount = 0x7f020091;
public static final int isLightTheme = 0x7f020092;
public static final int itemPadding = 0x7f020093;
public static final int keylines = 0x7f020094;
public static final int lastBaselineToBottomHeight = 0x7f020095;
public static final int layout = 0x7f020096;
public static final int layout_anchor = 0x7f020097;
public static final int layout_anchorGravity = 0x7f020098;
public static final int layout_behavior = 0x7f020099;
public static final int layout_dodgeInsetEdges = 0x7f0200c3;
public static final int layout_insetEdge = 0x7f0200cc;
public static final int layout_keyline = 0x7f0200cd;
public static final int lineHeight = 0x7f0200cf;
public static final int listChoiceBackgroundIndicator = 0x7f0200d0;
public static final int listDividerAlertDialog = 0x7f0200d1;
public static final int listItemLayout = 0x7f0200d2;
public static final int listLayout = 0x7f0200d3;
public static final int listMenuViewStyle = 0x7f0200d4;
public static final int listPopupWindowStyle = 0x7f0200d5;
public static final int listPreferredItemHeight = 0x7f0200d6;
public static final int listPreferredItemHeightLarge = 0x7f0200d7;
public static final int listPreferredItemHeightSmall = 0x7f0200d8;
public static final int listPreferredItemPaddingLeft = 0x7f0200d9;
public static final int listPreferredItemPaddingRight = 0x7f0200da;
public static final int logo = 0x7f0200db;
public static final int logoDescription = 0x7f0200dc;
public static final int maxButtonHeight = 0x7f0200dd;
public static final int measureWithLargestChild = 0x7f0200de;
public static final int multiChoiceItemLayout = 0x7f0200df;
public static final int navigationContentDescription = 0x7f0200e0;
public static final int navigationIcon = 0x7f0200e1;
public static final int navigationMode = 0x7f0200e2;
public static final int numericModifiers = 0x7f0200e3;
public static final int overlapAnchor = 0x7f0200e4;
public static final int paddingBottomNoButtons = 0x7f0200e5;
public static final int paddingEnd = 0x7f0200e6;
public static final int paddingStart = 0x7f0200e7;
public static final int paddingTopNoTitle = 0x7f0200e8;
public static final int panelBackground = 0x7f0200e9;
public static final int panelMenuListTheme = 0x7f0200ea;
public static final int panelMenuListWidth = 0x7f0200eb;
public static final int popupMenuStyle = 0x7f0200ec;
public static final int popupTheme = 0x7f0200ed;
public static final int popupWindowStyle = 0x7f0200ee;
public static final int preserveIconSpacing = 0x7f0200ef;
public static final int progressBarPadding = 0x7f0200f0;
public static final int progressBarStyle = 0x7f0200f1;
public static final int queryBackground = 0x7f0200f2;
public static final int queryHint = 0x7f0200f3;
public static final int radioButtonStyle = 0x7f0200f4;
public static final int ratingBarStyle = 0x7f0200f5;
public static final int ratingBarStyleIndicator = 0x7f0200f6;
public static final int ratingBarStyleSmall = 0x7f0200f7;
public static final int searchHintIcon = 0x7f0200f8;
public static final int searchIcon = 0x7f0200f9;
public static final int searchViewStyle = 0x7f0200fa;
public static final int seekBarStyle = 0x7f0200fb;
public static final int selectableItemBackground = 0x7f0200fc;
public static final int selectableItemBackgroundBorderless = 0x7f0200fd;
public static final int showAsAction = 0x7f0200fe;
public static final int showDividers = 0x7f0200ff;
public static final int showText = 0x7f020100;
public static final int showTitle = 0x7f020101;
public static final int singleChoiceItemLayout = 0x7f020102;
public static final int spinBars = 0x7f020103;
public static final int spinnerDropDownItemStyle = 0x7f020104;
public static final int spinnerStyle = 0x7f020105;
public static final int splitTrack = 0x7f020106;
public static final int srcCompat = 0x7f020107;
public static final int state_above_anchor = 0x7f020108;
public static final int statusBarBackground = 0x7f020109;
public static final int subMenuArrow = 0x7f02010a;
public static final int submitBackground = 0x7f02010b;
public static final int subtitle = 0x7f02010c;
public static final int subtitleTextAppearance = 0x7f02010d;
public static final int subtitleTextColor = 0x7f02010e;
public static final int subtitleTextStyle = 0x7f02010f;
public static final int suggestionRowLayout = 0x7f020110;
public static final int switchMinWidth = 0x7f020111;
public static final int switchPadding = 0x7f020112;
public static final int switchStyle = 0x7f020113;
public static final int switchTextAppearance = 0x7f020114;
public static final int textAllCaps = 0x7f020115;
public static final int textAppearanceLargePopupMenu = 0x7f020116;
public static final int textAppearanceListItem = 0x7f020117;
public static final int textAppearanceListItemSecondary = 0x7f020118;
public static final int textAppearanceListItemSmall = 0x7f020119;
public static final int textAppearancePopupMenuHeader = 0x7f02011a;
public static final int textAppearanceSearchResultSubtitle = 0x7f02011b;
public static final int textAppearanceSearchResultTitle = 0x7f02011c;
public static final int textAppearanceSmallPopupMenu = 0x7f02011d;
public static final int textColorAlertDialogListItem = 0x7f02011e;
public static final int textColorSearchUrl = 0x7f02011f;
public static final int theme = 0x7f020120;
public static final int thickness = 0x7f020121;
public static final int thumbTextPadding = 0x7f020122;
public static final int thumbTint = 0x7f020123;
public static final int thumbTintMode = 0x7f020124;
public static final int tickMark = 0x7f020125;
public static final int tickMarkTint = 0x7f020126;
public static final int tickMarkTintMode = 0x7f020127;
public static final int tint = 0x7f020128;
public static final int tintMode = 0x7f020129;
public static final int title = 0x7f02012a;
public static final int titleMargin = 0x7f02012b;
public static final int titleMarginBottom = 0x7f02012c;
public static final int titleMarginEnd = 0x7f02012d;
public static final int titleMarginStart = 0x7f02012e;
public static final int titleMarginTop = 0x7f02012f;
public static final int titleMargins = 0x7f020130;
public static final int titleTextAppearance = 0x7f020131;
public static final int titleTextColor = 0x7f020132;
public static final int titleTextStyle = 0x7f020133;
public static final int toolbarNavigationButtonStyle = 0x7f020134;
public static final int toolbarStyle = 0x7f020135;
public static final int tooltipForegroundColor = 0x7f020136;
public static final int tooltipFrameBackground = 0x7f020137;
public static final int tooltipText = 0x7f020138;
public static final int track = 0x7f020139;
public static final int trackTint = 0x7f02013a;
public static final int trackTintMode = 0x7f02013b;
public static final int ttcIndex = 0x7f02013c;
public static final int viewInflaterClass = 0x7f02013d;
public static final int voiceIcon = 0x7f02013e;
public static final int windowActionBar = 0x7f02013f;
public static final int windowActionBarOverlay = 0x7f020140;
public static final int windowActionModeOverlay = 0x7f020141;
public static final int windowFixedHeightMajor = 0x7f020142;
public static final int windowFixedHeightMinor = 0x7f020143;
public static final int windowFixedWidthMajor = 0x7f020144;
public static final int windowFixedWidthMinor = 0x7f020145;
public static final int windowMinWidthMajor = 0x7f020146;
public static final int windowMinWidthMinor = 0x7f020147;
public static final int windowNoTitle = 0x7f020148;
}
public static final class bool {
private bool() {}
public static final int abc_action_bar_embed_tabs = 0x7f030000;
public static final int abc_allow_stacked_button_bar = 0x7f030001;
public static final int abc_config_actionMenuItemAllCaps = 0x7f030002;
}
public static final class color {
private color() {}
public static final int abc_background_cache_hint_selector_material_dark = 0x7f040000;
public static final int abc_background_cache_hint_selector_material_light = 0x7f040001;
public static final int abc_btn_colored_borderless_text_material = 0x7f040002;
public static final int abc_btn_colored_text_material = 0x7f040003;
public static final int abc_color_highlight_material = 0x7f040004;
public static final int abc_hint_foreground_material_dark = 0x7f040005;
public static final int abc_hint_foreground_material_light = 0x7f040006;
public static final int abc_input_method_navigation_guard = 0x7f040007;
public static final int abc_primary_text_disable_only_material_dark = 0x7f040008;
public static final int abc_primary_text_disable_only_material_light = 0x7f040009;
public static final int abc_primary_text_material_dark = 0x7f04000a;
public static final int abc_primary_text_material_light = 0x7f04000b;
public static final int abc_search_url_text = 0x7f04000c;
public static final int abc_search_url_text_normal = 0x7f04000d;
public static final int abc_search_url_text_pressed = 0x7f04000e;
public static final int abc_search_url_text_selected = 0x7f04000f;
public static final int abc_secondary_text_material_dark = 0x7f040010;
public static final int abc_secondary_text_material_light = 0x7f040011;
public static final int abc_tint_btn_checkable = 0x7f040012;
public static final int abc_tint_default = 0x7f040013;
public static final int abc_tint_edittext = 0x7f040014;
public static final int abc_tint_seek_thumb = 0x7f040015;
public static final int abc_tint_spinner = 0x7f040016;
public static final int abc_tint_switch_track = 0x7f040017;
public static final int accent_material_dark = 0x7f040018;
public static final int accent_material_light = 0x7f040019;
public static final int background_floating_material_dark = 0x7f04001a;
public static final int background_floating_material_light = 0x7f04001b;
public static final int background_material_dark = 0x7f04001c;
public static final int background_material_light = 0x7f04001d;
public static final int bright_foreground_disabled_material_dark = 0x7f04001e;
public static final int bright_foreground_disabled_material_light = 0x7f04001f;
public static final int bright_foreground_inverse_material_dark = 0x7f040020;
public static final int bright_foreground_inverse_material_light = 0x7f040021;
public static final int bright_foreground_material_dark = 0x7f040022;
public static final int bright_foreground_material_light = 0x7f040023;
public static final int button_material_dark = 0x7f040024;
public static final int button_material_light = 0x7f040025;
public static final int dim_foreground_disabled_material_dark = 0x7f040029;
public static final int dim_foreground_disabled_material_light = 0x7f04002a;
public static final int dim_foreground_material_dark = 0x7f04002b;
public static final int dim_foreground_material_light = 0x7f04002c;
public static final int error_color_material_dark = 0x7f04002d;
public static final int error_color_material_light = 0x7f04002e;
public static final int foreground_material_dark = 0x7f04002f;
public static final int foreground_material_light = 0x7f040030;
public static final int highlighted_text_material_dark = 0x7f040031;
public static final int highlighted_text_material_light = 0x7f040032;
public static final int material_blue_grey_800 = 0x7f040033;
public static final int material_blue_grey_900 = 0x7f040034;
public static final int material_blue_grey_950 = 0x7f040035;
public static final int material_deep_teal_200 = 0x7f040036;
public static final int material_deep_teal_500 = 0x7f040037;
public static final int material_grey_100 = 0x7f040038;
public static final int material_grey_300 = 0x7f040039;
public static final int material_grey_50 = 0x7f04003a;
public static final int material_grey_600 = 0x7f04003b;
public static final int material_grey_800 = 0x7f04003c;
public static final int material_grey_850 = 0x7f04003d;
public static final int material_grey_900 = 0x7f04003e;
public static final int notification_action_color_filter = 0x7f04003f;
public static final int notification_icon_bg_color = 0x7f040040;
public static final int primary_dark_material_dark = 0x7f040041;
public static final int primary_dark_material_light = 0x7f040042;
public static final int primary_material_dark = 0x7f040043;
public static final int primary_material_light = 0x7f040044;
public static final int primary_text_default_material_dark = 0x7f040045;
public static final int primary_text_default_material_light = 0x7f040046;
public static final int primary_text_disabled_material_dark = 0x7f040047;
public static final int primary_text_disabled_material_light = 0x7f040048;
public static final int ripple_material_dark = 0x7f040049;
public static final int ripple_material_light = 0x7f04004a;
public static final int secondary_text_default_material_dark = 0x7f04004b;
public static final int secondary_text_default_material_light = 0x7f04004c;
public static final int secondary_text_disabled_material_dark = 0x7f04004d;
public static final int secondary_text_disabled_material_light = 0x7f04004e;
public static final int switch_thumb_disabled_material_dark = 0x7f04004f;
public static final int switch_thumb_disabled_material_light = 0x7f040050;
public static final int switch_thumb_material_dark = 0x7f040051;
public static final int switch_thumb_material_light = 0x7f040052;
public static final int switch_thumb_normal_material_dark = 0x7f040053;
public static final int switch_thumb_normal_material_light = 0x7f040054;
public static final int tooltip_background_dark = 0x7f040055;
public static final int tooltip_background_light = 0x7f040056;
}
public static final class dimen {
private dimen() {}
public static final int abc_action_bar_content_inset_material = 0x7f050000;
public static final int abc_action_bar_content_inset_with_nav = 0x7f050001;
public static final int abc_action_bar_default_height_material = 0x7f050002;
public static final int abc_action_bar_default_padding_end_material = 0x7f050003;
public static final int abc_action_bar_default_padding_start_material = 0x7f050004;
public static final int abc_action_bar_elevation_material = 0x7f050005;
public static final int abc_action_bar_icon_vertical_padding_material = 0x7f050006;
public static final int abc_action_bar_overflow_padding_end_material = 0x7f050007;
public static final int abc_action_bar_overflow_padding_start_material = 0x7f050008;
public static final int abc_action_bar_stacked_max_height = 0x7f050009;
public static final int abc_action_bar_stacked_tab_max_width = 0x7f05000a;
public static final int abc_action_bar_subtitle_bottom_margin_material = 0x7f05000b;
public static final int abc_action_bar_subtitle_top_margin_material = 0x7f05000c;
public static final int abc_action_button_min_height_material = 0x7f05000d;
public static final int abc_action_button_min_width_material = 0x7f05000e;
public static final int abc_action_button_min_width_overflow_material = 0x7f05000f;
public static final int abc_alert_dialog_button_bar_height = 0x7f050010;
public static final int abc_alert_dialog_button_dimen = 0x7f050011;
public static final int abc_button_inset_horizontal_material = 0x7f050012;
public static final int abc_button_inset_vertical_material = 0x7f050013;
public static final int abc_button_padding_horizontal_material = 0x7f050014;
public static final int abc_button_padding_vertical_material = 0x7f050015;
public static final int abc_cascading_menus_min_smallest_width = 0x7f050016;
public static final int abc_config_prefDialogWidth = 0x7f050017;
public static final int abc_control_corner_material = 0x7f050018;
public static final int abc_control_inset_material = 0x7f050019;
public static final int abc_control_padding_material = 0x7f05001a;
public static final int abc_dialog_corner_radius_material = 0x7f05001b;
public static final int abc_dialog_fixed_height_major = 0x7f05001c;
public static final int abc_dialog_fixed_height_minor = 0x7f05001d;
public static final int abc_dialog_fixed_width_major = 0x7f05001e;
public static final int abc_dialog_fixed_width_minor = 0x7f05001f;
public static final int abc_dialog_list_padding_bottom_no_buttons = 0x7f050020;
public static final int abc_dialog_list_padding_top_no_title = 0x7f050021;
public static final int abc_dialog_min_width_major = 0x7f050022;
public static final int abc_dialog_min_width_minor = 0x7f050023;
public static final int abc_dialog_padding_material = 0x7f050024;
public static final int abc_dialog_padding_top_material = 0x7f050025;
public static final int abc_dialog_title_divider_material = 0x7f050026;
public static final int abc_disabled_alpha_material_dark = 0x7f050027;
public static final int abc_disabled_alpha_material_light = 0x7f050028;
public static final int abc_dropdownitem_icon_width = 0x7f050029;
public static final int abc_dropdownitem_text_padding_left = 0x7f05002a;
public static final int abc_dropdownitem_text_padding_right = 0x7f05002b;
public static final int abc_edit_text_inset_bottom_material = 0x7f05002c;
public static final int abc_edit_text_inset_horizontal_material = 0x7f05002d;
public static final int abc_edit_text_inset_top_material = 0x7f05002e;
public static final int abc_floating_window_z = 0x7f05002f;
public static final int abc_list_item_padding_horizontal_material = 0x7f050030;
public static final int abc_panel_menu_list_width = 0x7f050031;
public static final int abc_progress_bar_height_material = 0x7f050032;
public static final int abc_search_view_preferred_height = 0x7f050033;
public static final int abc_search_view_preferred_width = 0x7f050034;
public static final int abc_seekbar_track_background_height_material = 0x7f050035;
public static final int abc_seekbar_track_progress_height_material = 0x7f050036;
public static final int abc_select_dialog_padding_start_material = 0x7f050037;
public static final int abc_switch_padding = 0x7f050038;
public static final int abc_text_size_body_1_material = 0x7f050039;
public static final int abc_text_size_body_2_material = 0x7f05003a;
public static final int abc_text_size_button_material = 0x7f05003b;
public static final int abc_text_size_caption_material = 0x7f05003c;
public static final int abc_text_size_display_1_material = 0x7f05003d;
public static final int abc_text_size_display_2_material = 0x7f05003e;
public static final int abc_text_size_display_3_material = 0x7f05003f;
public static final int abc_text_size_display_4_material = 0x7f050040;
public static final int abc_text_size_headline_material = 0x7f050041;
public static final int abc_text_size_large_material = 0x7f050042;
public static final int abc_text_size_medium_material = 0x7f050043;
public static final int abc_text_size_menu_header_material = 0x7f050044;
public static final int abc_text_size_menu_material = 0x7f050045;
public static final int abc_text_size_small_material = 0x7f050046;
public static final int abc_text_size_subhead_material = 0x7f050047;
public static final int abc_text_size_subtitle_material_toolbar = 0x7f050048;
public static final int abc_text_size_title_material = 0x7f050049;
public static final int abc_text_size_title_material_toolbar = 0x7f05004a;
public static final int compat_button_inset_horizontal_material = 0x7f05004b;
public static final int compat_button_inset_vertical_material = 0x7f05004c;
public static final int compat_button_padding_horizontal_material = 0x7f05004d;
public static final int compat_button_padding_vertical_material = 0x7f05004e;
public static final int compat_control_corner_material = 0x7f05004f;
public static final int compat_notification_large_icon_max_height = 0x7f050050;
public static final int compat_notification_large_icon_max_width = 0x7f050051;
public static final int disabled_alpha_material_dark = 0x7f050052;
public static final int disabled_alpha_material_light = 0x7f050053;
public static final int highlight_alpha_material_colored = 0x7f050054;
public static final int highlight_alpha_material_dark = 0x7f050055;
public static final int highlight_alpha_material_light = 0x7f050056;
public static final int hint_alpha_material_dark = 0x7f050057;
public static final int hint_alpha_material_light = 0x7f050058;
public static final int hint_pressed_alpha_material_dark = 0x7f050059;
public static final int hint_pressed_alpha_material_light = 0x7f05005a;
public static final int notification_action_icon_size = 0x7f05005b;
public static final int notification_action_text_size = 0x7f05005c;
public static final int notification_big_circle_margin = 0x7f05005d;
public static final int notification_content_margin_start = 0x7f05005e;
public static final int notification_large_icon_height = 0x7f05005f;
public static final int notification_large_icon_width = 0x7f050060;
public static final int notification_main_column_padding_top = 0x7f050061;
public static final int notification_media_narrow_margin = 0x7f050062;
public static final int notification_right_icon_size = 0x7f050063;
public static final int notification_right_side_padding_top = 0x7f050064;
public static final int notification_small_icon_background_padding = 0x7f050065;
public static final int notification_small_icon_size_as_large = 0x7f050066;
public static final int notification_subtext_size = 0x7f050067;
public static final int notification_top_pad = 0x7f050068;
public static final int notification_top_pad_large_text = 0x7f050069;
public static final int tooltip_corner_radius = 0x7f05006a;
public static final int tooltip_horizontal_padding = 0x7f05006b;
public static final int tooltip_margin = 0x7f05006c;
public static final int tooltip_precise_anchor_extra_offset = 0x7f05006d;
public static final int tooltip_precise_anchor_threshold = 0x7f05006e;
public static final int tooltip_vertical_padding = 0x7f05006f;
public static final int tooltip_y_offset_non_touch = 0x7f050070;
public static final int tooltip_y_offset_touch = 0x7f050071;
}
public static final class drawable {
private drawable() {}
public static final int abc_ab_share_pack_mtrl_alpha = 0x7f060001;
public static final int abc_action_bar_item_background_material = 0x7f060002;
public static final int abc_btn_borderless_material = 0x7f060003;
public static final int abc_btn_check_material = 0x7f060004;
public static final int abc_btn_check_to_on_mtrl_000 = 0x7f060005;
public static final int abc_btn_check_to_on_mtrl_015 = 0x7f060006;
public static final int abc_btn_colored_material = 0x7f060007;
public static final int abc_btn_default_mtrl_shape = 0x7f060008;
public static final int abc_btn_radio_material = 0x7f060009;
public static final int abc_btn_radio_to_on_mtrl_000 = 0x7f06000a;
public static final int abc_btn_radio_to_on_mtrl_015 = 0x7f06000b;
public static final int abc_btn_switch_to_on_mtrl_00001 = 0x7f06000c;
public static final int abc_btn_switch_to_on_mtrl_00012 = 0x7f06000d;
public static final int abc_cab_background_internal_bg = 0x7f06000e;
public static final int abc_cab_background_top_material = 0x7f06000f;
public static final int abc_cab_background_top_mtrl_alpha = 0x7f060010;
public static final int abc_control_background_material = 0x7f060011;
public static final int abc_dialog_material_background = 0x7f060012;
public static final int abc_edit_text_material = 0x7f060013;
public static final int abc_ic_ab_back_material = 0x7f060014;
public static final int abc_ic_arrow_drop_right_black_24dp = 0x7f060015;
public static final int abc_ic_clear_material = 0x7f060016;
public static final int abc_ic_commit_search_api_mtrl_alpha = 0x7f060017;
public static final int abc_ic_go_search_api_material = 0x7f060018;
public static final int abc_ic_menu_copy_mtrl_am_alpha = 0x7f060019;
public static final int abc_ic_menu_cut_mtrl_alpha = 0x7f06001a;
public static final int abc_ic_menu_overflow_material = 0x7f06001b;
public static final int abc_ic_menu_paste_mtrl_am_alpha = 0x7f06001c;
public static final int abc_ic_menu_selectall_mtrl_alpha = 0x7f06001d;
public static final int abc_ic_menu_share_mtrl_alpha = 0x7f06001e;
public static final int abc_ic_search_api_material = 0x7f06001f;
public static final int abc_ic_star_black_16dp = 0x7f060020;
public static final int abc_ic_star_black_36dp = 0x7f060021;
public static final int abc_ic_star_black_48dp = 0x7f060022;
public static final int abc_ic_star_half_black_16dp = 0x7f060023;
public static final int abc_ic_star_half_black_36dp = 0x7f060024;
public static final int abc_ic_star_half_black_48dp = 0x7f060025;
public static final int abc_ic_voice_search_api_material = 0x7f060026;
public static final int abc_item_background_holo_dark = 0x7f060027;
public static final int abc_item_background_holo_light = 0x7f060028;
public static final int abc_list_divider_material = 0x7f060029;
public static final int abc_list_divider_mtrl_alpha = 0x7f06002a;
public static final int abc_list_focused_holo = 0x7f06002b;
public static final int abc_list_longpressed_holo = 0x7f06002c;
public static final int abc_list_pressed_holo_dark = 0x7f06002d;
public static final int abc_list_pressed_holo_light = 0x7f06002e;
public static final int abc_list_selector_background_transition_holo_dark = 0x7f06002f;
public static final int abc_list_selector_background_transition_holo_light = 0x7f060030;
public static final int abc_list_selector_disabled_holo_dark = 0x7f060031;
public static final int abc_list_selector_disabled_holo_light = 0x7f060032;
public static final int abc_list_selector_holo_dark = 0x7f060033;
public static final int abc_list_selector_holo_light = 0x7f060034;
public static final int abc_menu_hardkey_panel_mtrl_mult = 0x7f060035;
public static final int abc_popup_background_mtrl_mult = 0x7f060036;
public static final int abc_ratingbar_indicator_material = 0x7f060037;
public static final int abc_ratingbar_material = 0x7f060038;
public static final int abc_ratingbar_small_material = 0x7f060039;
public static final int abc_scrubber_control_off_mtrl_alpha = 0x7f06003a;
public static final int abc_scrubber_control_to_pressed_mtrl_000 = 0x7f06003b;
public static final int abc_scrubber_control_to_pressed_mtrl_005 = 0x7f06003c;
public static final int abc_scrubber_primary_mtrl_alpha = 0x7f06003d;
public static final int abc_scrubber_track_mtrl_alpha = 0x7f06003e;
public static final int abc_seekbar_thumb_material = 0x7f06003f;
public static final int abc_seekbar_tick_mark_material = 0x7f060040;
public static final int abc_seekbar_track_material = 0x7f060041;
public static final int abc_spinner_mtrl_am_alpha = 0x7f060042;
public static final int abc_spinner_textfield_background_material = 0x7f060043;
public static final int abc_switch_thumb_material = 0x7f060044;
public static final int abc_switch_track_mtrl_alpha = 0x7f060045;
public static final int abc_tab_indicator_material = 0x7f060046;
public static final int abc_tab_indicator_mtrl_alpha = 0x7f060047;
public static final int abc_text_cursor_material = 0x7f060048;
public static final int abc_text_select_handle_left_mtrl_dark = 0x7f060049;
public static final int abc_text_select_handle_left_mtrl_light = 0x7f06004a;
public static final int abc_text_select_handle_middle_mtrl_dark = 0x7f06004b;
public static final int abc_text_select_handle_middle_mtrl_light = 0x7f06004c;
public static final int abc_text_select_handle_right_mtrl_dark = 0x7f06004d;
public static final int abc_text_select_handle_right_mtrl_light = 0x7f06004e;
public static final int abc_textfield_activated_mtrl_alpha = 0x7f06004f;
public static final int abc_textfield_default_mtrl_alpha = 0x7f060050;
public static final int abc_textfield_search_activated_mtrl_alpha = 0x7f060051;
public static final int abc_textfield_search_default_mtrl_alpha = 0x7f060052;
public static final int abc_textfield_search_material = 0x7f060053;
public static final int abc_vector_test = 0x7f060054;
public static final int notification_action_background = 0x7f060057;
public static final int notification_bg = 0x7f060058;
public static final int notification_bg_low = 0x7f060059;
public static final int notification_bg_low_normal = 0x7f06005a;
public static final int notification_bg_low_pressed = 0x7f06005b;
public static final int notification_bg_normal = 0x7f06005c;
public static final int notification_bg_normal_pressed = 0x7f06005d;
public static final int notification_icon_background = 0x7f06005e;
public static final int notification_template_icon_bg = 0x7f06005f;
public static final int notification_template_icon_low_bg = 0x7f060060;
public static final int notification_tile_bg = 0x7f060061;
public static final int notify_panel_notification_icon_bg = 0x7f060062;
public static final int tooltip_frame_dark = 0x7f060063;
public static final int tooltip_frame_light = 0x7f060064;
}
public static final class id {
private id() {}
public static final int action_bar = 0x7f070007;
public static final int action_bar_activity_content = 0x7f070008;
public static final int action_bar_container = 0x7f070009;
public static final int action_bar_root = 0x7f07000a;
public static final int action_bar_spinner = 0x7f07000b;
public static final int action_bar_subtitle = 0x7f07000c;
public static final int action_bar_title = 0x7f07000d;
public static final int action_container = 0x7f07000e;
public static final int action_context_bar = 0x7f07000f;
public static final int action_divider = 0x7f070010;
public static final int action_image = 0x7f070011;
public static final int action_menu_divider = 0x7f070012;
public static final int action_menu_presenter = 0x7f070013;
public static final int action_mode_bar = 0x7f070014;
public static final int action_mode_bar_stub = 0x7f070015;
public static final int action_mode_close_button = 0x7f070016;
public static final int action_text = 0x7f070017;
public static final int actions = 0x7f070018;
public static final int activity_chooser_view_content = 0x7f070019;
public static final int add = 0x7f07001a;
public static final int alertTitle = 0x7f07001b;
public static final int async = 0x7f07001e;
public static final int blocking = 0x7f070021;
public static final int bottom = 0x7f070022;
public static final int buttonPanel = 0x7f070024;
public static final int checkbox = 0x7f070029;
public static final int chronometer = 0x7f07002a;
public static final int content = 0x7f07002e;
public static final int contentPanel = 0x7f07002f;
public static final int custom = 0x7f070030;
public static final int customPanel = 0x7f070031;
public static final int decor_content_parent = 0x7f070032;
public static final int default_activity_button = 0x7f070033;
public static final int edit_query = 0x7f070037;
public static final int end = 0x7f070038;
public static final int expand_activities_button = 0x7f070039;
public static final int expanded_menu = 0x7f07003a;
public static final int forever = 0x7f07003e;
public static final int group_divider = 0x7f070040;
public static final int home = 0x7f070043;
public static final int icon = 0x7f070045;
public static final int icon_group = 0x7f070046;
public static final int image = 0x7f070048;
public static final int info = 0x7f070049;
public static final int italic = 0x7f07004b;
public static final int left = 0x7f07004c;
public static final int line1 = 0x7f07004d;
public static final int line3 = 0x7f07004e;
public static final int listMode = 0x7f07004f;
public static final int list_item = 0x7f070050;
public static final int message = 0x7f070051;
public static final int multiply = 0x7f070053;
public static final int none = 0x7f070055;
public static final int normal = 0x7f070056;
public static final int notification_background = 0x7f070057;
public static final int notification_main_column = 0x7f070058;
public static final int notification_main_column_container = 0x7f070059;
public static final int parentPanel = 0x7f07005c;
public static final int progress_circular = 0x7f07005e;
public static final int progress_horizontal = 0x7f07005f;
public static final int radio = 0x7f070060;
public static final int right = 0x7f070061;
public static final int right_icon = 0x7f070062;
public static final int right_side = 0x7f070063;
public static final int screen = 0x7f070064;
public static final int scrollIndicatorDown = 0x7f070065;
public static final int scrollIndicatorUp = 0x7f070066;
public static final int scrollView = 0x7f070067;
public static final int search_badge = 0x7f070068;
public static final int search_bar = 0x7f070069;
public static final int search_button = 0x7f07006a;
public static final int search_close_btn = 0x7f07006b;
public static final int search_edit_frame = 0x7f07006c;
public static final int search_go_btn = 0x7f07006d;
public static final int search_mag_icon = 0x7f07006e;
public static final int search_plate = 0x7f07006f;
public static final int search_src_text = 0x7f070070;
public static final int search_voice_btn = 0x7f070071;
public static final int select_dialog_listview = 0x7f070072;
public static final int shortcut = 0x7f070073;
public static final int spacer = 0x7f070077;
public static final int split_action_bar = 0x7f070078;
public static final int src_atop = 0x7f07007b;
public static final int src_in = 0x7f07007c;
public static final int src_over = 0x7f07007d;
public static final int start = 0x7f07007f;
public static final int submenuarrow = 0x7f070080;
public static final int submit_area = 0x7f070081;
public static final int tabMode = 0x7f070082;
public static final int tag_transition_group = 0x7f070083;
public static final int tag_unhandled_key_event_manager = 0x7f070084;
public static final int tag_unhandled_key_listeners = 0x7f070085;
public static final int text = 0x7f070086;
public static final int text2 = 0x7f070087;
public static final int textSpacerNoButtons = 0x7f070088;
public static final int textSpacerNoTitle = 0x7f070089;
public static final int time = 0x7f07008a;
public static final int title = 0x7f07008b;
public static final int titleDividerNoCustom = 0x7f07008c;
public static final int title_template = 0x7f07008d;
public static final int top = 0x7f07008e;
public static final int topPanel = 0x7f07008f;
public static final int uniform = 0x7f070090;
public static final int up = 0x7f070091;
public static final int wrap_content = 0x7f070095;
}
public static final class integer {
private integer() {}
public static final int abc_config_activityDefaultDur = 0x7f080000;
public static final int abc_config_activityShortDur = 0x7f080001;
public static final int cancel_button_image_alpha = 0x7f080002;
public static final int config_tooltipAnimTime = 0x7f080003;
public static final int status_bar_notification_info_maxnum = 0x7f080004;
}
public static final class layout {
private layout() {}
public static final int abc_action_bar_title_item = 0x7f090000;
public static final int abc_action_bar_up_container = 0x7f090001;
public static final int abc_action_menu_item_layout = 0x7f090002;
public static final int abc_action_menu_layout = 0x7f090003;
public static final int abc_action_mode_bar = 0x7f090004;
public static final int abc_action_mode_close_item_material = 0x7f090005;
public static final int abc_activity_chooser_view = 0x7f090006;
public static final int abc_activity_chooser_view_list_item = 0x7f090007;
public static final int abc_alert_dialog_button_bar_material = 0x7f090008;
public static final int abc_alert_dialog_material = 0x7f090009;
public static final int abc_alert_dialog_title_material = 0x7f09000a;
public static final int abc_cascading_menu_item_layout = 0x7f09000b;
public static final int abc_dialog_title_material = 0x7f09000c;
public static final int abc_expanded_menu_layout = 0x7f09000d;
public static final int abc_list_menu_item_checkbox = 0x7f09000e;
public static final int abc_list_menu_item_icon = 0x7f09000f;
public static final int abc_list_menu_item_layout = 0x7f090010;
public static final int abc_list_menu_item_radio = 0x7f090011;
public static final int abc_popup_menu_header_item_layout = 0x7f090012;
public static final int abc_popup_menu_item_layout = 0x7f090013;
public static final int abc_screen_content_include = 0x7f090014;
public static final int abc_screen_simple = 0x7f090015;
public static final int abc_screen_simple_overlay_action_mode = 0x7f090016;
public static final int abc_screen_toolbar = 0x7f090017;
public static final int abc_search_dropdown_item_icons_2line = 0x7f090018;
public static final int abc_search_view = 0x7f090019;
public static final int abc_select_dialog_material = 0x7f09001a;
public static final int abc_tooltip = 0x7f09001b;
public static final int notification_action = 0x7f09001d;
public static final int notification_action_tombstone = 0x7f09001e;
public static final int notification_template_custom_big = 0x7f09001f;
public static final int notification_template_icon_group = 0x7f090020;
public static final int notification_template_part_chronometer = 0x7f090021;
public static final int notification_template_part_time = 0x7f090022;
public static final int select_dialog_item_material = 0x7f090023;
public static final int select_dialog_multichoice_material = 0x7f090024;
public static final int select_dialog_singlechoice_material = 0x7f090025;
public static final int support_simple_spinner_dropdown_item = 0x7f090026;
}
public static final class string {
private string() {}
public static final int abc_action_bar_home_description = 0x7f0b0000;
public static final int abc_action_bar_up_description = 0x7f0b0001;
public static final int abc_action_menu_overflow_description = 0x7f0b0002;
public static final int abc_action_mode_done = 0x7f0b0003;
public static final int abc_activity_chooser_view_see_all = 0x7f0b0004;
public static final int abc_activitychooserview_choose_application = 0x7f0b0005;
public static final int abc_capital_off = 0x7f0b0006;
public static final int abc_capital_on = 0x7f0b0007;
public static final int abc_font_family_body_1_material = 0x7f0b0008;
public static final int abc_font_family_body_2_material = 0x7f0b0009;
public static final int abc_font_family_button_material = 0x7f0b000a;
public static final int abc_font_family_caption_material = 0x7f0b000b;
public static final int abc_font_family_display_1_material = 0x7f0b000c;
public static final int abc_font_family_display_2_material = 0x7f0b000d;
public static final int abc_font_family_display_3_material = 0x7f0b000e;
public static final int abc_font_family_display_4_material = 0x7f0b000f;
public static final int abc_font_family_headline_material = 0x7f0b0010;
public static final int abc_font_family_menu_material = 0x7f0b0011;
public static final int abc_font_family_subhead_material = 0x7f0b0012;
public static final int abc_font_family_title_material = 0x7f0b0013;
public static final int abc_menu_alt_shortcut_label = 0x7f0b0014;
public static final int abc_menu_ctrl_shortcut_label = 0x7f0b0015;
public static final int abc_menu_delete_shortcut_label = 0x7f0b0016;
public static final int abc_menu_enter_shortcut_label = 0x7f0b0017;
public static final int abc_menu_function_shortcut_label = 0x7f0b0018;
public static final int abc_menu_meta_shortcut_label = 0x7f0b0019;
public static final int abc_menu_shift_shortcut_label = 0x7f0b001a;
public static final int abc_menu_space_shortcut_label = 0x7f0b001b;
public static final int abc_menu_sym_shortcut_label = 0x7f0b001c;
public static final int abc_prepend_shortcut_label = 0x7f0b001d;
public static final int abc_search_hint = 0x7f0b001e;
public static final int abc_searchview_description_clear = 0x7f0b001f;
public static final int abc_searchview_description_query = 0x7f0b0020;
public static final int abc_searchview_description_search = 0x7f0b0021;
public static final int abc_searchview_description_submit = 0x7f0b0022;
public static final int abc_searchview_description_voice = 0x7f0b0023;
public static final int abc_shareactionprovider_share_with = 0x7f0b0024;
public static final int abc_shareactionprovider_share_with_application = 0x7f0b0025;
public static final int abc_toolbar_collapse_description = 0x7f0b0026;
public static final int search_menu_title = 0x7f0b0028;
public static final int status_bar_notification_info_overflow = 0x7f0b0029;
}
public static final class style {
private style() {}
public static final int AlertDialog_AppCompat = 0x7f0c0000;
public static final int AlertDialog_AppCompat_Light = 0x7f0c0001;
public static final int Animation_AppCompat_Dialog = 0x7f0c0002;
public static final int Animation_AppCompat_DropDownUp = 0x7f0c0003;
public static final int Animation_AppCompat_Tooltip = 0x7f0c0004;
public static final int Base_AlertDialog_AppCompat = 0x7f0c0006;
public static final int Base_AlertDialog_AppCompat_Light = 0x7f0c0007;
public static final int Base_Animation_AppCompat_Dialog = 0x7f0c0008;
public static final int Base_Animation_AppCompat_DropDownUp = 0x7f0c0009;
public static final int Base_Animation_AppCompat_Tooltip = 0x7f0c000a;
public static final int Base_DialogWindowTitleBackground_AppCompat = 0x7f0c000c;
public static final int Base_DialogWindowTitle_AppCompat = 0x7f0c000b;
public static final int Base_TextAppearance_AppCompat = 0x7f0c000d;
public static final int Base_TextAppearance_AppCompat_Body1 = 0x7f0c000e;
public static final int Base_TextAppearance_AppCompat_Body2 = 0x7f0c000f;
public static final int Base_TextAppearance_AppCompat_Button = 0x7f0c0010;
public static final int Base_TextAppearance_AppCompat_Caption = 0x7f0c0011;
public static final int Base_TextAppearance_AppCompat_Display1 = 0x7f0c0012;
public static final int Base_TextAppearance_AppCompat_Display2 = 0x7f0c0013;
public static final int Base_TextAppearance_AppCompat_Display3 = 0x7f0c0014;
public static final int Base_TextAppearance_AppCompat_Display4 = 0x7f0c0015;
public static final int Base_TextAppearance_AppCompat_Headline = 0x7f0c0016;
public static final int Base_TextAppearance_AppCompat_Inverse = 0x7f0c0017;
public static final int Base_TextAppearance_AppCompat_Large = 0x7f0c0018;
public static final int Base_TextAppearance_AppCompat_Large_Inverse = 0x7f0c0019;
public static final int Base_TextAppearance_AppCompat_Light_Widget_PopupMenu_Large = 0x7f0c001a;
public static final int Base_TextAppearance_AppCompat_Light_Widget_PopupMenu_Small = 0x7f0c001b;
public static final int Base_TextAppearance_AppCompat_Medium = 0x7f0c001c;
public static final int Base_TextAppearance_AppCompat_Medium_Inverse = 0x7f0c001d;
public static final int Base_TextAppearance_AppCompat_Menu = 0x7f0c001e;
public static final int Base_TextAppearance_AppCompat_SearchResult = 0x7f0c001f;
public static final int Base_TextAppearance_AppCompat_SearchResult_Subtitle = 0x7f0c0020;
public static final int Base_TextAppearance_AppCompat_SearchResult_Title = 0x7f0c0021;
public static final int Base_TextAppearance_AppCompat_Small = 0x7f0c0022;
public static final int Base_TextAppearance_AppCompat_Small_Inverse = 0x7f0c0023;
public static final int Base_TextAppearance_AppCompat_Subhead = 0x7f0c0024;
public static final int Base_TextAppearance_AppCompat_Subhead_Inverse = 0x7f0c0025;
public static final int Base_TextAppearance_AppCompat_Title = 0x7f0c0026;
public static final int Base_TextAppearance_AppCompat_Title_Inverse = 0x7f0c0027;
public static final int Base_TextAppearance_AppCompat_Tooltip = 0x7f0c0028;
public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Menu = 0x7f0c0029;
public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Subtitle = 0x7f0c002a;
public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Subtitle_Inverse = 0x7f0c002b;
public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Title = 0x7f0c002c;
public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Title_Inverse = 0x7f0c002d;
public static final int Base_TextAppearance_AppCompat_Widget_ActionMode_Subtitle = 0x7f0c002e;
public static final int Base_TextAppearance_AppCompat_Widget_ActionMode_Title = 0x7f0c002f;
public static final int Base_TextAppearance_AppCompat_Widget_Button = 0x7f0c0030;
public static final int Base_TextAppearance_AppCompat_Widget_Button_Borderless_Colored = 0x7f0c0031;
public static final int Base_TextAppearance_AppCompat_Widget_Button_Colored = 0x7f0c0032;
public static final int Base_TextAppearance_AppCompat_Widget_Button_Inverse = 0x7f0c0033;
public static final int Base_TextAppearance_AppCompat_Widget_DropDownItem = 0x7f0c0034;
public static final int Base_TextAppearance_AppCompat_Widget_PopupMenu_Header = 0x7f0c0035;
public static final int Base_TextAppearance_AppCompat_Widget_PopupMenu_Large = 0x7f0c0036;
public static final int Base_TextAppearance_AppCompat_Widget_PopupMenu_Small = 0x7f0c0037;
public static final int Base_TextAppearance_AppCompat_Widget_Switch = 0x7f0c0038;
public static final int Base_TextAppearance_AppCompat_Widget_TextView_SpinnerItem = 0x7f0c0039;
public static final int Base_TextAppearance_Widget_AppCompat_ExpandedMenu_Item = 0x7f0c003a;
public static final int Base_TextAppearance_Widget_AppCompat_Toolbar_Subtitle = 0x7f0c003b;
public static final int Base_TextAppearance_Widget_AppCompat_Toolbar_Title = 0x7f0c003c;
public static final int Base_ThemeOverlay_AppCompat = 0x7f0c004b;
public static final int Base_ThemeOverlay_AppCompat_ActionBar = 0x7f0c004c;
public static final int Base_ThemeOverlay_AppCompat_Dark = 0x7f0c004d;
public static final int Base_ThemeOverlay_AppCompat_Dark_ActionBar = 0x7f0c004e;
public static final int Base_ThemeOverlay_AppCompat_Dialog = 0x7f0c004f;
public static final int Base_ThemeOverlay_AppCompat_Dialog_Alert = 0x7f0c0050;
public static final int Base_ThemeOverlay_AppCompat_Light = 0x7f0c0051;
public static final int Base_Theme_AppCompat = 0x7f0c003d;
public static final int Base_Theme_AppCompat_CompactMenu = 0x7f0c003e;
public static final int Base_Theme_AppCompat_Dialog = 0x7f0c003f;
public static final int Base_Theme_AppCompat_DialogWhenLarge = 0x7f0c0043;
public static final int Base_Theme_AppCompat_Dialog_Alert = 0x7f0c0040;
public static final int Base_Theme_AppCompat_Dialog_FixedSize = 0x7f0c0041;
public static final int Base_Theme_AppCompat_Dialog_MinWidth = 0x7f0c0042;
public static final int Base_Theme_AppCompat_Light = 0x7f0c0044;
public static final int Base_Theme_AppCompat_Light_DarkActionBar = 0x7f0c0045;
public static final int Base_Theme_AppCompat_Light_Dialog = 0x7f0c0046;
public static final int Base_Theme_AppCompat_Light_DialogWhenLarge = 0x7f0c004a;
public static final int Base_Theme_AppCompat_Light_Dialog_Alert = 0x7f0c0047;
public static final int Base_Theme_AppCompat_Light_Dialog_FixedSize = 0x7f0c0048;
public static final int Base_Theme_AppCompat_Light_Dialog_MinWidth = 0x7f0c0049;
public static final int Base_V21_ThemeOverlay_AppCompat_Dialog = 0x7f0c0056;
public static final int Base_V21_Theme_AppCompat = 0x7f0c0052;
public static final int Base_V21_Theme_AppCompat_Dialog = 0x7f0c0053;
public static final int Base_V21_Theme_AppCompat_Light = 0x7f0c0054;
public static final int Base_V21_Theme_AppCompat_Light_Dialog = 0x7f0c0055;
public static final int Base_V22_Theme_AppCompat = 0x7f0c0057;
public static final int Base_V22_Theme_AppCompat_Light = 0x7f0c0058;
public static final int Base_V23_Theme_AppCompat = 0x7f0c0059;
public static final int Base_V23_Theme_AppCompat_Light = 0x7f0c005a;
public static final int Base_V26_Theme_AppCompat = 0x7f0c005b;
public static final int Base_V26_Theme_AppCompat_Light = 0x7f0c005c;
public static final int Base_V26_Widget_AppCompat_Toolbar = 0x7f0c005d;
public static final int Base_V28_Theme_AppCompat = 0x7f0c005e;
public static final int Base_V28_Theme_AppCompat_Light = 0x7f0c005f;
public static final int Base_V7_ThemeOverlay_AppCompat_Dialog = 0x7f0c0064;
public static final int Base_V7_Theme_AppCompat = 0x7f0c0060;
public static final int Base_V7_Theme_AppCompat_Dialog = 0x7f0c0061;
public static final int Base_V7_Theme_AppCompat_Light = 0x7f0c0062;
public static final int Base_V7_Theme_AppCompat_Light_Dialog = 0x7f0c0063;
public static final int Base_V7_Widget_AppCompat_AutoCompleteTextView = 0x7f0c0065;
public static final int Base_V7_Widget_AppCompat_EditText = 0x7f0c0066;
public static final int Base_V7_Widget_AppCompat_Toolbar = 0x7f0c0067;
public static final int Base_Widget_AppCompat_ActionBar = 0x7f0c0068;
public static final int Base_Widget_AppCompat_ActionBar_Solid = 0x7f0c0069;
public static final int Base_Widget_AppCompat_ActionBar_TabBar = 0x7f0c006a;
public static final int Base_Widget_AppCompat_ActionBar_TabText = 0x7f0c006b;
public static final int Base_Widget_AppCompat_ActionBar_TabView = 0x7f0c006c;
public static final int Base_Widget_AppCompat_ActionButton = 0x7f0c006d;
public static final int Base_Widget_AppCompat_ActionButton_CloseMode = 0x7f0c006e;
public static final int Base_Widget_AppCompat_ActionButton_Overflow = 0x7f0c006f;
public static final int Base_Widget_AppCompat_ActionMode = 0x7f0c0070;
public static final int Base_Widget_AppCompat_ActivityChooserView = 0x7f0c0071;
public static final int Base_Widget_AppCompat_AutoCompleteTextView = 0x7f0c0072;
public static final int Base_Widget_AppCompat_Button = 0x7f0c0073;
public static final int Base_Widget_AppCompat_ButtonBar = 0x7f0c0079;
public static final int Base_Widget_AppCompat_ButtonBar_AlertDialog = 0x7f0c007a;
public static final int Base_Widget_AppCompat_Button_Borderless = 0x7f0c0074;
public static final int Base_Widget_AppCompat_Button_Borderless_Colored = 0x7f0c0075;
public static final int Base_Widget_AppCompat_Button_ButtonBar_AlertDialog = 0x7f0c0076;
public static final int Base_Widget_AppCompat_Button_Colored = 0x7f0c0077;
public static final int Base_Widget_AppCompat_Button_Small = 0x7f0c0078;
public static final int Base_Widget_AppCompat_CompoundButton_CheckBox = 0x7f0c007b;
public static final int Base_Widget_AppCompat_CompoundButton_RadioButton = 0x7f0c007c;
public static final int Base_Widget_AppCompat_CompoundButton_Switch = 0x7f0c007d;
public static final int Base_Widget_AppCompat_DrawerArrowToggle = 0x7f0c007e;
public static final int Base_Widget_AppCompat_DrawerArrowToggle_Common = 0x7f0c007f;
public static final int Base_Widget_AppCompat_DropDownItem_Spinner = 0x7f0c0080;
public static final int Base_Widget_AppCompat_EditText = 0x7f0c0081;
public static final int Base_Widget_AppCompat_ImageButton = 0x7f0c0082;
public static final int Base_Widget_AppCompat_Light_ActionBar = 0x7f0c0083;
public static final int Base_Widget_AppCompat_Light_ActionBar_Solid = 0x7f0c0084;
public static final int Base_Widget_AppCompat_Light_ActionBar_TabBar = 0x7f0c0085;
public static final int Base_Widget_AppCompat_Light_ActionBar_TabText = 0x7f0c0086;
public static final int Base_Widget_AppCompat_Light_ActionBar_TabText_Inverse = 0x7f0c0087;
public static final int Base_Widget_AppCompat_Light_ActionBar_TabView = 0x7f0c0088;
public static final int Base_Widget_AppCompat_Light_PopupMenu = 0x7f0c0089;
public static final int Base_Widget_AppCompat_Light_PopupMenu_Overflow = 0x7f0c008a;
public static final int Base_Widget_AppCompat_ListMenuView = 0x7f0c008b;
public static final int Base_Widget_AppCompat_ListPopupWindow = 0x7f0c008c;
public static final int Base_Widget_AppCompat_ListView = 0x7f0c008d;
public static final int Base_Widget_AppCompat_ListView_DropDown = 0x7f0c008e;
public static final int Base_Widget_AppCompat_ListView_Menu = 0x7f0c008f;
public static final int Base_Widget_AppCompat_PopupMenu = 0x7f0c0090;
public static final int Base_Widget_AppCompat_PopupMenu_Overflow = 0x7f0c0091;
public static final int Base_Widget_AppCompat_PopupWindow = 0x7f0c0092;
public static final int Base_Widget_AppCompat_ProgressBar = 0x7f0c0093;
public static final int Base_Widget_AppCompat_ProgressBar_Horizontal = 0x7f0c0094;
public static final int Base_Widget_AppCompat_RatingBar = 0x7f0c0095;
public static final int Base_Widget_AppCompat_RatingBar_Indicator = 0x7f0c0096;
public static final int Base_Widget_AppCompat_RatingBar_Small = 0x7f0c0097;
public static final int Base_Widget_AppCompat_SearchView = 0x7f0c0098;
public static final int Base_Widget_AppCompat_SearchView_ActionBar = 0x7f0c0099;
public static final int Base_Widget_AppCompat_SeekBar = 0x7f0c009a;
public static final int Base_Widget_AppCompat_SeekBar_Discrete = 0x7f0c009b;
public static final int Base_Widget_AppCompat_Spinner = 0x7f0c009c;
public static final int Base_Widget_AppCompat_Spinner_Underlined = 0x7f0c009d;
public static final int Base_Widget_AppCompat_TextView_SpinnerItem = 0x7f0c009e;
public static final int Base_Widget_AppCompat_Toolbar = 0x7f0c009f;
public static final int Base_Widget_AppCompat_Toolbar_Button_Navigation = 0x7f0c00a0;
public static final int Platform_AppCompat = 0x7f0c00a1;
public static final int Platform_AppCompat_Light = 0x7f0c00a2;
public static final int Platform_ThemeOverlay_AppCompat = 0x7f0c00a3;
public static final int Platform_ThemeOverlay_AppCompat_Dark = 0x7f0c00a4;
public static final int Platform_ThemeOverlay_AppCompat_Light = 0x7f0c00a5;
public static final int Platform_V21_AppCompat = 0x7f0c00a6;
public static final int Platform_V21_AppCompat_Light = 0x7f0c00a7;
public static final int Platform_V25_AppCompat = 0x7f0c00a8;
public static final int Platform_V25_AppCompat_Light = 0x7f0c00a9;
public static final int Platform_Widget_AppCompat_Spinner = 0x7f0c00aa;
public static final int RtlOverlay_DialogWindowTitle_AppCompat = 0x7f0c00ab;
public static final int RtlOverlay_Widget_AppCompat_ActionBar_TitleItem = 0x7f0c00ac;
public static final int RtlOverlay_Widget_AppCompat_DialogTitle_Icon = 0x7f0c00ad;
public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem = 0x7f0c00ae;
public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem_InternalGroup = 0x7f0c00af;
public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem_Shortcut = 0x7f0c00b0;
public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem_SubmenuArrow = 0x7f0c00b1;
public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem_Text = 0x7f0c00b2;
public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem_Title = 0x7f0c00b3;
public static final int RtlOverlay_Widget_AppCompat_SearchView_MagIcon = 0x7f0c00b9;
public static final int RtlOverlay_Widget_AppCompat_Search_DropDown = 0x7f0c00b4;
public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Icon1 = 0x7f0c00b5;
public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Icon2 = 0x7f0c00b6;
public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Query = 0x7f0c00b7;
public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Text = 0x7f0c00b8;
public static final int RtlUnderlay_Widget_AppCompat_ActionButton = 0x7f0c00ba;
public static final int RtlUnderlay_Widget_AppCompat_ActionButton_Overflow = 0x7f0c00bb;
public static final int TextAppearance_AppCompat = 0x7f0c00bc;
public static final int TextAppearance_AppCompat_Body1 = 0x7f0c00bd;
public static final int TextAppearance_AppCompat_Body2 = 0x7f0c00be;
public static final int TextAppearance_AppCompat_Button = 0x7f0c00bf;
public static final int TextAppearance_AppCompat_Caption = 0x7f0c00c0;
public static final int TextAppearance_AppCompat_Display1 = 0x7f0c00c1;
public static final int TextAppearance_AppCompat_Display2 = 0x7f0c00c2;
public static final int TextAppearance_AppCompat_Display3 = 0x7f0c00c3;
public static final int TextAppearance_AppCompat_Display4 = 0x7f0c00c4;
public static final int TextAppearance_AppCompat_Headline = 0x7f0c00c5;
public static final int TextAppearance_AppCompat_Inverse = 0x7f0c00c6;
public static final int TextAppearance_AppCompat_Large = 0x7f0c00c7;
public static final int TextAppearance_AppCompat_Large_Inverse = 0x7f0c00c8;
public static final int TextAppearance_AppCompat_Light_SearchResult_Subtitle = 0x7f0c00c9;
public static final int TextAppearance_AppCompat_Light_SearchResult_Title = 0x7f0c00ca;
public static final int TextAppearance_AppCompat_Light_Widget_PopupMenu_Large = 0x7f0c00cb;
public static final int TextAppearance_AppCompat_Light_Widget_PopupMenu_Small = 0x7f0c00cc;
public static final int TextAppearance_AppCompat_Medium = 0x7f0c00cd;
public static final int TextAppearance_AppCompat_Medium_Inverse = 0x7f0c00ce;
public static final int TextAppearance_AppCompat_Menu = 0x7f0c00cf;
public static final int TextAppearance_AppCompat_SearchResult_Subtitle = 0x7f0c00d0;
public static final int TextAppearance_AppCompat_SearchResult_Title = 0x7f0c00d1;
public static final int TextAppearance_AppCompat_Small = 0x7f0c00d2;
public static final int TextAppearance_AppCompat_Small_Inverse = 0x7f0c00d3;
public static final int TextAppearance_AppCompat_Subhead = 0x7f0c00d4;
public static final int TextAppearance_AppCompat_Subhead_Inverse = 0x7f0c00d5;
public static final int TextAppearance_AppCompat_Title = 0x7f0c00d6;
public static final int TextAppearance_AppCompat_Title_Inverse = 0x7f0c00d7;
public static final int TextAppearance_AppCompat_Tooltip = 0x7f0c00d8;
public static final int TextAppearance_AppCompat_Widget_ActionBar_Menu = 0x7f0c00d9;
public static final int TextAppearance_AppCompat_Widget_ActionBar_Subtitle = 0x7f0c00da;
public static final int TextAppearance_AppCompat_Widget_ActionBar_Subtitle_Inverse = 0x7f0c00db;
public static final int TextAppearance_AppCompat_Widget_ActionBar_Title = 0x7f0c00dc;
public static final int TextAppearance_AppCompat_Widget_ActionBar_Title_Inverse = 0x7f0c00dd;
public static final int TextAppearance_AppCompat_Widget_ActionMode_Subtitle = 0x7f0c00de;
public static final int TextAppearance_AppCompat_Widget_ActionMode_Subtitle_Inverse = 0x7f0c00df;
public static final int TextAppearance_AppCompat_Widget_ActionMode_Title = 0x7f0c00e0;
public static final int TextAppearance_AppCompat_Widget_ActionMode_Title_Inverse = 0x7f0c00e1;
public static final int TextAppearance_AppCompat_Widget_Button = 0x7f0c00e2;
public static final int TextAppearance_AppCompat_Widget_Button_Borderless_Colored = 0x7f0c00e3;
public static final int TextAppearance_AppCompat_Widget_Button_Colored = 0x7f0c00e4;
public static final int TextAppearance_AppCompat_Widget_Button_Inverse = 0x7f0c00e5;
public static final int TextAppearance_AppCompat_Widget_DropDownItem = 0x7f0c00e6;
public static final int TextAppearance_AppCompat_Widget_PopupMenu_Header = 0x7f0c00e7;
public static final int TextAppearance_AppCompat_Widget_PopupMenu_Large = 0x7f0c00e8;
public static final int TextAppearance_AppCompat_Widget_PopupMenu_Small = 0x7f0c00e9;
public static final int TextAppearance_AppCompat_Widget_Switch = 0x7f0c00ea;
public static final int TextAppearance_AppCompat_Widget_TextView_SpinnerItem = 0x7f0c00eb;
public static final int TextAppearance_Compat_Notification = 0x7f0c00ec;
public static final int TextAppearance_Compat_Notification_Info = 0x7f0c00ed;
public static final int TextAppearance_Compat_Notification_Line2 = 0x7f0c00ee;
public static final int TextAppearance_Compat_Notification_Time = 0x7f0c00ef;
public static final int TextAppearance_Compat_Notification_Title = 0x7f0c00f0;
public static final int TextAppearance_Widget_AppCompat_ExpandedMenu_Item = 0x7f0c00f1;
public static final int TextAppearance_Widget_AppCompat_Toolbar_Subtitle = 0x7f0c00f2;
public static final int TextAppearance_Widget_AppCompat_Toolbar_Title = 0x7f0c00f3;
public static final int ThemeOverlay_AppCompat = 0x7f0c0109;
public static final int ThemeOverlay_AppCompat_ActionBar = 0x7f0c010a;
public static final int ThemeOverlay_AppCompat_Dark = 0x7f0c010b;
public static final int ThemeOverlay_AppCompat_Dark_ActionBar = 0x7f0c010c;
public static final int ThemeOverlay_AppCompat_Dialog = 0x7f0c010d;
public static final int ThemeOverlay_AppCompat_Dialog_Alert = 0x7f0c010e;
public static final int ThemeOverlay_AppCompat_Light = 0x7f0c010f;
public static final int Theme_AppCompat = 0x7f0c00f4;
public static final int Theme_AppCompat_CompactMenu = 0x7f0c00f5;
public static final int Theme_AppCompat_DayNight = 0x7f0c00f6;
public static final int Theme_AppCompat_DayNight_DarkActionBar = 0x7f0c00f7;
public static final int Theme_AppCompat_DayNight_Dialog = 0x7f0c00f8;
public static final int Theme_AppCompat_DayNight_DialogWhenLarge = 0x7f0c00fb;
public static final int Theme_AppCompat_DayNight_Dialog_Alert = 0x7f0c00f9;
public static final int Theme_AppCompat_DayNight_Dialog_MinWidth = 0x7f0c00fa;
public static final int Theme_AppCompat_DayNight_NoActionBar = 0x7f0c00fc;
public static final int Theme_AppCompat_Dialog = 0x7f0c00fd;
public static final int Theme_AppCompat_DialogWhenLarge = 0x7f0c0100;
public static final int Theme_AppCompat_Dialog_Alert = 0x7f0c00fe;
public static final int Theme_AppCompat_Dialog_MinWidth = 0x7f0c00ff;
public static final int Theme_AppCompat_Light = 0x7f0c0101;
public static final int Theme_AppCompat_Light_DarkActionBar = 0x7f0c0102;
public static final int Theme_AppCompat_Light_Dialog = 0x7f0c0103;
public static final int Theme_AppCompat_Light_DialogWhenLarge = 0x7f0c0106;
public static final int Theme_AppCompat_Light_Dialog_Alert = 0x7f0c0104;
public static final int Theme_AppCompat_Light_Dialog_MinWidth = 0x7f0c0105;
public static final int Theme_AppCompat_Light_NoActionBar = 0x7f0c0107;
public static final int Theme_AppCompat_NoActionBar = 0x7f0c0108;
public static final int Widget_AppCompat_ActionBar = 0x7f0c0110;
public static final int Widget_AppCompat_ActionBar_Solid = 0x7f0c0111;
public static final int Widget_AppCompat_ActionBar_TabBar = 0x7f0c0112;
public static final int Widget_AppCompat_ActionBar_TabText = 0x7f0c0113;
public static final int Widget_AppCompat_ActionBar_TabView = 0x7f0c0114;
public static final int Widget_AppCompat_ActionButton = 0x7f0c0115;
public static final int Widget_AppCompat_ActionButton_CloseMode = 0x7f0c0116;
public static final int Widget_AppCompat_ActionButton_Overflow = 0x7f0c0117;
public static final int Widget_AppCompat_ActionMode = 0x7f0c0118;
public static final int Widget_AppCompat_ActivityChooserView = 0x7f0c0119;
public static final int Widget_AppCompat_AutoCompleteTextView = 0x7f0c011a;
public static final int Widget_AppCompat_Button = 0x7f0c011b;
public static final int Widget_AppCompat_ButtonBar = 0x7f0c0121;
public static final int Widget_AppCompat_ButtonBar_AlertDialog = 0x7f0c0122;
public static final int Widget_AppCompat_Button_Borderless = 0x7f0c011c;
public static final int Widget_AppCompat_Button_Borderless_Colored = 0x7f0c011d;
public static final int Widget_AppCompat_Button_ButtonBar_AlertDialog = 0x7f0c011e;
public static final int Widget_AppCompat_Button_Colored = 0x7f0c011f;
public static final int Widget_AppCompat_Button_Small = 0x7f0c0120;
public static final int Widget_AppCompat_CompoundButton_CheckBox = 0x7f0c0123;
public static final int Widget_AppCompat_CompoundButton_RadioButton = 0x7f0c0124;
public static final int Widget_AppCompat_CompoundButton_Switch = 0x7f0c0125;
public static final int Widget_AppCompat_DrawerArrowToggle = 0x7f0c0126;
public static final int Widget_AppCompat_DropDownItem_Spinner = 0x7f0c0127;
public static final int Widget_AppCompat_EditText = 0x7f0c0128;
public static final int Widget_AppCompat_ImageButton = 0x7f0c0129;
public static final int Widget_AppCompat_Light_ActionBar = 0x7f0c012a;
public static final int Widget_AppCompat_Light_ActionBar_Solid = 0x7f0c012b;
public static final int Widget_AppCompat_Light_ActionBar_Solid_Inverse = 0x7f0c012c;
public static final int Widget_AppCompat_Light_ActionBar_TabBar = 0x7f0c012d;
public static final int Widget_AppCompat_Light_ActionBar_TabBar_Inverse = 0x7f0c012e;
public static final int Widget_AppCompat_Light_ActionBar_TabText = 0x7f0c012f;
public static final int Widget_AppCompat_Light_ActionBar_TabText_Inverse = 0x7f0c0130;
public static final int Widget_AppCompat_Light_ActionBar_TabView = 0x7f0c0131;
public static final int Widget_AppCompat_Light_ActionBar_TabView_Inverse = 0x7f0c0132;
public static final int Widget_AppCompat_Light_ActionButton = 0x7f0c0133;
public static final int Widget_AppCompat_Light_ActionButton_CloseMode = 0x7f0c0134;
public static final int Widget_AppCompat_Light_ActionButton_Overflow = 0x7f0c0135;
public static final int Widget_AppCompat_Light_ActionMode_Inverse = 0x7f0c0136;
public static final int Widget_AppCompat_Light_ActivityChooserView = 0x7f0c0137;
public static final int Widget_AppCompat_Light_AutoCompleteTextView = 0x7f0c0138;
public static final int Widget_AppCompat_Light_DropDownItem_Spinner = 0x7f0c0139;
public static final int Widget_AppCompat_Light_ListPopupWindow = 0x7f0c013a;
public static final int Widget_AppCompat_Light_ListView_DropDown = 0x7f0c013b;
public static final int Widget_AppCompat_Light_PopupMenu = 0x7f0c013c;
public static final int Widget_AppCompat_Light_PopupMenu_Overflow = 0x7f0c013d;
public static final int Widget_AppCompat_Light_SearchView = 0x7f0c013e;
public static final int Widget_AppCompat_Light_Spinner_DropDown_ActionBar = 0x7f0c013f;
public static final int Widget_AppCompat_ListMenuView = 0x7f0c0140;
public static final int Widget_AppCompat_ListPopupWindow = 0x7f0c0141;
public static final int Widget_AppCompat_ListView = 0x7f0c0142;
public static final int Widget_AppCompat_ListView_DropDown = 0x7f0c0143;
public static final int Widget_AppCompat_ListView_Menu = 0x7f0c0144;
public static final int Widget_AppCompat_PopupMenu = 0x7f0c0145;
public static final int Widget_AppCompat_PopupMenu_Overflow = 0x7f0c0146;
public static final int Widget_AppCompat_PopupWindow = 0x7f0c0147;
public static final int Widget_AppCompat_ProgressBar = 0x7f0c0148;
public static final int Widget_AppCompat_ProgressBar_Horizontal = 0x7f0c0149;
public static final int Widget_AppCompat_RatingBar = 0x7f0c014a;
public static final int Widget_AppCompat_RatingBar_Indicator = 0x7f0c014b;
public static final int Widget_AppCompat_RatingBar_Small = 0x7f0c014c;
public static final int Widget_AppCompat_SearchView = 0x7f0c014d;
public static final int Widget_AppCompat_SearchView_ActionBar = 0x7f0c014e;
public static final int Widget_AppCompat_SeekBar = 0x7f0c014f;
public static final int Widget_AppCompat_SeekBar_Discrete = 0x7f0c0150;
public static final int Widget_AppCompat_Spinner = 0x7f0c0151;
public static final int Widget_AppCompat_Spinner_DropDown = 0x7f0c0152;
public static final int Widget_AppCompat_Spinner_DropDown_ActionBar = 0x7f0c0153;
public static final int Widget_AppCompat_Spinner_Underlined = 0x7f0c0154;
public static final int Widget_AppCompat_TextView_SpinnerItem = 0x7f0c0155;
public static final int Widget_AppCompat_Toolbar = 0x7f0c0156;
public static final int Widget_AppCompat_Toolbar_Button_Navigation = 0x7f0c0157;
public static final int Widget_Compat_NotificationActionContainer = 0x7f0c0158;
public static final int Widget_Compat_NotificationActionText = 0x7f0c0159;
public static final int Widget_Support_CoordinatorLayout = 0x7f0c015a;
}
public static final class styleable {
private styleable() {}
public static final int[] ActionBar = { 0x7f020031, 0x7f020032, 0x7f020033, 0x7f02005d, 0x7f02005e, 0x7f02005f, 0x7f020060, 0x7f020061, 0x7f020062, 0x7f020065, 0x7f02006a, 0x7f02006b, 0x7f020076, 0x7f020087, 0x7f020088, 0x7f020089, 0x7f02008a, 0x7f02008b, 0x7f020090, 0x7f020093, 0x7f0200db, 0x7f0200e2, 0x7f0200ed, 0x7f0200f0, 0x7f0200f1, 0x7f02010c, 0x7f02010f, 0x7f02012a, 0x7f020133 };
public static final int ActionBar_background = 0;
public static final int ActionBar_backgroundSplit = 1;
public static final int ActionBar_backgroundStacked = 2;
public static final int ActionBar_contentInsetEnd = 3;
public static final int ActionBar_contentInsetEndWithActions = 4;
public static final int ActionBar_contentInsetLeft = 5;
public static final int ActionBar_contentInsetRight = 6;
public static final int ActionBar_contentInsetStart = 7;
public static final int ActionBar_contentInsetStartWithNavigation = 8;
public static final int ActionBar_customNavigationLayout = 9;
public static final int ActionBar_displayOptions = 10;
public static final int ActionBar_divider = 11;
public static final int ActionBar_elevation = 12;
public static final int ActionBar_height = 13;
public static final int ActionBar_hideOnContentScroll = 14;
public static final int ActionBar_homeAsUpIndicator = 15;
public static final int ActionBar_homeLayout = 16;
public static final int ActionBar_icon = 17;
public static final int ActionBar_indeterminateProgressStyle = 18;
public static final int ActionBar_itemPadding = 19;
public static final int ActionBar_logo = 20;
public static final int ActionBar_navigationMode = 21;
public static final int ActionBar_popupTheme = 22;
public static final int ActionBar_progressBarPadding = 23;
public static final int ActionBar_progressBarStyle = 24;
public static final int ActionBar_subtitle = 25;
public static final int ActionBar_subtitleTextStyle = 26;
public static final int ActionBar_title = 27;
public static final int ActionBar_titleTextStyle = 28;
public static final int[] ActionBarLayout = { 0x10100b3 };
public static final int ActionBarLayout_android_layout_gravity = 0;
public static final int[] ActionMenuItemView = { 0x101013f };
public static final int ActionMenuItemView_android_minWidth = 0;
public static final int[] ActionMenuView = { };
public static final int[] ActionMode = { 0x7f020031, 0x7f020032, 0x7f02004a, 0x7f020087, 0x7f02010f, 0x7f020133 };
public static final int ActionMode_background = 0;
public static final int ActionMode_backgroundSplit = 1;
public static final int ActionMode_closeItemLayout = 2;
public static final int ActionMode_height = 3;
public static final int ActionMode_subtitleTextStyle = 4;
public static final int ActionMode_titleTextStyle = 5;
public static final int[] ActivityChooserView = { 0x7f020078, 0x7f020091 };
public static final int ActivityChooserView_expandActivityOverflowButtonDrawable = 0;
public static final int ActivityChooserView_initialActivityCount = 1;
public static final int[] AlertDialog = { 0x10100f2, 0x7f020040, 0x7f020041, 0x7f0200d2, 0x7f0200d3, 0x7f0200df, 0x7f020101, 0x7f020102 };
public static final int AlertDialog_android_layout = 0;
public static final int AlertDialog_buttonIconDimen = 1;
public static final int AlertDialog_buttonPanelSideLayout = 2;
public static final int AlertDialog_listItemLayout = 3;
public static final int AlertDialog_listLayout = 4;
public static final int AlertDialog_multiChoiceItemLayout = 5;
public static final int AlertDialog_showTitle = 6;
public static final int AlertDialog_singleChoiceItemLayout = 7;
public static final int[] AnimatedStateListDrawableCompat = { 0x101011c, 0x1010194, 0x1010195, 0x1010196, 0x101030c, 0x101030d };
public static final int AnimatedStateListDrawableCompat_android_dither = 0;
public static final int AnimatedStateListDrawableCompat_android_visible = 1;
public static final int AnimatedStateListDrawableCompat_android_variablePadding = 2;
public static final int AnimatedStateListDrawableCompat_android_constantSize = 3;
public static final int AnimatedStateListDrawableCompat_android_enterFadeDuration = 4;
public static final int AnimatedStateListDrawableCompat_android_exitFadeDuration = 5;
public static final int[] AnimatedStateListDrawableItem = { 0x10100d0, 0x1010199 };
public static final int AnimatedStateListDrawableItem_android_id = 0;
public static final int AnimatedStateListDrawableItem_android_drawable = 1;
public static final int[] AnimatedStateListDrawableTransition = { 0x1010199, 0x1010449, 0x101044a, 0x101044b };
public static final int AnimatedStateListDrawableTransition_android_drawable = 0;
public static final int AnimatedStateListDrawableTransition_android_toId = 1;
public static final int AnimatedStateListDrawableTransition_android_fromId = 2;
public static final int AnimatedStateListDrawableTransition_android_reversible = 3;
public static final int[] AppCompatImageView = { 0x1010119, 0x7f020107, 0x7f020128, 0x7f020129 };
public static final int AppCompatImageView_android_src = 0;
public static final int AppCompatImageView_srcCompat = 1;
public static final int AppCompatImageView_tint = 2;
public static final int AppCompatImageView_tintMode = 3;
public static final int[] AppCompatSeekBar = { 0x1010142, 0x7f020125, 0x7f020126, 0x7f020127 };
public static final int AppCompatSeekBar_android_thumb = 0;
public static final int AppCompatSeekBar_tickMark = 1;
public static final int AppCompatSeekBar_tickMarkTint = 2;
public static final int AppCompatSeekBar_tickMarkTintMode = 3;
public static final int[] AppCompatTextHelper = { 0x1010034, 0x101016d, 0x101016e, 0x101016f, 0x1010170, 0x1010392, 0x1010393 };
public static final int AppCompatTextHelper_android_textAppearance = 0;
public static final int AppCompatTextHelper_android_drawableTop = 1;
public static final int AppCompatTextHelper_android_drawableBottom = 2;
public static final int AppCompatTextHelper_android_drawableLeft = 3;
public static final int AppCompatTextHelper_android_drawableRight = 4;
public static final int AppCompatTextHelper_android_drawableStart = 5;
public static final int AppCompatTextHelper_android_drawableEnd = 6;
public static final int[] AppCompatTextView = { 0x1010034, 0x7f02002c, 0x7f02002d, 0x7f02002e, 0x7f02002f, 0x7f020030, 0x7f020079, 0x7f02007b, 0x7f020095, 0x7f0200cf, 0x7f020115 };
public static final int AppCompatTextView_android_textAppearance = 0;
public static final int AppCompatTextView_autoSizeMaxTextSize = 1;
public static final int AppCompatTextView_autoSizeMinTextSize = 2;
public static final int AppCompatTextView_autoSizePresetSizes = 3;
public static final int AppCompatTextView_autoSizeStepGranularity = 4;
public static final int AppCompatTextView_autoSizeTextType = 5;
public static final int AppCompatTextView_firstBaselineToTopHeight = 6;
public static final int AppCompatTextView_fontFamily = 7;
public static final int AppCompatTextView_lastBaselineToBottomHeight = 8;
public static final int AppCompatTextView_lineHeight = 9;
public static final int AppCompatTextView_textAllCaps = 10;
public static final int[] AppCompatTheme = { 0x1010057, 0x10100ae, 0x7f020000, 0x7f020001, 0x7f020002, 0x7f020003, 0x7f020004, 0x7f020005, 0x7f020006, 0x7f020007, 0x7f020008, 0x7f020009, 0x7f02000a, 0x7f02000b, 0x7f02000c, 0x7f02000e, 0x7f02000f, 0x7f020010, 0x7f020011, 0x7f020012, 0x7f020013, 0x7f020014, 0x7f020015, 0x7f020016, 0x7f020017, 0x7f020018, 0x7f020019, 0x7f02001a, 0x7f02001b, 0x7f02001c, 0x7f02001d, 0x7f02001e, 0x7f020021, 0x7f020022, 0x7f020023, 0x7f020024, 0x7f020025, 0x7f02002b, 0x7f020039, 0x7f02003a, 0x7f02003b, 0x7f02003c, 0x7f02003d, 0x7f02003e, 0x7f020042, 0x7f020043, 0x7f020047, 0x7f020048, 0x7f02004e, 0x7f02004f, 0x7f020050, 0x7f020051, 0x7f020052, 0x7f020053, 0x7f020054, 0x7f020055, 0x7f020056, 0x7f020057, 0x7f020063, 0x7f020067, 0x7f020068, 0x7f020069, 0x7f02006c, 0x7f02006e, 0x7f020071, 0x7f020072, 0x7f020073, 0x7f020074, 0x7f020075, 0x7f020089, 0x7f02008f, 0x7f0200d0, 0x7f0200d1, 0x7f0200d4, 0x7f0200d5, 0x7f0200d6, 0x7f0200d7, 0x7f0200d8, 0x7f0200d9, 0x7f0200da, 0x7f0200e9, 0x7f0200ea, 0x7f0200eb, 0x7f0200ec, 0x7f0200ee, 0x7f0200f4, 0x7f0200f5, 0x7f0200f6, 0x7f0200f7, 0x7f0200fa, 0x7f0200fb, 0x7f0200fc, 0x7f0200fd, 0x7f020104, 0x7f020105, 0x7f020113, 0x7f020116, 0x7f020117, 0x7f020118, 0x7f020119, 0x7f02011a, 0x7f02011b, 0x7f02011c, 0x7f02011d, 0x7f02011e, 0x7f02011f, 0x7f020134, 0x7f020135, 0x7f020136, 0x7f020137, 0x7f02013d, 0x7f02013f, 0x7f020140, 0x7f020141, 0x7f020142, 0x7f020143, 0x7f020144, 0x7f020145, 0x7f020146, 0x7f020147, 0x7f020148 };
public static final int AppCompatTheme_android_windowIsFloating = 0;
public static final int AppCompatTheme_android_windowAnimationStyle = 1;
public static final int AppCompatTheme_actionBarDivider = 2;
public static final int AppCompatTheme_actionBarItemBackground = 3;
public static final int AppCompatTheme_actionBarPopupTheme = 4;
public static final int AppCompatTheme_actionBarSize = 5;
public static final int AppCompatTheme_actionBarSplitStyle = 6;
public static final int AppCompatTheme_actionBarStyle = 7;
public static final int AppCompatTheme_actionBarTabBarStyle = 8;
public static final int AppCompatTheme_actionBarTabStyle = 9;
public static final int AppCompatTheme_actionBarTabTextStyle = 10;
public static final int AppCompatTheme_actionBarTheme = 11;
public static final int AppCompatTheme_actionBarWidgetTheme = 12;
public static final int AppCompatTheme_actionButtonStyle = 13;
public static final int AppCompatTheme_actionDropDownStyle = 14;
public static final int AppCompatTheme_actionMenuTextAppearance = 15;
public static final int AppCompatTheme_actionMenuTextColor = 16;
public static final int AppCompatTheme_actionModeBackground = 17;
public static final int AppCompatTheme_actionModeCloseButtonStyle = 18;
public static final int AppCompatTheme_actionModeCloseDrawable = 19;
public static final int AppCompatTheme_actionModeCopyDrawable = 20;
public static final int AppCompatTheme_actionModeCutDrawable = 21;
public static final int AppCompatTheme_actionModeFindDrawable = 22;
public static final int AppCompatTheme_actionModePasteDrawable = 23;
public static final int AppCompatTheme_actionModePopupWindowStyle = 24;
public static final int AppCompatTheme_actionModeSelectAllDrawable = 25;
public static final int AppCompatTheme_actionModeShareDrawable = 26;
public static final int AppCompatTheme_actionModeSplitBackground = 27;
public static final int AppCompatTheme_actionModeStyle = 28;
public static final int AppCompatTheme_actionModeWebSearchDrawable = 29;
public static final int AppCompatTheme_actionOverflowButtonStyle = 30;
public static final int AppCompatTheme_actionOverflowMenuStyle = 31;
public static final int AppCompatTheme_activityChooserViewStyle = 32;
public static final int AppCompatTheme_alertDialogButtonGroupStyle = 33;
public static final int AppCompatTheme_alertDialogCenterButtons = 34;
public static final int AppCompatTheme_alertDialogStyle = 35;
public static final int AppCompatTheme_alertDialogTheme = 36;
public static final int AppCompatTheme_autoCompleteTextViewStyle = 37;
public static final int AppCompatTheme_borderlessButtonStyle = 38;
public static final int AppCompatTheme_buttonBarButtonStyle = 39;
public static final int AppCompatTheme_buttonBarNegativeButtonStyle = 40;
public static final int AppCompatTheme_buttonBarNeutralButtonStyle = 41;
public static final int AppCompatTheme_buttonBarPositiveButtonStyle = 42;
public static final int AppCompatTheme_buttonBarStyle = 43;
public static final int AppCompatTheme_buttonStyle = 44;
public static final int AppCompatTheme_buttonStyleSmall = 45;
public static final int AppCompatTheme_checkboxStyle = 46;
public static final int AppCompatTheme_checkedTextViewStyle = 47;
public static final int AppCompatTheme_colorAccent = 48;
public static final int AppCompatTheme_colorBackgroundFloating = 49;
public static final int AppCompatTheme_colorButtonNormal = 50;
public static final int AppCompatTheme_colorControlActivated = 51;
public static final int AppCompatTheme_colorControlHighlight = 52;
public static final int AppCompatTheme_colorControlNormal = 53;
public static final int AppCompatTheme_colorError = 54;
public static final int AppCompatTheme_colorPrimary = 55;
public static final int AppCompatTheme_colorPrimaryDark = 56;
public static final int AppCompatTheme_colorSwitchThumbNormal = 57;
public static final int AppCompatTheme_controlBackground = 58;
public static final int AppCompatTheme_dialogCornerRadius = 59;
public static final int AppCompatTheme_dialogPreferredPadding = 60;
public static final int AppCompatTheme_dialogTheme = 61;
public static final int AppCompatTheme_dividerHorizontal = 62;
public static final int AppCompatTheme_dividerVertical = 63;
public static final int AppCompatTheme_dropDownListViewStyle = 64;
public static final int AppCompatTheme_dropdownListPreferredItemHeight = 65;
public static final int AppCompatTheme_editTextBackground = 66;
public static final int AppCompatTheme_editTextColor = 67;
public static final int AppCompatTheme_editTextStyle = 68;
public static final int AppCompatTheme_homeAsUpIndicator = 69;
public static final int AppCompatTheme_imageButtonStyle = 70;
public static final int AppCompatTheme_listChoiceBackgroundIndicator = 71;
public static final int AppCompatTheme_listDividerAlertDialog = 72;
public static final int AppCompatTheme_listMenuViewStyle = 73;
public static final int AppCompatTheme_listPopupWindowStyle = 74;
public static final int AppCompatTheme_listPreferredItemHeight = 75;
public static final int AppCompatTheme_listPreferredItemHeightLarge = 76;
public static final int AppCompatTheme_listPreferredItemHeightSmall = 77;
public static final int AppCompatTheme_listPreferredItemPaddingLeft = 78;
public static final int AppCompatTheme_listPreferredItemPaddingRight = 79;
public static final int AppCompatTheme_panelBackground = 80;
public static final int AppCompatTheme_panelMenuListTheme = 81;
public static final int AppCompatTheme_panelMenuListWidth = 82;
public static final int AppCompatTheme_popupMenuStyle = 83;
public static final int AppCompatTheme_popupWindowStyle = 84;
public static final int AppCompatTheme_radioButtonStyle = 85;
public static final int AppCompatTheme_ratingBarStyle = 86;
public static final int AppCompatTheme_ratingBarStyleIndicator = 87;
public static final int AppCompatTheme_ratingBarStyleSmall = 88;
public static final int AppCompatTheme_searchViewStyle = 89;
public static final int AppCompatTheme_seekBarStyle = 90;
public static final int AppCompatTheme_selectableItemBackground = 91;
public static final int AppCompatTheme_selectableItemBackgroundBorderless = 92;
public static final int AppCompatTheme_spinnerDropDownItemStyle = 93;
public static final int AppCompatTheme_spinnerStyle = 94;
public static final int AppCompatTheme_switchStyle = 95;
public static final int AppCompatTheme_textAppearanceLargePopupMenu = 96;
public static final int AppCompatTheme_textAppearanceListItem = 97;
public static final int AppCompatTheme_textAppearanceListItemSecondary = 98;
public static final int AppCompatTheme_textAppearanceListItemSmall = 99;
public static final int AppCompatTheme_textAppearancePopupMenuHeader = 100;
public static final int AppCompatTheme_textAppearanceSearchResultSubtitle = 101;
public static final int AppCompatTheme_textAppearanceSearchResultTitle = 102;
public static final int AppCompatTheme_textAppearanceSmallPopupMenu = 103;
public static final int AppCompatTheme_textColorAlertDialogListItem = 104;
public static final int AppCompatTheme_textColorSearchUrl = 105;
public static final int AppCompatTheme_toolbarNavigationButtonStyle = 106;
public static final int AppCompatTheme_toolbarStyle = 107;
public static final int AppCompatTheme_tooltipForegroundColor = 108;
public static final int AppCompatTheme_tooltipFrameBackground = 109;
public static final int AppCompatTheme_viewInflaterClass = 110;
public static final int AppCompatTheme_windowActionBar = 111;
public static final int AppCompatTheme_windowActionBarOverlay = 112;
public static final int AppCompatTheme_windowActionModeOverlay = 113;
public static final int AppCompatTheme_windowFixedHeightMajor = 114;
public static final int AppCompatTheme_windowFixedHeightMinor = 115;
public static final int AppCompatTheme_windowFixedWidthMajor = 116;
public static final int AppCompatTheme_windowFixedWidthMinor = 117;
public static final int AppCompatTheme_windowMinWidthMajor = 118;
public static final int AppCompatTheme_windowMinWidthMinor = 119;
public static final int AppCompatTheme_windowNoTitle = 120;
public static final int[] ButtonBarLayout = { 0x7f020026 };
public static final int ButtonBarLayout_allowStacking = 0;
public static final int[] ColorStateListItem = { 0x10101a5, 0x101031f, 0x7f020027 };
public static final int ColorStateListItem_android_color = 0;
public static final int ColorStateListItem_android_alpha = 1;
public static final int ColorStateListItem_alpha = 2;
public static final int[] CompoundButton = { 0x1010107, 0x7f020044, 0x7f020045 };
public static final int CompoundButton_android_button = 0;
public static final int CompoundButton_buttonTint = 1;
public static final int CompoundButton_buttonTintMode = 2;
public static final int[] CoordinatorLayout = { 0x7f020094, 0x7f020109 };
public static final int CoordinatorLayout_keylines = 0;
public static final int CoordinatorLayout_statusBarBackground = 1;
public static final int[] CoordinatorLayout_Layout = { 0x10100b3, 0x7f020097, 0x7f020098, 0x7f020099, 0x7f0200c3, 0x7f0200cc, 0x7f0200cd };
public static final int CoordinatorLayout_Layout_android_layout_gravity = 0;
public static final int CoordinatorLayout_Layout_layout_anchor = 1;
public static final int CoordinatorLayout_Layout_layout_anchorGravity = 2;
public static final int CoordinatorLayout_Layout_layout_behavior = 3;
public static final int CoordinatorLayout_Layout_layout_dodgeInsetEdges = 4;
public static final int CoordinatorLayout_Layout_layout_insetEdge = 5;
public static final int CoordinatorLayout_Layout_layout_keyline = 6;
public static final int[] DrawerArrowToggle = { 0x7f020029, 0x7f02002a, 0x7f020036, 0x7f02004d, 0x7f02006f, 0x7f020085, 0x7f020103, 0x7f020121 };
public static final int DrawerArrowToggle_arrowHeadLength = 0;
public static final int DrawerArrowToggle_arrowShaftLength = 1;
public static final int DrawerArrowToggle_barLength = 2;
public static final int DrawerArrowToggle_color = 3;
public static final int DrawerArrowToggle_drawableSize = 4;
public static final int DrawerArrowToggle_gapBetweenBars = 5;
public static final int DrawerArrowToggle_spinBars = 6;
public static final int DrawerArrowToggle_thickness = 7;
public static final int[] FontFamily = { 0x7f02007c, 0x7f02007d, 0x7f02007e, 0x7f02007f, 0x7f020080, 0x7f020081 };
public static final int FontFamily_fontProviderAuthority = 0;
public static final int FontFamily_fontProviderCerts = 1;
public static final int FontFamily_fontProviderFetchStrategy = 2;
public static final int FontFamily_fontProviderFetchTimeout = 3;
public static final int FontFamily_fontProviderPackage = 4;
public static final int FontFamily_fontProviderQuery = 5;
public static final int[] FontFamilyFont = { 0x1010532, 0x1010533, 0x101053f, 0x101056f, 0x1010570, 0x7f02007a, 0x7f020082, 0x7f020083, 0x7f020084, 0x7f02013c };
public static final int FontFamilyFont_android_font = 0;
public static final int FontFamilyFont_android_fontWeight = 1;
public static final int FontFamilyFont_android_fontStyle = 2;
public static final int FontFamilyFont_android_ttcIndex = 3;
public static final int FontFamilyFont_android_fontVariationSettings = 4;
public static final int FontFamilyFont_font = 5;
public static final int FontFamilyFont_fontStyle = 6;
public static final int FontFamilyFont_fontVariationSettings = 7;
public static final int FontFamilyFont_fontWeight = 8;
public static final int FontFamilyFont_ttcIndex = 9;
public static final int[] GradientColor = { 0x101019d, 0x101019e, 0x10101a1, 0x10101a2, 0x10101a3, 0x10101a4, 0x1010201, 0x101020b, 0x1010510, 0x1010511, 0x1010512, 0x1010513 };
public static final int GradientColor_android_startColor = 0;
public static final int GradientColor_android_endColor = 1;
public static final int GradientColor_android_type = 2;
public static final int GradientColor_android_centerX = 3;
public static final int GradientColor_android_centerY = 4;
public static final int GradientColor_android_gradientRadius = 5;
public static final int GradientColor_android_tileMode = 6;
public static final int GradientColor_android_centerColor = 7;
public static final int GradientColor_android_startX = 8;
public static final int GradientColor_android_startY = 9;
public static final int GradientColor_android_endX = 10;
public static final int GradientColor_android_endY = 11;
public static final int[] GradientColorItem = { 0x10101a5, 0x1010514 };
public static final int GradientColorItem_android_color = 0;
public static final int GradientColorItem_android_offset = 1;
public static final int[] LinearLayoutCompat = { 0x10100af, 0x10100c4, 0x1010126, 0x1010127, 0x1010128, 0x7f02006b, 0x7f02006d, 0x7f0200de, 0x7f0200ff };
public static final int LinearLayoutCompat_android_gravity = 0;
public static final int LinearLayoutCompat_android_orientation = 1;
public static final int LinearLayoutCompat_android_baselineAligned = 2;
public static final int LinearLayoutCompat_android_baselineAlignedChildIndex = 3;
public static final int LinearLayoutCompat_android_weightSum = 4;
public static final int LinearLayoutCompat_divider = 5;
public static final int LinearLayoutCompat_dividerPadding = 6;
public static final int LinearLayoutCompat_measureWithLargestChild = 7;
public static final int LinearLayoutCompat_showDividers = 8;
public static final int[] LinearLayoutCompat_Layout = { 0x10100b3, 0x10100f4, 0x10100f5, 0x1010181 };
public static final int LinearLayoutCompat_Layout_android_layout_gravity = 0;
public static final int LinearLayoutCompat_Layout_android_layout_width = 1;
public static final int LinearLayoutCompat_Layout_android_layout_height = 2;
public static final int LinearLayoutCompat_Layout_android_layout_weight = 3;
public static final int[] ListPopupWindow = { 0x10102ac, 0x10102ad };
public static final int ListPopupWindow_android_dropDownHorizontalOffset = 0;
public static final int ListPopupWindow_android_dropDownVerticalOffset = 1;
public static final int[] MenuGroup = { 0x101000e, 0x10100d0, 0x1010194, 0x10101de, 0x10101df, 0x10101e0 };
public static final int MenuGroup_android_enabled = 0;
public static final int MenuGroup_android_id = 1;
public static final int MenuGroup_android_visible = 2;
public static final int MenuGroup_android_menuCategory = 3;
public static final int MenuGroup_android_orderInCategory = 4;
public static final int MenuGroup_android_checkableBehavior = 5;
public static final int[] MenuItem = { 0x1010002, 0x101000e, 0x10100d0, 0x1010106, 0x1010194, 0x10101de, 0x10101df, 0x10101e1, 0x10101e2, 0x10101e3, 0x10101e4, 0x10101e5, 0x101026f, 0x7f02000d, 0x7f02001f, 0x7f020020, 0x7f020028, 0x7f02005c, 0x7f02008c, 0x7f02008d, 0x7f0200e3, 0x7f0200fe, 0x7f020138 };
public static final int MenuItem_android_icon = 0;
public static final int MenuItem_android_enabled = 1;
public static final int MenuItem_android_id = 2;
public static final int MenuItem_android_checked = 3;
public static final int MenuItem_android_visible = 4;
public static final int MenuItem_android_menuCategory = 5;
public static final int MenuItem_android_orderInCategory = 6;
public static final int MenuItem_android_title = 7;
public static final int MenuItem_android_titleCondensed = 8;
public static final int MenuItem_android_alphabeticShortcut = 9;
public static final int MenuItem_android_numericShortcut = 10;
public static final int MenuItem_android_checkable = 11;
public static final int MenuItem_android_onClick = 12;
public static final int MenuItem_actionLayout = 13;
public static final int MenuItem_actionProviderClass = 14;
public static final int MenuItem_actionViewClass = 15;
public static final int MenuItem_alphabeticModifiers = 16;
public static final int MenuItem_contentDescription = 17;
public static final int MenuItem_iconTint = 18;
public static final int MenuItem_iconTintMode = 19;
public static final int MenuItem_numericModifiers = 20;
public static final int MenuItem_showAsAction = 21;
public static final int MenuItem_tooltipText = 22;
public static final int[] MenuView = { 0x10100ae, 0x101012c, 0x101012d, 0x101012e, 0x101012f, 0x1010130, 0x1010131, 0x7f0200ef, 0x7f02010a };
public static final int MenuView_android_windowAnimationStyle = 0;
public static final int MenuView_android_itemTextAppearance = 1;
public static final int MenuView_android_horizontalDivider = 2;
public static final int MenuView_android_verticalDivider = 3;
public static final int MenuView_android_headerBackground = 4;
public static final int MenuView_android_itemBackground = 5;
public static final int MenuView_android_itemIconDisabledAlpha = 6;
public static final int MenuView_preserveIconSpacing = 7;
public static final int MenuView_subMenuArrow = 8;
public static final int[] PopupWindow = { 0x1010176, 0x10102c9, 0x7f0200e4 };
public static final int PopupWindow_android_popupBackground = 0;
public static final int PopupWindow_android_popupAnimationStyle = 1;
public static final int PopupWindow_overlapAnchor = 2;
public static final int[] PopupWindowBackgroundState = { 0x7f020108 };
public static final int PopupWindowBackgroundState_state_above_anchor = 0;
public static final int[] RecycleListView = { 0x7f0200e5, 0x7f0200e8 };
public static final int RecycleListView_paddingBottomNoButtons = 0;
public static final int RecycleListView_paddingTopNoTitle = 1;
public static final int[] SearchView = { 0x10100da, 0x101011f, 0x1010220, 0x1010264, 0x7f020049, 0x7f020058, 0x7f020066, 0x7f020086, 0x7f02008e, 0x7f020096, 0x7f0200f2, 0x7f0200f3, 0x7f0200f8, 0x7f0200f9, 0x7f02010b, 0x7f020110, 0x7f02013e };
public static final int SearchView_android_focusable = 0;
public static final int SearchView_android_maxWidth = 1;
public static final int SearchView_android_inputType = 2;
public static final int SearchView_android_imeOptions = 3;
public static final int SearchView_closeIcon = 4;
public static final int SearchView_commitIcon = 5;
public static final int SearchView_defaultQueryHint = 6;
public static final int SearchView_goIcon = 7;
public static final int SearchView_iconifiedByDefault = 8;
public static final int SearchView_layout = 9;
public static final int SearchView_queryBackground = 10;
public static final int SearchView_queryHint = 11;
public static final int SearchView_searchHintIcon = 12;
public static final int SearchView_searchIcon = 13;
public static final int SearchView_submitBackground = 14;
public static final int SearchView_suggestionRowLayout = 15;
public static final int SearchView_voiceIcon = 16;
public static final int[] Spinner = { 0x10100b2, 0x1010176, 0x101017b, 0x1010262, 0x7f0200ed };
public static final int Spinner_android_entries = 0;
public static final int Spinner_android_popupBackground = 1;
public static final int Spinner_android_prompt = 2;
public static final int Spinner_android_dropDownWidth = 3;
public static final int Spinner_popupTheme = 4;
public static final int[] StateListDrawable = { 0x101011c, 0x1010194, 0x1010195, 0x1010196, 0x101030c, 0x101030d };
public static final int StateListDrawable_android_dither = 0;
public static final int StateListDrawable_android_visible = 1;
public static final int StateListDrawable_android_variablePadding = 2;
public static final int StateListDrawable_android_constantSize = 3;
public static final int StateListDrawable_android_enterFadeDuration = 4;
public static final int StateListDrawable_android_exitFadeDuration = 5;
public static final int[] StateListDrawableItem = { 0x1010199 };
public static final int StateListDrawableItem_android_drawable = 0;
public static final int[] SwitchCompat = { 0x1010124, 0x1010125, 0x1010142, 0x7f020100, 0x7f020106, 0x7f020111, 0x7f020112, 0x7f020114, 0x7f020122, 0x7f020123, 0x7f020124, 0x7f020139, 0x7f02013a, 0x7f02013b };
public static final int SwitchCompat_android_textOn = 0;
public static final int SwitchCompat_android_textOff = 1;
public static final int SwitchCompat_android_thumb = 2;
public static final int SwitchCompat_showText = 3;
public static final int SwitchCompat_splitTrack = 4;
public static final int SwitchCompat_switchMinWidth = 5;
public static final int SwitchCompat_switchPadding = 6;
public static final int SwitchCompat_switchTextAppearance = 7;
public static final int SwitchCompat_thumbTextPadding = 8;
public static final int SwitchCompat_thumbTint = 9;
public static final int SwitchCompat_thumbTintMode = 10;
public static final int SwitchCompat_track = 11;
public static final int SwitchCompat_trackTint = 12;
public static final int SwitchCompat_trackTintMode = 13;
public static final int[] TextAppearance = { 0x1010095, 0x1010096, 0x1010097, 0x1010098, 0x101009a, 0x101009b, 0x1010161, 0x1010162, 0x1010163, 0x1010164, 0x10103ac, 0x7f02007b, 0x7f020115 };
public static final int TextAppearance_android_textSize = 0;
public static final int TextAppearance_android_typeface = 1;
public static final int TextAppearance_android_textStyle = 2;
public static final int TextAppearance_android_textColor = 3;
public static final int TextAppearance_android_textColorHint = 4;
public static final int TextAppearance_android_textColorLink = 5;
public static final int TextAppearance_android_shadowColor = 6;
public static final int TextAppearance_android_shadowDx = 7;
public static final int TextAppearance_android_shadowDy = 8;
public static final int TextAppearance_android_shadowRadius = 9;
public static final int TextAppearance_android_fontFamily = 10;
public static final int TextAppearance_fontFamily = 11;
public static final int TextAppearance_textAllCaps = 12;
public static final int[] Toolbar = { 0x10100af, 0x1010140, 0x7f02003f, 0x7f02004b, 0x7f02004c, 0x7f02005d, 0x7f02005e, 0x7f02005f, 0x7f020060, 0x7f020061, 0x7f020062, 0x7f0200db, 0x7f0200dc, 0x7f0200dd, 0x7f0200e0, 0x7f0200e1, 0x7f0200ed, 0x7f02010c, 0x7f02010d, 0x7f02010e, 0x7f02012a, 0x7f02012b, 0x7f02012c, 0x7f02012d, 0x7f02012e, 0x7f02012f, 0x7f020130, 0x7f020131, 0x7f020132 };
public static final int Toolbar_android_gravity = 0;
public static final int Toolbar_android_minHeight = 1;
public static final int Toolbar_buttonGravity = 2;
public static final int Toolbar_collapseContentDescription = 3;
public static final int Toolbar_collapseIcon = 4;
public static final int Toolbar_contentInsetEnd = 5;
public static final int Toolbar_contentInsetEndWithActions = 6;
public static final int Toolbar_contentInsetLeft = 7;
public static final int Toolbar_contentInsetRight = 8;
public static final int Toolbar_contentInsetStart = 9;
public static final int Toolbar_contentInsetStartWithNavigation = 10;
public static final int Toolbar_logo = 11;
public static final int Toolbar_logoDescription = 12;
public static final int Toolbar_maxButtonHeight = 13;
public static final int Toolbar_navigationContentDescription = 14;
public static final int Toolbar_navigationIcon = 15;
public static final int Toolbar_popupTheme = 16;
public static final int Toolbar_subtitle = 17;
public static final int Toolbar_subtitleTextAppearance = 18;
public static final int Toolbar_subtitleTextColor = 19;
public static final int Toolbar_title = 20;
public static final int Toolbar_titleMargin = 21;
public static final int Toolbar_titleMarginBottom = 22;
public static final int Toolbar_titleMarginEnd = 23;
public static final int Toolbar_titleMarginStart = 24;
public static final int Toolbar_titleMarginTop = 25;
public static final int Toolbar_titleMargins = 26;
public static final int Toolbar_titleTextAppearance = 27;
public static final int Toolbar_titleTextColor = 28;
public static final int[] View = { 0x1010000, 0x10100da, 0x7f0200e6, 0x7f0200e7, 0x7f020120 };
public static final int View_android_theme = 0;
public static final int View_android_focusable = 1;
public static final int View_paddingEnd = 2;
public static final int View_paddingStart = 3;
public static final int View_theme = 4;
public static final int[] ViewBackgroundHelper = { 0x10100d4, 0x7f020034, 0x7f020035 };
public static final int ViewBackgroundHelper_android_background = 0;
public static final int ViewBackgroundHelper_backgroundTint = 1;
public static final int ViewBackgroundHelper_backgroundTintMode = 2;
public static final int[] ViewStubCompat = { 0x10100d0, 0x10100f2, 0x10100f3 };
public static final int ViewStubCompat_android_id = 0;
public static final int ViewStubCompat_android_layout = 1;
public static final int ViewStubCompat_android_inflatedId = 2;
}
}
| [
"htata31@gmail.com"
] | htata31@gmail.com |
b88f937d705e64a9a7205e047b558076fe9f65be | a623cb613fe17d934b03ca4f235a055a696d94d5 | /nem-monitor/src/main/java/org/nem/monitor/NemMonitor.java | f0d6a94acb0c84943a8064e281e9d07b729b6524 | [
"MIT"
] | permissive | filchef/NemCommunityClient | 6d5191fe3cfa31b6de4d6fc3f44c3a053f4e92bf | af2222afee951e7898bdface1aa58fed6c2e81ea | refs/heads/master | 2021-01-21T09:03:04.713322 | 2014-08-27T07:12:10 | 2014-08-27T07:12:10 | 23,467,658 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,247 | java | package org.nem.monitor;
import org.nem.core.connect.*;
import org.nem.core.deploy.LoggingBootstrapper;
import org.nem.monitor.config.*;
import org.nem.monitor.node.*;
import org.nem.monitor.ux.TrayIconBuilder;
import javax.swing.*;
import java.awt.*;
import java.util.logging.Logger;
/**
* The nem monitor program.
*/
public class NemMonitor {
private static final Logger LOGGER = Logger.getLogger(NemMonitor.class.getName());
static {
// initialize logging before anything is logged; otherwise not all
// settings will take effect
LoggingBootstrapper.bootstrap(new MonitorConfiguration().getNemFolder());
}
/**
* The main entry point.
*
* @param args The command line arguments.
*/
public static void main(final String[] args) {
final MonitorCommandLine commandLine = MonitorCommandLine.parse(args);
LOGGER.info(String.format("NCC JNLP configured as: %s", commandLine.getNccJnlpUrl()));
LOGGER.info(String.format("NIS JNLP configured as: %s", commandLine.getNisJnlpUrl()));
SwingUtilities.invokeLater(() -> {
LOGGER.info("setting up system tray");
// fail if the system tray is not supported
if (!SystemTray.isSupported()) {
throw new SystemTrayException("SystemTray is not supported");
}
final String nemFolder = new MonitorConfiguration().getNemFolder();
final SystemTray tray = SystemTray.getSystemTray();
final TrayIconBuilder builder = new TrayIconBuilder(
createHttpMethodClient(),
new WebStartLauncher(nemFolder),
new WebBrowser());
builder.addStatusMenuItems(new NisNodePolicy(nemFolder), commandLine.getNisJnlpUrl());
builder.addSeparator();
builder.addStatusMenuItems(new NccNodePolicy(nemFolder), commandLine.getNccJnlpUrl());
builder.addSeparator();
builder.addExitMenuItem(tray);
try {
tray.add(builder.create());
} catch (final AWTException e) {
throw new SystemTrayException("Unable to add icon to system tray", e);
}
});
}
private static HttpMethodClient<ErrorResponseDeserializerUnion> createHttpMethodClient() {
final int CONNECTION_TIMEOUT = 2000;
final int SOCKET_TIMEOUT = 2000;
final int REQUEST_TIMEOUT = 4000;
return new HttpMethodClient<>(CONNECTION_TIMEOUT, SOCKET_TIMEOUT, REQUEST_TIMEOUT);
}
} | [
"jaguar0625@127.0.0.1"
] | jaguar0625@127.0.0.1 |
1dac3ed5a830916aded7e3d8042a2107656eedbe | d845c34f5b875c220293265b49dfd51f290d4ee0 | /projects/org.graalvm.vm.posix/src/org/graalvm/vm/posix/api/Timespec.java | deacd4bca528aa29a8a3c235e1267083c7d62819 | [
"UPL-1.0",
"Apache-2.0"
] | permissive | pekd/vmx86 | d136c86b8ccd2d22f3aaff9296bb861d6fac5d42 | f7e7e839a13f6d519cf25598dd5dfcdcacd1a177 | refs/heads/dev | 2022-07-01T23:35:21.609475 | 2022-06-17T16:53:14 | 2022-06-17T16:53:14 | 215,284,931 | 4 | 2 | NOASSERTION | 2020-02-28T15:12:46 | 2019-10-15T11:45:31 | Java | UTF-8 | Java | false | false | 3,751 | java | /*
* Copyright (c) 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* The Universal Permissive License (UPL), Version 1.0
*
* Subject to the condition set forth below, permission is hereby granted to any
* person obtaining a copy of this software, associated documentation and/or
* data (collectively the "Software"), free of charge and under any and all
* copyright rights in the Software, and any and all patent rights owned or
* freely licensable by each licensor hereunder covering either (i) the
* unmodified Software as contributed to or provided by such licensor, or (ii)
* the Larger Works (as defined below), to deal in both
*
* (a) the Software, and
*
* (b) any piece of software and/or hardware listed in the lrgrwrks.txt file if
* one is included with the Software each a "Larger Work" to which the Software
* is contributed by such licensors),
*
* without restriction, including without limitation the rights to copy, create
* derivative works of, display, perform, and distribute the Software and make,
* use, sell, offer for sale, import, export, have made, and have sold the
* Software and the Larger Work(s), and to sublicense the foregoing rights on
* either these or other terms.
*
* This license is subject to the following condition:
*
* The above copyright notice and either this complete permission notice or at a
* minimum a reference to the UPL must be included in all copies or substantial
* portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*/
package org.graalvm.vm.posix.api;
import java.util.Date;
public class Timespec implements Struct {
public long tv_sec;
public long tv_nsec;
public Timespec() {
}
public Timespec(long tv_sec, long tv_nsec) {
this.tv_sec = tv_sec;
this.tv_nsec = tv_nsec;
}
public Timespec(Date date) {
long msec = date.getTime();
tv_sec = msec / 1000;
tv_nsec = (msec % 1000) * 1000000;
}
public Timespec(Timespec ts) {
copyFrom(ts);
}
public long toMillis() {
return tv_sec * 1000 + (tv_nsec / 1000000);
}
public void copyFrom(Timespec ts) {
tv_sec = ts.tv_sec;
tv_nsec = ts.tv_nsec;
}
@Override
public PosixPointer read32(PosixPointer ptr) {
PosixPointer p = ptr;
tv_sec = Integer.toUnsignedLong(p.getI32());
p = p.add(4);
tv_nsec = Integer.toUnsignedLong(p.getI32());
return p.add(4);
}
@Override
public PosixPointer read64(PosixPointer ptr) {
PosixPointer p = ptr;
tv_sec = p.getI64();
p = p.add(8);
tv_nsec = p.getI64();
return p.add(8);
}
@Override
public PosixPointer write32(PosixPointer ptr) {
PosixPointer p = ptr;
p.setI32((int) tv_sec);
p = p.add(4);
p.setI32((int) tv_nsec);
return p.add(4);
}
@Override
public PosixPointer write64(PosixPointer ptr) {
PosixPointer p = ptr;
p.setI64(tv_sec);
p = p.add(8);
p.setI64(tv_nsec);
return p.add(8);
}
@Override
public String toString() {
return String.format("{tv_sec=%d,tv_nsec=%d}", tv_sec, tv_nsec);
}
}
| [
"pekarekdaniel@gmail.com"
] | pekarekdaniel@gmail.com |
b429883edd25144f758c6d71f000f08a0f8620e4 | bb7564812e31fc8b7f44b240749dedc4ffca9409 | /src/test/java/me/bayes/vertx/spring/boot/VertxPropertiesTest.java | d674e48542d03deb12a377e232ff10a7615b4167 | [
"Apache-2.0"
] | permissive | kevinbayes/vertx-spring-boot-starter | c25d07a11338931b0106e9d72c90351f7018adce | 1b17f8f3976a705f0eda1b6ed98a1e6dca099ec0 | refs/heads/master | 2020-12-24T12:20:13.064566 | 2017-07-12T09:50:53 | 2017-07-12T09:50:53 | 73,055,609 | 3 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,308 | java | /**
* Copyright 2016 Kevin Bayes
*
* 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 me.bayes.vertx.spring.boot;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
import static org.junit.Assert.*;
/**
* Created by kevinbayes on 7/11/16.
*/
@RunWith(SpringJUnit4ClassRunner.class)
@SpringBootTest(classes = Launcher.class)
public class VertxPropertiesTest {
@Value("${spring.boot.ext.vertx.eventLoopPoolSize}")
public String eventLoopPoolSize;
@Test
public void getEventLoopPoolSize() throws Exception {
assertEquals("123", eventLoopPoolSize);
}
} | [
"kevinbayes@Admin-088s-MacBook-Pro.local"
] | kevinbayes@Admin-088s-MacBook-Pro.local |
2919db243774761028bb379a5d4f568400682156 | 66c19ca02f9841b71564e88316e15008a029420c | /src/main/java/chen/guo/example/jersey/rest/Download.java | 5d116cc7979702eeed963fd66eb9666b9819d804 | [] | no_license | enjoyear/jersey | 5a258447225b90dfd2ca343639222252b59091e9 | 8f623af9e31c744858a92fc6577d588b966a0fca | refs/heads/master | 2020-08-05T14:37:13.537243 | 2016-09-06T02:37:15 | 2016-09-06T02:37:15 | 66,962,593 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,441 | java | package chen.guo.example.jersey.rest;
import chen.guo.example.jersey.service.DownloadService;
import org.glassfish.jersey.media.multipart.FormDataParam;
import javax.ws.rs.Consumes;
import javax.ws.rs.FormParam;
import javax.ws.rs.GET;
import javax.ws.rs.POST;
import javax.ws.rs.Path;
import javax.ws.rs.Produces;
import javax.ws.rs.core.MediaType;
import javax.ws.rs.core.Response;
import javax.ws.rs.core.StreamingOutput;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.Reader;
@Path("home")
public class Download {
private DownloadService downloadService = new DownloadService();
@GET
@Path("download")
@Produces(MediaType.TEXT_HTML)
public InputStream doGet() throws FileNotFoundException {
//http://localhost:8080/home/download
File f = new File("src/main/webapp/WEB-INF/html/download.html");
return new FileInputStream(f);
}
@POST
@Path("download")
@Consumes(MediaType.MULTIPART_FORM_DATA)
@Produces(MediaType.APPLICATION_OCTET_STREAM)
public Response uploadDownload(@FormDataParam("content") String content,
@FormDataParam("option") String option,
@FormDataParam("fileStream") InputStream fileStream,
@FormDataParam("checkbox") String checkBox) {
//curl --data "content=hi,there" localhost:8080/home/download
System.out.println("downloading...");
StreamingOutput stream = os -> {
StringBuilder sb = new StringBuilder();
sb.append("Content:,").append(content).append("\n");
sb.append("Option:,").append(option).append("\n");
sb.append("CheckBox:,").append(checkBox).append("\n"); //returns "on" or null
final int bufferSize = 1024;
final char[] buffer = new char[bufferSize];
final StringBuilder out = new StringBuilder();
Reader reader = new InputStreamReader(fileStream, "UTF-8");
while (true) {
int size = reader.read(buffer, 0, buffer.length);
if (size < 0)
break;
out.append(buffer, 0, size);
}
sb.append("Uploaded File:,").append(out.toString()).append("\n");
downloadService.download(os, sb.toString());
};
//String mediaType = download != null ? "text/csv" : MediaType.TEXT_PLAIN;
return Response.ok(stream, "text/csv").build();
}
}
| [
"almightygc@gmail.com"
] | almightygc@gmail.com |
8e1f30dca267b4b635bd7a97d1770c4814ec95af | af9d493bdbc89a9e28a1054437d5a6c6a8f5a566 | /app/src/main/java/com/podmark/twitter/store/CredentialStore.java | 35b8c4108f5e0afd6906ac20933c427e29ab5141 | [] | no_license | talhaocakci/podcastsocial | e7fe3f8f1525a277fb442b3792c6fba8bddb088e | 0b7adb9866c827bf0809f241893de3a91bc52e09 | refs/heads/master | 2021-01-11T19:53:01.122254 | 2017-03-09T20:11:35 | 2017-03-09T20:11:35 | 70,582,097 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 162 | java | package com.podmark.twitter.store;
public interface CredentialStore {
String[] read();
void write(String[] response);
void clearCredentials();
}
| [
"talha.ocakci@monitise.com"
] | talha.ocakci@monitise.com |
c2d5065055fe960abbff64fdf820fdc0a9b4a02f | 296b33b9b9311921c8803c6bfd9e322a2c0ce449 | /src/com/Principal.java | f0d329b4d66a9af200d1835e344aed6df8af0d18 | [] | no_license | Otax-png/Lord-of-the-Rings | 0d0644a6e4b1d1c14871b592c70840566ad28da2 | 2d4a23de67137814987735fab3bb6a2f47ef4e28 | refs/heads/master | 2023-06-03T04:06:04.882075 | 2021-06-23T22:13:27 | 2021-06-23T22:13:27 | 379,728,896 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 151 | java | package com;
public class Principal {
public static void main(String[] args) {
Juego juego = new Juego();
juego.jugar();
}
}
| [
"taxturnil201@gmail.com"
] | taxturnil201@gmail.com |
7cc6bbec96d2dfef40b4a6c3c8139ef8aa784931 | 7f9b73b3e2ac2f112d40aea55e38014cee5d71b5 | /core/src/main/java/com/musikais/filter/CORSFilter.java | ce5f2318cb7dc7ed832db1fbe1e0108b8f5f51c7 | [] | no_license | johntheo/Musikais | 21322164330ec0324f3d3f947fd772b9b9153785 | e55521fb2d66308fe65f1a0871daa4c47943a8b6 | refs/heads/master | 2016-09-06T00:43:49.385175 | 2016-02-01T20:21:06 | 2016-02-01T20:21:06 | 25,286,028 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 984 | java | package com.musikais.filter;
import java.io.IOException;
import javax.servlet.Filter;
import javax.servlet.FilterChain;
import javax.servlet.FilterConfig;
import javax.servlet.ServletException;
import javax.servlet.ServletRequest;
import javax.servlet.ServletResponse;
import javax.servlet.http.HttpServletResponse;
import org.springframework.stereotype.Component;
@Component
public class CORSFilter implements Filter {
public void doFilter(ServletRequest req, ServletResponse res, FilterChain chain) throws IOException, ServletException {
HttpServletResponse response = (HttpServletResponse) res;
response.setHeader("Access-Control-Allow-Origin", "*");
response.setHeader("Access-Control-Allow-Methods", "POST, GET, OPTIONS, DELETE");
response.setHeader("Access-Control-Max-Age", "3600");
response.setHeader("Access-Control-Allow-Headers", "x-requested-with");
chain.doFilter(req, res);
}
public void init(FilterConfig filterConfig) {}
public void destroy() {}
} | [
"john.theo.souza@gmail.com"
] | john.theo.souza@gmail.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.