blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 7 332 | content_id stringlengths 40 40 | detected_licenses listlengths 0 50 | license_type stringclasses 2
values | repo_name stringlengths 7 115 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringclasses 557
values | visit_date timestamp[us] | revision_date timestamp[us] | committer_date timestamp[us] | github_id int64 5.85k 684M ⌀ | star_events_count int64 0 77.7k | fork_events_count int64 0 48k | gha_license_id stringclasses 17
values | gha_event_created_at timestamp[us] | gha_created_at timestamp[us] | gha_language stringclasses 82
values | src_encoding stringclasses 28
values | language stringclasses 1
value | is_vendor bool 1
class | is_generated bool 2
classes | length_bytes int64 7 5.41M | extension stringclasses 11
values | content stringlengths 7 5.41M | authors listlengths 1 1 | author stringlengths 0 161 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
bc20cbdb0dc9ac60c2fdf50479fe3b7b1a5f4caa | af7b3639959b5735abe0bac83e640f3adb6fbba5 | /src/test/java/ashraful/rnd/vertx_redis/TestMainVerticle.java | c9f3f1a147be470bb7ef511c6c9985a8cc4756b9 | [] | no_license | Ashraf-RnD/vertx-redis | e998ebfa212e6c99b7726c21b306d5834093a245 | 94de3e6a517b1b6f194d377e1895e539d238320b | refs/heads/master | 2023-05-27T19:46:49.710716 | 2021-06-09T20:16:41 | 2021-06-09T20:16:41 | 375,478,326 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 660 | java | package ashraful.rnd.vertx_redis;
import io.vertx.core.Vertx;
import io.vertx.junit5.VertxExtension;
import io.vertx.junit5.VertxTestContext;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.extension.ExtendWith;
@ExtendWith(VertxExtension.class)
public class TestMainVerticle {
@BeforeEach
void deploy_verticle(Vertx vertx, VertxTestContext testContext) {
vertx.deployVerticle(new MainVerticle(), testContext.succeeding(id -> testContext.completeNow()));
}
@Test
void verticle_deployed(Vertx vertx, VertxTestContext testContext) throws Throwable {
testContext.completeNow();
}
}
| [
"ashraful.ph041@gmail.com"
] | ashraful.ph041@gmail.com |
9e63abe48d130223184ce1516b82ffaca8991195 | a12713feb683bba6bf13f23a11ec318d1c4bc0eb | /YndexDirectAPI/src/main/java/com/HideoKuzeGits/yndexDirectAPI/wrapClasses/Strategy.java | 2ab3953562d313617f066223612d12120824d90b | [] | no_license | Hideo-Kudze/Yandex-Direct-Broker | 4c1f40d0e30278786d2d627598ed06c8639a7a2f | 7d0200ac6e2d3828e4dcac665e4bbc12875e0ae7 | refs/heads/master | 2021-01-24T06:13:37.097663 | 2015-04-20T17:12:48 | 2015-04-20T17:12:48 | 34,272,418 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 619 | java |
package com.HideoKuzeGits.yndexDirectAPI.wrapClasses;
import javax.annotation.Generated;
import com.google.gson.annotations.Expose;
import com.google.gson.annotations.SerializedName;
@Generated("org.jsonschema2pojo")
public class Strategy extends AbstractWrap{
public Strategy(String strategyName) {
this.strategyName = strategyName;
}
@SerializedName("StrategyName")
@Expose
private String strategyName;
public String getStrategyName() {
return strategyName;
}
public void setStrategyName(String strategyName) {
this.strategyName = strategyName;
}
}
| [
"hideo.kuze@gmail.com"
] | hideo.kuze@gmail.com |
fbfcd8a8c5b6f60e2b8ee7d207d859dcc09db5d1 | 54c179b98af9e060278673f89747f13368d98ac0 | /bmp/bms/plan-summary/java/com/cdthgk/bmp/planSndSummary/annualPlan/action/AnnualPlanSelectAction.java | acfd9f7b139454ef28c229daa23d86f05b4dd31b | [] | no_license | toner-thy/toner-707 | 68b13a1a99ac91b2e38d8b94f3b9631bb6f500ff | 1b11b6d7afe08d1207309f11bf4fbdf87cdf3a69 | refs/heads/master | 2021-01-10T02:43:56.755708 | 2015-11-29T04:26:58 | 2015-11-29T04:26:58 | 43,945,951 | 3 | 1 | null | null | null | null | UTF-8 | Java | false | false | 4,095 | java | /**
*
*/
package com.cdthgk.bmp.planSndSummary.annualPlan.action;
import java.util.Collection;
import java.util.List;
import com.cdthgk.bmp.core.action.BmpAction;
import com.cdthgk.bmp.planSndSummary.annualPlan.service.AnnualPlanService;
import com.cdthgk.bmp.planSndSummary.annualPlan.vo.AnnualPlan;
import com.cdthgk.common.bean.BeanUtils;
import com.cdthgk.common.lang.LangUtils;
import com.cdthgk.component.ioc.ContextUtils;
import com.cdthgk.model.structure.autocomplete.Result;
import com.cdthgk.model.structure.autocomplete.Results;
import com.cdthgk.platform.district.domain.District;
import ec.common.PageSortModel;
/**
* <p>
* 类的说明放这里
* </p>
* <p>
* 创建人 宋亚非 创建时间 2014-4-30 - 下午2:08:09
* </p>
* <blockquote>
* <h4>历史修改记录</h4>
* <ul>
* <li>修改人 修改时间 修改描述
* </ul>
* </blockquote>
* <p>
* copyright cdthgk 2010-2011, all rights reserved.
* </p>
*
* @author 钟冀
* @author cdthgk r&d
* @since 1.0
* @version 1.0
*/
public class AnnualPlanSelectAction extends BmpAction{
private AnnualPlanService annualPlanService;
private AnnualPlan annualPlan;
/**
* 自动补全
* @return
*/
public String autocomplete() {
if( annualPlan==null ){
annualPlan = new AnnualPlan();
}
//查询数据
List<AnnualPlan> annualPlanlyList = this.annualPlanService.getListPage(null, annualPlan, getCurrentUser().getOrgan(),null,false, null);
//构建数据
Results results = new Results();//数据集对象
String dataSelector = getHeader("data-selector");
//遍历数据
for (AnnualPlan ap : annualPlanlyList) {
Result result = new Result(ap.getAnnualPlanTitle(), ap.getAnnualPlanId());
if (LangUtils.isNotEmpty(dataSelector)) {
Collection<String> selector = ContextUtils.getDefaultContext().getBean(dataSelector);
for (String sn : selector) {
result.addData(sn, BeanUtils.getProperty(ap, sn));
}
}
results.addResult(result);
}
setResultData(results);
return AUTOCOMPLETE;
}
/**
* 页面
* @return
*/
public String singelSelect() {
if( annualPlan==null ){
annualPlan = new AnnualPlan();
}
//secrecyPersonQo.setOrgan(getCurrentUser().getOrgan());
//secrecyPersonQo.setSecrecySatusOfDecryption(SECRECY_STATUS_DECRYPTION);
PageSortModel<AnnualPlan> psm = new PageSortModel<AnnualPlan>(getRequest(), "dataList");
List<AnnualPlan> annualPlanList = this.annualPlanService.getListPage(psm, annualPlan, getCurrentUser().getOrgan(),null,false, null);
this.putToRequest("dataList", annualPlanList);
return SUCCESS;
}
/**
* @return the annualPlanService
*/
public AnnualPlanService getAnnualPlanService() {
return annualPlanService;
}
/**
* @param annualPlanService the annualPlanService to set
*/
public void setAnnualPlanService(AnnualPlanService annualPlanService) {
this.annualPlanService = annualPlanService;
}
/**
* @return the annualPlan
*/
public AnnualPlan getAnnualPlan() {
return annualPlan;
}
/**
* @param annualPlan the annualPlan to set
*/
public void setAnnualPlan(AnnualPlan annualPlan) {
this.annualPlan = annualPlan;
}
}
| [
"394633608@qq.com"
] | 394633608@qq.com |
88a37f77d831ae7096d72eca542ed295a36724fb | eacfbe32241f523797a321af38ae0347bfe11c3e | /src/main/java/UploaderSimple.java | 7031c291d1bc5dfd8123fd1ceb18dc0c2d667262 | [] | no_license | viktorburka/jellyfish | 9e4b6b5256e9d92a0db85ca381f24a8512694cdf | d3c4297bf43b8db02cc050b2af4c1cbc36cab702 | refs/heads/master | 2020-04-05T08:33:22.255301 | 2018-11-08T14:12:13 | 2018-11-08T14:12:13 | 156,717,335 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 490 | java | import java.io.InputStream;
import java.util.HashMap;
import java.util.Map;
public class UploaderSimple implements Uploader {
public void upload(String url, Map<String,String> options, Sender snd, InputStream input) throws Exception {
try {
snd.openConnection(url, options);
snd.writePart(input, new HashMap<>());
snd.closeConnection();
} catch (Sender.SenderOperationError e) {
throw new Exception(e);
}
}
}
| [
"viktor.burka@turner.com"
] | viktor.burka@turner.com |
659638458fe92321b4aab478eb8e528cdb9b6862 | aaab0e0f158346b7d6051f0759e26a3ea814a7bd | /src/com/meizhuo/etips/activities/SchoolNewsMainActivity.java | 4fa78a27a6930b7a83d5e7da9486b5200c32d7b0 | [
"MIT"
] | permissive | ade951/ETips | ab09642afe0f47677777e9c13ecf5e260aba1b84 | cc4bbb8c5a0255ca83637c83bf1660cfe821c20f | refs/heads/master | 2021-01-21T03:14:12.465313 | 2014-01-11T07:20:42 | 2014-01-11T07:20:42 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 7,681 | java | package com.meizhuo.etips.activities;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
import org.apache.http.client.ClientProtocolException;
import android.content.Intent;
import android.os.Bundle;
import android.os.Handler;
import android.os.Message;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.AdapterView;
import android.widget.AdapterView.OnItemClickListener;
import android.widget.BaseAdapter;
import android.widget.Button;
import android.widget.ListView;
import android.widget.TextView;
import android.widget.Toast;
import com.meizhuo.etips.common.utils.ETipsContants;
import com.meizhuo.etips.common.utils.FileUtils;
import com.meizhuo.etips.model.SchoolNewList;
import com.meizhuo.etips.model.SchoolNews;
import com.meizhuo.etips.net.utils.WYUNewsAPI;
import com.meizhuo.etips.ui.WaittingDialog;
public class SchoolNewsMainActivity extends BaseUIActivity {
private int page = 1, totalPage = -1;
private Button backBtn, nextBtn, prevBtn;
private TextView tv_pageInfo;
private ListView lv;
private List<SchoolNews> list;
private WYUNewsAPI api;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.acty_schoolnews_main);
initData();
initLayout();
onWork();
}
private void onWork() {
SNMHandler handler = new SNMHandler();
new SNMThread(handler).start();
}
@Override
protected void initLayout() {
backBtn = (Button) this.findViewById(R.id.acty_schoolnews_main_back);
nextBtn = (Button) this.findViewById(R.id.acty_schoolnews_main_next);
prevBtn = (Button) this.findViewById(R.id.acty_schoolnews_main_prev);
tv_pageInfo = (TextView) this
.findViewById(R.id.acty_schoolnews_main_page);
lv = (ListView) this.findViewById(R.id.acty_schoolnews_main_listview);
final Handler h = new Handler() {
public void handleMessage(Message msg) {
if (totalPage == -1 && (List<SchoolNews>) msg.obj != null) {
list = (List<SchoolNews>) msg.obj;
lv.setAdapter(new SNAdapter());
}
}
};
new LoadFileThread(h).start();
lv.setOnItemClickListener(new OnItemClickListener() {
@Override
public void onItemClick(AdapterView<?> parent, View view,
int position, long id) {
Intent intent = new Intent(SchoolNewsMainActivity.this,
SchoolNewsDetailActivity.class);
intent.putExtra("linkPath", list.get(position).linkPath);
intent.putExtra("position", position);
intent.putExtra("title", list.get(position).title);
intent.putExtra("content", list.get(position).content);
startActivityForResult(intent,
ETipsContants.RequestCode_SchoolNewMain2Detail);
}
});
backBtn.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
SchoolNewsMainActivity.this.finish();
}
});
nextBtn.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
if (totalPage != -1)
page++; // 第一次进入的时候cancle了dialog
onWork();
}
});
prevBtn.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
if (totalPage == -1) {
onWork();
} else {
if (page - 1 >= 1) {
page--;
onWork();
} else {
Toast.makeText(SchoolNewsMainActivity.this,
"囧~已经是首页了!", Toast.LENGTH_SHORT).show();
}
}
}
});
}
@Override
protected void initData() {
}
@Override
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
super.onActivityResult(requestCode, resultCode, data);
if (requestCode == ETipsContants.RequestCode_SchoolNewMain2Detail
&& resultCode == RESULT_OK) {
int position = data.getIntExtra("position", 0);
list.get(position).content = data.getStringExtra("content");
}
}
class SNAdapter extends BaseAdapter {
@Override
public int getCount() {
return list.size();
}
@Override
public Object getItem(int position) {
return list.get(position);
}
@Override
public long getItemId(int position) {
return position;
}
@Override
public View getView(int position, View convertView, ViewGroup parent) {
SNViewHolder h = null;
if (convertView == null) {
h = new SNViewHolder();
convertView = LayoutInflater.from(SchoolNewsMainActivity.this)
.inflate(R.layout.item_schoolnew_main_listview, null);
h.tv_from = (TextView) convertView
.findViewById(R.id.item_schoolnew_main_listview_from);
h.tv_time = (TextView) convertView
.findViewById(R.id.item_schoolnew_main_listview_time);
h.tv_title = (TextView) convertView
.findViewById(R.id.item_schoolnew_main_listview_title);
convertView.setTag(h);
} else {
h = (SNViewHolder) convertView.getTag();
}
SchoolNews sn = list.get(position);
h.tv_from.setText(sn.from);
h.tv_time.setText(sn.time);
h.tv_title.setText(sn.title);
return convertView;
}
class SNViewHolder {
TextView tv_title, tv_time, tv_from;
}
}
class SNMHandler extends Handler {
WaittingDialog dialog;
@Override
public void handleMessage(Message msg) {
switch (msg.what) {
case ETipsContants.Start:
dialog = new WaittingDialog(SchoolNewsMainActivity.this);
dialog.show();
break;
case ETipsContants.Logining:
break;
case ETipsContants.Downloading:
if (!dialog.isShowing()) {
dialog = null;
break;
}
dialog.setText("ETips获取数据中...");
break;
case ETipsContants.Finish:
if (!dialog.isShowing()) {
dialog = null;
break;
}
// 保存首页
if (totalPage == -1 && page == 1 && list != null) {
new Thread(new Runnable() {
@Override
public void run() {
FileUtils.saveObject(SchoolNewsMainActivity.this,
SchoolNewList.getInstance(list),
ETipsContants.File_NewsCache);
}
}).start();
}
totalPage = msg.arg1;
tv_pageInfo.setText("第" + page + "/" + totalPage + "页");
// update UI;
lv.setAdapter(new SNAdapter());
dialog.dismiss();
dialog = null;
break;
case ETipsContants.Fail:
if (!dialog.isShowing()) {
dialog = null;
break;
}
Toast.makeText(SchoolNewsMainActivity.this, (String) msg.obj,
Toast.LENGTH_SHORT).show();
dialog.dismiss();
dialog = null;
break;
}
}
}
class SNMThread extends Thread {
Handler handler;
public SNMThread(Handler h) {
this.handler = h;
}
@Override
public void run() {
handler.sendEmptyMessage(ETipsContants.Start);
if (api == null)
api = new WYUNewsAPI();
Message msg = handler.obtainMessage();
try {
list = api.getSchoolNews(page);
if (list.size() > 0) {
msg.what = ETipsContants.Finish;
msg.arg1 = api.getSCtotalPage();
} else {
msg.what = ETipsContants.Fail;
msg.obj = "获取数据失败!";
}
handler.sendMessage(msg);
} catch (ClientProtocolException e) {
e.printStackTrace();
msg.what = ETipsContants.Fail;
msg.obj = "囧~网络不给力啊!";
handler.sendMessage(msg);
} catch (IOException e) {
e.printStackTrace();
msg.what = ETipsContants.Fail;
msg.obj = "囧~网络不给力啊!";
handler.sendMessage(msg);
}
}
}
class LoadFileThread extends Thread {
Handler h;
public LoadFileThread(Handler h) {
this.h = h;
}
@Override
public void run() {
Message msg = new Message() ;
msg.obj = (ArrayList<SchoolNews>) FileUtils
.readObject(SchoolNewsMainActivity.this,ETipsContants.File_NewsCache);
h.sendMessage(msg);
}
}
}
| [
"tonjayin@gmail.com"
] | tonjayin@gmail.com |
2787309074ebd0cd4c647971e4482c5e4fe4ca12 | 2c07f6e993bb08a70134d5e53b6e15e806e49a40 | /src/main/java/pageobject/settings/settingMenu/CompanyInformationPage.java | 15bb242544b45776d6ea3e08ee3939b6bf09602f | [] | no_license | sombra-nazar-bagrii/studioNinjaAutomationTest | 20d5d7dfaf2775495810821c769c293f6b890ae1 | e0b0141bf08361fcae7d53fd3908bad987eb9fa2 | refs/heads/master | 2021-09-11T19:09:29.618932 | 2018-04-11T07:32:31 | 2018-04-11T07:32:31 | 103,650,164 | 0 | 0 | null | 2018-03-02T10:06:31 | 2017-09-15T11:36:17 | Java | UTF-8 | Java | false | false | 304 | java | package pageobject.settings.settingMenu;
import ComfigurationClasses.Page;
import org.openqa.selenium.WebDriver;
/**
* Created by sombramac-19 on 3/28/18.
*/
public class CompanyInformationPage extends Page {
public CompanyInformationPage(WebDriver webDriver) {
super(webDriver);
}
}
| [
"vitaliy.romaniv@sombrainc.com"
] | vitaliy.romaniv@sombrainc.com |
b16f0f8e724df3ead2931cc945d102b7a6dcf2f8 | 8d1142c34f7ef5cb63c5e3115f4b58e19c036b51 | /dump-code/panelpower/org.acra.util.ReportUtils.java | c871e388d0546e0af40aaf9e93faf1c63abadb9e | [] | no_license | kingking888/android-auto-hack | b19c979f2c39a3584ba5841c7b13b253cfc798c8 | e91cb827c7ebf53ad253f965df55bfcaa9e82c32 | refs/heads/master | 2021-01-26T11:09:51.958052 | 2020-02-27T02:59:49 | 2020-02-27T02:59:49 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 3,547 | java | package org.acra.util;
import android.content.Context;
import android.os.Environment;
import android.os.StatFs;
import android.telephony.TelephonyManager;
import android.util.Log;
import android.util.SparseArray;
import java.io.File;
import java.net.InetAddress;
import java.net.NetworkInterface;
import java.net.SocketException;
import java.util.Enumeration;
import org.acra.ACRA;
public final class ReportUtils {
public static long getAvailableInternalMemorySize() {
StatFs statFs = new StatFs(Environment.getDataDirectory().getPath());
return ((long) statFs.getAvailableBlocks()) * ((long) statFs.getBlockSize());
}
public static long getTotalInternalMemorySize() {
StatFs statFs = new StatFs(Environment.getDataDirectory().getPath());
return ((long) statFs.getBlockCount()) * ((long) statFs.getBlockSize());
}
public static String getDeviceId(Context context) {
try {
return ((TelephonyManager) context.getSystemService("phone")).getDeviceId();
} catch (RuntimeException e) {
String str = ACRA.LOG_TAG;
StringBuilder sb = new StringBuilder();
sb.append("Couldn't retrieve DeviceId for : ");
sb.append(context.getPackageName());
Log.w(str, sb.toString(), e);
return null;
}
}
public static String getApplicationFilePath(Context context) {
File filesDir = context.getFilesDir();
if (filesDir != null) {
return filesDir.getAbsolutePath();
}
String str = ACRA.LOG_TAG;
StringBuilder sb = new StringBuilder();
sb.append("Couldn't retrieve ApplicationFilePath for : ");
sb.append(context.getPackageName());
Log.w(str, sb.toString());
return "Couldn't retrieve ApplicationFilePath";
}
public static String sparseArrayToString(SparseArray<?> sparseArray) {
StringBuilder sb = new StringBuilder();
if (sparseArray == null) {
return "null";
}
sb.append('{');
for (int i = 0; i < sparseArray.size(); i++) {
sb.append(sparseArray.keyAt(i));
sb.append(" => ");
if (sparseArray.valueAt(i) == null) {
sb.append("null");
} else {
sb.append(sparseArray.valueAt(i).toString());
}
if (i < sparseArray.size() - 1) {
sb.append(", ");
}
}
sb.append('}');
return sb.toString();
}
public static String getLocalIpAddress() {
StringBuilder sb = new StringBuilder();
try {
Enumeration<NetworkInterface> networkInterfaces = NetworkInterface.getNetworkInterfaces();
boolean z = true;
while (networkInterfaces.hasMoreElements()) {
Enumeration<InetAddress> inetAddresses = networkInterfaces.nextElement().getInetAddresses();
while (inetAddresses.hasMoreElements()) {
InetAddress nextElement = inetAddresses.nextElement();
if (!nextElement.isLoopbackAddress()) {
if (!z) {
sb.append(10);
}
sb.append(nextElement.getHostAddress().toString());
z = false;
}
}
}
} catch (SocketException e) {
ACRA.log.w(ACRA.LOG_TAG, e.toString());
}
return sb.toString();
}
} | [
"rjsdid7325@naver.com"
] | rjsdid7325@naver.com |
3f02f50da7750ec7a28dc4cc92b5791716bc65b3 | fb90db098088bba368c62f3de0b86d4be157b36d | /core_java/twitter/src/test/java/ca/jrvs/apps/twitter/service/TwitterServiceIntTest.java | f92aaa9966fa6c30cda37a9334f625ad8eca053a | [] | no_license | jarviscanada/jarvis_data_eng_ShadabShaikh | 725b08e93a46245ac13050842557980979b1c34f | dde639564317367069a30d893b043d289cce27bd | refs/heads/master | 2023-06-05T17:15:53.107958 | 2021-06-24T16:48:50 | 2021-06-24T16:48:50 | 341,384,472 | 0 | 0 | null | 2021-07-02T02:14:58 | 2021-02-23T01:01:17 | Jupyter Notebook | UTF-8 | Java | false | false | 2,999 | java | package ca.jrvs.apps.twitter.service;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
import ca.jrvs.apps.twitter.TwitterHttpHelper;
import ca.jrvs.apps.twitter.dao.CrdDao;
import ca.jrvs.apps.twitter.dao.TwitterDao;
import ca.jrvs.apps.twitter.dao.helper.HttpHelper;
import ca.jrvs.apps.twitter.model.Tweet;
import ca.jrvs.apps.twitter.util.TweetBuilder;
import java.util.List;
import org.junit.Before;
import org.junit.Test;
public class TwitterServiceIntTest {
Service service;
private TwitterDao dao;
@Before
public void setUp() throws Exception {
String consumerKey = System.getenv("consumerKey");
String consumerSecret = System.getenv("consumerSecret");
String accessToken = System.getenv("accessToken");
String tokenSecret = System.getenv("tokenSecret");
System.out.println(consumerKey + "|" + consumerSecret + "|" + accessToken + "|" + tokenSecret);
//set up dependency
HttpHelper httpHelper = new TwitterHttpHelper(consumerKey, consumerSecret, accessToken,
tokenSecret);
//pass dependency
CrdDao dao = new TwitterDao(httpHelper);
this.service = new TwitterService(dao);
}
@Test
public void postTweet() {
String hashTag = "#hash";
String lorem = "Lorem ipsum dolor sit amet, consectetur adipiscing elit,";
String text = lorem + hashTag + " " + System.currentTimeMillis();
//Test text length over 140 chars
String text2 =
lorem + lorem + lorem + lorem + lorem + hashTag + " " + System.currentTimeMillis();
Float longt = -19f;
Float lat = 72f;
Tweet postTweet = new Tweet();
postTweet = TweetBuilder.buildTweet(text, longt, lat);
Tweet tweet = service.postTweet(postTweet);
assertEquals(text, tweet.getText());
assertNotNull(tweet.getCoordinates());
assertEquals(longt, tweet.getCoordinates().getCoordinates()[0], 0.01);
assertEquals(lat, tweet.getCoordinates().getCoordinates()[1], 0.01);
assertEquals("hash", tweet.getEntities().getHashtags()[0].getText());
}
@Test
public void showTweet() {
String id_str = "1378124119712096258";
Tweet findTweet = service.showTweet(id_str, null);
System.out.println(findTweet.toString());
assertNotNull(findTweet);
assertEquals(id_str, findTweet.getId_str());
assertEquals("Person", findTweet.getEntities().getUser_mentions()[0].getName());
assertEquals(1f, findTweet.getCoordinates().getCoordinates()[1], 0.01);
}
@Test
public void deleteTweets() {
final int delNum = 2;
String[] deleteID = {"1378185319594524675", "1378187944083722244"};
List<Tweet> deletedTweets = service.deleteTweets(deleteID);
for (int i = 0; i < delNum; i++) {
Tweet thisTweet = deletedTweets.get(i);
assertEquals(deleteID[i], thisTweet.getId_str());
assertEquals(1f, thisTweet.getCoordinates().getCoordinates()[1], 0.01);
}
}
} | [
"johndoe@example.com"
] | johndoe@example.com |
e675a553960f0146b55580a6467882f36313cd1d | 791ddf4cbc563f533e7d00a9259e24fe85008877 | /kernel/src/main/java/org/jboss/kernel/spi/validation/KernelBeanValidator.java | 7edc9f61cdb4fa51532267502d7b629c51ef5371 | [] | no_license | wolfc/microcontainer | 7dd1fe85057c31575458ad1a22c3f74534f72bd0 | 4ef8127e690e18f54f40287b72f68dbf3541b07c | refs/heads/master | 2020-04-25T23:27:30.830476 | 2013-01-09T14:15:50 | 2013-01-09T14:15:50 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,980 | java | /*
* JBoss, Home of Professional Open Source.
* Copyright 2008, Red Hat Middleware LLC, and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1 of
* the License, or (at your option) any later version.
*
* This software is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this software; if not, write to the Free
* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
*/
package org.jboss.kernel.spi.validation;
import org.jboss.beans.info.spi.PropertyInfo;
import org.jboss.joinpoint.spi.Joinpoint;
import org.jboss.kernel.spi.KernelObject;
import org.jboss.kernel.spi.dependency.KernelControllerContext;
import org.jboss.reflect.spi.MethodInfo;
/**
* The bridge between jsr303 and our pojo handling.
*
* @author <a href="mailto:ales.justin@jboss.org">Ales Justin</a>
*/
public interface KernelBeanValidator extends KernelObject
{
/**
* Is the validator disabled.
*
* @return is the validator disabled
*/
boolean isDisabled();
/**
* Validate constructor values.
*
* @param context the owner context
* @param joinpoint the constructor joinpoint
* @throws Throwable for any error
*/
void validateConstructorValues(KernelControllerContext context, Joinpoint joinpoint) throws Throwable;
/**
* Validate new instance.
*
* @param context the owner context
* @param target the target
* @throws Throwable for any error
*/
void validateInstance(KernelControllerContext context, Object target) throws Throwable;
/**
* Validate property value.
*
* @param context the owner context
* @param target the target
* @param propertyInfo the property
* @param value the new value
* @throws Throwable for any error
*/
void validatePropertyValue(KernelControllerContext context, Object target, PropertyInfo propertyInfo, Object value) throws Throwable;
/**
* Validate method values.
*
* @param context the owner context
* @param target the target
* @param methodInfo the method
* @param parameters the parameters
* @throws Throwable for any error
*/
void validateMethodValues(KernelControllerContext context, Object target, MethodInfo methodInfo, Object[] parameters) throws Throwable;
}
| [
"ajustin@redhat.com"
] | ajustin@redhat.com |
01d124d62ffac0fb3579a8b0a7161e0d8cea635c | 3b275bbdd6fce1b469312fa23a0d84cc92360578 | /src/Numberofbriquettes/Main.java | 352c86f6b4a45c4c52ea40fbf0f147721efd3b07 | [] | no_license | hedeqing/lanqiaobei | 7821d459c0e12658520f1b85eed693b386e27d9f | 247b32e3b64ee1473a221120c6c03e610836c79d | refs/heads/master | 2020-04-03T15:49:38.900356 | 2019-03-23T13:15:32 | 2019-03-23T13:15:32 | 155,379,279 | 6 | 0 | null | null | null | null | UTF-8 | Java | false | false | 259 | java | package Numberofbriquettes;
public class Main {
public static void main(String[] args) {
int sum =0;
int n = 0;
for(int i = 1;i<=100;i++){
n+=i;
sum+=n;
}
System.out.println(sum);
}
}
| [
"240484406@qq.com"
] | 240484406@qq.com |
807ce773484ef58107143ad6c1aa55b8067a1e9d | 8968d8ab5109dcb45600a8cc2db3444912269c1b | /src/com/example/slava/people/instances/Pianist.java | fe98c94f765fcd677796584a383c9f5cce418b69 | [] | no_license | bapm91/ArtistOOP | c8c90309221b0491be6c6b256bc28a1dbdf6e98f | b3d70e42fb0bced4b8fdc1216b349aa02fe623bb | refs/heads/master | 2021-07-10T10:51:52.513908 | 2017-10-05T17:14:39 | 2017-10-05T17:14:39 | 104,936,934 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 521 | java | package com.example.slava.people.instances;
import com.example.slava.interfaces.Skill;
import com.example.slava.people.Artist;
import com.example.slava.interfaces.Musician;
public class Pianist extends Artist implements Musician {
public Pianist(int age, String name, String pseudonym) {
super(age, name, pseudonym);
}
@Override
public String skillToString() {
return "играет на пианино";
}
@Override
public Skill getSkill() {
return this;
}
}
| [
"kulynych.v.a@init.dp.ua"
] | kulynych.v.a@init.dp.ua |
90f5a1724cda102550ab90e7a6b16cd5a33df32d | 5a63ebf280592a476765f30b7c638bb91f57abcf | /src/reflectAndClass/reflectMethod.java | 7b399fc5454b19a814f35185088bfeaf6452c7d1 | [] | no_license | Nigtunt/javaPractice | d87c496dee385d9c65f40f99576f9d902de9971c | a197ae27b2d406a40c6cb49e21e56519557fedd8 | refs/heads/master | 2022-09-20T15:51:59.251031 | 2020-06-02T06:02:25 | 2020-06-02T06:02:25 | 212,738,345 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 3,724 | java | package reflectAndClass;
import java.lang.reflect.Method;
class example3 {
int kkk;
static void staticMethod(){
System.out.println("执行staticMethod()方法");
}
public int publicMethod(int i) {
System.out.println("执行publicMethod()方法");
return i * 100;
}
protected int protectedMethod(String s, int i)
throws NumberFormatException {
System.out.println("执行protectedMethod()方法");
return Integer.valueOf(s) + i;
}
private String privateMethod(String... strings) {
System.out.println("执行privateMethod()方法");
StringBuffer stringBuffer = new StringBuffer();
for (int i = 0; i < strings.length; i++) {
stringBuffer.append(strings[i]);
}
return stringBuffer.toString();
}
}
public class reflectMethod {
public static void main(String[] args) {
example3 example = new example3();
Class exampleC = example.getClass();
// 获得所有方法
Method[] declaredMethods = exampleC.getDeclaredMethods();
for (int i = 0; i < declaredMethods.length; i++) {
Method method = declaredMethods[i]; // 遍历方法
System.out.println("名称为:" + method.getName()); // 获得方法名称
System.out.println("是否允许带有可变数量的参数:" + method.isVarArgs());
System.out.println("入口参数类型依次为:");
// 获得所有参数类型
Class[] parameterTypes = method.getParameterTypes();
for (int j = 0; j < parameterTypes.length; j++) {
System.out.println(" " + parameterTypes[j]);
}
// 获得方法返回值类型
System.out.println("返回值类型为:" + method.getReturnType());
System.out.println("可能抛出的异常类型有:");
// 获得方法可能抛出的所有异常类型
Class[] exceptionTypes = method.getExceptionTypes();
for (int j = 0; j < exceptionTypes.length; j++) {
System.out.println(" " + exceptionTypes[j]);
}
boolean isTurn = true;
while (isTurn) {
// 如果该方法的访问权限为private,则抛出异常,即不允许访问
try {
isTurn = false;
if("staticMethod".equals(method.getName()))
method.invoke(example); // 执行没有入口参数的方法
else if("publicMethod".equals(method.getName()))
System.out.println("返回值为:"
+ method.invoke(example, 168)); // 执行方法
else if("protectedMethod".equals(method.getName()))
System.out.println("返回值为:"
+ method.invoke(example, "7", 5)); // 执行方法
else if("privateMethod".equals(method.getName())) {
Object[] parameters = new Object[] { new String[] {
"M", "W", "Q" } }; // 定义二维数组
System.out.println("返回值为:"
+ method.invoke(example, parameters));
}
} catch (Exception e) {
System.out.println("在执行方法时抛出异常,"
+ "下面执行setAccessible()方法!");
method.setAccessible(true); // 设置为允许访问
isTurn = true;
}
}
System.out.println();
}
}
}
| [
"915540781@qq.com"
] | 915540781@qq.com |
410cb4e5ff630501b106898714e2f4d9df1eee85 | 43b0e6159b90fc9fc79d921e0be62932638a57e6 | /src/xtrememp/player/audio/AudioPlayer.java | b12ecc04da4e8ecf235e67c56cbfe1781ce4dca2 | [
"BSD-3-Clause"
] | permissive | HelgeStenstrom/XtremeMediaPlayer | 8031d8f0e7bb1aa125fae01d6fa189f2afa2cd93 | 73fe33598dae59e04dac68610d84851490d5b4a4 | refs/heads/master | 2020-07-26T21:26:43.113372 | 2019-09-16T08:33:24 | 2019-09-16T08:33:24 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 29,160 | java | /**
* Xtreme Media Player a cross-platform media player.
* Copyright (C) 2005-2011 Besmir Beqiri
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
package xtrememp.player.audio;
import java.io.File;
import java.io.IOException;
import java.net.URL;
import java.nio.ByteBuffer;
import java.nio.ByteOrder;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Set;
import java.util.concurrent.Callable;
import java.util.concurrent.ExecutionException;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.concurrent.Future;
import java.util.concurrent.locks.Condition;
import java.util.concurrent.locks.Lock;
import java.util.concurrent.locks.ReentrantLock;
import javax.sound.sampled.AudioFileFormat;
import javax.sound.sampled.AudioFormat;
import javax.sound.sampled.AudioInputStream;
import javax.sound.sampled.AudioSystem;
import javax.sound.sampled.BooleanControl;
import javax.sound.sampled.Control;
import javax.sound.sampled.DataLine;
import javax.sound.sampled.FloatControl;
import javax.sound.sampled.Line;
import javax.sound.sampled.LineUnavailableException;
import javax.sound.sampled.Mixer;
import javax.sound.sampled.SourceDataLine;
import javax.sound.sampled.UnsupportedAudioFileException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.tritonus.share.sampled.TAudioFormat;
import org.tritonus.share.sampled.file.TAudioFileFormat;
import javazoom.spi.PropertiesContainer;
import xtrememp.player.dsp.DigitalSignalSynchronizer;
/**
*
* @author Besmir Beqiri
*/
public class AudioPlayer implements Callable<Void> {
private final Logger logger = LoggerFactory.getLogger(AudioPlayer.class);
protected final int READ_BUFFER_SIZE = 4 * 1024;
protected final Lock lock = new ReentrantLock();
protected final Condition pauseCondition = lock.newCondition();
protected Object audioSource;
protected DigitalSignalSynchronizer dss;
protected AudioFileFormat audioFileFormat;
protected AudioInputStream audioInputStream;
protected SourceDataLine sourceDataLine;
protected String mixerName;
protected List<PlaybackListener> listeners;
protected ExecutorService execService;
protected Future<Void> future;
protected Map<String, Object> properties;
protected FloatControl gainControl;
protected FloatControl panControl;
protected BooleanControl muteControl;
protected int bufferSize = AudioSystem.NOT_SPECIFIED;
public static final int INIT = 0;
public static final int PLAY = 1;
public static final int PAUSE = 2;
public static final int SEEK = 3;
public static final int STOP = 4;
protected volatile int state = AudioSystem.NOT_SPECIFIED;
protected Map<String, Object> emptyMap = new HashMap<String, Object>();
protected long oldPosition = 0;
public AudioPlayer() {
execService = Executors.newFixedThreadPool(1);
dss = new DigitalSignalSynchronizer();
listeners = new ArrayList<PlaybackListener>();
reset();
}
public void addPlaybackListener(PlaybackListener listener) {
if (listener != null && !listeners.contains(listener)) {
listeners.add(listener);
}
}
public void removePlaybackListener(PlaybackListener listener) {
if (listener != null) {
listeners.remove(listener);
}
}
public List<PlaybackListener> getPlaybackListeners() {
return listeners;
}
protected void notifyEvent(Playback state) {
notifyEvent(state, emptyMap);
}
protected void notifyEvent(Playback state, Map properties) {
for (PlaybackListener listener : listeners) {
PlaybackEventLauncher launcher = new PlaybackEventLauncher(this,
state, getPosition() - oldPosition, properties, listener);
launcher.start();
}
logger.info("{}", state);
}
private void reset() {
if (sourceDataLine != null) {
sourceDataLine.flush();
sourceDataLine.close();
sourceDataLine = null;
}
audioFileFormat = null;
gainControl = null;
panControl = null;
muteControl = null;
future = null;
emptyMap.clear();
oldPosition = 0;
}
/**
* Open file to play.
* @param file
* @throws PlayerException
*/
public void open(File file) throws PlayerException {
if (file != null) {
audioSource = file;
init();
}
}
/**
* Open URL to play.
* @param url
* @throws PlayerException
*/
public void open(URL url) throws PlayerException {
if (url != null) {
audioSource = url;
init();
}
}
protected void init() throws PlayerException {
notifyEvent(Playback.BUFFERING);
int oldState = state;
state = AudioSystem.NOT_SPECIFIED;
if (oldState == INIT || oldState == PAUSE) {
lock.lock();
try {
pauseCondition.signal();
} finally {
lock.unlock();
}
}
awaitTermination();
lock.lock();
try {
reset();
initAudioInputStream();
initSourceDataLine();
} finally {
lock.unlock();
}
}
/**
* Inits AudioInputStream and AudioFileFormat from the data source.
* @throws PlayerException
*/
@SuppressWarnings("unchecked")
protected void initAudioInputStream() throws PlayerException {
// Close any previous opened audio stream before creating a new one.
closeStream();
if (audioInputStream == null) {
try {
logger.info("Data source: {}", audioSource);
if (audioSource instanceof File) {
initAudioInputStream((File) audioSource);
} else if (audioSource instanceof URL) {
initAudioInputStream((URL) audioSource);
}
AudioFormat sourceAudioFormat = audioInputStream.getFormat();
logger.info("Source format: {}", sourceAudioFormat);
int nSampleSizeInBits = sourceAudioFormat.getSampleSizeInBits();
if (nSampleSizeInBits <= 0) {
nSampleSizeInBits = 16;
}
if ((sourceAudioFormat.getEncoding() == AudioFormat.Encoding.ULAW) || (sourceAudioFormat.getEncoding() == AudioFormat.Encoding.ALAW)) {
nSampleSizeInBits = 16;
}
if (nSampleSizeInBits != 8) {
nSampleSizeInBits = 16;
}
AudioFormat targetAudioFormat = new AudioFormat(AudioFormat.Encoding.PCM_SIGNED, sourceAudioFormat.getSampleRate(), nSampleSizeInBits, sourceAudioFormat.getChannels(), sourceAudioFormat.getChannels() * (nSampleSizeInBits / 8), sourceAudioFormat.getSampleRate(), false);
logger.info("Target format: {}", targetAudioFormat);
// Create decoded stream.
audioInputStream = AudioSystem.getAudioInputStream(targetAudioFormat, audioInputStream);
if (audioFileFormat instanceof TAudioFileFormat) {
// Tritonus SPI compliant audio file format.
properties = ((TAudioFileFormat) audioFileFormat).properties();
// Clone the Map because it is not mutable.
properties = deepCopy(properties);
} else {
properties = new HashMap<String, Object>();
}
// Add JavaSound properties.
if (audioFileFormat.getByteLength() > 0) {
properties.put("audio.length.bytes", new Integer(audioFileFormat.getByteLength()));
}
if (audioFileFormat.getFrameLength() > 0) {
properties.put("audio.length.frames", new Integer(audioFileFormat.getFrameLength()));
}
if (audioFileFormat.getType() != null) {
properties.put("audio.type", audioFileFormat.getType().toString());
}
// Audio format.
AudioFormat audioFormat = audioFileFormat.getFormat();
if (audioFormat.getFrameRate() > 0) {
properties.put("audio.framerate.fps", new Float(audioFormat.getFrameRate()));
}
if (audioFormat.getFrameSize() > 0) {
properties.put("audio.framesize.bytes", new Integer(audioFormat.getFrameSize()));
}
if (audioFormat.getSampleRate() > 0) {
properties.put("audio.samplerate.hz", new Float(audioFormat.getSampleRate()));
}
if (audioFormat.getSampleSizeInBits() > 0) {
properties.put("audio.samplesize.bits", new Integer(audioFormat.getSampleSizeInBits()));
}
if (audioFormat.getChannels() > 0) {
properties.put("audio.channels", new Integer(audioFormat.getChannels()));
}
if (audioFormat instanceof TAudioFormat) {
// Tritonus SPI compliant audio format.
properties.putAll(((TAudioFormat) audioFormat).properties());
}
for (String key : properties.keySet()) {
logger.info("Audio Format Properties: {} = {}", key, properties.get(key));
}
} catch (UnsupportedAudioFileException ex) {
throw new PlayerException(ex);
} catch (IOException ex) {
throw new PlayerException(ex);
}
}
}
/**
* Inits Audio resources from file.
* @param file
* @throws javax.sound.sampled.UnsupportedAudioFileException
* @throws java.io.IOException
*/
protected void initAudioInputStream(File file) throws UnsupportedAudioFileException, IOException {
audioInputStream = AudioSystem.getAudioInputStream(file);
audioFileFormat = AudioSystem.getAudioFileFormat(file);
}
/**
* Inits Audio resources from URL.
* @param url
* @throws javax.sound.sampled.UnsupportedAudioFileException
* @throws java.io.IOException
*/
protected void initAudioInputStream(URL url) throws UnsupportedAudioFileException, IOException {
audioInputStream = AudioSystem.getAudioInputStream(url);
audioFileFormat = AudioSystem.getAudioFileFormat(url);
}
/**
* Inits Audio resources from AudioSystem.
* @throws PlayerException
*/
protected void initSourceDataLine() throws PlayerException {
if (sourceDataLine == null) {
try {
logger.info("Create Source Data Line");
AudioFormat audioFormat = audioInputStream.getFormat();
DataLine.Info lineInfo = new DataLine.Info(SourceDataLine.class, audioFormat, AudioSystem.NOT_SPECIFIED);
if (!AudioSystem.isLineSupported(lineInfo)) {
throw new PlayerException(lineInfo + " is not supported");
}
if (mixerName == null) {
// Primary Sound Driver
mixerName = getMixers().get(0);
}
Mixer mixer = getMixer(mixerName);
if (mixer != null) {
logger.info("Mixer: {}", mixer.getMixerInfo().toString());
sourceDataLine = (SourceDataLine) mixer.getLine(lineInfo);
} else {
sourceDataLine = (SourceDataLine) AudioSystem.getLine(lineInfo);
mixerName = null;
}
sourceDataLine.addLineListener(dss);
logger.info("Line Info: {}", sourceDataLine.getLineInfo().toString());
logger.info("Line AudioFormat: {}", sourceDataLine.getFormat().toString());
if (bufferSize <= 0) {
bufferSize = sourceDataLine.getBufferSize();
}
sourceDataLine.open(audioFormat, bufferSize);
logger.info("Line BufferSize: {}", sourceDataLine.getBufferSize());
for (Control c : sourceDataLine.getControls()) {
logger.info("Line Controls: {}", c);
}
if (sourceDataLine.isControlSupported(FloatControl.Type.MASTER_GAIN)) {
gainControl = (FloatControl) sourceDataLine.getControl(FloatControl.Type.MASTER_GAIN);
}
if (sourceDataLine.isControlSupported(FloatControl.Type.PAN)) {
panControl = (FloatControl) sourceDataLine.getControl(FloatControl.Type.PAN);
}
if (sourceDataLine.isControlSupported(BooleanControl.Type.MUTE)) {
muteControl = (BooleanControl) sourceDataLine.getControl(BooleanControl.Type.MUTE);
}
sourceDataLine.start();
state = INIT;
future = execService.submit(this);
notifyEvent(Playback.OPENED);
} catch (LineUnavailableException ex) {
throw new PlayerException(ex);
}
}
}
/**
* Set SourceDataLine buffer size. It affects audio latency
* (the delay between SourceDataLine.write(data) and real sound).
* @param bufferSize if equal to -1 (AudioSystem.NOT_SPECIFIED)
* means maximum buffer size available.
*/
public void setBufferSize(int bufferSize) {
if (bufferSize <= 0) {
this.bufferSize = AudioSystem.NOT_SPECIFIED;
} else {
this.bufferSize = bufferSize;
}
}
/**
* Return SourceDataLine buffer size.
* @return -1 (AudioSystem.NOT_SPECIFIED) for maximum buffer size.
*/
public int getBufferSize() {
return bufferSize;
}
/**
* Deep copy of a Map.
* @param src
* @return map
*/
protected Map<String, Object> deepCopy(Map<String, Object> src) {
Map<String, Object> map = new HashMap<String, Object>();
if (src != null) {
Set<String> keySet = src.keySet();
for (String key : keySet) {
Object value = src.get(key);
map.put(key, value);
// logger.info("key: {}, value: {}", key, value);
}
}
return map;
}
public List<String> getMixers() {
List<String> mixers = new ArrayList<String>();
Mixer.Info[] mixerInfos = AudioSystem.getMixerInfo();
if (mixerInfos != null) {
for (int i = 0, len = mixerInfos.length; i < len; i++) {
Line.Info lineInfo = new Line.Info(SourceDataLine.class);
Mixer _mixer = AudioSystem.getMixer(mixerInfos[i]);
if (_mixer.isLineSupported(lineInfo)) {
mixers.add(mixerInfos[i].getName());
}
}
}
return mixers;
}
public Mixer getMixer(String name) {
Mixer _mixer = null;
if (name != null) {
Mixer.Info[] mixerInfos = AudioSystem.getMixerInfo();
if (mixerInfos != null) {
for (int i = 0, len = mixerInfos.length; i < len; i++) {
if (mixerInfos[i].getName().equals(name)) {
_mixer = AudioSystem.getMixer(mixerInfos[i]);
break;
}
}
}
}
return _mixer;
}
public String getMixerName() {
return mixerName;
}
public void setMixerName(String name) {
mixerName = name;
}
public long getDuration() {
long duration = AudioSystem.NOT_SPECIFIED;
if (properties.containsKey("duration")) {
duration = ((Long) properties.get("duration")).longValue();
} else {
duration = getTimeLengthEstimation(properties);
}
return duration;
}
public int getByteLength() {
int bytesLength = AudioSystem.NOT_SPECIFIED;
if (properties != null) {
if (properties.containsKey("audio.length.bytes")) {
bytesLength = ((Integer) properties.get("audio.length.bytes")).intValue();
}
}
return bytesLength;
}
public int getPositionByte() {
int positionByte = AudioSystem.NOT_SPECIFIED;
if (properties != null) {
if (properties.containsKey("mp3.position.byte")) {
positionByte = ((Integer) properties.get("mp3.position.byte")).intValue();
return positionByte;
}
if (properties.containsKey("ogg.position.byte")) {
positionByte = ((Integer) properties.get("ogg.position.byte")).intValue();
return positionByte;
}
}
return positionByte;
}
protected long getTimeLengthEstimation(Map properties) {
long milliseconds = AudioSystem.NOT_SPECIFIED;
int byteslength = AudioSystem.NOT_SPECIFIED;
if (properties != null) {
if (properties.containsKey("audio.length.bytes")) {
byteslength = ((Integer) properties.get("audio.length.bytes")).intValue();
}
if (properties.containsKey("duration")) {
milliseconds = (int) (((Long) properties.get("duration")).longValue()) / 1000;
} else {
// Try to compute duration
int bitspersample = AudioSystem.NOT_SPECIFIED;
int channels = AudioSystem.NOT_SPECIFIED;
float samplerate = AudioSystem.NOT_SPECIFIED;
int framesize = AudioSystem.NOT_SPECIFIED;
if (properties.containsKey("audio.samplesize.bits")) {
bitspersample = ((Integer) properties.get("audio.samplesize.bits")).intValue();
}
if (properties.containsKey("audio.channels")) {
channels = ((Integer) properties.get("audio.channels")).intValue();
}
if (properties.containsKey("audio.samplerate.hz")) {
samplerate = ((Float) properties.get("audio.samplerate.hz")).floatValue();
}
if (properties.containsKey("audio.framesize.bytes")) {
framesize = ((Integer) properties.get("audio.framesize.bytes")).intValue();
}
if (bitspersample > 0) {
milliseconds = (long) (1000.0f * byteslength / (samplerate * channels * (bitspersample / 8)));
} else {
milliseconds = (long) (1000.0f * byteslength / (samplerate * framesize));
}
}
}
return milliseconds * 1000;
}
/**
* Sets Gain value.
* @param gain a value bitween -1.0 and +1.0
* @throws PlayerException
*/
public void setGain(float gain) throws PlayerException {
if (gainControl != null) {
double minGain = gainControl.getMinimum();
double maxGain = gainControl.getMaximum();
double ampGain = ((10.0f / 20.0f) * maxGain) - minGain;
double cste = Math.log(10.0) / 20;
double value = minGain + (1 / cste) * Math.log(1 + (Math.exp(cste * ampGain) - 1) * gain);
gainControl.setValue((float) value);
logger.info("{}", gainControl.toString());
} else {
throw new PlayerException("Gain control not supported");
}
}
public float getGain() {
float gain = 0.0f;
if (gainControl != null) {
gain = gainControl.getValue();
}
return gain;
}
/**
* Sets Pan value.
* @param pan a value bitween -1.0 and +1.0
* @throws PlayerException
*/
public void setPan(float pan) throws PlayerException {
if (panControl != null) {
panControl.setValue(pan);
logger.info("{}", panControl.toString());
} else {
throw new PlayerException("Pan control not supported");
}
}
public float getPan() {
float pan = 0.0f;
if (panControl != null) {
pan = panControl.getValue();
}
return pan;
}
/**
* Sets Mute value.
* @param mute a boolean value
* @throws PlayerException
*/
public void setMuted(boolean mute) throws PlayerException {
if (muteControl != null) {
muteControl.setValue(mute);
logger.info("{}", muteControl.toString());
} else {
throw new PlayerException("Mute control not supported");
}
}
public boolean isMuted() {
boolean muted = false;
if (muteControl != null) {
muted = muteControl.getValue();
}
return muted;
}
public long getPosition() {
long pos = 0;
if (sourceDataLine != null) {
pos = sourceDataLine.getMicrosecondPosition();
}
return pos;
}
public int getState() {
return state;
}
public DigitalSignalSynchronizer getDSS() {
return dss;
}
@Override
public Void call() throws PlayerException {
logger.info("Decoding thread started");
int nBytesRead = 0;
int audioDataLength = READ_BUFFER_SIZE;
ByteBuffer audioDataBuffer = ByteBuffer.allocate(audioDataLength);
audioDataBuffer.order(ByteOrder.LITTLE_ENDIAN);
lock.lock();
try {
while ((nBytesRead != -1) && (state != STOP) && (state != SEEK) && (state != AudioSystem.NOT_SPECIFIED)) {
try {
if (state == PLAY) {
int toRead = audioDataLength;
int totalRead = 0;
while (toRead > 0 && (nBytesRead = audioInputStream.read(audioDataBuffer.array(), totalRead, toRead)) != -1) {
totalRead += nBytesRead;
toRead -= nBytesRead;
}
if (totalRead > 0) {
byte[] trimBuffer = audioDataBuffer.array();
if (totalRead < trimBuffer.length) {
trimBuffer = new byte[totalRead];
System.arraycopy(audioDataBuffer.array(), 0, trimBuffer, 0, totalRead);
}
sourceDataLine.write(trimBuffer, 0, totalRead);
dss.writeAudioData(trimBuffer, 0, totalRead);
for (PlaybackListener pl : listeners) {
PlaybackEvent pe = new PlaybackEvent(this, Playback.PLAYING, getPosition() - oldPosition, emptyMap);
if (audioInputStream instanceof PropertiesContainer) {
// Pass audio parameters such as instant bitrate, ...
pe.setProperties(((PropertiesContainer) audioInputStream).properties());
}
pl.playbackProgress(pe);
}
}
} else if (state == INIT || state == PAUSE) {
if (sourceDataLine != null && sourceDataLine.isRunning()) {
sourceDataLine.flush();
sourceDataLine.stop();
}
pauseCondition.awaitUninterruptibly();
}
} catch (IOException ex) {
logger.error("Decoder Exception: ", ex);
state = STOP;
notifyEvent(Playback.STOPPED);
throw new PlayerException(ex);
}
}
if (sourceDataLine != null) {
sourceDataLine.flush();
sourceDataLine.stop();
sourceDataLine.close();
sourceDataLine = null;
}
closeStream();
if (nBytesRead == -1) {
notifyEvent(Playback.EOM);
}
} finally {
lock.unlock();
}
logger.info("Decoding thread completed");
return null;
}
private void awaitTermination() {
if (future != null && !future.isDone()) {
try {
future.get();
} catch (InterruptedException ex) {
logger.error(ex.getMessage(), ex);
} catch (ExecutionException ex) {
logger.error(ex.getMessage(), ex);
} finally {
// Harmless if task already completed
future.cancel(true); // interrupt if running
}
}
}
public void play() throws PlayerException {
lock.lock();
try {
switch (state) {
case STOP:
initAudioInputStream();
initSourceDataLine();
default:
if (sourceDataLine != null && !sourceDataLine.isRunning()) {
sourceDataLine.start();
}
state = PLAY;
pauseCondition.signal();
notifyEvent(Playback.PLAYING);
break;
}
} finally {
lock.unlock();
}
}
public void pause() {
if (sourceDataLine != null) {
if (state == PLAY) {
state = PAUSE;
notifyEvent(Playback.PAUSED);
}
}
}
public void stop() {
if (state != STOP) {
int oldState = state;
state = STOP;
if (oldState == INIT || oldState == PAUSE) {
lock.lock();
try {
pauseCondition.signal();
} finally {
lock.unlock();
}
}
awaitTermination();
notifyEvent(Playback.STOPPED);
}
}
public long seek(long bytes) throws PlayerException {
long totalSkipped = 0;
if (audioSource instanceof File) {
int bytesLength = getByteLength();
if ((bytesLength <= 0) || (bytes >= bytesLength)) {
notifyEvent(Playback.EOM);
return totalSkipped;
}
logger.info("Bytes to skip: {}", bytes);
oldPosition = getPosition();
int oldState = state;
if (state == PLAY) {
state = PAUSE;
}
lock.lock();
try {
notifyEvent(Playback.SEEKING);
initAudioInputStream();
if (audioInputStream != null) {
// long skipped = 0;
// while (totalSkipped < bytes) {
// skipped = audioInputStream.skip(bytes - totalSkipped);
// totalSkipped += skipped;
// if (skipped == 0) {
// break;
// }
// }
totalSkipped = audioInputStream.skip(bytes);
logger.info("Skipped bytes: {}/{}", totalSkipped, bytes);
if (totalSkipped == -1) {
throw new PlayerException("Seek not supported");
}
initSourceDataLine();
}
} catch (IOException ex) {
throw new PlayerException(ex);
} finally {
lock.unlock();
}
if (oldState == PLAY) {
play();
}
}
return totalSkipped;
}
protected void closeStream() {
if (audioInputStream != null) {
try {
audioInputStream.close();
audioInputStream = null;
logger.info("Stream closed");
} catch (IOException ex) {
logger.error("Cannot close stream", ex);
}
}
}
}
| [
"Alexandros.KENTROS@intrasoft-intl.com"
] | Alexandros.KENTROS@intrasoft-intl.com |
1d64e0157d53e2bc1ab59e9cfe44ab2a8bd168c6 | 9ffdeedbb966e25ae8f46045a4cd5fd4c4fdd71a | /fupin_2_0/src/main/java/com/roch/fupin/photo/SDK16.java | 85b206d89f8b3731d12394ac37d11022b7c4021f | [] | no_license | gugj/FuPin_2_0_TongLiao | ef6bc04356924411ed937b1f357eface1f06a5ab | 6bad2ea4550fb1d4349bd2a7ad34adfa40eb3eae | refs/heads/master | 2021-01-22T21:13:10.083617 | 2017-08-18T06:25:32 | 2017-08-18T06:25:32 | 100,679,481 | 1 | 0 | null | null | null | null | UTF-8 | Java | false | false | 227 | java | package com.roch.fupin.photo;
import android.annotation.TargetApi;
import android.view.View;
@TargetApi(16)
public class SDK16 {
public static void postOnAnimation(View view, Runnable r) {
view.postOnAnimation(r);
}
}
| [
"qqdongshao123@126.com"
] | qqdongshao123@126.com |
1d12de5dd9051d5ce43b971644de40e6c39283ad | 8e32a0e053460eea4dcfd493717de05d66be8e99 | /TestingProject/src/module-info.java | 6023d712b1e3d6f53f9c84e4b896219e8e189cac | [] | no_license | CantinaBots/EclipseTesting | 6792877e2b98dd30a07bee344544a599c8009528 | 306af1a57730ab6d0653b16a01f3588b425a68ea | refs/heads/master | 2023-05-08T20:05:30.781839 | 2021-05-22T06:32:56 | 2021-05-22T06:32:56 | 369,726,899 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 25 | java | module TestingProject {
} | [
"cthaxton@cantinacapital.com"
] | cthaxton@cantinacapital.com |
3aa2bd78464380a7c18c38c639f53c15fd4b4deb | e9daeea80ddb2fa64b6ba57addf14e363b497a79 | /commonwebitems/testsrc/uk/co/portaltech/tui/populators/BookFlowAccommodationPopulatorTest.java | 0a6238a84e4b3714125bb29fe213e39519370411 | [] | no_license | gousebashashaik/16.2.0.0 | 99922b8d5bf02cde3a8bf24dc7e044852078244f | 4374ee6408d052df512a82e54621facefbf55f32 | refs/heads/master | 2021-01-10T10:51:51.288078 | 2015-09-29T09:30:14 | 2015-09-29T09:30:14 | 43,352,196 | 1 | 1 | null | null | null | null | UTF-8 | Java | false | false | 9,670 | java | package uk.co.portaltech.tui.populators;
import static org.hamcrest.CoreMatchers.notNullValue;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.is;
import de.hybris.bootstrap.annotations.IntegrationTest;
import de.hybris.platform.core.Registry;
import de.hybris.platform.servicelayer.ServicelayerTransactionalTest;
import de.hybris.platform.servicelayer.config.ConfigurationService;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import javax.annotation.Resource;
import org.apache.commons.lang.StringUtils;
import org.junit.Before;
import org.junit.Test;
import org.springframework.beans.factory.annotation.Autowired;
import uk.co.portaltech.travel.services.rules.RuleEngineUtil;
import uk.co.portaltech.tui.model.WorldCareFundModel;
import uk.co.portaltech.tui.web.view.data.BookFlowAccommodationViewData;
import uk.co.portaltech.tui.web.view.data.FlightCarrier;
import uk.co.portaltech.tui.web.view.data.RatingsData;
import uk.co.portaltech.tui.web.view.data.SearchResultAccomodationViewData;
import uk.co.portaltech.tui.web.view.data.SearchResultFlightDetailViewData;
import uk.co.portaltech.tui.web.view.data.SearchResultFlightScheduleData;
import uk.co.portaltech.tui.web.view.data.SearchResultFlightViewData;
import uk.co.portaltech.tui.web.view.data.SearchResultPriceViewData;
import uk.co.portaltech.tui.web.view.data.SearchResultRoomsData;
import uk.co.portaltech.tui.web.view.data.SearchResultRoomsPriceData;
import uk.co.portaltech.tui.web.view.data.SearchResultViewData;
import uk.co.portaltech.tui.web.view.data.SearchResultsDestinationData;
import uk.co.portaltech.tui.web.view.data.SearchResultsLocationData;
import uk.co.portaltech.tui.web.view.data.SearchResultsRequestData;
import uk.co.portaltech.tui.web.view.data.SearchResultsResortData;
@IntegrationTest
public class BookFlowAccommodationPopulatorTest extends ServicelayerTransactionalTest {
@Resource
private BookFlowAccommodationPopulator bookFlowAccommodationPopulator;
private static final int NO_OF_ADULTS=2;
private static final int NO_OF_CHILD=3;
private SearchResultViewData searchResultData;
private BookFlowAccommodationViewData viewData;
private SearchResultFlightViewData itinerary;
private SearchResultFlightDetailViewData flightDetails,flightDetails1;
private SearchResultAccomodationViewData accommodation;
private SearchResultRoomsData roomData1;
private SearchResultPriceViewData priceData;
private FlightCarrier carrier,carrier1;
private SearchResultFlightScheduleData schedule,schedule1;
private SearchResultsLocationData location;
private SearchResultsDestinationData destination;
private SearchResultsResortData resort;
private RatingsData ratings;
private SearchResultRoomsPriceData price;
private static final int ARRIVAL_DATE_TIME_IN_MILLI=123323;
private static final int DEPARTURE_DATE_TIME_IN_MILLI=1223223;
private static final int SET_COMMERCIAL_PRIORITY=4;
private static final int SELLING_OUT=2;
private SearchResultsRequestData searchParameter;
/**
* Setting all the data to source before testing.
*/
@Before
public void setUp()
{ searchParameter =new SearchResultsRequestData();
searchResultData =new SearchResultViewData();
viewData=new BookFlowAccommodationViewData();
setUpPriceData();
setUpFlightData();
setUpAccommodation();
searchResultData.setCoachTransfer(true);
searchResultData.setPackageId("06012");
searchResultData.setTracsUnitCode("123345469");
searchParameter.setNoOfAdults(NO_OF_ADULTS);
searchParameter.setChildCount(NO_OF_CHILD);
}
/**
* Setting the Accommodation data.
*/
public void setUpAccommodation() {
accommodation=new SearchResultAccomodationViewData();
accommodation.setCode("06012");
accommodation.setCommercialPriority(SET_COMMERCIAL_PRIORITY);
accommodation.setDifferentiatedCode("0012");
accommodation.setDifferentiatedProduct(false);
accommodation.setDifferentiatedType("differentiatedType");
accommodation.setImageUrl("imageUrl");
location = new SearchResultsLocationData();
destination = new SearchResultsDestinationData();
destination.setCode("123");
destination.setName("Marrakech");
resort = new SearchResultsResortData();
resort.setCode("124");
resort.setName("resort");
location.setResort(resort);
location.setDestination(destination);
accommodation.setLocation(location );
accommodation.setName("Marrakech");
ratings=new RatingsData();
ratings.setOfficialRating("4");
ratings.setTripAdvisorRating("3");
accommodation.setRatings(ratings);
roomData1=new SearchResultRoomsData();
roomData1.setAvailability(true);
roomData1.setRoomType("doubleRoom");
roomData1.setSellingout(SELLING_OUT);
roomData1.setBoardType("All Inclusive");
roomData1.setRoomCode("156");
price = new SearchResultRoomsPriceData();
price.setDiscount("20");
roomData1.setPrice(price);
List<SearchResultRoomsData> rooms= new ArrayList<SearchResultRoomsData>();
rooms.add(roomData1);
accommodation.setRooms(rooms);
accommodation.setStrapline("strapline");
accommodation.setTripAdvisorReviewCount(2);
accommodation.setUrl("url");
HashMap<String,List<Object>> featureCodesAndValues =new HashMap<String,List<Object>>();
List<Object>value= new ArrayList<Object>();
Object obj= new Object();
value.add(obj);
featureCodesAndValues.put("featureCodesAndValues", value);
accommodation.putFeatureCodesAndValues(featureCodesAndValues);
searchResultData.setAccommodation(accommodation);
}
/**
* Setting the flight data.
*/
public void setUpFlightData() {
itinerary=new SearchResultFlightViewData();
itinerary.setDepartureAirport("London Luton");
itinerary.setDepartureDate("01-03-2013");
itinerary.setFlightText("flight text");
List<SearchResultFlightDetailViewData> viewsData = new ArrayList<SearchResultFlightDetailViewData>();
flightDetails =new SearchResultFlightDetailViewData();
flightDetails.setArrivalAirport("majoraka");
carrier= new FlightCarrier();
carrier.setCode("0001");
carrier.setName("taxi");
flightDetails.setCarrier(carrier);
flightDetails.setDepartureAirport("London Luton");
flightDetails.setHaulType("SH");
viewsData.add(flightDetails);
schedule = new SearchResultFlightScheduleData();
schedule.setArrivalDate("02-03-2013");
schedule.setArrivalDateTimeInMilli(ARRIVAL_DATE_TIME_IN_MILLI);
schedule.setArrivalTime("22:20");
schedule.setDepartureDate("01-03-2013");
schedule.setDepartureDateTimeInMilli(DEPARTURE_DATE_TIME_IN_MILLI);
schedule.setDepartureTime("12:30");
schedule.setOverlapDay(true);
flightDetails.setSchedule(schedule);
itinerary.setInbounds(viewsData);
List<SearchResultFlightDetailViewData> viewsData1 = new ArrayList<SearchResultFlightDetailViewData>();
flightDetails1 =new SearchResultFlightDetailViewData();
flightDetails1.setArrivalAirport("spain");
carrier1= new FlightCarrier();
carrier1.setCode("0002");
carrier1.setName("bus");
flightDetails1.setCarrier(carrier1);
flightDetails1.setDepartureAirport("London GatWick");
flightDetails1.setHaulType("LH");
viewsData1.add(flightDetails1);
schedule1 = new SearchResultFlightScheduleData();
schedule1.setArrivalDate("02-03-2013");
schedule1.setArrivalDateTimeInMilli(ARRIVAL_DATE_TIME_IN_MILLI);
schedule1.setArrivalTime("21:20");
schedule1.setDepartureDate("01-03-2013");
schedule1.setDepartureDateTimeInMilli(DEPARTURE_DATE_TIME_IN_MILLI);
schedule1.setDepartureTime("12:10");
schedule1.setOverlapDay(false);
itinerary.setOutbounds(viewsData1);
searchResultData.setItinerary(itinerary);
}
/**
* Setting the price data.
*/
public void setUpPriceData() {
priceData= new SearchResultPriceViewData();
priceData.setDepositAmount("120");
priceData.setDiscount("20");
priceData.setPerPerson("200");
priceData.setTotalParty("1600");
priceData.setLowDeposit("100");
priceData.setLowDepositExists(true);
priceData.setPromotionalOffer("PromotionalOffer");
searchResultData.setPrice(priceData);
}
/**
* Testing the populate method.
*/
@SuppressWarnings("boxing")
@Test
public void testPopulate() {
bookFlowAccommodationPopulator.populate(searchResultData, viewData) ;
assertThat(viewData, is(notNullValue()));
assertThat(viewData.getCreditCardData(), is(notNullValue()));
assertThat(viewData.getCreditCardData().getCreditCardPercentage(), is("2.5"));
assertThat(viewData.getCreditCardData().getDeposit(), is("102.5"));
assertThat(viewData.getCreditCardData().getTotal(), is("1660.5"));
assertThat(viewData.getPackageData(), is(searchResultData));
assertThat(viewData.getSubTotal(), is("1620.0"));
assertThat(viewData.getTotal(), is("1600.0"));
assertThat(viewData.getWorldCareFunds(), is(3.5));
assertThat(viewData.getPackageInfo().get("flight"),is((Object)true));
assertThat(viewData.getPackageInfo().get("coach"),is((Object)true));
assertThat(viewData.getPackageInfo().get("board"),is((Object)"All Inclusive"));
assertThat(viewData.getPackageInfo().get("donation"),is((Object)true));
assertThat(viewData.getPackageInfo().get("baggage"),is((Object)true));
assertThat(viewData.getPackageInfo().get("protection"),is((Object)true));
}
}
| [
"gousebasha.s@sonata-software.com"
] | gousebasha.s@sonata-software.com |
90c8d2550fd71c214f3ce7a014699fef2f5d3e41 | 13371739470f2f8fb536decb9364e79acd52c816 | /PrimaryHeat.java | 00ec4215b50a001a9c5d0a58eb0932739d880cbe | [] | no_license | SrimanRao19/Smart-Home-System | 402ce5153f8b4f546a63e262cc9587c5727e0947 | 0d6beea1c876ea3d1696dd4fd8a6c2a8ab88fde6 | refs/heads/master | 2021-04-26T22:51:32.447914 | 2018-03-08T23:44:49 | 2018-03-08T23:44:49 | 124,157,106 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 805 | java | //
// This is the <<boundary>> class for PrimaryHeat
// This class acts as the device driver for the primary heating unit.
// For this assignment, the on() and off() methods are just
// stubs.
//
// Students - Do Not Modify
//
// R. Pettit - 2016
//
public class PrimaryHeat {
private static boolean isOn = false;
public void on(){
if (isOn){
System.out.println("Primary Heater was already on");
}
else{
SystemStatus.setState(SystemState.HEATING);
isOn = true;
System.out.println("Primary Heater is On");
}
}
public void off(){
if (!isOn){
System.out.println("Primary Heater was already off");
}
else{
SystemStatus.setState(SystemState.OFF);
isOn = false;
System.out.println("Primary Heater is Off");
}
}
}
| [
"noreply@github.com"
] | noreply@github.com |
a109105eda8dff2c30f3caf75ce62672e5f441cd | 5e68f09b86b2f0f57cc574d693f5161d0191ee79 | /Android_Me-TFragments.01-StartingCode/app/build/generated/not_namespaced_r_class_sources/debug/processDebugResources/r/android/support/asynclayoutinflater/R.java | 866922caa89e0ef6e1e35fffedac5688226a5502 | [] | no_license | awaitingsignal/Android_Me-TFragments.01-StartingCode | 3c7d3cbb8f6f2e1d5f7e0240bea6c04dc905b791 | 38549124beb7f495da67ae41161eb62a0c05b2c1 | refs/heads/master | 2020-04-27T14:25:16.769696 | 2019-03-12T16:13:47 | 2019-03-12T16:13:47 | 174,409,522 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 10,466 | 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.asynclayoutinflater;
public final class R {
private R() {}
public static final class attr {
private attr() {}
public static final int alpha = 0x7f020027;
public static final int font = 0x7f02007a;
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 ttcIndex = 0x7f02013c;
}
public static final class color {
private color() {}
public static final int notification_action_color_filter = 0x7f04003f;
public static final int notification_icon_bg_color = 0x7f040040;
public static final int ripple_material_light = 0x7f04004a;
public static final int secondary_text_default_material_light = 0x7f04004c;
}
public static final class dimen {
private dimen() {}
public static final int compat_button_inset_horizontal_material = 0x7f05004d;
public static final int compat_button_inset_vertical_material = 0x7f05004e;
public static final int compat_button_padding_horizontal_material = 0x7f05004f;
public static final int compat_button_padding_vertical_material = 0x7f050050;
public static final int compat_control_corner_material = 0x7f050051;
public static final int compat_notification_large_icon_max_height = 0x7f050052;
public static final int compat_notification_large_icon_max_width = 0x7f050053;
public static final int notification_action_icon_size = 0x7f05005d;
public static final int notification_action_text_size = 0x7f05005e;
public static final int notification_big_circle_margin = 0x7f05005f;
public static final int notification_content_margin_start = 0x7f050060;
public static final int notification_large_icon_height = 0x7f050061;
public static final int notification_large_icon_width = 0x7f050062;
public static final int notification_main_column_padding_top = 0x7f050063;
public static final int notification_media_narrow_margin = 0x7f050064;
public static final int notification_right_icon_size = 0x7f050065;
public static final int notification_right_side_padding_top = 0x7f050066;
public static final int notification_small_icon_background_padding = 0x7f050067;
public static final int notification_small_icon_size_as_large = 0x7f050068;
public static final int notification_subtext_size = 0x7f050069;
public static final int notification_top_pad = 0x7f05006a;
public static final int notification_top_pad_large_text = 0x7f05006b;
}
public static final class drawable {
private drawable() {}
public static final int notification_action_background = 0x7f060078;
public static final int notification_bg = 0x7f060079;
public static final int notification_bg_low = 0x7f06007a;
public static final int notification_bg_low_normal = 0x7f06007b;
public static final int notification_bg_low_pressed = 0x7f06007c;
public static final int notification_bg_normal = 0x7f06007d;
public static final int notification_bg_normal_pressed = 0x7f06007e;
public static final int notification_icon_background = 0x7f06007f;
public static final int notification_template_icon_bg = 0x7f060080;
public static final int notification_template_icon_low_bg = 0x7f060081;
public static final int notification_tile_bg = 0x7f060082;
public static final int notify_panel_notification_icon_bg = 0x7f060083;
}
public static final class id {
private id() {}
public static final int action_container = 0x7f07000d;
public static final int action_divider = 0x7f07000f;
public static final int action_image = 0x7f070010;
public static final int action_text = 0x7f070016;
public static final int actions = 0x7f070017;
public static final int async = 0x7f07001e;
public static final int blocking = 0x7f070021;
public static final int chronometer = 0x7f07002a;
public static final int forever = 0x7f07003e;
public static final int icon = 0x7f070046;
public static final int icon_group = 0x7f070047;
public static final int info = 0x7f07004a;
public static final int italic = 0x7f07004c;
public static final int line1 = 0x7f07004f;
public static final int line3 = 0x7f070050;
public static final int normal = 0x7f070059;
public static final int notification_background = 0x7f07005a;
public static final int notification_main_column = 0x7f07005b;
public static final int notification_main_column_container = 0x7f07005c;
public static final int right_icon = 0x7f070065;
public static final int right_side = 0x7f070066;
public static final int tag_transition_group = 0x7f070086;
public static final int tag_unhandled_key_event_manager = 0x7f070087;
public static final int tag_unhandled_key_listeners = 0x7f070088;
public static final int text = 0x7f070089;
public static final int text2 = 0x7f07008a;
public static final int time = 0x7f07008d;
public static final int title = 0x7f07008e;
}
public static final class integer {
private integer() {}
public static final int status_bar_notification_info_maxnum = 0x7f080004;
}
public static final class layout {
private layout() {}
public static final int notification_action = 0x7f090020;
public static final int notification_action_tombstone = 0x7f090021;
public static final int notification_template_custom_big = 0x7f090022;
public static final int notification_template_icon_group = 0x7f090023;
public static final int notification_template_part_chronometer = 0x7f090024;
public static final int notification_template_part_time = 0x7f090025;
}
public static final class string {
private string() {}
public static final int status_bar_notification_info_overflow = 0x7f0b0029;
}
public static final class style {
private style() {}
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 Widget_Compat_NotificationActionContainer = 0x7f0c0158;
public static final int Widget_Compat_NotificationActionText = 0x7f0c0159;
}
public static final class styleable {
private styleable() {}
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[] 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;
}
}
| [
"awaitingsignal@protonmail.com"
] | awaitingsignal@protonmail.com |
279bc2a27ff23dfa4188c506ca8b1d1bdab54830 | fe2ef5d33ed920aef5fc5bdd50daf5e69aa00ed4 | /common/src/com/zyf/common/crud/tag/PopSelectTag.java | d8eec9fa1a13fbd779eef6cd9a1a273bba02e23e | [] | no_license | sensui74/legacy-project | 4502d094edbf8964f6bb9805be88f869bae8e588 | ff8156ae963a5c61575ff34612c908c4ccfc219b | refs/heads/master | 2020-03-17T06:28:16.650878 | 2016-01-08T03:46:00 | 2016-01-08T03:46:00 | null | 0 | 0 | null | null | null | null | GB18030 | Java | false | false | 2,260 | java | /**
* 沈阳卓越科技有限公司版权所有
* 项目名称:common
* 制作时间:Dec 19, 20079:06:37 PM
* 包名:com.zyf.common.crud.tag
* 文件名:PopSelectTag.java
* 制作者:zhaoyf
* @version
*/
package com.zyf.common.crud.tag;
import java.io.IOException;
import java.text.MessageFormat;
import javax.servlet.jsp.JspException;
import javax.servlet.jsp.JspWriter;
import javax.servlet.jsp.tagext.TagSupport;
import org.apache.commons.lang.StringUtils;
import org.springframework.web.util.ExpressionEvaluationUtils;
import com.zyf.struts.BaseFormPlus;
/**
*
* @author zhaoyf
* @version 1.0
*/
public class PopSelectTag extends TagSupport {
private String formName;
public String getFormName() {
return formName;
}
public void setFormName(String formName) {
this.formName = formName;
}
private static String script1="<script language=\"javascript\">\r\n"+
"var listObject = new Object();\r\n"+
"CurrentPage.onLoadSelect = function(){\r\n"+
"listObject = new ListUtil.Listing('listObject', 'listtable');\r\n"+
"listObject.init();\r\n"+
"top.definedWin.selectListing = function(inum) {\r\n";
//<c:if test="${theForm.popSelectType == 'radio'}">listObject.selectWindow(1);</c:if>
//<c:if test="${theForm.popSelectType == 'checkbox'}">listObject.selectWindow(2);</c:if>
private static String script2="}\r\n"+
"top.definedWin.closeListing = function(inum) {\r\n"+
"listObject.selectWindow();\r\n"+
"}\r\n"+
"}\r\n"+
"CurrentPage.onLoadSelect();\r\n"+
"</script>";
public int doEndTag() throws JspException {
// TODO Auto-generated method stub
JspWriter out = pageContext.getOut();
BaseFormPlus form = (BaseFormPlus)ExpressionEvaluationUtils.evaluate("formName",formName, pageContext);
String selcetFuction=null;
if(StringUtils.isBlank(form.getPopSelectType()))
return super.doEndTag();
if("only".equals(form.getPopSelectType()))
selcetFuction="listObject.selectWindow(1);";
if("multi".equals(form.getPopSelectType()))
selcetFuction="listObject.selectWindow(2);";
try {
out.print(script1);
out.print(selcetFuction);
out.print(script2);
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
return super.doEndTag();
}
}
| [
"wow_fei@163.com"
] | wow_fei@163.com |
caa85a3ea6751e2c0f7d7debc085b2c8daf4fc46 | 9957ebe2cdb82f77d7bab949c6c9d7524188efeb | /src/model/Domain.java | 3f97c10c6c53bed1f2c2477aa5944aff7fda1c52 | [] | no_license | uzerzero/Strollers-1 | daa737b74df55dacfef8487844d04787e773a9a9 | 260c046b818d8ccd7083b74eee487bff03ca820f | refs/heads/master | 2021-01-25T10:21:52.937424 | 2014-03-07T11:59:15 | 2014-03-07T11:59:15 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,428 | java | package model;
import java.util.ArrayList;
/**
* Created by cactus on 21/02/14.
*/
public class Domain {
private float _x, _y, _w, _h;
private ArrayList<Building> _buildings;
public Domain(float x, float y, float w, float h) {
_x = x;
_y = y;
_w = w;
_h = h;
_buildings = new ArrayList<Building>();
}
boolean isOutOfDomain(Vehicule v) {
return v.get_posX() < _x || v.get_posX() > _x + _w||
v.get_posY() < _y || v.get_posY() > _y + _h;
}
public void addBuilding(Building building) {
_buildings.add(building);
}
void replaceVehiculeInside(Vehicule v) {
if (v.get_posX() < _x)
v.set_posX(_x);
else if (v.get_posX() > _x + _w)
v.set_posX(_x + _w);
if (v.get_posY() < _y)
v.set_posY(_y);
else if (v.get_posY() > _y + _h)
v.set_posY(_y + _h);
}
boolean isCollisionWithOneBuilding(Building b, Vehicule v) {
return !(v.get_posX() < b.get_posX() || v.get_posX() > b.get_posX() + b.get_width() ||
v.get_posY() < b.get_posY() || v.get_posY() > b.get_posY() + b.get_height());
}
boolean isCollisionWithBuildings(Vehicule v) {
for (Building building : _buildings) {
if (isCollisionWithOneBuilding(building, v))
return true;
}
return false;
}
}
| [
"jerem.girard@gmail.com"
] | jerem.girard@gmail.com |
66cc551cba070c5fbf7239529428310952035fc6 | 44f6461935f0262b6ae59dfca4d40a60e523572a | /app/src/main/java/com/scj/beilu/app/mvp/common/bean/PageBean.java | f3aa428435611aed53dc9daac1e366cbac9f323d | [
"Apache-2.0"
] | permissive | hanpengfei/beilu-android-open-project | 12d9a2795d5ae7c0d1837e307cd6bb5beba6c045 | 5238f149410222c374b4a47d41d079b77b43ccd3 | refs/heads/master | 2022-11-28T16:34:08.300735 | 2020-08-12T11:17:59 | 2020-08-12T11:17:59 | 286,252,808 | 0 | 0 | Apache-2.0 | 2020-08-09T14:26:16 | 2020-08-09T14:26:16 | null | UTF-8 | Java | false | false | 6,380 | java | package com.scj.beilu.app.mvp.common.bean;
import java.util.List;
/**
* @author Mingxun
* @time on 2019/2/14 16:35
*/
public class PageBean<T> {
/**
* currentPage : 1
* list : [{"newsId":59,"userId":11,"newsTitle":"asdads","newsAuthor":"asdasd","newsSource":"asdads","newsBrief":"asdasd","newsPic":"https://beilutest.oss-cn-hangzhou.aliyuncs.com/news/about/cc54a377-529f-406a-8edf-638858ca2b6020190244210743.jpg","newsContent":null,"cateId":3,"newsDate":"2019-02-13 21:07:42","newsBrowseCount":0,"newsShareWebSite":"https://beilutest.oss-cn-hangzhou.aliyuncs.com/news/article/ff7fa073-c1df-4b50-8f38-3f8844a45d5f20190244210743.html","newsCollectionCount":0,"newsShareCount":0},{"newsId":59,"userId":11,"newsTitle":"asdads","newsAuthor":"asdasd","newsSource":"asdads","newsBrief":"asdasd","newsPic":"https://beilutest.oss-cn-hangzhou.aliyuncs.com/news/about/cc54a377-529f-406a-8edf-638858ca2b6020190244210743.jpg","newsContent":null,"cateId":3,"newsDate":"2019-02-13 21:07:42","newsBrowseCount":0,"newsShareWebSite":"https://beilutest.oss-cn-hangzhou.aliyuncs.com/news/article/ff7fa073-c1df-4b50-8f38-3f8844a45d5f20190244210743.html","newsCollectionCount":0,"newsShareCount":0},{"newsId":59,"userId":11,"newsTitle":"asdads","newsAuthor":"asdasd","newsSource":"asdads","newsBrief":"asdasd","newsPic":"https://beilutest.oss-cn-hangzhou.aliyuncs.com/news/about/cc54a377-529f-406a-8edf-638858ca2b6020190244210743.jpg","newsContent":null,"cateId":3,"newsDate":"2019-02-13 21:07:42","newsBrowseCount":0,"newsShareWebSite":"https://beilutest.oss-cn-hangzhou.aliyuncs.com/news/article/ff7fa073-c1df-4b50-8f38-3f8844a45d5f20190244210743.html","newsCollectionCount":0,"newsShareCount":0},{"newsId":59,"userId":11,"newsTitle":"asdads","newsAuthor":"asdasd","newsSource":"asdads","newsBrief":"asdasd","newsPic":"https://beilutest.oss-cn-hangzhou.aliyuncs.com/news/about/cc54a377-529f-406a-8edf-638858ca2b6020190244210743.jpg","newsContent":null,"cateId":3,"newsDate":"2019-02-13 21:07:42","newsBrowseCount":0,"newsShareWebSite":"https://beilutest.oss-cn-hangzhou.aliyuncs.com/news/article/ff7fa073-c1df-4b50-8f38-3f8844a45d5f20190244210743.html","newsCollectionCount":0,"newsShareCount":0},{"newsId":54,"userId":11,"newsTitle":"魅族 16th","newsAuthor":"MEIUZU","newsSource":"https://detail.meizu.com/item/meizu16th.html?click=store_index_banner_1&click=click_store_index_banner_1","newsBrief":"追求源于热爱","newsPic":"https://beilutest.oss-cn-hangzhou.aliyuncs.com/news/about/9b36d0bc-abda-479c-a9cb-e76d007b191720190244192641.jpg","newsContent":null,"cateId":3,"newsDate":"2019-02-13 19:26:40","newsBrowseCount":0,"newsShareWebSite":"https://beilutest.oss-cn-hangzhou.aliyuncs.com/news/article/3da05c5d-6708-4b7a-951a-d3cdfa52659120190244192640.html","newsCollectionCount":0,"newsShareCount":0},{"newsId":54,"userId":11,"newsTitle":"魅族 16th","newsAuthor":"MEIUZU","newsSource":"https://detail.meizu.com/item/meizu16th.html?click=store_index_banner_1&click=click_store_index_banner_1","newsBrief":"追求源于热爱","newsPic":"https://beilutest.oss-cn-hangzhou.aliyuncs.com/news/about/9b36d0bc-abda-479c-a9cb-e76d007b191720190244192641.jpg","newsContent":null,"cateId":3,"newsDate":"2019-02-13 19:26:40","newsBrowseCount":0,"newsShareWebSite":"https://beilutest.oss-cn-hangzhou.aliyuncs.com/news/article/3da05c5d-6708-4b7a-951a-d3cdfa52659120190244192640.html","newsCollectionCount":0,"newsShareCount":0},{"newsId":54,"userId":11,"newsTitle":"魅族 16th","newsAuthor":"MEIUZU","newsSource":"https://detail.meizu.com/item/meizu16th.html?click=store_index_banner_1&click=click_store_index_banner_1","newsBrief":"追求源于热爱","newsPic":"https://beilutest.oss-cn-hangzhou.aliyuncs.com/news/about/9b36d0bc-abda-479c-a9cb-e76d007b191720190244192641.jpg","newsContent":null,"cateId":3,"newsDate":"2019-02-13 19:26:40","newsBrowseCount":0,"newsShareWebSite":"https://beilutest.oss-cn-hangzhou.aliyuncs.com/news/article/3da05c5d-6708-4b7a-951a-d3cdfa52659120190244192640.html","newsCollectionCount":0,"newsShareCount":0},{"newsId":54,"userId":11,"newsTitle":"魅族 16th","newsAuthor":"MEIUZU","newsSource":"https://detail.meizu.com/item/meizu16th.html?click=store_index_banner_1&click=click_store_index_banner_1","newsBrief":"追求源于热爱","newsPic":"https://beilutest.oss-cn-hangzhou.aliyuncs.com/news/about/9b36d0bc-abda-479c-a9cb-e76d007b191720190244192641.jpg","newsContent":null,"cateId":3,"newsDate":"2019-02-13 19:26:40","newsBrowseCount":0,"newsShareWebSite":"https://beilutest.oss-cn-hangzhou.aliyuncs.com/news/article/3da05c5d-6708-4b7a-951a-d3cdfa52659120190244192640.html","newsCollectionCount":0,"newsShareCount":0}]
* startCount : 0
* nextPage : 0
*/
private int currentPage;
private int startCount;
private int nextPage;
private int totalCount;
private int totalPageCount;
private int previousPage;
private int firstPage;
private int endPage;
private List<T> list;
public int getCurrentPage() {
return currentPage;
}
public void setCurrentPage(int currentPage) {
this.currentPage = currentPage;
}
public int getStartCount() {
return startCount;
}
public void setStartCount(int startCount) {
this.startCount = startCount;
}
public int getNextPage() {
return nextPage;
}
public void setNextPage(int nextPage) {
this.nextPage = nextPage;
}
public List<T> getList() {
return list;
}
public void setList(List<T> list) {
this.list = list;
}
public int getTotalCount() {
return totalCount;
}
public void setTotalCount(int totalCount) {
this.totalCount = totalCount;
}
public int getTotalPageCount() {
return totalPageCount;
}
public void setTotalPageCount(int totalPageCount) {
this.totalPageCount = totalPageCount;
}
public int getPreviousPage() {
return previousPage;
}
public void setPreviousPage(int previousPage) {
this.previousPage = previousPage;
}
public int getFirstPage() {
return firstPage;
}
public void setFirstPage(int firstPage) {
this.firstPage = firstPage;
}
public int getEndPage() {
return endPage;
}
public void setEndPage(int endPage) {
this.endPage = endPage;
}
}
| [
"12345678"
] | 12345678 |
11fe6596fcbd11b4eaeb884175795013445bfa0d | 6d6b9df6a66e35bf90f73eb08fb7ceb437a758eb | /Projects/Project 5/TriangleListApp/TriangleList.java | d6db1c2828a847a51e9e5bbd8232618c97dec166 | [] | no_license | jussaw/Fundamentals-of-Computing-I-Java-I- | a27f39eb5621dea2dd49ddf656e0e4770c49ebc1 | a92813ca0394498a5d8159aa586ba28e76e3efcf | refs/heads/master | 2020-03-29T21:00:32.983974 | 2018-09-26T00:12:58 | 2018-09-26T00:12:58 | 150,344,056 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,674 | java | import java.util.ArrayList;
import java.text.DecimalFormat;
public class TriangleList {
String listName;
ArrayList<Triangle> tList;
public TriangleList(String listNameIn, ArrayList<Triangle> tListIn) {
listName = listNameIn;
tList = tListIn;
}
public String getListName() {
return listName;
}
public int numTriangles() {
return tList.size();
}
public double totalOfPerimeters() {
double total = 0;
// What value is returned if there are no Triangles in the list?
int index = 0;
while (index < tList.size()) {
total += tList.get(index).perimeter();
index++;
}
return total;
}
public double smallestPerimeter() {
double smallest = 0;
if (tList.size() != 0) {
smallest = tList.get(0).perimeter();
}
else {
return 0;
}
int index = 0;
while (index < tList.size()) {
if (!(smallest < tList.get(index).perimeter())) {
smallest = tList.get(index).perimeter();
}
index++;
}
return smallest;
}
public String largestPerimeterWithSides() {
double largest = 0;
int indexOfLargest = 0;
int index = 0;
while (index < tList.size()) {
if (tList.get(indexOfLargest).perimeter() < tList.get(index).perimeter()) {
indexOfLargest = index;
}
index++;
}
if (tList.size() > 0) {
return tList.get(indexOfLargest).perimeter()
+ " for sides "
+ tList.get(indexOfLargest).getS1() + ", "
+ tList.get(indexOfLargest).getS2() + ", "
+ tList.get(indexOfLargest).getS3();
}
else {
return "No triangles in list";
}
}
public String toString() {
String result = "\n" + listName + "\n";
int index = 0;
while (index < tList.size()) {
result += "\n" + tList.get(index) + "\n";
index++;
}
return result;
}
public String summary() {
DecimalFormat df = new DecimalFormat("#,##0.##");
String result = "";
result += "----- Summary for " + getListName()+ " -----";
result += "\nNumber of Triangles: " + numTriangles();
result += "\nSmallest Perimeter: " + smallestPerimeter();
result += "\nLargest Perimeter: " + largestPerimeterWithSides();
result += "\nTotal of Perimeters: " + totalOfPerimeters();
return result;
}
}
| [
"unconfigured@null.spigotmc.org"
] | unconfigured@null.spigotmc.org |
3faa38753c9ab2c710f7d23c50bd2ca2e64212eb | 6be39fc2c882d0b9269f1530e0650fd3717df493 | /weixin反编译/sources/com/tencent/mm/protocal/c/bz.java | 8658f58ea3d56b5e4115e672576d669a08f0d936 | [] | no_license | sir-deng/res | f1819af90b366e8326bf23d1b2f1074dfe33848f | 3cf9b044e1f4744350e5e89648d27247c9dc9877 | refs/heads/master | 2022-06-11T21:54:36.725180 | 2020-05-07T06:03:23 | 2020-05-07T06:03:23 | 155,177,067 | 5 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,253 | java | package com.tencent.mm.protocal.c;
import com.tencent.mm.bp.a;
import e.a.a.b;
public final class bz extends a {
public String idC;
public String vNZ;
protected final int a(int i, Object... objArr) {
int h;
if (i == 0) {
e.a.a.c.a aVar = (e.a.a.c.a) objArr[0];
if (this.idC == null) {
throw new b("Not all required fields were included: tp_username");
} else if (this.vNZ == null) {
throw new b("Not all required fields were included: antispam_ticket");
} else {
if (this.idC != null) {
aVar.g(1, this.idC);
}
if (this.vNZ == null) {
return 0;
}
aVar.g(2, this.vNZ);
return 0;
}
} else if (i == 1) {
if (this.idC != null) {
h = e.a.a.b.b.a.h(1, this.idC) + 0;
} else {
h = 0;
}
if (this.vNZ != null) {
h += e.a.a.b.b.a.h(2, this.vNZ);
}
return h;
} else if (i == 2) {
e.a.a.a.a aVar2 = new e.a.a.a.a((byte[]) objArr[0], unknownTagHandler);
for (h = a.a(aVar2); h > 0; h = a.a(aVar2)) {
if (!super.a(aVar2, this, h)) {
aVar2.cKx();
}
}
if (this.idC == null) {
throw new b("Not all required fields were included: tp_username");
} else if (this.vNZ != null) {
return 0;
} else {
throw new b("Not all required fields were included: antispam_ticket");
}
} else if (i != 3) {
return -1;
} else {
e.a.a.a.a aVar3 = (e.a.a.a.a) objArr[0];
bz bzVar = (bz) objArr[1];
switch (((Integer) objArr[2]).intValue()) {
case 1:
bzVar.idC = aVar3.AEQ.readString();
return 0;
case 2:
bzVar.vNZ = aVar3.AEQ.readString();
return 0;
default:
return -1;
}
}
}
}
| [
"denghailong@vargo.com.cn"
] | denghailong@vargo.com.cn |
60a349bba2cdb615426dd074d052b9a781825ddc | 689b1f5baa357bbf46cc65af6c58e9734b83d9cc | /src/main/java/com/tinkerpop/gremlin/functions/g/util/FromJsonFunction.java | b9c9b6cbb92d43407cbd092a03d88fa36e11479a | [
"BSD-3-Clause"
] | permissive | atiw003/gremlin | 780b234979e1dc757a563a7e75f6718f201d3662 | df985cd7f2a29004ff913b6429a364790f2d73cb | refs/heads/master | 2021-01-16T01:25:54.044418 | 2010-05-28T14:54:36 | 2010-05-28T14:54:36 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,068 | java | package com.tinkerpop.gremlin.functions.g.util;
import com.tinkerpop.gremlin.functions.Function;
import com.tinkerpop.gremlin.functions.FunctionHelper;
import com.tinkerpop.gremlin.functions.g.GremlinFunctionLibrary;
import com.tinkerpop.gremlin.statements.EvaluationException;
import org.apache.commons.jxpath.ExpressionContext;
import org.json.simple.parser.ContainerFactory;
import org.json.simple.parser.JSONParser;
import org.json.simple.parser.ParseException;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
/**
* @author Marko A. Rodriguez (http://markorodriguez.com)
*/
public class FromJsonFunction implements Function {
public static final String FUNCTION_NAME = "from-json";
public Object invoke(final ExpressionContext context, final Object[] parameters) {
if (null != parameters && parameters.length == 1) {
Object object = FunctionHelper.nodeSetConversion(parameters[0]);
if (object instanceof String) {
String jsonString = (String) object;
JSONParser parser = new JSONParser();
ContainerFactory containerFactory = new ContainerFactory() {
public List creatArrayContainer() {
return new ArrayList();
}
public Map createObjectContainer() {
return new HashMap();
}
};
try {
return parser.parse(jsonString, containerFactory);
} catch (ParseException e) {
throw new EvaluationException("Unable to JSON parse: " + jsonString + " [at position " + e.getPosition() + "]");
}
}
}
throw EvaluationException.createException(FunctionHelper.makeFunctionName(GremlinFunctionLibrary.NAMESPACE_PREFIX, FUNCTION_NAME), EvaluationException.EvaluationErrorType.UNSUPPORTED_PARAMETERS);
}
public String getName() {
return FUNCTION_NAME;
}
}
| [
"okrammarko@gmail.com"
] | okrammarko@gmail.com |
f69d87e523fe1f5dedc1afa9a77818b312e58571 | c3d9753f0a0475dabb2eb7af2c544d34b6ab9108 | /APCSA 2020 V2/src/unit4/AddSubMult.java | cc988e5a44993cd2ce7a1d3d883ca72429219cb7 | [] | no_license | hafezip6020/APCSA-2020-V2 | 08e9bbe4f9bb045e638e88ee8d16b866d72800e9 | 97ba66ecb03005103928ad5582a107fdd6b22bdb | refs/heads/master | 2021-01-26T06:50:47.686896 | 2020-07-13T01:23:46 | 2020-07-13T01:23:46 | 243,353,910 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 379 | java | package unit4;
//(c) A+ Computer Science
//www.apluscompsci.com
//Name -
import static java.lang.System.*;
import java.util.Scanner;
public class AddSubMult
{
public static double check( double a, double b )
{
double num = 0;
if ( a > b ) {
num = a - b;
} else if( b > a ) {
num = b - a;
} else {
num = a*b;
}
return num;
}
} | [
"hafezip6020@CA-SU-F106-14.sduhsd.lan"
] | hafezip6020@CA-SU-F106-14.sduhsd.lan |
113f20262e3bb286f1fc813fa7b6205f55456cc2 | f672b68c13a903ebbf31862d7fa14eb35573adee | /android/app/build/generated/not_namespaced_r_class_sources/debug/processDebugResources/r/com/yalantis/ucrop/R.java | ee897e800c3a10355fa2732d28f84c884155f3e2 | [] | no_license | bibinprathap/SAICINSURANCE | 47205941be3bc8f105b6ea475a99391c4322fa7a | 6c6a7b3175187949952faf742e64229a8fd9b466 | refs/heads/master | 2022-11-07T03:50:26.506218 | 2020-06-17T16:26:00 | 2020-06-17T16:26:00 | 269,584,651 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 138,751 | 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 com.yalantis.ucrop;
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 int btn_checkbox_to_checked_box_inner_merged_animation = 0x7f01000c;
public static final int btn_checkbox_to_checked_box_outer_merged_animation = 0x7f01000d;
public static final int btn_checkbox_to_checked_icon_null_animation = 0x7f01000e;
public static final int btn_checkbox_to_unchecked_box_inner_merged_animation = 0x7f01000f;
public static final int btn_checkbox_to_unchecked_check_path_merged_animation = 0x7f010010;
public static final int btn_checkbox_to_unchecked_icon_null_animation = 0x7f010011;
public static final int btn_radio_to_off_mtrl_dot_group_animation = 0x7f010012;
public static final int btn_radio_to_off_mtrl_ring_outer_animation = 0x7f010013;
public static final int btn_radio_to_off_mtrl_ring_outer_path_animation = 0x7f010014;
public static final int btn_radio_to_on_mtrl_dot_group_animation = 0x7f010015;
public static final int btn_radio_to_on_mtrl_ring_outer_animation = 0x7f010016;
public static final int btn_radio_to_on_mtrl_ring_outer_path_animation = 0x7f010017;
public static final int ucrop_loader_circle_path = 0x7f01002c;
public static final int ucrop_loader_circle_scale = 0x7f01002d;
}
public static final class attr {
private attr() {}
public static final int actionBarDivider = 0x7f030000;
public static final int actionBarItemBackground = 0x7f030001;
public static final int actionBarPopupTheme = 0x7f030002;
public static final int actionBarSize = 0x7f030003;
public static final int actionBarSplitStyle = 0x7f030004;
public static final int actionBarStyle = 0x7f030005;
public static final int actionBarTabBarStyle = 0x7f030006;
public static final int actionBarTabStyle = 0x7f030007;
public static final int actionBarTabTextStyle = 0x7f030008;
public static final int actionBarTheme = 0x7f030009;
public static final int actionBarWidgetTheme = 0x7f03000a;
public static final int actionButtonStyle = 0x7f03000b;
public static final int actionDropDownStyle = 0x7f03000c;
public static final int actionLayout = 0x7f03000d;
public static final int actionMenuTextAppearance = 0x7f03000e;
public static final int actionMenuTextColor = 0x7f03000f;
public static final int actionModeBackground = 0x7f030010;
public static final int actionModeCloseButtonStyle = 0x7f030011;
public static final int actionModeCloseDrawable = 0x7f030012;
public static final int actionModeCopyDrawable = 0x7f030013;
public static final int actionModeCutDrawable = 0x7f030014;
public static final int actionModeFindDrawable = 0x7f030015;
public static final int actionModePasteDrawable = 0x7f030016;
public static final int actionModePopupWindowStyle = 0x7f030017;
public static final int actionModeSelectAllDrawable = 0x7f030018;
public static final int actionModeShareDrawable = 0x7f030019;
public static final int actionModeSplitBackground = 0x7f03001a;
public static final int actionModeStyle = 0x7f03001b;
public static final int actionModeWebSearchDrawable = 0x7f03001c;
public static final int actionOverflowButtonStyle = 0x7f03001d;
public static final int actionOverflowMenuStyle = 0x7f03001e;
public static final int actionProviderClass = 0x7f03001f;
public static final int actionViewClass = 0x7f030021;
public static final int activityChooserViewStyle = 0x7f030022;
public static final int alertDialogButtonGroupStyle = 0x7f030026;
public static final int alertDialogCenterButtons = 0x7f030027;
public static final int alertDialogStyle = 0x7f030028;
public static final int alertDialogTheme = 0x7f030029;
public static final int allowStacking = 0x7f03002a;
public static final int alpha = 0x7f03002b;
public static final int alphabeticModifiers = 0x7f03002c;
public static final int arrowHeadLength = 0x7f03002f;
public static final int arrowShaftLength = 0x7f030030;
public static final int autoCompleteTextViewStyle = 0x7f030031;
public static final int autoSizeMaxTextSize = 0x7f030032;
public static final int autoSizeMinTextSize = 0x7f030033;
public static final int autoSizePresetSizes = 0x7f030034;
public static final int autoSizeStepGranularity = 0x7f030035;
public static final int autoSizeTextType = 0x7f030036;
public static final int background = 0x7f030037;
public static final int backgroundSplit = 0x7f03003f;
public static final int backgroundStacked = 0x7f030040;
public static final int backgroundTint = 0x7f030041;
public static final int backgroundTintMode = 0x7f030042;
public static final int barLength = 0x7f030046;
public static final int borderlessButtonStyle = 0x7f030052;
public static final int buttonBarButtonStyle = 0x7f030061;
public static final int buttonBarNegativeButtonStyle = 0x7f030062;
public static final int buttonBarNeutralButtonStyle = 0x7f030063;
public static final int buttonBarPositiveButtonStyle = 0x7f030064;
public static final int buttonBarStyle = 0x7f030065;
public static final int buttonCompat = 0x7f030066;
public static final int buttonGravity = 0x7f030067;
public static final int buttonIconDimen = 0x7f030068;
public static final int buttonPanelSideLayout = 0x7f030069;
public static final int buttonStyle = 0x7f03006a;
public static final int buttonStyleSmall = 0x7f03006b;
public static final int buttonTint = 0x7f03006c;
public static final int buttonTintMode = 0x7f03006d;
public static final int checkboxStyle = 0x7f030076;
public static final int checkedTextViewStyle = 0x7f03007d;
public static final int closeIcon = 0x7f030092;
public static final int closeItemLayout = 0x7f030099;
public static final int collapseContentDescription = 0x7f03009a;
public static final int collapseIcon = 0x7f03009b;
public static final int color = 0x7f03009e;
public static final int colorAccent = 0x7f03009f;
public static final int colorBackgroundFloating = 0x7f0300a0;
public static final int colorButtonNormal = 0x7f0300a1;
public static final int colorControlActivated = 0x7f0300a2;
public static final int colorControlHighlight = 0x7f0300a3;
public static final int colorControlNormal = 0x7f0300a4;
public static final int colorError = 0x7f0300a5;
public static final int colorPrimary = 0x7f0300ac;
public static final int colorPrimaryDark = 0x7f0300ad;
public static final int colorSwitchThumbNormal = 0x7f0300b3;
public static final int commitIcon = 0x7f0300b4;
public static final int contentDescription = 0x7f0300b5;
public static final int contentInsetEnd = 0x7f0300b6;
public static final int contentInsetEndWithActions = 0x7f0300b7;
public static final int contentInsetLeft = 0x7f0300b8;
public static final int contentInsetRight = 0x7f0300b9;
public static final int contentInsetStart = 0x7f0300ba;
public static final int contentInsetStartWithNavigation = 0x7f0300bb;
public static final int controlBackground = 0x7f0300c2;
public static final int customNavigationLayout = 0x7f0300d5;
public static final int defaultQueryHint = 0x7f0300da;
public static final int dialogCornerRadius = 0x7f0300db;
public static final int dialogPreferredPadding = 0x7f0300dc;
public static final int dialogTheme = 0x7f0300dd;
public static final int displayOptions = 0x7f0300de;
public static final int divider = 0x7f0300df;
public static final int dividerHorizontal = 0x7f0300e0;
public static final int dividerPadding = 0x7f0300e1;
public static final int dividerVertical = 0x7f0300e2;
public static final int drawableBottomCompat = 0x7f0300e3;
public static final int drawableEndCompat = 0x7f0300e4;
public static final int drawableLeftCompat = 0x7f0300e5;
public static final int drawableRightCompat = 0x7f0300e6;
public static final int drawableSize = 0x7f0300e7;
public static final int drawableStartCompat = 0x7f0300e8;
public static final int drawableTint = 0x7f0300e9;
public static final int drawableTintMode = 0x7f0300ea;
public static final int drawableTopCompat = 0x7f0300eb;
public static final int drawerArrowStyle = 0x7f0300ec;
public static final int dropDownListViewStyle = 0x7f0300ed;
public static final int dropdownListPreferredItemHeight = 0x7f0300ee;
public static final int editTextBackground = 0x7f0300ef;
public static final int editTextColor = 0x7f0300f0;
public static final int editTextStyle = 0x7f0300f1;
public static final int elevation = 0x7f0300f2;
public static final int expandActivityOverflowButtonDrawable = 0x7f030104;
public static final int firstBaselineToTopHeight = 0x7f03011e;
public static final int font = 0x7f030120;
public static final int fontFamily = 0x7f030121;
public static final int fontProviderAuthority = 0x7f030122;
public static final int fontProviderCerts = 0x7f030123;
public static final int fontProviderFetchStrategy = 0x7f030124;
public static final int fontProviderFetchTimeout = 0x7f030125;
public static final int fontProviderPackage = 0x7f030126;
public static final int fontProviderQuery = 0x7f030127;
public static final int fontStyle = 0x7f030128;
public static final int fontVariationSettings = 0x7f030129;
public static final int fontWeight = 0x7f03012a;
public static final int gapBetweenBars = 0x7f03012c;
public static final int goIcon = 0x7f03012d;
public static final int height = 0x7f03012f;
public static final int hideOnContentScroll = 0x7f030135;
public static final int homeAsUpIndicator = 0x7f03013b;
public static final int homeLayout = 0x7f03013c;
public static final int icon = 0x7f03013e;
public static final int iconTint = 0x7f030144;
public static final int iconTintMode = 0x7f030145;
public static final int iconifiedByDefault = 0x7f030146;
public static final int imageButtonStyle = 0x7f030147;
public static final int indeterminateProgressStyle = 0x7f030148;
public static final int initialActivityCount = 0x7f030149;
public static final int isLightTheme = 0x7f03014b;
public static final int itemPadding = 0x7f030155;
public static final int lastBaselineToBottomHeight = 0x7f030167;
public static final int layout = 0x7f030168;
public static final int lineHeight = 0x7f030176;
public static final int listChoiceBackgroundIndicator = 0x7f030178;
public static final int listChoiceIndicatorMultipleAnimated = 0x7f030179;
public static final int listChoiceIndicatorSingleAnimated = 0x7f03017a;
public static final int listDividerAlertDialog = 0x7f03017b;
public static final int listItemLayout = 0x7f03017c;
public static final int listLayout = 0x7f03017d;
public static final int listMenuViewStyle = 0x7f03017e;
public static final int listPopupWindowStyle = 0x7f03017f;
public static final int listPreferredItemHeight = 0x7f030180;
public static final int listPreferredItemHeightLarge = 0x7f030181;
public static final int listPreferredItemHeightSmall = 0x7f030182;
public static final int listPreferredItemPaddingEnd = 0x7f030183;
public static final int listPreferredItemPaddingLeft = 0x7f030184;
public static final int listPreferredItemPaddingRight = 0x7f030185;
public static final int listPreferredItemPaddingStart = 0x7f030186;
public static final int logo = 0x7f030187;
public static final int logoDescription = 0x7f030188;
public static final int maxButtonHeight = 0x7f03019e;
public static final int measureWithLargestChild = 0x7f0301a1;
public static final int menu = 0x7f0301a2;
public static final int multiChoiceItemLayout = 0x7f0301a4;
public static final int navigationContentDescription = 0x7f0301a5;
public static final int navigationIcon = 0x7f0301a6;
public static final int navigationMode = 0x7f0301a7;
public static final int numericModifiers = 0x7f0301aa;
public static final int overlapAnchor = 0x7f0301ab;
public static final int paddingBottomNoButtons = 0x7f0301ad;
public static final int paddingEnd = 0x7f0301ae;
public static final int paddingStart = 0x7f0301af;
public static final int paddingTopNoTitle = 0x7f0301b0;
public static final int panelBackground = 0x7f0301b1;
public static final int panelMenuListTheme = 0x7f0301b2;
public static final int panelMenuListWidth = 0x7f0301b3;
public static final int popupMenuStyle = 0x7f0301bc;
public static final int popupTheme = 0x7f0301bd;
public static final int popupWindowStyle = 0x7f0301be;
public static final int preserveIconSpacing = 0x7f0301bf;
public static final int progressBarPadding = 0x7f0301c5;
public static final int progressBarStyle = 0x7f0301c6;
public static final int queryBackground = 0x7f0301c7;
public static final int queryHint = 0x7f0301c8;
public static final int radioButtonStyle = 0x7f0301c9;
public static final int ratingBarStyle = 0x7f0301cb;
public static final int ratingBarStyleIndicator = 0x7f0301cc;
public static final int ratingBarStyleSmall = 0x7f0301cd;
public static final int searchHintIcon = 0x7f0301e4;
public static final int searchIcon = 0x7f0301e5;
public static final int searchViewStyle = 0x7f0301e6;
public static final int seekBarStyle = 0x7f0301e7;
public static final int selectableItemBackground = 0x7f0301e8;
public static final int selectableItemBackgroundBorderless = 0x7f0301e9;
public static final int showAsAction = 0x7f0301ef;
public static final int showDividers = 0x7f0301f0;
public static final int showText = 0x7f0301f2;
public static final int showTitle = 0x7f0301f3;
public static final int singleChoiceItemLayout = 0x7f0301f5;
public static final int spinBars = 0x7f0301fb;
public static final int spinnerDropDownItemStyle = 0x7f0301fc;
public static final int spinnerStyle = 0x7f0301fd;
public static final int splitTrack = 0x7f0301fe;
public static final int srcCompat = 0x7f0301ff;
public static final int state_above_anchor = 0x7f030206;
public static final int subMenuArrow = 0x7f030211;
public static final int submitBackground = 0x7f030212;
public static final int subtitle = 0x7f030213;
public static final int subtitleTextAppearance = 0x7f030214;
public static final int subtitleTextColor = 0x7f030215;
public static final int subtitleTextStyle = 0x7f030216;
public static final int suggestionRowLayout = 0x7f030217;
public static final int switchMinWidth = 0x7f030218;
public static final int switchPadding = 0x7f030219;
public static final int switchStyle = 0x7f03021a;
public static final int switchTextAppearance = 0x7f03021b;
public static final int textAllCaps = 0x7f030236;
public static final int textAppearanceLargePopupMenu = 0x7f030241;
public static final int textAppearanceListItem = 0x7f030243;
public static final int textAppearanceListItemSecondary = 0x7f030244;
public static final int textAppearanceListItemSmall = 0x7f030245;
public static final int textAppearancePopupMenuHeader = 0x7f030247;
public static final int textAppearanceSearchResultSubtitle = 0x7f030248;
public static final int textAppearanceSearchResultTitle = 0x7f030249;
public static final int textAppearanceSmallPopupMenu = 0x7f03024a;
public static final int textColorAlertDialogListItem = 0x7f03024d;
public static final int textColorSearchUrl = 0x7f03024e;
public static final int textLocale = 0x7f030251;
public static final int theme = 0x7f030253;
public static final int thickness = 0x7f030255;
public static final int thumbTextPadding = 0x7f030256;
public static final int thumbTint = 0x7f030257;
public static final int thumbTintMode = 0x7f030258;
public static final int tickMark = 0x7f030259;
public static final int tickMarkTint = 0x7f03025a;
public static final int tickMarkTintMode = 0x7f03025b;
public static final int tint = 0x7f03025c;
public static final int tintMode = 0x7f03025d;
public static final int title = 0x7f03025e;
public static final int titleMargin = 0x7f030260;
public static final int titleMarginBottom = 0x7f030261;
public static final int titleMarginEnd = 0x7f030262;
public static final int titleMarginStart = 0x7f030263;
public static final int titleMarginTop = 0x7f030264;
public static final int titleMargins = 0x7f030265;
public static final int titleTextAppearance = 0x7f030266;
public static final int titleTextColor = 0x7f030267;
public static final int titleTextStyle = 0x7f030268;
public static final int toolbarNavigationButtonStyle = 0x7f03026a;
public static final int toolbarStyle = 0x7f03026b;
public static final int tooltipForegroundColor = 0x7f03026c;
public static final int tooltipFrameBackground = 0x7f03026d;
public static final int tooltipText = 0x7f03026e;
public static final int track = 0x7f03026f;
public static final int trackTint = 0x7f030270;
public static final int trackTintMode = 0x7f030271;
public static final int ttcIndex = 0x7f030272;
public static final int ucrop_artv_ratio_title = 0x7f030273;
public static final int ucrop_artv_ratio_x = 0x7f030274;
public static final int ucrop_artv_ratio_y = 0x7f030275;
public static final int ucrop_aspect_ratio_x = 0x7f030276;
public static final int ucrop_aspect_ratio_y = 0x7f030277;
public static final int ucrop_circle_dimmed_layer = 0x7f030278;
public static final int ucrop_dimmed_color = 0x7f030279;
public static final int ucrop_frame_color = 0x7f03027a;
public static final int ucrop_frame_stroke_size = 0x7f03027b;
public static final int ucrop_grid_color = 0x7f03027c;
public static final int ucrop_grid_column_count = 0x7f03027d;
public static final int ucrop_grid_row_count = 0x7f03027e;
public static final int ucrop_grid_stroke_size = 0x7f03027f;
public static final int ucrop_show_frame = 0x7f030280;
public static final int ucrop_show_grid = 0x7f030281;
public static final int ucrop_show_oval_crop_frame = 0x7f030282;
public static final int viewInflaterClass = 0x7f030286;
public static final int voiceIcon = 0x7f030287;
public static final int windowActionBar = 0x7f030288;
public static final int windowActionBarOverlay = 0x7f030289;
public static final int windowActionModeOverlay = 0x7f03028a;
public static final int windowFixedHeightMajor = 0x7f03028b;
public static final int windowFixedHeightMinor = 0x7f03028c;
public static final int windowFixedWidthMajor = 0x7f03028d;
public static final int windowFixedWidthMinor = 0x7f03028e;
public static final int windowMinWidthMajor = 0x7f03028f;
public static final int windowMinWidthMinor = 0x7f030290;
public static final int windowNoTitle = 0x7f030291;
}
public static final class bool {
private bool() {}
public static final int abc_action_bar_embed_tabs = 0x7f040000;
public static final int abc_allow_stacked_button_bar = 0x7f040001;
public static final int abc_config_actionMenuItemAllCaps = 0x7f040002;
}
public static final class color {
private color() {}
public static final int abc_background_cache_hint_selector_material_dark = 0x7f050000;
public static final int abc_background_cache_hint_selector_material_light = 0x7f050001;
public static final int abc_btn_colored_borderless_text_material = 0x7f050002;
public static final int abc_btn_colored_text_material = 0x7f050003;
public static final int abc_color_highlight_material = 0x7f050004;
public static final int abc_hint_foreground_material_dark = 0x7f050005;
public static final int abc_hint_foreground_material_light = 0x7f050006;
public static final int abc_input_method_navigation_guard = 0x7f050007;
public static final int abc_primary_text_disable_only_material_dark = 0x7f050008;
public static final int abc_primary_text_disable_only_material_light = 0x7f050009;
public static final int abc_primary_text_material_dark = 0x7f05000a;
public static final int abc_primary_text_material_light = 0x7f05000b;
public static final int abc_search_url_text = 0x7f05000c;
public static final int abc_search_url_text_normal = 0x7f05000d;
public static final int abc_search_url_text_pressed = 0x7f05000e;
public static final int abc_search_url_text_selected = 0x7f05000f;
public static final int abc_secondary_text_material_dark = 0x7f050010;
public static final int abc_secondary_text_material_light = 0x7f050011;
public static final int abc_tint_btn_checkable = 0x7f050012;
public static final int abc_tint_default = 0x7f050013;
public static final int abc_tint_edittext = 0x7f050014;
public static final int abc_tint_seek_thumb = 0x7f050015;
public static final int abc_tint_spinner = 0x7f050016;
public static final int abc_tint_switch_track = 0x7f050017;
public static final int accent_material_dark = 0x7f050018;
public static final int accent_material_light = 0x7f050019;
public static final int background_floating_material_dark = 0x7f05001a;
public static final int background_floating_material_light = 0x7f05001b;
public static final int background_material_dark = 0x7f05001c;
public static final int background_material_light = 0x7f05001d;
public static final int bright_foreground_disabled_material_dark = 0x7f05001e;
public static final int bright_foreground_disabled_material_light = 0x7f05001f;
public static final int bright_foreground_inverse_material_dark = 0x7f050020;
public static final int bright_foreground_inverse_material_light = 0x7f050021;
public static final int bright_foreground_material_dark = 0x7f050022;
public static final int bright_foreground_material_light = 0x7f050023;
public static final int button_material_dark = 0x7f050024;
public static final int button_material_light = 0x7f050025;
public static final int dim_foreground_disabled_material_dark = 0x7f050052;
public static final int dim_foreground_disabled_material_light = 0x7f050053;
public static final int dim_foreground_material_dark = 0x7f050054;
public static final int dim_foreground_material_light = 0x7f050055;
public static final int error_color_material_dark = 0x7f050056;
public static final int error_color_material_light = 0x7f050057;
public static final int foreground_material_dark = 0x7f050058;
public static final int foreground_material_light = 0x7f050059;
public static final int highlighted_text_material_dark = 0x7f05005a;
public static final int highlighted_text_material_light = 0x7f05005b;
public static final int material_blue_grey_800 = 0x7f05005c;
public static final int material_blue_grey_900 = 0x7f05005d;
public static final int material_blue_grey_950 = 0x7f05005e;
public static final int material_deep_teal_200 = 0x7f05005f;
public static final int material_deep_teal_500 = 0x7f050060;
public static final int material_grey_100 = 0x7f050061;
public static final int material_grey_300 = 0x7f050062;
public static final int material_grey_50 = 0x7f050063;
public static final int material_grey_600 = 0x7f050064;
public static final int material_grey_800 = 0x7f050065;
public static final int material_grey_850 = 0x7f050066;
public static final int material_grey_900 = 0x7f050067;
public static final int notification_action_color_filter = 0x7f0500a5;
public static final int notification_icon_bg_color = 0x7f0500a6;
public static final int primary_dark_material_dark = 0x7f0500a9;
public static final int primary_dark_material_light = 0x7f0500aa;
public static final int primary_material_dark = 0x7f0500ab;
public static final int primary_material_light = 0x7f0500ac;
public static final int primary_text_default_material_dark = 0x7f0500ad;
public static final int primary_text_default_material_light = 0x7f0500ae;
public static final int primary_text_disabled_material_dark = 0x7f0500af;
public static final int primary_text_disabled_material_light = 0x7f0500b0;
public static final int ripple_material_dark = 0x7f0500b1;
public static final int ripple_material_light = 0x7f0500b2;
public static final int secondary_text_default_material_dark = 0x7f0500b3;
public static final int secondary_text_default_material_light = 0x7f0500b4;
public static final int secondary_text_disabled_material_dark = 0x7f0500b5;
public static final int secondary_text_disabled_material_light = 0x7f0500b6;
public static final int switch_thumb_disabled_material_dark = 0x7f0500b7;
public static final int switch_thumb_disabled_material_light = 0x7f0500b8;
public static final int switch_thumb_material_dark = 0x7f0500b9;
public static final int switch_thumb_material_light = 0x7f0500ba;
public static final int switch_thumb_normal_material_dark = 0x7f0500bb;
public static final int switch_thumb_normal_material_light = 0x7f0500bc;
public static final int tooltip_background_dark = 0x7f0500bf;
public static final int tooltip_background_light = 0x7f0500c0;
public static final int ucrop_color_active_aspect_ratio = 0x7f0500c2;
public static final int ucrop_color_active_controls_color = 0x7f0500c3;
public static final int ucrop_color_black = 0x7f0500c4;
public static final int ucrop_color_blaze_orange = 0x7f0500c5;
public static final int ucrop_color_crop_background = 0x7f0500c6;
public static final int ucrop_color_default_crop_frame = 0x7f0500c7;
public static final int ucrop_color_default_crop_grid = 0x7f0500c8;
public static final int ucrop_color_default_dimmed = 0x7f0500c9;
public static final int ucrop_color_default_logo = 0x7f0500ca;
public static final int ucrop_color_ebony_clay = 0x7f0500cb;
public static final int ucrop_color_heather = 0x7f0500cc;
public static final int ucrop_color_inactive_aspect_ratio = 0x7f0500cd;
public static final int ucrop_color_inactive_controls_color = 0x7f0500ce;
public static final int ucrop_color_progress_wheel_line = 0x7f0500cf;
public static final int ucrop_color_statusbar = 0x7f0500d0;
public static final int ucrop_color_toolbar = 0x7f0500d1;
public static final int ucrop_color_toolbar_widget = 0x7f0500d2;
public static final int ucrop_color_white = 0x7f0500d3;
public static final int ucrop_color_widget = 0x7f0500d4;
public static final int ucrop_color_widget_active = 0x7f0500d5;
public static final int ucrop_color_widget_background = 0x7f0500d6;
public static final int ucrop_color_widget_rotate_angle = 0x7f0500d7;
public static final int ucrop_color_widget_rotate_mid_line = 0x7f0500d8;
public static final int ucrop_color_widget_text = 0x7f0500d9;
public static final int ucrop_scale_text_view_selector = 0x7f0500da;
}
public static final class dimen {
private dimen() {}
public static final int abc_action_bar_content_inset_material = 0x7f060000;
public static final int abc_action_bar_content_inset_with_nav = 0x7f060001;
public static final int abc_action_bar_default_height_material = 0x7f060002;
public static final int abc_action_bar_default_padding_end_material = 0x7f060003;
public static final int abc_action_bar_default_padding_start_material = 0x7f060004;
public static final int abc_action_bar_elevation_material = 0x7f060005;
public static final int abc_action_bar_icon_vertical_padding_material = 0x7f060006;
public static final int abc_action_bar_overflow_padding_end_material = 0x7f060007;
public static final int abc_action_bar_overflow_padding_start_material = 0x7f060008;
public static final int abc_action_bar_stacked_max_height = 0x7f060009;
public static final int abc_action_bar_stacked_tab_max_width = 0x7f06000a;
public static final int abc_action_bar_subtitle_bottom_margin_material = 0x7f06000b;
public static final int abc_action_bar_subtitle_top_margin_material = 0x7f06000c;
public static final int abc_action_button_min_height_material = 0x7f06000d;
public static final int abc_action_button_min_width_material = 0x7f06000e;
public static final int abc_action_button_min_width_overflow_material = 0x7f06000f;
public static final int abc_alert_dialog_button_bar_height = 0x7f060010;
public static final int abc_alert_dialog_button_dimen = 0x7f060011;
public static final int abc_button_inset_horizontal_material = 0x7f060012;
public static final int abc_button_inset_vertical_material = 0x7f060013;
public static final int abc_button_padding_horizontal_material = 0x7f060014;
public static final int abc_button_padding_vertical_material = 0x7f060015;
public static final int abc_cascading_menus_min_smallest_width = 0x7f060016;
public static final int abc_config_prefDialogWidth = 0x7f060017;
public static final int abc_control_corner_material = 0x7f060018;
public static final int abc_control_inset_material = 0x7f060019;
public static final int abc_control_padding_material = 0x7f06001a;
public static final int abc_dialog_corner_radius_material = 0x7f06001b;
public static final int abc_dialog_fixed_height_major = 0x7f06001c;
public static final int abc_dialog_fixed_height_minor = 0x7f06001d;
public static final int abc_dialog_fixed_width_major = 0x7f06001e;
public static final int abc_dialog_fixed_width_minor = 0x7f06001f;
public static final int abc_dialog_list_padding_bottom_no_buttons = 0x7f060020;
public static final int abc_dialog_list_padding_top_no_title = 0x7f060021;
public static final int abc_dialog_min_width_major = 0x7f060022;
public static final int abc_dialog_min_width_minor = 0x7f060023;
public static final int abc_dialog_padding_material = 0x7f060024;
public static final int abc_dialog_padding_top_material = 0x7f060025;
public static final int abc_dialog_title_divider_material = 0x7f060026;
public static final int abc_disabled_alpha_material_dark = 0x7f060027;
public static final int abc_disabled_alpha_material_light = 0x7f060028;
public static final int abc_dropdownitem_icon_width = 0x7f060029;
public static final int abc_dropdownitem_text_padding_left = 0x7f06002a;
public static final int abc_dropdownitem_text_padding_right = 0x7f06002b;
public static final int abc_edit_text_inset_bottom_material = 0x7f06002c;
public static final int abc_edit_text_inset_horizontal_material = 0x7f06002d;
public static final int abc_edit_text_inset_top_material = 0x7f06002e;
public static final int abc_floating_window_z = 0x7f06002f;
public static final int abc_list_item_height_large_material = 0x7f060030;
public static final int abc_list_item_height_material = 0x7f060031;
public static final int abc_list_item_height_small_material = 0x7f060032;
public static final int abc_list_item_padding_horizontal_material = 0x7f060033;
public static final int abc_panel_menu_list_width = 0x7f060034;
public static final int abc_progress_bar_height_material = 0x7f060035;
public static final int abc_search_view_preferred_height = 0x7f060036;
public static final int abc_search_view_preferred_width = 0x7f060037;
public static final int abc_seekbar_track_background_height_material = 0x7f060038;
public static final int abc_seekbar_track_progress_height_material = 0x7f060039;
public static final int abc_select_dialog_padding_start_material = 0x7f06003a;
public static final int abc_switch_padding = 0x7f06003b;
public static final int abc_text_size_body_1_material = 0x7f06003c;
public static final int abc_text_size_body_2_material = 0x7f06003d;
public static final int abc_text_size_button_material = 0x7f06003e;
public static final int abc_text_size_caption_material = 0x7f06003f;
public static final int abc_text_size_display_1_material = 0x7f060040;
public static final int abc_text_size_display_2_material = 0x7f060041;
public static final int abc_text_size_display_3_material = 0x7f060042;
public static final int abc_text_size_display_4_material = 0x7f060043;
public static final int abc_text_size_headline_material = 0x7f060044;
public static final int abc_text_size_large_material = 0x7f060045;
public static final int abc_text_size_medium_material = 0x7f060046;
public static final int abc_text_size_menu_header_material = 0x7f060047;
public static final int abc_text_size_menu_material = 0x7f060048;
public static final int abc_text_size_small_material = 0x7f060049;
public static final int abc_text_size_subhead_material = 0x7f06004a;
public static final int abc_text_size_subtitle_material_toolbar = 0x7f06004b;
public static final int abc_text_size_title_material = 0x7f06004c;
public static final int abc_text_size_title_material_toolbar = 0x7f06004d;
public static final int compat_button_inset_horizontal_material = 0x7f060053;
public static final int compat_button_inset_vertical_material = 0x7f060054;
public static final int compat_button_padding_horizontal_material = 0x7f060055;
public static final int compat_button_padding_vertical_material = 0x7f060056;
public static final int compat_control_corner_material = 0x7f060057;
public static final int compat_notification_large_icon_max_height = 0x7f060058;
public static final int compat_notification_large_icon_max_width = 0x7f060059;
public static final int disabled_alpha_material_dark = 0x7f060089;
public static final int disabled_alpha_material_light = 0x7f06008a;
public static final int highlight_alpha_material_colored = 0x7f06008e;
public static final int highlight_alpha_material_dark = 0x7f06008f;
public static final int highlight_alpha_material_light = 0x7f060090;
public static final int hint_alpha_material_dark = 0x7f060091;
public static final int hint_alpha_material_light = 0x7f060092;
public static final int hint_pressed_alpha_material_dark = 0x7f060093;
public static final int hint_pressed_alpha_material_light = 0x7f060094;
public static final int notification_action_icon_size = 0x7f06012e;
public static final int notification_action_text_size = 0x7f06012f;
public static final int notification_big_circle_margin = 0x7f060130;
public static final int notification_content_margin_start = 0x7f060131;
public static final int notification_large_icon_height = 0x7f060132;
public static final int notification_large_icon_width = 0x7f060133;
public static final int notification_main_column_padding_top = 0x7f060134;
public static final int notification_media_narrow_margin = 0x7f060135;
public static final int notification_right_icon_size = 0x7f060136;
public static final int notification_right_side_padding_top = 0x7f060137;
public static final int notification_small_icon_background_padding = 0x7f060138;
public static final int notification_small_icon_size_as_large = 0x7f060139;
public static final int notification_subtext_size = 0x7f06013a;
public static final int notification_top_pad = 0x7f06013b;
public static final int notification_top_pad_large_text = 0x7f06013c;
public static final int tooltip_corner_radius = 0x7f060142;
public static final int tooltip_horizontal_padding = 0x7f060143;
public static final int tooltip_margin = 0x7f060144;
public static final int tooltip_precise_anchor_extra_offset = 0x7f060145;
public static final int tooltip_precise_anchor_threshold = 0x7f060146;
public static final int tooltip_vertical_padding = 0x7f060147;
public static final int tooltip_y_offset_non_touch = 0x7f060148;
public static final int tooltip_y_offset_touch = 0x7f060149;
public static final int ucrop_default_crop_frame_stoke_width = 0x7f06014a;
public static final int ucrop_default_crop_grid_stoke_width = 0x7f06014b;
public static final int ucrop_default_crop_logo_size = 0x7f06014c;
public static final int ucrop_default_crop_rect_corner_touch_area_line_length = 0x7f06014d;
public static final int ucrop_default_crop_rect_corner_touch_threshold = 0x7f06014e;
public static final int ucrop_default_crop_rect_min_size = 0x7f06014f;
public static final int ucrop_height_crop_aspect_ratio_text = 0x7f060150;
public static final int ucrop_height_divider_shadow = 0x7f060151;
public static final int ucrop_height_horizontal_wheel_progress_line = 0x7f060152;
public static final int ucrop_height_wrapper_controls = 0x7f060153;
public static final int ucrop_height_wrapper_states = 0x7f060154;
public static final int ucrop_margin_horizontal_wheel_progress_line = 0x7f060155;
public static final int ucrop_margin_top_controls_text = 0x7f060156;
public static final int ucrop_margin_top_widget_text = 0x7f060157;
public static final int ucrop_padding_crop_frame = 0x7f060158;
public static final int ucrop_progress_size = 0x7f060159;
public static final int ucrop_size_dot_scale_text_view = 0x7f06015a;
public static final int ucrop_size_wrapper_rotate_button = 0x7f06015b;
public static final int ucrop_text_size_controls_text = 0x7f06015c;
public static final int ucrop_text_size_widget_text = 0x7f06015d;
public static final int ucrop_width_horizontal_wheel_progress_line = 0x7f06015e;
public static final int ucrop_width_middle_wheel_progress_line = 0x7f06015f;
}
public static final class drawable {
private drawable() {}
public static final int abc_ab_share_pack_mtrl_alpha = 0x7f070006;
public static final int abc_action_bar_item_background_material = 0x7f070007;
public static final int abc_btn_borderless_material = 0x7f070008;
public static final int abc_btn_check_material = 0x7f070009;
public static final int abc_btn_check_material_anim = 0x7f07000a;
public static final int abc_btn_check_to_on_mtrl_000 = 0x7f07000b;
public static final int abc_btn_check_to_on_mtrl_015 = 0x7f07000c;
public static final int abc_btn_colored_material = 0x7f07000d;
public static final int abc_btn_default_mtrl_shape = 0x7f07000e;
public static final int abc_btn_radio_material = 0x7f07000f;
public static final int abc_btn_radio_material_anim = 0x7f070010;
public static final int abc_btn_radio_to_on_mtrl_000 = 0x7f070011;
public static final int abc_btn_radio_to_on_mtrl_015 = 0x7f070012;
public static final int abc_btn_switch_to_on_mtrl_00001 = 0x7f070013;
public static final int abc_btn_switch_to_on_mtrl_00012 = 0x7f070014;
public static final int abc_cab_background_internal_bg = 0x7f070015;
public static final int abc_cab_background_top_material = 0x7f070016;
public static final int abc_cab_background_top_mtrl_alpha = 0x7f070017;
public static final int abc_control_background_material = 0x7f070018;
public static final int abc_dialog_material_background = 0x7f070019;
public static final int abc_edit_text_material = 0x7f07001a;
public static final int abc_ic_ab_back_material = 0x7f07001b;
public static final int abc_ic_arrow_drop_right_black_24dp = 0x7f07001c;
public static final int abc_ic_clear_material = 0x7f07001d;
public static final int abc_ic_commit_search_api_mtrl_alpha = 0x7f07001e;
public static final int abc_ic_go_search_api_material = 0x7f07001f;
public static final int abc_ic_menu_copy_mtrl_am_alpha = 0x7f070020;
public static final int abc_ic_menu_cut_mtrl_alpha = 0x7f070021;
public static final int abc_ic_menu_overflow_material = 0x7f070022;
public static final int abc_ic_menu_paste_mtrl_am_alpha = 0x7f070023;
public static final int abc_ic_menu_selectall_mtrl_alpha = 0x7f070024;
public static final int abc_ic_menu_share_mtrl_alpha = 0x7f070025;
public static final int abc_ic_search_api_material = 0x7f070026;
public static final int abc_ic_star_black_16dp = 0x7f070027;
public static final int abc_ic_star_black_36dp = 0x7f070028;
public static final int abc_ic_star_black_48dp = 0x7f070029;
public static final int abc_ic_star_half_black_16dp = 0x7f07002a;
public static final int abc_ic_star_half_black_36dp = 0x7f07002b;
public static final int abc_ic_star_half_black_48dp = 0x7f07002c;
public static final int abc_ic_voice_search_api_material = 0x7f07002d;
public static final int abc_item_background_holo_dark = 0x7f07002e;
public static final int abc_item_background_holo_light = 0x7f07002f;
public static final int abc_list_divider_material = 0x7f070030;
public static final int abc_list_divider_mtrl_alpha = 0x7f070031;
public static final int abc_list_focused_holo = 0x7f070032;
public static final int abc_list_longpressed_holo = 0x7f070033;
public static final int abc_list_pressed_holo_dark = 0x7f070034;
public static final int abc_list_pressed_holo_light = 0x7f070035;
public static final int abc_list_selector_background_transition_holo_dark = 0x7f070036;
public static final int abc_list_selector_background_transition_holo_light = 0x7f070037;
public static final int abc_list_selector_disabled_holo_dark = 0x7f070038;
public static final int abc_list_selector_disabled_holo_light = 0x7f070039;
public static final int abc_list_selector_holo_dark = 0x7f07003a;
public static final int abc_list_selector_holo_light = 0x7f07003b;
public static final int abc_menu_hardkey_panel_mtrl_mult = 0x7f07003c;
public static final int abc_popup_background_mtrl_mult = 0x7f07003d;
public static final int abc_ratingbar_indicator_material = 0x7f07003e;
public static final int abc_ratingbar_material = 0x7f07003f;
public static final int abc_ratingbar_small_material = 0x7f070040;
public static final int abc_scrubber_control_off_mtrl_alpha = 0x7f070041;
public static final int abc_scrubber_control_to_pressed_mtrl_000 = 0x7f070042;
public static final int abc_scrubber_control_to_pressed_mtrl_005 = 0x7f070043;
public static final int abc_scrubber_primary_mtrl_alpha = 0x7f070044;
public static final int abc_scrubber_track_mtrl_alpha = 0x7f070045;
public static final int abc_seekbar_thumb_material = 0x7f070046;
public static final int abc_seekbar_tick_mark_material = 0x7f070047;
public static final int abc_seekbar_track_material = 0x7f070048;
public static final int abc_spinner_mtrl_am_alpha = 0x7f070049;
public static final int abc_spinner_textfield_background_material = 0x7f07004a;
public static final int abc_switch_thumb_material = 0x7f07004b;
public static final int abc_switch_track_mtrl_alpha = 0x7f07004c;
public static final int abc_tab_indicator_material = 0x7f07004d;
public static final int abc_tab_indicator_mtrl_alpha = 0x7f07004e;
public static final int abc_text_cursor_material = 0x7f07004f;
public static final int abc_text_select_handle_left_mtrl_dark = 0x7f070050;
public static final int abc_text_select_handle_left_mtrl_light = 0x7f070051;
public static final int abc_text_select_handle_middle_mtrl_dark = 0x7f070052;
public static final int abc_text_select_handle_middle_mtrl_light = 0x7f070053;
public static final int abc_text_select_handle_right_mtrl_dark = 0x7f070054;
public static final int abc_text_select_handle_right_mtrl_light = 0x7f070055;
public static final int abc_textfield_activated_mtrl_alpha = 0x7f070056;
public static final int abc_textfield_default_mtrl_alpha = 0x7f070057;
public static final int abc_textfield_search_activated_mtrl_alpha = 0x7f070058;
public static final int abc_textfield_search_default_mtrl_alpha = 0x7f070059;
public static final int abc_textfield_search_material = 0x7f07005a;
public static final int abc_vector_test = 0x7f07005b;
public static final int btn_checkbox_checked_mtrl = 0x7f07005e;
public static final int btn_checkbox_checked_to_unchecked_mtrl_animation = 0x7f07005f;
public static final int btn_checkbox_unchecked_mtrl = 0x7f070060;
public static final int btn_checkbox_unchecked_to_checked_mtrl_animation = 0x7f070061;
public static final int btn_radio_off_mtrl = 0x7f070062;
public static final int btn_radio_off_to_on_mtrl_animation = 0x7f070063;
public static final int btn_radio_on_mtrl = 0x7f070064;
public static final int btn_radio_on_to_off_mtrl_animation = 0x7f070065;
public static final int notification_action_background = 0x7f070082;
public static final int notification_bg = 0x7f070083;
public static final int notification_bg_low = 0x7f070084;
public static final int notification_bg_low_normal = 0x7f070085;
public static final int notification_bg_low_pressed = 0x7f070086;
public static final int notification_bg_normal = 0x7f070087;
public static final int notification_bg_normal_pressed = 0x7f070088;
public static final int notification_icon_background = 0x7f070089;
public static final int notification_template_icon_bg = 0x7f07008a;
public static final int notification_template_icon_low_bg = 0x7f07008b;
public static final int notification_tile_bg = 0x7f07008c;
public static final int notify_panel_notification_icon_bg = 0x7f07008d;
public static final int tooltip_frame_dark = 0x7f070091;
public static final int tooltip_frame_light = 0x7f070092;
public static final int ucrop_crop = 0x7f070093;
public static final int ucrop_ic_angle = 0x7f070094;
public static final int ucrop_ic_crop = 0x7f070095;
public static final int ucrop_ic_crop_unselected = 0x7f070096;
public static final int ucrop_ic_cross = 0x7f070097;
public static final int ucrop_ic_done = 0x7f070098;
public static final int ucrop_ic_next = 0x7f070099;
public static final int ucrop_ic_reset = 0x7f07009a;
public static final int ucrop_ic_rotate = 0x7f07009b;
public static final int ucrop_ic_rotate_unselected = 0x7f07009c;
public static final int ucrop_ic_scale = 0x7f07009d;
public static final int ucrop_ic_scale_unselected = 0x7f07009e;
public static final int ucrop_rotate = 0x7f07009f;
public static final int ucrop_scale = 0x7f0700a0;
public static final int ucrop_shadow_upside = 0x7f0700a1;
public static final int ucrop_vector_ic_crop = 0x7f0700a2;
public static final int ucrop_vector_loader = 0x7f0700a3;
public static final int ucrop_vector_loader_animated = 0x7f0700a4;
public static final int ucrop_wrapper_controls_shape = 0x7f0700a5;
}
public static final class id {
private id() {}
public static final int accessibility_action_clickable_span = 0x7f08000a;
public static final int accessibility_custom_action_0 = 0x7f08000c;
public static final int accessibility_custom_action_1 = 0x7f08000d;
public static final int accessibility_custom_action_10 = 0x7f08000e;
public static final int accessibility_custom_action_11 = 0x7f08000f;
public static final int accessibility_custom_action_12 = 0x7f080010;
public static final int accessibility_custom_action_13 = 0x7f080011;
public static final int accessibility_custom_action_14 = 0x7f080012;
public static final int accessibility_custom_action_15 = 0x7f080013;
public static final int accessibility_custom_action_16 = 0x7f080014;
public static final int accessibility_custom_action_17 = 0x7f080015;
public static final int accessibility_custom_action_18 = 0x7f080016;
public static final int accessibility_custom_action_19 = 0x7f080017;
public static final int accessibility_custom_action_2 = 0x7f080018;
public static final int accessibility_custom_action_20 = 0x7f080019;
public static final int accessibility_custom_action_21 = 0x7f08001a;
public static final int accessibility_custom_action_22 = 0x7f08001b;
public static final int accessibility_custom_action_23 = 0x7f08001c;
public static final int accessibility_custom_action_24 = 0x7f08001d;
public static final int accessibility_custom_action_25 = 0x7f08001e;
public static final int accessibility_custom_action_26 = 0x7f08001f;
public static final int accessibility_custom_action_27 = 0x7f080020;
public static final int accessibility_custom_action_28 = 0x7f080021;
public static final int accessibility_custom_action_29 = 0x7f080022;
public static final int accessibility_custom_action_3 = 0x7f080023;
public static final int accessibility_custom_action_30 = 0x7f080024;
public static final int accessibility_custom_action_31 = 0x7f080025;
public static final int accessibility_custom_action_4 = 0x7f080026;
public static final int accessibility_custom_action_5 = 0x7f080027;
public static final int accessibility_custom_action_6 = 0x7f080028;
public static final int accessibility_custom_action_7 = 0x7f080029;
public static final int accessibility_custom_action_8 = 0x7f08002a;
public static final int accessibility_custom_action_9 = 0x7f08002b;
public static final int action_bar = 0x7f080032;
public static final int action_bar_activity_content = 0x7f080033;
public static final int action_bar_container = 0x7f080034;
public static final int action_bar_root = 0x7f080035;
public static final int action_bar_spinner = 0x7f080036;
public static final int action_bar_subtitle = 0x7f080037;
public static final int action_bar_title = 0x7f080038;
public static final int action_container = 0x7f080039;
public static final int action_context_bar = 0x7f08003a;
public static final int action_divider = 0x7f08003b;
public static final int action_image = 0x7f08003c;
public static final int action_menu_divider = 0x7f08003d;
public static final int action_menu_presenter = 0x7f08003e;
public static final int action_mode_bar = 0x7f08003f;
public static final int action_mode_bar_stub = 0x7f080040;
public static final int action_mode_close_button = 0x7f080041;
public static final int action_text = 0x7f080042;
public static final int actions = 0x7f080043;
public static final int activity_chooser_view_content = 0x7f080044;
public static final int add = 0x7f080045;
public static final int alertTitle = 0x7f080046;
public static final int async = 0x7f080049;
public static final int blocking = 0x7f08004c;
public static final int buttonPanel = 0x7f08004e;
public static final int checkbox = 0x7f080057;
public static final int checked = 0x7f080058;
public static final int chronometer = 0x7f08005b;
public static final int content = 0x7f080062;
public static final int contentPanel = 0x7f080063;
public static final int controls_shadow = 0x7f080064;
public static final int controls_wrapper = 0x7f080065;
public static final int custom = 0x7f080067;
public static final int customPanel = 0x7f080068;
public static final int decor_content_parent = 0x7f08006b;
public static final int default_activity_button = 0x7f08006c;
public static final int dialog_button = 0x7f080072;
public static final int edit_query = 0x7f080075;
public static final int expand_activities_button = 0x7f08007b;
public static final int expanded_menu = 0x7f08007c;
public static final int forever = 0x7f08008b;
public static final int ghost_view = 0x7f08008e;
public static final int ghost_view_holder = 0x7f08008f;
public static final int group_divider = 0x7f080090;
public static final int home = 0x7f080092;
public static final int icon = 0x7f080094;
public static final int icon_group = 0x7f080095;
public static final int image = 0x7f080097;
public static final int image_view_crop = 0x7f080098;
public static final int image_view_logo = 0x7f080099;
public static final int image_view_state_aspect_ratio = 0x7f08009a;
public static final int image_view_state_rotate = 0x7f08009b;
public static final int image_view_state_scale = 0x7f08009c;
public static final int info = 0x7f08009d;
public static final int italic = 0x7f08009e;
public static final int layout_aspect_ratio = 0x7f0800a2;
public static final int layout_rotate_wheel = 0x7f0800a3;
public static final int layout_scale_wheel = 0x7f0800a4;
public static final int line1 = 0x7f0800a6;
public static final int line3 = 0x7f0800a7;
public static final int listMode = 0x7f0800a8;
public static final int list_item = 0x7f0800a9;
public static final int menu_crop = 0x7f0800ac;
public static final int menu_loader = 0x7f0800ad;
public static final int message = 0x7f0800ae;
public static final int multiply = 0x7f0800cb;
public static final int none = 0x7f0800cf;
public static final int normal = 0x7f0800d0;
public static final int notification_background = 0x7f0800d1;
public static final int notification_main_column = 0x7f0800d2;
public static final int notification_main_column_container = 0x7f0800d3;
public static final int off = 0x7f0800d4;
public static final int on = 0x7f0800d5;
public static final int parentPanel = 0x7f0800d8;
public static final int parent_matrix = 0x7f0800d9;
public static final int progress_circular = 0x7f0800dd;
public static final int progress_horizontal = 0x7f0800de;
public static final int radio = 0x7f0800df;
public static final int right_icon = 0x7f0800e2;
public static final int right_side = 0x7f0800e3;
public static final int rotate_scroll_wheel = 0x7f0800ed;
public static final int save_non_transition_alpha = 0x7f0800ef;
public static final int save_overlay_view = 0x7f0800f0;
public static final int scale_scroll_wheel = 0x7f0800f2;
public static final int screen = 0x7f0800f3;
public static final int scrollIndicatorDown = 0x7f0800f5;
public static final int scrollIndicatorUp = 0x7f0800f6;
public static final int scrollView = 0x7f0800f7;
public static final int search_badge = 0x7f0800f9;
public static final int search_bar = 0x7f0800fa;
public static final int search_button = 0x7f0800fb;
public static final int search_close_btn = 0x7f0800fc;
public static final int search_edit_frame = 0x7f0800fd;
public static final int search_go_btn = 0x7f0800fe;
public static final int search_mag_icon = 0x7f0800ff;
public static final int search_plate = 0x7f080100;
public static final int search_src_text = 0x7f080101;
public static final int search_voice_btn = 0x7f080102;
public static final int select_dialog_listview = 0x7f080103;
public static final int shortcut = 0x7f080105;
public static final int spacer = 0x7f080110;
public static final int split_action_bar = 0x7f080111;
public static final int src_atop = 0x7f080112;
public static final int src_in = 0x7f080113;
public static final int src_over = 0x7f080114;
public static final int state_aspect_ratio = 0x7f080116;
public static final int state_rotate = 0x7f080117;
public static final int state_scale = 0x7f080118;
public static final int submenuarrow = 0x7f08011b;
public static final int submit_area = 0x7f08011c;
public static final int tabMode = 0x7f08011d;
public static final int tag_accessibility_actions = 0x7f08011e;
public static final int tag_accessibility_clickable_spans = 0x7f08011f;
public static final int tag_accessibility_heading = 0x7f080120;
public static final int tag_accessibility_pane_title = 0x7f080121;
public static final int tag_screen_reader_focusable = 0x7f080122;
public static final int tag_transition_group = 0x7f080123;
public static final int tag_unhandled_key_event_manager = 0x7f080124;
public static final int tag_unhandled_key_listeners = 0x7f080125;
public static final int text = 0x7f080128;
public static final int text2 = 0x7f080129;
public static final int textSpacerNoButtons = 0x7f08012b;
public static final int textSpacerNoTitle = 0x7f08012c;
public static final int text_view_crop = 0x7f080130;
public static final int text_view_rotate = 0x7f080131;
public static final int text_view_scale = 0x7f080132;
public static final int time = 0x7f080136;
public static final int title = 0x7f080137;
public static final int titleDividerNoCustom = 0x7f080138;
public static final int title_template = 0x7f080139;
public static final int toolbar = 0x7f08013a;
public static final int toolbar_title = 0x7f08013b;
public static final int topPanel = 0x7f08013d;
public static final int transition_current_scene = 0x7f08013f;
public static final int transition_layout_save = 0x7f080140;
public static final int transition_position = 0x7f080141;
public static final int transition_scene_layoutid_cache = 0x7f080142;
public static final int transition_transform = 0x7f080143;
public static final int ucrop = 0x7f080144;
public static final int ucrop_frame = 0x7f080145;
public static final int ucrop_photobox = 0x7f080146;
public static final int unchecked = 0x7f080147;
public static final int uniform = 0x7f080148;
public static final int up = 0x7f08014a;
public static final int view_overlay = 0x7f08014d;
public static final int wrap_content = 0x7f080153;
public static final int wrapper_controls = 0x7f080154;
public static final int wrapper_reset_rotate = 0x7f080155;
public static final int wrapper_rotate_by_angle = 0x7f080156;
public static final int wrapper_states = 0x7f080157;
}
public static final class integer {
private integer() {}
public static final int abc_config_activityDefaultDur = 0x7f090000;
public static final int abc_config_activityShortDur = 0x7f090001;
public static final int cancel_button_image_alpha = 0x7f090004;
public static final int config_tooltipAnimTime = 0x7f090005;
public static final int status_bar_notification_info_maxnum = 0x7f090016;
public static final int ucrop_progress_loading_anim_time = 0x7f090017;
}
public static final class interpolator {
private interpolator() {}
public static final int btn_checkbox_checked_mtrl_animation_interpolator_0 = 0x7f0a0000;
public static final int btn_checkbox_checked_mtrl_animation_interpolator_1 = 0x7f0a0001;
public static final int btn_checkbox_unchecked_mtrl_animation_interpolator_0 = 0x7f0a0002;
public static final int btn_checkbox_unchecked_mtrl_animation_interpolator_1 = 0x7f0a0003;
public static final int btn_radio_to_off_mtrl_animation_interpolator_0 = 0x7f0a0004;
public static final int btn_radio_to_on_mtrl_animation_interpolator_0 = 0x7f0a0005;
public static final int fast_out_slow_in = 0x7f0a0006;
}
public static final class layout {
private layout() {}
public static final int abc_action_bar_title_item = 0x7f0b0000;
public static final int abc_action_bar_up_container = 0x7f0b0001;
public static final int abc_action_menu_item_layout = 0x7f0b0002;
public static final int abc_action_menu_layout = 0x7f0b0003;
public static final int abc_action_mode_bar = 0x7f0b0004;
public static final int abc_action_mode_close_item_material = 0x7f0b0005;
public static final int abc_activity_chooser_view = 0x7f0b0006;
public static final int abc_activity_chooser_view_list_item = 0x7f0b0007;
public static final int abc_alert_dialog_button_bar_material = 0x7f0b0008;
public static final int abc_alert_dialog_material = 0x7f0b0009;
public static final int abc_alert_dialog_title_material = 0x7f0b000a;
public static final int abc_cascading_menu_item_layout = 0x7f0b000b;
public static final int abc_dialog_title_material = 0x7f0b000c;
public static final int abc_expanded_menu_layout = 0x7f0b000d;
public static final int abc_list_menu_item_checkbox = 0x7f0b000e;
public static final int abc_list_menu_item_icon = 0x7f0b000f;
public static final int abc_list_menu_item_layout = 0x7f0b0010;
public static final int abc_list_menu_item_radio = 0x7f0b0011;
public static final int abc_popup_menu_header_item_layout = 0x7f0b0012;
public static final int abc_popup_menu_item_layout = 0x7f0b0013;
public static final int abc_screen_content_include = 0x7f0b0014;
public static final int abc_screen_simple = 0x7f0b0015;
public static final int abc_screen_simple_overlay_action_mode = 0x7f0b0016;
public static final int abc_screen_toolbar = 0x7f0b0017;
public static final int abc_search_dropdown_item_icons_2line = 0x7f0b0018;
public static final int abc_search_view = 0x7f0b0019;
public static final int abc_select_dialog_material = 0x7f0b001a;
public static final int abc_tooltip = 0x7f0b001b;
public static final int custom_dialog = 0x7f0b001c;
public static final int notification_action = 0x7f0b004a;
public static final int notification_action_tombstone = 0x7f0b004b;
public static final int notification_template_custom_big = 0x7f0b0052;
public static final int notification_template_icon_group = 0x7f0b0053;
public static final int notification_template_part_chronometer = 0x7f0b0057;
public static final int notification_template_part_time = 0x7f0b0058;
public static final int select_dialog_item_material = 0x7f0b005c;
public static final int select_dialog_multichoice_material = 0x7f0b005d;
public static final int select_dialog_singlechoice_material = 0x7f0b005e;
public static final int support_simple_spinner_dropdown_item = 0x7f0b005f;
public static final int ucrop_activity_photobox = 0x7f0b006c;
public static final int ucrop_aspect_ratio = 0x7f0b006d;
public static final int ucrop_controls = 0x7f0b006e;
public static final int ucrop_fragment_photobox = 0x7f0b006f;
public static final int ucrop_layout_rotate_wheel = 0x7f0b0070;
public static final int ucrop_layout_scale_wheel = 0x7f0b0071;
public static final int ucrop_view = 0x7f0b0072;
}
public static final class menu {
private menu() {}
public static final int ucrop_menu_activity = 0x7f0c0000;
}
public static final class string {
private string() {}
public static final int abc_action_bar_home_description = 0x7f0f0000;
public static final int abc_action_bar_up_description = 0x7f0f0001;
public static final int abc_action_menu_overflow_description = 0x7f0f0002;
public static final int abc_action_mode_done = 0x7f0f0003;
public static final int abc_activity_chooser_view_see_all = 0x7f0f0004;
public static final int abc_activitychooserview_choose_application = 0x7f0f0005;
public static final int abc_capital_off = 0x7f0f0006;
public static final int abc_capital_on = 0x7f0f0007;
public static final int abc_menu_alt_shortcut_label = 0x7f0f0008;
public static final int abc_menu_ctrl_shortcut_label = 0x7f0f0009;
public static final int abc_menu_delete_shortcut_label = 0x7f0f000a;
public static final int abc_menu_enter_shortcut_label = 0x7f0f000b;
public static final int abc_menu_function_shortcut_label = 0x7f0f000c;
public static final int abc_menu_meta_shortcut_label = 0x7f0f000d;
public static final int abc_menu_shift_shortcut_label = 0x7f0f000e;
public static final int abc_menu_space_shortcut_label = 0x7f0f000f;
public static final int abc_menu_sym_shortcut_label = 0x7f0f0010;
public static final int abc_prepend_shortcut_label = 0x7f0f0011;
public static final int abc_search_hint = 0x7f0f0012;
public static final int abc_searchview_description_clear = 0x7f0f0013;
public static final int abc_searchview_description_query = 0x7f0f0014;
public static final int abc_searchview_description_search = 0x7f0f0015;
public static final int abc_searchview_description_submit = 0x7f0f0016;
public static final int abc_searchview_description_voice = 0x7f0f0017;
public static final int abc_shareactionprovider_share_with = 0x7f0f0018;
public static final int abc_shareactionprovider_share_with_application = 0x7f0f0019;
public static final int abc_toolbar_collapse_description = 0x7f0f001a;
public static final int search_menu_title = 0x7f0f007a;
public static final int status_bar_notification_info_overflow = 0x7f0f0082;
public static final int ucrop_crop = 0x7f0f0087;
public static final int ucrop_error_input_data_is_absent = 0x7f0f0088;
public static final int ucrop_label_edit_photo = 0x7f0f0089;
public static final int ucrop_label_original = 0x7f0f008a;
public static final int ucrop_menu_crop = 0x7f0f008b;
public static final int ucrop_mutate_exception_hint = 0x7f0f008c;
public static final int ucrop_rotate = 0x7f0f008d;
public static final int ucrop_scale = 0x7f0f008e;
}
public static final class style {
private style() {}
public static final int AlertDialog_AppCompat = 0x7f100000;
public static final int AlertDialog_AppCompat_Light = 0x7f100001;
public static final int Animation_AppCompat_Dialog = 0x7f100002;
public static final int Animation_AppCompat_DropDownUp = 0x7f100003;
public static final int Animation_AppCompat_Tooltip = 0x7f100004;
public static final int Base_AlertDialog_AppCompat = 0x7f100009;
public static final int Base_AlertDialog_AppCompat_Light = 0x7f10000a;
public static final int Base_Animation_AppCompat_Dialog = 0x7f10000b;
public static final int Base_Animation_AppCompat_DropDownUp = 0x7f10000c;
public static final int Base_Animation_AppCompat_Tooltip = 0x7f10000d;
public static final int Base_DialogWindowTitleBackground_AppCompat = 0x7f100010;
public static final int Base_DialogWindowTitle_AppCompat = 0x7f10000f;
public static final int Base_TextAppearance_AppCompat = 0x7f100014;
public static final int Base_TextAppearance_AppCompat_Body1 = 0x7f100015;
public static final int Base_TextAppearance_AppCompat_Body2 = 0x7f100016;
public static final int Base_TextAppearance_AppCompat_Button = 0x7f100017;
public static final int Base_TextAppearance_AppCompat_Caption = 0x7f100018;
public static final int Base_TextAppearance_AppCompat_Display1 = 0x7f100019;
public static final int Base_TextAppearance_AppCompat_Display2 = 0x7f10001a;
public static final int Base_TextAppearance_AppCompat_Display3 = 0x7f10001b;
public static final int Base_TextAppearance_AppCompat_Display4 = 0x7f10001c;
public static final int Base_TextAppearance_AppCompat_Headline = 0x7f10001d;
public static final int Base_TextAppearance_AppCompat_Inverse = 0x7f10001e;
public static final int Base_TextAppearance_AppCompat_Large = 0x7f10001f;
public static final int Base_TextAppearance_AppCompat_Large_Inverse = 0x7f100020;
public static final int Base_TextAppearance_AppCompat_Light_Widget_PopupMenu_Large = 0x7f100021;
public static final int Base_TextAppearance_AppCompat_Light_Widget_PopupMenu_Small = 0x7f100022;
public static final int Base_TextAppearance_AppCompat_Medium = 0x7f100023;
public static final int Base_TextAppearance_AppCompat_Medium_Inverse = 0x7f100024;
public static final int Base_TextAppearance_AppCompat_Menu = 0x7f100025;
public static final int Base_TextAppearance_AppCompat_SearchResult = 0x7f100026;
public static final int Base_TextAppearance_AppCompat_SearchResult_Subtitle = 0x7f100027;
public static final int Base_TextAppearance_AppCompat_SearchResult_Title = 0x7f100028;
public static final int Base_TextAppearance_AppCompat_Small = 0x7f100029;
public static final int Base_TextAppearance_AppCompat_Small_Inverse = 0x7f10002a;
public static final int Base_TextAppearance_AppCompat_Subhead = 0x7f10002b;
public static final int Base_TextAppearance_AppCompat_Subhead_Inverse = 0x7f10002c;
public static final int Base_TextAppearance_AppCompat_Title = 0x7f10002d;
public static final int Base_TextAppearance_AppCompat_Title_Inverse = 0x7f10002e;
public static final int Base_TextAppearance_AppCompat_Tooltip = 0x7f10002f;
public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Menu = 0x7f100030;
public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Subtitle = 0x7f100031;
public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Subtitle_Inverse = 0x7f100032;
public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Title = 0x7f100033;
public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Title_Inverse = 0x7f100034;
public static final int Base_TextAppearance_AppCompat_Widget_ActionMode_Subtitle = 0x7f100035;
public static final int Base_TextAppearance_AppCompat_Widget_ActionMode_Title = 0x7f100036;
public static final int Base_TextAppearance_AppCompat_Widget_Button = 0x7f100037;
public static final int Base_TextAppearance_AppCompat_Widget_Button_Borderless_Colored = 0x7f100038;
public static final int Base_TextAppearance_AppCompat_Widget_Button_Colored = 0x7f100039;
public static final int Base_TextAppearance_AppCompat_Widget_Button_Inverse = 0x7f10003a;
public static final int Base_TextAppearance_AppCompat_Widget_DropDownItem = 0x7f10003b;
public static final int Base_TextAppearance_AppCompat_Widget_PopupMenu_Header = 0x7f10003c;
public static final int Base_TextAppearance_AppCompat_Widget_PopupMenu_Large = 0x7f10003d;
public static final int Base_TextAppearance_AppCompat_Widget_PopupMenu_Small = 0x7f10003e;
public static final int Base_TextAppearance_AppCompat_Widget_Switch = 0x7f10003f;
public static final int Base_TextAppearance_AppCompat_Widget_TextView_SpinnerItem = 0x7f100040;
public static final int Base_TextAppearance_Widget_AppCompat_ExpandedMenu_Item = 0x7f100045;
public static final int Base_TextAppearance_Widget_AppCompat_Toolbar_Subtitle = 0x7f100046;
public static final int Base_TextAppearance_Widget_AppCompat_Toolbar_Title = 0x7f100047;
public static final int Base_ThemeOverlay_AppCompat = 0x7f100069;
public static final int Base_ThemeOverlay_AppCompat_ActionBar = 0x7f10006a;
public static final int Base_ThemeOverlay_AppCompat_Dark = 0x7f10006b;
public static final int Base_ThemeOverlay_AppCompat_Dark_ActionBar = 0x7f10006c;
public static final int Base_ThemeOverlay_AppCompat_Dialog = 0x7f10006d;
public static final int Base_ThemeOverlay_AppCompat_Dialog_Alert = 0x7f10006e;
public static final int Base_ThemeOverlay_AppCompat_Light = 0x7f10006f;
public static final int Base_Theme_AppCompat = 0x7f100048;
public static final int Base_Theme_AppCompat_CompactMenu = 0x7f100049;
public static final int Base_Theme_AppCompat_Dialog = 0x7f10004a;
public static final int Base_Theme_AppCompat_DialogWhenLarge = 0x7f10004e;
public static final int Base_Theme_AppCompat_Dialog_Alert = 0x7f10004b;
public static final int Base_Theme_AppCompat_Dialog_FixedSize = 0x7f10004c;
public static final int Base_Theme_AppCompat_Dialog_MinWidth = 0x7f10004d;
public static final int Base_Theme_AppCompat_Light = 0x7f10004f;
public static final int Base_Theme_AppCompat_Light_DarkActionBar = 0x7f100050;
public static final int Base_Theme_AppCompat_Light_Dialog = 0x7f100051;
public static final int Base_Theme_AppCompat_Light_DialogWhenLarge = 0x7f100055;
public static final int Base_Theme_AppCompat_Light_Dialog_Alert = 0x7f100052;
public static final int Base_Theme_AppCompat_Light_Dialog_FixedSize = 0x7f100053;
public static final int Base_Theme_AppCompat_Light_Dialog_MinWidth = 0x7f100054;
public static final int Base_V21_ThemeOverlay_AppCompat_Dialog = 0x7f100083;
public static final int Base_V21_Theme_AppCompat = 0x7f10007f;
public static final int Base_V21_Theme_AppCompat_Dialog = 0x7f100080;
public static final int Base_V21_Theme_AppCompat_Light = 0x7f100081;
public static final int Base_V21_Theme_AppCompat_Light_Dialog = 0x7f100082;
public static final int Base_V22_Theme_AppCompat = 0x7f100084;
public static final int Base_V22_Theme_AppCompat_Light = 0x7f100085;
public static final int Base_V23_Theme_AppCompat = 0x7f100086;
public static final int Base_V23_Theme_AppCompat_Light = 0x7f100087;
public static final int Base_V26_Theme_AppCompat = 0x7f100088;
public static final int Base_V26_Theme_AppCompat_Light = 0x7f100089;
public static final int Base_V26_Widget_AppCompat_Toolbar = 0x7f10008a;
public static final int Base_V28_Theme_AppCompat = 0x7f10008b;
public static final int Base_V28_Theme_AppCompat_Light = 0x7f10008c;
public static final int Base_V7_ThemeOverlay_AppCompat_Dialog = 0x7f100091;
public static final int Base_V7_Theme_AppCompat = 0x7f10008d;
public static final int Base_V7_Theme_AppCompat_Dialog = 0x7f10008e;
public static final int Base_V7_Theme_AppCompat_Light = 0x7f10008f;
public static final int Base_V7_Theme_AppCompat_Light_Dialog = 0x7f100090;
public static final int Base_V7_Widget_AppCompat_AutoCompleteTextView = 0x7f100092;
public static final int Base_V7_Widget_AppCompat_EditText = 0x7f100093;
public static final int Base_V7_Widget_AppCompat_Toolbar = 0x7f100094;
public static final int Base_Widget_AppCompat_ActionBar = 0x7f100095;
public static final int Base_Widget_AppCompat_ActionBar_Solid = 0x7f100096;
public static final int Base_Widget_AppCompat_ActionBar_TabBar = 0x7f100097;
public static final int Base_Widget_AppCompat_ActionBar_TabText = 0x7f100098;
public static final int Base_Widget_AppCompat_ActionBar_TabView = 0x7f100099;
public static final int Base_Widget_AppCompat_ActionButton = 0x7f10009a;
public static final int Base_Widget_AppCompat_ActionButton_CloseMode = 0x7f10009b;
public static final int Base_Widget_AppCompat_ActionButton_Overflow = 0x7f10009c;
public static final int Base_Widget_AppCompat_ActionMode = 0x7f10009d;
public static final int Base_Widget_AppCompat_ActivityChooserView = 0x7f10009e;
public static final int Base_Widget_AppCompat_AutoCompleteTextView = 0x7f10009f;
public static final int Base_Widget_AppCompat_Button = 0x7f1000a0;
public static final int Base_Widget_AppCompat_ButtonBar = 0x7f1000a6;
public static final int Base_Widget_AppCompat_ButtonBar_AlertDialog = 0x7f1000a7;
public static final int Base_Widget_AppCompat_Button_Borderless = 0x7f1000a1;
public static final int Base_Widget_AppCompat_Button_Borderless_Colored = 0x7f1000a2;
public static final int Base_Widget_AppCompat_Button_ButtonBar_AlertDialog = 0x7f1000a3;
public static final int Base_Widget_AppCompat_Button_Colored = 0x7f1000a4;
public static final int Base_Widget_AppCompat_Button_Small = 0x7f1000a5;
public static final int Base_Widget_AppCompat_CompoundButton_CheckBox = 0x7f1000a8;
public static final int Base_Widget_AppCompat_CompoundButton_RadioButton = 0x7f1000a9;
public static final int Base_Widget_AppCompat_CompoundButton_Switch = 0x7f1000aa;
public static final int Base_Widget_AppCompat_DrawerArrowToggle = 0x7f1000ab;
public static final int Base_Widget_AppCompat_DrawerArrowToggle_Common = 0x7f1000ac;
public static final int Base_Widget_AppCompat_DropDownItem_Spinner = 0x7f1000ad;
public static final int Base_Widget_AppCompat_EditText = 0x7f1000ae;
public static final int Base_Widget_AppCompat_ImageButton = 0x7f1000af;
public static final int Base_Widget_AppCompat_Light_ActionBar = 0x7f1000b0;
public static final int Base_Widget_AppCompat_Light_ActionBar_Solid = 0x7f1000b1;
public static final int Base_Widget_AppCompat_Light_ActionBar_TabBar = 0x7f1000b2;
public static final int Base_Widget_AppCompat_Light_ActionBar_TabText = 0x7f1000b3;
public static final int Base_Widget_AppCompat_Light_ActionBar_TabText_Inverse = 0x7f1000b4;
public static final int Base_Widget_AppCompat_Light_ActionBar_TabView = 0x7f1000b5;
public static final int Base_Widget_AppCompat_Light_PopupMenu = 0x7f1000b6;
public static final int Base_Widget_AppCompat_Light_PopupMenu_Overflow = 0x7f1000b7;
public static final int Base_Widget_AppCompat_ListMenuView = 0x7f1000b8;
public static final int Base_Widget_AppCompat_ListPopupWindow = 0x7f1000b9;
public static final int Base_Widget_AppCompat_ListView = 0x7f1000ba;
public static final int Base_Widget_AppCompat_ListView_DropDown = 0x7f1000bb;
public static final int Base_Widget_AppCompat_ListView_Menu = 0x7f1000bc;
public static final int Base_Widget_AppCompat_PopupMenu = 0x7f1000bd;
public static final int Base_Widget_AppCompat_PopupMenu_Overflow = 0x7f1000be;
public static final int Base_Widget_AppCompat_PopupWindow = 0x7f1000bf;
public static final int Base_Widget_AppCompat_ProgressBar = 0x7f1000c0;
public static final int Base_Widget_AppCompat_ProgressBar_Horizontal = 0x7f1000c1;
public static final int Base_Widget_AppCompat_RatingBar = 0x7f1000c2;
public static final int Base_Widget_AppCompat_RatingBar_Indicator = 0x7f1000c3;
public static final int Base_Widget_AppCompat_RatingBar_Small = 0x7f1000c4;
public static final int Base_Widget_AppCompat_SearchView = 0x7f1000c5;
public static final int Base_Widget_AppCompat_SearchView_ActionBar = 0x7f1000c6;
public static final int Base_Widget_AppCompat_SeekBar = 0x7f1000c7;
public static final int Base_Widget_AppCompat_SeekBar_Discrete = 0x7f1000c8;
public static final int Base_Widget_AppCompat_Spinner = 0x7f1000c9;
public static final int Base_Widget_AppCompat_Spinner_Underlined = 0x7f1000ca;
public static final int Base_Widget_AppCompat_TextView = 0x7f1000cb;
public static final int Base_Widget_AppCompat_TextView_SpinnerItem = 0x7f1000cc;
public static final int Base_Widget_AppCompat_Toolbar = 0x7f1000cd;
public static final int Base_Widget_AppCompat_Toolbar_Button_Navigation = 0x7f1000ce;
public static final int Platform_AppCompat = 0x7f1000ee;
public static final int Platform_AppCompat_Light = 0x7f1000ef;
public static final int Platform_ThemeOverlay_AppCompat = 0x7f1000f4;
public static final int Platform_ThemeOverlay_AppCompat_Dark = 0x7f1000f5;
public static final int Platform_ThemeOverlay_AppCompat_Light = 0x7f1000f6;
public static final int Platform_V21_AppCompat = 0x7f1000f7;
public static final int Platform_V21_AppCompat_Light = 0x7f1000f8;
public static final int Platform_V25_AppCompat = 0x7f1000f9;
public static final int Platform_V25_AppCompat_Light = 0x7f1000fa;
public static final int Platform_Widget_AppCompat_Spinner = 0x7f1000fb;
public static final int RtlOverlay_DialogWindowTitle_AppCompat = 0x7f1000fc;
public static final int RtlOverlay_Widget_AppCompat_ActionBar_TitleItem = 0x7f1000fd;
public static final int RtlOverlay_Widget_AppCompat_DialogTitle_Icon = 0x7f1000fe;
public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem = 0x7f1000ff;
public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem_InternalGroup = 0x7f100100;
public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem_Shortcut = 0x7f100101;
public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem_SubmenuArrow = 0x7f100102;
public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem_Text = 0x7f100103;
public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem_Title = 0x7f100104;
public static final int RtlOverlay_Widget_AppCompat_SearchView_MagIcon = 0x7f10010a;
public static final int RtlOverlay_Widget_AppCompat_Search_DropDown = 0x7f100105;
public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Icon1 = 0x7f100106;
public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Icon2 = 0x7f100107;
public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Query = 0x7f100108;
public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Text = 0x7f100109;
public static final int RtlUnderlay_Widget_AppCompat_ActionButton = 0x7f10010b;
public static final int RtlUnderlay_Widget_AppCompat_ActionButton_Overflow = 0x7f10010c;
public static final int TextAppearance_AppCompat = 0x7f100131;
public static final int TextAppearance_AppCompat_Body1 = 0x7f100132;
public static final int TextAppearance_AppCompat_Body2 = 0x7f100133;
public static final int TextAppearance_AppCompat_Button = 0x7f100134;
public static final int TextAppearance_AppCompat_Caption = 0x7f100135;
public static final int TextAppearance_AppCompat_Display1 = 0x7f100136;
public static final int TextAppearance_AppCompat_Display2 = 0x7f100137;
public static final int TextAppearance_AppCompat_Display3 = 0x7f100138;
public static final int TextAppearance_AppCompat_Display4 = 0x7f100139;
public static final int TextAppearance_AppCompat_Headline = 0x7f10013a;
public static final int TextAppearance_AppCompat_Inverse = 0x7f10013b;
public static final int TextAppearance_AppCompat_Large = 0x7f10013c;
public static final int TextAppearance_AppCompat_Large_Inverse = 0x7f10013d;
public static final int TextAppearance_AppCompat_Light_SearchResult_Subtitle = 0x7f10013e;
public static final int TextAppearance_AppCompat_Light_SearchResult_Title = 0x7f10013f;
public static final int TextAppearance_AppCompat_Light_Widget_PopupMenu_Large = 0x7f100140;
public static final int TextAppearance_AppCompat_Light_Widget_PopupMenu_Small = 0x7f100141;
public static final int TextAppearance_AppCompat_Medium = 0x7f100142;
public static final int TextAppearance_AppCompat_Medium_Inverse = 0x7f100143;
public static final int TextAppearance_AppCompat_Menu = 0x7f100144;
public static final int TextAppearance_AppCompat_SearchResult_Subtitle = 0x7f100145;
public static final int TextAppearance_AppCompat_SearchResult_Title = 0x7f100146;
public static final int TextAppearance_AppCompat_Small = 0x7f100147;
public static final int TextAppearance_AppCompat_Small_Inverse = 0x7f100148;
public static final int TextAppearance_AppCompat_Subhead = 0x7f100149;
public static final int TextAppearance_AppCompat_Subhead_Inverse = 0x7f10014a;
public static final int TextAppearance_AppCompat_Title = 0x7f10014b;
public static final int TextAppearance_AppCompat_Title_Inverse = 0x7f10014c;
public static final int TextAppearance_AppCompat_Tooltip = 0x7f10014d;
public static final int TextAppearance_AppCompat_Widget_ActionBar_Menu = 0x7f10014e;
public static final int TextAppearance_AppCompat_Widget_ActionBar_Subtitle = 0x7f10014f;
public static final int TextAppearance_AppCompat_Widget_ActionBar_Subtitle_Inverse = 0x7f100150;
public static final int TextAppearance_AppCompat_Widget_ActionBar_Title = 0x7f100151;
public static final int TextAppearance_AppCompat_Widget_ActionBar_Title_Inverse = 0x7f100152;
public static final int TextAppearance_AppCompat_Widget_ActionMode_Subtitle = 0x7f100153;
public static final int TextAppearance_AppCompat_Widget_ActionMode_Subtitle_Inverse = 0x7f100154;
public static final int TextAppearance_AppCompat_Widget_ActionMode_Title = 0x7f100155;
public static final int TextAppearance_AppCompat_Widget_ActionMode_Title_Inverse = 0x7f100156;
public static final int TextAppearance_AppCompat_Widget_Button = 0x7f100157;
public static final int TextAppearance_AppCompat_Widget_Button_Borderless_Colored = 0x7f100158;
public static final int TextAppearance_AppCompat_Widget_Button_Colored = 0x7f100159;
public static final int TextAppearance_AppCompat_Widget_Button_Inverse = 0x7f10015a;
public static final int TextAppearance_AppCompat_Widget_DropDownItem = 0x7f10015b;
public static final int TextAppearance_AppCompat_Widget_PopupMenu_Header = 0x7f10015c;
public static final int TextAppearance_AppCompat_Widget_PopupMenu_Large = 0x7f10015d;
public static final int TextAppearance_AppCompat_Widget_PopupMenu_Small = 0x7f10015e;
public static final int TextAppearance_AppCompat_Widget_Switch = 0x7f10015f;
public static final int TextAppearance_AppCompat_Widget_TextView_SpinnerItem = 0x7f100160;
public static final int TextAppearance_Compat_Notification = 0x7f100161;
public static final int TextAppearance_Compat_Notification_Info = 0x7f100162;
public static final int TextAppearance_Compat_Notification_Line2 = 0x7f100164;
public static final int TextAppearance_Compat_Notification_Time = 0x7f100167;
public static final int TextAppearance_Compat_Notification_Title = 0x7f100169;
public static final int TextAppearance_Widget_AppCompat_ExpandedMenu_Item = 0x7f100182;
public static final int TextAppearance_Widget_AppCompat_Toolbar_Subtitle = 0x7f100183;
public static final int TextAppearance_Widget_AppCompat_Toolbar_Title = 0x7f100184;
public static final int ThemeOverlay_AppCompat = 0x7f1001d9;
public static final int ThemeOverlay_AppCompat_ActionBar = 0x7f1001da;
public static final int ThemeOverlay_AppCompat_Dark = 0x7f1001db;
public static final int ThemeOverlay_AppCompat_Dark_ActionBar = 0x7f1001dc;
public static final int ThemeOverlay_AppCompat_DayNight = 0x7f1001dd;
public static final int ThemeOverlay_AppCompat_DayNight_ActionBar = 0x7f1001de;
public static final int ThemeOverlay_AppCompat_Dialog = 0x7f1001df;
public static final int ThemeOverlay_AppCompat_Dialog_Alert = 0x7f1001e0;
public static final int ThemeOverlay_AppCompat_Light = 0x7f1001e1;
public static final int Theme_AppCompat = 0x7f100186;
public static final int Theme_AppCompat_CompactMenu = 0x7f100187;
public static final int Theme_AppCompat_DayNight = 0x7f100188;
public static final int Theme_AppCompat_DayNight_DarkActionBar = 0x7f100189;
public static final int Theme_AppCompat_DayNight_Dialog = 0x7f10018a;
public static final int Theme_AppCompat_DayNight_DialogWhenLarge = 0x7f10018d;
public static final int Theme_AppCompat_DayNight_Dialog_Alert = 0x7f10018b;
public static final int Theme_AppCompat_DayNight_Dialog_MinWidth = 0x7f10018c;
public static final int Theme_AppCompat_DayNight_NoActionBar = 0x7f10018e;
public static final int Theme_AppCompat_Dialog = 0x7f10018f;
public static final int Theme_AppCompat_DialogWhenLarge = 0x7f100192;
public static final int Theme_AppCompat_Dialog_Alert = 0x7f100190;
public static final int Theme_AppCompat_Dialog_MinWidth = 0x7f100191;
public static final int Theme_AppCompat_Light = 0x7f100193;
public static final int Theme_AppCompat_Light_DarkActionBar = 0x7f100194;
public static final int Theme_AppCompat_Light_Dialog = 0x7f100195;
public static final int Theme_AppCompat_Light_DialogWhenLarge = 0x7f100198;
public static final int Theme_AppCompat_Light_Dialog_Alert = 0x7f100196;
public static final int Theme_AppCompat_Light_Dialog_MinWidth = 0x7f100197;
public static final int Theme_AppCompat_Light_NoActionBar = 0x7f100199;
public static final int Theme_AppCompat_NoActionBar = 0x7f10019a;
public static final int Widget_AppCompat_ActionBar = 0x7f100206;
public static final int Widget_AppCompat_ActionBar_Solid = 0x7f100207;
public static final int Widget_AppCompat_ActionBar_TabBar = 0x7f100208;
public static final int Widget_AppCompat_ActionBar_TabText = 0x7f100209;
public static final int Widget_AppCompat_ActionBar_TabView = 0x7f10020a;
public static final int Widget_AppCompat_ActionButton = 0x7f10020b;
public static final int Widget_AppCompat_ActionButton_CloseMode = 0x7f10020c;
public static final int Widget_AppCompat_ActionButton_Overflow = 0x7f10020d;
public static final int Widget_AppCompat_ActionMode = 0x7f10020e;
public static final int Widget_AppCompat_ActivityChooserView = 0x7f10020f;
public static final int Widget_AppCompat_AutoCompleteTextView = 0x7f100210;
public static final int Widget_AppCompat_Button = 0x7f100211;
public static final int Widget_AppCompat_ButtonBar = 0x7f100217;
public static final int Widget_AppCompat_ButtonBar_AlertDialog = 0x7f100218;
public static final int Widget_AppCompat_Button_Borderless = 0x7f100212;
public static final int Widget_AppCompat_Button_Borderless_Colored = 0x7f100213;
public static final int Widget_AppCompat_Button_ButtonBar_AlertDialog = 0x7f100214;
public static final int Widget_AppCompat_Button_Colored = 0x7f100215;
public static final int Widget_AppCompat_Button_Small = 0x7f100216;
public static final int Widget_AppCompat_CompoundButton_CheckBox = 0x7f100219;
public static final int Widget_AppCompat_CompoundButton_RadioButton = 0x7f10021a;
public static final int Widget_AppCompat_CompoundButton_Switch = 0x7f10021b;
public static final int Widget_AppCompat_DrawerArrowToggle = 0x7f10021c;
public static final int Widget_AppCompat_DropDownItem_Spinner = 0x7f10021d;
public static final int Widget_AppCompat_EditText = 0x7f10021e;
public static final int Widget_AppCompat_ImageButton = 0x7f10021f;
public static final int Widget_AppCompat_Light_ActionBar = 0x7f100220;
public static final int Widget_AppCompat_Light_ActionBar_Solid = 0x7f100221;
public static final int Widget_AppCompat_Light_ActionBar_Solid_Inverse = 0x7f100222;
public static final int Widget_AppCompat_Light_ActionBar_TabBar = 0x7f100223;
public static final int Widget_AppCompat_Light_ActionBar_TabBar_Inverse = 0x7f100224;
public static final int Widget_AppCompat_Light_ActionBar_TabText = 0x7f100225;
public static final int Widget_AppCompat_Light_ActionBar_TabText_Inverse = 0x7f100226;
public static final int Widget_AppCompat_Light_ActionBar_TabView = 0x7f100227;
public static final int Widget_AppCompat_Light_ActionBar_TabView_Inverse = 0x7f100228;
public static final int Widget_AppCompat_Light_ActionButton = 0x7f100229;
public static final int Widget_AppCompat_Light_ActionButton_CloseMode = 0x7f10022a;
public static final int Widget_AppCompat_Light_ActionButton_Overflow = 0x7f10022b;
public static final int Widget_AppCompat_Light_ActionMode_Inverse = 0x7f10022c;
public static final int Widget_AppCompat_Light_ActivityChooserView = 0x7f10022d;
public static final int Widget_AppCompat_Light_AutoCompleteTextView = 0x7f10022e;
public static final int Widget_AppCompat_Light_DropDownItem_Spinner = 0x7f10022f;
public static final int Widget_AppCompat_Light_ListPopupWindow = 0x7f100230;
public static final int Widget_AppCompat_Light_ListView_DropDown = 0x7f100231;
public static final int Widget_AppCompat_Light_PopupMenu = 0x7f100232;
public static final int Widget_AppCompat_Light_PopupMenu_Overflow = 0x7f100233;
public static final int Widget_AppCompat_Light_SearchView = 0x7f100234;
public static final int Widget_AppCompat_Light_Spinner_DropDown_ActionBar = 0x7f100235;
public static final int Widget_AppCompat_ListMenuView = 0x7f100236;
public static final int Widget_AppCompat_ListPopupWindow = 0x7f100237;
public static final int Widget_AppCompat_ListView = 0x7f100238;
public static final int Widget_AppCompat_ListView_DropDown = 0x7f100239;
public static final int Widget_AppCompat_ListView_Menu = 0x7f10023a;
public static final int Widget_AppCompat_PopupMenu = 0x7f10023b;
public static final int Widget_AppCompat_PopupMenu_Overflow = 0x7f10023c;
public static final int Widget_AppCompat_PopupWindow = 0x7f10023d;
public static final int Widget_AppCompat_ProgressBar = 0x7f10023e;
public static final int Widget_AppCompat_ProgressBar_Horizontal = 0x7f10023f;
public static final int Widget_AppCompat_RatingBar = 0x7f100240;
public static final int Widget_AppCompat_RatingBar_Indicator = 0x7f100241;
public static final int Widget_AppCompat_RatingBar_Small = 0x7f100242;
public static final int Widget_AppCompat_SearchView = 0x7f100243;
public static final int Widget_AppCompat_SearchView_ActionBar = 0x7f100244;
public static final int Widget_AppCompat_SeekBar = 0x7f100245;
public static final int Widget_AppCompat_SeekBar_Discrete = 0x7f100246;
public static final int Widget_AppCompat_Spinner = 0x7f100247;
public static final int Widget_AppCompat_Spinner_DropDown = 0x7f100248;
public static final int Widget_AppCompat_Spinner_DropDown_ActionBar = 0x7f100249;
public static final int Widget_AppCompat_Spinner_Underlined = 0x7f10024a;
public static final int Widget_AppCompat_TextView = 0x7f10024b;
public static final int Widget_AppCompat_TextView_SpinnerItem = 0x7f10024c;
public static final int Widget_AppCompat_Toolbar = 0x7f10024d;
public static final int Widget_AppCompat_Toolbar_Button_Navigation = 0x7f10024e;
public static final int Widget_Compat_NotificationActionContainer = 0x7f10024f;
public static final int Widget_Compat_NotificationActionText = 0x7f100250;
public static final int ucrop_ImageViewWidgetIcon = 0x7f1002b9;
public static final int ucrop_TextViewCropAspectRatio = 0x7f1002ba;
public static final int ucrop_TextViewWidget = 0x7f1002bb;
public static final int ucrop_TextViewWidgetText = 0x7f1002bc;
public static final int ucrop_WrapperIconState = 0x7f1002bd;
public static final int ucrop_WrapperRotateButton = 0x7f1002be;
}
public static final class styleable {
private styleable() {}
public static final int[] ActionBar = { 0x7f030037, 0x7f03003f, 0x7f030040, 0x7f0300b6, 0x7f0300b7, 0x7f0300b8, 0x7f0300b9, 0x7f0300ba, 0x7f0300bb, 0x7f0300d5, 0x7f0300de, 0x7f0300df, 0x7f0300f2, 0x7f03012f, 0x7f030135, 0x7f03013b, 0x7f03013c, 0x7f03013e, 0x7f030148, 0x7f030155, 0x7f030187, 0x7f0301a7, 0x7f0301bd, 0x7f0301c5, 0x7f0301c6, 0x7f030213, 0x7f030216, 0x7f03025e, 0x7f030268 };
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 = { 0x7f030037, 0x7f03003f, 0x7f030099, 0x7f03012f, 0x7f030216, 0x7f030268 };
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 = { 0x7f030104, 0x7f030149 };
public static final int ActivityChooserView_expandActivityOverflowButtonDrawable = 0;
public static final int ActivityChooserView_initialActivityCount = 1;
public static final int[] AlertDialog = { 0x10100f2, 0x7f030068, 0x7f030069, 0x7f03017c, 0x7f03017d, 0x7f0301a4, 0x7f0301f3, 0x7f0301f5 };
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, 0x7f0301ff, 0x7f03025c, 0x7f03025d };
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, 0x7f030259, 0x7f03025a, 0x7f03025b };
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, 0x7f030032, 0x7f030033, 0x7f030034, 0x7f030035, 0x7f030036, 0x7f0300e3, 0x7f0300e4, 0x7f0300e5, 0x7f0300e6, 0x7f0300e8, 0x7f0300e9, 0x7f0300ea, 0x7f0300eb, 0x7f03011e, 0x7f030121, 0x7f030129, 0x7f030167, 0x7f030176, 0x7f030236, 0x7f030251 };
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_drawableBottomCompat = 6;
public static final int AppCompatTextView_drawableEndCompat = 7;
public static final int AppCompatTextView_drawableLeftCompat = 8;
public static final int AppCompatTextView_drawableRightCompat = 9;
public static final int AppCompatTextView_drawableStartCompat = 10;
public static final int AppCompatTextView_drawableTint = 11;
public static final int AppCompatTextView_drawableTintMode = 12;
public static final int AppCompatTextView_drawableTopCompat = 13;
public static final int AppCompatTextView_firstBaselineToTopHeight = 14;
public static final int AppCompatTextView_fontFamily = 15;
public static final int AppCompatTextView_fontVariationSettings = 16;
public static final int AppCompatTextView_lastBaselineToBottomHeight = 17;
public static final int AppCompatTextView_lineHeight = 18;
public static final int AppCompatTextView_textAllCaps = 19;
public static final int AppCompatTextView_textLocale = 20;
public static final int[] AppCompatTheme = { 0x1010057, 0x10100ae, 0x7f030000, 0x7f030001, 0x7f030002, 0x7f030003, 0x7f030004, 0x7f030005, 0x7f030006, 0x7f030007, 0x7f030008, 0x7f030009, 0x7f03000a, 0x7f03000b, 0x7f03000c, 0x7f03000e, 0x7f03000f, 0x7f030010, 0x7f030011, 0x7f030012, 0x7f030013, 0x7f030014, 0x7f030015, 0x7f030016, 0x7f030017, 0x7f030018, 0x7f030019, 0x7f03001a, 0x7f03001b, 0x7f03001c, 0x7f03001d, 0x7f03001e, 0x7f030022, 0x7f030026, 0x7f030027, 0x7f030028, 0x7f030029, 0x7f030031, 0x7f030052, 0x7f030061, 0x7f030062, 0x7f030063, 0x7f030064, 0x7f030065, 0x7f03006a, 0x7f03006b, 0x7f030076, 0x7f03007d, 0x7f03009f, 0x7f0300a0, 0x7f0300a1, 0x7f0300a2, 0x7f0300a3, 0x7f0300a4, 0x7f0300a5, 0x7f0300ac, 0x7f0300ad, 0x7f0300b3, 0x7f0300c2, 0x7f0300db, 0x7f0300dc, 0x7f0300dd, 0x7f0300e0, 0x7f0300e2, 0x7f0300ed, 0x7f0300ee, 0x7f0300ef, 0x7f0300f0, 0x7f0300f1, 0x7f03013b, 0x7f030147, 0x7f030178, 0x7f030179, 0x7f03017a, 0x7f03017b, 0x7f03017e, 0x7f03017f, 0x7f030180, 0x7f030181, 0x7f030182, 0x7f030183, 0x7f030184, 0x7f030185, 0x7f030186, 0x7f0301b1, 0x7f0301b2, 0x7f0301b3, 0x7f0301bc, 0x7f0301be, 0x7f0301c9, 0x7f0301cb, 0x7f0301cc, 0x7f0301cd, 0x7f0301e6, 0x7f0301e7, 0x7f0301e8, 0x7f0301e9, 0x7f0301fc, 0x7f0301fd, 0x7f03021a, 0x7f030241, 0x7f030243, 0x7f030244, 0x7f030245, 0x7f030247, 0x7f030248, 0x7f030249, 0x7f03024a, 0x7f03024d, 0x7f03024e, 0x7f03026a, 0x7f03026b, 0x7f03026c, 0x7f03026d, 0x7f030286, 0x7f030288, 0x7f030289, 0x7f03028a, 0x7f03028b, 0x7f03028c, 0x7f03028d, 0x7f03028e, 0x7f03028f, 0x7f030290, 0x7f030291 };
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_listChoiceIndicatorMultipleAnimated = 72;
public static final int AppCompatTheme_listChoiceIndicatorSingleAnimated = 73;
public static final int AppCompatTheme_listDividerAlertDialog = 74;
public static final int AppCompatTheme_listMenuViewStyle = 75;
public static final int AppCompatTheme_listPopupWindowStyle = 76;
public static final int AppCompatTheme_listPreferredItemHeight = 77;
public static final int AppCompatTheme_listPreferredItemHeightLarge = 78;
public static final int AppCompatTheme_listPreferredItemHeightSmall = 79;
public static final int AppCompatTheme_listPreferredItemPaddingEnd = 80;
public static final int AppCompatTheme_listPreferredItemPaddingLeft = 81;
public static final int AppCompatTheme_listPreferredItemPaddingRight = 82;
public static final int AppCompatTheme_listPreferredItemPaddingStart = 83;
public static final int AppCompatTheme_panelBackground = 84;
public static final int AppCompatTheme_panelMenuListTheme = 85;
public static final int AppCompatTheme_panelMenuListWidth = 86;
public static final int AppCompatTheme_popupMenuStyle = 87;
public static final int AppCompatTheme_popupWindowStyle = 88;
public static final int AppCompatTheme_radioButtonStyle = 89;
public static final int AppCompatTheme_ratingBarStyle = 90;
public static final int AppCompatTheme_ratingBarStyleIndicator = 91;
public static final int AppCompatTheme_ratingBarStyleSmall = 92;
public static final int AppCompatTheme_searchViewStyle = 93;
public static final int AppCompatTheme_seekBarStyle = 94;
public static final int AppCompatTheme_selectableItemBackground = 95;
public static final int AppCompatTheme_selectableItemBackgroundBorderless = 96;
public static final int AppCompatTheme_spinnerDropDownItemStyle = 97;
public static final int AppCompatTheme_spinnerStyle = 98;
public static final int AppCompatTheme_switchStyle = 99;
public static final int AppCompatTheme_textAppearanceLargePopupMenu = 100;
public static final int AppCompatTheme_textAppearanceListItem = 101;
public static final int AppCompatTheme_textAppearanceListItemSecondary = 102;
public static final int AppCompatTheme_textAppearanceListItemSmall = 103;
public static final int AppCompatTheme_textAppearancePopupMenuHeader = 104;
public static final int AppCompatTheme_textAppearanceSearchResultSubtitle = 105;
public static final int AppCompatTheme_textAppearanceSearchResultTitle = 106;
public static final int AppCompatTheme_textAppearanceSmallPopupMenu = 107;
public static final int AppCompatTheme_textColorAlertDialogListItem = 108;
public static final int AppCompatTheme_textColorSearchUrl = 109;
public static final int AppCompatTheme_toolbarNavigationButtonStyle = 110;
public static final int AppCompatTheme_toolbarStyle = 111;
public static final int AppCompatTheme_tooltipForegroundColor = 112;
public static final int AppCompatTheme_tooltipFrameBackground = 113;
public static final int AppCompatTheme_viewInflaterClass = 114;
public static final int AppCompatTheme_windowActionBar = 115;
public static final int AppCompatTheme_windowActionBarOverlay = 116;
public static final int AppCompatTheme_windowActionModeOverlay = 117;
public static final int AppCompatTheme_windowFixedHeightMajor = 118;
public static final int AppCompatTheme_windowFixedHeightMinor = 119;
public static final int AppCompatTheme_windowFixedWidthMajor = 120;
public static final int AppCompatTheme_windowFixedWidthMinor = 121;
public static final int AppCompatTheme_windowMinWidthMajor = 122;
public static final int AppCompatTheme_windowMinWidthMinor = 123;
public static final int AppCompatTheme_windowNoTitle = 124;
public static final int[] ButtonBarLayout = { 0x7f03002a };
public static final int ButtonBarLayout_allowStacking = 0;
public static final int[] ColorStateListItem = { 0x10101a5, 0x101031f, 0x7f03002b };
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, 0x7f030066, 0x7f03006c, 0x7f03006d };
public static final int CompoundButton_android_button = 0;
public static final int CompoundButton_buttonCompat = 1;
public static final int CompoundButton_buttonTint = 2;
public static final int CompoundButton_buttonTintMode = 3;
public static final int[] DrawerArrowToggle = { 0x7f03002f, 0x7f030030, 0x7f030046, 0x7f03009e, 0x7f0300e7, 0x7f03012c, 0x7f0301fb, 0x7f030255 };
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 = { 0x7f030122, 0x7f030123, 0x7f030124, 0x7f030125, 0x7f030126, 0x7f030127 };
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, 0x7f030120, 0x7f030128, 0x7f030129, 0x7f03012a, 0x7f030272 };
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, 0x7f0300df, 0x7f0300e1, 0x7f0301a1, 0x7f0301f0 };
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, 0x7f03000d, 0x7f03001f, 0x7f030021, 0x7f03002c, 0x7f0300b5, 0x7f030144, 0x7f030145, 0x7f0301aa, 0x7f0301ef, 0x7f03026e };
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, 0x7f0301bf, 0x7f030211 };
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, 0x7f0301ab };
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 = { 0x7f030206 };
public static final int PopupWindowBackgroundState_state_above_anchor = 0;
public static final int[] RecycleListView = { 0x7f0301ad, 0x7f0301b0 };
public static final int RecycleListView_paddingBottomNoButtons = 0;
public static final int RecycleListView_paddingTopNoTitle = 1;
public static final int[] SearchView = { 0x10100da, 0x101011f, 0x1010220, 0x1010264, 0x7f030092, 0x7f0300b4, 0x7f0300da, 0x7f03012d, 0x7f030146, 0x7f030168, 0x7f0301c7, 0x7f0301c8, 0x7f0301e4, 0x7f0301e5, 0x7f030212, 0x7f030217, 0x7f030287 };
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, 0x7f0301bd };
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, 0x7f0301f2, 0x7f0301fe, 0x7f030218, 0x7f030219, 0x7f03021b, 0x7f030256, 0x7f030257, 0x7f030258, 0x7f03026f, 0x7f030270, 0x7f030271 };
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, 0x1010585, 0x7f030121, 0x7f030129, 0x7f030236, 0x7f030251 };
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_android_textFontWeight = 11;
public static final int TextAppearance_fontFamily = 12;
public static final int TextAppearance_fontVariationSettings = 13;
public static final int TextAppearance_textAllCaps = 14;
public static final int TextAppearance_textLocale = 15;
public static final int[] Toolbar = { 0x10100af, 0x1010140, 0x7f030067, 0x7f03009a, 0x7f03009b, 0x7f0300b6, 0x7f0300b7, 0x7f0300b8, 0x7f0300b9, 0x7f0300ba, 0x7f0300bb, 0x7f030187, 0x7f030188, 0x7f03019e, 0x7f0301a2, 0x7f0301a5, 0x7f0301a6, 0x7f0301bd, 0x7f030213, 0x7f030214, 0x7f030215, 0x7f03025e, 0x7f030260, 0x7f030261, 0x7f030262, 0x7f030263, 0x7f030264, 0x7f030265, 0x7f030266, 0x7f030267 };
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_menu = 14;
public static final int Toolbar_navigationContentDescription = 15;
public static final int Toolbar_navigationIcon = 16;
public static final int Toolbar_popupTheme = 17;
public static final int Toolbar_subtitle = 18;
public static final int Toolbar_subtitleTextAppearance = 19;
public static final int Toolbar_subtitleTextColor = 20;
public static final int Toolbar_title = 21;
public static final int Toolbar_titleMargin = 22;
public static final int Toolbar_titleMarginBottom = 23;
public static final int Toolbar_titleMarginEnd = 24;
public static final int Toolbar_titleMarginStart = 25;
public static final int Toolbar_titleMarginTop = 26;
public static final int Toolbar_titleMargins = 27;
public static final int Toolbar_titleTextAppearance = 28;
public static final int Toolbar_titleTextColor = 29;
public static final int[] View = { 0x1010000, 0x10100da, 0x7f0301ae, 0x7f0301af, 0x7f030253 };
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, 0x7f030041, 0x7f030042 };
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;
public static final int[] ucrop_AspectRatioTextView = { 0x7f030273, 0x7f030274, 0x7f030275 };
public static final int ucrop_AspectRatioTextView_ucrop_artv_ratio_title = 0;
public static final int ucrop_AspectRatioTextView_ucrop_artv_ratio_x = 1;
public static final int ucrop_AspectRatioTextView_ucrop_artv_ratio_y = 2;
public static final int[] ucrop_UCropView = { 0x7f030276, 0x7f030277, 0x7f030278, 0x7f030279, 0x7f03027a, 0x7f03027b, 0x7f03027c, 0x7f03027d, 0x7f03027e, 0x7f03027f, 0x7f030280, 0x7f030281, 0x7f030282 };
public static final int ucrop_UCropView_ucrop_aspect_ratio_x = 0;
public static final int ucrop_UCropView_ucrop_aspect_ratio_y = 1;
public static final int ucrop_UCropView_ucrop_circle_dimmed_layer = 2;
public static final int ucrop_UCropView_ucrop_dimmed_color = 3;
public static final int ucrop_UCropView_ucrop_frame_color = 4;
public static final int ucrop_UCropView_ucrop_frame_stroke_size = 5;
public static final int ucrop_UCropView_ucrop_grid_color = 6;
public static final int ucrop_UCropView_ucrop_grid_column_count = 7;
public static final int ucrop_UCropView_ucrop_grid_row_count = 8;
public static final int ucrop_UCropView_ucrop_grid_stroke_size = 9;
public static final int ucrop_UCropView_ucrop_show_frame = 10;
public static final int ucrop_UCropView_ucrop_show_grid = 11;
public static final int ucrop_UCropView_ucrop_show_oval_crop_frame = 12;
}
}
| [
"asadkkhan.net@gmail.com"
] | asadkkhan.net@gmail.com |
f2f680107dc1da964fbbcd5cf4edc728dde3676a | 9f69eb7de9968552877458f6b44b7b700d725683 | /app/src/main/java/com/app/greenttaxi/share/App.java | 224f788ab79e7c397f87f0ea79c3b61d5f730f71 | [] | no_license | MotawroonProjects/GreentTaxi | ae4e97c83922e5118c167142034ebd2fa40239b6 | 5a15a4956eb36f476c9fe6185e90b5ecf6a4ac9c | refs/heads/master | 2023-05-01T03:03:58.206869 | 2021-05-09T10:26:41 | 2021-05-09T10:26:41 | 365,695,370 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 784 | java | package com.app.greenttaxi.share;
import android.content.Context;
import androidx.multidex.MultiDexApplication;
import com.app.greenttaxi.language.Language;
public class App extends MultiDexApplication {
@Override
protected void attachBaseContext(Context newBase) {
super.attachBaseContext(Language.updateResources(newBase,"ar"));
}
@Override
public void onCreate() {
super.onCreate();
// TypefaceUtil.setDefaultFont(this, "DEFAULT", "fonts/Tajawal-Regular.ttf");
// TypefaceUtil.setDefaultFont(this, "MONOSPACE", "fonts/Tajawal-Regular.ttf");
// TypefaceUtil.setDefaultFont(this, "SERIF", "fonts/Tajawal-Regular.ttf");
// TypefaceUtil.setDefaultFont(this, "SANS_SERIF", "fonts/Tajawal-Regular.ttf");
}
}
| [
"ahmedmohamed23345@gmail.com"
] | ahmedmohamed23345@gmail.com |
327517bab7f043eb45e06049d45fe5e6bd120cb6 | 8142ebaaac633cbf94e2328a29f21e7b2d63181e | /src/main5.java | 5b7894a793a4b8cf59ee84211265e1dc44f7bdd5 | [] | no_license | lucasCoruqieri/aplicacao1-github | a5ce99b19aca300f65654bf51f0be090c1f9c010 | 53b128c4090c045953b7254494a47c306b8730bf | refs/heads/master | 2021-02-13T00:00:32.996271 | 2020-03-03T15:50:52 | 2020-03-03T15:50:52 | 244,644,063 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 462 | java | import java.util.Scanner;
public class main5 {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int x;
String s1, s2, s3;
x = sc.nextInt();
sc.nextLine();
s1 = sc.nextLine();
s2 = sc.nextLine();
s3 = sc.nextLine();
System.out.println("Valor das Strings:");
System.out.println(x);
System.out.println(s1);
System.out.println(s2);
System.out.println(s3);
sc.close();
}
}
| [
"lrcoruqieri@gmail.com"
] | lrcoruqieri@gmail.com |
ec8a9fa80a00be3f5da075a3e202a773ef0a79fc | 31710d8fc437302a342d2758ee6303c8f63da6ad | /STS_WS_Ecommerce/ecommerce/src/main/java/com/scs/ecommerce/EcommerceConfiguration.java | 23550127585f8557baee7ff5bda75e3f4acd8a08 | [] | no_license | chandrasekharsivaraju/DemoProject | 5fff97696b386e8657f9336f562d9917259cab36 | 767fc5b544874bceb068194dfea7b8d02556f19a | refs/heads/master | 2023-04-12T11:55:18.448006 | 2021-05-03T08:36:29 | 2021-05-03T08:36:29 | 363,835,709 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 188 | java | package com.scs.ecommerce;
import org.springframework.boot.autoconfigure.web.servlet.WebMvcAutoConfiguration;
public class EcommerceConfiguration extends WebMvcAutoConfiguration {
}
| [
"Chandrasekhar_Sivaraju@epam.com"
] | Chandrasekhar_Sivaraju@epam.com |
31ea320de74a34b30e2c7db571a3ce23d5121ec3 | d630f8cb8c7a625bd49b3168c0650b8b509b3009 | /app/src/main/java/com/arduino/blue/theglenn/arduinoblue/BlueAdapter.java | 233e4cfb729efc97865df70bbe65cdc44de1e091 | [] | no_license | theGlenn/Android-Bluetooth-Arduino | 1b5c6b3c348c5d82038dd41a7839d660e7af5788 | 4e7186cdc641bbcc83482a87b596512bcb0880de | refs/heads/master | 2021-01-01T05:40:49.479548 | 2015-03-02T16:18:38 | 2015-03-02T16:18:38 | 31,545,703 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,262 | java | package com.arduino.blue.theglenn.arduinoblue;
import android.bluetooth.BluetoothDevice;
import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ArrayAdapter;
import android.widget.TextView;
import java.util.ArrayList;
/**
* Created by theGlenn on 15/10/2014.
*/
public class BlueAdapter extends ArrayAdapter<BluetoothDevice> {
private final int layoutResourceId;
private ArrayList<BluetoothDevice> items;
private LayoutInflater inflater;
public BlueAdapter(Context context, int layoutResourceId, ArrayList<BluetoothDevice> items) {
super(context, layoutResourceId, items);
this.items = items;
this.layoutResourceId = layoutResourceId;
this.inflater = LayoutInflater.from(getContext());
}
public BlueAdapter(Context context, int layoutResourceId) {
super(context, layoutResourceId);
this.items = new ArrayList<BluetoothDevice>();
this.layoutResourceId = layoutResourceId;
this.inflater = LayoutInflater.from(getContext());
}
public ArrayList<BluetoothDevice> getItems() {
return items;
}
@Override
public BluetoothDevice getItem(int position) {
return items.get(position);
}
@Override
public void add(BluetoothDevice newDailyData) {
items.add(newDailyData);
notifyDataSetChanged();
}
@Override
public View getView(int position, View view, ViewGroup parent) {
ViewHolderDevice holder;
if (view != null) {
holder = (ViewHolderDevice) view.getTag();
} else {
view = inflater.inflate(layoutResourceId, parent, false);
holder = new ViewHolderDevice();
holder.textView1 = (TextView) view.findViewById(android.R.id.text1);
holder.textView2 = (TextView) view.findViewById(android.R.id.text2);
view.setTag(holder);
}
BluetoothDevice bd = getItem(position);
holder.textView1.setText(bd.getName());
holder.textView2.setText(bd.getAddress());
return view;
}
static class ViewHolderDevice {
TextView textView1;
TextView textView2;
}
}
| [
"kenpachi.os@gmail.com"
] | kenpachi.os@gmail.com |
1bc85906b9b0e987a1a903606b8513985d59bc88 | b103694371be3fca5358dd142453e1754d327389 | /sdk/src/androidTest/java/org/dpppt/android/sdk/internal/CryptoBenchmark.java | b1af78473c6d421c40d715e3b919016a0a4ca4f4 | [] | no_license | fynngodau/dp3t-sdk-android-sdkonly | 247085cbfdbfa48b5932625f6ffe33aa106e9c93 | 37a67846358f562a8b8f4a50280f1b5500cd6bbb | refs/heads/master | 2022-04-19T11:13:19.938502 | 2020-04-22T18:44:47 | 2020-04-22T18:44:47 | 257,989,066 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,793 | java | /*
* Created by Ubique Innovation AG
* https://www.ubique.ch
* Copyright (c) 2020. All rights reserved.
*/
package org.dpppt.android.sdk.internal;
import androidx.benchmark.BenchmarkState;
import androidx.benchmark.junit4.BenchmarkRule;
import androidx.test.ext.junit.runners.AndroidJUnit4;
import androidx.test.platform.app.InstrumentationRegistry;
import java.util.ArrayList;
import org.dpppt.android.sdk.internal.crypto.CryptoModule;
import org.dpppt.android.sdk.internal.crypto.EphId;
import org.dpppt.android.sdk.internal.database.models.Contact;
import org.dpppt.android.sdk.internal.util.DayDate;
import org.junit.Rule;
import org.junit.Test;
import org.junit.runner.RunWith;
@RunWith(AndroidJUnit4.class)
public class CryptoBenchmark {
private static final int NUMBER_OF_DAYS_TO_TEST = 5;
private static final int NUMBER_OF_CONTACTS_PER_DAY = 50;
@Rule
public BenchmarkRule benchmarkRule = new BenchmarkRule();
@Test
public void key_matching_performance() {
final BenchmarkState state = benchmarkRule.getState();
CryptoModule module = CryptoModule.getInstance(InstrumentationRegistry.getInstrumentation().getContext());
module.reset();
if (module.init()) {
int i = 0;
while (state.keepRunning()) {
String key = "much longer key which is used for the hash functino but this should not have an influence" +
Integer.toHexString(i);
module.checkContacts(key.getBytes(), new DayDate().subtractDays(NUMBER_OF_DAYS_TO_TEST), new DayDate(), (date -> {
ArrayList<Contact> contacts = new ArrayList<>();
for (int x = 0; x < NUMBER_OF_CONTACTS_PER_DAY; x++) {
contacts.add(new Contact(0, new DayDate(), new EphId(new byte[CryptoModule.KEY_LENGTH]), 0));
}
return contacts;
}), (contact -> {}));
i += 1;
}
}
}
}
| [
"fynngodau@mailbox.org"
] | fynngodau@mailbox.org |
dbd02124045c841c2dc0eeac59cadda34d4145c0 | 894a7b56c21ca3ac63af7dbe17dfb365907a2d96 | /provider-server/src/main/java/com/yang/service/TicketService.java | 20b0579631091818f8a94190145fa9a9635758bf | [] | no_license | yangzhao1201/springboot-06-zookeeper-dubbo | b9aa41189a976bd9052e2ccc3fb0849a91f11994 | 5c7d496569ba158ee075ca7ad022aac08f6d4792 | refs/heads/master | 2023-05-10T00:00:54.821298 | 2021-06-08T21:55:57 | 2021-06-08T21:55:57 | 375,154,961 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 168 | java | package com.yang.service;
/**
* @author TangYuan
* @create 2021--06--08--19:40
* @description
*/
public interface TicketService {
public String getTicket();
}
| [
"yangzhao1201@gmail.com"
] | yangzhao1201@gmail.com |
5633b055b2420890e191b031cd914a368f7985c9 | fd21afe6dd48600ad48699601f8d579dc3366f51 | /cdb/core/src/main/java/com/excilys/formation/java/cdb/model/CompaniePage.java | aa46997c641923172db5eb756e881b54fab9a93b | [] | no_license | joachimbocaz/computer-database | 86a73c7bd976600de41b708d3e6cfb8ce1a83487 | 3979b786c3cbd1db6d555a70b70b792c5f3f82f4 | refs/heads/master | 2022-11-23T08:55:21.103791 | 2020-07-29T10:18:26 | 2020-07-29T10:18:26 | 272,378,347 | 0 | 0 | null | 2020-07-29T10:18:28 | 2020-06-15T08:05:28 | Java | UTF-8 | Java | false | false | 689 | java | package com.excilys.formation.java.cdb.model;
import java.util.List;
public class CompaniePage extends Page<Companie>{
public CompaniePage() {
}
public CompaniePage(int numPage) {
super(numPage);
}
@Override
public List<Companie> findAllEntity(String column, String order) {
// List<Companie> compagnieList = new ArrayList<Companie>();
// Dao<Companie> companieDao = new CompanieDao();
// compagnieList = companieDao.findAllLimite(this.getNbElementByPage(), this.getOffSet());
// this.setEntity(compagnieList);
// return compagnieList;
return null;
}
@Override
public void printPage() {
for(Companie elem:getEntity()) {
System.out.println(elem);
}
}
}
| [
"joachimbocaz@gmail.com"
] | joachimbocaz@gmail.com |
9cb4e948651ce1badd0681dc756a46aab4933849 | a46cf01389a641f7e54bcaf03558df358f8f9e4c | /local_1/assignments/src/oops/Parent.java | 082f182b0a4a56905b237f160dc9a15e03c79fa2 | [] | no_license | niteshkatiyar/local_1 | 0bad6025ffbe981ff910d404c08fa415dab24c03 | f4d32b8f619e76bd142c783b89c91703786adf0e | refs/heads/master | 2020-05-18T02:39:17.088474 | 2015-07-02T13:24:29 | 2015-07-02T13:24:29 | 37,182,105 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,047 | java | package oops;
public class Parent
{
public String familyName;
public String language;
public int offsprings;
public Parent(String familyName, String language, int offsprings)
{
this.familyName = familyName;
this.language = language;
this.offsprings = offsprings;
}
public Parent(String familyName)
{
this.familyName = familyName;
}
public void displayInfo()
{
System.out.println("Parent information.");
System.out.println("Family Name: "+familyName + " & Language Spoken: "+language +" & has "+offsprings + " ofsprings");
}
public void getOffsprings()
{
System.out.println("Offsprings: "+offsprings);
}
public String getLanguage()
{
return language;
}
public String getFamilyName() {
return familyName;
}
public void setFamilyName(String familyName) {
this.familyName = familyName;
}
public void setLanguage(String language) {
this.language = language;
}
public void setOffsprings(int offsprings) {
this.offsprings = offsprings;
}
}
| [
"dvfurnish@gmail.com"
] | dvfurnish@gmail.com |
97dc3bbf57bc0c4c166426c2f9f7d49aa81e6ef3 | edd17b21529bcf5ebf82bde16004327109a8087e | /2.2.2. spring_mvc/src/main/java/web/models/Car.java | 485bd211582d4b09e4b4bc6d494f215cd74d593e | [] | no_license | GitMyCount/spring-mvc | 44e761521131908f0165dad31fa18a8483ef862e | 63381bb2b4216da5459b9180cdadc86a00f5eea2 | refs/heads/master | 2023-03-12T03:59:00.215296 | 2021-03-01T13:19:36 | 2021-03-01T13:19:36 | 343,421,900 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 828 | java | package web.models;
public class Car {
private int id;
private String marka;
private int model;
private String color;
public Car(int id, String marka, int model, String color) {
this.id = id;
this.marka = marka;
this.model = model;
this.color = color;
}
public int getId() {
return id;
}
public void setId(int id) {
this.id = id;
}
public String getMarka() {
return marka;
}
public void setMarka(String marka) {
this.marka = marka;
}
public int getModel() {
return model;
}
public void setModel(int model) {
this.model = model;
}
public String getColor() {
return color;
}
public void setColor(String color) {
this.color = color;
}
}
| [
"dvd.off@mail.ru"
] | dvd.off@mail.ru |
155e97aca7120068f249771bb97583aee42065e7 | 839bfe2ba569642834fa6ca9e8a055f286419f8b | /src/main/java/com/demo/service/ReportOfferService.java | 503497d47a7f8305ae8faaf957f90d09eacb43a7 | [] | no_license | Mihin125/JobRep | e45339b47a90e4d0460634e880d3f18cb8149ff4 | caf09384e1b2ee6cc700ea24b1b36bac3ff82f97 | refs/heads/master | 2023-05-13T10:36:51.854864 | 2021-06-09T06:39:30 | 2021-06-09T06:39:30 | 364,159,215 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,612 | java | package com.demo.service;
import com.demo.dto.ReportOfferDto;
import com.demo.model.ReportOffer;
import com.demo.repository.ReportOfferRespositorty;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;
@Service
public class ReportOfferService {
@Autowired
ReportOfferRespositorty reportOfferRespositorty;
@Autowired
UserService userService;
@Autowired
OfferService offerService;
public void saveReport(ReportOfferDto reportOfferDto){
ReportOffer reportOffer = new ReportOffer();
reportOffer.setDescription(reportOfferDto.getDescription());
reportOffer.setReportingUser(userService.findById(reportOfferDto.getReportingUserId()));
reportOffer.setOffer(offerService.findById(reportOfferDto.getOfferId()));
reportOffer.setDateTime(reportOffer.getDateTime());
reportOfferRespositorty.save(reportOffer);
}
public List<ReportOffer> getReportsByOfferId(long offerId){
return reportOfferRespositorty.findByOfferId(offerId);
}
public void markAsViewed(long id){
ReportOffer reportOffer = findById(id);
reportOffer.setViewed(true);
reportOfferRespositorty.save(reportOffer);
}
public ReportOffer findById(long id){
return reportOfferRespositorty.findById(id).orElseThrow(NullPointerException::new);
}
public List<ReportOffer> getAllUnviewed(){
return reportOfferRespositorty.findByViewed();
}
public int getNoOfUnviewed(){
return getAllUnviewed().size();
}
}
| [
"mihin125@gmail.com"
] | mihin125@gmail.com |
4f6560d4c0d0a817ce970af2f0fa1aa322fa94cd | 1b523bf1b3bfd9782227ca394ac20143baf4974c | /official/chapter05/phoneme/phoneme_feature-mr3-rel-src-b01-17_jul_2008/midp/src/configuration/properties/reference/classes/com/sun/midp/main/Configuration.java | 098f080c8e752e0cc040612c40f47b088a127f4c | [] | no_license | Joyounger/armlinuxbook | 66c80192a2d4ea068bba2e21c92067705da08949 | b7fea1d8c235cbd1f4551b5495bbacc777d91916 | refs/heads/master | 2021-05-06T10:17:58.433025 | 2018-03-31T09:14:02 | 2018-03-31T09:14:02 | 114,165,147 | 1 | 1 | null | null | null | null | UTF-8 | Java | false | false | 6,613 | java | /*
*
*
* Copyright 1990-2008 Sun Microsystems, Inc. All Rights Reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License version
* 2 only, as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License version 2 for more details (a copy is
* included at /legal/license.txt).
*
* You should have received a copy of the GNU General Public License
* version 2 along with this work; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
* 02110-1301 USA
*
* Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa
* Clara, CA 95054 or visit www.sun.com if you need additional
* information or have any questions.
*/
package com.sun.midp.main;
/** access the implementation configuration file parameters. */
public class Configuration {
/** Don't let anyone instantiate this class */
private Configuration() {
}
/**
* Gets the implementation property indicated by the specified key.
*
* @param key the name of the implementation property.
* @return the string value of the implementation property,
* or <code>null</code> if there is no property with that key.
*
* @exception NullPointerException if <code>key</code> is
* <code>null</code>.
* @exception IllegalArgumentException if <code>key</code> is empty.
*/
public static String getProperty(String key) {
// If key is null, then a NullPointerException is thrown.
// If key is blank, then throw a specific IllegalArgumentException
if (key.length() == 0) {
throw new IllegalArgumentException("key can't be empty");
}
return getProperty0(key);
}
/**
* Gets the implementation property indicated by the specified key or
* returns the specified default value.
*
* @param key the name of the implementation property.
* @param def the default value for the property if not
* specified in the configuration files or command
* line over rides.
* @return the string value of the implementation property,
* or <code>def</code> if there is no property with that key.
*
* @exception NullPointerException if <code>key</code> is
* <code>null</code>.
* @exception IllegalArgumentException if <code>key</code> is empty.
*/
public static String getPropertyDefault(String key, String def) {
String result = getProperty(key);
return (result != null ? result : def);
}
/**
* Gets the implementation property indicated by the specified key or
* returns the specified default value as an positive int.
*
* @param key the name of the implementation property.
* @param def the default value for the property if not
* specified in the configuration files or command
* line over rides.
*
* @return the int value of the implementation property,
* or <code>def</code> if there is no property with that key or
* the config value is not a positive int (zero is not
* positive).
*
* @exception NullPointerException if <code>key</code> is
* <code>null</code>.
* @exception IllegalArgumentException if <code>key</code> is empty.
*/
public static int getPositiveIntProperty(String key, int def) {
int temp = getIntProperty(key, def);
if (temp > 0) {
return temp;
}
return def;
}
/**
* Gets the implementation property indicated by the specified key or
* returns the specified default value as an non-zero int.
*
* @param key the name of the implementation property.
* @param def the default value for the property if not
* specified in the configuration files or command
* line over rides.
* @return the int value of the implementation property,
* or <code>def</code> if there is no property with that key or
* the config value is not an int.
*
* @exception NullPointerException if <code>key</code> is
* <code>null</code>.
* @exception IllegalArgumentException if <code>key</code> is empty.
*/
public static int getNonNegativeIntProperty(String key, int def) {
int temp = getIntProperty(key, def);
if (temp >= 0) {
return temp;
}
return def;
}
/**
* Gets the implementation property indicated by the specified key or
* returns the specified default value as an int.
*
* @param key the name of the implementation property.
* @param def the default value for the property if not
* specified in the configuration files or command
* line over rides.
*
* @return the int value of the implementation property,
* or <code>def</code> if there is no property with that key or
* the config value is not an int.
*
* @exception NullPointerException if <code>key</code> is
* <code>null</code>.
* @exception IllegalArgumentException if <code>key</code> is empty.
*/
public static int getIntProperty(String key, int def) {
/*
* Get the maximum number of persistent connections
* from the configuration file.
*/
String prop = getProperty(key);
if (prop == null) {
return def;
}
try {
int temp = Integer.parseInt(prop);
return temp;
} catch (NumberFormatException nfe) {
// keep the default
}
return def;
}
/**
* native interface to the configuration parameter storage.
*
* @param key the name of the implementation property.
* @return the string value of the implementation property,
* or <code>null</code> if there is no property with that key.
*/
private native static String getProperty0(String key);
}
| [
"942510346@qq.com"
] | 942510346@qq.com |
5725429cce33f23b25c4e2cc29ebd378dfefba76 | 42949bf027a0bb5fbc0daf6eb504403f5b6afa3c | /src/main/java/com/hyperchain/wallet/Dao/AssetDao.java | be6d0dcc837716ffaa17f37d083b464104d6de2e | [] | no_license | Viren157/Digital-Wallet-Java | e2dab3ad28e97510064bbac95dc001f08f09a644 | f30583a9ab860bf348a0e76499505af4bc234b9b | refs/heads/master | 2021-09-19T13:15:57.826340 | 2018-07-28T05:38:28 | 2018-07-28T05:46:40 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,256 | java | package com.hyperchain.wallet.Dao;
import com.hyperchain.wallet.model.Asset;
import com.hyperchain.wallet.model.User;
import org.springframework.stereotype.Repository;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
@Repository
public class AssetDao {
List<Asset> assets = new ArrayList<>();
public Asset FindUser(int id){
for (Asset asset : this.assets){
if (id == asset.id){
return asset;
}
}
return null;
}
public List<Asset> FindAssetByAddr(String assetAddr,String accountAddr){
List<Asset> assets = new ArrayList<>();
for (Asset asset : this.assets){
if (asset.assetAddr.equals(assetAddr) && asset.accountAddr.equals(accountAddr)){
assets.add(asset);
}
}
return assets;
}
public Asset FindOneAssetByAddr(String assetAddr,String accountAddr){
for (Asset asset : this.assets){
if (asset.assetAddr.equals(assetAddr) && asset.accountAddr.equals(accountAddr)){
return asset;
}
}
return null;
}
public Asset FindAssetByAddrAndType(String assetAddr,String type){
for (Asset asset : this.assets){
if (asset.assetAddr.equals(assetAddr) && asset.type.equals(type)){
return asset;
}
}
return null;
}
public Asset AssetByAddr(String assetAddr){
for (Asset asset : this.assets){
if (asset.assetAddr.equals(assetAddr)){
return asset;
}
}
return null;
}
public List<Asset> FindAssetByType(String type,String accountAddr){
List<Asset> assets = new ArrayList<>();
for (Asset asset : this.assets){
if ((type.equals("")|| asset.type.equals(type)) && asset.accountAddr.equals(accountAddr)){
assets.add(asset);
}
}
return assets;
}
public int Save(Asset asset) {
if (asset.id == 0){
asset.id = assets.size()+1;
this.assets.add(asset);
}else{
this.assets.set(asset.id-1,asset);
}
return asset.id;
}
}
| [
"cspilgrimzww@163.com"
] | cspilgrimzww@163.com |
5ef8da0b5c5d216cc19ddc3018ddfc834e1239c0 | 178025f7e02d5c5cd211712f4de66e70951375a4 | /src/main/java/com/solvve/lab/kinoproject/client/themoviedb/dto/PersonReadDTO.java | 52dd91284f880fc41a1c9d29de3f858e14ba1edc | [] | no_license | eglushenko/kinoproject | 69bc791142ae57678d6e096c2fc6a9b6cb365a66 | 084f95611c712b47af913f9322e8688b98a36a27 | refs/heads/master | 2020-12-23T13:33:47.586178 | 2020-05-04T11:45:11 | 2020-05-04T11:45:11 | 237,167,714 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 279 | java | package com.solvve.lab.kinoproject.client.themoviedb.dto;
import lombok.Data;
@Data
public class PersonReadDTO {
private String id;
private String birthday;
private String deathday;
private String name;
private int gender;
private String biography;
}
| [
"e.glushenko@hotmail.com"
] | e.glushenko@hotmail.com |
51f5455e38bdf529cd4c5439a90ac4bb1b99ade9 | 06deb77e091bd58033924de5aa2b35ec8163778e | /ee7-ejb-cdi-scopemix-web/src/main/java/org/example/web/ExampleWebRequest.java | 05c3c2a0490c512d1e91f5d2abb556534fed6676 | [] | no_license | StefanHeimberg/ee7-ejb-cdi-scopemix | 38c4f1682e52ccf61f430994dc105618d866ac73 | d6845f1426db53f7abf3db2ab129259b7114a289 | refs/heads/master | 2020-03-23T15:23:43.140874 | 2018-07-23T22:03:39 | 2018-07-23T22:03:39 | 141,744,995 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 3,669 | java | package org.example.web;
import java.io.IOException;
import javax.annotation.PostConstruct;
import javax.annotation.PreDestroy;
import javax.ejb.EJB;
import javax.inject.Inject;
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 org.example.ejb.ExampleEjbFacade;
import org.example.ejb.ExampleEjbService1;
import org.example.ejb.ExampleEjbStartup;
import org.example.ejblite.ExampleEjbLiteService;
import org.example.sharedlib.ExampleDependedBean;
import org.example.sharedlib.ExampleRequestBean;
import org.example.sharedlib.RandomUtil;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
*
* @author Stefan Heimberg <kontakt@stefanheimberg.ch>
*/
@WebServlet(urlPatterns = "/request")
//@RequestScoped kann nicht verwendet werden da es sonst zur exception kommt:
//java.lang.IllegalArgumentException: The class org.example.web.ExampleWebRequest is annotated with an invalid scope
// und ohne @RequestScoped wird dieselbe instanz des ExampleWebRequest über mehrere request/threads verwendet.
public class ExampleWebRequest extends HttpServlet {
private final Logger LOG;
private final String id;
@EJB
private ExampleEjbService1 exampleService1;
@EJB
private ExampleEjbFacade exampleEjbFacade;
@EJB
private ExampleEjbStartup exampleEjbStartup;
@EJB
private ExampleEjbLiteService exampleEjbLiteService;
@Inject
private ExampleRequestBean exampleRequestBean;
@Inject
private ExampleDependedBean exampleDependedBean;
public ExampleWebRequest() {
this.id = RandomUtil.randomId(ExampleWebRequest.class);
LOG = LoggerFactory.getLogger(id);
LOG.info("constructor called");
}
@PostConstruct
public void postConstruct() {
LOG.info("postConstruct called");
}
@PreDestroy
public void preDestroy() {
LOG.info("preDestroy called");
}
@Override
protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {
logIds("", id, id);
}
public void logIds(final String indent, final String originId, final String callerId) {
LOG.info("originId: {}, {}caller: {}, this.id: {}", originId, indent, callerId, id);
LOG.info("originId: {}, {}caller: {}, exampleRequestBean.class: {}", originId, indent, callerId, exampleRequestBean.getClass().getName());
exampleRequestBean.logIds(indent + " ", originId, id);
LOG.info("originId: {}, {}caller: {}, exampleService1.class: {}", originId, indent, callerId, exampleService1.getClass().getName());
exampleService1.logIds(indent + " ", originId, id);
LOG.info("originId: {}, {}caller: {}, exampleService2.class: {}", originId, indent, callerId, exampleEjbFacade.getClass().getName());
exampleEjbFacade.logIds(indent + " ", originId, id);
LOG.info("originId: {}, {}caller: {}, exampleEjbStartup.class: {}", originId, indent, callerId, exampleEjbStartup.getClass().getName());
exampleEjbStartup.logIds(indent + " ", originId, id);
LOG.info("originId: {}, {}caller: {}, exampleEjbLiteService.class: {}", originId, indent, callerId, exampleEjbLiteService.getClass().getName());
exampleEjbLiteService.logIds(indent + " ", originId, id);
LOG.info("originId: {}, {}caller: {}, exampleDependedBean.class: {}", originId, indent, callerId, exampleDependedBean.getClass().getName());
exampleDependedBean.logIds(indent + " ", originId, id);
}
}
| [
"kontakt@stefanheimberg.ch"
] | kontakt@stefanheimberg.ch |
4680acd1e740e9cb677049c978e20e1a52c45db4 | 09aa22430b77d9a7b2b8adb35302a58380d0a754 | /src/test/java/com/servico/correio/ServiicoCorreiosApplicationTests.java | e007b7fb1df6cac1823161c976f228bb2e01ddd9 | [] | no_license | RodrikKlesse/correios | 22c83911b1b9b54c44d96b484187b9be95f1a535 | 4ee0b58a65004153d807fabe7bc2e7fa0a398b9d | refs/heads/master | 2023-03-02T00:26:56.803543 | 2021-02-10T21:53:59 | 2021-02-10T21:53:59 | 337,863,285 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 221 | java | package com.servico.correio;
import org.junit.jupiter.api.Test;
import org.springframework.boot.test.context.SpringBootTest;
@SpringBootTest
class ServiicoCorreiosApplicationTests {
@Test
void contextLoads() {
}
}
| [
"rodrik_hsk@hotmail.com"
] | rodrik_hsk@hotmail.com |
edf846cb2a04dca197071b1344609787e24809b9 | c729197836d6a41574e01295e55e349870f1aafe | /src/main/java/za/ac/cput/Repository/Implementation/System/SolvedCaseRepositoryImplementation.java | 3113c62b3ae03af3c160c4a0f0f6a170f65464d3 | [] | no_license | ryanpetersen99/Assignment8 | ff6d098b50330dbd3d9c5d3ce7bec7aaec4ef019 | 62855af40ef33f531fce69b52e7a286980da8c7c | refs/heads/master | 2020-05-25T16:59:39.538003 | 2019-05-22T07:23:37 | 2019-05-22T07:23:37 | 187,897,944 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,857 | java | package za.ac.cput.Repository.Implementation.System;
import za.ac.cput.Domain.System.SolvedCase;
import za.ac.cput.Repository.System.SolvedCaseRepository;
import java.util.HashSet;
import java.util.Set;
public class SolvedCaseRepositoryImplementation implements SolvedCaseRepository {
private static SolvedCaseRepositoryImplementation solvedCaseRepositoryImplementation = null;
private Set<SolvedCase> solvedCaseSet;
private SolvedCaseRepositoryImplementation(){
this.solvedCaseSet = new HashSet<>();
}
private SolvedCase findCase(String caseID){
return this.solvedCaseSet.stream()
.filter(solvedCase -> solvedCase.getCaseID().trim().equals(caseID))
.findAny()
.orElse(null);
}
public static SolvedCaseRepositoryImplementation getRepository(){
if(solvedCaseRepositoryImplementation == null)solvedCaseRepositoryImplementation = new SolvedCaseRepositoryImplementation();
return solvedCaseRepositoryImplementation;
}
@Override
public SolvedCase create(SolvedCase solvedCase) {
this.solvedCaseSet.add(solvedCase);
return solvedCase;
}
@Override
public SolvedCase read(String caseID) {
return findCase(caseID);
}
@Override
public SolvedCase update(SolvedCase solvedCase) {
SolvedCase delete = findCase(solvedCase.getCaseID());
if(delete != null){
this.solvedCaseSet.remove(delete);
return create(solvedCase);
}
return null;
}
@Override
public void delete(String caseID) {
SolvedCase solvedCase = findCase(caseID);
if(solvedCase != null) {
this.solvedCaseSet.remove(solvedCase);
}
}
public Set<SolvedCase> getSolvedCaseSet() {
return this.solvedCaseSet;
}
}
| [
"47520518+ryanpetersen99@users.noreply.github.com"
] | 47520518+ryanpetersen99@users.noreply.github.com |
63de49ea4251a785488613b0ae6c027877fa8e5a | 6317dd15a43982658773bdc0fdc5cb6c2881f040 | /spring-cloud-starter-grpc-examples/test/test-client/src/main/java/com/icekredit/examples/test/client/service/TestService.java | 8d2a7c0f47a061fc38d7bc4d446a5b3f8767b6a0 | [] | no_license | lazycathome/spring-cloud-starter-grpc | 7e9f88dbbe6f27c7482794431c750595c97a7907 | 064cce15c8c521b4f2529bdf204342959e05ee98 | refs/heads/master | 2020-03-23T01:53:34.835343 | 2017-12-20T04:01:07 | 2017-12-20T04:01:07 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 202 | java | package com.icekredit.examples.test.client.service;
import com.icekredit.phone.PhoneType;
public interface TestService {
String addPhoneToUser(int uid, PhoneType phoneType, String phoneNubmer);
}
| [
"ningwenchao@163.com"
] | ningwenchao@163.com |
65774eb30714585202acde593f988ede25038098 | a22c6fdaacdf1c63440b3d76c26932ff048fb0b9 | /src/main/java/com/bazlur/tips/solid/srp/after/ReservationService.java | cc736dfa221ddddb951909dadee8cb00d34cbf14 | [] | no_license | rokon12/java-tips | ea8330d0d8d794f51eac947a2a0f39992659918f | 60da5b720b6e16c6ca53e98fd3996772fc84b8e5 | refs/heads/master | 2016-09-12T15:40:36.943205 | 2016-03-08T00:21:09 | 2016-03-08T00:21:09 | 59,617,968 | 2 | 0 | null | null | null | null | UTF-8 | Java | false | false | 266 | java | package com.bazlur.tips.solid.srp.after;
import com.bazlur.tips.solid.srp.before.OrderItem;
import java.util.List;
/**
* @author Bazlur Rahman Rokon
* @since 3/8/16.
*/
public interface ReservationService {
void reserveInventory(List<OrderItem> items);
}
| [
"anm_brr@yahoo.com"
] | anm_brr@yahoo.com |
e7e4d90eefb70a66568cc519ffbc1e420c6fb4c8 | d2d1b51db5b2937568a6c08c2dcd974eed73c8a4 | /lzy_shop/src/main/java/com/lzy/shop/service/ShopServiceImpl.java | cb4a2a4155d2e5e206bd6d97389b49d6b6c15e21 | [] | no_license | lizhongyu-lzy/lzy_shop | e8dfc48495d83d0d415343326baba6143ba16a66 | 6406634d8ba44802bc3cea310ce0b46436d3292a | refs/heads/master | 2022-12-21T13:57:05.501780 | 2019-07-10T12:01:11 | 2019-07-10T12:01:11 | 196,197,539 | 0 | 0 | null | 2022-12-16T09:11:27 | 2019-07-10T12:02:35 | JavaScript | UTF-8 | Java | false | false | 1,182 | java | package com.lzy.shop.service;
import java.util.List;
import java.util.Map;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.lzy.shop.dao.ShopMapper;
import com.lzy.shop.domain.Shop;
import com.lzy.shop.domain.Type;
@Service
public class ShopServiceImpl implements ShopService {
@Autowired
private ShopMapper mapper;
public List getList(Map map) {
// TODO Auto-generated method stub
return mapper.getList(map);
}
public List getType() {
// TODO Auto-generated method stub
return mapper.getType();
}
@Override
public void add(Shop shop, Integer[] tid) {
mapper.addShop(shop);
if(tid != null) {
for (Integer i : tid) {
mapper.addCenter(shop.getSid(),i);
}
}
}
@Override
public Shop getShop(Integer sid) {
// TODO Auto-generated method stub
return mapper.getShop(sid);
}
@Override
public List getTypeCha(Integer sid) {
// TODO Auto-generated method stub
return mapper.getTypeCha(sid);
}
@Override
public void del(String sid) {
mapper.delShop(sid);
mapper.delCenter(sid);
}
}
| [
"2099945679@qq.com"
] | 2099945679@qq.com |
cb2d8e4d7ee524fb6811609f0da8e52cecb25134 | 81f42120b84af34a274f99bd004bdf2c2646985b | /theory/distributedIdService/src/main/java/com/wolfbe/distributedid/sdks/SdkServerHandler.java | 45c8cbf8fa995d079366b3e8dead00f065d7aea8 | [
"Apache-2.0"
] | permissive | spencercjh/codeLife | 60f877999f5769678308133f9463cab6ae3dabe0 | be27d99380c0a1bdf4bea9a86b0d436deb7e2d2d | refs/heads/master | 2022-06-25T14:41:14.540818 | 2020-07-13T15:40:23 | 2020-07-13T15:40:23 | 175,650,453 | 6 | 1 | Apache-2.0 | 2022-06-20T22:45:36 | 2019-03-14T15:34:11 | Java | UTF-8 | Java | false | false | 2,607 | java | package com.wolfbe.distributedid.sdks;
import com.wolfbe.distributedid.core.SnowFlake;
import com.wolfbe.distributedid.exception.RemotingTooMuchRequestException;
import com.wolfbe.distributedid.util.GlobalConfig;
import com.wolfbe.distributedid.util.NettyUtil;
import io.netty.channel.*;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.util.concurrent.Semaphore;
import java.util.concurrent.TimeUnit;
/**
* 通过雪花算法生成唯一ID,写入Channel返回
* @author Andy
*/
public class SdkServerHandler extends SimpleChannelInboundHandler {
private static final Logger logger = LoggerFactory.getLogger(SdkServerHandler.class);
/**
* 通过信号量来控制流量
*/
private Semaphore semaphore = new Semaphore(GlobalConfig.HANDLE_SDKS_TPS);
private SnowFlake snowFlake;
SdkServerHandler(SnowFlake snowFlake) {
this.snowFlake = snowFlake;
}
@Override
protected void channelRead0(ChannelHandlerContext ctx, Object msg) throws Exception {
if (msg instanceof SdkProto) {
SdkProto sdkProto = (SdkProto) msg;
logger.info("SdkServerHandler msg is: {}", sdkProto.toString());
if (semaphore.tryAcquire(GlobalConfig.ACQUIRE_TIMEOUT_MILLIS, TimeUnit.MILLISECONDS)) {
try {
sdkProto.setDid(snowFlake.nextId());
ctx.channel().writeAndFlush(sdkProto).addListener((ChannelFutureListener) channelFuture -> semaphore.release());
} catch (Exception e) {
semaphore.release();
logger.error("Sdk Server handler error", e);
}
} else {
sdkProto.setDid(-1);
ctx.channel().writeAndFlush(sdkProto);
String info = String.format("SdkServerHandler tryAcquire semaphore timeout, %dms, waiting thread " +
"nums: %d availablePermit: %d",
GlobalConfig.ACQUIRE_TIMEOUT_MILLIS,
this.semaphore.getQueueLength(),
this.semaphore.availablePermits()
);
logger.warn(info);
throw new RemotingTooMuchRequestException(info);
}
}
}
@Override
public void exceptionCaught(ChannelHandlerContext ctx, Throwable cause) throws Exception {
Channel channel = ctx.channel();
logger.error("Sdk Server Handler channel [{}] error and will be closed", NettyUtil.parseRemoteAddr(channel), cause);
NettyUtil.closeChannel(channel);
}
}
| [
"fixed-term.spencer.cai@cn.bosch.com"
] | fixed-term.spencer.cai@cn.bosch.com |
5ac00200cea8f1c208bd4cdd8bd10d3659846312 | 1e19314a8b1f0b64ae442a485d79fa9151a1107e | /src/by/it/viktorbrui/jd02_01/Helper.java | 0d9ce383a1b0ae752d7de1ccbec9078b2f66b32e | [] | no_license | igorkiselev93/JD2017-12-16 | 2271cdc1c161eabc10009b0638de8b194489d581 | 7bb21bfe1358cf9611bce9684907fb2d7e8b0e44 | refs/heads/master | 2021-05-10T08:34:50.864238 | 2018-02-22T10:21:57 | 2018-02-22T10:21:57 | 118,894,315 | 1 | 0 | null | 2018-01-25T09:50:05 | 2018-01-25T09:50:04 | null | UTF-8 | Java | false | false | 538 | java | package by.it.viktorbrui.jd02_01;
import java.util.Random;
public class Helper {
private final static Random random=new Random();
static int getRandom(int bound){
return random.nextInt(bound);
}
private static int getRandom(int start, int stop){
return start+random.nextInt(stop-start);
}
static void sleep(int start, int stop){
try {
Thread.sleep(Helper.getRandom(start,stop));
} catch (InterruptedException e) {
e.printStackTrace();
}
}
}
| [
"artyom.yavorski@gmail.com"
] | artyom.yavorski@gmail.com |
28ee6bf9c9daa9cd156765cc0647e9172ea8cb92 | 4b0bf4787e89bcae7e4759bde6d7f3ab2c81f849 | /aliyun-java-sdk-sas/src/main/java/com/aliyuncs/sas/transform/v20181203/DescribeAccessKeyLeakDetailResponseUnmarshaller.java | 6b417e4eb69a6021a939214d6b6b665c1a7fab92 | [
"Apache-2.0"
] | permissive | aliyun/aliyun-openapi-java-sdk | a263fa08e261f12d45586d1b3ad8a6609bba0e91 | e19239808ad2298d32dda77db29a6d809e4f7add | refs/heads/master | 2023-09-03T12:28:09.765286 | 2023-09-01T09:03:00 | 2023-09-01T09:03:00 | 39,555,898 | 1,542 | 1,317 | NOASSERTION | 2023-09-14T07:27:05 | 2015-07-23T08:41:13 | Java | UTF-8 | Java | false | false | 3,730 | java | /*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.aliyuncs.sas.transform.v20181203;
import com.aliyuncs.sas.model.v20181203.DescribeAccessKeyLeakDetailResponse;
import com.aliyuncs.transform.UnmarshallerContext;
public class DescribeAccessKeyLeakDetailResponseUnmarshaller {
public static DescribeAccessKeyLeakDetailResponse unmarshall(DescribeAccessKeyLeakDetailResponse describeAccessKeyLeakDetailResponse, UnmarshallerContext _ctx) {
describeAccessKeyLeakDetailResponse.setRequestId(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.RequestId"));
describeAccessKeyLeakDetailResponse.setType(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.Type"));
describeAccessKeyLeakDetailResponse.setGithubUserPicUrl(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.GithubUserPicUrl"));
describeAccessKeyLeakDetailResponse.setGithubUser(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.GithubUser"));
describeAccessKeyLeakDetailResponse.setGithubRepoName(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.GithubRepoName"));
describeAccessKeyLeakDetailResponse.setGithubFileType(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.GithubFileType"));
describeAccessKeyLeakDetailResponse.setRemark(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.Remark"));
describeAccessKeyLeakDetailResponse.setGithubFileUpdateTime(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.GithubFileUpdateTime"));
describeAccessKeyLeakDetailResponse.setWhitelistStatus(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.WhitelistStatus"));
describeAccessKeyLeakDetailResponse.setGithubFileName(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.GithubFileName"));
describeAccessKeyLeakDetailResponse.setSource(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.Source"));
describeAccessKeyLeakDetailResponse.setGmtModified(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.GmtModified"));
describeAccessKeyLeakDetailResponse.setAsset(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.Asset"));
describeAccessKeyLeakDetailResponse.setDealTime(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.DealTime"));
describeAccessKeyLeakDetailResponse.setAccesskeyId(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.AccesskeyId"));
describeAccessKeyLeakDetailResponse.setGithubFileUrl(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.GithubFileUrl"));
describeAccessKeyLeakDetailResponse.setDealType(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.DealType"));
describeAccessKeyLeakDetailResponse.setCode(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.Code"));
describeAccessKeyLeakDetailResponse.setGmtCreate(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.GmtCreate"));
describeAccessKeyLeakDetailResponse.setGithubRepoUrl(_ctx.stringValue("DescribeAccessKeyLeakDetailResponse.GithubRepoUrl"));
describeAccessKeyLeakDetailResponse.setTokenValid(_ctx.integerValue("DescribeAccessKeyLeakDetailResponse.TokenValid"));
describeAccessKeyLeakDetailResponse.setWhitelistTime(_ctx.longValue("DescribeAccessKeyLeakDetailResponse.WhitelistTime"));
return describeAccessKeyLeakDetailResponse;
}
} | [
"sdk-team@alibabacloud.com"
] | sdk-team@alibabacloud.com |
f5b950d7edcaee1f9e9e142fe879a09689218190 | 0554f194b0ea739fc335a152a3145c2ae96b0245 | /fest-assert-android-test/src/main/java/org/fest/assertions/internal/DoubleArrays_assertEmpty_Test.java | 393537023b3dcc248007fba9c529e3be1e4a4861 | [
"Apache-2.0"
] | permissive | nicstrong/fest-assertions-android | 76e4239e34130f72c2503590a9657c316c8570ef | 2869c3279ae7eaa8dd7e76a9802e33ca5d16fac8 | refs/heads/master | 2016-09-09T18:19:20.501101 | 2011-12-18T23:11:23 | 2011-12-18T23:11:23 | 1,804,253 | 1 | 1 | null | null | null | null | UTF-8 | Java | false | false | 2,266 | java | /*
* Created on Dec 20, 2010
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on
* an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the
* specific language governing permissions and limitations under the License.
*
* Copyright @2010-2011 the original author or authors.
*/
package org.fest.assertions.internal;
import static org.fest.assertions.error.ShouldBeEmpty.shouldBeEmpty;
import static org.fest.assertions.test.DoubleArrayFactory.emptyArray;
import static org.fest.assertions.test.ExpectedException.none;
import static org.fest.assertions.test.FailureMessages.actualIsNull;
import static org.fest.assertions.test.TestData.someInfo;
import static org.fest.assertions.test.TestFailures.expectedAssertionErrorNotThrown;
import static org.mockito.Mockito.*;
import org.fest.assertions.core.AssertionInfo;
import org.fest.assertions.test.ExpectedException;
import org.junit.*;
/**
* Tests for <code>{@link DoubleArrays#assertEmpty(AssertionInfo, double[])}</code>.
*
* @author Alex Ruiz
*/
public class DoubleArrays_assertEmpty_Test {
@Rule public ExpectedException thrown = none();
private Failures failures;
private DoubleArrays arrays;
@Before public void setUp() {
failures = spy(new Failures());
arrays = new DoubleArrays();
arrays.failures = failures;
}
@Test public void should_fail_if_actual_is_null() {
thrown.expectAssertionError(actualIsNull());
arrays.assertEmpty(someInfo(), null);
}
@Test public void should_fail_if_actual_is_not_empty() {
AssertionInfo info = someInfo();
double[] actual = { 6d, 8d };
try {
arrays.assertEmpty(info, actual);
} catch (AssertionError e) {
verify(failures).failure(info, shouldBeEmpty(actual));
return;
}
throw expectedAssertionErrorNotThrown();
}
@Test public void should_pass_if_actual_is_empty() {
arrays.assertEmpty(someInfo(), emptyArray());
}
}
| [
"nic.strong@gmail.com"
] | nic.strong@gmail.com |
4ff15c4da60883ab072938a679af074c0bc45bbf | 10fa500b73489056d11a5e1237af312bc5d28dfa | /src/main/java/com/thinkgem/fast/modules/sales/entity/SalesBackTicketVo.java | fc91d34726d1780f831ba21189b6f1f7d3e7fa93 | [] | no_license | drugmanage/drug_manage | d19821f157f6b8f522847639e1c137e900e0c839 | 0ca421728b7a062f54c585b3ca5e6ffd0f5e67ca | refs/heads/master | 2022-12-24T04:44:59.302585 | 2019-06-20T07:54:38 | 2019-06-20T07:54:38 | 154,301,385 | 0 | 1 | null | 2022-12-16T02:08:23 | 2018-10-23T09:34:59 | JavaScript | UTF-8 | Java | false | false | 3,739 | java | package com.thinkgem.fast.modules.sales.entity;
import com.thinkgem.fast.common.persistence.DataEntity;
/**
* 销售退回开票单列表展示Entity
* @author shiao
* @version 2019-01-08
*/
public class SalesBackTicketVo extends DataEntity<SalesBackTicketVo> {
/**
*
*/
private static final long serialVersionUID = 231621827727823615L;
private String salesGoodsId; // 销售商品ID
private String goodsCode;
private String goodsName;
private String goodsSpec;
private String goodsType;
private String manufacturer;
private String unit;
private String content;
private String unitBackNumber; // 单位退货数量
private Double backPriceTaxFree; // 总不含税金额
private Double backPriceTotalTax; // 总税额
private Double backPriceTaxAmount; // 总含税金额
private String returnReason; // 退货原因
public SalesBackTicketVo() {
super();
}
public SalesBackTicketVo(SalesBackTicket salesBackTicket, SalesGoodsVo salesGoodsVo){
this.salesGoodsId = salesGoodsVo.getId();
this.goodsCode = salesGoodsVo.getGoodsCode();
this.goodsName = salesGoodsVo.getGoodsName();
this.goodsSpec = salesGoodsVo.getGoodsSpec();
this.goodsType = salesGoodsVo.getGoodsType();
this.manufacturer = salesGoodsVo.getManufacturer();
this.unit = salesGoodsVo.getUnit();
this.content = salesGoodsVo.getContent();
this.backPriceTaxFree = salesBackTicket.getBackPriceTaxFree();
this.backPriceTotalTax = salesBackTicket.getBackPriceTotalTax();
this.backPriceTaxAmount = salesBackTicket.getBackPriceTaxAmount();
this.unitBackNumber = salesBackTicket.getUnitBackNumber();
this.returnReason = salesBackTicket.getReturnReason();
}
public String getSalesGoodsId() {
return salesGoodsId;
}
public void setSalesGoodsId(String salesGoodsId) {
this.salesGoodsId = salesGoodsId;
}
public String getGoodsCode() {
return goodsCode;
}
public void setGoodsCode(String goodsCode) {
this.goodsCode = goodsCode;
}
public String getGoodsName() {
return goodsName;
}
public void setGoodsName(String goodsName) {
this.goodsName = goodsName;
}
public String getGoodsSpec() {
return goodsSpec;
}
public void setGoodsSpec(String goodsSpec) {
this.goodsSpec = goodsSpec;
}
public String getGoodsType() {
return goodsType;
}
public void setGoodsType(String goodsType) {
this.goodsType = goodsType;
}
public String getManufacturer() {
return manufacturer;
}
public void setManufacturer(String manufacturer) {
this.manufacturer = manufacturer;
}
public String getUnit() {
return unit;
}
public void setUnit(String unit) {
this.unit = unit;
}
public String getContent() {
return content;
}
public void setContent(String content) {
this.content = content;
}
public String getUnitBackNumber() {
return unitBackNumber;
}
public void setUnitBackNumber(String unitBackNumber) {
this.unitBackNumber = unitBackNumber;
}
public Double getBackPriceTaxFree() {
return backPriceTaxFree;
}
public void setBackPriceTaxFree(Double backPriceTaxFree) {
this.backPriceTaxFree = backPriceTaxFree;
}
public Double getBackPriceTotalTax() {
return backPriceTotalTax;
}
public void setBackPriceTotalTax(Double backPriceTotalTax) {
this.backPriceTotalTax = backPriceTotalTax;
}
public Double getBackPriceTaxAmount() {
return backPriceTaxAmount;
}
public void setBackPriceTaxAmount(Double backPriceTaxAmount) {
this.backPriceTaxAmount = backPriceTaxAmount;
}
public String getReturnReason() {
return returnReason;
}
public void setReturnReason(String returnReason) {
this.returnReason = returnReason;
}
} | [
"214388584@qq.com"
] | 214388584@qq.com |
74296fcf2d7ef693e57676cbfecdb2161f2116df | 02478122b0b736b307c07b9e4dbb7d2f392f04b8 | /Main.java | b7e2fa486d69e6ec8f84f7115f0a397e1bb8df3a | [] | no_license | Onecl1ck/Calc | dfb5bfbcf080cec03480b8be6b1fec47828e55b1 | 6bbbd6538db76e01e4abb851e15910c779f33f82 | refs/heads/master | 2020-05-05T11:50:58.380991 | 2019-04-18T18:31:15 | 2019-04-18T18:31:15 | 180,006,064 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,119 | java | public class Main {
public static void main(String[] args) {
String input= "6+(4+(2+(3+2)*(4+2)))+(2+3)";
String input1= "(2+(3+2)*(4+2))";
//System.out.println("Ответ: " + Calcu.calc(Input.inputnorm(input)));
//System.out.println("Ответ: " + (Input.cutrightbracket(Input.cutleftbracket(input))));
//System.out.println("Ответ: " + Input.cutrightbracket(Input.cutleftbracket((Input.cutrightbracket(Input.cutleftbracket(input))))));
//System.out.println("Ответ: " + (Input.cutrightbracket(Input.cutleftbracket(input1))));
//System.out.println("Ответ: " + (Input.pokanezaebet(input)));
//System.out.println("Ответ: " + (Calcu.calc(InputConvert.inputnorm(Input.pokanezaebet(input)))));
//System.out.println("Глобал: " + Input.calcbracket(input));
//System.out.println("Глобал2: " + Input.calcbracket(Input.calcbracket(input)));
System.out.println("Глобал: " + Input.pokanezaebet2(input));
MyFrame frame = new MyFrame();
frame.setVisible(true);
}
} | [
"noreply@github.com"
] | noreply@github.com |
76a2b31531c621e5c7bd068a3dca6ee034e96894 | e2ef7cc3776762a5895776adadb718ab7850fb0e | /financialSystem/src/com/train/servlet/try1.java | 29ba1e969c7e724b5a65078e90078372421c2d95 | [] | no_license | liuquan250/company | 9df2eb3ab04cbacba6da771152de13b4771f1a9f | e839aebe93c6687a56678590832a78f00b160c1d | refs/heads/master | 2021-06-25T17:50:01.751070 | 2020-10-25T12:36:59 | 2020-10-25T12:36:59 | 138,454,924 | 0 | 0 | null | null | null | null | GB18030 | Java | false | false | 693 | java | package com.train.servlet;
import java.sql.Date;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Calendar;
public class try1 {
public static String addDay(String s, int n) {
try {
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
Calendar cd = Calendar.getInstance();
cd.setTime(sdf.parse(s));
cd.add(Calendar.DATE, n);//增加一天
//cd.add(Calendar.MONTH, n);//增加一个月
return sdf.format(cd.getTime());
} catch (Exception e) {
return null;
}
}
}
| [
"1731120097@qq.com"
] | 1731120097@qq.com |
7601b871d9c7eb1128a915e5562c4d1f2329d316 | fc0879f1a64a9b12f191b46f3ee08f32114519af | /gameserver/src/ru/catssoftware/gameserver/instancemanager/grandbosses/QueenAntManager.java | 77df119b0dc44cc3574e65fd0d047c6710183d74 | [] | no_license | Snikers0309/lucera2 | b26f59953edec905aefeb2c4273f3dec17e88a9d | 53d623903322e177cc7eb34a7e292878cbc74841 | refs/heads/master | 2023-03-23T00:25:53.002593 | 2013-01-30T01:11:33 | 2013-01-30T01:11:33 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 4,956 | java | package ru.catssoftware.gameserver.instancemanager.grandbosses;
import ru.catssoftware.config.L2Properties;
import ru.catssoftware.extension.GameExtensionManager;
import ru.catssoftware.extension.ObjectExtension;
import ru.catssoftware.gameserver.ThreadPoolManager;
import ru.catssoftware.gameserver.datatables.NpcTable;
import ru.catssoftware.gameserver.model.L2Attackable;
import ru.catssoftware.gameserver.model.L2Character;
import ru.catssoftware.gameserver.model.L2Spawn;
import ru.catssoftware.gameserver.model.actor.instance.L2GrandBossInstance;
import ru.catssoftware.gameserver.model.actor.instance.L2PcInstance;
import ru.catssoftware.gameserver.model.entity.GrandBossState;
import ru.catssoftware.gameserver.model.entity.GrandBossState.StateEnum;
import ru.catssoftware.gameserver.model.mapregion.TeleportWhereType;
import ru.catssoftware.gameserver.model.quest.pack.ai.QueenAnt;
import ru.catssoftware.gameserver.model.zone.L2Zone;
import ru.catssoftware.gameserver.templates.chars.L2NpcTemplate;
import ru.catssoftware.tools.random.Rnd;
public class QueenAntManager extends BossLair {
public static long MIN_RESPAWN;
public static long MAX_RESPAWN;
public static int SAFE_LEVEL;
public static int MAX_NURSES;
public static int MAX_GUARDS;
public static boolean AK_ENABLE;
private static QueenAntManager _instance;
private boolean _loaded = false;
public static QueenAntManager getInstance() {
if(_instance==null)
_instance = new QueenAntManager();
return _instance;
}
private QueenAntManager() {
super();
try {
L2Properties p = new L2Properties("./config/main/events/bosses.properties");
MIN_RESPAWN = Integer.parseInt(p.getProperty("QueenAntMinRespawn","1440"));
MAX_RESPAWN = Integer.parseInt(p.getProperty("QueenAntMaxRespawn","2880"));
SAFE_LEVEL = Integer.parseInt(p.getProperty("QueenAntMaxSafeLevel","48"));
MAX_NURSES = Integer.parseInt(p.getProperty("QueenAntNumberOfNurses","6"));
MAX_GUARDS = Integer.parseInt(p.getProperty("QueenAntNumberOfGuards","8"));
AK_ENABLE = Boolean.parseBoolean(p.getProperty("QueenAntEnabled","true"));
if(AK_ENABLE) {
_loaded = true;
new QueenAnt();
}
GameExtensionManager.getInstance().registerExtension(new checkLevelUp());
} catch(Exception e) {
_log.error("QuuenAntManager: Error while reading config",e);
_loaded = false;
return;
}
}
@Override
public void init() {
if(!_loaded)
return;
L2NpcTemplate template = NpcTable.getInstance().getTemplate(29001);
_bossSpawn = new L2Spawn(template);
_bossSpawn.setLocx(-21610);
_bossSpawn.setLocy(181594);
_bossSpawn.setLocz(-5734);
_bossSpawn.stopRespawn();
_state = new GrandBossState(29001);
switch (_state.getState()) {
case DEAD:
long inter = Rnd.get((int)(MIN_RESPAWN*60000), (int)(MAX_RESPAWN*60000));
_state.setRespawnDate(inter);
_state.setState(StateEnum.INTERVAL);
case INTERVAL:
ThreadPoolManager.getInstance().schedule(new Runnable() {
public void run() {
doSpawn();
}
}, _state.getInterval());
break;
case UNKNOWN:
_state.setState(StateEnum.ALIVE);
case ALIVE:
case NOTSPAWN:
doSpawn();
break;
}
_log.info("QueenAntManager: State of Queen Ant is "+_state.getState());
}
private void doSpawn() {
L2GrandBossInstance ak = (L2GrandBossInstance)_bossSpawn.doSpawn();
ak._lair = this;
_state.setState(StateEnum.ALIVE);
_state.update();
}
@Override
public void setRespawn() {
}
@Override
public void setUnspawn() {
_state.setState(StateEnum.INTERVAL);
long interval = Rnd.get(MIN_RESPAWN,MAX_RESPAWN) * 60000;
_state.setRespawnDate(interval);
_state.update();
_log.info("QueenAntManager: State of Queen Ant is "+_state.getState());
ThreadPoolManager.getInstance().schedule(new Runnable() {
public void run() {
doSpawn();
}
}, _state.getInterval());
}
@Override
public void onExit(L2Character cha) {
if(cha instanceof L2Attackable) {
int npcId = ((L2Attackable)cha).getNpcId();
if(npcId == QueenAnt.GUARD || npcId == QueenAnt.NURSE || npcId == QueenAnt.ROYAL || npcId==QueenAnt.QUEEN)
cha.teleToLocation(_bossSpawn.getLocx(), _bossSpawn.getLocy(), _bossSpawn.getLocz());
}
}
private class checkLevelUp extends ObjectExtension
{
@Override
public Class<?>[] forClasses() {
return new Class<?>[]{ L2PcInstance.class };
}
@Override
public Object hanlde(Object object, Action action, Object... params)
{
if (action.equals(Action.PC_LEVEL_UP) && object instanceof L2PcInstance)
{
L2PcInstance player = (L2PcInstance) object;
if (player.isInsideZone(L2Zone.FLAG_QUEEN))
if (SAFE_LEVEL > 0 && player.getLevel() > SAFE_LEVEL)
player.teleToLocation(TeleportWhereType.Town);
}
return null;
}
}
}
| [
"topp3000@mail.ru"
] | topp3000@mail.ru |
56f52071319011ddd209da3b5ee1ee3a912ae4d2 | 12a4a256565bebbe2d6c92e7bd05a4c42ee00ad1 | /shjw/src/main/java/com/sojson/common/model/Kd.java | 69f76ba85144d7b7e1200c4526039f15f1a00edf | [] | no_license | xjmnmjd/test2 | 17c90be4419bdf9ceae5125473651967b596b6b2 | ed6a5351f8d03fadacfdaf3efbc8d40999b7f57b | refs/heads/master | 2020-03-21T20:43:11.241254 | 2018-06-28T14:26:49 | 2018-06-28T14:26:49 | 139,023,668 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,126 | java | package com.sojson.common.model;
import java.io.Serializable;
/**
* 快递实体
*
* @author zjf
* @version 1.0,2017年9月14日
*
*/
public class Kd implements Serializable {
private int kdid;
private String kd_no;
private String kd_company;
private int orderid;
private String insert_time;
public int getKdid() {
return kdid;
}
public void setKdid(int kdid) {
this.kdid = kdid;
}
public String getKd_no() {
return kd_no;
}
public void setKd_no(String kd_no) {
this.kd_no = kd_no;
}
public String getKd_company() {
return kd_company;
}
public void setKd_company(String kd_company) {
this.kd_company = kd_company;
}
public int getOrderid() {
return orderid;
}
public void setOrderid(int orderid) {
this.orderid = orderid;
}
public String getInsert_time() {
return insert_time;
}
public void setInsert_time(String insert_time) {
this.insert_time = insert_time;
}
@Override
public String toString() {
return "Kd [kdid=" + kdid + ", kd_no=" + kd_no + ", kd_company="
+ kd_company + ", orderid=" + orderid + ", insert_time="
+ insert_time + "]";
}
}
| [
"xujunit@163.com"
] | xujunit@163.com |
150f98c0398d63b1d41fe67d204e6c2dee7391e4 | 2581526d7c741bcf4cb3aedcd471e424f25354dc | /app/src/main/java/com/tutorialsbuzz/navigationdrawer/activity/NotificationDescription.java | 21b5110c98a4f69b7185cff23214129f4c98cd9d | [] | no_license | Shankar1056/iasucc | 1951ead3077be3facabf88217736fc322d82bca1 | 48cd090911ca93455496346dd2395a2e04aede72 | refs/heads/master | 2020-03-07T04:45:43.786541 | 2018-03-29T11:57:25 | 2018-03-29T11:57:25 | 127,275,889 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 4,091 | java | package com.tutorialsbuzz.navigationdrawer.activity;
import android.content.Intent;
import android.os.Bundle;
import android.os.StrictMode;
import android.support.v4.view.ViewPager;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.widget.Toolbar;
import android.view.Menu;
import android.view.View;
import android.view.WindowManager;
import android.widget.ImageView;
import android.widget.TextView;
import com.tutorialsbuzz.navigationdrawer.activity.adapter.NotificationDescriptionPagerAdapter;
import com.tutorialsbuzz.navigationdrawer.activity.common.ClsGeneral;
import com.tutorialsbuzz.navigationdrawer.activity.model.NotificationModel;
import com.ucc.application.R;
import java.util.ArrayList;
/**
* Created by indglobal on 11/4/16.
*/
public class NotificationDescription extends AppCompatActivity {
TextView actionbar_title;
NotificationDescriptionPagerAdapter mCustomPagerAdapter;
ViewPager mViewPager;
Toolbar toolbar;
int position,total_length;
private ImageView refresh;
String name,currentDate=null;
public static ArrayList<NotificationModel> arrayList;
@Override
protected void onCreate(Bundle savedInstanceState) {
getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN, WindowManager.LayoutParams.FLAG_FULLSCREEN);
super.onCreate(savedInstanceState);
if (android.os.Build.VERSION.SDK_INT > 9) {
StrictMode.ThreadPolicy policy =
new StrictMode.ThreadPolicy.Builder().permitAll().build();
StrictMode.setThreadPolicy(policy);
}
String headerlanguage = ClsGeneral.getPreferences(NotificationDescription.this, "choosedlanguage");
ClsGeneral.updatelanguage(headerlanguage);
setContentView(R.layout.notification_description_layout);
toolbar = (Toolbar) findViewById(R.id.toolbar);
actionbar_title=(TextView)findViewById(R.id.actionbar_title);
setSupportActionBar(toolbar);
getSupportActionBar().setDisplayShowHomeEnabled(true);
getSupportActionBar().setDisplayHomeAsUpEnabled(true);
refresh=(ImageView)findViewById(R.id.refresh);
refresh.setVisibility(View.GONE);
Intent i =getIntent();
name=i.getStringExtra("guidelineLayout");
if (name.equalsIgnoreCase("Guidelines")) {
actionbar_title.setText(getResources().getString(R.string.guidlines_description));
}
if (name.equalsIgnoreCase("Notifications")) {
actionbar_title.setText(getResources().getString(R.string.notification_description));
}
toolbar.setNavigationOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
finish();
}
});
arrayList = new ArrayList<NotificationModel>();
arrayList=(ArrayList<NotificationModel>) getIntent().getSerializableExtra("arraylist");
position = getIntent().getExtras().getInt("position");
total_length=getIntent().getExtras().getInt("total_length");
currentDate=getIntent().getStringExtra("currentDate");
mCustomPagerAdapter = new NotificationDescriptionPagerAdapter(NotificationDescription.this,getSupportFragmentManager(),arrayList,total_length,currentDate);
mViewPager = (ViewPager) findViewById(R.id.view_pager);
mViewPager.setAdapter(mCustomPagerAdapter);
mViewPager.setCurrentItem(position);
}
public void setCurrentItem (int item, boolean smoothScroll) {
mViewPager.setCurrentItem(item, smoothScroll);
}
@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_main, menu);
return true;
}
@Override
protected void onResume() {
super.onResume();
String headerlanguage = ClsGeneral.getPreferences(NotificationDescription.this, "choosedlanguage");
ClsGeneral.updatelanguage(headerlanguage);
}
}
| [
"shankar@spotsoon.com"
] | shankar@spotsoon.com |
93a3137de9dbdb0615c649d435b886e4728dbf53 | 3b3e83914533cd1a653a39cb7ad17ae3b3c691a1 | /src/online/wangxuan/annotation/UseCaseTracker.java | 110a2fb9b6d5bf57e75295262c4cce68e0835ef0 | [] | no_license | Demons-wx/ThinkInJava | 7efe6a3f6a3a42a0001eab0fe1e60fc428c9a5ad | 5e34f65bb88ca56571ee7d46cf6bdfec26d16916 | refs/heads/master | 2021-07-22T17:13:05.678069 | 2018-04-24T10:01:12 | 2018-04-24T10:01:12 | 89,494,685 | 1 | 0 | null | null | null | null | UTF-8 | Java | false | false | 956 | java | package online.wangxuan.annotation;
import java.lang.reflect.Method;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
/**
* @author wangxuan
* @date 2018/4/8 下午11:16
*/
public class UseCaseTracker {
public static void trackUseCases(List<Integer> useCases, Class<?> cl) {
for (Method m : cl.getDeclaredMethods()) {
UseCase uc = m.getAnnotation(UseCase.class);
if (uc != null) {
System.out.println("Found Use Case: " + uc.id() + " " + uc.description());
useCases.remove(new Integer(uc.id()));
}
}
for (int i : useCases) {
System.out.println("Warning: Missing use case-" + i);
}
}
public static void main(String[] args) {
List<Integer> useCases = new ArrayList<>();
Collections.addAll(useCases, 47, 48, 49, 50);
trackUseCases(useCases, PasswordUtils.class);
}
}
| [
"demons_wx@163.com"
] | demons_wx@163.com |
4270b986c221979683235ff70cfddc19eadf423b | 764c94d4cf116b0e4d98a38e842e4e6a0468a666 | /ebaysdkcore/src/main/java/com/ebay/soap/eBLBaseComponents/PictureManagerPictureDisplayType.java | 01499323ba5666bbae81a6e44b92b38d6b11f209 | [] | no_license | linus87/ebaysdk | 26dde361dbb75e03fca137eaf6a61c5e892f1303 | 2fb2cbade57ae654fa83ae1b7c5f3e4f741b1fc1 | refs/heads/master | 2023-07-19T10:34:02.644641 | 2021-06-01T13:30:36 | 2021-06-01T13:30:36 | 150,661,586 | 1 | 0 | null | 2023-07-18T06:53:34 | 2018-09-28T00:06:01 | Java | UTF-8 | Java | false | false | 6,463 | java |
package com.ebay.soap.eBLBaseComponents;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlAnyElement;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlSchemaType;
import javax.xml.bind.annotation.XmlType;
import org.w3c.dom.Element;
/**
*
* This type is deprecated.
*
*
* <p>Java class for PictureManagerPictureDisplayType complex type.
*
* <p>The following schema fragment specifies the expected content contained within this class.
*
* <pre>
* <complexType name="PictureManagerPictureDisplayType">
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <element name="DisplayType" type="{urn:ebay:apis:eBLBaseComponents}PictureManagerPictureDisplayTypeCodeType" minOccurs="0"/>
* <element name="URL" type="{http://www.w3.org/2001/XMLSchema}anyURI" minOccurs="0"/>
* <element name="Size" type="{http://www.w3.org/2001/XMLSchema}int" minOccurs="0"/>
* <element name="Height" type="{http://www.w3.org/2001/XMLSchema}int" minOccurs="0"/>
* <element name="Width" type="{http://www.w3.org/2001/XMLSchema}int" minOccurs="0"/>
* <any/>
* </sequence>
* </restriction>
* </complexContent>
* </complexType>
* </pre>
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "PictureManagerPictureDisplayType", propOrder = {
"displayType",
"url",
"size",
"height",
"width",
"any"
})
public class PictureManagerPictureDisplayType
implements Serializable
{
private final static long serialVersionUID = 12343L;
@XmlElement(name = "DisplayType")
protected PictureManagerPictureDisplayTypeCodeType displayType;
@XmlElement(name = "URL")
@XmlSchemaType(name = "anyURI")
protected String url;
@XmlElement(name = "Size")
protected Integer size;
@XmlElement(name = "Height")
protected Integer height;
@XmlElement(name = "Width")
protected Integer width;
@XmlAnyElement(lax = true)
protected List<Object> any;
/**
* Gets the value of the displayType property.
*
* @return
* possible object is
* {@link PictureManagerPictureDisplayTypeCodeType }
*
*/
public PictureManagerPictureDisplayTypeCodeType getDisplayType() {
return displayType;
}
/**
* Sets the value of the displayType property.
*
* @param value
* allowed object is
* {@link PictureManagerPictureDisplayTypeCodeType }
*
*/
public void setDisplayType(PictureManagerPictureDisplayTypeCodeType value) {
this.displayType = value;
}
/**
* Gets the value of the url property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getURL() {
return url;
}
/**
* Sets the value of the url property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setURL(String value) {
this.url = value;
}
/**
* Gets the value of the size property.
*
* @return
* possible object is
* {@link Integer }
*
*/
public Integer getSize() {
return size;
}
/**
* Sets the value of the size property.
*
* @param value
* allowed object is
* {@link Integer }
*
*/
public void setSize(Integer value) {
this.size = value;
}
/**
* Gets the value of the height property.
*
* @return
* possible object is
* {@link Integer }
*
*/
public Integer getHeight() {
return height;
}
/**
* Sets the value of the height property.
*
* @param value
* allowed object is
* {@link Integer }
*
*/
public void setHeight(Integer value) {
this.height = value;
}
/**
* Gets the value of the width property.
*
* @return
* possible object is
* {@link Integer }
*
*/
public Integer getWidth() {
return width;
}
/**
* Sets the value of the width property.
*
* @param value
* allowed object is
* {@link Integer }
*
*/
public void setWidth(Integer value) {
this.width = value;
}
/**
*
*
* @return
* array of
* {@link Object }
* {@link Element }
*
*/
public Object[] getAny() {
if (this.any == null) {
return new Object[ 0 ] ;
}
return ((Object[]) this.any.toArray(new Object[this.any.size()] ));
}
/**
*
*
* @return
* one of
* {@link Object }
* {@link Element }
*
*/
public Object getAny(int idx) {
if (this.any == null) {
throw new IndexOutOfBoundsException();
}
return this.any.get(idx);
}
public int getAnyLength() {
if (this.any == null) {
return 0;
}
return this.any.size();
}
/**
*
*
* @param values
* allowed objects are
* {@link Object }
* {@link Element }
*
*/
public void setAny(Object[] values) {
this._getAny().clear();
int len = values.length;
for (int i = 0; (i<len); i ++) {
this.any.add(values[i]);
}
}
protected List<Object> _getAny() {
if (any == null) {
any = new ArrayList<Object>();
}
return any;
}
/**
*
*
* @param value
* allowed object is
* {@link Object }
* {@link Element }
*
*/
public Object setAny(int idx, Object value) {
return this.any.set(idx, value);
}
}
| [
"lyan2@ebay.com"
] | lyan2@ebay.com |
0f4b7d8a16813b0c644789530e0c3d02f1f5ed1d | 0f5cbcfe2503821e0293e3f5ddf7d87483d18a3e | /web13/src/com/asit/dao/DeleteCreatorDaoInterface.java | 2c0dfa243c2cd6bc533ac30c54dd867bc42cc9b3 | [] | no_license | asitghosh/TechChallengeAsitUpdated | eaa8103893b97cb58460ec241b2453c0a0680a6d | 39ec636424f6e381b02deb5cfeeffe1a1dc61368 | refs/heads/master | 2020-05-25T19:17:23.022988 | 2017-03-14T14:24:54 | 2017-03-14T14:24:54 | 84,957,535 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 223 | java | package com.asit.dao;
import java.sql.SQLException;
import com.asit.domain.AccountDomain;
public interface DeleteCreatorDaoInterface {
public void deleteCreatorDao(AccountDomain accountDomainObj) throws SQLException;
}
| [
"asitghosh.cs@gmail.com"
] | asitghosh.cs@gmail.com |
56f225ab01fe6f700471934624f68d693a471cfd | 4e815704d10bbbb063ea5991c288e19dd58c35d8 | /src/main/java/dev/blachut/svelte/lang/parsing/html/ExtendableHtmlParsing.java | 4b5335e5e4425f444881e5a2967e65c27e6e8606 | [
"MIT"
] | permissive | deboxlibrary/svelte-intellij | dd4572f2e16e70edef6c385d58eb4b88779de668 | f91c94557a20322bfec12f8b28dbab5e7c00db49 | refs/heads/master | 2022-12-30T04:39:32.684006 | 2020-10-18T01:00:32 | 2020-10-18T01:00:32 | 295,261,422 | 0 | 0 | MIT | 2020-09-14T00:20:46 | 2020-09-14T00:12:05 | null | UTF-8 | Java | false | false | 23,210 | java | // Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
/*
* @author max
*/
package dev.blachut.svelte.lang.parsing.html;
import com.intellij.codeInsight.completion.CompletionUtilCore;
import com.intellij.codeInsight.daemon.XmlErrorBundle;
import com.intellij.lang.PsiBuilder;
import com.intellij.lang.html.HtmlParsing;
import com.intellij.openapi.util.text.StringUtil;
import com.intellij.psi.tree.ICustomParsingType;
import com.intellij.psi.tree.IElementType;
import com.intellij.psi.tree.ILazyParseableElementType;
import com.intellij.psi.xml.XmlElementType;
import com.intellij.psi.xml.XmlTokenType;
import com.intellij.util.containers.Stack;
import com.intellij.xml.util.HtmlUtil;
import org.jetbrains.annotations.NonNls;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.util.Objects;
/**
* Created because HtmlParsing is not extendable enough to support Svelte overrides
*/
public class ExtendableHtmlParsing extends HtmlParsing {
@NonNls
private static final String TR_TAG = "tr";
@NonNls
private static final String TD_TAG = "td";
@NonNls
private static final String TH_TAG = "th";
@NonNls
private static final String TABLE_TAG = "table";
private final PsiBuilder myBuilder;
private final Stack<String> myTagNamesStack = new Stack<>();
private final Stack<String> myOriginalTagNamesStack = new Stack<>();
private final Stack<PsiBuilder.Marker> myTagMarkersStack = new Stack<>();
@NonNls
private static final String COMPLETION_NAME = StringUtil.toLowerCase(CompletionUtilCore.DUMMY_IDENTIFIER_TRIMMED);
public ExtendableHtmlParsing(final PsiBuilder builder) {
super(builder);
myBuilder = builder;
}
public void parseDocument() {
final PsiBuilder.Marker document = mark();
while (token() == XmlTokenType.XML_COMMENT_START) {
parseComment();
}
parseProlog();
PsiBuilder.Marker error = null;
while (!eof()) {
final IElementType tt = token();
if (tt == XmlTokenType.XML_START_TAG_START) {
error = flushError(error);
parseTag();
} else if (tt == XmlTokenType.XML_COMMENT_START) {
error = flushError(error);
parseComment();
} else if (tt == XmlTokenType.XML_PI_START) {
error = flushError(error);
parseProcessingInstruction();
} else if (tt == XmlTokenType.XML_CHAR_ENTITY_REF || tt == XmlTokenType.XML_ENTITY_REF_TOKEN) {
parseReference();
} else if (tt == XmlTokenType.XML_REAL_WHITE_SPACE || tt == XmlTokenType.XML_DATA_CHARACTERS) {
error = flushError(error);
advance();
} else if (tt == XmlTokenType.XML_END_TAG_START) {
final PsiBuilder.Marker tagEndError = myBuilder.mark();
advance();
if (token() == XmlTokenType.XML_NAME) {
advance();
if (token() == XmlTokenType.XML_TAG_END) {
advance();
}
}
tagEndError.error(XmlErrorBundle.message("xml.parsing.closing.tag.matches.nothing"));
} else if (hasCustomTopLevelContent()) {
error = parseCustomTopLevelContent(error);
} else {
if (error == null) error = mark();
advance();
}
}
flushOpenTags();
myTagMarkersStack.clear();
myTagNamesStack.clear();
myOriginalTagNamesStack.clear();
if (error != null) {
error.error(XmlErrorBundle.message("top.level.element.is.not.completed"));
}
document.done(XmlElementType.HTML_DOCUMENT);
}
protected void flushOpenTags() {
while (hasTags()) {
final String tagName = myTagNamesStack.peek();
if (isEndTagRequired(tagName)) {
error(XmlErrorBundle.message("named.element.is.not.closed", myOriginalTagNamesStack.peek()));
}
doneTag();
}
}
protected boolean isEndTagRequired(@NotNull String tagName) {
return !HtmlUtil.isOptionalEndForHtmlTagL(tagName) && !"html".equals(tagName) && !"body".equals(tagName);
}
protected boolean hasCustomTopLevelContent() {
return false;
}
protected PsiBuilder.Marker parseCustomTopLevelContent(PsiBuilder.Marker error) {
return error;
}
protected boolean hasCustomTagContent() {
return false;
}
protected PsiBuilder.Marker parseCustomTagContent(PsiBuilder.Marker xmlText) {
return xmlText;
}
protected boolean hasCustomHeaderContent() {
return false;
}
protected void parseCustomHeaderContent() {
}
@Nullable
protected static PsiBuilder.Marker flushError(PsiBuilder.Marker error) {
if (error != null) {
error.error(XmlErrorBundle.message("xml.parsing.unexpected.tokens"));
}
return null;
}
private void parseDoctype() {
assert token() == XmlTokenType.XML_DOCTYPE_START : "Doctype start expected";
final PsiBuilder.Marker doctype = mark();
advance();
while (token() != XmlTokenType.XML_DOCTYPE_END && !eof()) advance();
if (eof()) {
error(XmlErrorBundle.message("xml.parsing.unexpected.end.of.file"));
} else {
advance();
}
doctype.done(XmlElementType.XML_DOCTYPE);
}
public void parseTag() {
assert token() == XmlTokenType.XML_START_TAG_START : "Tag start expected";
String originalTagName;
PsiBuilder.Marker xmlText = null;
while (!eof()) {
final IElementType tt = token();
if (tt == XmlTokenType.XML_START_TAG_START) {
xmlText = terminateText(xmlText);
final PsiBuilder.Marker tag = mark();
// Start tag header
advance();
if (token() != XmlTokenType.XML_NAME) {
error(XmlErrorBundle.message("xml.parsing.tag.name.expected"));
originalTagName = "";
} else {
originalTagName = Objects.requireNonNull(myBuilder.getTokenText());
advance();
}
String tagName = StringUtil.toLowerCase(originalTagName);
while (childTerminatesParentInStack(tagName)) {
PsiBuilder.Marker top = closeTag();
top.doneBefore(getHtmlTagElementType(), tag);
}
pushTag(tag, tagName, originalTagName);
parseHeader(tagName);
if (token() == XmlTokenType.XML_EMPTY_ELEMENT_END) {
advance();
doneTag();
continue;
}
if (token() == XmlTokenType.XML_TAG_END) {
advance();
} else {
error(XmlErrorBundle.message("tag.start.is.not.closed"));
doneTag();
continue;
}
if (isSingleTag(tagName, originalTagName)) {
final PsiBuilder.Marker footer = mark();
while (token() == XmlTokenType.XML_REAL_WHITE_SPACE) {
advance();
}
if (token() == XmlTokenType.XML_END_TAG_START) {
advance();
if (token() == XmlTokenType.XML_NAME) {
if (tagName.equalsIgnoreCase(myBuilder.getTokenText())) {
advance();
footer.drop();
if (token() == XmlTokenType.XML_TAG_END) {
advance();
}
doneTag();
continue;
}
}
}
footer.rollbackTo();
doneTag();
}
} else if (tt == XmlTokenType.XML_PI_START) {
xmlText = terminateText(xmlText);
parseProcessingInstruction();
} else if (tt == XmlTokenType.XML_ENTITY_REF_TOKEN || tt == XmlTokenType.XML_CHAR_ENTITY_REF) {
xmlText = startText(xmlText);
parseReference();
} else if (tt == XmlTokenType.XML_CDATA_START) {
xmlText = startText(xmlText);
parseCData();
} else if (tt == XmlTokenType.XML_COMMENT_START) {
xmlText = startText(xmlText);
parseComment();
} else if (tt == XmlTokenType.XML_BAD_CHARACTER) {
xmlText = startText(xmlText);
final PsiBuilder.Marker error = mark();
advance();
error.error(XmlErrorBundle.message("unescaped.ampersand.or.nonterminated.character.entity.reference"));
} else if (tt instanceof ICustomParsingType || tt instanceof ILazyParseableElementType) {
xmlText = terminateText(xmlText);
advance();
} else if (token() == XmlTokenType.XML_END_TAG_START) {
xmlText = terminateText(xmlText);
final PsiBuilder.Marker footer = mark();
advance();
if (token() == XmlTokenType.XML_NAME) {
String endName = StringUtil.toLowerCase(Objects.requireNonNull(myBuilder.getTokenText()));
final String parentTagName = !myTagNamesStack.isEmpty() ? myTagNamesStack.peek() : "";
if (!parentTagName.equals(endName) && !endName.endsWith(COMPLETION_NAME)) {
final boolean isOptionalTagEnd = HtmlUtil.isOptionalEndForHtmlTagL(parentTagName);
final boolean hasChancesToMatch = HtmlUtil.isOptionalEndForHtmlTagL(endName) ? childTerminatesParentInStack(endName) : isTagNameFurtherInStack(endName);
if (hasChancesToMatch) {
footer.rollbackTo();
if (!isOptionalTagEnd) {
error(XmlErrorBundle.message("named.element.is.not.closed", myOriginalTagNamesStack.peek()));
}
doneTag();
} else {
advance();
if (token() == XmlTokenType.XML_TAG_END) advance();
footer.error(XmlErrorBundle.message("xml.parsing.closing.tag.matches.nothing"));
}
continue;
}
advance();
while (token() != XmlTokenType.XML_TAG_END && token() != XmlTokenType.XML_START_TAG_START && token() != XmlTokenType.XML_END_TAG_START && !eof()) {
error(XmlErrorBundle.message("xml.parsing.unexpected.token"));
advance();
}
} else {
// error(XmlErrorBundle.message("xml.parsing.closing.tag.name.missing"));
error("Closing tag name missing");
}
footer.drop();
if (token() == XmlTokenType.XML_TAG_END) {
advance();
} else {
error(XmlErrorBundle.message("xml.parsing.closing.tag.is.not.done"));
}
if (hasTags()) doneTag();
} else if ((token() == XmlTokenType.XML_REAL_WHITE_SPACE || token() == XmlTokenType.XML_DATA_CHARACTERS) && !hasTags()) {
xmlText = terminateText(xmlText);
advance();
} else if (hasCustomTagContent()) {
xmlText = parseCustomTagContent(xmlText);
} else {
xmlText = startText(xmlText);
advance();
}
}
terminateText(xmlText);
}
protected boolean isSingleTag(@NotNull String tagName, @NotNull String originalTagName) {
return HtmlUtil.isSingleHtmlTagL(tagName);
}
protected boolean hasTags() {
return !myTagNamesStack.isEmpty();
}
protected void pushTag(PsiBuilder.Marker tagMarker, String tagName, String originalTagName) {
myTagMarkersStack.push(tagMarker);
myTagNamesStack.push(tagName);
myOriginalTagNamesStack.push(originalTagName);
}
protected PsiBuilder.Marker closeTag() {
myTagNamesStack.pop();
myOriginalTagNamesStack.pop();
return myTagMarkersStack.pop();
}
protected String peekTagName() {
return myTagNamesStack.peek();
}
protected PsiBuilder.Marker peekTagMarker() {
return myTagMarkersStack.peek();
}
protected int tagLevel() {
return myTagNamesStack.size();
}
protected boolean isTagNameFurtherInStack(@NotNull String endName) {
return myTagNamesStack.contains(endName);
}
private void doneTag() {
PsiBuilder.Marker tag = myTagMarkersStack.peek();
tag.done(getHtmlTagElementType());
final String tagName = myTagNamesStack.peek();
closeTag();
terminateAutoClosingParentTag(tag, tagName);
}
/**
* Handles things like {@code <p>parentTag<p>tag} which result in 2 sibling paragraphs
*/
protected void terminateAutoClosingParentTag(@NotNull PsiBuilder.Marker tag, @NotNull String tagName) {
final String parentTagName = hasTags() ? myTagNamesStack.peek() : "";
boolean isInlineTagContainer = HtmlUtil.isInlineTagContainerL(parentTagName);
boolean isOptionalTagEnd = HtmlUtil.isOptionalEndForHtmlTagL(parentTagName);
boolean isValidParent = isInlineTagContainer && isOptionalTagEnd;
if (isValidParent && HtmlUtil.isHtmlBlockTagL(tagName) && !HtmlUtil.isPossiblyInlineTag(tagName)) {
PsiBuilder.Marker top = closeTag();
top.doneBefore(getHtmlTagElementType(), tag);
}
}
protected IElementType getHtmlTagElementType() {
return XmlElementType.HTML_TAG;
}
private void parseHeader(String tagName) {
boolean freeMakerTag = !tagName.isEmpty() && '#' == tagName.charAt(0);
do {
final IElementType tt = token();
if (freeMakerTag) {
if (tt == XmlTokenType.XML_EMPTY_ELEMENT_END ||
tt == XmlTokenType.XML_TAG_END ||
tt == XmlTokenType.XML_END_TAG_START ||
tt == XmlTokenType.XML_START_TAG_START) break;
advance();
} else {
if (tt == XmlTokenType.XML_NAME) {
parseAttribute();
} else if (tt == XmlTokenType.XML_CHAR_ENTITY_REF || tt == XmlTokenType.XML_ENTITY_REF_TOKEN) {
parseReference();
} else if (hasCustomHeaderContent()) {
parseCustomHeaderContent();
} else {
break;
}
}
}
while (!eof());
}
private boolean childTerminatesParentInStack(final String childName) {
for (int i = myTagNamesStack.size() - 1; i >= 0; i--) {
String parentName = myTagNamesStack.get(i);
Boolean result = childTerminatesParent(childName, parentName, i + 1);
if (result != null) {
return result;
}
}
return false;
}
@Nullable
protected Boolean childTerminatesParent(final String childName, final String parentName, int tagLevel) {
final boolean isCell = TD_TAG.equals(childName) || TH_TAG.equals(childName);
final boolean isRow = TR_TAG.equals(childName);
final boolean isStructure = isStructure(childName);
final boolean isParentTable = TABLE_TAG.equals(parentName);
final boolean isParentStructure = isStructure(parentName);
if (isCell && (TR_TAG.equals(parentName) || isParentStructure || isParentTable) ||
isRow && (isParentStructure || isParentTable) ||
isStructure && isParentTable) {
return false;
}
if ("li".equals(childName) && ("ul".equals(parentName) || "ol".equals(parentName))) {
return false;
}
if ("dl".equals(parentName) && ("dd".equals(childName) || "dt".equals(childName))) {
return false;
}
if (HtmlUtil.canTerminate(childName, parentName)) {
return true;
}
return null;
}
private static boolean isStructure(String childName) {
return "thead".equals(childName) || "tbody".equals(childName) || "tfoot".equals(childName);
}
@NotNull
protected PsiBuilder.Marker startText(@Nullable PsiBuilder.Marker xmlText) {
if (xmlText == null) {
xmlText = mark();
}
return xmlText;
}
@Nullable
protected static PsiBuilder.Marker terminateText(@Nullable PsiBuilder.Marker xmlText) {
if (xmlText != null) {
xmlText.done(XmlElementType.XML_TEXT);
xmlText = null;
}
return xmlText;
}
protected void parseCData() {
assert token() == XmlTokenType.XML_CDATA_START;
final PsiBuilder.Marker cdata = mark();
while (token() != XmlTokenType.XML_CDATA_END && !eof()) {
advance();
}
if (!eof()) {
advance();
}
cdata.done(XmlElementType.XML_CDATA);
}
protected void parseComment() {
final PsiBuilder.Marker comment = mark();
advance();
while (true) {
final IElementType tt = token();
if (tt == XmlTokenType.XML_COMMENT_CHARACTERS || tt == XmlTokenType.XML_CONDITIONAL_COMMENT_START
|| tt == XmlTokenType.XML_CONDITIONAL_COMMENT_START_END || tt == XmlTokenType.XML_CONDITIONAL_COMMENT_END_START
|| tt == XmlTokenType.XML_CONDITIONAL_COMMENT_END) {
advance();
continue;
}
if (tt == XmlTokenType.XML_ENTITY_REF_TOKEN || tt == XmlTokenType.XML_CHAR_ENTITY_REF) {
parseReference();
continue;
}
if (tt == XmlTokenType.XML_BAD_CHARACTER) {
final PsiBuilder.Marker error = mark();
advance();
error.error(XmlErrorBundle.message("xml.parsing.bad.character"));
continue;
}
if (tt == XmlTokenType.XML_COMMENT_END) {
advance();
}
break;
}
comment.done(XmlElementType.XML_COMMENT);
}
protected void parseReference() {
if (token() == XmlTokenType.XML_CHAR_ENTITY_REF) {
advance();
} else if (token() == XmlTokenType.XML_ENTITY_REF_TOKEN) {
final PsiBuilder.Marker ref = mark();
advance();
ref.done(XmlElementType.XML_ENTITY_REF);
} else {
assert false : "Unexpected token";
}
}
protected void parseAttribute() {
assert token() == XmlTokenType.XML_NAME;
final PsiBuilder.Marker att = mark();
advance();
if (token() == XmlTokenType.XML_EQ) {
advance();
parseAttributeValue();
}
att.done(XmlElementType.XML_ATTRIBUTE);
}
protected void parseAttributeValue() {
final PsiBuilder.Marker attValue = mark();
if (token() == XmlTokenType.XML_ATTRIBUTE_VALUE_START_DELIMITER) {
while (true) {
final IElementType tt = token();
if (tt == null || tt == XmlTokenType.XML_ATTRIBUTE_VALUE_END_DELIMITER || tt == XmlTokenType.XML_END_TAG_START || tt == XmlTokenType
.XML_EMPTY_ELEMENT_END ||
tt == XmlTokenType.XML_START_TAG_START) {
break;
}
if (tt == XmlTokenType.XML_BAD_CHARACTER) {
final PsiBuilder.Marker error = mark();
advance();
error.error(XmlErrorBundle.message("unescaped.ampersand.or.nonterminated.character.entity.reference"));
} else if (tt == XmlTokenType.XML_ENTITY_REF_TOKEN) {
parseReference();
} else {
advance();
}
}
if (token() == XmlTokenType.XML_ATTRIBUTE_VALUE_END_DELIMITER) {
advance();
} else {
error(XmlErrorBundle.message("xml.parsing.unclosed.attribute.value"));
}
} else {
if (token() != XmlTokenType.XML_TAG_END && token() != XmlTokenType.XML_EMPTY_ELEMENT_END) {
advance(); // Single token att value
}
}
attValue.done(XmlElementType.XML_ATTRIBUTE_VALUE);
}
private void parseProlog() {
while (true) {
final IElementType tt = token();
if (tt == XmlTokenType.XML_COMMENT_START) {
parseComment();
} else if (tt == XmlTokenType.XML_REAL_WHITE_SPACE) {
advance();
} else {
break;
}
}
final PsiBuilder.Marker prolog = mark();
while (true) {
final IElementType tt = token();
if (tt == XmlTokenType.XML_PI_START) {
parseProcessingInstruction();
} else if (tt == XmlTokenType.XML_DOCTYPE_START) {
parseDoctype();
} else if (tt == XmlTokenType.XML_COMMENT_START) {
parseComment();
} else if (tt == XmlTokenType.XML_REAL_WHITE_SPACE) {
advance();
} else {
break;
}
}
prolog.done(XmlElementType.XML_PROLOG);
}
protected void parseProcessingInstruction() {
assert token() == XmlTokenType.XML_PI_START;
final PsiBuilder.Marker pi = mark();
advance();
if (token() == XmlTokenType.XML_NAME || token() == XmlTokenType.XML_PI_TARGET) {
advance();
}
while (token() == XmlTokenType.XML_NAME) {
advance();
if (token() == XmlTokenType.XML_EQ) {
advance();
} else {
error(XmlErrorBundle.message("expected.attribute.eq.sign"));
}
parseAttributeValue();
}
if (token() == XmlTokenType.XML_PI_END) {
advance();
} else {
error(XmlErrorBundle.message("xml.parsing.unterminated.processing.instruction"));
}
pi.done(XmlElementType.XML_PROCESSING_INSTRUCTION);
}
protected void error(@NotNull String message) {
myBuilder.error(message);
}
}
| [
"blachut.tomasz@gmail.com"
] | blachut.tomasz@gmail.com |
68f0c23b3c4f6070542ef9f5cc0e338054583367 | 575b47da41b4290fbc67e328f7cdc73a8fc78360 | /ObserverFactory.java | 9b328e8744be5390bfab6549246976c8428a6a6e | [] | no_license | cristianpavel/ContentFilter | b4e9e5c58cf02732821697ad4a3988aae8302956 | 99cceb2bcbf9fc68cfde9ef4d1f2036c9bee76f3 | refs/heads/master | 2021-01-23T23:53:07.796100 | 2018-02-24T13:35:41 | 2018-02-24T13:35:41 | 122,743,153 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 3,050 | java | /**
* SingletonFactory pentru Observer. Creeaza
* observeri de tipul User, pornind de la un id
* si o expresie.
*
* @author Cristian Pavel - 324 CB
*
*/
public class ObserverFactory {
private static final ObserverFactory INSTANCE = new ObserverFactory();
private ObserverFactory() {
}
public static ObserverFactory getInstance() {
return INSTANCE;
}
/**
*
* @param id - id-ul observer-ului
* @param expression - expresia ce trebuie transformata in arbore
* @return un Observer de tipul User
*/
public Observer createObserver(int id, String expression) {
if (expression.equals("nil"))
return new User(id, null);
/**
* scapam de toate spatiile dintre paranteze
* si operatori
*/
expression = expression.replaceAll("\\( ","\\(");
expression = expression.replaceAll("\\) ","\\)");
expression = expression.replaceAll(" \\(","\\(");
expression = expression.replaceAll(" \\)","\\)");
return new User(id,generateTree(expression));
}
/**
* Genereaza un arbore (filtru) pornind de la o expresie).
* Apelez functia recursiv, spargand-o de fiecare data in 2.
* Ex. Avand (EXPR1) && (EXPR2) o sa ma duc mai intai pe stanga,
* rezolv EXPR1, dupa ma duc in dreapta, rezolv EXPR2, si la
* sfarsit fac AND node, care are copii nodurile radacina dat de
* EXPR1 si EXPR2.
*
* Cand ajung la caz de baza fara AND sau OR, creez operator
* cu OperatorsFactory si fac frunza.
*
*
* @param expression - din input
* @return arborele ce trebuie vizitat
*/
private Node generateTree(String expression) {
Node root = null;
//caz de baza
if (expression.indexOf("&&") == -1 && expression.indexOf("||") == -1) {
expression = expression.replaceAll("[()]", "").trim();
root = new BooleanNode(OperatorsFactory.getInstance().createOperator(expression));
return root;
}
/**
* Gasesc EXPR1 si EXPR2. Caut punctul in care se inchide
* prima paranteza deschisa.
*
*/
int nrUnclosed = 0;
int i = 0;
for (; i < expression.length(); i++) {
if (expression.charAt(i) == '(')
nrUnclosed++;
if (expression.charAt(i) == ')')
nrUnclosed--;
if (nrUnclosed == 0)
break;
}
/**
* daca daca am o singura paranteza (doar EXPR1, doar EXPR2)
* elimin paranteza de la inceput si de la sfarsit pentru ca e inutila
*
*/
if (i == expression.length() - 1) {
return generateTree(expression.substring(1,expression.length() - 1));
}
//iau jumatatea dreapta a expresiei
String halfExpression = expression.substring(i + 1).trim();
Node left = generateTree(expression.substring(1,i)); //recursiv EXPR1
Node right = generateTree(halfExpression.substring(2)); //recursiv EXPR1
if (halfExpression.charAt(0) == '&') //fac nodul radacina
root = new AndNode(left,right);
else
root = new OrNode(left,right);
return root;
}
}
| [
"pcristian97@googlemail.com"
] | pcristian97@googlemail.com |
7585046246c7b88a5d799439be700fea188aae70 | f2baee584724d2b94911898a75b0feba6451d564 | /Task_01b_04.java | 36f714818530a1b25e3678c5c713fad4932f16d6 | [] | no_license | Ivan-Salnikov/Java-Introducing-Tasks_code | 2992792d80df054735cd12a65bae763b44e78bbe | e904399100e4870e90c9a43c5c2532c14eb69c8d | refs/heads/main | 2023-03-16T08:57:37.608162 | 2021-03-05T12:39:39 | 2021-03-05T12:39:39 | 340,643,742 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 487 | java | package by.jonline.task01.main;
import java.math.*;
public class Task_01b_04 {
public static void main(String[] args) {
/*
* It is necessary to calculate the composition of squares of the first two hundred numbers.
*/
int x = 200;
BigInteger z = BigInteger.valueOf(1);
for (int n = 1; n <= x; n++) {
z = z.multiply(BigInteger.valueOf(n * n) );
}
System.out.println("Expression = " + z);
}
}
| [
"noreply@github.com"
] | noreply@github.com |
8aef18ff34355438a6d998bb0471de8be3f31ff8 | eac3f5e0ec9cb3bd9d8e7437b199e24f6c4d87e2 | /app/src/main/java/com/dagger/example/features/main/DownloadPhotosManager.java | 3ee83b287030f5230cb1cadd7c9f52497a6ce3d1 | [] | no_license | codeteo/DaggerExample | efbe107cf1cebcb83afc8154aefbd395d2bdc967 | c3df9661e2e7208d0b1723718dddaaf03fb5b130 | refs/heads/master | 2021-01-02T22:54:06.030799 | 2017-10-07T11:41:14 | 2017-10-07T11:41:14 | 99,416,598 | 0 | 0 | null | 2017-08-07T15:36:53 | 2017-08-05T10:42:11 | Java | UTF-8 | Java | false | false | 6,026 | java | package com.dagger.example.features.main;
import android.app.Application;
import android.app.DownloadManager;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.content.IntentFilter;
import android.database.Cursor;
import android.net.Uri;
import android.os.Environment;
import com.dagger.example.data.entities.PhotoDto;
import java.io.File;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import io.realm.Realm;
import io.realm.RealmResults;
import timber.log.Timber;
/**
* Downloads images from network and saves them to app's internal storage.
* Uses {@link DownloadManager}
*/
public class DownloadPhotosManager {
private static final String SUFFIX = "jpeg";
private static final String DIR_NAME = "Dagger";
private BroadcastReceiver broadcastReceiver;
private Realm realm;
private Application application;
private RealmResults<PhotoDto> realmUrls;
private List<PhotoDto> toBeDownloadedList = new ArrayList<>();
public DownloadPhotosManager(Realm realm, Application application) {
this.realm = realm;
this.application = application;
}
public void execute() {
getUrlsFromDB();
executeRequest();
}
private void getUrlsFromDB() {
try(Realm realmInstance = realm.getDefaultInstance()) {
realmUrls = realmInstance.where(PhotoDto.class)
.findAll();
// remove urls that already have a photo stored
removeDownloadedPhotosUrls(getPhotosFilenames());
}
}
private void executeRequest() {
Timber.i("START executeRequest");
final DownloadManager downloadManager = (DownloadManager) application.getSystemService(Context.DOWNLOAD_SERVICE);
// contains ID for each download request
final long[] DL_ID = new long[toBeDownloadedList.size()];
for (int i = 0; i < toBeDownloadedList.size(); i++) {
DL_ID[i] = downloadManager.enqueue(createRequestForDM(toBeDownloadedList.get(i)));
}
// get notified when the downloadManager is complete
broadcastReceiver = new BroadcastReceiver() {
@Override
public void onReceive(Context context, Intent intent) {
// ID of completed download
long completedDownloadID = intent.getLongExtra(DownloadManager.EXTRA_DOWNLOAD_ID, -1L);
Timber.i("MESA sto onReceive with completedID == %d", completedDownloadID);
if (Arrays.asList(DL_ID).contains(completedDownloadID)) {
// get the path of the downloaded file
DownloadManager.Query query = new DownloadManager.Query();
query.setFilterById(completedDownloadID);
Cursor cursor = downloadManager.query(query);
if (!cursor.moveToFirst()) {
Timber.i("Download error: cursor is empty");
return;
}
if (cursor.getInt(cursor.getColumnIndex(DownloadManager.COLUMN_STATUS))
!= DownloadManager.STATUS_SUCCESSFUL) {
Timber.i("Download failed: no success status");
return;
}
String path = cursor.getString(cursor.getColumnIndex(DownloadManager.COLUMN_LOCAL_URI));
Timber.i("File downloadManager complete. Location: \n" + path);
}
}
};
// register receiver to listen for ACTION_DOWNLOAD_COMPLETE action
// TODO: 8/9/17 Dont forget to unregister receiver
application.registerReceiver(broadcastReceiver, new IntentFilter(DownloadManager.ACTION_DOWNLOAD_COMPLETE));
}
private DownloadManager.Request createRequestForDM(PhotoDto photoDto) {
DownloadManager.Request request = null;
try {
request = new DownloadManager.Request(Uri.parse(photoDto.getDownloadUrl()));
} catch (IllegalArgumentException e) {
Timber.i("Error == %s", e.getMessage());
}
// allow mobile and WiFi downloads
request.setAllowedNetworkTypes(DownloadManager.Request.NETWORK_MOBILE | DownloadManager.Request.NETWORK_WIFI);
request.setTitle("DM Example");
request.setDescription("Downloading file");
// set the destination path for this download
request.setDestinationInExternalPublicDir(Environment.DIRECTORY_PICTURES +
File.separator + DIR_NAME, photoDto.getId() + "." + SUFFIX);
request.allowScanningByMediaScanner();
return request;
}
/**
* Get the filenames of the files stored in "Pictures/Dagger" directory.
* @return list of filenames without the ".jpeg" suffix.
*/
private List<String> getPhotosFilenames() {
List<String> filenamesList = new ArrayList<>();
File picturesDir = new File(Environment.getExternalStorageDirectory(), "Pictures");
File daggerDir = new File(picturesDir, DIR_NAME);
if (daggerDir.exists()) {
for (File file : daggerDir.listFiles()) {
if (file.isFile()) {
String fileName = file.getName();
filenamesList.add(stripSuffix(fileName));
}
}
}
return filenamesList;
}
/**
* Removes ".jpeg" suffix from filename
* @return filename without suffix
*/
private String stripSuffix(String filename) {
return filename.replace(".jpeg", "");
}
/**
* Removes urls from the list of to-be-downloaded urls that already have
*
*/
private void removeDownloadedPhotosUrls(List<String> filenames) {
for (PhotoDto photoDto:realmUrls){
if (!filenames.contains(photoDto.getId())) {
toBeDownloadedList.add(photoDto);
}
}
}
}
| [
"ramones.teo@gmail.com"
] | ramones.teo@gmail.com |
c25b0b3882e701e6405561d3fe3e38be2633e58d | 70cdf4d61759ccb9ffaaecb6fa297ca85ca55faa | /java/crystal/labs/instavines/activity/Alxjames.java | 54db8386009ef52fa74ca4ef30726d28f07c83fa | [
"MIT"
] | permissive | NileshArnaiya/Slapstick | 9417d363cf0cefcc693e5eacf08efa215a74ad4e | 589b70d5538c70a9e3a595a01954335e68d39b7e | refs/heads/master | 2021-01-21T17:32:00.011697 | 2017-05-21T14:37:52 | 2017-05-21T14:37:52 | 91,962,623 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 14,240 | java | package crystal.labs.instavines.activity;
import android.accounts.AccountManager;
import android.content.Intent;
import android.os.Bundle;
import android.support.design.widget.CoordinatorLayout;
import android.support.design.widget.FloatingActionButton;
import android.support.design.widget.Snackbar;
import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentTransaction;
import android.support.v7.app.AppCompatActivity;
import android.text.TextUtils;
import android.view.LayoutInflater;
import android.view.View;
import android.widget.EditText;
import com.google.android.gms.common.AccountPicker;
import com.google.api.client.googleapis.extensions.android.gms.auth.GoogleAccountCredential;
import com.google.api.client.util.ExponentialBackOff;
import java.io.IOException;
import java.util.Arrays;
import java.util.HashMap;
import java.util.Map;
import crystal.labs.instavines.CustomApplication;
import crystal.labs.instavines.R;
import crystal.labs.instavines.async.GetUsernameTask;
import crystal.labs.instavines.fragment.VideoListFragment;
import crystal.labs.instavines.fragment.YoutubePlayerFragment;
import crystal.labs.instavines.pojo.PlaylistItem;
import crystal.labs.instavines.pojo.PlaylistResponse;
import crystal.labs.instavines.util.Constants;
import crystal.labs.instavines.util.NetworkUtil;
import fr.castorflex.android.smoothprogressbar.SmoothProgressBar;
import fr.castorflex.android.smoothprogressbar.SmoothProgressDrawable;
import retrofit2.Call;
import retrofit2.Callback;
import retrofit2.Response;
public class Alxjames extends AppCompatActivity implements VideoListFragment.OnItemSelectedListener, View.OnClickListener {
private static final int REQUEST_CODE_PICK_ACCOUNT = 1000;
private static final int REQUEST_AUTHORIZATION = 55664;
private SmoothProgressBar mPocketBar;
private String nextPageToken;
private String OAuthToken;
private int totalResults = 0;
private String mEmail;
private String playlistId;
private VideoListFragment videoListFragment;
private YoutubePlayerFragment videoPlayerFragment;
private FloatingActionButton fab;
private CoordinatorLayout mView;
private Snackbar mSnackbar;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_home_screen);
initView();
LayoutInflater inflater = getLayoutInflater();
View alertLayout = inflater.inflate(R.layout.playlist_dialog_layout, null);
Intent i = getIntent();
final EditText etPlaylistId = (EditText) alertLayout.findViewById(R.id.et_playlist_id);
String anyshow = i.getStringExtra("mrbean");
etPlaylistId.setText(anyshow);
if (!TextUtils.isEmpty(etPlaylistId.getText().toString())) {
playlistId = etPlaylistId.getText().toString().trim();
getAnyPlaylist();
}
if (savedInstanceState != null) {
videoListFragment = (VideoListFragment) getSupportFragmentManager().findFragmentByTag(VideoListFragment.class.getSimpleName());
videoPlayerFragment = (YoutubePlayerFragment) getSupportFragmentManager().findFragmentByTag(YoutubePlayerFragment.class.getSimpleName());
switchVideoListFragment(videoListFragment, VideoListFragment.class.getSimpleName());
switchVideoPlayerFragment(videoPlayerFragment, YoutubePlayerFragment.class.getSimpleName());
} else {
// pickUserAccount();
videoListFragment = VideoListFragment.newInstance();
videoPlayerFragment = YoutubePlayerFragment.newInstance();
switchVideoListFragment(videoListFragment, VideoListFragment.class.getSimpleName());
switchVideoPlayerFragment(videoPlayerFragment, YoutubePlayerFragment.class.getSimpleName());
}
}
private void initView() {
mView = (CoordinatorLayout) findViewById(R.id.coordinator_layout);
mPocketBar = (SmoothProgressBar) findViewById(R.id.pocketProgressBar);
mPocketBar.setSmoothProgressDrawableCallbacks(new SmoothProgressDrawable.Callbacks() {
@Override
public void onStop() {
mPocketBar.setVisibility(View.INVISIBLE);
}
@Override
public void onStart() {
mPocketBar.setVisibility(View.VISIBLE);
}
});
mSnackbar = Snackbar.make(mView, getString(R.string.fetch_token_msg), Snackbar.LENGTH_INDEFINITE);
}
private void pickUserAccount() {
String[] accountTypes = new String[]{"com.google"};
Intent mIntent = AccountPicker.newChooseAccountIntent(null, null,
accountTypes, false, null, null, null, null);
if (mIntent.resolveActivity(getPackageManager()) != null) {
startActivityForResult(mIntent, REQUEST_CODE_PICK_ACCOUNT);
}
}
@Override
public void onActivityResult(int requestCode, int resultCode, Intent data) {
super.onActivityResult(requestCode, resultCode, data);
if (requestCode == REQUEST_CODE_PICK_ACCOUNT) {
// Receiving a result from the AccountPicker
if (resultCode == RESULT_OK) {
mEmail = data.getStringExtra(AccountManager.KEY_ACCOUNT_NAME);
// With the account name acquired, go get the auth token
//getToken();
}
}
if (requestCode == REQUEST_AUTHORIZATION) {
if (resultCode == RESULT_OK) {
//getToken();
}
}
}
private void getToken() {
mSnackbar.show();
if (NetworkUtil.isNetworkAvailable(getApplicationContext())) {
final GoogleAccountCredential googleCredential = GoogleAccountCredential.usingOAuth2(getApplicationContext(), Arrays.asList(Constants.SCOPES));
googleCredential.setBackOff(new ExponentialBackOff());
new GetUsernameTask(this, googleCredential.setSelectedAccountName(mEmail), new GetUsernameTask.InterfaceAsyncTask() {
@Override
public void onTokenReceived(String result) {
if (result != null) {
if (result.contains(" ")) {
OAuthToken = "Bearer " + result.split(" ")[0];
playlistId = result.split(" ")[1];
} else {
OAuthToken = "Bearer " + result;
}
getOauthPlaylist();
} else {
mSnackbar.setText(getString(R.string.token_error_msg));
}
}
}).execute();
} else {
mSnackbar.setText(getString(R.string.internet_error_msg));
mSnackbar.setAction("Retry", new View.OnClickListener() {
@Override
public void onClick(View v) {
mSnackbar.dismiss();
//getToken();
}
});
}
}
private void getOauthPlaylist() {
mSnackbar.setText(getString(R.string.load_playlist_msg));
mSnackbar.show();
Map<String, String> firstFilters = new HashMap<>();
firstFilters.put("part", "snippet");
firstFilters.put("maxResults", "50");
firstFilters.put("playlistId", playlistId);
mPocketBar.progressiveStart();
Call<PlaylistResponse> getOauthPlaylist = CustomApplication.getYoutubeClient().getService().getOauthPlaylist(OAuthToken, firstFilters);
getOauthPlaylist.enqueue(new Callback<PlaylistResponse>() {
@Override
public void onResponse(Response<PlaylistResponse> playlistResponse) {
mPocketBar.progressiveStop();
mSnackbar.dismiss();
if (playlistResponse.isSuccess() && playlistResponse.body().getPlaylistItems().size() != 0) {
totalResults = playlistResponse.body().getResponsePageInfo().getTotalResults();
nextPageToken = playlistResponse.body().getNextPageToken();
if (videoListFragment != null) {
videoListFragment.loadList(OAuthToken, playlistId, nextPageToken, playlistResponse.body().getPlaylistItems());
}
if (videoPlayerFragment != null) {
videoPlayerFragment.setVideoId(playlistResponse.body().getPlaylistItems().get(0).getItemSnippet().getSnippetResourceId().getVideoId());
}
}
}
@Override
public void onFailure(Throwable t) {
mPocketBar.progressiveStop();
if (t instanceof IOException) {
mSnackbar.setText(getString(R.string.internet_error_msg));
mSnackbar.setAction("Retry", new View.OnClickListener() {
@Override
public void onClick(View v) {
mSnackbar.dismiss();
getOauthPlaylist();
}
});
}
}
});
}
private void getAnyPlaylist() {
mSnackbar.setText(getString(R.string.load_playlist_msg));
mSnackbar.show();
Map<String, String> firstFilters = new HashMap<>();
firstFilters.put("part", "snippet");
firstFilters.put("maxResults", "50");
firstFilters.put("playlistId", playlistId);
firstFilters.put("key", Constants.API_KEY);
mPocketBar.progressiveStart();
Call<PlaylistResponse> getAnyPlaylist = CustomApplication.getYoutubeClient().getService().getAnyPlaylist(firstFilters);
getAnyPlaylist.enqueue(new Callback<PlaylistResponse>() {
@Override
public void onResponse(Response<PlaylistResponse> playlistResponse) {
mPocketBar.progressiveStop();
mSnackbar.dismiss();
if (playlistResponse.isSuccess() && playlistResponse.body().getPlaylistItems().size() != 0) {
totalResults = playlistResponse.body().getResponsePageInfo().getTotalResults();
nextPageToken = playlistResponse.body().getNextPageToken();
if (videoListFragment != null) {
videoListFragment.loadList(null, playlistId, nextPageToken, playlistResponse.body().getPlaylistItems());
}
if (videoPlayerFragment != null) {
videoPlayerFragment.setVideoId(playlistResponse.body().getPlaylistItems().get(0).getItemSnippet().getSnippetResourceId().getVideoId());
}
}
}
@Override
public void onFailure(Throwable t) {
mPocketBar.progressiveStop();
if (t instanceof IOException) {
mSnackbar.setText(getString(R.string.internet_error_msg));
mSnackbar.setAction("Retry", new View.OnClickListener() {
@Override
public void onClick(View v) {
mSnackbar.dismiss();
getAnyPlaylist();
}
});
}
}
});
}
private void switchVideoPlayerFragment(Fragment mTarget, String tag) {
if (mTarget != null && !mTarget.isInLayout()) {
getSupportFragmentManager().beginTransaction()
.replace(R.id.video_player_container, mTarget, tag)
.setTransition(FragmentTransaction.TRANSIT_FRAGMENT_OPEN)
.commit();
}
}
private void switchVideoListFragment(Fragment mTarget, String tag) {
if (mTarget != null && !mTarget.isInLayout()) {
getSupportFragmentManager().beginTransaction()
.replace(R.id.video_list_container, mTarget, tag)
.setTransition(FragmentTransaction.TRANSIT_FRAGMENT_OPEN)
.commit();
}
}
@Override
public void onItemSelected(PlaylistItem playlistItem) {
if (videoPlayerFragment != null) {
videoPlayerFragment.setVideoId(playlistItem.getItemSnippet().getSnippetResourceId().getVideoId());
}
}
@Override
public void onClick(View v) {
}
// @Override
// public void onClick(View view) {
// switch (view.getId()) {
// case R.id.fab:
// fab.hide();
//
// break;
// }
// }
// public void displayPlaylistDialog() {
// LayoutInflater inflater = getLayoutInflater();
// View alertLayout = inflater.inflate(R.layout.playlist_dialog_layout, null);
// final EditText etPlaylistId = (EditText) alertLayout.findViewById(R.id.et_playlist_id);
// etPlaylistId.setText("PLrQwDBhnZHYo5qASKSCQdF8sZHSVOrHuE");
//
// AlertDialog.Builder alert = new AlertDialog.Builder(this);
// alert.setView(alertLayout);
// alert.setCancelable(true);
// alert.setNegativeButton("Cancel", null);
// alert.setPositiveButton("Fetch", new DialogInterface.OnClickListener() {
//
// @Override
// public void onClick(DialogInterface dialog, int which) {
// // code for matching password
// if (!TextUtils.isEmpty(etPlaylistId.getText().toString())) {
// playlistId = etPlaylistId.getText().toString().trim();
// getAnyPlaylist();
// }
// }
// });
// AlertDialog dialog = alert.create();
// dialog.show();
// }
}
| [
"noreply@github.com"
] | noreply@github.com |
2cc79be4615ed96d4d96ba50e487b22e2e56cde7 | d523206fce46708a6fe7b2fa90e81377ab7b6024 | /com/google/android/gms/wallet/CreateWalletObjectsRequest.java | 6e3376ca5c49cc3faa04a173698fb4f05f8f2ed7 | [] | no_license | BlitzModder/BlitzJava | 0ee94cc069dc4b7371d1399ff5575471bdc88aac | 6c6d71d2847dfd5f9f4f7c716cd820aeb7e45f2c | refs/heads/master | 2021-06-11T15:04:05.571324 | 2017-02-04T16:04:55 | 2017-02-04T16:04:55 | 77,459,517 | 1 | 2 | null | null | null | null | UTF-8 | Java | false | false | 1,365 | java | package com.google.android.gms.wallet;
import android.os.Parcel;
import android.os.Parcelable.Creator;
import com.google.android.gms.common.internal.safeparcel.SafeParcelable;
public final class CreateWalletObjectsRequest
implements SafeParcelable
{
public static final Parcelable.Creator<CreateWalletObjectsRequest> CREATOR = new zzd();
private final int mVersionCode;
LoyaltyWalletObject zzbjd;
OfferWalletObject zzbje;
GiftCardWalletObject zzbjf;
CreateWalletObjectsRequest()
{
this.mVersionCode = 3;
}
CreateWalletObjectsRequest(int paramInt, LoyaltyWalletObject paramLoyaltyWalletObject, OfferWalletObject paramOfferWalletObject, GiftCardWalletObject paramGiftCardWalletObject)
{
this.mVersionCode = paramInt;
this.zzbjd = paramLoyaltyWalletObject;
this.zzbje = paramOfferWalletObject;
this.zzbjf = paramGiftCardWalletObject;
}
public int describeContents()
{
return 0;
}
public int getVersionCode()
{
return this.mVersionCode;
}
public void writeToParcel(Parcel paramParcel, int paramInt)
{
zzd.zza(this, paramParcel, paramInt);
}
}
/* Location: /Users/subdiox/Downloads/dex2jar-2.0/net.wargaming.wot.blitz-dex2jar.jar!/com/google/android/gms/wallet/CreateWalletObjectsRequest.class
* Java compiler version: 6 (50.0)
* JD-Core Version: 0.7.1
*/ | [
"subdiox@gmail.com"
] | subdiox@gmail.com |
676e3ea234c3dd6063c30b69605526120e02e609 | 0ad51dde288a43c8c2216de5aedcd228e93590ac | /com/vmware/converter/UplinkPortVlanUntrunkedEvent.java | 67a8dd5cb183ed709609a14eaff827def2b4c01f | [] | no_license | YujiEda/converter-sdk-java | 61c37b2642f3a9305f2d3d5851c788b1f3c2a65f | bcd6e09d019d38b168a9daa1471c8e966222753d | refs/heads/master | 2020-04-03T09:33:38.339152 | 2019-02-11T15:19:04 | 2019-02-11T15:19:04 | 155,151,917 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 3,718 | java | /**
* UplinkPortVlanUntrunkedEvent.java
*
* This file was auto-generated from WSDL
* by the Apache Axis 1.4 Apr 22, 2006 (06:55:48 PDT) WSDL2Java emitter.
*/
package com.vmware.converter;
public class UplinkPortVlanUntrunkedEvent extends com.vmware.converter.DvsHealthStatusChangeEvent implements java.io.Serializable {
public UplinkPortVlanUntrunkedEvent() {
}
public UplinkPortVlanUntrunkedEvent(
int key,
int chainId,
java.util.Calendar createdTime,
java.lang.String userName,
com.vmware.converter.DatacenterEventArgument datacenter,
com.vmware.converter.ComputeResourceEventArgument computeResource,
com.vmware.converter.HostEventArgument host,
com.vmware.converter.VmEventArgument vm,
com.vmware.converter.DatastoreEventArgument ds,
com.vmware.converter.NetworkEventArgument net,
com.vmware.converter.DvsEventArgument dvs,
java.lang.String fullFormattedMessage,
java.lang.String changeTag,
java.lang.String switchUuid,
com.vmware.converter.HostMemberHealthCheckResult healthResult) {
super(
key,
chainId,
createdTime,
userName,
datacenter,
computeResource,
host,
vm,
ds,
net,
dvs,
fullFormattedMessage,
changeTag,
switchUuid,
healthResult);
}
private java.lang.Object __equalsCalc = null;
public synchronized boolean equals(java.lang.Object obj) {
if (!(obj instanceof UplinkPortVlanUntrunkedEvent)) return false;
UplinkPortVlanUntrunkedEvent other = (UplinkPortVlanUntrunkedEvent) obj;
if (obj == null) return false;
if (this == obj) return true;
if (__equalsCalc != null) {
return (__equalsCalc == obj);
}
__equalsCalc = obj;
boolean _equals;
_equals = super.equals(obj);
__equalsCalc = null;
return _equals;
}
private boolean __hashCodeCalc = false;
public synchronized int hashCode() {
if (__hashCodeCalc) {
return 0;
}
__hashCodeCalc = true;
int _hashCode = super.hashCode();
__hashCodeCalc = false;
return _hashCode;
}
// Type metadata
private static org.apache.axis.description.TypeDesc typeDesc =
new org.apache.axis.description.TypeDesc(UplinkPortVlanUntrunkedEvent.class, true);
static {
typeDesc.setXmlType(new javax.xml.namespace.QName("urn:vim25", "UplinkPortVlanUntrunkedEvent"));
}
/**
* Return type metadata object
*/
public static org.apache.axis.description.TypeDesc getTypeDesc() {
return typeDesc;
}
/**
* Get Custom Serializer
*/
public static org.apache.axis.encoding.Serializer getSerializer(
java.lang.String mechType,
java.lang.Class _javaType,
javax.xml.namespace.QName _xmlType) {
return
new org.apache.axis.encoding.ser.BeanSerializer(
_javaType, _xmlType, typeDesc);
}
/**
* Get Custom Deserializer
*/
public static org.apache.axis.encoding.Deserializer getDeserializer(
java.lang.String mechType,
java.lang.Class _javaType,
javax.xml.namespace.QName _xmlType) {
return
new org.apache.axis.encoding.ser.BeanDeserializer(
_javaType, _xmlType, typeDesc);
}
}
| [
"yuji_eda@dwango.co.jp"
] | yuji_eda@dwango.co.jp |
ba5dc6791495f760a9e40509f7a9e31ea752c1b4 | 19245fb41975eaa5ffd5e4a5302913e347d32059 | /src/main/java/com/demo/graphql/queryresolver/ProductQueryResolver.java | e8609c69c3547c187887411335b9a75898a20bb8 | [] | no_license | dineshpabbi10/graphql-demo-dinesh | 4ee8b1140855ed64e67f1bc40e872fdb757c87bf | e7136a124700e7508150891a8f99783a3f8408b6 | refs/heads/master | 2023-08-23T11:12:41.477899 | 2021-10-16T23:39:09 | 2021-10-16T23:39:09 | 417,764,161 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 697 | java | package com.demo.graphql.queryresolver;
import com.coxautodev.graphql.tools.GraphQLQueryResolver;
import com.demo.graphql.service.ProductService;
import com.demo.graphql.views.ProductView;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import java.util.List;
@Component
public class ProductQueryResolver implements GraphQLQueryResolver {
@Autowired
ProductService productService;
public List<ProductView> findAllProducts(){
return productService.findAllProducts();
}
public List<ProductView> findAllProductsByIds(List<Integer> ids){
return productService.findAllProductsByIds(ids);
}
}
| [
"dineshpabbi10@gmail.com"
] | dineshpabbi10@gmail.com |
0386185d528e80ebddb00ea1411a8fe8a3fac86d | 8bf1ad574b6ff4ab624105172ea3a3467f49e06c | /ch08/src/main/java/com/apress/prospring3/ch8/domain/ContactTelDetail.java | 1e1ed10b400fc666ff1383eb1d3cc8fb01c3c158 | [] | no_license | jasox/spring3-pro | 98ba6d2ecb8a6e8662b826ab5206f0848f4cbc44 | 87cbb7f6b997ed6f26ea37664fd213ee1492f81e | refs/heads/master | 2021-01-20T08:25:08.339236 | 2017-03-04T17:40:51 | 2017-03-04T17:40:51 | 83,907,140 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 998 | java | /**
* Created on Oct 5, 2011
*/
package com.apress.prospring3.ch8.domain;
import java.io.Serializable;
/**
* @author Clarence
*
*/
public class ContactTelDetail implements Serializable {
private static final long serialVersionUID = 1L;
private Long id;
private Long contactId;
private String telType;
private String telNumber;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getTelType() {
return telType;
}
public void setTelType(String telType) {
this.telType = telType;
}
public String getTelNumber() {
return telNumber;
}
public void setTelNumber(String telNumber) {
this.telNumber = telNumber;
}
public Long getContactId() {
return contactId;
}
public void setContactId(Long contactId) {
this.contactId = contactId;
}
public String toString() {
return "Contact Tel Detail - Id: " + id + ", Contact id: " + contactId
+ ", Type: " + telType + ", Number: " + telNumber;
}
}
| [
"jasox@gazeta.pl"
] | jasox@gazeta.pl |
4fa659ec506b792be6d7995df603abdde6222f4b | 44d85c27b2157ea6cdab7fa8b920f43486a346cb | /persistencia/ConexaoMysql.java | 25cfe1c0dc727cce323afa2af76a1cd502ea06ef | [] | no_license | LucasRohr/Projeto-Integrador | d194e44ad02ae8d538eb617944b116d8aeaf4269 | 5b1c96c1f34b4bf4f81fcb74827b8b2a056e0a01 | refs/heads/master | 2020-04-01T02:48:31.458899 | 2018-11-24T13:46:18 | 2018-11-24T13:46:18 | 152,796,342 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,250 | java | package com.melodiam.persistencia;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;
public class ConexaoMysql {
private Connection conexao;
private String ip;
private String nomeBd;
private String login;
private String senha;
public ConexaoMysql(String ip, String nomeBd, String login, String senha) {
this.ip = ip;
this.nomeBd = nomeBd;
this.login = login;
this.senha = senha;
}
public Connection getConexao() {
return this.conexao;
}
public void abrirConexao() {
try {
Class.forName("com.mysql.cj.jdbc.Driver");
String endereco = "jdbc:mysql://"+this.ip+"/"+this.nomeBd+"?useTimezone=true&serverTimezone=UTC";
this.conexao = DriverManager.getConnection(endereco, login, senha);
} catch (ClassNotFoundException e) {
e.printStackTrace();
} catch (SQLException e) {
e.printStackTrace();
}
}
public void fecharConexao() {
if(this.conexao!=null) {
// VERIFICAR SE A CONEXAO TA ABERTA
try {
if(!this.conexao.isClosed()){
this.conexao.close();
}
} catch (SQLException e) {
e.printStackTrace();
}
}
}
}
| [
"noreply@github.com"
] | noreply@github.com |
5c68f7162977e9608d0fc95657d6fe94b8e08128 | db08d5f745fd3f2ccc253e1ad23210bb17a10760 | /open-bidder-netty-client/src/main/java/com/google/openbidder/netty/client/NettyClientFactory.java | 481daf5e07f134e8897a07d4c4457704b427091b | [
"Apache-2.0"
] | permissive | Essens/openbidder | ade2b73152dcca0ddedab9fba46ec9c2f04d94a0 | 59f724fe6e3dd969934b77ff5b059c97dc7d1d9c | refs/heads/Initial | 2021-01-22T01:42:40.351068 | 2015-08-30T06:15:46 | 2015-08-30T06:15:46 | 49,961,489 | 10 | 8 | null | 2016-01-19T15:20:14 | 2016-01-19T15:20:13 | null | UTF-8 | Java | false | false | 3,226 | java | /*
* Copyright 2013 Google Inc. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.google.openbidder.netty.client;
import static com.google.common.base.Preconditions.checkNotNull;
import com.google.common.util.concurrent.AbstractIdleService;
import com.beust.jcommander.internal.Nullable;
import io.netty.bootstrap.Bootstrap;
import io.netty.channel.Channel;
import io.netty.channel.ChannelFuture;
import io.netty.channel.ChannelInitializer;
import io.netty.channel.ChannelOption;
import io.netty.channel.EventLoopGroup;
import io.netty.channel.socket.SocketChannel;
import java.net.URI;
/**
* Baseline Netty client as a {@link com.google.common.util.concurrent.Service}.
* @param <M> Message type
*/
public class NettyClientFactory<M> extends AbstractIdleService {
private final EventLoopGroup clientGroup;
private final Class<? extends Channel> clientChannel;
private final ChannelInitializer<SocketChannel> channelInitializer;
@Nullable private final URI defaultUri;
private final Bootstrap bootstrap = new Bootstrap();
private final int connectionTimeout;
public NettyClientFactory(
EventLoopGroup clientGroup,
Class<? extends Channel> clientChannel,
ChannelInitializer<SocketChannel> channelInitializer,
int connectionTimeout) {
this(clientGroup, clientChannel, channelInitializer, connectionTimeout, /* default URL */ null);
}
public NettyClientFactory(
EventLoopGroup clientGroup,
Class<? extends Channel> clientChannel,
ChannelInitializer<SocketChannel> channelInitializer,
int connectionTimeout,
URI defaultUri) {
this.clientGroup = checkNotNull(clientGroup);
this.clientChannel = checkNotNull(clientChannel);
this.channelInitializer = checkNotNull(channelInitializer);
this.connectionTimeout = connectionTimeout;
this.defaultUri = defaultUri;
}
protected NettyClient<M> makeClient(ChannelFuture connectFuture) throws Exception {
return new NettyClient<>(connectFuture.sync().channel());
}
public NettyClient<M> connect() throws Exception {
checkNotNull(defaultUri, "Default URL must be set for calling connect()");
return connect(defaultUri);
}
public NettyClient<M> connect(URI uri) throws Exception {
return makeClient(bootstrap.validate().connect(uri.getHost(), uri.getPort()));
}
@Override
protected void startUp() throws Exception {
bootstrap.group(clientGroup)
.channel(clientChannel)
.option(ChannelOption.CONNECT_TIMEOUT_MILLIS, connectionTimeout)
.handler(channelInitializer);
}
@Override
protected void shutDown() throws Exception {
clientGroup.shutdownGracefully();
}
}
| [
"aakif@mobitrans.net"
] | aakif@mobitrans.net |
428a28b1d757c701446869a516c4d10399e8b084 | 4ab7707fe411d8560799762b418223b43df713c8 | /src/main/java/matsk/mszdqabbs/Service/CommentService.java | 4f5a0a65f7e162a184d04da047518edc16200b96 | [] | no_license | JL-shungen/mszdqabbs | 0d35ac03f4b1291d42b8a5142bfff5896328eb19 | e6a0b4fd8c0803c1d2ba5f34fa2b453856b8a358 | refs/heads/master | 2022-06-21T08:14:03.947972 | 2020-05-09T07:25:10 | 2020-05-09T07:25:10 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 579 | java | package matsk.mszdqabbs.Service;
import javax.servlet.http.HttpServletRequest;
public interface CommentService {
String handleNewComment(Integer to_comment,
Integer to_comment_type,
String content,
HttpServletRequest request);
String getTopComment(Integer to_comment, Integer to_comment_type);
String getRemainAllComment(Integer to_comment, Integer to_comment_type);
String likeOrDislike(int commentId, int likeOrDislike);
String getCommentsBy(Integer commentator);
}
| [
"1004529325@qq.com"
] | 1004529325@qq.com |
a7e93c758f28beee9ce533464467fda7f1745b29 | b3384cd8a0719e925cb3b0bab8cb5f46f06b2813 | /Practies_DataStructur/ExceptionHandling/src/com/mp/ExceptionThrow.java | c81a0c3938792b35d9affd5b2daeebea8dc57872 | [] | no_license | ManojPatidar007/DATASTRUCTURE | b33bdef64761592079ca54e23db2f759482695cd | e065096712918ace355214b975c8b6a2bfbf7fff | refs/heads/master | 2021-06-26T00:10:43.695403 | 2019-07-27T10:37:19 | 2019-07-27T10:37:19 | 149,109,301 | 0 | 0 | null | 2020-10-13T12:34:52 | 2018-09-17T10:34:35 | JavaScript | UTF-8 | Java | false | false | 282 | java | package com.mp;
public class ExceptionThrow {
public static void main(String ar[]){
try {
show();
} catch (Exception e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
private static void show() throws Exception {
throw new Exception();
}
}
| [
"manojpatidar315@gmail.com"
] | manojpatidar315@gmail.com |
cc72faa60726f4bc38ddd9eead09d3e0fa6214ea | 437cc123a8e67be2c9332cf7ffbbc17e003dbec0 | /HomeBrain/LocalScheduler/src/main/java/ir/tiroon/localScheduler/Scheduling/OptimizationAlgorithm.java | 24068f088ab4d881da60bb53f052db8e5f19c1f1 | [] | no_license | bmd007/SmartGridConsupmtionOpimizer | a2b511c82dc1df73b036ec3a9325c2f66c24de7f | e2535a261383ae54901d1bb9eea482fc32540921 | refs/heads/master | 2020-04-24T11:59:46.855017 | 2019-02-21T21:09:03 | 2019-02-21T21:09:03 | 171,943,228 | 1 | 0 | null | null | null | null | UTF-8 | Java | false | false | 4,366 | java | package ir.tiroon.localScheduler.Scheduling;
import ir.tiroon.localScheduler.model.UsageRecord;
import ir.tiroon.localScheduler.service.UsageRecordServices;
import ir.tiroon.localScheduler.util.*;
import okhttp3.RequestBody;
import org.json.JSONArray;
import org.json.JSONObject;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import java.math.BigInteger;
import java.sql.Date;
import java.util.ArrayList;
import java.util.List;
import static ir.tiroon.localScheduler.util.OkHttpUtil.JSON;
@Component
public class OptimizationAlgorithm {
Integer lastFullSumOnArea;
@Autowired
UsageRecordServices usageRecordServices;
Integer lastAreaSumPerHour[] = new Integer[24];
@Autowired
Oauth2Util oauth2Util;
public OptimizationAlgorithm() {
lastFullSumOnArea = 1000;
}
public void newArealSumReceived(String message) throws Exception {
JSONObject jo = new JSONObject(message);
lastFullSumOnArea = jo.getInt("sumResult");
JSONArray areaSumPerHourJsonArray = jo.getJSONArray("areaSumPerHourJsonArray");
for (int i = 0; i < 24; i++) {
lastAreaSumPerHour[i] = areaSumPerHourJsonArray.getInt(i);
System.out.println("BMD::r from sumP:" + areaSumPerHourJsonArray.getInt(i));
}
if (checkWhetherAnotherRoundIsNeeded())
runOneRound();
}
public void runOneRound() throws Exception {
optimizeRequestVectors();
//////////////////////////////////
oauth2Util.gainAccessToken();
PaillierUtil.gainPublicKey(oauth2Util.gainedAccessToken);
////////////////preparing the results of this round then send them to sum provider
JSONObject jo = new JSONObject();
JSONArray ja = new JSONArray();
ArrayList<Double> localSumPerHour = new ArrayList<>(24);
for (int i = 0; i < 24; i++)
localSumPerHour.add((double) 0);
ArrayList<UsageRecord> tomorrowUsageRecords =
usageRecordServices.getUsageRecordsByDate(new Date(Util.getTomorrowDate().getTime()));
final Double[] temp = new Double[1];
for (int j = 0; j < 24; j++) {
temp[0] = 0.0;
int finalJ = j;
tomorrowUsageRecords.stream().forEach(usageRecord ->
temp[0] += (usageRecord.getRequestVector().get(finalJ) * usageRecord.getDevice().getUsagePerHour()));
System.out.println("BMD::>> local sum on hour:" + finalJ + " is:" + temp[0]);
localSumPerHour.set(j, temp[0]);
ja.put(j, Util.objectToString(PaillierUtil.encrypt(BigInteger.valueOf(temp[0].longValue()))));
}
jo.put("localSumPerHourJsonArray", ja);
jo.put("localSum", Util.objectToString(PaillierUtil.encrypt(BigInteger.valueOf(150))));
RequestBody body = RequestBody.create(JSON, jo.toString());
OkHttpUtil okHttp = new OkHttpUtil(OkHttpUtil.accessTokenCredential(oauth2Util.gainedAccessToken));
System.out.println("BMD:abc:" + okHttp.post("http://localhost:8081/sump/tellLocalSchedulingResult", body));
}
//on each execution of this method, scheduledVectors of usageRecords should be set
void optimizeRequestVectors() {
ArrayList<UsageRecord> usageRecordsByDate = usageRecordServices.getUsageRecordsByDate(new Date(Util.getTomorrowDate().getTime()));
for (UsageRecord usageRecord : usageRecordsByDate) {
boolean isScheduleVectorUnTouched = true;
for (Integer temp : usageRecord.getScheduledVector())
if (temp != 0) {
isScheduleVectorUnTouched = false;
break;
}
List<Integer> scheduledVector;
if (isScheduleVectorUnTouched == true)
scheduledVector = usageRecord.getRequestVector();
else
scheduledVector = usageRecord.getScheduledVector();
for (int i = 0; i < 24; i++)
scheduledVector.set(i, scheduledVector.get(i) == 1 ? 0 : 1);
usageRecord.setScheduledVector(scheduledVector);
usageRecordServices.saveOrUpdate(usageRecord);
}
}
private boolean checkWhetherAnotherRoundIsNeeded() {
return Util.hourOfToday() < 22;
}
}
| [
"bmd579@gmail.com"
] | bmd579@gmail.com |
2e56efe1041234059935c3fc4583c112137e6eca | 22680d1080ebd59c5ef4177cd820f93ce5581ec4 | /src/main/java/com/eway/springboot1/config/LoginFilter.java | 9436364eaabf1f01ca734be12cbd88c36cd4ed41 | [] | no_license | codingKings/springboot1 | a31d07df56f15c73677d2b77868f6b8bb4b6c723 | 7ca718c070abdc209582d4cfc47595ba833e331b | refs/heads/master | 2020-07-22T03:08:18.900841 | 2019-09-08T08:30:55 | 2019-09-08T08:30:55 | 206,982,025 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,580 | java | package com.eway.springboot1.config;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.core.authority.AuthorityUtils;
import org.springframework.security.core.userdetails.User;
import org.springframework.security.core.userdetails.UserDetails;
import org.springframework.security.core.userdetails.UserDetailsService;
import org.springframework.security.core.userdetails.UsernameNotFoundException;
import org.springframework.security.crypto.password.PasswordEncoder;
import org.springframework.stereotype.Component;
/**
* @author 程龙
* @version 创建时间:2019年9月7日 下午9:52:12
* @ClassName 类名称:LoginFilter
* @Description 类描述:LoginFilter配置用户认证类实现UserDetailsService接口,因为我们是要有自己的一套用户体系,所以要配置用户认证
*/
@Component
public class LoginFilter implements UserDetailsService {
@Autowired
private PasswordEncoder passwordEncoder;
private Logger logger = LoggerFactory.getLogger("adminLogger");
@Override
public UserDetails loadUserByUsername(String username) throws UsernameNotFoundException {
logger.info("用户的用户名: {}", username);
// TODO 根据用户名,查找到对应的密码,与权限
//封装用户信息,并返回。参数分别是:用户名,密码,用户权限
User user = new User(username, passwordEncoder.encode("123456"),
AuthorityUtils.commaSeparatedStringToAuthorityList("admin"));
return user;
}
}
| [
"974966577@qq.com"
] | 974966577@qq.com |
c88920fe4fabae15f6fe4a8eace53b8585426497 | 407585e164319e95eae917dc996cd4e8d9abb276 | /Meteor/build/manifests/debug/gen/am1010/studio/BuildConfig.java | fbd8ada3d27f7ceb13331fc9ed6e0a0807c7857f | [] | no_license | home3k/meteor | 2f4745a369dd22aedee77558491b6a06dddebc2f | 8c2ae4700aeae838950ceeb273426165ce434570 | refs/heads/master | 2021-01-01T20:41:09.299238 | 2014-08-26T00:43:44 | 2014-08-26T00:43:44 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 184 | java | /*___Generated_by_IDEA___*/
/** Automatically generated file. DO NOT MODIFY */
package am1010.studio;
public final class BuildConfig {
public final static boolean DEBUG = true;
} | [
"home3k@gmail.com"
] | home3k@gmail.com |
78eaab344f46598e8324a345284244742c5315ac | bc67bd70aaa83b0c8c902defbb928838f5e9b668 | /java/1.x/picocontainer/tags/picocontainer-1_3-RC-1/gems/src/java/org/picocontainer/gems/util/Multicaster.java | 17d04752486c750789b84c645c5c9e67194243ae | [
"BSD-3-Clause"
] | permissive | codehaus/picocontainer | b07475fe034384926579e2b4f6f25e68f057cae2 | 7be6b8b0eb33421dc7a755817628e06b79bd879d | refs/heads/master | 2023-07-20T01:30:02.348980 | 2014-10-08T04:44:44 | 2014-10-08T04:44:44 | 36,501,409 | 2 | 2 | null | null | null | null | UTF-8 | Java | false | false | 2,021 | java | /*****************************************************************************
* Copyright (C) NanoContainer Organization. All rights reserved. *
* ------------------------------------------------------------------------- *
* The software in this package is published under the terms of the BSD *
* style license a copy of which has been included with this distribution in *
* the LICENSE.txt file. *
* *
* Original code by Aslak Hellesoy & Joerg Schaible *
*****************************************************************************/
package org.picocontainer.gems.util;
import com.thoughtworks.proxy.ProxyFactory;
import com.thoughtworks.proxy.toys.multicast.Multicasting;
import org.picocontainer.PicoContainer;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
/**
* Factory for creating a multicaster object that multicasts calls to all
* components in a PicoContainer instance.
*
* @author Aslak Hellesøy
* @author Chris Stevenson
* @author Paul Hammant
* @since 1.2
*/
public class Multicaster {
/**
* Create a {@link Multicasting} proxy for the components of a {@link PicoContainer}.
*
* @param pico the container
* @param callInInstantiationOrder <code>true</code> if the components will be called in instantiation order
* @param proxyFactory the ProxyFactory to use
* @return the Multicasting proxy
* @since 1.2
*/
public static Object object(PicoContainer pico, boolean callInInstantiationOrder, ProxyFactory proxyFactory) {
List copy = new ArrayList(pico.getComponentInstances());
if (!callInInstantiationOrder) {
// reverse the list
Collections.reverse(copy);
}
Object[] targets = copy.toArray();
return Multicasting.object(proxyFactory, targets);
}
} | [
"mauro@ac66bb80-72f5-0310-8d68-9f556cfffb23"
] | mauro@ac66bb80-72f5-0310-8d68-9f556cfffb23 |
11b516f38cc4d229ec5be06052eaa46ae3796e7f | 0a94f322120d9391f1d50a7d3dee21f484c37528 | /app/src/main/java/hipad/bill/ui/fragment/ExpendFragment.java | 6b2d217d399b2c3c1634ad132b5f5cf8e3d008ec | [] | no_license | bysr/BillProject | f2505aabc68e85fe3e02bf77f584cf36d3f0da16 | 6c372f818cb313a1eae9c98b1328d010c11d3056 | refs/heads/master | 2020-04-23T15:44:16.302014 | 2019-02-18T11:54:35 | 2019-02-18T11:54:35 | 107,770,291 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 8,354 | java | package hipad.bill.ui.fragment;
import android.content.Context;
import android.content.Intent;
import android.net.Uri;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v4.app.Fragment;
import android.support.v7.widget.DefaultItemAnimator;
import android.support.v7.widget.LinearLayoutManager;
import android.support.v7.widget.RecyclerView;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import org.xutils.DbManager;
import org.xutils.ex.DbException;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import hipad.bill.MyApplication;
import hipad.bill.adapter.IncomeAdapter;
import hipad.bill.bean.AccountBook;
import hipad.bill.bean.AccountInfo;
import hipad.bill.bean.MonthAccout;
import hipad.bill.ui.AccountMonthAty;
import hipad.bill.ui.ColumnInfoActivity;
import hipad.bill.utils.DateUtils;
import hipad.bill.utils.MathTools;
import hipad.billproject.R;
/**
* A simple {@link Fragment} subclass.
* Activities that contain this fragment must implement the
* {@link ExpendFragment.OnFragmentInteractionListener} interface
* to handle interaction events.
* Use the {@link ExpendFragment#newInstance} factory method to
* create an instance of this fragment.
*/
public class ExpendFragment extends BaseFragment {
// TODO: Rename parameter arguments, choose names that match
// the fragment initialization parameters, e.g. ARG_ITEM_NUMBER
private static final String ARG_PARAM1 = "param1";
private static final String ARG_PARAM2 = "param2";
private static final String ARG_PARAM = "param";
private OnFragmentInteractionListener mListener;
RecyclerView recycler_expend;
IncomeAdapter adapter;
List<AccountInfo> list;
private int cYear, cMonth;
private AccountBook book;
private MonthAccout monthAccout;
private DbManager db;
private Map<Integer, List<AccountInfo>> map;//存储一类账单
public ExpendFragment() {
// Required empty public constructor
}
/**
* Use this factory method to create a new instance of
* this fragment using the provided parameters.
*
* @return A new instance of fragment ExpendFragment.
*/
// TODO: Rename and change types and number of parameters
public static ExpendFragment newInstance(int year, int month, AccountBook book) {
ExpendFragment fragment = new ExpendFragment();
Bundle args = new Bundle();
args.putInt(ARG_PARAM1, year);
args.putInt(ARG_PARAM2, month);
args.putSerializable(ARG_PARAM, book);
fragment.setArguments(args);
return fragment;
}
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
if (getArguments() != null) {
cYear = getArguments().getInt(ARG_PARAM1, DateUtils.nowYear());
cMonth = getArguments().getInt(ARG_PARAM2, DateUtils.nowMonth());
book = (AccountBook) getArguments().getSerializable(ARG_PARAM);
}
AccountMonthAty infoAty = (AccountMonthAty) getActivity();
infoAty.setExpendClickedListener(new AccountMonthAty.OnButtonClickedListener() {
@Override
public void onClickedMonth(int year, int month) {
cYear = year;
cMonth = month;
initData();
}
});
}
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState) {
// Inflate the layout for this fragment
return inflater.inflate(R.layout.fragment_expend, container, false);
}
@Override
public void onActivityCreated(@Nullable Bundle savedInstanceState) {
super.onActivityCreated(savedInstanceState);
initView();
}
@Override
public void onResume() {
super.onResume();
initData();
}
private void initData() {
//刷新数据
adapter.addDatas(generateData());
}
private void initView() {
recycler_expend = (RecyclerView) getActivity().findViewById(R.id.recycler_expend);
list = new ArrayList<>();
adapter = new IncomeAdapter(list, getActivity());
recycler_expend.setAdapter(adapter);
adapter.setTitle("总支出");
recycler_expend.setLayoutManager(new LinearLayoutManager(getActivity(), LinearLayoutManager.VERTICAL, false));
recycler_expend.setItemAnimator(new DefaultItemAnimator());
setHeader(recycler_expend);
adapter.setOnItemClickListener(new IncomeAdapter.OnItemClickListener() {
@Override
public void onItemClick(int position, AccountInfo data) {
Intent intent = new Intent(getActivity(), ColumnInfoActivity.class);
intent.putExtra("year", cYear);
intent.putExtra("month", cMonth);
intent.putExtra("type", data.getType());
intent.putExtra("book", book);
startActivity(intent);
}
});
db = MyApplication.getInstance().getDbManager();
map = new HashMap<>();
}
private List<AccountInfo> generateData() {
map.clear();
List<AccountInfo> mlist = null;//数据库查询数据
List<AccountInfo> Maplist = new ArrayList<>();//整理后的数据
long start = DateUtils.dateToStamp(DateUtils.getFirstDayOfMonth(cYear, cMonth, null));
long end = DateUtils.dateToStamp(DateUtils.getLastDayOfMonth(cYear, cMonth, null));
try {
mlist = book.getInfoNeg(db, start, end);//这个是查询出所有账单,要求是查询出
} catch (DbException e) {
e.printStackTrace();
}
//对查询结果归类处理,逻辑简单点,通过map中转下list;
for (int i = 0; i < mlist.size(); i++) {//
int type = mlist.get(i).getType();//获取当前账单属性
if (map.get(type) == null) {
List<AccountInfo> list = new ArrayList<>();
list.add(mlist.get(i));
map.put(type, list);
} else {
List<AccountInfo> list = map.get(type);
list.add(mlist.get(i));
}
}
//
for (List<AccountInfo> list : map.values()) {
AccountInfo accountInfo = new AccountInfo();
float count = 0f;
for (AccountInfo info : list) {
count += info.getBill_money();
accountInfo.setType(info.getType());
}
accountInfo.setBill_money(MathTools.getAbs(count));
Maplist.add(accountInfo);
}
return Maplist;
}
private void setHeader(RecyclerView view) {
View header = LayoutInflater.from(getActivity()).inflate(R.layout.item_head_pchart, view, false);
adapter.setHeaderView(header);
}
// TODO: Rename method, update argument and hook method into UI event
public void onButtonPressed(Uri uri) {
if (mListener != null) {
mListener.onFragmentInteraction(uri);
}
}
@Override
public void onAttach(Context context) {
super.onAttach(context);
if (context instanceof OnFragmentInteractionListener) {
mListener = (OnFragmentInteractionListener) context;
} else {
throw new RuntimeException(context.toString()
+ " must implement OnFragmentInteractionListener");
}
}
@Override
public void onDetach() {
super.onDetach();
mListener = null;
}
/**
* This interface must be implemented by activities that contain this
* fragment to allow an interaction in this fragment to be communicated
* to the activity and potentially other fragments contained in that
* activity.
* <p>
* See the Android Training lesson <a href=
* "http://developer.android.com/training/basics/fragments/communicating.html"
* >Communicating with Other Fragments</a> for more information.
*/
public interface OnFragmentInteractionListener {
// TODO: Update argument type and name
void onFragmentInteraction(Uri uri);
}
}
| [
"m1350212947@163.com"
] | m1350212947@163.com |
d06886ffbe33fe8df0d3b8b789d76e890d6ffada | 1c68ffa7b1df31ba0266bb1ac3873f5cdfdae34d | /src/ziekenhuis/Operatiekamer.java | 4a703025bca75551ec625d146a608e917c7764e3 | [] | no_license | MarkLunding/ziekenhuis | 10351de3d842188577aa20389de11eb24fa68a6b | a3ef704cb5ff7e4246a797e349b4e21a4dded4f6 | refs/heads/master | 2020-05-20T12:20:46.461894 | 2019-05-12T18:26:00 | 2019-05-12T18:26:00 | 185,567,140 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 297 | java | package ziekenhuis;
public class Operatiekamer extends Kamer implements SterieleRuimte {
private boolean steriel = true;
Operatiekamer() {
aantalBedden = 1;
aantalPatienten = 0;
}
public boolean isSteriel() {
if (steriel = true) {
return true;
} else {
return false;
}
}
}
| [
"e.westhof@workingspirit.nl"
] | e.westhof@workingspirit.nl |
cfba87ef3384504ebb5096f4fd648c430f772882 | 03582f5e32a7ca70ce77c08215b8e4bf9ac50980 | /Poo/principalAviao.java | 4c23663b798ff711d75e3eb5bb98ddb08d11a8a2 | [] | no_license | jessica403/exercicios | c4d38ea7acc815496a613958495de10ef7b5d46e | b195614d1f8c16adbf3c4efeec726347efa73739 | refs/heads/main | 2023-03-13T02:18:00.469146 | 2021-03-08T05:09:45 | 2021-03-08T05:09:45 | 345,528,963 | 0 | 0 | null | null | null | null | ISO-8859-1 | Java | false | false | 839 | java | package Poo;
import java.util.Scanner;
public class principalAviao {
public static void main(String[] args) {
System.out.println("SISTEMA DE CONTROLE DE VOOS \n");
Scanner tec = new Scanner(System.in);
aviao aviao1 = new aviao();
System.out.print("Digite o modelo do Aviao: ");
aviao1.modeloAviao=tec.next().toUpperCase();
System.out.print("Digite em siglas o local de partida do avião: ");
aviao1.partida= tec.next();
System.out.print("Digite a quantidade de passageiros: ");
aviao1.quantidadePassageiros = tec.nextInt();
System.out.print("Digite o destina do voo (1) Russia / (2) Madagascar / (3) Australia: ");
aviao1.destino=tec.nextInt();
System.out.printf("\n");
aviao1.mostra();
aviao1.mostrarDestino();
tec.close();
}
}
| [
"noreply@github.com"
] | noreply@github.com |
7c2f40c914f00e49cde3fb16e6154183f72c5b35 | 720f138e70aa052acd6e992ff31c27bbea9a198d | /PracticeProgramming9/src/main/java/com/mycompany/practiceprogramming9/SimpleSort.java | 1360dc0c3edbfc3e53f303685589d17f3a3aa69d | [] | no_license | kengardiner/SoftwareGuildJavaFullStackWork | 2438698bf3f407020978016bb5ab13602d049bd0 | 2ce98fbf21135979251f10c1505b1cd15417755f | refs/heads/master | 2021-05-16T05:23:11.116103 | 2017-10-10T18:35:08 | 2017-10-10T18:35:08 | 106,449,844 | 0 | 3 | null | null | null | null | UTF-8 | Java | false | false | 980 | java | /*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package com.mycompany.practiceprogramming9;
import java.util.Arrays;
/**
*
* @author n0252282
*/
public class SimpleSort {
public static void main(String[] args) {
int[] firstHalf = {3, 7, 9, 10, 16, 19, 20, 34, 55, 67, 88, 99};
int[] secondHalf = {1, 4, 8, 11, 15, 18, 21, 44, 54, 79, 89, 100};
int[] wholeNumbers = new int[24];
for (int j = 0; j < firstHalf.length; j++) {
wholeNumbers[j] = firstHalf[j];
}
for (int i = 0; i < secondHalf.length; i++) {
wholeNumbers[i+firstHalf.length] = secondHalf[i];
}
Arrays.sort(wholeNumbers);
for(int num: wholeNumbers){
System.out.print(num + " ");
}
}
}
| [
"ken_gardiner@yahoo.com"
] | ken_gardiner@yahoo.com |
639447fde895db653d537118c6898a4a962e6433 | 214706281c1a18c46179e067e20fedcc68ad4612 | /app/src/main/java/com/das/jospablo/littewebservice/entity/Repo.java | 8bcc6063b550ad4bf6fec9bf5f33670158839ce9 | [] | no_license | jose-cabrera/LittleWebService | 45c5ddb8e8d6d992f6487dda7f1afaf72829978e | 2077d030c3a96a9a944df01bfbc828fab70b230e | refs/heads/master | 2021-01-20T18:33:26.067733 | 2016-07-22T22:21:53 | 2016-07-22T22:21:53 | 61,919,340 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,161 | java | package com.das.jospablo.littewebservice.entity;
import com.google.gson.annotations.SerializedName;
/**
* Created by JoséPablo on 24/06/16.
* Repo Plain Old Java Object POJO
*/
public class Repo {
private int id;
private String name;
private String full_name;
@SerializedName("private")
private boolean bPrivate;
private String html_url;
private String description;
private boolean fork;
private String url;
private String created_at;
private String updated_at;
private String git_url;
public String getCreated_at() {
return created_at;
}
public void setCreated_at(String created_at) {
this.created_at = created_at;
}
public String getUpdated_at() {
return updated_at;
}
public void setUpdated_at(String updated_at) {
this.updated_at = updated_at;
}
public String getGit_url() {
return git_url;
}
public void setGit_url(String git_url) {
this.git_url = git_url;
}
public int getId() {
return id;
}
public void setId(int id) {
this.id = id;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getFull_name() {
return full_name;
}
public void setFull_name(String full_name) {
this.full_name = full_name;
}
public boolean isbPrivate() {
return bPrivate;
}
public void setbPrivate(boolean bPrivate) {
this.bPrivate = bPrivate;
}
public String getHtml_url() {
return html_url;
}
public void setHtml_url(String html_url) {
this.html_url = html_url;
}
public String getDescription() {
return description;
}
public void setDescription(String description) {
this.description = description;
}
public boolean isFork() {
return fork;
}
public void setFork(boolean fork) {
this.fork = fork;
}
public String getUrl() {
return url;
}
public void setUrl(String url) {
this.url = url;
}
}
| [
"deltadax18@gmail.com"
] | deltadax18@gmail.com |
14a489fd2f52df122f13797cedab5a52f848e64e | 5c07bd675c8847d825b6f9b5825f3fdf6c3b23f8 | /ml/p1/Attributes.java | 75e926fce7742e31483f227376a4e4dae7cb1afd | [] | no_license | SamThacher/2018school | bdd6fec007618f608f233149d1bab126e6161c3c | fa5f64cae506ab0b74dae7de818b5766beb7438a | refs/heads/master | 2020-03-27T07:52:03.634301 | 2018-12-21T05:19:10 | 2018-12-21T05:19:10 | 146,198,712 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,768 | java |
public class Attributes
{
private java.util.ArrayList<Attribute> attributes;
private int classIndex;
private boolean hasNumericAttributes;
public Attributes()
{
attributes = new java.util.ArrayList<Attribute>();
hasNumericAttributes = false;
}
public void add(Attribute attribute)
{
if(!hasNumericAttributes && attribute instanceof NumericAttribute)
{
hasNumericAttributes = true;
}
attributes.add(attribute);
}
public int getClassIndex()
{
return attributes.size()-1;
}
public boolean getHasNumericAttributes()
{
return hasNumericAttributes;
}
public Attribute get(int i)
{
return attributes.get(i);
}
public Attribute getClassAttribute()
{
return attributes.get(attributes.size()-1);
}
public int getIndex(java.lang.String name) throws java.lang.Exception
{
for(int i = 0; i < attributes.size(); i++)
{
if(attributes.get(i).getName() == name)
{
return i;
}
}
throw new java.lang.Exception("name not in array");
}
public int size()
{
return attributes.size();
}
public void parse(java.util.Scanner scanner) throws java.lang.Exception
{
AttributeFactory factory = new AttributeFactory();
while(!scanner.hasNext("@attribute"))
{
scanner.nextLine();
}
while(true)
{
if(!scanner.hasNext("@attribute"))
{
break;
}
else
{
this.add(factory.make(scanner));
}
}
}
public void setClassIndex(int classIndex) throws java.lang.Exception
{
this.classIndex = classIndex;
}
public java.lang.String toString()
{
StringBuilder s = new StringBuilder();
for(int i = 0; i < attributes.size(); i++)
{
s.append(attributes.get(i).toString() + "\n");
}
return s.toString();
}
public static void main(java.lang.String[] args)
{
}
} | [
"samthacher@Sams-MacBook-Air-2.local"
] | samthacher@Sams-MacBook-Air-2.local |
e5aa78b2c357724f96577eec85b94025e15a4108 | b9a3230e580ff33c9e844f11a9869f12a107d0d0 | /GRAMATICA/src/portugol/node/TComentAninhado.java | 836d588bea2acaadab460d87a54d358c66c18f96 | [] | no_license | Fabio-Anderon/LFT | fe7ded81cf72435a15867c05d28c534d9421a6c8 | 8b64b0cb6478345992572ebe74d52a021c9f24ff | refs/heads/master | 2021-01-10T19:30:56.258902 | 2014-05-30T23:10:20 | 2014-05-30T23:10:20 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 831 | java | /* This file was generated by SableCC (http://www.sablecc.org/). */
package portugol.node;
import portugol.analysis.*;
@SuppressWarnings("nls")
public final class TComentAninhado extends Token
{
public TComentAninhado()
{
super.setText("/*");
}
public TComentAninhado(int line, int pos)
{
super.setText("/*");
setLine(line);
setPos(pos);
}
@Override
public Object clone()
{
return new TComentAninhado(getLine(), getPos());
}
@Override
public void apply(Switch sw)
{
((Analysis) sw).caseTComentAninhado(this);
}
/* @Override
public void setText(@SuppressWarnings("unused") String text)
{
throw new RuntimeException("Cannot change TComentAninhado text.");
}*/
}
| [
"Anderson@Anderson-pc"
] | Anderson@Anderson-pc |
5d62273b5ab131acec6b5bb848fdee6d0dd3ec39 | f3f2ef9a447a2d0fae5eade7a906daac1ccc328e | /src/StacksAndQueues/DynamicStack.java | 000e28cf28371415dc9fed6f39e2b7a8159d9be5 | [] | no_license | puneetjyot/DS_With_Java | ce17022307eb3042a945db1e6738fb4c6fac2d65 | dbcc5a4e0f9a337abffb596c84a8e1e99b81e9f8 | refs/heads/master | 2020-03-26T14:03:40.791445 | 2018-08-16T09:57:26 | 2018-08-16T09:57:26 | 144,970,107 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 752 | java | package StacksAndQueues;
public class DynamicStack extends StackUsingArrays {
public DynamicStack() throws Exception {
this(DEFAULT_CAPACITY);
}
public DynamicStack(int capacity) throws Exception {
super(capacity);
}
public void push(int item) throws Exception {
if (this.tos == this.data.length - 1) {
int[] arr = new int[2 * this.data.length];
for (int i = 0; i < this.data.length; i++) {
arr[i] = this.data[i];
}
this.data = arr;
}
super.push(item);
}
public int pop() throws Exception {
if (this.size() == this.data.length / 4) {
int[] arr = new int[this.data.length / 2];
for (int i = 0; i <= this.size() - 1; i++) {
arr[i] = this.data[i];
}
this.data = arr;
}
return super.pop();
}
}
| [
"puneet.khurana01@nagarro.com"
] | puneet.khurana01@nagarro.com |
651ded6abf39d19835ae4019274fdbad739382ea | 1103b5eaa01695cd24080e914b02e89ec5217bf3 | /Demos/InterviewPrepration/Prepration/Prepration/HackerRank/Implementation/Append and Delete/Solution.java | c96c711fb509d9b2e9498d97ba5e327ebffd7501 | [] | no_license | Senbagakumar/SelfLearnings | 5dae8b00fe307b1b07e26d6c54f5cad226943798 | 5f299dbea90a82d26e521f3fa1038e65c886a338 | refs/heads/master | 2023-01-10T06:39:19.636022 | 2021-12-08T03:27:58 | 2021-12-08T03:27:58 | 144,771,078 | 1 | 1 | null | 2023-01-07T15:43:59 | 2018-08-14T20:53:12 | JavaScript | UTF-8 | Java | false | false | 2,490 | java | import java.io.*;
import java.util.*;
import java.text.*;
import java.math.*;
import java.util.regex.*;
/*
* The minimum number of characters to be deleted and add in order to convert string1 to string2 is
* saved in the variable 'necessaryOperations'.
* The conversion is possible in three cases:
* 1) k == necessaryOperations: of course, the conversion is possible.
*
* hello
* helloworld
* 5
*
* necessaryOperations = 5
* We perform 5 additions
* The answer is YES
*
* 2) k >= necessaryOperations && (k - necessaryOperations) % 2 == 0:
* by subtracting 'necessaryOperations' from 'k', we obtain the number of 'dummy operations':
* a dummy operation is the addition and the instantaneous deletion of the same character (or viceversa).
* Since a dummy operation consists of two actions (addition and deletion), we have to check the parity:
* if the parity is even, the conversion is possible.
*
* hellno
* hellyes
* 7
*
* necessaryOperations = 5
* k - necessaryOperations = 2 (dummy operations)
* We perform 2 necessary deletions, 1 dummy addition, 1 dummy deletion and 3 necessary additions
* The answer is YES
*
* hellno
* hellyes
* 4
*
* necessaryOperations = 5
* k - necessaryOperations = 1 (dummy operations)
* Since the number of dummy operations is odd, we cannot compensate for a dummy addition/deletion.
* The answer is NO
*
* 3) k >= string1.length() + string2.length():
* since we can still perform a delete operation on an empty string to get the empty string,
* the conversion is possible.
*
* hell
* he
* 10
*
* We perform 5 deletions to obtain the empty string, 3 deletions on the empty string and 2 additions.
* The answer is YES
*
*/
public class Solution {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
String string1 = sc.next();
String string2 = sc.next();
int k = sc.nextInt();
int minLen = Math.min(string1.length(), string2.length());
int firstDifferentIndex = minLen;
for (int i = 0; i < minLen; i++) {
if (string1.charAt(i) != string2.charAt(i)) {
firstDifferentIndex = i;
break;
}
}
int necessaryOperations = string1.length() + string2.length() - 2 * firstDifferentIndex;
if (k == necessaryOperations || (k >= necessaryOperations && (k - necessaryOperations) % 2 == 0)
|| k >= string1.length() + string2.length()) {
System.out.println("Yes");
} else {
System.out.println("No");
}
sc.close();
}
}
| [
"v-sesiga@microsoft.com"
] | v-sesiga@microsoft.com |
387750e7bc9ee869aad07f740f09ed7b723a0d48 | 2215478141a355e9370e9db15ed7414c1df59ff1 | /SchoolManager/Server/SchoolManagerApi/src/main/java/com/chris/school/model/xo/TeacherXo.java | bf71b5f511b821ae0c10bad206292f4c9221725b | [] | no_license | chrischendev/Projects | fa9cb487b6ac49f28a6b25c3ddcdd53e04fc5a99 | 2fe4d20fd0981ea8305e681dae8a06252d37ca72 | refs/heads/master | 2022-12-27T06:10:30.939853 | 2020-04-22T05:36:07 | 2020-04-22T05:36:07 | 189,320,542 | 0 | 0 | null | 2022-12-16T05:05:38 | 2019-05-30T00:55:36 | Java | UTF-8 | Java | false | false | 721 | java | package com.chris.school.model.xo;
import com.chris.framework.builder.annotation.ExpandField;
import lombok.Data;
import com.chris.school.model.orm.TeacherEntity;
import lombok.AllArgsConstructor;
import com.chris.framework.builder.annotation.Expand;
import lombok.NoArgsConstructor;
/**
* App: ChrisApplication
* Pkg: com.chris.school.model.xo
* Author: Chris Chen
* Time: 2018/07/03
* Explain:
*/
@NoArgsConstructor
@AllArgsConstructor
@Data
@Expand(baseEntity = TeacherEntity.class)
public class TeacherXo {
private Integer id;
private String name;
private String cell;
private Boolean gender;
@ExpandField(baseField="userId")
private TeacherXo user;
private String description;
} | [
"chrischen2018@163.com"
] | chrischen2018@163.com |
64066e727ae7651100ec9cf370b0f9da7bea015c | aeff069a9153ba377c75be36d02634dc2fad3568 | /Entropy/src/us/rockhopper/entropy/network/MultiplayerServer.java | 235ffe94a75f3c6a641ea29db20d7fe17077bcb5 | [] | no_license | ian-tang/EntropyCore | 7c3d6d38d15897a3a7998f4640b8df06a3976ae7 | dedbae931b9ab71d79a2ccd98e44cccfc6b0c93b | refs/heads/master | 2021-10-10T17:02:43.960623 | 2014-06-11T00:43:22 | 2014-06-11T00:43:22 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 11,273 | java | package us.rockhopper.entropy.network;
import java.io.IOException;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.Timer;
import java.util.TimerTask;
import java.util.concurrent.ConcurrentLinkedQueue;
import us.rockhopper.entropy.entities.Ship;
import us.rockhopper.entropy.entities.Weapon;
import us.rockhopper.entropy.network.Packet.Packet0Player;
import us.rockhopper.entropy.network.Packet.Packet1Ship;
import us.rockhopper.entropy.network.Packet.Packet2InboundSize;
import us.rockhopper.entropy.network.Packet.Packet3ShipCompleted;
import us.rockhopper.entropy.network.Packet.Packet4Ready;
import us.rockhopper.entropy.network.Packet.Packet5GameStart;
import us.rockhopper.entropy.network.Packet.Packet6Key;
import us.rockhopper.entropy.network.Packet.Packet7PositionUpdate;
import us.rockhopper.entropy.network.Packet.Packet8DuelStart;
import us.rockhopper.entropy.utility.CollisionListener;
import us.rockhopper.entropy.utility.Part;
import us.rockhopper.entropy.utility.PartClassAdapter;
import com.badlogic.gdx.Gdx;
import com.badlogic.gdx.math.Vector2;
import com.badlogic.gdx.physics.box2d.Body;
import com.badlogic.gdx.physics.box2d.JointEdge;
import com.badlogic.gdx.physics.box2d.World;
import com.badlogic.gdx.utils.Array;
import com.esotericsoftware.kryo.Kryo;
import com.esotericsoftware.kryonet.Connection;
import com.esotericsoftware.kryonet.Listener;
import com.esotericsoftware.kryonet.Server;
import com.esotericsoftware.minlog.Log;
import com.google.gson.GsonBuilder;
/**
* The multiplayer server. Simulates the game world and sends updates to the clients.
*
* @author Tim Clancy
* @version 6.9.14
*
*/
public class MultiplayerServer extends Listener {
private Server server;
private World world;
private HashMap<String, Boolean> players;
private ArrayList<Packet1Ship> shipPackets;
private ArrayList<Packet2InboundSize> shipSizePackets;
private ArrayList<Packet3ShipCompleted> shipCompletedPackets;
HashMap<String, String> shipStrings = new HashMap<String, String>();
protected ConcurrentLinkedQueue<Packet6Key> clientMessageQueue;
private HashMap<String, Ship> allShips;
private final float TIMESTEP = 1 / 60f;
private final int VELOCITYITERATIONS = 8, POSITIONITERATIONS = 3;
private boolean start;
private boolean gameLogic;
public MultiplayerServer(String port) {
Log.set(Log.LEVEL_DEBUG);
server = new Server();
world = new World(new Vector2(0, 0), true);
this.clientMessageQueue = new ConcurrentLinkedQueue<Packet6Key>();
allShips = new HashMap<String, Ship>();
this.registerPackets();
// Server listening on its own thread.
server.addListener(new Listener.QueuedListener(this) {
protected void queue(Runnable runnable) {
Gdx.app.postRunnable(runnable);
}
});
try {
server.bind(Integer.parseInt(port));
// TODO wtf is with all these threads this can probably be fixed
// Start the server listening for input
new Thread(server).start();
// Start the server gameloop
Timer t = new Timer();
// Thanks to @mobidevelop
final Runnable runnable = new Runnable() {
int step = 0;
@Override
public void run() {
if (!gameLogic) { // Create the ships on the first tick of game logic...this ensures they remain
// properly aligned.
for (String playerName : allShips.keySet()) {
Ship ship = allShips.get(playerName);
ship.setWorld(world);
ship.create();
ship.release();
}
world.setContactListener(new CollisionListener());
gameLogic = true;
}
++step;
processKeyPresses();
updateShips();
// TODO currently sending the position updates 66.66 time a second without any clientside
// interpolation
if (step == 1) {
step = 0;
shipToClient();
// projectilesToClient();
}
// Remove bodies flagged for deletion
sweepDeadBodies();
}
};
t.schedule(new TimerTask() {
@Override
public void run() {
if (start) {
Gdx.app.postRunnable(runnable);
}
}
}, 0L, 15);
System.out.println("[SERVER] Started new server.");
players = new HashMap<String, Boolean>();
shipPackets = new ArrayList<Packet1Ship>();
shipSizePackets = new ArrayList<Packet2InboundSize>();
shipCompletedPackets = new ArrayList<Packet3ShipCompleted>();
} catch (IOException e) {
e.printStackTrace();
}
}
// public void projectilesToClient() { // TODO mother of god...triple for loop
// for (String playerName : allShips.keySet()) {
// Ship ship = allShips.get(playerName);
// for (Part part : ship.getParts()) {
// if (part instanceof Weapon) {
// Weapon weapon = (Weapon) part;
// for (Part bullet : weapon.getProjectiles()) {
// Packet9Projectile projectile = new Packet9Projectile();
// projectile.name = playerName;
// }
// }
//
// Packet7PositionUpdate updatePacket = new Packet7PositionUpdate();
// updatePacket.name = playerName;
// updatePacket.partNumber = part.getNumber();
// updatePacket.x = part.getBody().getPosition().x;
// updatePacket.y = part.getBody().getPosition().y;
// updatePacket.angle = part.getBody().getAngle();
//
// // TODO create the render-update packet?
// server.sendToAllTCP(updatePacket);
// }
// }
// }
public void shipToClient() {
for (String playerName : allShips.keySet()) {
Ship ship = allShips.get(playerName);
for (Part part : ship.getParts()) {
Packet7PositionUpdate updatePacket = new Packet7PositionUpdate();
updatePacket.name = playerName;
updatePacket.partNumber = part.getNumber();
updatePacket.x = part.getBody().getPosition().x;
updatePacket.y = part.getBody().getPosition().y;
updatePacket.angle = part.getBody().getAngle();
// TODO create the render-update packet?
server.sendToAllTCP(updatePacket);
}
}
}
public void updateShips() {
for (String playerName : allShips.keySet()) {
Ship ship = allShips.get(playerName);
ship.update();
}
world.step(TIMESTEP, VELOCITYITERATIONS, POSITIONITERATIONS);
}
public void processKeyPresses() {
Packet6Key msg;
while ((msg = clientMessageQueue.poll()) != null) {
Ship keyedShip = allShips.get(msg.name);
for (Part part : keyedShip.getParts()) {
if (msg.isDown) {
part.trigger(msg.keyPress);
} else {
part.unTrigger(msg.keyPress);
}
// If this part was a weapon, this was a projectile-action, and clients need to be notified that they
// should also fire a projectile.
if (part instanceof Weapon) {
}
}
}
}
public void sweepDeadBodies() {
Array<Body> tempBodies = new Array<Body>();
world.getBodies(tempBodies);
for (Body body : tempBodies) {
if (body != null) {
Part part = (Part) body.getUserData();
if (part.isDead() && !world.isLocked()) {
body.setUserData(null);
removeBodySafely(body);
body = null;
}
}
}
}
public void removeBodySafely(Body body) {
// to prevent some obscure c assertion that happened randomly once in a blue moon
final Array<JointEdge> list = body.getJointList();
while (list.size > 0) {
world.destroyJoint(list.get(0).joint);
}
// actual remove
world.destroyBody(body);
}
private void registerPackets() {
Kryo kryo = server.getKryo();
Network.register(kryo);
}
@Override
public void connected(Connection c) {
System.out.println("[SERVER] " + c.getID() + " connected.");
}
@Override
public void disconnected(Connection c) {
System.out.println("[SERVER] " + c.getID() + " disconnected.");
}
@Override
public void received(Connection c, Object o) {
if (o instanceof Packet0Player) {
Packet0Player player = ((Packet0Player) o);
System.out.println("[SERVER] Player " + player.name + " received from connection " + c.getID() + ".");
// If this is a player just entering the lobby
if (!players.keySet().contains(player.name)) {
players.put(player.name, false);
server.sendToAllExceptTCP(c.getID(), player);
System.out.println("[SERVER] Getting " + player.name + " up to speed.");
for (String playerOtherName : players.keySet()) {
Packet0Player playerOther = new Packet0Player();
playerOther.name = playerOtherName;
server.sendToTCP(c.getID(), playerOther);
Packet4Ready readyPacket = new Packet4Ready();
readyPacket.name = playerOtherName;
readyPacket.ready = players.get(playerOtherName);
server.sendToTCP(c.getID(), readyPacket);
}
String currentShip = "";
int j = 0;
for (int i = 0; i < shipSizePackets.size(); ++i) {
Packet2InboundSize start = shipSizePackets.get(i);
currentShip = start.shipName;
server.sendToTCP(c.getID(), start);
System.out.println(currentShip);
while (j < shipPackets.size() && shipPackets.get(j).name.equals(start.name)
&& shipPackets.get(j).shipName.equals(currentShip)) {
server.sendToTCP(c.getID(), shipPackets.get(j));
++j;
}
Packet3ShipCompleted packetComplete = shipCompletedPackets.get(i);
server.sendToTCP(c.getID(), packetComplete);
}
}
} else if (o instanceof Packet1Ship) {
Packet1Ship packet = ((Packet1Ship) o);
shipPackets.add(packet);
// Grab ship information
String shipJSON = shipStrings.get(packet.name);
shipJSON += packet.ship;
shipStrings.put(packet.name, shipJSON);
server.sendToAllTCP(o);
} else if (o instanceof Packet2InboundSize) {
Packet2InboundSize packet = ((Packet2InboundSize) o);
shipStrings.put(packet.name, "");
System.out.println("[SERVER] Will try processing ship of size " + packet.size + " from " + packet.name);
shipSizePackets.add((Packet2InboundSize) o);
// // TODO ideally this would check for duplicate packets, and if they are found, then the sending would be
server.sendToAllTCP(o);
} else if (o instanceof Packet3ShipCompleted) {
Packet3ShipCompleted packetComplete = ((Packet3ShipCompleted) o);
System.out.println("[SERVER] " + ((Packet3ShipCompleted) o).name + " indicates that their ship sending is "
+ ((Packet3ShipCompleted) o).signal);
shipCompletedPackets.add((Packet3ShipCompleted) o);
// Server-side initialization of ship list
String playerName = packetComplete.name;
GsonBuilder gson = new GsonBuilder();
gson.registerTypeAdapter(Part.class, new PartClassAdapter());
System.out.println(shipStrings.get(playerName));
Ship ship = gson.create().fromJson(shipStrings.get(playerName), Ship.class);
System.out.println("[CLIENT] Received entire " + ship.getName() + " from " + playerName);
allShips.put(playerName, ship);
server.sendToAllTCP(o);
} else if (o instanceof Packet4Ready) {
Packet4Ready packet = (Packet4Ready) o;
System.out.println("[SERVER] " + packet.name + " is ready " + packet.ready);
players.put(packet.name, packet.ready);
server.sendToAllExceptTCP(c.getID(), o);
// If every player is ready
boolean ready = true;
for (String playerName : players.keySet()) {
if (!players.get(playerName)) {
ready = false;
}
}
if (ready) {
server.sendToAllTCP(new Packet5GameStart());
}
} else if (o instanceof Packet6Key) {
this.clientMessageQueue.add((Packet6Key) o);
server.sendToAllTCP(o);
} else if (o instanceof Packet8DuelStart) {
start = true;
}
}
}
| [
"thenewtinkerer@gmail.com"
] | thenewtinkerer@gmail.com |
0f549dd86b946f77dcecf62f30ba128688c7ad42 | 4aaa392f426b8fdcc5bf8bc1b4c06d18448c0d78 | /src/stacktests/SimpleStack4.java | b7b3bcd4f86a21418b69ab6876096b44850a8ca2 | [] | no_license | karipursiainen/Testing | 8136f9e8b7dd61a94995c35434a113b342c1da14 | fa2e3144f14fddf8313aff4c8c273c7f870a7877 | refs/heads/master | 2020-06-11T00:55:14.532411 | 2016-12-07T11:40:40 | 2016-12-07T11:40:40 | 75,828,964 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,523 | java | package stacktests;
/**
*
* @author juha
*/
import java.lang.reflect.Array;
import java.util.Arrays;
import java.util.logging.Level;
import java.util.logging.Logger;
public class SimpleStack4<E> {
private int size;
private E[] stack;
private int top; // topmost element in the stack is returned
public SimpleStack4(Class<E> c, int s) {
// Use Array native method to create array of a type only known at run time
@SuppressWarnings("unchecked")
E[] tempArr = (E[]) Array.newInstance(c, s);
assert s > 0;
size = s;
this.stack = tempArr;
top = -1;
}
public void push(E j) {
if (top+1 >= stack.length) {
ensureCapacity();
}
assert top <= size;
stack[++top] = j;
System.out.println("top index: " + top);
}
public E pop() {
assert top >= 0;
return stack[top--];
}
public E peek() {
assert top >= 0;
return stack[top];
}
public boolean isEmpty() {
return (top == -1);
}
public boolean isFull() {
return (top == size - 1);
}
/**
* to reserve more capacity of array
*/
private void ensureCapacity() {
System.out.println("current len: " + stack.length);
int currentLen = stack.length;
size = currentLen * 2;
stack = Arrays.copyOf(stack, size);
// Assertion to test that the capacity*2 is ensured
}
public static void main(String[] args) {
SimpleStack4<Integer> intStack = new SimpleStack4(Integer.class, (10));
// push some elements in to the stack
intStack.push(1);
intStack.push(2);
intStack.push(3);
intStack.push(4);
intStack.push(5);
intStack.push(6);
intStack.push(7);
intStack.push(8);
intStack.push(9);
intStack.push(10);
intStack.push(11);
intStack.push(12);
// peek couple of times
System.out.println("topmost element: " + intStack.peek());
System.out.println("topmost element: " + intStack.peek());
while (!intStack.isEmpty()) {
int value = -1;
value = intStack.pop();
System.out.print(value + " ");
System.out.println();
}
// Now it is mandatory to handle checked Exception
int value2 = intStack.peek();
int value3 = intStack.pop();
}
}
| [
"kari_pursiainen@hotmail.com"
] | kari_pursiainen@hotmail.com |
1c4c68c1bfe2cb6b15d82486f99ff611f3812090 | fa91450deb625cda070e82d5c31770be5ca1dec6 | /Diff-Raw-Data/1/1_6930d68347f3f138cac835e9db06a67c69d35a37/LookAndFeelFactory/1_6930d68347f3f138cac835e9db06a67c69d35a37_LookAndFeelFactory_t.java | 85738f5255652a53983b2792fad0981d7f2b2beb | [] | 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 | 67,381 | java | /*
* @(#)LookAndFeelFactory.java 5/28/2005
*
* Copyright 2002 - 2005 JIDE Software Inc. All rights reserved.
*/
package com.jidesoft.plaf;
import com.jidesoft.icons.IconsFactory;
import com.jidesoft.icons.JideIconsFactory;
import com.jidesoft.plaf.basic.Painter;
import com.jidesoft.plaf.eclipse.Eclipse3xMetalUtils;
import com.jidesoft.plaf.eclipse.Eclipse3xWindowsUtils;
import com.jidesoft.plaf.eclipse.EclipseMetalUtils;
import com.jidesoft.plaf.eclipse.EclipseWindowsUtils;
import com.jidesoft.plaf.office2003.Office2003Painter;
import com.jidesoft.plaf.office2003.Office2003WindowsUtils;
import com.jidesoft.plaf.vsnet.VsnetMetalUtils;
import com.jidesoft.plaf.vsnet.VsnetWindowsUtils;
import com.jidesoft.plaf.xerto.XertoMetalUtils;
import com.jidesoft.plaf.xerto.XertoWindowsUtils;
import com.jidesoft.swing.JideSwingUtilities;
import com.jidesoft.swing.JideTabbedPane;
import com.jidesoft.utils.ProductNames;
import com.jidesoft.utils.SecurityUtils;
import com.jidesoft.utils.SystemInfo;
import com.sun.java.swing.plaf.windows.WindowsLookAndFeel;
import sun.swing.SwingLazyValue;
import javax.swing.*;
import javax.swing.plaf.BorderUIResource;
import javax.swing.plaf.ColorUIResource;
import javax.swing.plaf.FontUIResource;
import javax.swing.plaf.InsetsUIResource;
import javax.swing.plaf.metal.MetalLookAndFeel;
import java.awt.*;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import java.util.List;
import java.util.Vector;
/**
* JIDE Software created many new components that need their own ComponentUI classes and additional UIDefaults in
* UIDefaults table. LookAndFeelFactory can take the UIDefaults from any existing look and feel and add the extra
* UIDefaults JIDE components need.
* <p/>
* Before using any JIDE components, please make you call one of the two LookAndFeelFactory.installJideExtension(...)
* methods. Bascially, you set L&F using UIManager first just like before, then call installJideExtension. See code
* below for an example.
* <code><pre>
* UIManager.setLookAndFeel(WindowsLookAndFeel.class.getName()); // you need to catch the
* exceptions
* on this call.
* LookAndFeelFactory.installJideExtension();
* </pre></code>
* LookAndFeelFactory.installJideExtension() method will check what kind of L&F you set and what operating system you
* are on and decide which style of JIDE extension it will install. Here is the rule. <ul> <li> OS: Windows XP with XP
* theme on, L&F: Windows L&F => OFFICE2003_STYLE <li> OS: any Windows, L&F: Windows L&F => VSNET_STYLE <li> OS: Linux,
* L&F: any L&F based on Metal L&F => VSNET_STYLE <li> OS: Mac OSX, L&F: Aqua L&F => AQUA_STYLE <li> OS: any OS, L&F:
* Quaqua L&F => AQUA_STYLE <li> Otherwise => VSNET_STYLE </ul> There is also another installJideExtension which takes
* an int style parameter. You can pass in {@link #VSNET_STYLE}, {@link #ECLIPSE_STYLE}, {@link #ECLIPSE3X_STYLE},
* {@link #OFFICE2003_STYLE}, or {@link #XERTO_STYLE}. In the other word, you will make the choice of style instead of
* letting LookAndFeelFactory to decide one for you. Please note, there is no constant defined for AQUA_STYLE. The only
* way to use it is when you are using Aqua L&F or Quaqua L&F and you call installJideExtension() method, the one
* without parameter.
* <p/>
* LookAndFeelFactory supports a number of known L&Fs. You can see those L&Fs as constants whose names are something
* like "_LNF" such as WINDOWS_LNF.
* <p/>
* If you are using a 3rd party L&F we are not officially supporting, we might need to customize it. Here are two
* classes you can use. The first one is {@link UIDefaultsCustomizer}. You can add a number of customizers to
* LookAndFeelFactory. After LookAndFeelFactory installJideExtension method is called, we will call customize() method
* on each UIDefaultsCustomizer to add additional UIDefaults you specified. You can use UIDefaultsCustomizer to do
* things like small tweaks to UIDefaults without the hassle of creating a new style.
* <p/>
* Most likely, we will not need to use {@link UIDefaultsInitializer} if you are use L&Fs such as WindowsLookAndFeel,
* any L&Fs based on MetalLookAndFeel, or AquaLookAndFeel etc. The only exception is Synth L&F and any L&Fs based on it.
* The reason is we calcualte all colors we will use in JIDE components from existing wel-known UIDefaults. For example,
* we will use UIManagerLookup.getColor("activeCaption") to calculate a color that we can use in dockable frame's title
* pane. We will use UIManagerLookup.getColor("control") to calculate a color that we can use as background of JIDE
* component. Most L&Fs will fill those UIDefaults. However in Synth L&F, those UIDefaults may or may not have a valid
* value. You will end up with NPE later in the code when you call installJideExtension. In this case, you can add those
* extra UIDefaults in UIDefaultsInitializer. We will call it before installJideExtension is called so that those
* UIDefaults are there ready for us to use. This is how added support to GTK L&F and Synthethica L&F.
* <p/>
* {@link #installJideExtension()} method will only add the additional UIDefaults to current ClassLoader. If you have
* several class loaders in your system, you probably should tell the UIManager to use the class loader that called
* <code>installJideExtension</code>. Otherwise, you might some unexpected errors. Here is how to specify the class
* loaders.
* <code><pre>
* UIManager.put("ClassLoader", currentClass.getClassLoader()); // currentClass is the class where
* the code is.
* LookAndFeelFactory.installDefaultLookAndFeelAndExtension(); // or installJideExtension()
* </pre></code>
*/
public class LookAndFeelFactory implements ProductNames {
/**
* Class name of Windows L&F provided in Sun JDK.
*/
public static final String WINDOWS_LNF = "com.sun.java.swing.plaf.windows.WindowsLookAndFeel";
/**
* Class name of Metal L&F provided in Sun JDK.
*/
public static final String METAL_LNF = "javax.swing.plaf.metal.MetalLookAndFeel";
/**
* Class name of Aqua L&F provided in Apple Mac OSX JDK.
*/
public static final String AQUA_LNF = "apple.laf.AquaLookAndFeel";
/**
* Class name of Quaqua L&F.
*/
public static final String QUAQUA_LNF = "ch.randelshofer.quaqua.QuaquaLookAndFeel";
/**
* Class name of Quaqua Alloy L&F.
*/
public static final String ALLOY_LNF = "com.incors.plaf.alloy.AlloyLookAndFeel";
/**
* Class name of Synthetica L&F.
*/
public static final String SYNTHETICA_LNF = "de.javasoft.plaf.synthetica.SyntheticaLookAndFeel";
private static final String SYNTHETICA_LNF_PREFIX = "de.javasoft.plaf.synthetica.Synthetica";
/**
* Class name of Plastic3D L&F before JGoodies Look 1.3 release.
*/
public static final String PLASTIC3D_LNF = "com.jgoodies.plaf.plastic.Plastic3DLookAndFeel";
/**
* Class name of Plastic3D L&F after JGoodies Look 1.3 release.
*/
public static final String PLASTIC3D_LNF_1_3 = "com.jgoodies.looks.plastic.Plastic3DLookAndFeel";
/**
* Class name of PlasticXP L&F.
*/
public static final String PLASTICXP_LNF = "com.jgoodies.looks.plastic.PlasticXPLookAndFeel";
/**
* Class name of Tonic L&F.
*/
public static final String TONIC_LNF = "com.digitprop.tonic.TonicLookAndFeel";
/**
* Class name of A03 L&F.
*/
public static final String A03_LNF = "a03.swing.plaf.A03LookAndFeel";
/**
* Class name of Pgs L&F.
*/
public static final String PGS_LNF = "com.pagosoft.plaf.PgsLookAndFeel";
/**
* Class name of GTK L&F provided by Sun JDK.
*/
public static final String GTK_LNF = "com.sun.java.swing.plaf.gtk.GTKLookAndFeel";
/**
* The name of Nimbus L&F. We didn't create a constant for Nimbus is because the package name will be changed in
* JDK7 release
*/
public static final String NIMBUS_LNF_NAME = "NimbusLookAndFeel";
/**
* A style that you can use with {@link #installJideExtension(int)} method. This style is the same as VSNET_STYLE
* except it doesn't have menu related UIDefaults. You can only use this style if you didn't use any component from
* JIDE Action Framework.
* <p/>
*
* @see #VSNET_STYLE
*/
public final static int VSNET_STYLE_WITHOUT_MENU = 0;
/**
* A style that you can use with {@link #installJideExtension(int)} method. This style mimics the visual style of
* Microsoft Visuasl Studio .NET for the toolbars, menus and dockable windows.
* <p/>
* Vsnet style is a very simple style with no gradient. Although it works on almost all L&Fs in any operating
* systems, it looks the best on Windows 2000 or 98, or on Windows XP when XP theme is not on. If XP theme is on, we
* suggest you use Office2003 style or Xerto style. Since the style is so simple, it works with a lot of the 3rd
* party L&F such as Tonic, Pgs, Alloy etc without causing too much noice. That's why this is also the default style
* for any L&Fs we don't recognize when you call {@link #installJideExtension()}, the one with out style parameter.
* If you would like another style to be used as the default style, you can call {@link #setDefaultStyle(int)}
* method.
* <p/>
* Here is the code to set to Windows L&F with Vsnet style extension.
* <code><pre>
* UIManager.setLookAndFeel(WindowsLookAndFeel.class.getName()); // you need to catch the
* exceptions on this call.
* LookAndFeelFactory.installJideExtension(LookAndFeelFactory.VSNET_STYLE);
* </pre></code>
* There is a special system property "shading theme" you can use. If you turn it on using the code below, you will
* see a graident on dockable frame's title pane and rounded corner and graident on the tabs of JideTabbedPane. So
* if the L&F you are using uses graident, you can set this property to true to match with your L&F. For example, if
* you use Plastic3D L&F, turning this property on will look better.
* <code><pre>
* System.setProperty("shadingtheme", "true");
* </pre></code>
*/
public final static int VSNET_STYLE = 1;
/**
* A style that you can use with {@link #installJideExtension(int)} method. This style mimics the visual style of
* Eclipse 2.x for the toolbars, menus and dockable windows.
* <p/>
* Eclipse style works for almost all L&Fs and on any operating systems, although it looks the best on Windows. For
* any other operating systems we suggest you to use XERTO_STYLE or VSNET_STYLE.
* <p/>
* Here is the code to set to any L&F with Eclipse style extension.
* <code><pre>
* UIManager.setLookAndFeel(AnyLookAndFeel.class.getName()); // you need to catch the
* exceptions
* on this call.
* LookAndFeelFactory.installJideExtension(LookAndFeelFactory.ECLIPSE_STYLE);
* </pre></code>
*/
public final static int ECLIPSE_STYLE = 2;
/**
* A style that you can use with {@link #installJideExtension(int)} method. This style mimics the visual style of
* Microsoft Office2003 for the toolbars, menus and dockable windows.
* <p/>
* Office2003 style looks great on Windows XP when Windows or Windows XP L&F from Sun JDK is used. It replicated the
* exact same style as Microsoft Office 2003, to give your end user a familar visual style.
* <p/>
* Here is the code to set to Windows L&F with Office2003 style extension.
* <code><pre>
* UIManager.setLookAndFeel(WindowsLookAndFeel.class.getName()); // you need to catch the
* exceptions on this call.
* LookAndFeelFactory.installJideExtension(LookAndFeelFactory.OFFICE2003_STYLE);
* </pre></code>
* It works either on any other Windows such as Winodows 2000, Windows 98 etc. If you are on Windows XP, Office2003
* style will change theme based on the theme setting in Windows Display Property. But if you are not on XP,
* Office2003 style will use the default gray theme only. You can force to change it using {@link
* Office2003Painter#setColorName(String)} method, but it won't look good as other non-JIDE components won't have
* the matching theme.
* <p/>
* Office2003 style doesn't work on any operating systems other than Windows mainly because the design of Office2003
* style is so centric to Windows that it doesn't look good on other operating systems.
*/
public final static int OFFICE2003_STYLE = 3;
/**
* A style that you can use with {@link #installJideExtension(int)} method. This style is created by Xerto
* (http://www.xerto.com) which is used in their Imagery product.
* <p/>
* Xerto style looks great on Windows XP when Windows XP L&F from Sun JDK is used.
* <p/>
* Here is the code to set to Windows L&F with Xerto style extension.
* <code><pre>
* UIManager.setLookAndFeel(WindowsLookAndFeel.class.getName()); // you need to catch the
* exceptions on this call.
* LookAndFeelFactory.installJideExtension(LookAndFeelFactory.XERTO_STYLE);
* </pre></code>
* Although it looks the best on Windows, Xerto style also supports Linux or Solaris if you use any L&Fs based on
* Metal L&F or Synth L&F. For example, we recommend you to use Xerto style as default if you use SyntheticaL&F, a
* L&F based on Synth. To use it, you bascially replace WindowsLookAndFeel to the L&F you want to use in
* setLookAndFeel line above.
*/
public final static int XERTO_STYLE = 4;
/**
* A style that you can use with {@link #installJideExtension(int)} method. This style is the same as XERTO_STYLE
* except it doesn't have menu related UIDefaults. You can only use this style if you didn't use any component from
* JIDE Action Framework. Please note, we only use menu extension for Xerto style when the underlying L&F is Windows
* L&F. If you are using L&F such as Metal or other 3rd party L&F based on Metal, XERTO_STYLE_WITHOUT_MENU will be
* used even you use XERTO_STYLE when calling to installJideExtension().
* <p/>
*
* @see #XERTO_STYLE
*/
public final static int XERTO_STYLE_WITHOUT_MENU = 6;
/**
* A style that you can use with {@link #installJideExtension(int)} method. This style mimics the visual style of
* Eclipse 3.x for the toolbars, menus and dockable windows.
* <p/>
* Eclipse 3x style works for almost all L&Fs and on any operating systems, although it looks the best on Windows.
* For any other OS's we suggest you to use XERTO_STYLE or VSNET_STYLE.
* <code><pre>
* UIManager.setLookAndFeel(AnyLookAndFeel.class.getName()); // you need to catch the
* exceptions
* on this call.
* LookAndFeelFactory.installJideExtension(LookAndFeelFactory.ECLIPSE3X_STYLE);
* </pre></code>
*/
public final static int ECLIPSE3X_STYLE = 5;
private static int _style = -1;
private static int _defaultStyle = -1;
private static LookAndFeel _lookAndFeel;
/**
* If installJideExtension is called, it will put an entry on UIDefaults table.
* UIManagerLookup.getBoolean(JIDE_EXTENSION_INSTALLLED) will return true. You can also use {@link
* #isJideExtensionInstalled()} to check the value instead of using UIManagerLookup.getBoolean(JIDE_EXTENSION_INSTALLLED).
*/
public final static String JIDE_EXTENSION_INSTALLLED = "jidesoft.extendsionInstalled";
/**
* If installJideExtension is called, a JIDE style will be installed on UIDefaults table. If so,
* UIManagerLookup.getInt(JIDE_STYLE_INSTALLED) will return you the style that is installed. For example, if the
* value is 1, it means VSNET_STYLE is installed because 1 is the value of VSNET_STYLE.
*/
public final static String JIDE_STYLE_INSTALLED = "jidesoft.extendsionStyle";
/**
* An interface to make the customization of UIDefaults easier. This customizer will be called after
* installJideExtension() is called. So if you want to further customize UIDefault, you can use this customzier to
* do it.
*/
public static interface UIDefaultsCustomizer {
void customize(UIDefaults defaults);
}
/**
* An interface to make the initialization of UIDefaults easier. This initializer will be called before
* installJideExtension() is called. So if you want to initialize UIDefault before installJideExtension is called,
* you can use this initializer to do it.
*/
public static interface UIDefaultsInitializer {
void initialize(UIDefaults defaults);
}
private static List<UIDefaultsCustomizer> _uiDefaultsCustomizers = new Vector();
private static List<UIDefaultsInitializer> _uiDefaultsInitializers = new Vector();
protected LookAndFeelFactory() {
}
/**
* Gets the default style. If you never set default style before, it will return OFFICE2003_STYLE if you are on
* Windows XP, L&F is instance of Windows L&F and XP theme is on. Otherwise, it will return VSNET_STYLE. If you set
* default style before, it will return whatever style you set.
*
* @return the default style.
*/
public static int getDefaultStyle() {
if (_defaultStyle == -1) {
int suggestedStyle;
try {
if (XPUtils.isXPStyleOn() && UIManager.getLookAndFeel() instanceof WindowsLookAndFeel) {
suggestedStyle = OFFICE2003_STYLE;
}
else {
suggestedStyle = VSNET_STYLE;
}
}
catch (UnsupportedOperationException e) {
suggestedStyle = VSNET_STYLE;
}
return suggestedStyle;
}
return _defaultStyle;
}
/**
* Sets the default style. If you call this method to set a default style, {@link #installJideExtension()} will use
* it as the default style.
*
* @param defaultStyle the default style.
*/
public static void setDefaultStyle(int defaultStyle) {
_defaultStyle = defaultStyle;
}
/**
* Adds additional UIDefaults JIDE needed to UIDefault table. You must call this method everytime switching look and
* feel. And callupdateComponentTreeUI() in corresponding DockingManager or DockableBarManager after this call.
* <pre><code>
* try {
* UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
* }
* catch (ClassNotFoundException e) {
* e.printStackTrace();
* }
* catch (InstantiationException e) {
* e.printStackTrace();
* }
* catch (IllegalAccessException e) {
* e.printStackTrace();
* }
* catch (UnsupportedLookAndFeelException e) {
* e.printStackTrace();
* }
* <p/>
* // to add attitional UIDefault for JIDE components
* LookAndFeelFactory.installJideExtension(); // use default style VSNET_STYLE. You can change
* to a different style
* using setDefaultStyle(int style) and then call this method. Or simply call
* installJideExtension(style).
* <p/>
* // call updateComponentTreeUI
* frame.getDockableBarManager().updateComponentTreeUI();
* frame.getDockingManager().updateComponentTreeUI();
* </code></pre>
*/
public static void installJideExtension() {
installJideExtension(getDefaultStyle());
}
/**
* Add additional UIDefaults JIDE needed to UIDefaults table. You must call this method everytime switching look and
* feel. And call updateComponentTreeUI() in corresponding DockingManager or DockableBarManager after this call.
* <pre><code>
* try {
* UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
* }
* catch (ClassNotFoundException e) {
* e.printStackTrace();
* }
* catch (InstantiationException e) {
* e.printStackTrace();
* }
* catch (IllegalAccessException e) {
* e.printStackTrace();
* }
* catch (UnsupportedLookAndFeelException e) {
* e.printStackTrace();
* }
* <p/>
* // to add attitional UIDefault for JIDE components
* LookAndFeelFactory.installJideExtension(LookAndFeelFactory.OFFICE2003_STYLE);
* <p/>
* // call updateComponentTreeUI
* frame.getDockableBarManager().updateComponentTreeUI();
* frame.getDockingManager().updateComponentTreeUI();
* </code></pre>
*
* @param style the style of the extension.
*/
public static void installJideExtension(int style) {
installJideExtension(UIManager.getLookAndFeelDefaults(), UIManager.getLookAndFeel(), style);
}
/**
* Checks if JIDE extension is installed. Please note, UIManager.setLookAndFeel() method will overwrite the whole
* UIDefaults table. So even you called {@link #installJideExtension()} method before, UIManager.setLookAndFeel()
* method make isJideExtensionInstalled returning false.
*
* @return true if installed.
*/
public static boolean isJideExtensionInstalled() {
return UIDefaultsLookup.getBoolean(JIDE_EXTENSION_INSTALLLED);
}
/**
* Installs the UIDefault needed by JIDE component to the uiDefaults table passed in.
*
* @param uiDefaults the UIDefault tables where JIDE UIDefaults will be installed.
* @param lnf the LookAndFeel. This may have an effect on which set of JIDE UIDefaults we will install.
* @param style the style of the JIDE UIDefaults.
*/
public static void installJideExtension(UIDefaults uiDefaults, LookAndFeel lnf, int style) {
if (isJideExtensionInstalled() && _style == style && _lookAndFeel == lnf) {
return;
}
_style = style;
uiDefaults.put(JIDE_STYLE_INSTALLED, _style);
_lookAndFeel = lnf;
UIDefaultsInitializer[] initializers = getUIDefaultsInitializers();
for (UIDefaultsInitializer initializer : initializers) {
if (initializer != null) {
initializer.initialize(uiDefaults);
}
}
// For Alloy
/* if (lnf.getClass().getName().equals(ALLOY_LNF) && isAlloyLnfInstalled()) {
Object progressBarUI = uiDefaults.get("ProgressBarUI");
VsnetMetalUtils.initClassDefaults(uiDefaults);
VsnetMetalUtils.initComponentDefaults(uiDefaults);
uiDefaults.put("ProgressBarUI", progressBarUI);
uiDefaults.put("DockableFrameUI", "com.jidesoft.plaf.vsnet.VsnetDockableFrameUI");
uiDefaults.put("DockableFrameTitlePane.hideIcon", IconsFactory.getIcon(null, titleButtonImage, 0, 0, titleButtonSize, titleButtonSize));
uiDefaults.put("DockableFrameTitlePane.unfloatIcon", IconsFactory.getIcon(null, titleButtonImage, 0, titleButtonSize, titleButtonSize, titleButtonSize));
uiDefaults.put("DockableFrameTitlePane.floatIcon", IconsFactory.getIcon(null, titleButtonImage, 0, 2 * titleButtonSize, titleButtonSize, titleButtonSize));
uiDefaults.put("DockableFrameTitlePane.autohideIcon", IconsFactory.getIcon(null, titleButtonImage, 0, 3 * titleButtonSize, titleButtonSize, titleButtonSize));
uiDefaults.put("DockableFrameTitlePane.stopAutohideIcon", IconsFactory.getIcon(null, titleButtonImage, 0, 4 * titleButtonSize, titleButtonSize, titleButtonSize));
uiDefaults.put("DockableFrameTitlePane.hideAutohideIcon", IconsFactory.getIcon(null, titleButtonImage, 0, 5 * titleButtonSize, titleButtonSize, titleButtonSize));
uiDefaults.put("DockableFrameTitlePane.maximizeIcon", IconsFactory.getIcon(null, titleButtonImage, 0, 6 * titleButtonSize, titleButtonSize, titleButtonSize));
uiDefaults.put("DockableFrameTitlePane.restoreIcon", IconsFactory.getIcon(null, titleButtonImage, 0, 7 * titleButtonSize, titleButtonSize, titleButtonSize));
uiDefaults.put("DockableFrameTitlePane.buttonGap", new Integer(4)); // gap between buttons
}
else */
if ((lnf.getClass().getName().equals(ALLOY_LNF) && isAlloyLnfInstalled())
|| (lnf.getClass().getName().equals(PLASTIC3D_LNF) && isPlastic3DLnfInstalled())
|| (lnf.getClass().getName().equals(PLASTIC3D_LNF_1_3) && isPlastic3D13LnfInstalled())
|| (lnf.getClass().getName().equals(PLASTICXP_LNF) && isPlasticXPLnfInstalled())
|| (lnf.getClass().getName().equals(PGS_LNF) && isPgsLnfInstalled())
|| (lnf.getClass().getName().equals(TONIC_LNF) && isTonicLnfInstalled())) {
switch (style) {
case OFFICE2003_STYLE:
VsnetWindowsUtils.initComponentDefaults(uiDefaults);
Office2003WindowsUtils.initComponentDefaults(uiDefaults);
Office2003WindowsUtils.initClassDefaults(uiDefaults, false);
break;
case VSNET_STYLE:
case VSNET_STYLE_WITHOUT_MENU:
VsnetMetalUtils.initComponentDefaults(uiDefaults);
VsnetMetalUtils.initClassDefaults(uiDefaults);
Painter gripperPainter = new Painter() {
public void paint(JComponent c, Graphics g, Rectangle rect, int orientation, int state) {
Office2003Painter.getInstance().paintGripper(c, g, rect, orientation, state);
}
};
// set all grippers to Office2003 style gripper
uiDefaults.put("Gripper.painter", gripperPainter);
uiDefaults.put("JideTabbedPane.gripperPainter", gripperPainter);
uiDefaults.put("JideTabbedPane.defaultTabShape", JideTabbedPane.SHAPE_OFFICE2003);
uiDefaults.put("JideTabbedPane.selectedTabTextForeground", UIDefaultsLookup.getColor("controlText"));
uiDefaults.put("JideTabbedPane.unselectedTabTextForeground", UIDefaultsLookup.getColor("controlText"));
uiDefaults.put("JideTabbedPane.foreground", UIDefaultsLookup.getColor("controlText"));
uiDefaults.put("JideTabbedPane.light", UIDefaultsLookup.getColor("control"));
uiDefaults.put("JideSplitPaneDivider.gripperPainter", gripperPainter);
int products = LookAndFeelFactory.getProductsUsed();
if ((products & PRODUCT_DOCK) != 0) {
ImageIcon titleButtonImage = IconsFactory.getImageIcon(VsnetWindowsUtils.class, "icons/title_buttons_windows.gif"); // 10 x 10 x 8
final int titleButtonSize = 10;
uiDefaults.put("DockableFrameUI", "com.jidesoft.plaf.vsnet.VsnetDockableFrameUI");
uiDefaults.put("DockableFrameTitlePane.hideIcon", IconsFactory.getIcon(null, titleButtonImage, 0, 0, titleButtonSize, titleButtonSize));
uiDefaults.put("DockableFrameTitlePane.unfloatIcon", IconsFactory.getIcon(null, titleButtonImage, 0, titleButtonSize, titleButtonSize, titleButtonSize));
uiDefaults.put("DockableFrameTitlePane.floatIcon", IconsFactory.getIcon(null, titleButtonImage, 0, 2 * titleButtonSize, titleButtonSize, titleButtonSize));
uiDefaults.put("DockableFrameTitlePane.autohideIcon", IconsFactory.getIcon(null, titleButtonImage, 0, 3 * titleButtonSize, titleButtonSize, titleButtonSize));
uiDefaults.put("DockableFrameTitlePane.stopAutohideIcon", IconsFactory.getIcon(null, titleButtonImage, 0, 4 * titleButtonSize, titleButtonSize, titleButtonSize));
uiDefaults.put("DockableFrameTitlePane.hideAutohideIcon", IconsFactory.getIcon(null, titleButtonImage, 0, 5 * titleButtonSize, titleButtonSize, titleButtonSize));
uiDefaults.put("DockableFrameTitlePane.maximizeIcon", IconsFactory.getIcon(null, titleButtonImage, 0, 6 * titleButtonSize, titleButtonSize, titleButtonSize));
uiDefaults.put("DockableFrameTitlePane.restoreIcon", IconsFactory.getIcon(null, titleButtonImage, 0, 7 * titleButtonSize, titleButtonSize, titleButtonSize));
uiDefaults.put("DockableFrameTitlePane.buttonGap", 4); // gap between buttons
uiDefaults.put("DockableFrame.titleBorder", new BorderUIResource(BorderFactory.createEmptyBorder(1, 0, 1, 0)));
uiDefaults.put("DockableFrame.border", new BorderUIResource(BorderFactory.createEmptyBorder(2, 0, 0, 0)));
uiDefaults.put("DockableFrameTitlePane.gripperPainter", gripperPainter);
}
break;
case ECLIPSE_STYLE:
EclipseMetalUtils.initComponentDefaults(uiDefaults);
EclipseMetalUtils.initClassDefaults(uiDefaults);
break;
case ECLIPSE3X_STYLE:
Eclipse3xMetalUtils.initComponentDefaults(uiDefaults);
Eclipse3xMetalUtils.initClassDefaults(uiDefaults);
break;
case XERTO_STYLE:
case XERTO_STYLE_WITHOUT_MENU:
XertoMetalUtils.initComponentDefaults(uiDefaults);
XertoMetalUtils.initClassDefaults(uiDefaults);
break;
}
}
else if (lnf.getClass().getName().equals(MetalLookAndFeel.class.getName())) {
switch (style) {
case OFFICE2003_STYLE:
case VSNET_STYLE:
VsnetMetalUtils.initComponentDefaults(uiDefaults);
VsnetMetalUtils.initClassDefaultsWithMenu(uiDefaults);
break;
case ECLIPSE_STYLE:
EclipseMetalUtils.initComponentDefaults(uiDefaults);
EclipseMetalUtils.initClassDefaults(uiDefaults);
break;
case ECLIPSE3X_STYLE:
Eclipse3xMetalUtils.initComponentDefaults(uiDefaults);
Eclipse3xMetalUtils.initClassDefaults(uiDefaults);
break;
case VSNET_STYLE_WITHOUT_MENU:
VsnetMetalUtils.initComponentDefaults(uiDefaults);
VsnetMetalUtils.initClassDefaults(uiDefaults);
break;
case XERTO_STYLE:
case XERTO_STYLE_WITHOUT_MENU:
XertoMetalUtils.initComponentDefaults(uiDefaults);
XertoMetalUtils.initClassDefaults(uiDefaults);
break;
default:
}
}
else if (lnf instanceof MetalLookAndFeel) {
switch (style) {
case OFFICE2003_STYLE:
VsnetMetalUtils.initComponentDefaults(uiDefaults);
VsnetMetalUtils.initClassDefaults(uiDefaults);
break;
case ECLIPSE_STYLE:
EclipseMetalUtils.initClassDefaults(uiDefaults);
EclipseMetalUtils.initComponentDefaults(uiDefaults);
break;
case ECLIPSE3X_STYLE:
Eclipse3xMetalUtils.initClassDefaults(uiDefaults);
Eclipse3xMetalUtils.initComponentDefaults(uiDefaults);
break;
case VSNET_STYLE:
case VSNET_STYLE_WITHOUT_MENU:
VsnetMetalUtils.initComponentDefaults(uiDefaults);
VsnetMetalUtils.initClassDefaults(uiDefaults);
break;
case XERTO_STYLE:
case XERTO_STYLE_WITHOUT_MENU:
XertoMetalUtils.initComponentDefaults(uiDefaults);
XertoMetalUtils.initClassDefaults(uiDefaults);
break;
default:
}
}
else if (lnf instanceof WindowsLookAndFeel) {
switch (style) {
case OFFICE2003_STYLE:
VsnetWindowsUtils.initComponentDefaultsWithMenu(uiDefaults);
VsnetWindowsUtils.initClassDefaultsWithMenu(uiDefaults);
Office2003WindowsUtils.initClassDefaults(uiDefaults);
Office2003WindowsUtils.initComponentDefaults(uiDefaults);
break;
case ECLIPSE_STYLE:
EclipseWindowsUtils.initClassDefaultsWithMenu(uiDefaults);
EclipseWindowsUtils.initComponentDefaultsWithMenu(uiDefaults);
break;
case ECLIPSE3X_STYLE:
Eclipse3xWindowsUtils.initClassDefaultsWithMenu(uiDefaults);
Eclipse3xWindowsUtils.initComponentDefaultsWithMenu(uiDefaults);
break;
case VSNET_STYLE:
VsnetWindowsUtils.initComponentDefaultsWithMenu(uiDefaults);
VsnetWindowsUtils.initClassDefaultsWithMenu(uiDefaults);
break;
case VSNET_STYLE_WITHOUT_MENU:
VsnetWindowsUtils.initComponentDefaults(uiDefaults);
VsnetWindowsUtils.initClassDefaults(uiDefaults);
break;
case XERTO_STYLE:
XertoWindowsUtils.initComponentDefaultsWithMenu(uiDefaults);
XertoWindowsUtils.initClassDefaultsWithMenu(uiDefaults);
break;
case XERTO_STYLE_WITHOUT_MENU:
XertoWindowsUtils.initComponentDefaults(uiDefaults);
XertoWindowsUtils.initClassDefaults(uiDefaults);
break;
default:
}
}
// For Mac only
else if ((isLnfInUse(AQUA_LNF) && isAquaLnfInstalled())
|| (isLnfInUse(QUAQUA_LNF) && isQuaquaLnfInstalled())) {
// use reflection since we don't deliver source code of AquaJideUtils as most users don't compile it on Mac OS X
try {
Class<?> aquaJideUtils = getUIManagerClassLoader().loadClass("com.jidesoft.plaf.aqua.AquaJideUtils");
aquaJideUtils.getMethod("initComponentDefaults", UIDefaults.class).invoke(null, uiDefaults);
aquaJideUtils.getMethod("initClassDefaults", UIDefaults.class).invoke(null, uiDefaults);
}
catch (ClassNotFoundException e) {
throw new RuntimeException(e);
}
catch (IllegalAccessException e) {
throw new RuntimeException(e);
}
catch (IllegalArgumentException e) {
throw new RuntimeException(e);
}
catch (InvocationTargetException e) {
JideSwingUtilities.throwInvocationTargetException(e);
}
catch (NoSuchMethodException e) {
throw new RuntimeException(e);
}
catch (SecurityException e) {
throw new RuntimeException(e);
}
}
else {
// built in initializer
if (isGTKLnfInstalled() && isLnfInUse(GTK_LNF)) {
new GTKInitializer().initialize(uiDefaults);
}
else if (isSyntheticaLnfInstalled()
&& (lnf.getClass().getName().startsWith(SYNTHETICA_LNF_PREFIX) || isLnfInUse(SYNTHETICA_LNF))) {
new SyntheticaInitializer().initialize(uiDefaults);
}
else if (isNimbusLnfInstalled() && lnf.getClass().getName().indexOf(NIMBUS_LNF_NAME) != -1) {
new NimbusInitializer().initialize(uiDefaults);
}
switch (style) {
case OFFICE2003_STYLE:
if (SystemInfo.isWindows()) {
VsnetWindowsUtils.initComponentDefaultsWithMenu(uiDefaults);
Office2003WindowsUtils.initComponentDefaults(uiDefaults);
Office2003WindowsUtils.initClassDefaults(uiDefaults);
}
else {
VsnetMetalUtils.initComponentDefaults(uiDefaults);
VsnetMetalUtils.initClassDefaults(uiDefaults);
}
break;
case ECLIPSE_STYLE:
if (SystemInfo.isWindows()) {
EclipseWindowsUtils.initClassDefaultsWithMenu(uiDefaults);
EclipseWindowsUtils.initComponentDefaultsWithMenu(uiDefaults);
}
else {
EclipseMetalUtils.initClassDefaults(uiDefaults);
EclipseMetalUtils.initComponentDefaults(uiDefaults);
}
break;
case ECLIPSE3X_STYLE:
if (SystemInfo.isWindows()) {
Eclipse3xWindowsUtils.initClassDefaultsWithMenu(uiDefaults);
Eclipse3xWindowsUtils.initComponentDefaultsWithMenu(uiDefaults);
}
else {
Eclipse3xMetalUtils.initClassDefaults(uiDefaults);
Eclipse3xMetalUtils.initComponentDefaults(uiDefaults);
}
break;
case VSNET_STYLE:
if (SystemInfo.isWindows()) {
VsnetWindowsUtils.initClassDefaultsWithMenu(uiDefaults);
VsnetWindowsUtils.initComponentDefaultsWithMenu(uiDefaults);
}
else {
VsnetMetalUtils.initComponentDefaults(uiDefaults);
VsnetMetalUtils.initClassDefaults(uiDefaults);
}
break;
case VSNET_STYLE_WITHOUT_MENU:
if (SystemInfo.isWindows()) {
VsnetWindowsUtils.initClassDefaults(uiDefaults);
VsnetWindowsUtils.initComponentDefaults(uiDefaults);
}
else {
VsnetMetalUtils.initComponentDefaults(uiDefaults);
VsnetMetalUtils.initClassDefaults(uiDefaults);
}
break;
case XERTO_STYLE:
if (SystemInfo.isWindows()) {
XertoWindowsUtils.initClassDefaultsWithMenu(uiDefaults);
XertoWindowsUtils.initComponentDefaultsWithMenu(uiDefaults);
}
else {
XertoMetalUtils.initComponentDefaults(uiDefaults);
XertoMetalUtils.initClassDefaults(uiDefaults);
}
break;
case XERTO_STYLE_WITHOUT_MENU:
if (SystemInfo.isWindows()) {
XertoWindowsUtils.initClassDefaults(uiDefaults);
XertoWindowsUtils.initComponentDefaults(uiDefaults);
}
else {
XertoMetalUtils.initComponentDefaults(uiDefaults);
XertoMetalUtils.initClassDefaults(uiDefaults);
}
break;
default:
}
// built in customizer
if (lnf.getClass().getName().startsWith(SYNTHETICA_LNF_PREFIX) || isLnfInUse(SYNTHETICA_LNF)) {
new SyntheticaCustomizer().customize(uiDefaults);
}
}
uiDefaults.put(JIDE_EXTENSION_INSTALLLED, Boolean.TRUE);
UIDefaultsCustomizer[] customizers = getUIDefaultsCustomizers();
for (UIDefaultsCustomizer customizer : customizers) {
if (customizer != null) {
customizer.customize(uiDefaults);
}
}
}
/**
* Returns whether or not the L&F is in classpath.
*
* @param lnfName the L&F name.
* @return <tt>true</tt> if the L&F is in classpath, <tt>false</tt> otherwise
*/
public static boolean isLnfInstalled(String lnfName) {
try {
getUIManagerClassLoader().loadClass(lnfName);
return true;
}
catch (ClassNotFoundException e) {
return false;
}
}
public static ClassLoader getUIManagerClassLoader() {
Object cl = UIManager.get("ClassLoader");
if (cl instanceof ClassLoader) {
return (ClassLoader) cl;
}
ClassLoader classLoader = LookAndFeelFactory.class.getClassLoader();
if (classLoader == null) {
classLoader = ClassLoader.getSystemClassLoader();
}
return classLoader;
}
/**
* Checks if the L&F is the L&F or a subclass of the L&F.
*
* @param lnfName the L&F name.
* @return true or false.
*/
public static boolean isLnfInUse(String lnfName) {
try {
return lnfName.equals(UIManager.getLookAndFeel().getClass().getName())
|| Class.forName(lnfName).isAssignableFrom(UIManager.getLookAndFeel().getClass());
}
catch (ClassNotFoundException e) {
return false;
}
}
/**
* Returns whether or not the Aqua L&F is in classpath.
*
* @return <tt>true</tt> if aqua L&F is in classpath, <tt>false</tt> otherwise
*/
public static boolean isAquaLnfInstalled() {
return isLnfInstalled(AQUA_LNF);
}
/**
* Returns whether or not the Quaqua L&F is in classpath.
*
* @return <tt>true</tt> if Quaqua L&F is in classpath, <tt>false</tt> otherwise
*/
public static boolean isQuaquaLnfInstalled() {
return isLnfInstalled(QUAQUA_LNF);
}
/**
* Returns whether alloy L&F is in classpath
*
* @return <tt>true</tt> alloy L&F is in classpath, <tt>false</tt> otherwise
*/
public static boolean isAlloyLnfInstalled() {
return isLnfInstalled(ALLOY_LNF);
}
/**
* Returns whether GTK L&F is in classpath
*
* @return <tt>true</tt> GTK L&F is in classpath, <tt>false</tt> otherwise
*/
public static boolean isGTKLnfInstalled() {
return isLnfInstalled(GTK_LNF);
}
/**
* Returns whether Plastic3D L&F is in classpath
*
* @return <tt>true</tt> Plastic3D L&F is in classpath, <tt>false</tt> otherwise
*/
public static boolean isPlastic3DLnfInstalled() {
return isLnfInstalled(PLASTIC3D_LNF);
}
/**
* Returns whether Plastic3D L&F is in classpath
*
* @return <tt>true</tt> Plastic3D L&F is in classpath, <tt>false</tt> otherwise
*/
public static boolean isPlastic3D13LnfInstalled() {
return isLnfInstalled(PLASTIC3D_LNF_1_3);
}
/**
* Returns whether PlasticXP L&F is in classpath
*
* @return <tt>true</tt> Plastic3D L&F is in classpath, <tt>false</tt> otherwise
*/
public static boolean isPlasticXPLnfInstalled() {
return isLnfInstalled(PLASTICXP_LNF);
}
/**
* Returns whether Tonic L&F is in classpath
*
* @return <tt>true</tt> Tonic L&F is in classpath, <tt>false</tt> otherwise
*/
public static boolean isTonicLnfInstalled() {
return isLnfInstalled(TONIC_LNF);
}
/**
* Returns whether A03 L&F is in classpath
*
* @return <tt>true</tt> A03 L&F is in classpath, <tt>false</tt> otherwise
*/
public static boolean isA03LnfInstalled() {
return isLnfInstalled(A03_LNF);
}
/**
* Returns whether or not the Pgs L&F is in classpath.
*
* @return <tt>true</tt> if pgs L&F is in classpath, <tt>false</tt> otherwise
*/
public static boolean isPgsLnfInstalled() {
return isLnfInstalled(PGS_LNF);
}
/**
* Returns whether or not the Synthetica L&F is in classpath.
*
* @return <tt>true</tt> if Synthetica L&F is in classpath, <tt>false</tt> otherwise
*/
public static boolean isSyntheticaLnfInstalled() {
return isLnfInstalled(SYNTHETICA_LNF);
}
/**
* Returns whether or not the Nimbus L&F is in classpath.
*
* @return <tt>true</tt> if Nimbus L&F is in classpath, <tt>false</tt> otherwise
*/
public static boolean isNimbusLnfInstalled() {
UIManager.LookAndFeelInfo[] infos = UIManager.getInstalledLookAndFeels();
for (UIManager.LookAndFeelInfo info : infos) {
if (info.getClassName().indexOf(NIMBUS_LNF_NAME) != -1) {
return true;
}
}
return false;
}
/**
* Install the default L&F. In this method, we will look at system property "swing.defaultlaf" first. If the value
* is set and it's not an instance of Synth L&F, we will use it. Otherwise, we will use Metal L&F is OS is Linux or
* UNIX and use UIManager.getSystemLookAndFeelClassName() for other OS. In addition, we will add JIDE extension to
* it.
*/
public static void installDefaultLookAndFeelAndExtension() {
installDefaultLookAndFeel();
// to add attitional UIDefault for JIDE components
LookAndFeelFactory.installJideExtension();
}
/**
* Install the default L&F. In this method, we will look at system property "swing.defaultlaf" first. If the value
* is set and it's not an instance of Synth L&F, we will use it. Otherwise, we will use Metal L&F is OS is Linux or
* UNIX and use UIManager.getSystemLookAndFeelClassName() for other OS.
*/
public static void installDefaultLookAndFeel() {
try {
String lnfName = SecurityUtils.getProperty("swing.defaultlaf", null);
Class<?> lnfClass = null;
if (lnfName != null) {
try {
lnfClass = getUIManagerClassLoader().loadClass(lnfName);
}
catch (ClassNotFoundException e) {
// ignore
}
}
if (lnfClass == null) {
UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
}
else {
UIManager.setLookAndFeel(lnfName);
}
}
catch (Exception e) {
// ignore
}
}
/**
* Gets current L&F.
*
* @return the current L&F.
*/
public static LookAndFeel getLookAndFeel() {
return _lookAndFeel;
}
/**
* Gets current style.
*
* @return the current style.
*/
public static int getStyle() {
return _style;
}
/**
* Gets all UIDefaults customizers.
*
* @return an array of UIDefaults customizers.
*/
public static UIDefaultsCustomizer[] getUIDefaultsCustomizers() {
return _uiDefaultsCustomizers.toArray(new UIDefaultsCustomizer[_uiDefaultsCustomizers.size()]);
}
/**
* Adds your own UIDefaults customizer. This customizer will be called after installJideExtension() is called.
* <code><pre>
* For example, we use "JideButton.font" as the UIDefault for the JideButton font. If you want
* to use another font, you can do
* LookAndFeelFactory.addUIDefaultsCustomizer(new LookAndFeelFactory.UIDefaultsCustomizer() {
* public void customize(UIDefaults defaults) {
* defaults.put("JideButton.font", whateverFont);
* }
* });
* </pre></code>
*
* @param uiDefaultsCustomizer the UIDefaultsCustomizer
*/
public static void addUIDefaultsCustomizer(UIDefaultsCustomizer uiDefaultsCustomizer) {
if (!_uiDefaultsCustomizers.contains(uiDefaultsCustomizer)) {
_uiDefaultsCustomizers.add(uiDefaultsCustomizer);
}
}
/**
* Removes an existing UIDefaults customizer you added before.
*
* @param uiDefaultsCustomizer the UIDefaultsCustomizer
*/
public static void removeUIDefaultsCustomizer(UIDefaultsCustomizer uiDefaultsCustomizer) {
_uiDefaultsCustomizers.remove(uiDefaultsCustomizer);
}
/**
* Gets all UIDefaults initializers.
*
* @return an array of UIDefaults initializers.
*/
public static UIDefaultsInitializer[] getUIDefaultsInitializers() {
return _uiDefaultsInitializers.toArray(new UIDefaultsInitializer[_uiDefaultsInitializers.size()]);
}
/**
* Adds your own UIDefaults initializer. This initializer will be called before installJideExtension() is called.
* <p/>
* Here is how you use it. For example, we use the color of UIDefault "activeCaption" to get the active title color
* which we will use for active title bar color in JIDE components. If the L&F you are using doesn't set this
* UIDefault, we might throw NPE later in the code. To avoid this, you call
* <code><pre>
* LookAndFeelFactory.addUIDefaultsInitializer(new LookAndFeelFactory.UIDefaultsInitializer() {
* public void initialize(UIDefaults defaults) {
* defaults.put("activeCaption", whateverColor);
* }
* });
* UIManager.setLookAndFeel(...); // set whatever L&F
* LookAndFeelFactory.installJideExtension(); // install the UIDefaults needed by the JIDE
* components
* </pre></code>
*
* @param uiDefaultsInitializer the UIDefaultsInitializer.
*/
public static void addUIDefaultsInitializer(UIDefaultsInitializer uiDefaultsInitializer) {
if (!_uiDefaultsInitializers.contains(uiDefaultsInitializer)) {
_uiDefaultsInitializers.add(uiDefaultsInitializer);
}
}
/**
* Removes an existing UIDefaults initializer you added before.
*
* @param uiDefaultsInitializer the UIDefaultsInitializer
*/
public static void removeUIDefaultsInitializer(UIDefaultsInitializer uiDefaultsInitializer) {
_uiDefaultsInitializers.remove(uiDefaultsInitializer);
}
public static class GTKInitializer implements UIDefaultsInitializer {
public void initialize(UIDefaults defaults) {
ImageIcon rightImageIcon = IconsFactory.createMaskImage(new JLabel(), JideIconsFactory.getImageIcon(JideIconsFactory.Arrow.RIGHT), Color.BLACK, Color.GRAY);
ImageIcon downImageIcon = IconsFactory.createMaskImage(new JLabel(), JideIconsFactory.getImageIcon(JideIconsFactory.Arrow.DOWN), Color.BLACK, Color.GRAY);
Object[] uiDefaults = {
"activeCaption", defaults.getColor("textHighlight"),
"activeCaptionText", defaults.getColor("textHighlightText"),
"inactiveCaptionBorder", defaults.getColor("controlShadowtextHighlightText"),
"CategorizedTable.categoryCollapsedIcon", rightImageIcon,
"CategorizedTable.categoryExpandedIcon", downImageIcon,
"CategorizedTable.collapsedIcon", rightImageIcon,
"CategorizedTable.expandedIcon", downImageIcon,
};
putDefaults(defaults, uiDefaults);
}
}
public static class SyntheticaInitializer implements UIDefaultsInitializer {
public void initialize(UIDefaults defaults) {
Object[] uiDefaults = {
"Label.font", UIDefaultsLookup.getFont("Button.font"),
"ToolBar.font", UIDefaultsLookup.getFont("Button.font"),
"MenuItem.acceleratorFont", UIDefaultsLookup.getFont("Button.font"),
"ComboBox.disabledForeground", defaults.get("Synthetica.comboBox.disabled.textColor"),
"ComboBox.disabledBackground", defaults.get("Synthetica.comboBox.disabled.backgroundColor"),
"Slider.focusInsets", new InsetsUIResource(0, 0, 0, 0),
};
putDefaults(defaults, uiDefaults);
}
}
public static class SyntheticaCustomizer implements UIDefaultsCustomizer {
public void customize(UIDefaults defaults) {
Object[] uiDefaults = {
"JideTabbedPaneUI", "com.jidesoft.plaf.synthetica.SyntheticaJideTabbedPaneUI",
"Workspace.background", UIManager.getColor("control"),
"JideTabbedPane.tabAreaBackground", UIManager.getColor("control"),
"JideTabbedPane.background", UIManager.getColor("control"),
"JideTabbedPane.defaultTabShape", JideTabbedPane.SHAPE_ROUNDED_VSNET,
"JideTabbedPane.defaultTabShape", JideTabbedPane.SHAPE_ROUNDED_VSNET,
"DockableFrame.inactiveTitleForeground", UIDefaultsLookup.getColor("Synthetica.flexdock.titlebar.color"),
"DockableFrame.activeTitleForeground", UIDefaultsLookup.getColor("Synthetica.flexdock.titlebar.color.selected"),
"DockableFrame.titleBorder", UIDefaultsLookup.getColor("Synthetica.flexdock.border.color"),
"JideTabbedPane.contentBorderInsets", new InsetsUIResource(2, 2, 2, 2),
"FrameContainer.contentBorderInsets", new InsetsUIResource(2, 2, 2, 2),
"CollapsiblePane.background", UIDefaultsLookup.getColor("TaskPane.borderColor"),
"CollapsiblePane.emphasizedBackground", UIDefaultsLookup.getColor("TaskPane.borderColor"),
"CollapsiblePane.foreground", UIDefaultsLookup.getColor("TaskPane.titleForeground"),
"CollapsiblePane.emphasizedForeground", UIDefaultsLookup.getColor("TaskPane.specialTitleForeground"),
"StatusBarItem.border", new BorderUIResource(BorderFactory.createEmptyBorder(2, 2, 2, 2)),
"JideButton.foreground", UIDefaultsLookup.getColor("Synthetica.flexdock.titlebar.color.selected"),
"JideSplitButton.foreground", UIDefaultsLookup.getColor("Synthetica.flexdock.titlebar.color.selected"),
"Icon.floating", Boolean.FALSE,
"CommandBar.border", new BorderUIResource(BorderFactory.createEmptyBorder()),
"CommandBar.borderVert", new BorderUIResource(BorderFactory.createEmptyBorder()),
"CommandBar.borderFloating", new BorderUIResource(BorderFactory.createCompoundBorder(BorderFactory.createLineBorder(UIDefaultsLookup.getColor("InternalFrame.activeTitleBackground"), 2), BorderFactory.createEmptyBorder(1, 1, 1, 1))),
"CommandBar.titleBarBackground", UIDefaultsLookup.getColor("InternalFrame.activeTitleBackground"),
"CommandBarContainer.verticalGap", 0,
"JideSplitPane.dividerSize", 6,
};
overwriteDefaults(defaults, uiDefaults);
try {
Class<?> painterClass = Class.forName("com.jidesoft.plaf.synthetica.SyntheticaJidePainter");
Method getInstanceMethod = painterClass.getMethod("getInstance");
Object painter = getInstanceMethod.invoke(null);
UIDefaultsLookup.put(UIManager.getDefaults(), "Theme.painter", painter);
}
catch (ClassNotFoundException e) {
e.printStackTrace();
}
catch (NoSuchMethodException e) {
e.printStackTrace();
}
catch (IllegalAccessException e) {
e.printStackTrace();
}
catch (InvocationTargetException e) {
e.printStackTrace();
}
}
}
public static class NimbusInitializer implements UIDefaultsInitializer {
public void initialize(UIDefaults defaults) {
Object marginBorder = new SwingLazyValue(
"javax.swing.plaf.basic.BasicBorders$MarginBorder");
Object[] uiDefaults = {
"textHighlight", new ColorUIResource(197, 218, 233),
"controlText", new ColorUIResource(Color.BLACK),
"activeCaptionText", new ColorUIResource(Color.BLACK),
"MenuItem.acceleratorFont", new FontUIResource("Arial", Font.PLAIN, 12),
"ComboBox.background", new ColorUIResource(Color.WHITE),
"ComboBox.disabledForeground", new ColorUIResource(Color.DARK_GRAY),
"ComboBox.disabledBackground", new ColorUIResource(Color.GRAY),
"activeCaption", new ColorUIResource(197, 218, 233),
"inactiveCaption", new ColorUIResource(Color.DARK_GRAY),
"control", new ColorUIResource(220, 223, 228),
"controlLtHighlight", new ColorUIResource(Color.WHITE),
"controlHighlight", new ColorUIResource(Color.LIGHT_GRAY),
"controlShadow", new ColorUIResource(133, 137, 144),
"controlDkShadow", new ColorUIResource(Color.BLACK),
"MenuItem.background", new ColorUIResource(237, 239, 242),
"SplitPane.background", new ColorUIResource(220, 223, 228),
"Tree.hash", new ColorUIResource(Color.GRAY),
"TextField.foreground", new ColorUIResource(Color.BLACK),
"TextField.inactiveForeground", new ColorUIResource(Color.BLACK),
"TextField.selectionForeground", new ColorUIResource(Color.WHITE),
"TextField.selectionBackground", new ColorUIResource(197, 218, 233),
"Table.gridColor", new ColorUIResource(Color.BLACK),
"TextField.background", new ColorUIResource(Color.WHITE),
"Table.selectionBackground", defaults.getColor("Tree.selectionBackground"),
"Table.selectionForeground", defaults.getColor("Tree.selectionForeground"),
"Menu.border", marginBorder,
"MenuItem.border", marginBorder,
"CheckBoxMenuItem.border", marginBorder,
"RadioButtonMenuItem.border", marginBorder,
};
putDefaults(defaults, uiDefaults);
}
}
@SuppressWarnings({"UseOfSystemOutOrSystemErr"})
public static void verifyDefaults(UIDefaults table, Object[] keyValueList) {
for (int i = 0, max = keyValueList.length; i < max; i += 2) {
Object value = keyValueList[i + 1];
if (value == null) {
System.out.println("The value for " + keyValueList[i] + " is null");
}
else {
Object oldValue = table.get(keyValueList[i]);
if (oldValue != null) {
System.out.println("The value for " + keyValueList[i] + " exists which is " + oldValue);
}
}
}
}
/**
* Puts a list of UIDefault to the UIDefaults table. The keyValueList is an array with a key and value in pair. If
* the value is null, this method will remove the key from the table. If the table already has a value for the key,
* the new value will be ignored. This is the difference from {@link #putDefaults(javax.swing.UIDefaults,Object[])}
* method. You should use this method in {@link UIDefaultsInitializer} so that it fills in the UIDefault value only
* when it is missing.
*
* @param table the ui defaults table
* @param keyValueArray the key value array. It is in the format of a key followed by a value.
*/
public static void putDefaults(UIDefaults table, Object[] keyValueArray) {
for (int i = 0, max = keyValueArray.length; i < max; i += 2) {
Object value = keyValueArray[i + 1];
if (value == null) {
table.remove(keyValueArray[i]);
}
else {
if (table.get(keyValueArray[i]) == null) {
table.put(keyValueArray[i], value);
}
}
}
}
/**
* Puts a list of UIDefault to the UIDefaults table. The keyValueList is an array with a key and value in pair. If
* the value is null, this method will remove the key from the table. Otherwise, it will put the new value in even
* if the table already has a value for the key. This is the difference from {@link
* #putDefaults(javax.swing.UIDefaults,Object[])} method. You should use this method in {@link UIDefaultsCustomizer}
* because you always want to override the existing value using the new value.
*
* @param table the ui defaults table
* @param keyValueArray the key value array. It is in the format of a key followed by a value.
*/
public static void overwriteDefaults(UIDefaults table, Object[] keyValueArray) {
for (int i = 0, max = keyValueArray.length; i < max; i += 2) {
Object value = keyValueArray[i + 1];
if (value == null) {
table.remove(keyValueArray[i]);
}
else {
table.put(keyValueArray[i], value);
}
}
}
private static int _productsUsed = -1;
public static int getProductsUsed() {
if (_productsUsed == -1) {
_productsUsed = 0;
try {
Class.forName("com.jidesoft.docking.Product");
_productsUsed |= PRODUCT_DOCK;
}
catch (ClassNotFoundException e) {
//
}
try {
Class.forName("com.jidesoft.action.Product");
_productsUsed |= PRODUCT_ACTION;
}
catch (ClassNotFoundException e) {
//
}
try {
Class.forName("com.jidesoft.document.Product");
_productsUsed |= PRODUCT_COMPONENTS;
}
catch (ClassNotFoundException e) {
//
}
try {
Class.forName("com.jidesoft.grid.Product");
_productsUsed |= PRODUCT_GRIDS;
}
catch (ClassNotFoundException e) {
//
}
try {
Class.forName("com.jidesoft.wizard.Product");
_productsUsed |= PRODUCT_DIALOGS;
}
catch (ClassNotFoundException e) {
//
}
try {
Class.forName("com.jidesoft.pivot.Product");
_productsUsed |= PRODUCT_PIVOT;
}
catch (ClassNotFoundException e) {
//
}
try {
Class.forName("com.jidesoft.shortcut.Product");
_productsUsed |= PRODUCT_SHORTCUT;
}
catch (ClassNotFoundException e) {
//
}
try {
Class.forName("com.jidesoft.editor.Product");
_productsUsed |= PRODUCT_CODE_EDITOR;
}
catch (ClassNotFoundException e) {
//
}
try {
Class.forName("com.jidesoft.rss.Product");
_productsUsed |= PRODUCT_FEEDREADER;
}
catch (ClassNotFoundException e) {
//
}
}
return _productsUsed;
}
/**
* Sets the products you will use. This is needed so that LookAndFeelFactory knows what UIDefault to initialize. For
* example, if you use only JIDE Docking Framework and JIDE Grids, you should call
* <code>setProductUsed(ProductNames.PRODUCT_DOCK | ProductNames.PRODUCT_GRIDS)</code> so that we don't initialize
* UIDefaults needed by any other products. If you use this class as part of JIDE Common Layer open source project,
* you should call <code>setProductUsed(ProductNames.PRODUCT_COMMON)</code>. If you want to use all JIDE products,
* you should call <code>setProductUsed(ProductNames.PRODUCT_ALL)</code>
*
* @param productsUsed a bit-wise OR of product values defined in {@link com.jidesoft.utils.ProductNames}.
*/
public static void setProductsUsed(int productsUsed) {
_productsUsed = productsUsed;
}
/**
* Checks if the current L&F uses decorated frames.
*
* @return true if the current L&F uses decorated frames. Otherwise false.
*/
public static boolean isCurrentLnfDecorated() {
return !isLnfInUse(SYNTHETICA_LNF);
}
}
| [
"yuzhongxing88@gmail.com"
] | yuzhongxing88@gmail.com |
4a3c11c7acff614f30fce77f85c8f6c34d8f737e | e11715b545d852658c8dab89c76256d890aef0df | /challenge/src/main/java/com/example/truelogic/demo/repository/PlayerRepository.java | 2d31cdb61a8d2ca81616fadd71ab7cf68ff1a597 | [] | no_license | Julianga19/truelogic | 66536f39d64b6284fd035d8e70778a5d024bbee6 | 039e2121a7b3a5aa17286b17d1159162f1f0b394 | refs/heads/main | 2023-06-07T00:48:39.821329 | 2021-06-29T13:09:07 | 2021-06-29T13:09:07 | 381,359,205 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 283 | java | package com.example.truelogic.demo.repository;
import com.example.truelogic.demo.model.Player;
import org.springframework.data.repository.CrudRepository;
/**
*
* @author jgarzon
*/
public interface PlayerRepository extends CrudRepository<Player, Integer> {
}
| [
"noreply@github.com"
] | noreply@github.com |
f65ffd3dccc76053f8d80c2076160df6d69393f6 | e932ebf6d16bee11a007feaaec94978a867a7015 | /Project/tolometCore/src/main/java/com/akrog/tolomet/providers/MeteoNavarraProvider.java | 26fe5769a9a0e4320a927a61de2a42f1ae26265b | [] | no_license | akrogp/tolomet | 62a195081e5f4f336e5c9df349aa4226dbe70855 | 2e03b9c5ee9e119c7b0ef29776f60c88877837bc | refs/heads/master | 2023-05-01T12:04:49.656796 | 2023-04-19T20:33:15 | 2023-04-19T20:33:15 | 45,478,043 | 3 | 2 | null | null | null | null | UTF-8 | Java | false | false | 5,632 | java | package com.akrog.tolomet.providers;
import com.akrog.tolomet.Station;
import com.akrog.tolomet.utils.Utils;
import com.akrog.tolomet.io.Downloader;
import java.text.DateFormat;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.List;
import java.util.TimeZone;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
public class MeteoNavarraProvider implements WindProvider {
public MeteoNavarraProvider() {
df = new SimpleDateFormat("dd/MM/yyyyH:mm");
df.setTimeZone(TimeZone.getTimeZone("GMT"));
}
@Override
public void refresh(Station station) {
travel(station, System.currentTimeMillis());
}
@Override
public boolean travel(Station station, long date) {
Calendar now = Calendar.getInstance(TimeZone.getTimeZone("GMT"));
now.setTimeInMillis(date);
String time1 = String.format("%d/%d/%d", now.get(Calendar.DAY_OF_MONTH), now.get(Calendar.MONTH)+1, now.get(Calendar.YEAR) );
String time2 = String.format("%d/%d/%d", now.get(Calendar.DAY_OF_MONTH)+1, now.get(Calendar.MONTH)+1, now.get(Calendar.YEAR) );
downloader = new Downloader();
downloader.useLineBreak(false);
downloader.setUrl("http://meteo.navarra.es/download/estacion_datos.cfm");
downloader.addParam("IDEstacion",station.getCode().substring(2));
downloader.addParam("p_10","7");
downloader.addParam("p_10","2");
downloader.addParam("p_10","9");
downloader.addParam("p_10","6");
downloader.addParam("p_10","1");
downloader.addParam("fecha_desde",time1);
downloader.addParam("fecha_hasta",time2);
downloader.addParam("dl","csv");
updateStation(station, downloader.download());
return true;
}
@Override
public void cancel() {
if( downloader != null )
downloader.cancel();
}
protected void updateStation(Station station, String data) {
if( data == null )
return;
String[] cells = data.split(",");
long date;
Number num;
if( cells.length < 26 )
return;
int i;
for( i = 0; i < cells.length; i++ )
if( cells[i].toLowerCase().contains("fecha") )
break;
for( i = i+16; i < cells.length; i+=8 ) {
if( END_PATTERN.matcher(cells[i]).find() )
break;
if( cells[i].equals("\"\"") || cells[i+1].equals("\"- -\"") )
continue;
date = toEpoch(getContent(cells[i]));
num = Integer.parseInt(getContent(cells[i+1]));
station.getMeteo().getWindDirection().put(date, num);
num = Float.parseFloat(getContent(cells[i+6]));
station.getMeteo().getWindSpeedMed().put(date, num);
num = Float.parseFloat(getContent(cells[i+4]));
station.getMeteo().getWindSpeedMax().put(date, num);
try {
num = (float)Integer.parseInt(getContent(cells[i+2]));
station.getMeteo().getAirHumidity().put(date, num);
} catch( Exception e ) {}
try {
num = Float.parseFloat(getContent(cells[i+7]));
station.getMeteo().getAirTemperature().put(date, num);
} catch( Exception e ) {}
}
}
@Override
public int getRefresh( String code ) {
return 10;
}
@Override
public String getInfoUrl(String code) {
return "http://meteo.navarra.es/estaciones/estacion_detalle.cfm?idestacion="+code.substring(2);
}
@Override
public String getUserUrl(String code) {
return "http://meteo.navarra.es/estaciones/estacion.cfm?IDEstacion="+code.substring(2);
}
@Override
public List<Station> downloadStations() {
List<Station> stations = new ArrayList<>();
Downloader dw = new Downloader();
dw.setUrl("http://meteo.navarra.es/estaciones/mapadeestaciones.cfm");
String data = dw.download("relieve");
Matcher matcher = LAYER_PATTERN.matcher(data);
while( matcher.find() ) {
if( matcher.group(3).contains("MAN") )
continue;
if( !matcher.group(5).endsWith("GN") )
continue;
Station station = new Station();
station.setName(matcher.group(5).replaceAll(" GN", ""));
station.setCode("GN"+matcher.group(1));
station.setCountry("ES");
station.setRegion(182);
station.setProviderType(WindProviderType.MeteoNavarra);
if( !downloadCoords(station) )
return null;
Utils.utm2ll(station);
stations.add(station);
}
return stations;
}
private boolean downloadCoords(Station station) {
Downloader dw = new Downloader();
dw.setUrl("http://meteo.navarra.es/estaciones/estacion.cfm");
dw.addParam("IDEstacion", station.getCode().substring(2));
String[] lines = dw.download("fotos").split("\n");
int fields = 2;
for( String line : lines ) {
if( line.contains("X:") ) {
station.setLongitude(Integer.parseInt(line.split("X:")[1]));
fields--;
} else if (line.contains("Y:") ) {
StringBuilder sb = new StringBuilder();
String str = line.split("Y:")[1];
for( int i = 0; i < str.length() && Character.isDigit(str.charAt(i)); i++ )
sb.append(str.charAt(i));
station.setLatitude(Integer.parseInt(sb.toString()));
fields--;
}
if( fields <= 0 )
break;
}
return fields == 0;
}
private long toEpoch( String str ) {
try {
return df.parse(str).getTime();
} catch (ParseException e) {
e.printStackTrace();
return 0;
}
}
private String getContent( String cell ) {
return cell.replaceAll("\"","").replace('.',this.separator);
}
private static final Pattern END_PATTERN = Pattern.compile("[a-zA-Z]");
private static final Pattern LAYER_PATTERN = Pattern.compile("doLayer1\\((.*),(.*),'(.*)','(.*)','(.*)',(.*),(.*), ?(.*), ?(.*)\\);");
private final char separator = '.';
private Downloader downloader;
private final DateFormat df;
}
| [
"gorka.prieto@gmail.com"
] | gorka.prieto@gmail.com |
66a3ee86536f96e134825ce491f728073155a112 | 1a870eff07c27476074f979d8e5abddde2646840 | /com/sun/corba/se/PortableActivationIDL/LocatorHelper.java | 361ad5db08cfae536400c68e8847d7e4f1c9652b | [
"Apache-2.0"
] | permissive | zhenjunMa/JDK8Translation | ef6684e2292a6646129ba4206af136ffd292d0b0 | 0f9269a359b7ef2a778d89fb4e82ac4e47ea26e9 | refs/heads/master | 2021-06-07T18:59:11.037612 | 2020-09-18T02:49:43 | 2020-09-18T02:49:43 | 97,243,202 | 13 | 5 | null | 2020-09-18T02:49:44 | 2017-07-14T14:36:54 | Java | UTF-8 | Java | false | false | 2,966 | java | package com.sun.corba.se.PortableActivationIDL;
/**
* com/sun/corba/se/PortableActivationIDL/LocatorHelper.java .
* Generated by the IDL-to-Java compiler (portable), version "3.2"
* from /Users/java_re/workspace/8-2-build-macosx-x86_64/jdk8u111/7883/corba/src/share/classes/com/sun/corba/se/PortableActivationIDL/activation.idl
* Thursday, September 22, 2016 3:33:14 PM PDT
*/
abstract public class LocatorHelper
{
private static String _id = "IDL:PortableActivationIDL/Locator:1.0";
public static void insert (org.omg.CORBA.Any a, com.sun.corba.se.PortableActivationIDL.Locator that)
{
org.omg.CORBA.portable.OutputStream out = a.create_output_stream ();
a.type (type ());
write (out, that);
a.read_value (out.create_input_stream (), type ());
}
public static com.sun.corba.se.PortableActivationIDL.Locator extract (org.omg.CORBA.Any a)
{
return read (a.create_input_stream ());
}
private static org.omg.CORBA.TypeCode __typeCode = null;
synchronized public static org.omg.CORBA.TypeCode type ()
{
if (__typeCode == null)
{
__typeCode = org.omg.CORBA.ORB.init ().create_interface_tc (com.sun.corba.se.PortableActivationIDL.LocatorHelper.id (), "Locator");
}
return __typeCode;
}
public static String id ()
{
return _id;
}
public static com.sun.corba.se.PortableActivationIDL.Locator read (org.omg.CORBA.portable.InputStream istream)
{
return narrow (istream.read_Object (_LocatorStub.class));
}
public static void write (org.omg.CORBA.portable.OutputStream ostream, com.sun.corba.se.PortableActivationIDL.Locator value)
{
ostream.write_Object ((org.omg.CORBA.Object) value);
}
public static com.sun.corba.se.PortableActivationIDL.Locator narrow (org.omg.CORBA.Object obj)
{
if (obj == null)
return null;
else if (obj instanceof com.sun.corba.se.PortableActivationIDL.Locator)
return (com.sun.corba.se.PortableActivationIDL.Locator)obj;
else if (!obj._is_a (id ()))
throw new org.omg.CORBA.BAD_PARAM ();
else
{
org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl)obj)._get_delegate ();
com.sun.corba.se.PortableActivationIDL._LocatorStub stub = new com.sun.corba.se.PortableActivationIDL._LocatorStub ();
stub._set_delegate(delegate);
return stub;
}
}
public static com.sun.corba.se.PortableActivationIDL.Locator unchecked_narrow (org.omg.CORBA.Object obj)
{
if (obj == null)
return null;
else if (obj instanceof com.sun.corba.se.PortableActivationIDL.Locator)
return (com.sun.corba.se.PortableActivationIDL.Locator)obj;
else
{
org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl)obj)._get_delegate ();
com.sun.corba.se.PortableActivationIDL._LocatorStub stub = new com.sun.corba.se.PortableActivationIDL._LocatorStub ();
stub._set_delegate(delegate);
return stub;
}
}
}
| [
"mzj911101@yahoo.com"
] | mzj911101@yahoo.com |
7e599f62cc01d312aa15aa112d9a042ff2f2f91a | 446a56b68c88df8057e85f424dbac90896f05602 | /support/cas-server-support-token-tickets/src/main/java/org/apereo/cas/token/authentication/principal/TokenWebApplicationService.java | 3119369e8ad9779ce6e4d47a9833b659937c1ada | [
"Apache-2.0",
"LicenseRef-scancode-free-unknown",
"LicenseRef-scancode-warranty-disclaimer"
] | permissive | apereo/cas | c29deb0224c52997cbfcae0073a4eb65ebf41205 | 5dc06b010aa7fd1b854aa1ae683d1ab284c09367 | refs/heads/master | 2023-09-01T06:46:11.062065 | 2023-09-01T01:17:22 | 2023-09-01T01:17:22 | 2,352,744 | 9,879 | 3,935 | Apache-2.0 | 2023-09-14T14:06:17 | 2011-09-09T01:36:42 | Java | UTF-8 | Java | false | false | 757 | java | package org.apereo.cas.token.authentication.principal;
import org.apereo.cas.authentication.principal.AbstractWebApplicationService;
import lombok.NoArgsConstructor;
import jakarta.persistence.DiscriminatorValue;
import jakarta.persistence.Entity;
import java.io.Serial;
/**
* This is {@link TokenWebApplicationService}.
*
* @author Misagh Moayyed
* @since 5.2.0
*/
@Entity
@DiscriminatorValue("token")
@NoArgsConstructor
public class TokenWebApplicationService extends AbstractWebApplicationService {
@Serial
private static final long serialVersionUID = -8844121291312069964L;
public TokenWebApplicationService(final String id, final String originalUrl, final String artifactId) {
super(id, originalUrl, artifactId);
}
}
| [
"mm1844@gmail.com"
] | mm1844@gmail.com |
e1c23adb1925a3b877dca692ea74a8a1063b9174 | eb71e782cebec26969623bb5c3638d6f62516290 | /src/com/rs/game/player/dialogues/Thessalia.java | ee5c0feed61b63d83496f9979720f7813923fb13 | [] | no_license | DukeCharles/revision-718-server | 0fe7230a4c7da8de6f7de289ef1b4baec81fbd8b | cc69a0ab6e139d5cc7e2db9a73ec1eeaf76fd6e3 | refs/heads/main | 2023-06-25T05:50:04.376413 | 2021-07-25T19:38:35 | 2021-07-25T19:38:35 | 387,924,360 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 3,011 | java | package com.rs.game.player.dialogues;
import com.rs.game.player.content.PlayerLook;
import com.rs.utils.ShopsHandler;
public class Thessalia extends Dialogue {
int npcId;
@Override
public void start() {
npcId = (Integer) parameters[0];
sendNPCDialogue(npcId, 9827, "Would you like to buy any fine clothes?");
}
@Override
public void run(int interfaceId, int componentId) {
switch (stage) {
case -1:
stage = 0;
sendOptionsDialogue(SEND_DEFAULT_OPTIONS_TITLE, "What do you have?", "No, thank you.");
break;
case 0:
if (componentId == OPTION_2) {
stage = 1;
sendPlayerDialogue(9827, "No, thank you.");
} else {
stage = 2;
sendPlayerDialogue(9827, "What do you have?");
}
break;
case 1:
stage = -2;
sendNPCDialogue(npcId, 9827, "Well, please return if you change your mind.");
break;
case 2:
stage = 3;
sendNPCDialogue(npcId, 9827,
"Well, I have a number of fine pieces of clothing on sale or, if you prefer, I can offer you an exclusive, total clothing makeover?");
break;
case 3:
stage = 4;
sendOptionsDialogue(SEND_DEFAULT_OPTIONS_TITLE, "Tell me more about this makeover.",
"I'd just like to buy some clothes.");
break;
case 4:
if (componentId == OPTION_2) {
ShopsHandler.openShop(player, 18);
end();
} else {
stage = 5;
sendPlayerDialogue(9827, "Tell me more about this makeover.");
}
break;
case 5:
stage = 6;
sendNPCDialogue(npcId, 9827, "Certainly!");
break;
case 6:
stage = 7;
sendNPCDialogue(npcId, 9827,
"Here at Thessalia's Fine Clothing Boutique we offer a unique service, where we totally revamp your outfit to your choosing. Tired of always wearing the same outfit, day-in, day-out? Then this is the service for you!");
break;
case 7:
stage = 8;
sendNPCDialogue(npcId, 9827, "So, what do you say? Interested?");
break;
case 8:
stage = 9;
sendOptionsDialogue(SEND_DEFAULT_OPTIONS_TITLE, "I'd like to change my outfit, please.",
"I'd just like to buy some cloths.", "No, thank you.");
break;
case 9:
if (componentId == OPTION_3) {
stage = 1;
sendPlayerDialogue(9827, "No, thank you.");
} else if (componentId == OPTION_2) {
ShopsHandler.openShop(player, 18);
end();
} else {
stage = 10;
sendPlayerDialogue(9827, "I'd like to change my outfit, please");
}
break;
case 10:
if (player.getEquipment().wearingArmour()) {
stage = -2;
sendNPCDialogue(npcId, 9827,
"You can't try them on while wearing armour. Take it off and then speak to me again.");
} else {
stage = 11;
sendNPCDialogue(npcId, 9827,
"Wonderful. Feel free to try on some items and see if there's anything you would like.");
}
break;
case 11:
stage = 12;
sendPlayerDialogue(9827, "Okay, thanks.");
break;
case 12:
PlayerLook.openThessaliasMakeOver(player);
end();
break;
default:
end();
break;
}
}
@Override
public void finish() {
}
}
| [
"charles.simon.morin@gmail.com"
] | charles.simon.morin@gmail.com |
3dbbf12eb0a46bd79aaa79de59b858780647e229 | 0ecc3f1b9199f398368b1126966c8f3a04351b0c | /clients-business-capability-starter/src/main/java/com/lulobank/clients/starter/v3/mapper/ApprovedOfferMapper.java | b5fe58eede28889afe42911475ef663123cd9500 | [] | no_license | zhenyuncai/client | 30c990af3fe97f8e63d7440f53a73819fcef572b | a352c3cc1d563e5ffa9886988bf831630a915d65 | refs/heads/main | 2023-06-04T12:59:02.973045 | 2021-06-29T23:16:07 | 2021-06-29T23:16:07 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 538 | java | package com.lulobank.clients.starter.v3.mapper;
import com.lulobank.clients.services.domain.productoffers.ProductOffer;
import com.lulobank.clients.starter.v3.adapters.in.dto.ApprovedOffer;
import org.mapstruct.Mapper;
import org.mapstruct.ReportingPolicy;
import org.mapstruct.factory.Mappers;
@Mapper(unmappedTargetPolicy = ReportingPolicy.IGNORE)
public interface ApprovedOfferMapper {
ApprovedOfferMapper INSTANCE = Mappers.getMapper(ApprovedOfferMapper.class);
ApprovedOffer toApprovedOffer(ProductOffer productOffer);
}
| [
"juan.toledo@globant.com"
] | juan.toledo@globant.com |
b23bd5fb0939bd7aaa72ee5f7270949a06e7693d | 3c93431c01c50af1a866bdfed31abcdc6fefae0a | /webStudy04_Mybatis/src/main/java/kr/or/ddit/filter/auth/AuthenticationFilter.java | 8cb10647b321585b9740130d97cee8b7af830436 | [] | no_license | kimgwanhee/sturdy-potato | e6a256ad2d47c6c7ccfc0271fa17eb6b03d8635c | bc7e5070d27aa9ee2d42899efd6f0e973f2ca6ad | refs/heads/master | 2020-04-06T13:57:38.571565 | 2018-12-12T11:28:41 | 2018-12-12T11:28:41 | 157,521,656 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 3,753 | java | package kr.or.ddit.filter.auth;
import java.io.IOException;
import java.lang.reflect.Array;
import java.util.Arrays;
import java.util.Enumeration;
import java.util.LinkedHashMap;
import java.util.Map;
import java.util.ResourceBundle;
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.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;
/**
*
* @author KGH
* @since 2018. 12. 4.
* @version 1.0
* @see javax.servlet.http.HttpServlet
* <pre>
* [[개정이력(Modification Information)]]
* 수정일 수정자 수정내용
* -------- -------- ----------------------
* 2018. 12. 4. KGH 보호가 필요한 자원에 대해 접근을 시도하는 유저가 인증이 되어있는지 여부를 확인.
* Copyright (c) 2018 by DDIT All right reserved
* </pre>
*/
public class AuthenticationFilter implements Filter {
private Map<String, String[]> securedResources; //모든 자원정보와, 권한정보가 여러개인것도 있었으므롱
//한번읽어서 한번 로딩했다면 그대로 유지 init- 여러번 할 필요 x(계속 호출 x)
private String securedResourceInfo;
public static final String SECUREDRESOURCEATTR = "securedResources";
@Override
public void init(FilterConfig filterConfig) throws ServletException {
securedResources = new LinkedHashMap<>();
filterConfig.getServletContext().setAttribute(SECUREDRESOURCEATTR, securedResources);//어느영역에서 가져와서 싱글톤으로 들어감
securedResourceInfo = filterConfig.getInitParameter("securedResourcesInfo");
ResourceBundle bundle = ResourceBundle.getBundle(securedResourceInfo);
//위 baseName은 클래스패스, 확장자를 제외한 나머지 경로 들어가야함 , 로케일에 대한정보는 포함x
Enumeration<String> keys = bundle.getKeys();//이게 이제 맵의 키로 사용되야함
while(keys.hasMoreElements()) {//키가 다음에 있을때까지..
String uri = keys.nextElement();
String valueString =bundle.getString(uri);
String[] auth = valueString.split(",");
Arrays.sort(auth);//검색할때 쉬우도록 자동 정렬되도록
//이제 맵에넣기
securedResources.put(uri.trim(), auth);
}
}
@Override
public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain)
throws IOException, ServletException {
HttpServletRequest req = (HttpServletRequest)request;
// 2. 요청 분석(주소, 파라미터, 메소드, 헤더...)-주소 분석하기 위해서 주소 꺼내는데 req안에있다.
String uri = req.getRequestURI();
int cpLength = req.getContextPath().length();
uri = uri.substring(cpLength).split(";")[0];
boolean pass = true;
//맵을 하나 만들어서 관리하자 ~
if(securedResources.containsKey(uri)) {//vo가 필요한 자원에접근 -> 로그인여부 확인
HttpSession session = req.getSession();
if(session.getAttribute("authMember")==null) {//vo가 필요한데 로그인은 x -> 문제
pass = false;
}
}
if(pass) {
chain.doFilter(request, response);
}else {//다시 로그인페이지로 이동
String goPage = "/login/loginForm.jsp";
// response //지금 할아버지로 되어있음위에
HttpServletResponse resp = (HttpServletResponse)response;
resp.sendRedirect(req.getContextPath()+goPage);
}
}
@Override
public void destroy() {
// TODO Auto-generated method stub
}
}
| [
"rhksgml1458@gmail.com"
] | rhksgml1458@gmail.com |
fe69880077761f87a72bab11cfa3ae13ef4f11f9 | 933da9e44be32496f14d8fb806ca703e57fb2e1c | /Tugas/ExamBootcamp/QuizKhairil/QuizKhairil2.java | 200ceab2f3acd5ca0e208cf8ead77b47eb6e96ee | [] | no_license | Padepokan79/BootCampG7 | de16a04512e5ee906b137bc4c358d257aee9bd64 | 4143c068b8a393b680bdc0394b9db6d73361de0e | refs/heads/master | 2020-03-14T09:21:16.175053 | 2018-06-29T10:18:49 | 2018-06-29T10:18:49 | 131,543,216 | 0 | 0 | null | 2018-06-29T10:18:50 | 2018-04-30T01:07:31 | Java | UTF-8 | Java | false | false | 1,917 | java | /*
Program : Quiz
Creator : Khairil
Created At : 29 Mei 2018 10:34 AM
Updated By :
Update Date :
*/
import java.util.Scanner;
class QuizKhairil2 {
public static void main(String[] args) {
Scanner inputE = new Scanner(System.in);
Boolean split = false;
String inputBaris;
int vertikal, horizontal, baris, kolom, minInputan, maxInputan; //baris x kolom y && vert baris horz kolom
minInputan = 2;
maxInputan = 20;
baris = 0;
while(split == false) {
System.out.print("Jumlah baris untuk segitiga pascal yang akan ditampilkan : ");
inputBaris = inputE.next();
vertikal = 0;
horizontal = 0;
if(inputBaris.matches("[0-9-]+")) {
baris = Integer.parseInt(inputBaris);
if(baris < minInputan) {
System.out.println("Maaf, jumlah baris tidak boleh kurang dari 2.");
System.out.println("Silahkan input kembali.");
split = false;
}
else if(baris > maxInputan) {
System.out.println("Maaf, jumlah baris tidak boleh lebih dari 20.");
System.out.println("Silahkan input kembali.");
split = false;
}
else {
split = true;
}
}
else {
System.out.println("Maaf, input yang diterima hanya berupa angka.");
System.out.println("Silahkan input kembali.");
split = false;
}
}
vertikal = horizontal = 0;
kolom = baris;
int [][] dongle = new int [baris][kolom];
for(vertikal=0; vertikal<baris; vertikal++) {
for(horizontal=0; horizontal<kolom; horizontal++) {
if(( vertikal+horizontal ) >= (baris - 1)) {
if( (vertikal+horizontal == (baris-1)) || (horizontal == (baris - 1))) {
dongle[vertikal][horizontal] = 1;
}
else {
dongle[vertikal][horizontal] = ((dongle[vertikal-1][horizontal]) + dongle[vertikal-1][horizontal+1]);
}
System.out.print(dongle[vertikal][horizontal]+ " ");
}
}
System.out.println();
}
}
} | [
"khairil.anwar852@gmail.com"
] | khairil.anwar852@gmail.com |
bda70ebf79f4661e6e4cb7a8782c4aa0a38fee17 | 52df76c40de033ad01743a1d531d19341ead2ede | /java-orientacao-a-objetos/src/SequenciaEscape.java | a280acd8b6196ebda9727e21314bfb49681795cd | [] | no_license | Rafael1989/Java-o-o | 1a7b09d8c407ab9abaa576070d55eedc50d7cb58 | 390fe00085fadc6e1389d3622bd6d7e456235c40 | refs/heads/master | 2020-03-23T03:44:21.841215 | 2018-07-15T17:49:08 | 2018-07-15T17:49:08 | 141,046,254 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 158 | java |
public class SequenciaEscape {
public static void main(String []args) {
System.out.println("A \"Maria\" roubou pão \n \\na casa do \"João\".");
}
}
| [
"flns_rafa@hotmail.com"
] | flns_rafa@hotmail.com |
587d65137102b4d7287a573ac76d3d66079c939e | 959f0c4849b34611d53b235b08ca84b4aac2a46a | /src/main/java/org/ago/goan/anno/impl/DetectResult.java | 2bd49084176e6c2003423d6f37de494d4a95e6f2 | [
"Apache-2.0"
] | permissive | 0x00b/golandanno | b2f2b02986dd9f893d7848675664d8fb3f79771d | f34a6dabf30e09ed1932c37f2d451c37b51243de | refs/heads/main | 2023-07-27T15:08:14.119233 | 2021-09-08T02:53:44 | 2021-09-08T02:53:44 | 382,983,680 | 5 | 0 | null | null | null | null | UTF-8 | Java | false | false | 219 | java | package org.ago.goan.anno.impl;
public class DetectResult {
//是否命中类型
public String code;
//code的起始行
public int startLine;
public Object result;
public String linePrefix;
} | [
"genejli@MacBook-Pro.local"
] | genejli@MacBook-Pro.local |
1ff50de2c5b1d57cccae09f12ea0bb56b6f62341 | ea19b55f17724ad54e0cc3e2b1876802bdd3b5cb | /HW2_Extend/src/Kid.java | 5831aedfc7d630a10887dd849bf7730a14aa38bc | [] | no_license | TramanhV-Le/CS372-HW2 | 30e1ca644b6e98bbb8dc74243755978cda7fbbd0 | 873ea8dce7e172c3415eaf7015279d5c7d628de9 | refs/heads/master | 2021-01-12T03:39:28.117293 | 2017-01-12T00:02:18 | 2017-01-12T00:03:02 | 78,247,705 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 384 | java | /**
* DESCRIPTION: Allows input from PersonClass and allows favorite candy to be implemented
* @author tle19
*
*/
public class Kid extends PersonClass {
String faveCandy;
public Kid(String newName, int newAge, int newPhone, String newFaveCandy) {
// TODO Auto-generated method stub
name = newName;
age = newAge;
phoneNum = newPhone;
faveCandy = newFaveCandy;
}
}
| [
"tle19@my.whitworth.edu"
] | tle19@my.whitworth.edu |
fd6653495c50ef7dd9742d0efc992a86cef25c8e | 4270d1b325838019c338fb774c21503114e0e674 | /Authentification/src/main/java/com/fr/adaming/repository/IUserRepository.java | 475e71b873eb7da27e138173823017401818a912 | [] | no_license | Maxremb/Authentification | b435b097d7cd49891c98bf39b47c15b979d8bfbe | 0794de7ad42b121d181445ea3b91d9b48bf46f0c | refs/heads/master | 2022-04-08T16:39:32.036637 | 2020-03-10T16:17:08 | 2020-03-10T16:17:08 | 246,302,640 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 331 | java | package com.fr.adaming.repository;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;
import com.fr.adaming.entity.User;
@Repository
public interface IUserRepository extends JpaRepository<User, Integer>{
public User findByEmailAndPwd(String email, String pwd);
}
| [
"maxime.rembert@gmail.com"
] | maxime.rembert@gmail.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.