blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 7 410 | content_id stringlengths 40 40 | detected_licenses listlengths 0 51 | license_type stringclasses 2
values | repo_name stringlengths 5 132 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringlengths 4 80 | visit_date timestamp[us] | revision_date timestamp[us] | committer_date timestamp[us] | github_id int64 5.85k 684M ⌀ | star_events_count int64 0 209k | fork_events_count int64 0 110k | gha_license_id stringclasses 22
values | gha_event_created_at timestamp[us] | gha_created_at timestamp[us] | gha_language stringclasses 132
values | src_encoding stringclasses 34
values | language stringclasses 1
value | is_vendor bool 1
class | is_generated bool 2
classes | length_bytes int64 3 9.45M | extension stringclasses 28
values | content stringlengths 3 9.45M | authors listlengths 1 1 | author_id stringlengths 0 352 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
630430b367ddd46aa3f4dd94d8d853f2bdf8ebf2 | b841f45e43e7ee1a1ef1de3834672451a39949f0 | /Collections_java/src/Launch6.java | 5193c17c0534cfe6e81bd45730db879ed6c4f2a1 | [] | no_license | vinaynani9316/All_Java_programs | e7a4f6decf6f24618b987743fef55a366402ec0c | 00852b2e199662041e27f056d3b1d56a4c5b00cb | refs/heads/master | 2020-03-21T09:08:48.708126 | 2018-07-26T20:12:31 | 2018-07-26T20:12:31 | 138,384,409 | 0 | 0 | null | 2018-06-23T13:40:22 | 2018-06-23T08:24:14 | Java | UTF-8 | Java | false | false | 581 | java | import java.util.ArrayList;
public class Launch6
{
public static void main(String[] args)
{
ArrayList<Integer> l1=new ArrayList<Integer>();
l1.add(10);
l1.add(20);
l1.add(30);
l1.add(40);
l1.add(50);
l1.add(30);
l1.add(60);
l1.add(80);
System.out.println(l1);
l1.set(2, 100); // set() will remove the particular index element replace with new element.
System.out.println(l1);
l1.add(2, 1000); //add() push the indexed element & add to it.
System.out.println(l1);
}
}
| [
"vinod@DESKTOP-GC87GJT"
] | vinod@DESKTOP-GC87GJT |
d23ac6016186348dcccf5033e2abd68908a904a4 | 247e3e51cf0aeca7e6d23a19f863ba0a7f084072 | /src/methd_of_programing/array/Medium.java | e61ad18d0d8a439b479fb6e69b6972a905064cba | [] | no_license | KeXianting/algorithm_java | 48b56da200ce70ba06529ce07f0407a920d4021b | 47a1f7f28b4b9643cb1689164cdb2661759dd5aa | refs/heads/master | 2021-05-16T16:22:47.161128 | 2019-07-01T03:09:19 | 2019-07-01T03:09:19 | 119,938,587 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 8,536 | java | package methd_of_programing.array;
import data_struct.heap.Heap;
import sort.QuickSort;
import java.util.Arrays;
/**
* Created by kentorvalds on 2017/11/10.
* 给定3个数,请找出3个数的中位数
*
* 求两个无序数组的中位数
* 给定两个无序数组分别叫A和B,长度分别是m和n, 求这两个无序数组的中位数, 要求时间复杂度
* 为O(m+n), 空间复杂度为O(1)
*
*
*/
public class Medium {
public static void main(String[] args){
int[] a = {3, 10, 8};
System.out.println("三个数的中位数: " + getMediumOfThreeNumbers(a));
int arr1[] = { 2, 12,11, 5, 10, 43, 24, 33};//12
int arr2[] = { 10, 23, 41, 70, 84, 29, 6 };//29
double medium = getUnOderArraysMedium(arr1, arr2);
System.out.println("两个无序数组的中位数: " + medium);
//两个有序数组的中位数
System.out.println("两个有序数组的中位数: ");
int b1[] = {1,3,6,9};
int b2[] = {2, 4, 10, 12,13};
System.out.println("方法1: " + findMedianSortedArraysMethod1(b1, b2));
System.out.println("方法2: " + findMedianSortedArraysMethod2(b1, b2));
}
//给定3个数,请找出3个数的中位数
public static int getMediumOfThreeNumbers(int[] a){
if (a.length < 3){
return a[0];
}
QuickSort.sort(a, 0, a.length - 1);
return a[1];
}
//两个无序数组的中位数
//1.将前(n+1)/2个元素调整为一个小顶堆(或者大顶堆)
//2.对后续的每一个元素,和堆顶比较,如果小于等于堆顶,丢弃之,取下一个元素。 如果大于堆顶,用该元素取代堆顶,调整堆,取下一元素。重复此步骤
//3.当遍历完所有元素之后,堆顶即是中位数
public static double getUnOderArraysMedium(int[] a, int[] b){
//对a建立最大堆
int mediumA = getArrayMedium(a);
int mediumB = getArrayMedium(b);
return (mediumA + mediumB)/2;
}
private static int getArrayMedium(int[] a){
Heap heap = new Heap(Arrays.copyOf(a, a.length/2 + 1),a.length/2 + 1);
for (int i = a.length/2 + 1; i < a.length; i ++){
int temp = heap.extractMax();
if (a[i] < temp){
heap.insert(a[i]);
}else {
heap.insert(temp);
}
}
int medium = heap.extractMax();
System.out.println("aa " + medium);
return medium;
}
//两个有序数组的中位数
//方法1: 时间O(n) 空间O(1)
/*
如果数组a的中位数小于数组b的中位数,那么整体的中位数只可能出现在a的右区间加上b的左区间之中;
如果数组a的中位数大于等于数组b的中位数,那么整体的中位数只可能出现在a的左区间加上b的右区间之中
*/
//方法1: 如果对时间复杂度没有要求,这个方法是实现起来最简单的,我们只需要从下往上依次数(n+m)/2个元素即可。
// 由于两个数组都已经排序,我们可以使用两个指针指向数组“底部”,通过比较两个数组“底部”的元素大小来决定计哪一个元素
// ,同时将其所在数组的指针“向上”移一位。为了方便处理总元素为偶数的情况,这里将找中位数变成找第k小的元素
public static double findMedianSortedArraysMethod1(int[] nums1, int[] nums2) {
int len1 = nums1.length;
int len2 = nums2.length;
int total = len1 + len2;
if(total % 2==0){
//若总长度为偶数, 则中位数为中间两个数和的一半
return (findKth(nums1,nums2,total/2)+findKth(nums1,nums2,total/2+1))/2.0;
} else {
//若总长度为奇数, 则去中间的数
return findKth(nums1,nums2,total/2+1);
}
}
//返回数组nums1和nums2中第k大的数
//{1,3,6,9};{2, 4, 10, 12,13}
/*
计数的循环是用来找到第k-1个元素的,最后return的时候再判断第k个元素是哪一个
在每次计数的循环中要先判断两个数组指针是否超界,在最后return之前也要判断一次
*/
private static int findKth(int[] nums1, int[] nums2, int k){
int p = 0, q = 0;//p为nums1的指针, q为nums2的指针
for(int i = 0; i < k - 1; i++){
//判断p是否越界
if(p>=nums1.length && q<nums2.length){
q++;
} else if(q>=nums2.length && p<nums1.length){//判断q是否越界
p++;
} else if(nums1[p]>nums2[q]){//如果nums1中的当前元素比nums2中的大, 则nums2后移一位
q++;
} else { //nums1[p]<=nums2[q], 否则nums1前移一位
p++;
}
}
//p,q以前的元素都比nums1[p],nums2[q]小
if(p>=nums1.length) {
return nums2[q];
} else if(q>=nums2.length) {
return nums1[p];
} else {
return Math.min(nums1[p],nums2[q]);
}
}
//方法2: 分治法 Divide and Conquer,时间O(log(m+n)) 空间O(1)
/*
题目要求O(log(m+n))的时间复杂度,一般来说都是分治法或者二分搜索。首先我们先分析下题目,假设两个有序序列共有n个元素(根据中位数的定义我们要分两种情况考虑),当n为奇数时,搜寻第(n/2+1)个元素,当n为偶数时,搜寻第(n/2+1)和第(n/2)个元素,然后取他们的均值。进一步的,我们可以把这题抽象为“搜索两个有序序列的第k个元素”。如果我们解决了这个k元素问题,那中位数不过是k的取值不同罢了。
那如何搜索两个有序序列中第k个元素呢,这里又有个技巧。假设序列都是从小到大排列,对于第一个序列中前p个元素和第二个序列中前q个元素,我们想要的最终结果是:p+q等于k-1,且一序列第p个元素和二序列第q个元素都小于总序列第k个元素。因为总序列中,必然有k-1个元素小于等于第k个元素。这样第p+1个元素或者第q+1个元素就是我们要找的第k个元素。
所以,我们可以通过二分法将问题规模缩小,假设p=k/2-1,则q=k-p-1,且p+q=k-1。如果第一个序列第p个元素小于第二个序列第q个元素,我们不确定二序列第q个元素是大了还是小了,但一序列的前p个元素肯定都小于目标,所以我们将第一个序列前p个元素全部抛弃,形成一个较短的新序列。然后,用新序列替代原先的第一个序列,再找其中的第k-p个元素(因为我们已经排除了p个元素,k需要更新为k-p),依次递归。同理,如果第一个序列第p个元素大于第二个序列第q个元素,我们则抛弃第二个序列的前q个元素。递归的终止条件有如下几种:
较短序列所有元素都被抛弃,则返回较长序列的第k个元素(在数组中下标是k-1)
一序列第p个元素等于二序列第q个元素,此时总序列第p+q=k-1个元素的后一个元素,也就是总序列的第k个元素
每次递归不仅要更新数组起始位置(起始位置之前的元素被抛弃),也要更新k的大小(扣除被抛弃的元素)
*/
public static double findMedianSortedArraysMethod2(int[] nums1, int[] nums2) {
int m = nums1.length, n = nums2.length;
int k = (m + n) / 2;
if((m+n)%2==0){
return (findKth1(nums1,nums2,0,0,m,n,k)+findKth1(nums1,nums2,0,0,m,n,k+1))/2;
} else {
return findKth1(nums1,nums2,0,0,m,n,k+1);
}
}
private static double findKth1(int[] arr1, int[] arr2, int start1, int start2, int len1, int len2, int k){
// 保证arr1是较短的数组
if(len1>len2){
return findKth1(arr2,arr1,start2,start1,len2,len1,k);
}
if(len1==0){
return arr2[start2 + k - 1];
}
if(k==1){
return Math.min(arr1[start1],arr2[start2]);
}
int p1 = Math.min(k/2,len1) ;
int p2 = k - p1;
if(arr1[start1 + p1-1]<arr2[start2 + p2-1]){
return findKth1(arr1,arr2,start1 + p1,start2,len1-p1,len2,k-p1);
} else if(arr1[start1 + p1-1]>arr2[start2 + p2-1]){
return findKth1(arr1,arr2,start1,start2 + p2,len1,len2-p2,k-p2);
} else {
return arr1[start1 + p1-1];
}
}
}
| [
"xianting_ke@163.com"
] | xianting_ke@163.com |
3363dcd32e8d6e2cb6c68df1bf8b08b7fd5816db | b87aac9f210ef0c03f2f2468eaebc767e472378d | /app/src/main/java/com/example/abdilla/badrtest/helper/Status.java | 891f3c88ad2dc4880d4b7fa6f934f4ba239e79a3 | [] | no_license | julioabdilla/BadrTest | 0a2477b8db81612d98885b11baf144bd1eb24833 | e55300c165c478672f36a01ee6cae753db73ab8d | refs/heads/master | 2021-01-22T01:10:20.795872 | 2017-09-03T13:40:56 | 2017-09-03T13:40:56 | 102,199,099 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 462 | java | package com.example.abdilla.badrtest.helper;
import java.io.Serializable;
/**
* Created by abdilla on 6/5/16.
*/
public class Status implements Serializable {
private String status;
public boolean isSuccess() {
return status.equals("success");
}
public void setSuccess(String status) {
this.status = status;
}
public void setSuccess(boolean status) {
this.status = status ? "success" : "failed";
}
}
| [
"julio.abdilla@gmail.com"
] | julio.abdilla@gmail.com |
6ddeb0fa0d34f67cd65da43aa3d53cab28eed61b | dc34183416c18cec33aff4c29f5b71be7f0d8e39 | /src/main/java/com/ffderakhshan/movieDemo/MovieMapClass.java | a043136771c34be5715583e338ea5edffc177b94 | [] | no_license | ffderakhshan/CS-499-A3 | ede76495440c0c9eb4bb3121f93d3a47f33ba0a2 | a41390bd3eadacfe6c138a7010b0b18700f6a447 | refs/heads/master | 2021-01-18T22:45:21.523754 | 2017-03-09T20:14:12 | 2017-03-09T20:14:12 | 84,379,649 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,424 | java | package com.ffderakhshan.movieDemo;
import java.io.IOException;
import java.util.StringTokenizer;
import org.apache.hadoop.io.LongWritable;
import org.apache.hadoop.io.FloatWritable;
import org.apache.hadoop.io.IntWritable;
import org.apache.hadoop.io.Text;
import org.apache.hadoop.mapreduce.Mapper;
/**
* Map Class which extends MapReduce.Mapper class
* Map reads an input line at a time, and tokenizes based on comma delimiter.
* It maps tokens with:
* Key: movieID and Value: rating
* the latter to be consumed by the ReduceClass
*/
public class MovieMapClass extends Mapper<LongWritable, Text, IntWritable, FloatWritable>{
private IntWritable movieId = new IntWritable();
private FloatWritable rating = new FloatWritable();
/**
* map function of Mapper parent class takes a line of text at a time and
* splits to tokens and passes to the context as key: movieId, and value: rating.
* The input text is composed of [movieId, userId, rating]
*/
@Override
protected void map(LongWritable key, Text value, Context context)
throws IOException, InterruptedException {
String line = value.toString();
StringTokenizer st = new StringTokenizer(line,",");
while(st.hasMoreTokens()){
movieId.set(Integer.parseInt(st.nextToken()));
st.nextToken(); // skip userId
rating.set(Float.parseFloat(st.nextToken()));
context.write(movieId, rating);
}
}
}
| [
"fariba@b98-aruba1-guest-10-110-30-50.wlan.cpp.edu"
] | fariba@b98-aruba1-guest-10-110-30-50.wlan.cpp.edu |
d0153be09c1f6804e7f48417650bb036049a2016 | ef7c846fd866bbc748a2e8719358c55b73f6fc96 | /library/weiui/src/main/java/vip/kuaifan/weiui/extend/integration/glide/load/model/UnitModelLoader.java | 6e76b8574d2b8d47e89d9976ebc200ea5486161b | [
"MIT"
] | permissive | shaibaoj/weiui | 9e876fa3797537faecccca74a0c9206dba67e444 | 131a8e3a6ecad245f421f039d2bedc8a0362879d | refs/heads/master | 2020-03-17T22:45:52.855193 | 2018-07-02T01:56:51 | 2018-07-02T01:56:51 | 134,017,696 | 0 | 0 | null | 2018-07-02T01:56:52 | 2018-05-19T01:01:44 | Java | UTF-8 | Java | false | false | 3,521 | java | package vip.kuaifan.weiui.extend.integration.glide.load.model;
import android.support.annotation.NonNull;
import vip.kuaifan.weiui.extend.integration.glide.Priority;
import vip.kuaifan.weiui.extend.integration.glide.load.DataSource;
import vip.kuaifan.weiui.extend.integration.glide.load.Options;
import vip.kuaifan.weiui.extend.integration.glide.load.data.DataFetcher;
import vip.kuaifan.weiui.extend.integration.glide.signature.ObjectKey;
/**
* A put of helper classes that performs no loading and instead always returns the given model as
* the data to decode.
*
* @param <Model> The type of model that will also be returned as decodable data.
*/
public class UnitModelLoader<Model> implements ModelLoader<Model, Model> {
@SuppressWarnings("deprecation")
private static final UnitModelLoader<?> INSTANCE = new UnitModelLoader<>();
@SuppressWarnings("unchecked")
public static <T> UnitModelLoader<T> getInstance() {
return (UnitModelLoader<T>) INSTANCE;
}
/**
* @deprecated Use {@link #getInstance()} instead.
*/
// Need constructor to document deprecation, will be removed, when constructor is privatized.
@SuppressWarnings({"PMD.UnnecessaryConstructor", "DeprecatedIsStillUsed"})
@Deprecated
public UnitModelLoader() {
// Intentionally empty.
}
@Override
public LoadData<Model> buildLoadData(@NonNull Model model, int width, int height,
@NonNull Options options) {
return new LoadData<>(new ObjectKey(model), new UnitFetcher<>(model));
}
@Override
public boolean handles(@NonNull Model model) {
return true;
}
private static class UnitFetcher<Model> implements DataFetcher<Model> {
private final Model resource;
UnitFetcher(Model resource) {
this.resource = resource;
}
@Override
public void loadData(@NonNull Priority priority,
@NonNull DataCallback<? super Model> callback) {
callback.onDataReady(resource);
}
@Override
public void cleanup() {
// Do nothing.
}
@Override
public void cancel() {
// Do nothing.
}
@NonNull
@SuppressWarnings("unchecked")
@Override
public Class<Model> getDataClass() {
return (Class<Model>) resource.getClass();
}
@NonNull
@Override
public DataSource getDataSource() {
return DataSource.LOCAL;
}
}
/**
* Factory for producing {@link vip.kuaifan.weiui.extend.integration.glide.load.model.UnitModelLoader}s.
*
* @param <Model> The type of model that will also be returned as decodable data.
*/
// PMD.SingleMethodSingleton false positive: https://github.com/pmd/pmd/issues/816
@SuppressWarnings("PMD.SingleMethodSingleton")
public static class Factory<Model> implements ModelLoaderFactory<Model, Model> {
@SuppressWarnings("deprecation")
private static final Factory<?> FACTORY = new Factory<>();
@SuppressWarnings("unchecked")
public static <T> Factory<T> getInstance() {
return (Factory<T>) FACTORY;
}
/** @deprecated Use {@link #getInstance()} instead. */
// Need constructor to document deprecation, will be removed, when constructor is privatized.
@SuppressWarnings("PMD.UnnecessaryConstructor")
@Deprecated
public Factory() {
// Intentionally empty.
}
@NonNull
@Override
public ModelLoader<Model, Model> build(MultiModelLoaderFactory multiFactory) {
return UnitModelLoader.getInstance();
}
@Override
public void teardown() {
// Do nothing.
}
}
}
| [
"342210020@qq.com"
] | 342210020@qq.com |
ae295c386564681e747ec54bc371572597b25c30 | fa1408365e2e3f372aa61e7d1e5ea5afcd652199 | /src/testcases/CWE129_Improper_Validation_of_Array_Index/s05/CWE129_Improper_Validation_of_Array_Index__URLConnection_array_size_53b.java | 2afcbec2a6226ac11ae20b3aee4a2df3ceb82ee3 | [] | no_license | bqcuong/Juliet-Test-Case | 31e9c89c27bf54a07b7ba547eddd029287b2e191 | e770f1c3969be76fdba5d7760e036f9ba060957d | refs/heads/master | 2020-07-17T14:51:49.610703 | 2019-09-03T16:22:58 | 2019-09-03T16:22:58 | 206,039,578 | 1 | 2 | null | null | null | null | UTF-8 | Java | false | false | 1,697 | java | /* TEMPLATE GENERATED TESTCASE FILE
Filename: CWE129_Improper_Validation_of_Array_Index__URLConnection_array_size_53b.java
Label Definition File: CWE129_Improper_Validation_of_Array_Index.label.xml
Template File: sources-sinks-53b.tmpl.java
*/
/*
* @description
* CWE: 129 Improper Validation of Array Index
* BadSource: URLConnection Read data from a web server with URLConnection
* GoodSource: A hardcoded non-zero, non-min, non-max, even number
* Sinks: array_size
* GoodSink: data is used to set the size of the array and it must be greater than 0
* BadSink : data is used to set the size of the array, but it could be set to 0
* Flow Variant: 53 Data flow: data passed as an argument from one method through two others to a fourth; all four functions are in different classes in the same package
*
* */
package testcases.CWE129_Improper_Validation_of_Array_Index.s05;
import testcasesupport.*;
import javax.servlet.http.*;
public class CWE129_Improper_Validation_of_Array_Index__URLConnection_array_size_53b
{
public void badSink(int data ) throws Throwable
{
(new CWE129_Improper_Validation_of_Array_Index__URLConnection_array_size_53c()).badSink(data );
}
/* goodG2B() - use goodsource and badsink */
public void goodG2BSink(int data ) throws Throwable
{
(new CWE129_Improper_Validation_of_Array_Index__URLConnection_array_size_53c()).goodG2BSink(data );
}
/* goodB2G() - use badsource and goodsink */
public void goodB2GSink(int data ) throws Throwable
{
(new CWE129_Improper_Validation_of_Array_Index__URLConnection_array_size_53c()).goodB2GSink(data );
}
}
| [
"bqcuong2212@gmail.com"
] | bqcuong2212@gmail.com |
8c2c80f29e4f5f59686ffc447374dd4f127d4c09 | 8d051536cfebb3a4322d405d2c625e0e6824c57d | /app/src/main/java/com/smack/administrator/smackstudyapplication/emojicon/EaseEmojiconPagerView.java | df0ef969f5826f5808f01e8636809a0da3c0b8bb | [] | no_license | ruichaoqun/SmackStudyApplication | 7c1d96ffe6dfdf2fc891a96771e90c9c8d5af57b | 9f698d65eb4113cf02bb07e79b40e8a91571e0f5 | refs/heads/master | 2020-03-29T05:40:07.799631 | 2018-12-18T10:35:45 | 2018-12-18T10:35:45 | 149,592,707 | 1 | 0 | null | null | null | null | UTF-8 | Java | false | false | 10,220 | java | package com.smack.administrator.smackstudyapplication.emojicon;
import android.content.Context;
import android.support.v4.view.PagerAdapter;
import android.support.v4.view.ViewPager;
import android.util.AttributeSet;
import android.view.View;
import android.widget.AdapterView;
import android.widget.AdapterView.OnItemClickListener;
import android.widget.GridView;
import com.smack.administrator.smackstudyapplication.R;
import com.smack.administrator.smackstudyapplication.emojicon.EaseEmojicon.Type;
import java.util.ArrayList;
import java.util.List;
public class EaseEmojiconPagerView extends ViewPager {
private Context context;
private List<EaseEmojiconGroupEntity> groupEntities;
private PagerAdapter pagerAdapter;
private int emojiconRows = 3;
private int emojiconColumns = 7;
private int bigEmojiconRows = 2;
private int bigEmojiconColumns = 4;
private int firstGroupPageSize;
private int maxPageCount;
private int previousPagerPosition;
private EaseEmojiconPagerViewListener pagerViewListener;
private List<View> viewpages;
public EaseEmojiconPagerView(Context context, AttributeSet attrs) {
super(context, attrs);
this.context = context;
}
public EaseEmojiconPagerView(Context context) {
this(context, null);
}
public void init(List<EaseEmojiconGroupEntity> emojiconGroupList, int emijiconColumns, int bigEmojiconColumns){
if(emojiconGroupList == null){
throw new RuntimeException("emojiconGroupList is null");
}
this.groupEntities = emojiconGroupList;
this.emojiconColumns = emijiconColumns;
this.bigEmojiconColumns = bigEmojiconColumns;
viewpages = new ArrayList<View>();
for(int i = 0; i < groupEntities.size(); i++){
EaseEmojiconGroupEntity group = groupEntities.get(i);
List<EaseEmojicon> groupEmojicons = group.getEmojiconList();
List<View> gridViews = getGroupGridViews(group);
if(i == 0){
firstGroupPageSize = gridViews.size();
}
maxPageCount = Math.max(gridViews.size(), maxPageCount);
viewpages.addAll(gridViews);
}
pagerAdapter = new EmojiconPagerAdapter(viewpages);
setAdapter(pagerAdapter);
setOnPageChangeListener(new EmojiPagerChangeListener());
if(pagerViewListener != null){
pagerViewListener.onPagerViewInited(maxPageCount, firstGroupPageSize);
}
}
public void setPagerViewListener(EaseEmojiconPagerViewListener pagerViewListener){
this.pagerViewListener = pagerViewListener;
}
/**
* set emojicon group position
* @param position
*/
public void setGroupPostion(int position){
if (getAdapter() != null && position >= 0 && position < groupEntities.size()) {
int count = 0;
for (int i = 0; i < position; i++) {
count += getPageSize(groupEntities.get(i));
}
setCurrentItem(count);
}
}
/**
* get emojicon group gridview list
* @param groupEntity
* @return
*/
public List<View> getGroupGridViews(EaseEmojiconGroupEntity groupEntity){
List<EaseEmojicon> emojiconList = groupEntity.getEmojiconList();
int itemSize = emojiconColumns * emojiconRows -1;
int totalSize = emojiconList.size();
Type emojiType = groupEntity.getType();
if(emojiType == Type.BIG_EXPRESSION){
itemSize = bigEmojiconColumns * bigEmojiconRows;
}
int pageSize = totalSize % itemSize == 0 ? totalSize/itemSize : totalSize/itemSize + 1;
List<View> views = new ArrayList<View>();
for(int i = 0; i < pageSize; i++){
View view = View.inflate(context, R.layout.ease_expression_gridview, null);
GridView gv = (GridView) view.findViewById(R.id.gridview);
if(emojiType == Type.BIG_EXPRESSION){
gv.setNumColumns(bigEmojiconColumns);
}else{
gv.setNumColumns(emojiconColumns);
}
List<EaseEmojicon> list = new ArrayList<EaseEmojicon>();
if(i != pageSize -1){
list.addAll(emojiconList.subList(i * itemSize, (i+1) * itemSize));
}else{
list.addAll(emojiconList.subList(i * itemSize, totalSize));
}
if(emojiType != Type.BIG_EXPRESSION){
EaseEmojicon deleteIcon = new EaseEmojicon();
deleteIcon.setEmojiText(EaseSmileUtils.DELETE_KEY);
list.add(deleteIcon);
}
final EmojiconGridAdapter gridAdapter = new EmojiconGridAdapter(context, 1, list, emojiType);
gv.setAdapter(gridAdapter);
gv.setOnItemClickListener(new OnItemClickListener() {
@Override
public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
EaseEmojicon emojicon = gridAdapter.getItem(position);
if(pagerViewListener != null){
String emojiText = emojicon.getEmojiText();
if(emojiText != null && emojiText.equals(EaseSmileUtils.DELETE_KEY)){
pagerViewListener.onDeleteImageClicked();
}else{
pagerViewListener.onExpressionClicked(emojicon);
}
}
}
});
views.add(view);
}
return views;
}
/**
* add emojicon group
* @param groupEntity
*/
public void addEmojiconGroup(EaseEmojiconGroupEntity groupEntity, boolean notifyDataChange) {
int pageSize = getPageSize(groupEntity);
if(pageSize > maxPageCount){
maxPageCount = pageSize;
if(pagerViewListener != null && pagerAdapter != null){
pagerViewListener.onGroupMaxPageSizeChanged(maxPageCount);
}
}
viewpages.addAll(getGroupGridViews(groupEntity));
if(pagerAdapter != null && notifyDataChange){
pagerAdapter.notifyDataSetChanged();
}
}
/**
* remove emojicon group
* @param position
*/
public void removeEmojiconGroup(int position){
if(position > groupEntities.size() - 1){
return;
}
if(pagerAdapter != null){
pagerAdapter.notifyDataSetChanged();
}
}
/**
* get size of pages
* @return
*/
private int getPageSize(EaseEmojiconGroupEntity groupEntity) {
List<EaseEmojicon> emojiconList = groupEntity.getEmojiconList();
int itemSize = emojiconColumns * emojiconRows -1;
int totalSize = emojiconList.size();
Type emojiType = groupEntity.getType();
if(emojiType == Type.BIG_EXPRESSION){
itemSize = bigEmojiconColumns * bigEmojiconRows;
}
int pageSize = totalSize % itemSize == 0 ? totalSize/itemSize : totalSize/itemSize + 1;
return pageSize;
}
private class EmojiPagerChangeListener implements OnPageChangeListener {
@Override
public void onPageSelected(int position) {
int endSize = 0;
int groupPosition = 0;
for(EaseEmojiconGroupEntity groupEntity : groupEntities){
int groupPageSize = getPageSize(groupEntity);
//if the position is in current group
if(endSize + groupPageSize > position){
//this is means user swipe to here from previous page
if(previousPagerPosition - endSize < 0){
if(pagerViewListener != null){
pagerViewListener.onGroupPositionChanged(groupPosition, groupPageSize);
pagerViewListener.onGroupPagePostionChangedTo(0);
}
break;
}
//this is means user swipe to here from back page
if(previousPagerPosition - endSize >= groupPageSize){
if(pagerViewListener != null){
pagerViewListener.onGroupPositionChanged(groupPosition, groupPageSize);
pagerViewListener.onGroupPagePostionChangedTo(position - endSize);
}
break;
}
//page changed
if(pagerViewListener != null){
pagerViewListener.onGroupInnerPagePostionChanged(previousPagerPosition-endSize, position-endSize);
}
break;
}
groupPosition++;
endSize += groupPageSize;
}
previousPagerPosition = position;
}
@Override
public void onPageScrollStateChanged(int arg0) {
}
@Override
public void onPageScrolled(int arg0, float arg1, int arg2) {
}
}
public interface EaseEmojiconPagerViewListener{
/**
* pagerview initialized
* @param groupMaxPageSize --max pages size
* @param firstGroupPageSize-- size of first group pages
*/
void onPagerViewInited(int groupMaxPageSize, int firstGroupPageSize);
/**
* group position changed
* @param groupPosition--group position
* @param pagerSizeOfGroup--page size of group
*/
void onGroupPositionChanged(int groupPosition, int pagerSizeOfGroup);
/**
* page position changed
* @param oldPosition
* @param newPosition
*/
void onGroupInnerPagePostionChanged(int oldPosition, int newPosition);
/**
* group page position changed
* @param position
*/
void onGroupPagePostionChangedTo(int position);
/**
* max page size changed
* @param maxCount
*/
void onGroupMaxPageSizeChanged(int maxCount);
void onDeleteImageClicked();
void onExpressionClicked(EaseEmojicon emojicon);
}
}
| [
"ruichaoqun121@163.com"
] | ruichaoqun121@163.com |
02bdaa3765f63b7eb29600bc485d4d95dbdd8da2 | ff578101c84d64fcfb9bef1222e0bda327673d44 | /kodilla-testing2/src/test/java/com/kodilla/testing2/crudapp/CrudAppTestSuite.java | 6e5900398327d460f307f285a49bf18ee14ddae5 | [] | no_license | BeataBRB/beata-blizniewska-kodilla-java | 9ae939b102622e02c5c997fa87034a07ed97ef5c | bc4815f363877d628e8ea5b3789286c062064bba | refs/heads/master | 2020-05-31T08:33:14.040098 | 2020-02-16T09:27:13 | 2020-02-16T09:27:13 | 190,192,146 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 5,861 | java | package com.kodilla.testing2.crudapp;
import com.kodilla.testing2.config.WebDriverConfig;
import org.junit.*;
import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.support.ui.Select;
import java.util.Random;
import java.util.stream.Collectors;
public class CrudAppTestSuite {
public static final String BASE_URL = "https://beatabrb.github.io/";
private WebDriver driver;
private Random generator;
@Before
public void initTests() {
driver = WebDriverConfig.getDriver(WebDriverConfig.CHROME);
driver.get(BASE_URL);
generator = new Random();
}
@After
public void cleanUpAfterTest() {
driver.close();
}
public String createCrudAppTestTask() throws InterruptedException {
final String XPATH_TASK_NAME = "//form[contains(@action,\"createTask\")]/fieldset[1]/input";
final String XPATH_TASK_CONTENT = "//form[contains(@action,\"createTask\")]/fieldset[2]/textarea";
final String XPATH_ADD_BUTTON = "//form[contains(@action,\"createTask\")]/fieldset[3]/button";
String taskName = "Task number " + generator.nextInt(100000);
String taskContent = taskName + " content";
WebElement name = driver.findElement(By.xpath(XPATH_TASK_NAME));
name.sendKeys(taskName);
WebElement content = driver.findElement(By.xpath(XPATH_TASK_CONTENT));
content.sendKeys(taskContent);
WebElement addButton = driver.findElement(By.xpath(XPATH_ADD_BUTTON));
addButton.click();
Thread.sleep(2000);
return taskName;
}
private void sendTestTaskToTrello(String taskName) throws InterruptedException {
driver.navigate().refresh();
while (!driver.findElement(By.xpath("//select[1]")).isDisplayed()) ;
driver.findElements(By.xpath("//form[@class=\"datatable__row\"]")).stream()
.filter(anyForm ->
anyForm.findElement(By.xpath(".//p[@class=\"datatable__field-value\"]"))
.getText().equals(taskName))
.forEach(theForm -> {
WebElement selectElement = theForm.findElement(By.xpath(".//select[1]"));
Select select = new Select(selectElement);
select.selectByIndex(1);
WebElement buttonCreateCard =
theForm.findElement(By.xpath(".//button[contains(@class,\"card-creation\")]"));
buttonCreateCard.click();
});
Thread.sleep(5000);
}
private boolean checkTaskExistsInTrello(String taskName) throws InterruptedException {
final String TRELLO_URL="https://trello.com/login";
boolean result = false;
WebDriver driverTrello=WebDriverConfig.getDriver(WebDriverConfig.CHROME);
driverTrello.get(TRELLO_URL);
driverTrello.findElement(By.id("user")).sendKeys("beatabliniewska");
driverTrello.findElement(By.id("password")).sendKeys("Borynio12");
driverTrello.findElement(By.id("login")).submit();
Thread.sleep(2000);
driverTrello.findElements(By.xpath("//a[@class=\"board-tile\"]")).stream()
.filter(aHref->aHref.findElements(By.xpath(".//div[@title=\"Kodilla Application\"]")).size()>0)
.forEach(aHref->aHref.click());
Thread.sleep(2000);
result=driverTrello.findElements(By.xpath("//span")).stream()
.filter(theSpan->theSpan.getText().contains(taskName))
.collect(Collectors.toList())
.size()>0;
driverTrello.close();
return result;
}
private int checkTaskExistsInCrud(String taskName) throws InterruptedException {
Thread.sleep(2000);
driver.navigate().refresh();
Thread.sleep(2000);
int size=driver.findElements(By.xpath("//form[@class=\"datatable__row\"]")).stream()
.filter(anyForm ->
anyForm.findElement(By.xpath(".//p[@class=\"datatable__field-value\"]"))
.getText().equals(taskName))
.collect(Collectors.toList()).size();
System.out.println("Size="+size);
return size;
}
private void shouldDeleteTaskInCrudApp(String taskName) throws InterruptedException {
Thread.sleep(2000);
try {
driver.switchTo().alert().accept();
}catch (Exception e){
}
driver.navigate().refresh();
while (!driver.findElement(By.xpath("//select[1]")).isDisplayed()) ;
driver.findElements(By.xpath("//form[@class=\"datatable__row\"]")).stream()
.filter(anyForm ->
anyForm.findElement(By.xpath(".//p[@class=\"datatable__field-value\"]"))
.getText().equals(taskName))
.forEach(theForm -> {
WebElement selectElement = theForm.findElement(By.xpath(".//select[1]"));
Select select = new Select(selectElement);
select.selectByIndex(0);
WebElement buttonDeleteTask =
theForm.findElement(By.xpath(".//button[contains(.,\"Delete\")]"));
buttonDeleteTask.click();
});
}
@Test
public void shouldCreateTrelloCard() throws InterruptedException {
String taskName = createCrudAppTestTask();
sendTestTaskToTrello(taskName);
boolean isTaskExistsInTrello=checkTaskExistsInTrello(taskName);
shouldDeleteTaskInCrudApp(taskName);
boolean isTaskExistsInCrud=checkTaskExistsInCrud(taskName)>0;
Assert.assertTrue(isTaskExistsInTrello);
Assert.assertFalse(isTaskExistsInCrud);
}
}
| [
"bblizniewska.1988@gmail.com"
] | bblizniewska.1988@gmail.com |
5f830d1bcb5cf729826b1e5965a5e42a2b8d6a90 | 565a09cf432652421d0256c7bc264fc12bd25d2d | /src/main/java/org/macross/shopping_mall/model/entity/CommodityCategory.java | bdea14d73a5c29a3fc5cbbc280ccf5ae549bfa48 | [] | no_license | MacrossGithub-coder/ShoppingMall | c5554efddb83a46b4fa0a93557bb13d16290d565 | 822d56be98f3afb8343cbd12e462d55bbad70f6f | refs/heads/master | 2023-01-08T20:33:33.078541 | 2020-11-10T11:20:51 | 2020-11-10T11:20:51 | 284,045,737 | 2 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,475 | java | package org.macross.shopping_mall.model.entity;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.Date;
import java.util.List;
/**
* id int 类别id
* describe varchar 描述
* create_time datetime
*/
public class CommodityCategory {
private Integer id;
private String describe;
@JsonProperty("create_time")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
private Date createTime;
private List<Commodity> commodityList;
@Override
public String toString() {
return "CommodityCategory{" +
"id=" + id +
", describe='" + describe + '\'' +
", createTime=" + createTime +
", commodityList=" + commodityList +
'}';
}
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
public String getDescribe() {
return describe;
}
public void setDescribe(String describe) {
this.describe = describe;
}
public Date getCreateTime() {
return createTime;
}
public void setCreateTime(Date createTime) {
this.createTime = createTime;
}
public List<Commodity> getCommodityList() {
return commodityList;
}
public void setCommodityList(List<Commodity> commodityList) {
this.commodityList = commodityList;
}
}
| [
"66687575+MacrossGithub-coder@users.noreply.github.com"
] | 66687575+MacrossGithub-coder@users.noreply.github.com |
b7d364080216b4fe1f28456c6dd35b26acdd25ef | ba3fcb3e973b200c39f8b5f527855ff7d90549ad | /projeto-jpa/src/main/java/br/com/alura/jpa/testes/CriaConta.java | 12da857e1d832b7d3fd3a8770b20b269f76cfc98 | [] | no_license | torresmath/java-jdbc | caae4818609833854d706a478807a266a730476c | f70f9ece57892be64f094669f70101b11e87a3cb | refs/heads/main | 2023-04-24T23:37:54.321691 | 2021-05-16T17:43:43 | 2021-05-16T17:43:43 | 367,948,219 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 657 | java | package br.com.alura.jpa.testes;
import br.com.alura.jpa.modelo.Conta;
import javax.persistence.EntityManager;
import javax.persistence.EntityManagerFactory;
import javax.persistence.Persistence;
public class CriaConta {
public static void main(String[] args) {
EntityManagerFactory emf = Persistence.createEntityManagerFactory("contas");
EntityManager em = emf.createEntityManager();
Conta conta = new Conta();
conta.setTitular("Matheus");
conta.setNumero(1234);
conta.setAgencia(4321);
em.getTransaction().begin();
em.persist(conta);
em.getTransaction().commit();
}
}
| [
"torresmatheus_@hotmail.com"
] | torresmatheus_@hotmail.com |
1f896e316cd45c403591c9ba6e0c34d5273f3699 | 37e2f76cadcbf09314366a5bc7eff7b06e89c4b7 | /src/main/java/frc/robot/subsystems/DriveBaseHolder.java | f1459b16c42f039b6c95cbdc04dd03b35eb23741 | [] | permissive | FRC2706/2020-2706-Robot-Code | 802226e50f546390749d76742842080ab9ab4bd9 | e34dbcac4f7614aa381f3d46e5d7ccca9cd70a22 | refs/heads/master | 2022-11-25T10:04:44.251177 | 2020-11-05T01:03:42 | 2020-11-05T01:03:42 | 232,693,579 | 6 | 3 | BSD-3-Clause | 2020-11-05T01:03:43 | 2020-01-09T01:18:12 | Java | UTF-8 | Java | false | false | 658 | java | package frc.robot.subsystems;
import frc.robot.Robot;
import frc.robot.config.Config;
import java.lang.reflect.InvocationTargetException;
public class DriveBaseHolder {
private static DriveBase INSTANCE;
public static void init() {
try {
INSTANCE = Config.DRIVEBASE_CLASS.getDeclaredConstructor().newInstance();
} catch (NoSuchMethodException | IllegalAccessException | InstantiationException | InvocationTargetException e) {
Robot.haltRobot("Cannot instantiate instance of DriveBase", e);
}
}
public static DriveBase getInstance() {
return INSTANCE;
}
}
| [
"nrgill28@gmail.com"
] | nrgill28@gmail.com |
3641330a9dd21b261c7d50ef52775902e3059886 | 075e0ef731109ec156f9e62b2b393745cc2a385f | /src/main/java/com/zimmur/platform/manage/web/common/PropertiesCommon.java | f2a9b0cfe4e29923ee2e61ba57762acb73b9b143 | [] | no_license | huangsx0512/manage-web | 42009f9984ae8fc0a6b593da617c6f184dc4efa8 | ceb3ac7fc5c64820fa9bab1a7d4b4e3958954810 | refs/heads/master | 2020-04-13T10:42:48.486616 | 2019-04-09T13:50:06 | 2019-04-09T13:50:06 | 163,150,429 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 655 | java | package com.zimmur.platform.manage.web.common;
import java.io.IOException;
import java.util.Properties;
import org.springframework.core.io.ClassPathResource;
import org.springframework.core.io.Resource;
import org.springframework.core.io.support.PropertiesLoaderUtils;
public class PropertiesCommon {
private static Properties props;
static{
Resource resource = new ClassPathResource("/config/sysconfig.properties");
try {
props = PropertiesLoaderUtils.loadProperties(resource);
} catch (IOException e) {
e.printStackTrace();
}
}
public static String getProperty(String name){
return props==null?"":props.getProperty(name);
}
}
| [
"hsx902910@163.com"
] | hsx902910@163.com |
12834aaa006434a932ffac44703d4f264eacacf9 | acacfb5a0407ea1349a78bc71c70100e72a8103d | /src/main/java/tr/com/epias/web/test/gen/model/QueryContractStatusResponse.java | 29ecc1e99222f97a04cc243612ba9dd115946391 | [] | no_license | epiastr/gopjavaclient | 798af63e25580db30b9686a3772d6d1508c7d6ee | 98bc7f1a5f5ef7c9fa64f847f2d88cf823f173dd | refs/heads/master | 2021-01-01T03:43:14.611768 | 2016-05-12T13:05:47 | 2016-05-12T13:05:47 | 58,641,438 | 2 | 1 | null | null | null | null | UTF-8 | Java | false | false | 1,899 | java | package tr.com.epias.web.test.gen.model;
import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.util.ArrayList;
import java.util.List;
import tr.com.epias.web.test.gen.model.ContractStatus;
import com.google.gson.annotations.SerializedName;
/**
* This field keeps which statues a contact can be.
**/
@ApiModel(description = "This field keeps which statues a contact can be.")
public class QueryContractStatusResponse {
@SerializedName("statuses")
private List<ContractStatus> statuses = new ArrayList<ContractStatus>();
/**
* This field keeps the list of contact statues.
**/
@ApiModelProperty(value = "This field keeps the list of contact statues.")
public List<ContractStatus> getStatuses() {
return statuses;
}
public void setStatuses(List<ContractStatus> statuses) {
this.statuses = statuses;
}
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
QueryContractStatusResponse queryContractStatusResponse = (QueryContractStatusResponse) o;
return Objects.equals(this.statuses, queryContractStatusResponse.statuses);
}
@Override
public int hashCode() {
return Objects.hash(statuses);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class QueryContractStatusResponse {\n");
sb.append(" statuses: ").append(toIndentedString(statuses)).append("\n");
sb.append("}");
return sb.toString();
}
/**
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}
}
| [
"orhan.yilmaz@epias.intra"
] | orhan.yilmaz@epias.intra |
c2853546535e841de009f5cd3dbd7a383308d635 | 35948689cf2cfbc08b4aa762e1e2457b3e37720a | /proxy/web/src/main/java/ir/ac/iust/dml/kg/knowledge/proxy/web/services/v1/ForwardServiceImpl.java | d74c161740576b002e3f4c1d72133f3ec0715987 | [
"Apache-2.0"
] | permissive | IUST-DMLab/farsbase | b0b9b02ac271a05f7793fbe1eae4e6c6627300df | 2e020ae3d619a35ffa00079b9aeb31ca77ce2346 | refs/heads/master | 2020-03-24T22:18:46.314400 | 2018-08-01T11:56:23 | 2018-08-01T11:56:23 | 143,078,400 | 1 | 0 | null | null | null | null | UTF-8 | Java | false | false | 4,013 | java | package ir.ac.iust.dml.kg.knowledge.proxy.web.services.v1;
import ir.ac.iust.dml.kg.knowledge.proxy.access.dao.IForwardDao;
import ir.ac.iust.dml.kg.knowledge.proxy.access.dao.IPermissionDao;
import ir.ac.iust.dml.kg.knowledge.proxy.access.entities.Forward;
import ir.ac.iust.dml.kg.knowledge.proxy.access.entities.Permission;
import ir.ac.iust.dml.kg.knowledge.proxy.access.entities.UrnMatching;
import ir.ac.iust.dml.kg.knowledge.proxy.web.logic.ForwardLogic;
import ir.ac.iust.dml.kg.knowledge.proxy.web.services.v1.data.ForwardData;
import ir.ac.iust.dml.kg.knowledge.proxy.web.services.v1.data.PermissionData;
import org.bson.types.ObjectId;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.core.GrantedAuthority;
import org.springframework.security.core.context.SecurityContextHolder;
import javax.jws.WebService;
import javax.validation.Valid;
import java.util.ArrayList;
import java.util.Collection;
import java.util.List;
import java.util.Set;
/**
* Impl {@link IUserServices}
*/
@SuppressWarnings("SpringAutowiredFieldsWarningInspection")
@WebService(endpointInterface = "ir.ac.iust.dml.kg.knowledge.proxy.web.services.v1.IForwardService")
public class ForwardServiceImpl implements IForwardService {
@Autowired
private ForwardLogic forwardLogic;
@Autowired
private IForwardDao forwardDao;
@Autowired
private IPermissionDao permissionDao;
@Override
public List<String> login() {
final Collection<? extends GrantedAuthority> authorities = SecurityContextHolder.getContext().getAuthentication().getAuthorities();
final List<String> result = new ArrayList<>();
authorities.forEach(a -> result.add(a.getAuthority()));
return result;
}
@Override
public Permission permission(@Valid PermissionData data) {
final Permission permission = data.getIdentifier() == null ? new Permission() : permissionDao.read(new ObjectId(data.getIdentifier()));
if (permission == null) return null;
final Permission oldPermission = permissionDao.readByTitle(data.getTitle());
if (oldPermission != null && !oldPermission.getIdentifier().equals(permission.getIdentifier()))
throw new RuntimeException("Title can not be repeated");
data.fill(permission);
permissionDao.write(permission);
return permission;
}
@Override
public List<Permission> permissions() {
return permissionDao.readAll();
}
@Override
public List<Forward> forwards() {
return forwardDao.readAll();
}
@Override
public ForwardData edit(@Valid ForwardData data) {
final Forward forward = data.getIdentifier() == null ? new Forward() : forwardDao.read(new ObjectId(data.getIdentifier()));
if (forward == null)
throw new RuntimeException("Not found");
final Forward oldForward = forwardDao.readBySource(data.getSource());
if (oldForward != null && !oldForward.getIdentifier().equals(forward.getIdentifier()))
throw new RuntimeException("Title can not be repeated");
data.fill(forward);
forward.getPermissions().clear();
data.getPermissions().forEach(dp -> {
final Permission per = permissionDao.readByTitle(dp);
if (per != null)
forward.getPermissions().add(per);
});
assert data.getUrns().size() == forward.getUrns().size();
for (int i = 0; i < data.getUrns().size(); i++) {
final Set<String> permissions = data.getUrns().get(i).getPermissions();
final UrnMatching urnMatching = forward.getUrns().get(i);
permissions.forEach(dp -> {
final Permission per = permissionDao.readByTitle(dp);
if (per != null)
urnMatching.getPermissions().add(per);
});
}
forwardDao.write(forward);
forwardLogic.reload();
return data.sync(forward);
}
}
| [
"majid.asgari@gmail.com"
] | majid.asgari@gmail.com |
4c65f4e24257a0a5d5098ec4e846884e66131a8b | 4cc7e63c8619085ed2d4915d769a13a454c1fd84 | /UdemyPracticas/src/Aritmetica/Aritmetica_V3.java | fff002a26eb788a0c6f6c9e79bd652a1c22986c4 | [] | no_license | GildoC/Test | 0b6b21fc4983a4c787ea0edf07abd3057c01c31c | c07d4964efc16e13ca33c4b6136471dedfc64a30 | refs/heads/master | 2021-01-22T05:11:09.226421 | 2019-12-19T02:23:40 | 2019-12-19T02:23:40 | 102,277,909 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 631 | 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 Aritmetica;
public class Aritmetica_V3 {
int a;
int b;
Aritmetica_V3(){
}
Aritmetica_V3(int a, int b){
this.a = a;
this.b = b;
}
int sumar(){
return a + b;
}
int restar(){
return a - b;
}
int multiplicar(){
return a * b;
}
int dividir(){
return a/b;
}
}
| [
"Gildo@Gildo-Asus"
] | Gildo@Gildo-Asus |
8e533ca85f6dffc12c8d3c72226f11a521f78b41 | 3e199d64551f1ce3fde392d657b753a09d26939d | /android/app/src/main/java/com/plappyhannerandroid/MainActivity.java | 3171e9a9d14084380b27976344a068c43866835f | [] | no_license | jnk2016/happy-planner-frontend | 79fff2d7bc9445fcda69df2ed70feaa9d02d86d7 | b6a700061f51a3a315da67bad821150d40af4d7f | refs/heads/master | 2023-04-19T14:02:52.793117 | 2021-02-08T10:34:25 | 2021-02-08T10:34:25 | 322,148,031 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 365 | java | package com.plappyhannerandroid;
import com.facebook.react.ReactActivity;
public class MainActivity extends ReactActivity {
/**
* Returns the name of the main component registered from JavaScript. This is used to schedule
* rendering of the component.
*/
@Override
protected String getMainComponentName() {
return "PlappyHannerAndroid";
}
}
| [
"jnk2016@gmail.com"
] | jnk2016@gmail.com |
a2185f96d0daebf36b1b57c150a64b915300ed5b | 0c207c2c8996f9e5fd79077484858b217a22ca36 | /day05_butterknife/src/main/java/com/nan/day05_butterknife/MainActivity2.java | fcd188fce0f914b23b66be4afbef9bc60386a19f | [] | no_license | huannan/Architecture | 13a75919eaa2a952125aa2c5868ee17ad111b9d5 | f41ac58b1533c75bd8945a30efd9ff23c243bfe1 | refs/heads/master | 2022-08-23T07:52:43.482888 | 2022-06-30T08:45:23 | 2022-06-30T08:45:23 | 292,816,424 | 11 | 3 | null | null | null | null | UTF-8 | Java | false | false | 829 | java | package com.nan.day05_butterknife;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.widget.TextView;
import com.nan.day05_butterknife_annotations.BindView;
import com.nan.day05_butterknife_core.ButterKnife;
import com.nan.day05_butterknife_core.Unbinder;
public class MainActivity2 extends AppCompatActivity {
@BindView(R.id.tv3)
TextView tv3;
@BindView(R.id.tv4)
TextView tv4;
private Unbinder mUnbinder;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main2);
mUnbinder = ButterKnife.bind(this);
tv3.setText("成功");
}
@Override
protected void onDestroy() {
mUnbinder.unbind();
super.onDestroy();
}
} | [
"wuhuannan@meizu.com"
] | wuhuannan@meizu.com |
41b075f6d5790beea8acf5a50f94d9a4a886d298 | c54bd79cfbd65b00a63ca9de7c9b9729e397c57e | /src/com/java/test/CalculatorNormal.java | 654ee066c2f22c375e6e546196032a29a01fef04 | [] | no_license | surajsontakke/practice | f7671b9832c712b42f46c8f1a6876ebf808d1ad8 | 3e55722ebc0316eeac95dac7c318bf448eee6188 | refs/heads/master | 2020-05-15T12:29:44.094162 | 2019-04-19T13:33:30 | 2019-04-19T13:33:30 | 182,266,200 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 460 | java | package com.java.test;
import java.util.Scanner;
public class CalculatorNormal {
public static void main(String[] args) {
// TODO Auto-generated method stub
Scanner scan = new Scanner(System.in);
double fnum, snum, avrange;
System.out.println("Enter first number : ");
fnum = scan.nextDouble();
System.out.println("Enter second number :");
snum = scan.nextDouble();
avrange = fnum + snum;
System.out.println("Avrage :" + avrange);
}
}
| [
"suraj.sontakke52@yahoo.in"
] | suraj.sontakke52@yahoo.in |
4043d7a2d19fd2d328eea437c5823060dead5416 | ec0ca7ddb7e1e4f943055343320ad31d59d8d3fc | /JAVA-SE/10.【接口、多态】/src/main/java/com/aurora/demo02/MyInterfaceA.java | d853cfb04b2a4534ba7fa2fd765b352e386b6336 | [] | no_license | liuxuan-scut/JavaSE | eab815b49880b193380782b120e975aabec4390c | aa8f78164e6d2884e4c2d87869374cf6f8438f3c | refs/heads/master | 2022-11-24T11:30:09.724248 | 2020-07-31T05:35:24 | 2020-07-31T05:35:24 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 407 | java | package com.aurora.demo02;
public interface MyInterfaceA {
// 错误写法!接口不能有静态代码块
// static {
//
// }
// 错误写法!接口不能有构造方法
// public MyInterfaceA() {
//
// }
public abstract void methodA();
public abstract void methodAbs();
public default void methodDefault() {
System.out.println("默认方法AAA");
}
}
| [
"wh14787946648@outlook.com"
] | wh14787946648@outlook.com |
a12a2023497e42a681a3b8b3d4fe35dba2a07ee1 | 790138a2258b5090f7afe8006b5eb92e650cdaa0 | /src/main/java/com/example/demo/DemoApplication.java | eb73b1fc804a0ba4351f3aa17367f46e618dbcf7 | [] | no_license | lijian19931216/lilijun | d0588c11c87ee43d6074301ed99a98065018c516 | 4e3055c54f6720ceebdfd6ddd9a59fdc55a182da | refs/heads/master | 2022-06-22T22:51:39.023596 | 2019-10-21T13:50:04 | 2019-10-21T13:50:04 | 204,953,275 | 0 | 0 | null | 2022-06-17T02:35:04 | 2019-08-28T14:36:32 | JavaScript | UTF-8 | Java | false | false | 663 | java | package com.example.demo;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
@SpringBootApplication
public class DemoApplication extends SpringBootServletInitializer {
public static void main(String[] args) {
SpringApplication.run(DemoApplication.class, args);
}
@Override
protected SpringApplicationBuilder configure(SpringApplicationBuilder builder) {
return builder.sources(DemoApplication.class);
}
}
| [
"928229131@qq.com"
] | 928229131@qq.com |
3709e6bab87361e8ff883bb9ae8b72b7322d4b77 | d6875a18ef080b900bc1f2cb5c28cabe15185864 | /src/main/java/com/sg/floormaster/dto/OrderSerializerForFileSave.java | caab1b54e53bc67f7aa17460d5cffd8ef5e2eae0 | [] | no_license | vannjo02/FloorMaster | e641897675eec510e6229746623f509217428256 | d45bf512b0b77342363f1b23a7945139bf8f7536 | refs/heads/master | 2020-04-10T06:00:42.925301 | 2018-12-07T15:49:01 | 2018-12-07T15:49:01 | 160,753,222 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,295 | java |
package com.sg.floormaster.dto;
import com.google.gson.JsonElement;
import com.google.gson.JsonObject;
import com.google.gson.JsonSerializationContext;
import com.google.gson.JsonSerializer;
import java.lang.reflect.Type;
/**
*
* @author Joshua Vannatter
*/
public class OrderSerializerForFileSave implements JsonSerializer<Order> {
@Override
public JsonElement serialize(Order order, Type type, JsonSerializationContext context) {
JsonObject jOb = new JsonObject();
jOb.addProperty("OrderID", order.getOrderId());
jOb.addProperty("date", order.getDate().toString());
jOb.addProperty("customerName", order.getCustomerName());
jOb.addProperty("state", order.getState());
jOb.addProperty("taxRate", order.getTaxRate());
jOb.addProperty("productType", order.getProductType());
jOb.addProperty("area", order.getArea());
jOb.addProperty("costPerSqFt", order.getMaterialCostPerSqFt());
jOb.addProperty("materialCost", order.getMaterialCost());
jOb.addProperty("laborCostPerSqFt", order.getLaborCostPerSqFt());
jOb.addProperty("laborCost", order.getLaborCost());
jOb.addProperty("tax", order.getTax());
jOb.addProperty("total", order.getTotal());
return jOb;
}
}
| [
"vannjo02@luther.edu"
] | vannjo02@luther.edu |
f71f52ee384108eb61ef037e9302516fb65434df | a8d9596e8943c782889734deab02a07c1f09b3d9 | /genie-common-internal/src/main/java/com/netflix/genie/common/internal/services/impl/JobDirectoryManifestServiceImpl.java | dfb6b10dcc96198880e41424d7c7b9377951e167 | [
"Apache-2.0"
] | permissive | cnxtech/genie | edf623ff431d89829d323054fce02251aa6d2817 | b01a44f522c0ef03428376d869262b4bafcf54cb | refs/heads/master | 2022-05-14T00:20:51.706497 | 2019-08-05T19:11:20 | 2019-08-06T20:40:18 | 201,105,300 | 0 | 0 | Apache-2.0 | 2022-05-01T08:15:50 | 2019-08-07T18:22:01 | Java | UTF-8 | Java | false | false | 2,923 | java | /*
*
* Copyright 2019 Netflix, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
package com.netflix.genie.common.internal.services.impl;
import com.github.benmanes.caffeine.cache.Cache;
import com.netflix.genie.common.internal.dto.DirectoryManifest;
import com.netflix.genie.common.internal.services.JobDirectoryManifestService;
import lombok.extern.slf4j.Slf4j;
import java.io.IOException;
import java.nio.file.Path;
/**
* Implementation of {@link JobDirectoryManifestService} that caches manifests produced by the factory for a few
* seconds, thus avoiding re-calculating the same for subsequent requests (e.g. a user navigating a tree true the UI).
*
* @author mprimi
* @since 4.0.0
*/
@Slf4j
public class JobDirectoryManifestServiceImpl implements JobDirectoryManifestService {
private final Cache<Path, DirectoryManifest> cache;
private final DirectoryManifest.Factory factory;
private final boolean includeChecksum;
/**
* Constructor.
*
* @param factory the directory manifest factory
* @param cache the loading cache to use
* @param includeChecksum whether to produce manifests that include checksums
*/
public JobDirectoryManifestServiceImpl(
final DirectoryManifest.Factory factory,
final Cache<Path, DirectoryManifest> cache,
final boolean includeChecksum
) {
this.factory = factory;
this.cache = cache;
this.includeChecksum = includeChecksum;
}
/**
* {@inheritDoc}
*/
@Override
public DirectoryManifest getDirectoryManifest(final Path jobDirectoryPath) throws IOException {
try {
return cache.get(
jobDirectoryPath.normalize().toAbsolutePath(),
path -> {
try {
return this.factory.getDirectoryManifest(path, this.includeChecksum);
} catch (IOException e) {
throw new RuntimeException("Failed to create manifest", e);
}
}
);
} catch (RuntimeException e) {
if (e.getCause() != null && e.getCause() instanceof IOException) {
// Unwrap and throw the original IOException
throw (IOException) e.getCause();
}
throw e;
}
}
}
| [
"mprimi@netflix.com"
] | mprimi@netflix.com |
1fbd6a4f9d679808c3f2a526b0a407ed0af6b3e5 | 3957e45e36f25535df2d06a9c69afd813d5a3199 | /src/main/java/com/github/com/jorgdz/app/service/IUsuarioService.java | 51dee227c9a3d66ed360e8f01dac5e163c7648ea | [] | no_license | jorgdz/biblioteca | 6ab58063c9c2b0eaaf6af7460d74ed0ec79a1a5a | 909fc3d2050230dd3f5ba86d5335045f038a1c74 | refs/heads/master | 2021-02-26T19:18:39.222300 | 2020-03-31T23:18:01 | 2020-03-31T23:18:01 | 245,548,120 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 558 | java | package com.github.com.jorgdz.app.service;
import java.util.Optional;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import com.github.com.jorgdz.app.entity.Usuario;
public interface IUsuarioService {
Usuario findById(Long id);
Page<Usuario> findAll(Optional<String> nombres, Optional<String> apellidos, Optional<String> correo, Optional<Boolean> enabled, Pageable pageable);
Usuario findByCorreo(String correo);
Usuario findByCorreo(String correo, Long id);
Usuario save(Usuario usuario);
}
| [
"jdzm@outlook.es"
] | jdzm@outlook.es |
cdd4421f9162109e25b572a83e66970949a01ea6 | 89853df9ca1bfff1b32132195b31e085a1d833a0 | /Proy_FormRightNow/src/com/rightnow/ws/nullfields/ContactSalesSettingsNullFieldsE.java | 3ca76b61820e4958cabcea9efb50f616e1a94502 | [] | no_license | WSebastian/Proy_RightNow_Soap | 88ca135b26e4812cb750adbbbc45baf37d6dc9b5 | 9bd68a4cfd622efd5e37ee5f2e3f64749f1c54db | refs/heads/master | 2021-03-12T23:29:46.950775 | 2015-10-28T20:46:18 | 2015-10-28T20:46:18 | 42,743,575 | 0 | 1 | null | null | null | null | UTF-8 | Java | false | false | 15,776 | java |
/**
* ContactSalesSettingsNullFieldsE.java
*
* This file was auto-generated from WSDL
* by the Apache Axis2 version: 1.5.1 Built on : Oct 19, 2009 (10:59:34 EDT)
*/
package com.rightnow.ws.nullfields;
/**
* ContactSalesSettingsNullFieldsE bean class
*/
public class ContactSalesSettingsNullFieldsE
implements org.apache.axis2.databinding.ADBBean{
public static final javax.xml.namespace.QName MY_QNAME = new javax.xml.namespace.QName(
"urn:nullfields.ws.rightnow.com/v1_2",
"ContactSalesSettingsNullFields",
"ns3");
private static java.lang.String generatePrefix(java.lang.String namespace) {
if(namespace.equals("urn:nullfields.ws.rightnow.com/v1_2")){
return "ns3";
}
return org.apache.axis2.databinding.utils.BeanUtil.getUniquePrefix();
}
/**
* field for ContactSalesSettingsNullFields
*/
protected com.rightnow.ws.nullfields.ContactSalesSettingsNullFields localContactSalesSettingsNullFields ;
/**
* Auto generated getter method
* @return com.rightnow.ws.nullfields.ContactSalesSettingsNullFields
*/
public com.rightnow.ws.nullfields.ContactSalesSettingsNullFields getContactSalesSettingsNullFields(){
return localContactSalesSettingsNullFields;
}
/**
* Auto generated setter method
* @param param ContactSalesSettingsNullFields
*/
public void setContactSalesSettingsNullFields(com.rightnow.ws.nullfields.ContactSalesSettingsNullFields param){
this.localContactSalesSettingsNullFields=param;
}
/**
* isReaderMTOMAware
* @return true if the reader supports MTOM
*/
public static boolean isReaderMTOMAware(javax.xml.stream.XMLStreamReader reader) {
boolean isReaderMTOMAware = false;
try{
isReaderMTOMAware = java.lang.Boolean.TRUE.equals(reader.getProperty(org.apache.axiom.om.OMConstants.IS_DATA_HANDLERS_AWARE));
}catch(java.lang.IllegalArgumentException e){
isReaderMTOMAware = false;
}
return isReaderMTOMAware;
}
/**
*
* @param parentQName
* @param factory
* @return org.apache.axiom.om.OMElement
*/
public org.apache.axiom.om.OMElement getOMElement (
final javax.xml.namespace.QName parentQName,
final org.apache.axiom.om.OMFactory factory) throws org.apache.axis2.databinding.ADBException{
org.apache.axiom.om.OMDataSource dataSource =
new org.apache.axis2.databinding.ADBDataSource(this,MY_QNAME){
public void serialize(org.apache.axis2.databinding.utils.writer.MTOMAwareXMLStreamWriter xmlWriter) throws javax.xml.stream.XMLStreamException {
ContactSalesSettingsNullFieldsE.this.serialize(MY_QNAME,factory,xmlWriter);
}
};
return new org.apache.axiom.om.impl.llom.OMSourcedElementImpl(
MY_QNAME,factory,dataSource);
}
public void serialize(final javax.xml.namespace.QName parentQName,
final org.apache.axiom.om.OMFactory factory,
org.apache.axis2.databinding.utils.writer.MTOMAwareXMLStreamWriter xmlWriter)
throws javax.xml.stream.XMLStreamException, org.apache.axis2.databinding.ADBException{
serialize(parentQName,factory,xmlWriter,false);
}
public void serialize(final javax.xml.namespace.QName parentQName,
final org.apache.axiom.om.OMFactory factory,
org.apache.axis2.databinding.utils.writer.MTOMAwareXMLStreamWriter xmlWriter,
boolean serializeType)
throws javax.xml.stream.XMLStreamException, org.apache.axis2.databinding.ADBException{
//We can safely assume an element has only one type associated with it
if (localContactSalesSettingsNullFields==null){
throw new org.apache.axis2.databinding.ADBException("Property cannot be null!");
}
localContactSalesSettingsNullFields.serialize(MY_QNAME,factory,xmlWriter);
}
/**
* Util method to write an attribute with the ns prefix
*/
private void writeAttribute(java.lang.String prefix,java.lang.String namespace,java.lang.String attName,
java.lang.String attValue,javax.xml.stream.XMLStreamWriter xmlWriter) throws javax.xml.stream.XMLStreamException{
if (xmlWriter.getPrefix(namespace) == null) {
xmlWriter.writeNamespace(prefix, namespace);
xmlWriter.setPrefix(prefix, namespace);
}
xmlWriter.writeAttribute(namespace,attName,attValue);
}
/**
* Util method to write an attribute without the ns prefix
*/
private void writeAttribute(java.lang.String namespace,java.lang.String attName,
java.lang.String attValue,javax.xml.stream.XMLStreamWriter xmlWriter) throws javax.xml.stream.XMLStreamException{
if (namespace.equals(""))
{
xmlWriter.writeAttribute(attName,attValue);
}
else
{
registerPrefix(xmlWriter, namespace);
xmlWriter.writeAttribute(namespace,attName,attValue);
}
}
/**
* Util method to write an attribute without the ns prefix
*/
private void writeQNameAttribute(java.lang.String namespace, java.lang.String attName,
javax.xml.namespace.QName qname, javax.xml.stream.XMLStreamWriter xmlWriter) throws javax.xml.stream.XMLStreamException {
java.lang.String attributeNamespace = qname.getNamespaceURI();
java.lang.String attributePrefix = xmlWriter.getPrefix(attributeNamespace);
if (attributePrefix == null) {
attributePrefix = registerPrefix(xmlWriter, attributeNamespace);
}
java.lang.String attributeValue;
if (attributePrefix.trim().length() > 0) {
attributeValue = attributePrefix + ":" + qname.getLocalPart();
} else {
attributeValue = qname.getLocalPart();
}
if (namespace.equals("")) {
xmlWriter.writeAttribute(attName, attributeValue);
} else {
registerPrefix(xmlWriter, namespace);
xmlWriter.writeAttribute(namespace, attName, attributeValue);
}
}
/**
* method to handle Qnames
*/
private void writeQName(javax.xml.namespace.QName qname,
javax.xml.stream.XMLStreamWriter xmlWriter) throws javax.xml.stream.XMLStreamException {
java.lang.String namespaceURI = qname.getNamespaceURI();
if (namespaceURI != null) {
java.lang.String prefix = xmlWriter.getPrefix(namespaceURI);
if (prefix == null) {
prefix = generatePrefix(namespaceURI);
xmlWriter.writeNamespace(prefix, namespaceURI);
xmlWriter.setPrefix(prefix,namespaceURI);
}
if (prefix.trim().length() > 0){
xmlWriter.writeCharacters(prefix + ":" + org.apache.axis2.databinding.utils.ConverterUtil.convertToString(qname));
} else {
// i.e this is the default namespace
xmlWriter.writeCharacters(org.apache.axis2.databinding.utils.ConverterUtil.convertToString(qname));
}
} else {
xmlWriter.writeCharacters(org.apache.axis2.databinding.utils.ConverterUtil.convertToString(qname));
}
}
private void writeQNames(javax.xml.namespace.QName[] qnames,
javax.xml.stream.XMLStreamWriter xmlWriter) throws javax.xml.stream.XMLStreamException {
if (qnames != null) {
// we have to store this data until last moment since it is not possible to write any
// namespace data after writing the charactor data
java.lang.StringBuffer stringToWrite = new java.lang.StringBuffer();
java.lang.String namespaceURI = null;
java.lang.String prefix = null;
for (int i = 0; i < qnames.length; i++) {
if (i > 0) {
stringToWrite.append(" ");
}
namespaceURI = qnames[i].getNamespaceURI();
if (namespaceURI != null) {
prefix = xmlWriter.getPrefix(namespaceURI);
if ((prefix == null) || (prefix.length() == 0)) {
prefix = generatePrefix(namespaceURI);
xmlWriter.writeNamespace(prefix, namespaceURI);
xmlWriter.setPrefix(prefix,namespaceURI);
}
if (prefix.trim().length() > 0){
stringToWrite.append(prefix).append(":").append(org.apache.axis2.databinding.utils.ConverterUtil.convertToString(qnames[i]));
} else {
stringToWrite.append(org.apache.axis2.databinding.utils.ConverterUtil.convertToString(qnames[i]));
}
} else {
stringToWrite.append(org.apache.axis2.databinding.utils.ConverterUtil.convertToString(qnames[i]));
}
}
xmlWriter.writeCharacters(stringToWrite.toString());
}
}
/**
* Register a namespace prefix
*/
private java.lang.String registerPrefix(javax.xml.stream.XMLStreamWriter xmlWriter, java.lang.String namespace) throws javax.xml.stream.XMLStreamException {
java.lang.String prefix = xmlWriter.getPrefix(namespace);
if (prefix == null) {
prefix = generatePrefix(namespace);
while (xmlWriter.getNamespaceContext().getNamespaceURI(prefix) != null) {
prefix = org.apache.axis2.databinding.utils.BeanUtil.getUniquePrefix();
}
xmlWriter.writeNamespace(prefix, namespace);
xmlWriter.setPrefix(prefix, namespace);
}
return prefix;
}
/**
* databinding method to get an XML representation of this object
*
*/
public javax.xml.stream.XMLStreamReader getPullParser(javax.xml.namespace.QName qName)
throws org.apache.axis2.databinding.ADBException{
//We can safely assume an element has only one type associated with it
return localContactSalesSettingsNullFields.getPullParser(MY_QNAME);
}
/**
* Factory class that keeps the parse method
*/
public static class Factory{
/**
* static method to create the object
* Precondition: If this object is an element, the current or next start element starts this object and any intervening reader events are ignorable
* If this object is not an element, it is a complex type and the reader is at the event just after the outer start element
* Postcondition: If this object is an element, the reader is positioned at its end element
* If this object is a complex type, the reader is positioned at the end element of its outer element
*/
public static ContactSalesSettingsNullFieldsE parse(javax.xml.stream.XMLStreamReader reader) throws java.lang.Exception{
ContactSalesSettingsNullFieldsE object =
new ContactSalesSettingsNullFieldsE();
int event;
java.lang.String nillableValue = null;
java.lang.String prefix ="";
java.lang.String namespaceuri ="";
try {
while (!reader.isStartElement() && !reader.isEndElement())
reader.next();
// Note all attributes that were handled. Used to differ normal attributes
// from anyAttributes.
java.util.Vector handledAttributes = new java.util.Vector();
while(!reader.isEndElement()) {
if (reader.isStartElement() ){
if (reader.isStartElement() && new javax.xml.namespace.QName("urn:nullfields.ws.rightnow.com/v1_2","ContactSalesSettingsNullFields").equals(reader.getName())){
object.setContactSalesSettingsNullFields(com.rightnow.ws.nullfields.ContactSalesSettingsNullFields.Factory.parse(reader));
} // End of if for expected property start element
else{
// A start element we are not expecting indicates an invalid parameter was passed
throw new org.apache.axis2.databinding.ADBException("Unexpected subelement " + reader.getLocalName());
}
} else {
reader.next();
}
} // end of while loop
} catch (javax.xml.stream.XMLStreamException e) {
throw new java.lang.Exception(e);
}
return object;
}
}//end of factory class
}
| [
"asefora2080@gmail.com"
] | asefora2080@gmail.com |
db35889b10d8ce7f6b6664a3b073b99800963493 | 421dd2eb1f38b36769d65cbf71349259ff4584b0 | /src/com/fixent/sm/client/maintenance/view/SubjectMaintenanceView.java | 3d39e1c117bf09fc5159e5f8302b431d4cb43eda | [] | no_license | arulxavier/StudentManagement | fccfc5472fd0e941abb5098fca143024ca15462b | 2fe3227e46e7fcd13be8f59179f5b38b9376e3a9 | refs/heads/master | 2021-01-10T13:55:20.420095 | 2014-07-31T10:12:31 | 2014-07-31T10:12:31 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 11,180 | java | /*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.fixent.sm.client.maintenance.view;
/**
*
* @author Mathan
*/
public class SubjectMaintenanceView extends javax.swing.JPanel {
/**
* Creates new form Maintenance
*/
public SubjectMaintenanceView() {
initComponents();
}
/**
* This method is called from within the constructor to initialize the form.
* WARNING: Do NOT modify this code. The content of this method is always
* regenerated by the Form Editor.
*/
@SuppressWarnings("unchecked")
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {
jLabel1 = new javax.swing.JLabel();
jScrollPane1 = new javax.swing.JScrollPane();
subjectCategoryTable = new javax.swing.JTable();
subjectCategoryAddButton = new javax.swing.JButton();
subjectCategoryDeleteButton = new javax.swing.JButton();
jLabel2 = new javax.swing.JLabel();
jScrollPane2 = new javax.swing.JScrollPane();
subjectTable = new javax.swing.JTable();
subjectAddButton = new javax.swing.JButton();
subjectDeleteButton = new javax.swing.JButton();
errorMsgLabel = new javax.swing.JLabel();
setBackground(new java.awt.Color(255, 255, 255));
setAutoscrolls(true);
jLabel1.setFont(new java.awt.Font("Verdana", 1, 14)); // NOI18N
jLabel1.setText("Subject");
subjectCategoryTable.setFont(new java.awt.Font("Verdana", 0, 12)); // NOI18N
subjectCategoryTable.setModel(new javax.swing.table.DefaultTableModel(
new Object [][] {
},
new String [] {
"ID", "Subject Category Name"
}
) {
boolean[] canEdit = new boolean [] {
false, false
};
public boolean isCellEditable(int rowIndex, int columnIndex) {
return canEdit [columnIndex];
}
});
subjectCategoryTable.setFillsViewportHeight(true);
subjectCategoryTable.setGridColor(new java.awt.Color(204, 204, 204));
jScrollPane1.setViewportView(subjectCategoryTable);
subjectCategoryAddButton.setBackground(new java.awt.Color(61, 86, 109));
subjectCategoryAddButton.setFont(new java.awt.Font("Verdana", 0, 12)); // NOI18N
subjectCategoryAddButton.setForeground(new java.awt.Color(255, 255, 255));
subjectCategoryAddButton.setText("Add");
subjectCategoryDeleteButton.setBackground(new java.awt.Color(61, 86, 109));
subjectCategoryDeleteButton.setFont(new java.awt.Font("Verdana", 0, 12)); // NOI18N
subjectCategoryDeleteButton.setForeground(new java.awt.Color(255, 255, 255));
subjectCategoryDeleteButton.setText("Delete");
jLabel2.setFont(new java.awt.Font("Verdana", 1, 14)); // NOI18N
jLabel2.setText("Subject Category");
subjectTable.setFont(new java.awt.Font("Verdana", 0, 12)); // NOI18N
subjectTable.setModel(new javax.swing.table.DefaultTableModel(
new Object [][] {
},
new String [] {
"ID", "Subject Name", "Subject Category"
}
) {
boolean[] canEdit = new boolean [] {
false, false, false
};
public boolean isCellEditable(int rowIndex, int columnIndex) {
return canEdit [columnIndex];
}
});
subjectTable.setFillsViewportHeight(true);
subjectTable.setGridColor(new java.awt.Color(204, 204, 204));
subjectTable.getTableHeader().setReorderingAllowed(false);
jScrollPane2.setViewportView(subjectTable);
subjectTable.getColumnModel().getColumn(0).setPreferredWidth(30);
subjectAddButton.setBackground(new java.awt.Color(61, 86, 109));
subjectAddButton.setFont(new java.awt.Font("Verdana", 0, 12)); // NOI18N
subjectAddButton.setForeground(new java.awt.Color(255, 255, 255));
subjectAddButton.setText("Add");
subjectDeleteButton.setBackground(new java.awt.Color(61, 86, 109));
subjectDeleteButton.setFont(new java.awt.Font("Verdana", 0, 12)); // NOI18N
subjectDeleteButton.setForeground(new java.awt.Color(255, 255, 255));
subjectDeleteButton.setText("Delete");
errorMsgLabel.setForeground(new java.awt.Color(255, 0, 0));
javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
this.setLayout(layout);
layout.setHorizontalGroup(
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(layout.createSequentialGroup()
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(layout.createSequentialGroup()
.addGap(80, 80, 80)
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
.addGroup(layout.createSequentialGroup()
.addComponent(subjectCategoryAddButton)
.addGap(10, 10, 10)
.addComponent(subjectCategoryDeleteButton))
.addGroup(layout.createSequentialGroup()
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
.addGroup(layout.createSequentialGroup()
.addComponent(subjectAddButton)
.addGap(10, 10, 10)
.addComponent(subjectDeleteButton))
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
.addComponent(jLabel2, javax.swing.GroupLayout.Alignment.LEADING)
.addComponent(jScrollPane1, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(jScrollPane2, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(jLabel1, javax.swing.GroupLayout.Alignment.LEADING)))
.addGap(2, 2, 2))))
.addGroup(layout.createSequentialGroup()
.addGap(10, 10, 10)
.addComponent(errorMsgLabel, javax.swing.GroupLayout.PREFERRED_SIZE, 538, javax.swing.GroupLayout.PREFERRED_SIZE)))
.addGap(51, 51, 51))
);
layout.setVerticalGroup(
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(layout.createSequentialGroup()
.addContainerGap()
.addComponent(jLabel2)
.addGap(20, 20, 20)
.addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 123, javax.swing.GroupLayout.PREFERRED_SIZE)
.addGap(20, 20, 20)
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(subjectCategoryAddButton)
.addComponent(subjectCategoryDeleteButton))
.addGap(20, 20, 20)
.addComponent(jLabel1)
.addGap(20, 20, 20)
.addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 114, javax.swing.GroupLayout.PREFERRED_SIZE)
.addGap(20, 20, 20)
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(subjectAddButton)
.addComponent(subjectDeleteButton))
.addGap(25, 25, 25)
.addComponent(errorMsgLabel)
.addContainerGap())
);
}// </editor-fold>//GEN-END:initComponents
// Variables declaration - do not modify//GEN-BEGIN:variables
private javax.swing.JLabel errorMsgLabel;
private javax.swing.JLabel jLabel1;
private javax.swing.JLabel jLabel2;
private javax.swing.JScrollPane jScrollPane1;
private javax.swing.JScrollPane jScrollPane2;
private javax.swing.JButton subjectAddButton;
private javax.swing.JButton subjectCategoryAddButton;
private javax.swing.JButton subjectCategoryDeleteButton;
private javax.swing.JTable subjectCategoryTable;
private javax.swing.JButton subjectDeleteButton;
private javax.swing.JTable subjectTable;
// End of variables declaration//GEN-END:variables
public javax.swing.JLabel getjLabel1() {
return jLabel1;
}
public void setjLabel1(javax.swing.JLabel jLabel1) {
this.jLabel1 = jLabel1;
}
public javax.swing.JLabel getjLabel2() {
return jLabel2;
}
public void setjLabel2(javax.swing.JLabel jLabel2) {
this.jLabel2 = jLabel2;
}
public javax.swing.JScrollPane getjScrollPane1() {
return jScrollPane1;
}
public void setjScrollPane1(javax.swing.JScrollPane jScrollPane1) {
this.jScrollPane1 = jScrollPane1;
}
public javax.swing.JScrollPane getjScrollPane2() {
return jScrollPane2;
}
public void setjScrollPane2(javax.swing.JScrollPane jScrollPane2) {
this.jScrollPane2 = jScrollPane2;
}
public javax.swing.JButton getSubjectAddButton() {
return subjectAddButton;
}
public void setSubjectAddButton(javax.swing.JButton subjectAddButton) {
this.subjectAddButton = subjectAddButton;
}
public javax.swing.JButton getSubjectCategoryAddButton() {
return subjectCategoryAddButton;
}
public void setSubjectCategoryAddButton(
javax.swing.JButton subjectCategoryAddButton) {
this.subjectCategoryAddButton = subjectCategoryAddButton;
}
public javax.swing.JButton getSubjectCategoryDeleteButton() {
return subjectCategoryDeleteButton;
}
public void setSubjectCategoryDeleteButton(
javax.swing.JButton subjectCategoryDeleteButton) {
this.subjectCategoryDeleteButton = subjectCategoryDeleteButton;
}
public javax.swing.JTable getSubjectCategoryTable() {
return subjectCategoryTable;
}
public void setSubjectCategoryTable(javax.swing.JTable subjectCategoryTable) {
this.subjectCategoryTable = subjectCategoryTable;
}
public javax.swing.JButton getSubjectDeleteButton() {
return subjectDeleteButton;
}
public void setSubjectDeleteButton(javax.swing.JButton subjectDeleteButton) {
this.subjectDeleteButton = subjectDeleteButton;
}
public javax.swing.JTable getSubjectTable() {
return subjectTable;
}
public void setSubjectTable(javax.swing.JTable subjectTable) {
this.subjectTable = subjectTable;
}
public javax.swing.JLabel getErrorMsgLabel() {
return errorMsgLabel;
}
public void setErrorMsgLabel(javax.swing.JLabel errorMsgLabel) {
this.errorMsgLabel = errorMsgLabel;
}
}
| [
"mathan@ubuntu.(none)"
] | mathan@ubuntu.(none) |
f9243545ff4c5eecf3eed6c157d142da9f6a39be | 6da6cf5935fffd187eaade9146f56d12b0c581e0 | /src/main/java/com/renault/wired/SpringBootWebApplication.java | 5c6690379269563b46952e5df6ddfd02f80b87df | [] | no_license | caesarpro/fspage | 5c4eeab90a977356bc0e5a35cf13b696dcdd5be9 | efa6b4e644b69aa9279534210c81ae4b153cbae2 | refs/heads/master | 2020-04-05T23:17:29.017183 | 2017-03-27T15:21:07 | 2017-03-27T15:21:07 | 7,867,318 | 0 | 0 | null | 2017-03-27T15:21:08 | 2013-01-28T10:04:20 | null | UTF-8 | Java | false | false | 335 | java | package com.renault.wired;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication
public class SpringBootWebApplication {
public static void main(String[] args) {
SpringApplication.run(SpringBootWebApplication.class, args);
}
}
| [
"sebaoui@ubuntu.ubuntu-domain"
] | sebaoui@ubuntu.ubuntu-domain |
adec6107b9b5e6cb3f84086ac24d008f65f2b7df | b176b1b603cb5ea9a969c4d910214bde72a8b103 | /src/main/java/com/steve/academysteveback/blog/service/BlogService.java | 623233ebc6fb931495af7f39bd0db9d7acc5dae9 | [] | no_license | academystevelee/academysteve-back | 13c633095cbc943636e7af9f500441f87545701e | ef2af220a5f0225df4b71bc0712159593435e668 | refs/heads/master | 2023-08-11T14:01:34.605677 | 2021-09-27T08:44:17 | 2021-09-27T08:44:17 | 397,259,491 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,931 | java | package com.steve.academysteveback.blog.service;
import com.steve.academysteveback.blog.dto.BlogDto;
import com.steve.academysteveback.blog.entity.BlogEntity;
import com.steve.academysteveback.blog.repository.BlogRepository;
import com.steve.academysteveback.util.commoncode.CommonCodeService;
import com.steve.academysteveback.util.commoncode.CommonDto;
import com.steve.academysteveback.util.commoncode.CommonEntity;
import org.modelmapper.ModelMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.stereotype.Service;
import java.util.List;
import java.util.Optional;
@Service
public class BlogService {
@Autowired
BlogRepository blogRepository;
@Autowired
CommonCodeService commonCodeService;
ModelMapper modelMapper = new ModelMapper();
/**
* 강좌등록
* @param blogDto
*/
public void register(BlogDto blogDto) {
BlogEntity blogEntity = new BlogEntity();
blogEntity = modelMapper.map(blogDto, BlogEntity.class);
blogRepository.save(blogEntity);
}
/**
* 강좌조회
*/
public BlogEntity findByBlogNo(Long blogNo) {
BlogEntity blogEntity = blogRepository.findBySeq(blogNo);
blogEntity.setHit(blogEntity.getHit() + 1);
blogRepository.save(blogEntity);
return blogEntity;
}
public Page<BlogEntity> findByPageNo(Pageable pageable){
Page<BlogEntity> pbloglist = blogRepository.findAll(pageable);
for(int n = 0 ; n < pbloglist.getContent().size() ; n ++) {
CommonDto commonDto = new CommonDto();
commonDto.setCode1("cate");
commonDto.setCode2(pbloglist.getContent().get(n).getCate());
CommonEntity commonEntity = commonCodeService.findCodeName(commonDto);
pbloglist.getContent().get(n).setCate(commonEntity.getCodename());
}
return pbloglist;
}
}
| [
"stevelee@steveleejava.com"
] | stevelee@steveleejava.com |
6116067c587191c2deb22c2666277e00663c044c | b713d9697b33b12c6a9e315ccf2bc83f9a7f6243 | /sys_parent/sys_core/src/main/java/com/sys/core/App.java | 88d7d3af93c61f00ca6ed9b1aae14d2f5185c583 | [] | no_license | qshome/sys_parent | aa1a92cf5c00ff5d48848828d1a2287a14b1e10d | ee3c22f18abdb4e60a680016436306ab5464b06f | refs/heads/master | 2020-04-11T05:51:13.351332 | 2018-12-27T07:09:30 | 2018-12-27T07:09:30 | 161,561,912 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 188 | java | package com.sys.core;
/**
* Hello world!
*
*/
public class App
{
public static void main( String[] args )
{
System.out.println( "Hello World!" );
}
}
| [
"758085249@qq.com"
] | 758085249@qq.com |
4884f83f53a82add39faf9fc763c4b881f5e9000 | deb747e039ea25f5859ff8199015eadd7ff60070 | /src/cn/edu/xmu/software/binarykang/minor/sheet3/chapter05/_5_1/_5_1_2.java | 17662f22aa8ac5de6973ff1290e2f4c281a857c6 | [
"Apache-2.0"
] | permissive | huazhz/ParseWeb | fb393294614257457d59ea55647cfcc60466e2fe | d0275f08fc2799b0cce923dae988c63c10fa6b5e | refs/heads/master | 2020-04-17T14:40:51.763485 | 2017-07-17T09:22:54 | 2017-07-17T09:22:54 | null | 0 | 0 | null | null | null | null | WINDOWS-1252 | Java | false | false | 1,380 | java | package cn.edu.xmu.software.binarykang.minor.sheet3.chapter05._5_1;
import java.util.List;
import cn.edu.xmu.software.binarykang.minor.MinorBaseAction;
import cn.edu.xmu.software.binarykang.minor.parse.DataMap;
import cn.edu.xmu.software.binarykang.minor.util.MinorUtil;
import cn.edu.xmu.software.binarykang.word.Docx;
import cn.edu.xmu.software.binarykang.xlsx.Xlsx;
public class _5_1_2 extends MinorBaseAction
{
private final static String TABLE_KEY = "9-13Ëêϲ°®µÄ¶¯ÂþÌâ²Ä";
private List<DataMap> tableInfo;
public _5_1_2(Docx docx, Xlsx xlsx)
{
super(docx, xlsx);
tableInfo = MinorUtil.listMapFactory();
}
@Override
protected void readData()
{
MinorUtil.readData(xlsx, TABLE_KEY, tableInfo, BEGIN_COL + 1);
}
@Override
protected void replace()
{
MinorUtil.listSort(tableInfo);
for (int i = 0; i < 4; i++)
{
tr("${sheet_3_5_1_2_favor_cartoon_theme_" + i + "}",
tableInfo.get(i).getKey());
tr("${sheet_3_5_1_2_favor_cartoon_theme_" + i + "_rate}",
perf.format(tableInfo.get(i).getRate()));
}
for (int i = 8; i>5 ; i--)
{
tr("${sheet_3_5_1_2_favor_cartoon_theme_" + i + "}",
tableInfo.get(i).getKey());
tr("${sheet_3_5_1_2_favor_cartoon_theme_" + i + "_rate}",
perf.format(tableInfo.get(i).getRate()));
}
}
@Override
protected void chart()
{
MinorUtil.changeChart(tableInfo);
}
}
| [
"695089605@qq.com"
] | 695089605@qq.com |
8bb8401b77a9e005ed71fc13e33d0ff8fa5d24ad | 2f3c04382a66dbf222c8587edd67a5df4bc80422 | /src/com/cedar/cp/api/dimension/DimensionEditor.java | 4ea4d7b9c03285da508d7405e8aef1120707e062 | [] | no_license | arnoldbendaa/cppro | d3ab6181cc51baad2b80876c65e11e92c569f0cc | f55958b85a74ad685f1360ae33c881b50d6e5814 | refs/heads/master | 2020-03-23T04:18:00.265742 | 2018-09-11T08:15:28 | 2018-09-11T08:15:28 | 141,074,966 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,700 | java | // Decompiled by: Fernflower v0.8.6
// Date: 12.08.2012 13:04:17
// Copyright: 2008-2012, Stiver
// Home page: http://www.neshkov.com/ac_decompiler.html
package com.cedar.cp.api.dimension;
import com.cedar.cp.api.base.BusinessEditor;
import com.cedar.cp.api.base.CPException;
import com.cedar.cp.api.base.DuplicateNameValidationException;
import com.cedar.cp.api.base.ValidationException;
import com.cedar.cp.api.dimension.Dimension;
import com.cedar.cp.api.dimension.DimensionElement;
import com.cedar.cp.api.dimension.DimensionElementEditor;
import com.cedar.cp.api.model.ModelRef;
public interface DimensionEditor extends BusinessEditor {
void setType(int var1) throws ValidationException;
void setVisId(String var1) throws ValidationException;
void setDescription(String var1) throws ValidationException;
void setExternalSystemRef(Integer var1) throws ValidationException;
Dimension getDimension();
DimensionElement insertElement(String var1, String var2, int var3, boolean var4, boolean var5, int var6, boolean var7) throws DuplicateNameValidationException, ValidationException, CPException;
DimensionElement insertElement(String var1, String var2, int var3, boolean var4, boolean var5, int var6) throws DuplicateNameValidationException, ValidationException, CPException;
void removeElement(Object var1, String var2) throws ValidationException, CPException;
DimensionElementEditor getElementEditor(Object var1) throws ValidationException, CPException;
ModelRef queryOwningModel();
void setSubmitChangeManagementRequest(boolean var1);
boolean isAugmentMode();
}
| [
"arnoldbendaa@gmail.com"
] | arnoldbendaa@gmail.com |
5a384c374e83e0a9d8ff05f9a887cb64dd3d6508 | 48e835e6f176a8ac9ae3ca718e8922891f1e5a18 | /benchmark/validation/io/reactivex/internal/operators/single/SingleTakeUntilTest.java | b54e681666c6f50599c5e86f248d86de0eed8316 | [] | no_license | STAMP-project/dspot-experiments | f2c7a639d6616ae0adfc491b4cb4eefcb83d04e5 | 121487e65cdce6988081b67f21bbc6731354a47f | refs/heads/master | 2023-02-07T14:40:12.919811 | 2019-11-06T07:17:09 | 2019-11-06T07:17:09 | 75,710,758 | 14 | 19 | null | 2023-01-26T23:57:41 | 2016-12-06T08:27:42 | null | UTF-8 | Java | false | false | 18,366 | java | /**
* Copyright (c) 2016-present, RxJava Contributors.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software distributed under the License is
* distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See
* the License for the specific language governing permissions and limitations under the License.
*/
package io.reactivex.internal.operators.single;
import io.reactivex.TestHelper;
import io.reactivex.exceptions.TestException;
import io.reactivex.internal.subscriptions.BooleanSubscription;
import io.reactivex.observers.TestObserver;
import io.reactivex.plugins.RxJavaPlugins;
import io.reactivex.processors.PublishProcessor;
import java.util.List;
import java.util.concurrent.CancellationException;
import org.junit.Assert;
import org.junit.Test;
import org.reactivestreams.Subscriber;
public class SingleTakeUntilTest {
@Test
public void mainSuccessPublisher() {
PublishProcessor<Integer> pp = PublishProcessor.create();
PublishProcessor<Integer> source = PublishProcessor.create();
TestObserver<Integer> to = source.single((-99)).takeUntil(pp).test();
source.onNext(1);
source.onComplete();
to.assertResult(1);
}
@Test
public void mainSuccessSingle() {
PublishProcessor<Integer> pp = PublishProcessor.create();
PublishProcessor<Integer> source = PublishProcessor.create();
TestObserver<Integer> to = source.single((-99)).takeUntil(pp.single((-99))).test();
source.onNext(1);
source.onComplete();
to.assertResult(1);
}
@Test
public void mainSuccessCompletable() {
PublishProcessor<Integer> pp = PublishProcessor.create();
PublishProcessor<Integer> source = PublishProcessor.create();
TestObserver<Integer> to = source.single((-99)).takeUntil(pp.ignoreElements()).test();
source.onNext(1);
source.onComplete();
to.assertResult(1);
}
@Test
public void mainErrorPublisher() {
PublishProcessor<Integer> pp = PublishProcessor.create();
PublishProcessor<Integer> source = PublishProcessor.create();
TestObserver<Integer> to = source.single((-99)).takeUntil(pp).test();
source.onError(new TestException());
to.assertFailure(TestException.class);
}
@Test
public void mainErrorSingle() {
PublishProcessor<Integer> pp = PublishProcessor.create();
PublishProcessor<Integer> source = PublishProcessor.create();
TestObserver<Integer> to = source.single((-99)).takeUntil(pp.single((-99))).test();
source.onError(new TestException());
to.assertFailure(TestException.class);
}
@Test
public void mainErrorCompletable() {
PublishProcessor<Integer> pp = PublishProcessor.create();
PublishProcessor<Integer> source = PublishProcessor.create();
TestObserver<Integer> to = source.single((-99)).takeUntil(pp.ignoreElements()).test();
source.onError(new TestException());
to.assertFailure(TestException.class);
}
@Test
public void otherOnNextPublisher() {
PublishProcessor<Integer> pp = PublishProcessor.create();
PublishProcessor<Integer> source = PublishProcessor.create();
TestObserver<Integer> to = source.single((-99)).takeUntil(pp).test();
pp.onNext(1);
to.assertFailure(CancellationException.class);
}
@Test
public void otherOnNextSingle() {
PublishProcessor<Integer> pp = PublishProcessor.create();
PublishProcessor<Integer> source = PublishProcessor.create();
TestObserver<Integer> to = source.single((-99)).takeUntil(pp.single((-99))).test();
pp.onNext(1);
pp.onComplete();
to.assertFailure(CancellationException.class);
}
@Test
public void otherOnNextCompletable() {
PublishProcessor<Integer> pp = PublishProcessor.create();
PublishProcessor<Integer> source = PublishProcessor.create();
TestObserver<Integer> to = source.single((-99)).takeUntil(pp.ignoreElements()).test();
pp.onNext(1);
pp.onComplete();
to.assertFailure(CancellationException.class);
}
@Test
public void otherOnCompletePublisher() {
PublishProcessor<Integer> pp = PublishProcessor.create();
PublishProcessor<Integer> source = PublishProcessor.create();
TestObserver<Integer> to = source.single((-99)).takeUntil(pp).test();
pp.onComplete();
to.assertFailure(CancellationException.class);
}
@Test
public void otherOnCompleteCompletable() {
PublishProcessor<Integer> pp = PublishProcessor.create();
PublishProcessor<Integer> source = PublishProcessor.create();
TestObserver<Integer> to = source.single((-99)).takeUntil(pp.ignoreElements()).test();
pp.onComplete();
to.assertFailure(CancellationException.class);
}
@Test
public void otherErrorPublisher() {
PublishProcessor<Integer> pp = PublishProcessor.create();
PublishProcessor<Integer> source = PublishProcessor.create();
TestObserver<Integer> to = source.single((-99)).takeUntil(pp).test();
pp.onError(new TestException());
to.assertFailure(TestException.class);
}
@Test
public void otherErrorSingle() {
PublishProcessor<Integer> pp = PublishProcessor.create();
PublishProcessor<Integer> source = PublishProcessor.create();
TestObserver<Integer> to = source.single((-99)).takeUntil(pp.single((-99))).test();
pp.onError(new TestException());
to.assertFailure(TestException.class);
}
@Test
public void otherErrorCompletable() {
PublishProcessor<Integer> pp = PublishProcessor.create();
PublishProcessor<Integer> source = PublishProcessor.create();
TestObserver<Integer> to = source.single((-99)).takeUntil(pp.ignoreElements()).test();
pp.onError(new TestException());
to.assertFailure(TestException.class);
}
@Test
public void withPublisherDispose() {
TestHelper.checkDisposed(Single.never().takeUntil(Flowable.never()));
}
@Test
public void onErrorRace() {
for (int i = 0; i < (TestHelper.RACE_DEFAULT_LOOPS); i++) {
List<Throwable> errors = TestHelper.trackPluginErrors();
try {
final PublishProcessor<Integer> pp1 = PublishProcessor.create();
final PublishProcessor<Integer> pp2 = PublishProcessor.create();
TestObserver<Integer> to = pp1.singleOrError().takeUntil(pp2).test();
final TestException ex = new TestException();
Runnable r1 = new Runnable() {
@Override
public void run() {
pp1.onError(ex);
}
};
Runnable r2 = new Runnable() {
@Override
public void run() {
pp2.onError(ex);
}
};
TestHelper.race(r1, r2);
to.assertFailure(TestException.class);
if (!(errors.isEmpty())) {
TestHelper.assertUndeliverable(errors, 0, TestException.class);
}
} finally {
RxJavaPlugins.reset();
}
}
}
@Test
public void otherSignalsAndCompletes() {
List<Throwable> errors = TestHelper.trackPluginErrors();
try {
Single.just(1).takeUntil(Flowable.just(1).take(1)).test().assertFailure(CancellationException.class);
Assert.assertTrue(errors.toString(), errors.isEmpty());
} finally {
RxJavaPlugins.reset();
}
}
@Test
public void flowableCancelDelayed() {
Single.never().takeUntil(new Flowable<Integer>() {
@Override
protected void subscribeActual(Subscriber<? super Integer> s) {
s.onSubscribe(new BooleanSubscription());
s.onNext(1);
s.onNext(2);
}
}).test().assertFailure(CancellationException.class);
}
@Test
public void untilSingleMainSuccess() {
SingleSubject<Integer> main = SingleSubject.create();
SingleSubject<Integer> other = SingleSubject.create();
TestObserver<Integer> to = main.takeUntil(other).test();
Assert.assertTrue("Main no observers?", main.hasObservers());
Assert.assertTrue("Other no observers?", other.hasObservers());
main.onSuccess(1);
Assert.assertFalse("Main has observers?", main.hasObservers());
Assert.assertFalse("Other has observers?", other.hasObservers());
to.assertResult(1);
}
@Test
public void untilSingleMainError() {
SingleSubject<Integer> main = SingleSubject.create();
SingleSubject<Integer> other = SingleSubject.create();
TestObserver<Integer> to = main.takeUntil(other).test();
Assert.assertTrue("Main no observers?", main.hasObservers());
Assert.assertTrue("Other no observers?", other.hasObservers());
main.onError(new TestException());
Assert.assertFalse("Main has observers?", main.hasObservers());
Assert.assertFalse("Other has observers?", other.hasObservers());
to.assertFailure(TestException.class);
}
@Test
public void untilSingleOtherSuccess() {
SingleSubject<Integer> main = SingleSubject.create();
SingleSubject<Integer> other = SingleSubject.create();
TestObserver<Integer> to = main.takeUntil(other).test();
Assert.assertTrue("Main no observers?", main.hasObservers());
Assert.assertTrue("Other no observers?", other.hasObservers());
other.onSuccess(1);
Assert.assertFalse("Main has observers?", main.hasObservers());
Assert.assertFalse("Other has observers?", other.hasObservers());
to.assertFailure(CancellationException.class);
}
@Test
public void untilSingleOtherError() {
SingleSubject<Integer> main = SingleSubject.create();
SingleSubject<Integer> other = SingleSubject.create();
TestObserver<Integer> to = main.takeUntil(other).test();
Assert.assertTrue("Main no observers?", main.hasObservers());
Assert.assertTrue("Other no observers?", other.hasObservers());
other.onError(new TestException());
Assert.assertFalse("Main has observers?", main.hasObservers());
Assert.assertFalse("Other has observers?", other.hasObservers());
to.assertFailure(TestException.class);
}
@Test
public void untilSingleDispose() {
SingleSubject<Integer> main = SingleSubject.create();
SingleSubject<Integer> other = SingleSubject.create();
TestObserver<Integer> to = main.takeUntil(other).test();
Assert.assertTrue("Main no observers?", main.hasObservers());
Assert.assertTrue("Other no observers?", other.hasObservers());
to.dispose();
Assert.assertFalse("Main has observers?", main.hasObservers());
Assert.assertFalse("Other has observers?", other.hasObservers());
to.assertEmpty();
}
@Test
public void untilPublisherMainSuccess() {
SingleSubject<Integer> main = SingleSubject.create();
PublishProcessor<Integer> other = PublishProcessor.create();
TestObserver<Integer> to = main.takeUntil(other).test();
Assert.assertTrue("Main no observers?", main.hasObservers());
Assert.assertTrue("Other no observers?", other.hasSubscribers());
main.onSuccess(1);
Assert.assertFalse("Main has observers?", main.hasObservers());
Assert.assertFalse("Other has observers?", other.hasSubscribers());
to.assertResult(1);
}
@Test
public void untilPublisherMainError() {
SingleSubject<Integer> main = SingleSubject.create();
PublishProcessor<Integer> other = PublishProcessor.create();
TestObserver<Integer> to = main.takeUntil(other).test();
Assert.assertTrue("Main no observers?", main.hasObservers());
Assert.assertTrue("Other no observers?", other.hasSubscribers());
main.onError(new TestException());
Assert.assertFalse("Main has observers?", main.hasObservers());
Assert.assertFalse("Other has observers?", other.hasSubscribers());
to.assertFailure(TestException.class);
}
@Test
public void untilPublisherOtherOnNext() {
SingleSubject<Integer> main = SingleSubject.create();
PublishProcessor<Integer> other = PublishProcessor.create();
TestObserver<Integer> to = main.takeUntil(other).test();
Assert.assertTrue("Main no observers?", main.hasObservers());
Assert.assertTrue("Other no observers?", other.hasSubscribers());
other.onNext(1);
Assert.assertFalse("Main has observers?", main.hasObservers());
Assert.assertFalse("Other has observers?", other.hasSubscribers());
to.assertFailure(CancellationException.class);
}
@Test
public void untilPublisherOtherOnComplete() {
SingleSubject<Integer> main = SingleSubject.create();
PublishProcessor<Integer> other = PublishProcessor.create();
TestObserver<Integer> to = main.takeUntil(other).test();
Assert.assertTrue("Main no observers?", main.hasObservers());
Assert.assertTrue("Other no observers?", other.hasSubscribers());
other.onComplete();
Assert.assertFalse("Main has observers?", main.hasObservers());
Assert.assertFalse("Other has observers?", other.hasSubscribers());
to.assertFailure(CancellationException.class);
}
@Test
public void untilPublisherOtherError() {
SingleSubject<Integer> main = SingleSubject.create();
PublishProcessor<Integer> other = PublishProcessor.create();
TestObserver<Integer> to = main.takeUntil(other).test();
Assert.assertTrue("Main no observers?", main.hasObservers());
Assert.assertTrue("Other no observers?", other.hasSubscribers());
other.onError(new TestException());
Assert.assertFalse("Main has observers?", main.hasObservers());
Assert.assertFalse("Other has observers?", other.hasSubscribers());
to.assertFailure(TestException.class);
}
@Test
public void untilPublisherDispose() {
SingleSubject<Integer> main = SingleSubject.create();
PublishProcessor<Integer> other = PublishProcessor.create();
TestObserver<Integer> to = main.takeUntil(other).test();
Assert.assertTrue("Main no observers?", main.hasObservers());
Assert.assertTrue("Other no observers?", other.hasSubscribers());
to.dispose();
Assert.assertFalse("Main has observers?", main.hasObservers());
Assert.assertFalse("Other has observers?", other.hasSubscribers());
to.assertEmpty();
}
@Test
public void untilCompletableMainSuccess() {
SingleSubject<Integer> main = SingleSubject.create();
CompletableSubject other = CompletableSubject.create();
TestObserver<Integer> to = main.takeUntil(other).test();
Assert.assertTrue("Main no observers?", main.hasObservers());
Assert.assertTrue("Other no observers?", other.hasObservers());
main.onSuccess(1);
Assert.assertFalse("Main has observers?", main.hasObservers());
Assert.assertFalse("Other has observers?", other.hasObservers());
to.assertResult(1);
}
@Test
public void untilCompletableMainError() {
SingleSubject<Integer> main = SingleSubject.create();
CompletableSubject other = CompletableSubject.create();
TestObserver<Integer> to = main.takeUntil(other).test();
Assert.assertTrue("Main no observers?", main.hasObservers());
Assert.assertTrue("Other no observers?", other.hasObservers());
main.onError(new TestException());
Assert.assertFalse("Main has observers?", main.hasObservers());
Assert.assertFalse("Other has observers?", other.hasObservers());
to.assertFailure(TestException.class);
}
@Test
public void untilCompletableOtherOnComplete() {
SingleSubject<Integer> main = SingleSubject.create();
CompletableSubject other = CompletableSubject.create();
TestObserver<Integer> to = main.takeUntil(other).test();
Assert.assertTrue("Main no observers?", main.hasObservers());
Assert.assertTrue("Other no observers?", other.hasObservers());
other.onComplete();
Assert.assertFalse("Main has observers?", main.hasObservers());
Assert.assertFalse("Other has observers?", other.hasObservers());
to.assertFailure(CancellationException.class);
}
@Test
public void untilCompletableOtherError() {
SingleSubject<Integer> main = SingleSubject.create();
CompletableSubject other = CompletableSubject.create();
TestObserver<Integer> to = main.takeUntil(other).test();
Assert.assertTrue("Main no observers?", main.hasObservers());
Assert.assertTrue("Other no observers?", other.hasObservers());
other.onError(new TestException());
Assert.assertFalse("Main has observers?", main.hasObservers());
Assert.assertFalse("Other has observers?", other.hasObservers());
to.assertFailure(TestException.class);
}
@Test
public void untilCompletableDispose() {
SingleSubject<Integer> main = SingleSubject.create();
CompletableSubject other = CompletableSubject.create();
TestObserver<Integer> to = main.takeUntil(other).test();
Assert.assertTrue("Main no observers?", main.hasObservers());
Assert.assertTrue("Other no observers?", other.hasObservers());
to.dispose();
Assert.assertFalse("Main has observers?", main.hasObservers());
Assert.assertFalse("Other has observers?", other.hasObservers());
to.assertEmpty();
}
}
| [
"benjamin.danglot@inria.fr"
] | benjamin.danglot@inria.fr |
a2db3c2a7fd9ab3810a8fe77644ecde2eb8d28db | fc5f16c7dd1cd7aee2d2ca0eb414860b5ad6d384 | /src/temp/src/minecraft/net/minecraft/src/Packet15Place.java | f9967ade1efba65eaa933168a5aa95e7c9049ca5 | [] | no_license | Nickorama21/Minecraft--TI-Nspire-CX-Port | 44eeca7a742d199e223d712866352a9e12b3290c | 95acc13c310f519ed8d4ed5a755ef70712da532f | refs/heads/master | 2020-05-17T11:31:43.456900 | 2012-09-01T17:24:47 | 2012-09-01T17:24:52 | 5,623,326 | 4 | 1 | null | null | null | null | UTF-8 | Java | false | false | 2,802 | java | package net.minecraft.src;
import java.io.DataInputStream;
import java.io.DataOutputStream;
import java.io.IOException;
import net.minecraft.src.ItemStack;
import net.minecraft.src.NetHandler;
import net.minecraft.src.Packet;
public class Packet15Place extends Packet {
private int field_73415_a;
private int field_73413_b;
private int field_73414_c;
private int field_73411_d;
private ItemStack field_73412_e;
private float field_73409_f;
private float field_73410_g;
private float field_73416_h;
public Packet15Place() {}
public Packet15Place(int p_i3366_1_, int p_i3366_2_, int p_i3366_3_, int p_i3366_4_, ItemStack p_i3366_5_, float p_i3366_6_, float p_i3366_7_, float p_i3366_8_) {
this.field_73415_a = p_i3366_1_;
this.field_73413_b = p_i3366_2_;
this.field_73414_c = p_i3366_3_;
this.field_73411_d = p_i3366_4_;
this.field_73412_e = p_i3366_5_;
this.field_73409_f = p_i3366_6_;
this.field_73410_g = p_i3366_7_;
this.field_73416_h = p_i3366_8_;
}
public void func_73267_a(DataInputStream p_73267_1_) throws IOException {
this.field_73415_a = p_73267_1_.readInt();
this.field_73413_b = p_73267_1_.read();
this.field_73414_c = p_73267_1_.readInt();
this.field_73411_d = p_73267_1_.read();
this.field_73412_e = func_73276_c(p_73267_1_);
this.field_73409_f = (float)p_73267_1_.read() / 16.0F;
this.field_73410_g = (float)p_73267_1_.read() / 16.0F;
this.field_73416_h = (float)p_73267_1_.read() / 16.0F;
}
public void func_73273_a(DataOutputStream p_73273_1_) throws IOException {
p_73273_1_.writeInt(this.field_73415_a);
p_73273_1_.write(this.field_73413_b);
p_73273_1_.writeInt(this.field_73414_c);
p_73273_1_.write(this.field_73411_d);
func_73270_a(this.field_73412_e, p_73273_1_);
p_73273_1_.write((int)(this.field_73409_f * 16.0F));
p_73273_1_.write((int)(this.field_73410_g * 16.0F));
p_73273_1_.write((int)(this.field_73416_h * 16.0F));
}
public void func_73279_a(NetHandler p_73279_1_) {
p_73279_1_.func_72472_a(this);
}
public int func_73284_a() {
return 19;
}
public int func_73403_d() {
return this.field_73415_a;
}
public int func_73402_f() {
return this.field_73413_b;
}
public int func_73407_g() {
return this.field_73414_c;
}
public int func_73401_h() {
return this.field_73411_d;
}
public ItemStack func_73405_i() {
return this.field_73412_e;
}
public float func_73406_j() {
return this.field_73409_f;
}
public float func_73404_l() {
return this.field_73410_g;
}
public float func_73408_m() {
return this.field_73416_h;
}
}
| [
"nickparker.stl@gmail.com"
] | nickparker.stl@gmail.com |
d389ef4f1e674ebb2f6123763f8d6b2345da70a1 | d315efb39259f87fc1a50ce6940480a859a4b301 | /SolvedInterviewsQuestionsJava/src/strings/SubstringSearchMethods.java | 92c809f1e5cfb8732711c5487d301caa844cbd81 | [] | no_license | AnoopJS8/DataStructuresAndAlgorithms | 5e4fd48665a44f4b3a60a91fe1098a93127d7221 | 0ffcb6a4d28880ae66a10c3efc5094c05847f581 | refs/heads/master | 2021-01-17T07:09:25.158827 | 2016-07-25T04:38:33 | 2016-07-25T04:38:33 | 53,377,848 | 1 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,406 | java | package strings;
public class SubstringSearchMethods {
public boolean naiveMethod(char[] text,char[] pattern){
int i=0;
int j=0;
int k=0;
while(i<text.length&&j<pattern.length){
if(text[i]==pattern[j]){
i++;
j++;
}else{
j=0;
k++;
i=k;
}
}
if(j==pattern.length){
return true;
}
return false;
}
//Building Prefix array for KMP pattern matching
public int[] prefixArray(char[] pattern){
int[] prefix=new int[pattern.length];
int j=0;
for(int i=1;i<pattern.length;){
if(pattern[i]==pattern[j]){
prefix[i]=j+1;
i++;
j++;
}else{
if(j!=0){
j=prefix[j-1];
}else{
prefix[i]=0;
i++;
}
}
}
return prefix;
}
//KMP ALgo
public boolean KMP(char[] text,char[] pattern){
int[] prefix=prefixArray(pattern);
int i=0;int j=0;
while(i<text.length&&j<pattern.length){
if(text[i]==pattern[j]){
i++;j++;
}else{
if(j!=0){
j=prefix[j-1];
}else{
i++;
}
}
}
if(j==pattern.length)
return true;
return false;
}
public static void main(String[] args) {
// TODO Auto-generated method stub
String str = "cvbnm";
String subString = "bn";
SubstringSearchMethods m = new SubstringSearchMethods();
boolean result = m.KMP(str.toCharArray(), subString.toCharArray());
System.out.print(result);
}
}
| [
"anoop.jyoti88@gmail.com"
] | anoop.jyoti88@gmail.com |
b432d6fa0f95cfd32387c2e86ee51e595d7fc163 | 8532623bd3221b27625514a651710a4a189d9f3c | /src/org/teragrid/portal/filebrowser/applet/ui/tree/AnimatedTreeUI.java | ac4a714983910a78a44d30411131bea88371f0ad | [] | no_license | maytaldahan/filemanager | a8a7be80a4cca7083f72e248d028397b644632e5 | 3e9219246bd89de6b01b98c7bad55f61fe7c9200 | refs/heads/master | 2021-01-17T05:02:48.737340 | 2012-12-14T18:14:48 | 2012-12-14T18:14:48 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 7,872 | java | package org.teragrid.portal.filebrowser.applet.ui.tree;
/**
* Copyright Neil Cochrane 2006
*/
import java.awt.Graphics;
import java.awt.Rectangle;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.awt.image.BufferedImage;
import javax.swing.JComponent;
import javax.swing.JViewport;
import javax.swing.Timer;
import javax.swing.plaf.basic.BasicTreeUI;
import javax.swing.tree.TreePath;
/**
* Animates the expansion and collapse of tree nodes.
*
* Painting is hijacked after the user expands/collapses a node. Images are
* copied from the expanded tree and used to composite a new image of the
* lower part slowly sliding out from beneath the top part.
*/
public class AnimatedTreeUI extends BasicTreeUI
{
private BufferedImage _topImage;
private BufferedImage _bottomImage;
private BufferedImage _compositeImage;
private int _offsetY; // amount to offset bottom image position during animation
private int _subTreeHeight; // height of newly exposed subtree
private Timer _timer;
private ActionListener _timerListener;
private enum AnimationState {EXPANDING, COLLAPSING, NOT_ANIMATING};
private AnimationState _animationState;
private float _animationComplete = 0f; // animation progresses 1f -> 0f
public static float ANIMATION_SPEED = 0.66f; // nearer 1f = faster, 0f = slower
/** Creates a new instance of AnimatedTree */
public AnimatedTreeUI() {
super();
_animationState = AnimatedTreeUI.AnimationState.NOT_ANIMATING;
_timerListener = new TimerListener();
_timer = new Timer(1000/90, _timerListener);
}
/**
* All expand and collapsing done by the UI comes through here.
* Use it to trigger the start of animation
* @param path
*/
protected void toggleExpandState(TreePath path) {
if (_animationState != AnimatedTreeUI.AnimationState.NOT_ANIMATING)
return;
_animationComplete = 1f;
boolean state = !tree.isExpanded(path);
if (state){
super.toggleExpandState(path);
_subTreeHeight = _getSubTreeHeight(path);
_createImages(path);
_animationState = AnimatedTreeUI.AnimationState.EXPANDING;
}
else{
_subTreeHeight = _getSubTreeHeight(path);
_createImages(path);
super.toggleExpandState(path);
_animationState = AnimatedTreeUI.AnimationState.COLLAPSING;
}
_updateCompositeImage();
_timer.restart();
}
/**
* Grab two images from the tree. The bit below the expanded node
* (_bottomImage), and the rest above it (_topImage)
*/
private void _createImages(TreePath path){
int h = tree.getPreferredSize().height;
int w = tree.getPreferredSize().width;
BufferedImage baseImage = new BufferedImage(w, h, BufferedImage.TYPE_INT_RGB);
Graphics g = baseImage.getGraphics();
tree.paint(g);
// find the next row, this is where we take the overlay image from
int row = tree.getRowForPath(path)+1;
_offsetY = tree.getRowBounds(row).y;
_topImage = new BufferedImage(tree.getWidth(),
_offsetY, BufferedImage.TYPE_INT_RGB);
Graphics topG = _topImage.getGraphics();
topG.drawImage(baseImage,
0, 0, w, _offsetY, // dest
0, 0, w, _offsetY, // src
null);
_bottomImage = new BufferedImage(w,
baseImage.getHeight() - _offsetY, BufferedImage.TYPE_INT_RGB);
Graphics bottomG = _bottomImage.getGraphics();
bottomG.drawImage(baseImage,
0, 0, w, baseImage.getHeight() - _offsetY, // dest
0, _offsetY, w, baseImage.getHeight(), // src
null);
_compositeImage = new BufferedImage(w, h, BufferedImage.TYPE_INT_RGB);
g.dispose();
topG.dispose();
bottomG.dispose();
}
/**
* create image to paint when hijacked, by painting the lower hald of the
* image offset by an amount determined by the animation. Then paint the
* top part of the tree over the top, so some of the bottom peeks out.
*/
private void _updateCompositeImage(){
Graphics g = _compositeImage.getGraphics();
g.setColor(tree.getBackground());
g.fillRect(0, 0, _compositeImage.getWidth(), _compositeImage.getHeight());
int yOff = (int)(((float)_subTreeHeight) * (_animationComplete));
if (_animationState == AnimatedTreeUI.AnimationState.COLLAPSING)
yOff = _subTreeHeight - yOff;
int dy1 = _offsetY - yOff;
g.drawImage(_bottomImage, 0, dy1, null);
g.drawImage(_topImage, 0, 0, null);
g.dispose();
}
private boolean _isAnimationComplete(){
switch(_animationState){
case COLLAPSING:
case EXPANDING:
return _animationComplete * _offsetY < 1.3f;
}
return true;
}
/**
* get the height of the sub tree by measuring from the location of the first
* child in the subtree to the bottom of its last sibling
* The sub tree should be expanded for this to work correctly.
*/
public int _getSubTreeHeight(TreePath path)
{
if (path.getParentPath() == null)
return 0;
Object origObj = path.getLastPathComponent();
if (getModel().getChildCount(origObj) == 0)
return 0;
Object firstChild = getModel().getChild(origObj, 0);
Object lastChild = getModel().getChild(origObj, getModel().getChildCount(origObj)-1);
TreePath firstPath = path.pathByAddingChild(firstChild);
TreePath lastPath = path.pathByAddingChild(lastChild);
int topFirst = getPathBounds(tree, firstPath).y;
int bottomLast = getPathBounds(tree, lastPath).y + getPathBounds(tree, lastPath).height;
int height = bottomLast - topFirst;
return height;
}
private class TimerListener implements ActionListener{
public void actionPerformed(ActionEvent actionEvent) {
_animationComplete *= ANIMATION_SPEED;
if (_isAnimationComplete()){
_animationState = AnimatedTreeUI.AnimationState.NOT_ANIMATING;
_timer.stop();
}
else {
_updateCompositeImage();
}
tree.repaint();
}
}
// overridden because the default clipping routine gives a NPE
// when the painting is hijacked.
public void update(Graphics g, JComponent c) {
if (c.isOpaque()) {
g.setColor(c.getBackground());
g.fillRect(0, 0, c.getWidth(), c.getHeight());
}
if (_animationState != AnimatedTreeUI.AnimationState.NOT_ANIMATING) {
if (c.getParent() instanceof JViewport){
JViewport vp = (JViewport)c.getParent();
Rectangle visibleR = vp.getViewRect();
g.setClip(
visibleR.x,
visibleR.y,
visibleR.width,
visibleR.height);
} else {
g.setClip(0, 0,
_compositeImage.getWidth(),
_compositeImage.getHeight());
}
}
paint(g, c);
}
// Hijack painting when animating
public void paint(Graphics g, JComponent c) {
if (_animationState != AnimatedTreeUI.AnimationState.NOT_ANIMATING){
g.drawImage(_compositeImage,
0,
0,
null);
return;
}
else
super.paint(g, c);
}
}
| [
"dooley@tacc.utexas.edu"
] | dooley@tacc.utexas.edu |
5171a72445f96753d29c474ca2f952342657ffd3 | f50046326cdf9ee9be4d7206fa9dc945a38532a3 | /moon-ware/src/main/java/com/github/moon/ware/entity/WareOrderTaskDetailEntity.java | ee675246bb513e01d97d43da135a62a740fb27d7 | [] | no_license | RewriteW/moon | d6731d6cdb0dc8401c3c7bf7ddf920fa54f65376 | 03151634b99fe6dbc5de062d63285e1ed946d1c6 | refs/heads/main | 2023-03-12T08:26:24.632345 | 2021-03-01T00:28:00 | 2021-03-01T00:28:00 | 342,416,882 | 0 | 0 | null | 2021-02-26T05:48:46 | 2021-02-26T00:27:56 | JavaScript | UTF-8 | Java | false | false | 718 | java | package com.github.moon.ware.entity;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.util.Date;
import lombok.Data;
/**
* 库存工作单
*
* @author wsg
* @email wsg@gmail.com
* @date 2021-02-26 16:16:04
*/
@Data
@TableName("wms_ware_order_task_detail")
public class WareOrderTaskDetailEntity implements Serializable {
private static final long serialVersionUID = 1L;
/**
* id
*/
@TableId
private Long id;
/**
* sku_id
*/
private Long skuId;
/**
* sku_name
*/
private String skuName;
/**
* 购买个数
*/
private Integer skuNum;
/**
* 工作单id
*/
private Long taskId;
}
| [
"wushigao@166.com"
] | wushigao@166.com |
efcba4a8fff5fbed53284c1e02867f844f0dd956 | 5aefed117dfb1016976d23e64f366be8b147cd74 | /core/src/com/sugurugreg/game/sprites/Bird.java | 258ceb540374a68c28f2c156d15b05ae531ff456 | [] | no_license | Suguru-Tokuda/SkiGame | c043394afd86d2b9cdcc3587bcd1c99c5da2914a | 3eefc2b6ee5f04d1545573c978eae8ccd98d119a | refs/heads/master | 2021-01-13T01:48:26.114220 | 2017-03-02T04:15:48 | 2017-03-02T04:15:48 | 81,523,420 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,638 | java | package com.sugurugreg.game.sprites;
import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.graphics.g2d.TextureRegion;
import com.badlogic.gdx.math.Rectangle;
import com.badlogic.gdx.math.Vector3;
/**
* Created by Suguru on 2/10/17.
*/
public class Bird {
private static final int GRAVITY = -15;
private static final int MOVEMENT = 100;
private Vector3 position;
private Vector3 velocity;
private Rectangle bounds;
private Animation birdAnimation;
private Texture texture;
private Texture bird;
public Bird(int x, int y) {
position = new Vector3(x, y, 0);
velocity = new Vector3(0, 0, 0);
texture = new Texture("birdanimation.png");
birdAnimation = new Animation(new TextureRegion(texture), 3, 0);
bounds = new Rectangle(x, y, texture.getWidth() / 3, texture.getHeight());
}
public void update(float dt) {
birdAnimation.update(dt);
if (position.y > 0) {
velocity.add(0, GRAVITY, 0);
}
velocity.add(0, GRAVITY, 0);
velocity.scl(dt);
position.add(MOVEMENT * dt, velocity.y, 0);
if(position.y < 0) {
position.y = 0;
}
velocity.scl(1/dt);
bounds.setPosition(position.x, position.y);
}
public TextureRegion getTexture() {
return birdAnimation.getFrame();
}
public Vector3 getPosition() {
return position;
}
public void jump() {
velocity.y = 250;
}
public Rectangle getBounds() {
return bounds;
}
public void dispose() {
texture.dispose();
}
}
| [
"suguru.tokuda@gmail.com"
] | suguru.tokuda@gmail.com |
317be3b6404fc6b305e0cba86ac3e68632946e32 | bb948229c88575fd098ab8b06643ba86f6d31369 | /EventosMadrid/app/src/main/java/com/sfaci/eventos/activities/MapaActivity.java | 0bfd7ac4ba6873b938741400b918efdaf4a0dc42 | [] | no_license | codeandcoke/android-ejercicios | a94a19577257374ecc3b93b5d95921dc63a5959a | 3e6e42b9bf554b4619f74d5b7a77ebd5fb607370 | refs/heads/master | 2021-04-26T23:07:23.418552 | 2019-11-26T18:50:03 | 2019-11-26T18:50:03 | 123,933,868 | 1 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,432 | java | package com.sfaci.eventos.activities;
import android.app.Activity;
import android.content.Intent;
import android.support.annotation.NonNull;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import com.mapbox.mapboxsdk.MapboxAccountManager;
import com.mapbox.mapboxsdk.annotations.MarkerOptions;
import com.mapbox.mapboxsdk.camera.CameraPosition;
import com.mapbox.mapboxsdk.camera.CameraUpdateFactory;
import com.mapbox.mapboxsdk.geometry.LatLng;
import com.mapbox.mapboxsdk.maps.MapView;
import com.mapbox.mapboxsdk.maps.MapboxMap;
import com.mapbox.mapboxsdk.maps.OnMapReadyCallback;
import com.sfaci.eventos.R;
public class MapaActivity extends Activity
implements OnMapReadyCallback, MapboxMap.OnMapClickListener {
MapView mapa;
MapboxMap mapaBox;
double latitud, longitud;
String nombre;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
MapboxAccountManager.start(this, "pk.eyJ1Ijoic2ZhY2kiLCJhIjoiY2pwdTZiNDcxMDQ3NTQ4cXJicW51a2VjMSJ9.eeBDqqDQ8ELlz34avq9awg");
Intent intent = getIntent();
nombre = intent.getStringExtra("nombre");
latitud = intent.getDoubleExtra("latitud", 0);
longitud = intent.getDoubleExtra("longitud", 0);
setContentView(R.layout.activity_mapa);
mapa = (MapView) findViewById(R.id.mapa);
mapa.onCreate(savedInstanceState);
mapa.getMapAsync(this);
}
@Override
public void onMapReady(MapboxMap mapboxMap) {
mapaBox = mapboxMap;
mapaBox.addMarker(new MarkerOptions()
.setPosition(new LatLng(latitud, longitud))
.setTitle(nombre));
CameraPosition posicion = new CameraPosition.Builder()
.target(new LatLng(latitud, longitud)) // Fija la posición
.zoom(15) // Fija el nivel de zoom
.tilt(30) // Fija la inclinación de la cámara
.build();
mapaBox.animateCamera(
CameraUpdateFactory.newCameraPosition(
posicion), 7000);
addListener();
}
private void addListener() {
mapaBox.setOnMapClickListener(this);
}
@Override
public void onMapClick(@NonNull LatLng point) {
mapaBox.addMarker(new MarkerOptions()
.position(point)
.title("Eiffel Tower")
);
}
}
| [
"santiago.faci@gmail.com"
] | santiago.faci@gmail.com |
01defeeae452b33bc182f43e85665b43fb931198 | 73b0455759b35cc73ebe4f08079a1bef1ebd889f | /src/model/ServiceProduct2.java | a04b6dccb4d4489145ce377fb6f72564f8a29ad7 | [] | no_license | HugoPDF5/qualidade-SW | 57d35f343b794452ef6bf2689dd0f5c46cf9e48e | 4c589a3b69a9d333d1bfc2d7c344d44697e6b35b | refs/heads/master | 2023-07-13T16:33:40.727307 | 2021-09-02T03:44:36 | 2021-09-02T03:44:36 | 396,818,059 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,313 | java | package model;
import java.util.ArrayList;
import exception.ServiceException;
public class ServiceProduct2 {
private ArrayList<ServiceItem> itens = new ArrayList<ServiceItem>();
public ArrayList<ServiceItem> getItens() {
return itens;
}
public void addItem(ServiceItem item) throws ServiceException {
if (item != null) {
this.itens.add(item);
} else {
throw new ServiceException(Service.CANT_ADD_NULL_ITEM_TO_SERVICE);
}
}
/**
* Get the service itens which is courses
* @return An Array of ServiceItem with the courses only
*/
public ArrayList<ServiceItem> getCourses() {
ArrayList<ServiceItem> items = itens;
ArrayList<ServiceItem> courses = new ArrayList<ServiceItem>();
for (ServiceItem item : items) {
boolean isCourse = item.getClass().equals(Course.class);
if (isCourse) {
courses.add(item);
}
}
return courses;
}
/**
* Get the service itens which is packages
* @return An Array of ServiceItem with the packages only
*/
public ArrayList<ServiceItem> getPackages() {
ArrayList<ServiceItem> items = itens;
ArrayList<ServiceItem> packages = new ArrayList<ServiceItem>();
for (ServiceItem item : items) {
boolean isPackage = item.getClass().equals(Package.class);
if (isPackage) {
packages.add(item);
}
}
return packages;
}
} | [
"hugopatricio51@gmail.com"
] | hugopatricio51@gmail.com |
2a946caf1bdca5cc204f67e63f6e5f6a830b452c | 55d97b5f5f18d4414dad5a09dd83a4553151e26d | /src/main/java/hu/elte/cinema/converter/dto/SeatDtoConverter.java | b6b2c9dd2652b99d1af3d06463b52bbe0b94d18e | [] | no_license | CusterSquad/custer-cinema | 6bed53e2d64dec4de1e4670c445fdde91c77c4e3 | 1cd8e5e6aa936d35a589971d19ecb1d3a4fbcd03 | refs/heads/master | 2021-01-20T16:56:31.441792 | 2017-09-18T18:37:54 | 2017-09-18T18:37:54 | 82,842,499 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 577 | java | package hu.elte.cinema.converter.dto;
import hu.elte.cinema.dto.SeatDto;
import hu.elte.cinema.model.Seat;
import org.springframework.core.convert.converter.Converter;
import org.springframework.stereotype.Component;
@Component
public class SeatDtoConverter implements Converter<Seat, SeatDto> {
@Override
public SeatDto convert(Seat seat) {
SeatDto result = new SeatDto();
result.setId(seat.getId());
result.setX(seat.getX());
result.setY(seat.getY());
result.setReserved(seat.getReserved());
return result;
}
}
| [
"s.wap.elte@gmail.com"
] | s.wap.elte@gmail.com |
e3c425eefe75490efb04d793c4bcbb285859026d | c156463cf82d43fff75cd484b0884a6b99404aa2 | /ZeroToHero1/src/Object____Practice/Mobile_Application_TEST.java | fc722c08e1884b34549f49c6694cf707c6226ac6 | [] | no_license | bamboo1991/ZeroToHero1 | 39d71380d5e8f96beb4c4301cb3571b759d48a55 | 84402e09e63e176d5129f0460fd6087d218dabd8 | refs/heads/master | 2022-07-10T19:30:33.958922 | 2020-04-04T04:33:01 | 2020-04-04T04:33:01 | 241,712,319 | 0 | 1 | null | 2020-10-13T20:23:23 | 2020-02-19T19:56:37 | Java | UTF-8 | Java | false | false | 3,013 | java | package Object____Practice;
import java.util.Scanner;
public class Mobile_Application_TEST{
public static void main(String[] args) {
Scanner input = new Scanner(System.in);
Mobile_Aplication phone = new Mobile_Aplication();
System.out.println("Welcome to your contact list application");
System.out.println("please enter your name");
String name=input.next();
phone.personName=name;
System.out.println("please enter your passcode");
String code1= input.next();
phone.login("1234");
int exit=0;
do {
phone.instructions();
System.out.println("what instruction you want?");
int steps = input.nextInt();
switch (steps){
case 1:
System.out.println("enter your passcode");
String code =input.next();
phone.login(code);
break;
case 2:
phone.listOfContacts();
break;
case 3:
System.out.println("please add contact, enter name first");
String addName = input.next();
System.out.println("enter phone number");
String addPhoneNumber = input.next();
phone.addContacts(addName,addPhoneNumber);
break;
case 4:
System.out.println("please enter old name");
String oldName = input.next();
System.out.println("please enter your new name");
String newName=input.next();
phone.updateContacts(oldName,newName);
break;
case 5:
System.out.println("enter your old number");
String oldPhoneNum =input.next();
System.out.println("please enter new number");
String newNum = input.next();
phone.updatePhoneNum(oldPhoneNum,newNum);
break;
case 6:
System.out.println("please enter the name to remove from contact list");
String removeName=input.next();
phone.removeContacts(removeName);
break;
case 7:
System.out.println("please enter phone number");
String phoneNum = input.next();
System.out.println(phone.searchPhone(phoneNum));
break;
case 8:
System.out.println("please enter name to search");
String searchingName = input.next();
System.out.println(phone.searchName(searchingName));
break;
case 9:
exit=9;
break;
}
}while (exit!=9);
System.out.println("Thank you for using the Phone");
}
}
| [
"stamovuber@gmail.com"
] | stamovuber@gmail.com |
74ff3511a4c69c603e2ab299f4b444a6a757ec81 | 69b2284d7c60f1f28084e1884f68c42c372c49db | /src/org/utcluj/bpel/BPELInvoke.java | d899565e5c22bac5c2a7144a115768fc65b1a9ae | [] | no_license | mrlini/QoSoptimization | 431e4760bfd306f81051ed6240c03b763d0c45b1 | 759e1adad980ad17b55b8921fccae0623ae2d8fe | refs/heads/master | 2021-01-10T06:11:28.289204 | 2017-05-05T18:06:55 | 2017-05-05T18:06:55 | 43,005,811 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 464 | java | package org.utcluj.bpel;
/**
*
* This activity is used to call Web Services offered by service providers.
*
* @see <a href="http://docs.oasis-open.org/wsbpel/2.0/wsbpel-specification-draft.html#_Toc143402873">Web Services Business Process Execution Language Version 2.0</a>
*
* @author Florin Pop
*
*/
public class BPELInvoke extends BPELActivity {
/**
* The service type. This is not part of the BPEL specification.
*/
public String type;
}
| [
"mihsuciu@gmail.com"
] | mihsuciu@gmail.com |
e28863f191690798dae653151d3400b21cedb32a | adea4529c3f0756567a8871157c6b4a91cdeb25d | /app/src/main/java/com/example/vrushank/multibhashi/Rest/ApiInterface.java | 8b215b1fac072d87aa8f92d06272c730128702dd | [] | no_license | vrush03/Multibhashi2 | 82237ef2d18fb54bc776ce43772267654b4059f8 | dd86512628bac22897e9ae0e5ed311598667609a | refs/heads/master | 2021-01-19T10:17:12.010936 | 2017-04-13T20:43:55 | 2017-04-13T20:43:55 | 87,848,796 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 294 | java | package com.example.vrushank.multibhashi.Rest;
import com.example.vrushank.multibhashi.Model.ApiResponse;
import retrofit2.Call;
import retrofit2.http.GET;
/**
* Created by vrushank on 10/4/17.
*/
public interface ApiInterface {
@GET("bins/hoo8n/")
Call<ApiResponse> getData();
}
| [
"uvrushank21@gmail.com"
] | uvrushank21@gmail.com |
c773889c16f33f5adf866d6cdd759bd4fb235969 | 129f58086770fc74c171e9c1edfd63b4257210f3 | /src/testcases/CWE690_NULL_Deref_From_Return/CWE690_NULL_Deref_From_Return__System_getProperty_equals_22a.java | 3eaa2640f16ca23ec2206158bb14adf548fb76e9 | [] | no_license | glopezGitHub/Android23 | 1bd0b6a6c7ce3c7439a74f1e4dcef2c4c0fac4ba | 6215d0684c4fbdc7217ccfbedfccfca69824cc5e | refs/heads/master | 2023-03-07T15:14:59.447795 | 2023-02-06T13:59:49 | 2023-02-06T13:59:49 | 6,856,387 | 0 | 3 | null | 2023-02-06T18:38:17 | 2012-11-25T22:04:23 | Java | UTF-8 | Java | false | false | 3,652 | java | /* TEMPLATE GENERATED TESTCASE FILE
Filename: CWE690_NULL_Deref_From_Return__System_getProperty_equals_22a.java
Label Definition File: CWE690_NULL_Deref_From_Return.label.xml
Template File: sources-sinks-22a.tmpl.java
*/
/*
* @description
* CWE: 690 Unchecked return value is null, leading to a null pointer dereference.
* BadSource: System_getProperty Set data to return of System.getProperty
* GoodSource: Set data to fixed, non-null String
* Sinks: equals
* GoodSink: Call equals() on string literal (that is not null)
* BadSink : Call equals() on possibly null object
* Flow Variant: 22 Control flow: Flow controlled by value of a public static variable. Sink functions are in a separate file from sources.
*
* */
package testcases.CWE690_NULL_Deref_From_Return;
import testcasesupport.*;
import java.sql.*;
import javax.servlet.http.*;
public class CWE690_NULL_Deref_From_Return__System_getProperty_equals_22a extends AbstractTestCase
{
/* The public static variable below is used to drive control flow in the sink function.
The public static variable mimics a global variable in the C/C++ language family. */
public static boolean bad_public_static = false;
public void bad() throws Throwable
{
String data;
/* POTENTIAL FLAW: data may be set to null */
data = System.getProperty("CWE690");
bad_public_static = true;
(new CWE690_NULL_Deref_From_Return__System_getProperty_equals_22b()).bad_sink(data );
}
/* The public static variables below are used to drive control flow in the sink functions.
The public static variable mimics a global variable in the C/C++ language family. */
public static boolean goodB2G1_public_static = false;
public static boolean goodB2G2_public_static = false;
public static boolean goodG2B_public_static = false;
public void good() throws Throwable
{
goodB2G1();
goodB2G2();
goodG2B();
}
/* goodB2G1() - use badsource and goodsink by setting the static variable to false instead of true */
private void goodB2G1() throws Throwable
{
String data;
/* POTENTIAL FLAW: data may be set to null */
data = System.getProperty("CWE690");
goodB2G1_public_static = false;
(new CWE690_NULL_Deref_From_Return__System_getProperty_equals_22b()).goodB2G1_sink(data );
}
/* goodB2G2() - use badsource and goodsink by reversing the blocks in the if in the sink function */
private void goodB2G2() throws Throwable
{
String data;
/* POTENTIAL FLAW: data may be set to null */
data = System.getProperty("CWE690");
goodB2G2_public_static = true;
(new CWE690_NULL_Deref_From_Return__System_getProperty_equals_22b()).goodB2G2_sink(data );
}
/* goodG2B() - use goodsource and badsink */
private void goodG2B() throws Throwable
{
String data;
/* FIX: Set data to a fixed, non-null String */
data = "CWE690";
goodG2B_public_static = true;
(new CWE690_NULL_Deref_From_Return__System_getProperty_equals_22b()).goodG2B_sink(data );
}
/* Below is the main(). It is only used when building this testcase on
its own for testing or for building a binary to use in testing binary
analysis tools. It is not used when compiling all the testcases as one
application, which is how source code analysis tools are tested. */
public static void main(String[] args) throws ClassNotFoundException,
InstantiationException, IllegalAccessException
{
mainFromParent(args);
}
}
| [
"guillermo.pando@gmail.com"
] | guillermo.pando@gmail.com |
205509796fa25fcb40bf3e605dd8ca79c2fd04c2 | 132e3b8f56ed5d79c6190b280b93b182948a03a4 | /Sum of numbers using function/Main.java | d2bd7b058cad4231230475d530debf9b0089cb0c | [] | no_license | 15641A0577/Playground | 57799e5f771d92fee818cc38e8953c58e9498951 | 1c4fec506e64b8c732fc8b22ade5d5608672033b | refs/heads/master | 2020-04-26T19:20:33.347728 | 2019-06-11T19:18:53 | 2019-06-11T19:18:53 | 173,771,560 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 445 | java | import java.util.Scanner;
class Main{
public static void main (String[] args)
{
// Type your code here
Scanner in = new Scanner(System.in);
int n = in.nextInt();
System.out.print(sum_of_numbers(n)); // Function call
}
// Function to find the sum of numbers
public static int sum_of_numbers(int y)
{
int sum = 0;
for(int i = 1; i<= y; i++)
{
sum = sum + i;
}
return sum;
}
} | [
"40996081+15641A0577@users.noreply.github.com"
] | 40996081+15641A0577@users.noreply.github.com |
bc8fc84dea615d363394f6fcdcea817245494fba | dddd612dc53ff16b82cba7a56c956542bb9bc1ff | /Ders4/src/Kosulluİfadeler/İfElseApp.java | 0e33647198fc73e42a45844509596fbc7541f454 | [] | no_license | Upaksoy/Bilgeadam | 8cc60c5b5a42033f58528efea1a65ba4b953eda7 | d8fe51f60f3744cea708d7eb90a3d1f53d8d6a39 | refs/heads/master | 2020-04-18T22:04:58.531317 | 2019-03-03T11:11:42 | 2019-03-03T11:11:42 | 167,783,813 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 608 | java | package Kosulluİfadeler;
import java.util.Scanner;
public class İfElseApp {
public static void main(String[] args) {
// if parantez içerisindeki değer true ise blok içerisine girer.
//int a=5;
//if (a==5) {
//System.out.println("a değişkeni 5'e eşittir.");
// System.out.println("good bye...");
Scanner scanner=new Scanner(System.in);
System.out.println("bir sayı giriniz");
int sayi=scanner.nextInt();
if (sayi<10){
System.out.println("girilen sayı 10 dan küçüktür");
}
}
} | [
"ufuk.paksoy@icloud.com"
] | ufuk.paksoy@icloud.com |
345282f0689b15d6d05783ac8701feb037a03be8 | 2b6c5004b2f467d453f6a227306ae9830c1b834f | /lib/test/on2017_08/on2017_08_18_Goldman_Sachs_CodeSprint/Time_Series_Queries/TimeSeriesQueries.java | 0c4c82dd4a645e663290b6807a3add2cd69c67b8 | [] | no_license | gargoris/yaal | 83edf0bb36627aa96ce0e66c836d56f92ec5f842 | 4f927166577b16faa99c7d3e6d870f59d6977cb3 | refs/heads/master | 2020-12-21T04:48:30.470138 | 2020-04-19T11:25:19 | 2020-04-19T11:25:19 | 178,675,652 | 0 | 0 | null | 2019-03-31T10:54:25 | 2019-03-31T10:54:24 | null | UTF-8 | Java | false | false | 2,211 | java | package on2017_08.on2017_08_18_Goldman_Sachs_CodeSprint.Time_Series_Queries;
import net.egork.generated.collections.list.IntArrayList;
import net.egork.generated.collections.list.IntList;
import net.egork.io.InputReader;
import net.egork.io.OutputWriter;
public class TimeSeriesQueries {
public void solve(int testNumber, InputReader in, OutputWriter out) {
int n = in.readInt();
int q = in.readInt();
int[] t = in.readIntArray(n);
int[] p = in.readIntArray(n);
IntList up = new IntArrayList();
for (int i = 0; i < n; i++) {
if (up.size() == 0 || p[up.last()] < p[i]) {
up.add(i);
}
}
IntList down = new IntArrayList();
for (int i = n - 1; i >= 0; i--) {
if (down.size() == 0 || p[down.last()] < p[i]) {
down.add(i);
}
}
down.inPlaceReverse();
for (int i = 0; i < q; i++) {
int type = in.readInt();
int value = in.readInt();
if (type == 1) {
int left = 0;
int right = up.size();
while (left < right) {
int middle = (left + right) >> 1;
if (p[up.get(middle)] >= value) {
right = middle;
} else {
left = middle + 1;
}
}
if (left == up.size()) {
out.printLine(-1);
} else {
out.printLine(t[up.get(left)]);
}
} else {
int left = 0;
int right = down.size();
while (left < right) {
int middle = (left + right) >> 1;
if (t[down.get(middle)] >= value) {
right = middle;
} else {
left = middle + 1;
}
}
if (left == down.size()) {
out.printLine(-1);
} else {
out.printLine(p[down.get(left)]);
}
}
}
}
}
| [
"egor@egork.net"
] | egor@egork.net |
6b47c591cc938bc35a5586bc9d85756af60838a8 | 2b4f4b41e8a28a5024d41223b2876c87ee1eaa1a | /Eis-portlet/docroot/WEB-INF/service/com/idetronic/eis/NoSuchProjectStrategyException.java | b8c155d6fbb751cc9ddcfdcf2aebd5fd09f57b75 | [] | no_license | merbauraya/lportal6.2 | 48bb99e5b6b937fce6e20e5c76303c4982bcad02 | e7446107fd793a8ab557b4748f3214a83dbe6ce6 | refs/heads/master | 2021-01-21T19:51:52.682108 | 2017-08-08T14:42:38 | 2017-08-08T14:42:38 | 92,167,957 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,076 | java | /**
* Copyright (c) 2000-2013 Liferay, Inc. All rights reserved.
*
* This library 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 library is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
* details.
*/
package com.idetronic.eis;
import com.liferay.portal.NoSuchModelException;
/**
* @author Mazlan Mat
*/
public class NoSuchProjectStrategyException extends NoSuchModelException {
public NoSuchProjectStrategyException() {
super();
}
public NoSuchProjectStrategyException(String msg) {
super(msg);
}
public NoSuchProjectStrategyException(String msg, Throwable cause) {
super(msg, cause);
}
public NoSuchProjectStrategyException(Throwable cause) {
super(cause);
}
} | [
"mazlan.mat@gmail.com"
] | mazlan.mat@gmail.com |
506f58ee6c025c6d3822f38f6c940f986648947e | d3c7040ab7756ca9d247a580eab2a7d3522ff9f5 | /dbinspector/src/main/java/im/dino/dbinspector/DbInspector.java | 65552258cf1498017c9ab2e6c643123320df9b05 | [
"Apache-2.0"
] | permissive | leandrofavarin/android_dbinspector | 90126692ff63640570f00b553b3ff0aaf54ea738 | e81497db95c1514c90c24e39c998070777108817 | refs/heads/master | 2021-01-23T03:12:43.821292 | 2017-03-27T09:06:14 | 2017-03-27T09:06:14 | 86,057,361 | 0 | 0 | null | 2017-03-24T10:42:35 | 2017-03-24T10:42:35 | null | UTF-8 | Java | false | false | 361 | java | package im.dino.dbinspector;
import android.content.Context;
import android.content.Intent;
import im.dino.dbinspector.activities.DbInspectorActivity;
public final class DbInspector {
public static Intent getLaunchIntent(Context context) {
return DbInspectorActivity.launch(context)
.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
}
}
| [
"lfavarin@gmail.com"
] | lfavarin@gmail.com |
6b147012f5a3228d4510442f242fc29eab17f35d | c2ce04545374ce13047e9c6069e956ed2ca90ee7 | /src/Placer.java | ce1ab9e256f21caa2c4536d48b5b1b4c7ce661bf | [] | no_license | jyyzlzy/bin_packing2 | 09eb43e2ddd5890028af542ad5e41071b91fb15a | 9672518f3e2d2a4570f2927c16fef91c08f86913 | refs/heads/master | 2023-08-04T21:54:30.602183 | 2021-09-08T15:55:10 | 2021-09-08T15:55:10 | 404,372,207 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 6,112 | java | package cp_heuristics;
import java.util.Vector;
public class Placer {
public Vector<Place_info> place_item(Vector<Box> box_sequence, double[] bin_dimensions, Vector<Bin> bins) {
// results are stored in bins
bins.clear();
Vector<Place_info> how_to_place = new Vector<Place_info>();
// if no box needs to be placed
if (box_sequence.size() == 0) {
return how_to_place;
}
// initialization
Place_info place_info;
Bin bin_selected = null;
Box box = null, box_to_place = null;
double[] best_ems;
Box.Orientation best_ori = null;
int next_bin_id = 0;
// find the min_w
int n = box_sequence.size();
double[] min_w = new double[n];
double min_w_upper_bound = 1.0+Math.max(Math.max(bin_dimensions[0], bin_dimensions[1]), bin_dimensions[2]);
min_w[n-1] = min_w_upper_bound;
for (int i=n-2; i>=0; i--) {
min_w[i] = Math.min(min_w[i+1], box_sequence.elementAt(i+1).get_shortest_edge());
}
// place boxes one by one
for (int i=0; i<box_sequence.size(); i++) {
box = box_sequence.elementAt(i);
// find an existing bin to place the box
best_ems = new double[3];
best_ems[0] = -1; // -1 marks invalidity
for (int j=0; j<bins.size(); j++) {
best_ori = this.DFTRC(box, bins.elementAt(j), best_ems, "allowed");
if (best_ems[0] >= 0) {
bin_selected = bins.elementAt(j);
break;
}
}
// if no bin is good for the box
if (best_ems[0] == -1) {
bin_selected = new Bin(next_bin_id, bin_dimensions);
next_bin_id++;
bins.add(bin_selected);
best_ori = this.DFTRC(box, bin_selected, best_ems, "allowed");
}
// update the place information
place_info = new Place_info();
place_info.set_ems(best_ems);
place_info.bin_id = bin_selected.get_id();
place_info.best_ori = best_ori;
how_to_place.add(place_info);
// place the box into the selected bin
box_to_place = box.rotate(best_ori);
box_to_place.set_position(best_ems);
bin_selected.update(box_to_place, min_w[i]);
}
// return result
return how_to_place;
}
public Bin place_item_single_type(Box box_template, double[] bin_dimensions) {
// returns a bin that contains as many boxes as possible
// initialization
Bin bin = new Bin(0, bin_dimensions);
Box box = null, box_to_place = null;
double[] best_ems;
Box.Orientation best_ori = null;
// find the min_w
double min_w = box_template.get_shortest_edge();
// place boxes with preferred orientations
while (true) {
box = box_template.duplicate();
// find an existing bin to place the box
best_ems = new double[3];
best_ems[0] = -1; // -1 marks invalidity
best_ori = this.DFTRC(box, bin, best_ems, "preferred");
if (best_ems[0] < 0) { // no where to place
break;
}
// place the box into the selected bin
box_to_place = box.rotate(best_ori);
box_to_place.set_position(best_ems);
bin.update(box_to_place, min_w);
}
// place boxes with all allowed orientations
while (true) {
box = box_template.duplicate();
// find an existing bin to place the box
best_ems = new double[3];
best_ems[0] = -1; // -1 marks invalidity
best_ori = this.DFTRC(box, bin, best_ems, "allowed");
if (best_ems[0] < 0) { // no where to place
break;
}
// place the box into the selected bin
box_to_place = box.rotate(best_ori);
box_to_place.set_position(best_ems);
bin.update(box_to_place, min_w);
}
// return result
return bin;
}
private Box.Orientation DFTRC(Box box, Bin bin, double[] best_ems, String method) {
//System.out.println("run DFTRC");
Box.Orientation best_ori = Box.Orientation.Upright;
best_ems[0] = -1; // -1 marks an invalid ems
double dist_sq;
double max_dist_sq = -1;
Box box_rotated;
double[] bin_dimensions, curr_ems;
double x_plus_w, y_plus_h, z_plus_d, W, H, D;
Vector<double[]> ems = bin.get_ems();
bin_dimensions = bin.get_dimensions();
W = bin_dimensions[0];
H = bin_dimensions[1];
D = bin_dimensions[2];
for (int i=0; i<ems.size(); i++) {
curr_ems = ems.elementAt(i);
box.set_position(curr_ems);
//for (Box.Orientation ori: Box.Orientation.values()) {
Box.Orientation[] ori_to_search;
if (method == "preferred") {
ori_to_search = box.get_preferred_ori();
}
else {
ori_to_search = box.get_allowed_ori();
}
for (Box.Orientation ori: ori_to_search) {
//System.out.printf("%s \n", ori);
box_rotated = box.rotate(ori);
//box_rotated.show();
x_plus_w = box_rotated.get_x_plus_w();
y_plus_h = box_rotated.get_y_plus_h();
z_plus_d = box_rotated.get_z_plus_d();
//System.out.printf("%f, %f, %f \n", x_plus_w, y_plus_h, z_plus_d);
if ((x_plus_w <= W) && (y_plus_h <= H) && (z_plus_d <= D)) {
dist_sq = 1*(W-x_plus_w)*(W-x_plus_w) + 1*(H-y_plus_h)*(H-y_plus_h) + 10*(D-z_plus_d)*(D-z_plus_d);
//box_rotated.show();
//System.out.printf("%f, %f, %f \n", x_plus_w, y_plus_h, z_plus_d);
//System.out.printf("%f, %f, %f \n", W-x_plus_w, H-y_plus_h, D-z_plus_d);
//System.out.printf("dist sq: %f \n", dist_sq);
if (dist_sq > max_dist_sq) {
max_dist_sq = dist_sq;
best_ori = ori;
//System.out.printf("ems %d, dist_sq %f, ori %s \n", i, dist_sq, best_ori);
// copy values to best_ems
best_ems[0] = curr_ems[0];
best_ems[1] = curr_ems[1];
best_ems[2] = curr_ems[2];
}
}
}
}
return best_ori;
}
/*
private double find_min_w(Vector<Box> boxes, int start_idx, double upper_bound) {
double min_w = upper_bound;
for (int i=start_idx; i<boxes.size(); i++) {
min_w = Math.min(min_w, boxes.elementAt(i).get_shortest_edge());
}
return min_w;
}
*/
}
class Place_info {
public Place_info() {
this.best_ems = new double[3];
}
public void set_ems(double[] ems) {
this.best_ems[0] = ems[0];
this.best_ems[1] = ems[1];
this.best_ems[2] = ems[2];
}
public void show() {
System.out.printf("bin id: %d, coordinates: (%f, %f, %f), orientation: %s \n", bin_id, best_ems[0], best_ems[1], best_ems[2], best_ori);
}
public int bin_id;
public double[] best_ems;
public Box.Orientation best_ori;
}
| [
"jyyzlzy@gmail.com"
] | jyyzlzy@gmail.com |
044f199dc4f60057394ca6242cc4e4083455cb48 | fa91450deb625cda070e82d5c31770be5ca1dec6 | /Diff-Raw-Data/10/10_f8f5fb3c3a99be2b0ab8972e42538893958b0920/ConnectionManager/10_f8f5fb3c3a99be2b0ab8972e42538893958b0920_ConnectionManager_t.java | 1b08bbb80cdb3cdb7ddab786c75a531ec1538f06 | [] | 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 | 3,879 | java | package com.topsy.jmxproxy.jmx;
import com.topsy.jmxproxy.JMXProxyServiceConfiguration;
import com.topsy.jmxproxy.core.Host;
import com.yammer.dropwizard.lifecycle.Managed;
import java.util.HashMap;
import java.util.Map;
import java.util.concurrent.Executors;
import java.util.concurrent.ScheduledExecutorService;
import java.util.concurrent.TimeUnit;
import javax.ws.rs.core.Response;
import javax.ws.rs.WebApplicationException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
public class ConnectionManager implements Managed {
private static final Logger LOG = LoggerFactory.getLogger(ConnectionManager.class);
private final JMXProxyServiceConfiguration config;
private Map<String, ConnectionWorker> hosts;
private ScheduledExecutorService purge;
private boolean started = false;
public ConnectionManager(JMXProxyServiceConfiguration config) {
this.config = config;
hosts = new HashMap<String, ConnectionWorker>();
purge = Executors.newSingleThreadScheduledExecutor();
}
public Host getHost(String host) throws WebApplicationException {
return getHost(host, null);
}
public Host getHost(String host, ConnectionCredentials auth) throws WebApplicationException {
if (!config.getAllowedEndpoints().isEmpty() && !config.getAllowedEndpoints().contains(host)) {
throw new WebApplicationException(Response.Status.FORBIDDEN);
}
try {
synchronized (hosts) {
if (hosts.containsKey(host) && !hosts.get(host).checkCredentials(auth)) {
LOG.info("resetting credentials for " + host);
hosts.remove(host).shutdown();
}
if (!hosts.containsKey(host)) {
LOG.info("creating new worker for " + host);
hosts.put(host, new ConnectionWorker(host, auth, config.getCacheDuration()));
}
}
return hosts.get(host).getHost();
} catch (SecurityException e) {
throw new WebApplicationException(Response.Status.UNAUTHORIZED);
} catch (Exception e) {
throw new WebApplicationException(Response.Status.NOT_FOUND);
}
}
public boolean isStarted() {
return started;
}
public void start() {
LOG.info("starting jmx connection manager");
LOG.debug("allowedEndpoints: " + config.getAllowedEndpoints().size());
for (String ae : config.getAllowedEndpoints()) {
LOG.debug(" " + ae);
}
purge.scheduleAtFixedRate(new Runnable() {
@Override
public void run() {
LOG.debug("begin expiring stale hosts");
synchronized (hosts) {
for (Map.Entry<String, ConnectionWorker>hostEntry : hosts.entrySet()) {
if (hostEntry.getValue().isExpired(config.getAccessDuration())) {
LOG.debug("purging " + hostEntry.getKey());
hosts.remove(hostEntry.getKey()).shutdown();
}
}
}
LOG.debug("end expiring stale hosts");
}
}, config.getCleanInterval(), config.getCleanInterval(), TimeUnit.MINUTES);
started = true;
}
public void stop() {
LOG.info("stopping jmx connection manager");
purge.shutdown();
synchronized (hosts) {
for (Map.Entry<String, ConnectionWorker>hostEntry : hosts.entrySet()) {
LOG.debug("purging " + hostEntry.getKey());
hosts.remove(hostEntry.getKey()).shutdown();
}
}
hosts.clear();
started = false;
}
}
| [
"yuzhongxing88@gmail.com"
] | yuzhongxing88@gmail.com |
edcef26c14fe620177bc7528cde25ada7ff02325 | d8d23c6b0b2af190009188dd03aa036473e8b717 | /urule-core/src/main/java/com/bstek/urule/model/decisiontree/TreeNodeType.java | 868cd5d36d369009d4927e77f407cdb24681bdb4 | [
"Apache-2.0",
"LicenseRef-scancode-warranty-disclaimer",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | wuranjia/myRule | 30b3fdb73659221c32f88c968449de0b5cc29ded | 6fd0cd6c13ac23ad7f678dda9def8b553d72901e | refs/heads/master | 2022-12-16T09:45:05.495146 | 2019-10-17T02:10:21 | 2019-10-17T02:10:21 | 215,682,587 | 1 | 0 | Apache-2.0 | 2022-12-10T03:12:54 | 2019-10-17T02:05:48 | JavaScript | UTF-8 | Java | false | false | 926 | java | /*******************************************************************************
* Copyright 2017 Bstek
*
* 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.bstek.urule.model.decisiontree;
/**
* @author Jacky.gao
* @since 2016年3月2日
*/
public enum TreeNodeType {
condition,action,variable;
}
| [
"wuranjia07730@hellobike.com"
] | wuranjia07730@hellobike.com |
c6bf14d3b63e93c4d098dd3ed6ffdbf98fdbe05d | c2fc2a9ec50357cfbd02c5ab1036f8bcd990b199 | /src/Bipartite.java | d5c32a5c8ca0f5940755c1208b13134a46e2f477 | [] | no_license | chris-peng-1244/coursera-programming | 79c7e854202776ada65df3257217d1f781b52f11 | 60a028181167b7c28dc7f96098b7273767d5ec49 | refs/heads/master | 2021-01-25T13:23:45.327200 | 2018-06-16T04:31:43 | 2018-06-16T04:31:43 | 123,563,317 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,463 | java | import java.util.ArrayList;
import java.util.LinkedList;
import java.util.Queue;
import java.util.Scanner;
public class Bipartite {
private static int bipartite(ArrayList<Integer>[] adj) {
//write your code here
int INFINITY = adj.length + 1;
int[] dist = new int[adj.length];
int[] color = new int[adj.length];
for (int i = 0; i < adj.length; i++) {
dist[i] = INFINITY;
color[i] = -1;
}
dist[0] = 0;
color[0] = 0;
Queue<Integer> queue = new LinkedList<>();
queue.add(0);
while (!queue.isEmpty()) {
int u = queue.remove();
int nextColor = color[u] == 0 ? 1 : 0;
ArrayList<Integer> vertices = adj[u];
for (Integer v: vertices) {
if (dist[v] == INFINITY) {
queue.add(v);
dist[v] = dist[u] + 1;
color[v] = nextColor;
} else if (color[v] == color[u]) {
return 0;
}
}
}
return 1;
}
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
int n = scanner.nextInt();
int m = scanner.nextInt();
ArrayList<Integer>[] adj = (ArrayList<Integer>[])new ArrayList[n];
for (int i = 0; i < n; i++) {
adj[i] = new ArrayList<Integer>();
}
for (int i = 0; i < m; i++) {
int x, y;
x = scanner.nextInt();
y = scanner.nextInt();
adj[x - 1].add(y - 1);
adj[y - 1].add(x - 1);
}
System.out.println(bipartite(adj));
}
}
| [
"pengchi1244@gmail.com"
] | pengchi1244@gmail.com |
35c1e87ff461368ad7787b46c8c8cf73107f66f7 | 5641162a472bb56350aca1d2787e472a04a4fa91 | /Boutique/src/main/java/com/example/entity/ShoppingCartItem.java | 034661a571b9f1dd2cd1c364ad097bb9ce998f63 | [] | no_license | ReRekon/Boutique | e9d2609aed459d143d7ab0777da036e77c0e4ef6 | b518493eb392f25ef2451d7fce397bdeff800e99 | refs/heads/R | 2022-12-26T08:08:23.706177 | 2019-08-21T14:03:05 | 2019-08-21T14:03:05 | 196,218,322 | 3 | 1 | null | 2022-12-15T23:44:13 | 2019-07-10T14:16:05 | Java | UTF-8 | Java | false | false | 2,012 | java | package com.example.entity;
import java.math.BigDecimal;
import java.util.Date;
public class ShoppingCartItem {
private int shoppingCartItemId;
private int productId;
private int shoppingCartId;
private int productSpecificationId;
private long number;
private int state;
private String logo;
private BigDecimal finalPrice;
private BigDecimal totalPrice;
public int getProductSpecificationId() {
return productSpecificationId;
}
public void setProductSpecificationId(int productSpecificationId) {
this.productSpecificationId = productSpecificationId;
}
public String getLogo() {
return logo;
}
public void setLogo(String logo) {
this.logo = logo;
}
public BigDecimal getTotalPrice() {
return totalPrice;
}
public void setTotalPrice(BigDecimal totalPrice) {
this.totalPrice = totalPrice;
}
public int getShoppingCartItemId() {
return shoppingCartItemId;
}
public void setShoppingCartItemId(int shoppingCartItemId) {
this.shoppingCartItemId = shoppingCartItemId;
}
public int getProductId() {
return productId;
}
public void setProductId(int productId) {
this.productId = productId;
}
public int getShoppingCartId() {
return shoppingCartId;
}
public void setShoppingCartId(int shoppingCartId) {
this.shoppingCartId = shoppingCartId;
}
public long getNumber() {
return number;
}
public void setNumber(long number) {
this.number = number;
}
public int getState() {
return state;
}
public void setState(int state) {
this.state = state;
}
public BigDecimal getFinalPrice() {
return finalPrice;
}
public void setFinalPrice(BigDecimal finalPrice) {
this.finalPrice = finalPrice;
}
}
| [
"819071732@qq.com"
] | 819071732@qq.com |
bcf76ffbca099b67ffc14db33c9e09b01ed09476 | 22eb7d16cfeed30effe929feac681edfd0af3c76 | /src/main/java/com/mycompany/mockito/reference/documentation/tutorial/User.java | 5e8de280a29448a6275a9475ec37e45ea5f78b4d | [] | no_license | colinbut/learning-mockito | 9bd698f69f98077aff28ee3d648bfc1937d8d43f | 504aa9a37577953f09fd9f09b7fc1fa47aabde57 | refs/heads/master | 2020-06-29T21:41:05.937962 | 2016-08-30T19:45:57 | 2016-08-30T19:45:57 | 66,972,144 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 587 | java | /**
*
*/
package com.mycompany.mockito.reference.documentation.tutorial;
/**
* @author colin
*
*/
public class User {
private int userId;
private String username;
/**
* @return the userId
*/
public int getUserId() {
return userId;
}
/**
* @param userId the userId to set
*/
public void setUserId(int userId) {
this.userId = userId;
}
/**
* @return the username
*/
public String getUsername() {
return username;
}
/**
* @param username the username to set
*/
public void setUsername(String username) {
this.username = username;
}
}
| [
"colinbut@users.noreply.github.com"
] | colinbut@users.noreply.github.com |
bde612490bd40d4221f8106d1f731efb78209673 | bfc3548a7ae9cdced191b6bdd3b6fd5f11378a3d | /src/main/java/edu/axboot/domain/lightpms/guest/Guest.java | d3dd31a6610a326453e2375a8e5d4b8c5cd9626a | [] | no_license | dhyun10/light_PMS | 94aede30b152aba19c3ad4a14f0c180314fde8fb | 29e6506ef1ae48634ce11dfe4ee5b678a4d55eef | refs/heads/master | 2023-05-06T19:10:20.531326 | 2021-05-31T06:57:24 | 2021-05-31T06:57:24 | 370,256,710 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,509 | java | package edu.axboot.domain.lightpms.guest;
import com.chequer.axboot.core.annotations.ColumnPosition;
import edu.axboot.controllers.dto.GuestResponseDto;
import edu.axboot.controllers.dto.ReservationListResponseDto;
import edu.axboot.domain.BaseJpaModel;
import edu.axboot.domain.lightpms.reservation.Reservation;
import lombok.Builder;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;
import org.hibernate.annotations.NotFound;
import org.hibernate.annotations.NotFoundAction;
import javax.persistence.*;
import java.util.List;
@Setter
@Getter
@DynamicInsert
@DynamicUpdate
@Entity
@NoArgsConstructor
@Table(name = "PMS_GUEST")
public class Guest extends BaseJpaModel<Long> {
@Id
@Column(name = "ID", precision = 19, nullable = false)
@GeneratedValue(strategy = GenerationType.IDENTITY)
@ColumnPosition(1)
private Long id;
@Column(name = "GUEST_NM", length = 100, nullable = false)
@ColumnPosition(2)
private String guestNm;
@Column(name = "GUEST_NM_ENG", length = 100)
@ColumnPosition(3)
private String guestNmEng;
@Column(name = "GUEST_TEL", length = 18)
@ColumnPosition(4)
private String guestTel;
@Column(name = "EMAIL", length = 100)
@ColumnPosition(5)
private String email;
@Column(name = "BRTH", length = 10)
@ColumnPosition(6)
private String birth;
@Column(name = "GENDER", length = 20)
@ColumnPosition(7)
private String gender;
@Column(name = "LANG_CD", length = 20)
@ColumnPosition(8)
private String langCd;
@Column(name = "RMK", length = 500)
@ColumnPosition(9)
private String rmk;
@Builder
public Guest(Long id, String guestNm, String guestNmEng,
String guestTel, String email, String birth,
String gender, String langCd) {
this.id = id;
this.guestNm = guestNm;
this.guestNmEng = guestNmEng;
this.guestTel = guestTel;
this.email = email;
this.birth = birth;
this.gender = gender;
this.langCd = langCd;
}
@Override
public Long getId() {
return id;
}
// @OneToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY)
// @NotFound(action = NotFoundAction.IGNORE)
// @JoinColumn(name = "GUEST_ID", referencedColumnName = "ID", insertable = false, updatable = false)
// private List<Reservation> rsvList;
}
| [
"d-hyun10@hanmail.net"
] | d-hyun10@hanmail.net |
c7d0ea3b8143da8d68a455450b3a0c5baca6ee51 | 5c29d6f509ef0f87f288afeb312cd1f126277457 | /src/java/nio/DoubleBuffer.java | e6e8403642719fa002425fd1917f58ac321d98ff | [
"Apache-2.0"
] | permissive | Golde-nchow/jdk-1.7-annotated | d1c30cebbc0b968873b60e0a9cca3e1e85d17d42 | 726f675973e8498ea4afca13393f692e95255b94 | refs/heads/master | 2021-07-14T15:25:05.610358 | 2020-11-02T16:03:08 | 2020-11-02T16:03:08 | 221,722,100 | 0 | 0 | Apache-2.0 | 2019-11-14T14:53:58 | 2019-11-14T14:53:55 | null | UTF-8 | Java | false | false | 28,995 | java | /*
* Copyright (c) 2000, 2008, Oracle and/or its affiliates. All rights reserved.
* ORACLE PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*/
// -- This file was mechanically generated: Do not edit! -- //
package java.nio;
/**
* A double buffer.
*
* <p> This class defines four categories of operations upon
* double buffers:
*
* <ul>
*
* <li><p> Absolute and relative {@link #get() </code><i>get</i><code>} and
* {@link #put(double) </code><i>put</i><code>} methods that read and write
* single doubles; </p></li>
*
* <li><p> Relative {@link #get(double[]) </code><i>bulk get</i><code>}
* methods that transfer contiguous sequences of doubles from this buffer
* into an array; and</p></li>
*
* <li><p> Relative {@link #put(double[]) </code><i>bulk put</i><code>}
* methods that transfer contiguous sequences of doubles from a
* double array or some other double
* buffer into this buffer; and </p></li>
*
*
* <li><p> Methods for {@link #compact </code>compacting<code>}, {@link
* #duplicate </code>duplicating<code>}, and {@link #slice
* </code>slicing<code>} a double buffer. </p></li>
*
* </ul>
*
* <p> Double buffers can be created either by {@link #allocate
* </code><i>allocation</i><code>}, which allocates space for the buffer's
*
*
* content, by {@link #wrap(double[]) </code><i>wrapping</i><code>} an existing
* double array into a buffer, or by creating a
* <a href="ByteBuffer.html#views"><i>view</i></a> of an existing byte buffer.
*
*
*
*
* <p> Like a byte buffer, a double buffer is either <a
* href="ByteBuffer.html#direct"><i>direct</i> or <i>non-direct</i></a>. A
* double buffer created via the <tt>wrap</tt> methods of this class will
* be non-direct. A double buffer created as a view of a byte buffer will
* be direct if, and only if, the byte buffer itself is direct. Whether or not
* a double buffer is direct may be determined by invoking the {@link
* #isDirect isDirect} method. </p>
*
*
*
*
* <p> Methods in this class that do not otherwise have a value to return are
* specified to return the buffer upon which they are invoked. This allows
* method invocations to be chained.
*
*
*
* @author Mark Reinhold
* @author JSR-51 Expert Group
* @since 1.4
*/
public abstract class DoubleBuffer
extends Buffer
implements Comparable<DoubleBuffer>
{
// These fields are declared here rather than in Heap-X-Buffer in order to
// reduce the number of virtual method invocations needed to access these
// values, which is especially costly when coding small buffers.
//
final double[] hb; // Non-null only for heap buffers
final int offset;
boolean isReadOnly; // Valid only for heap buffers
// Creates a new buffer with the given mark, position, limit, capacity,
// backing array, and array offset
//
DoubleBuffer(int mark, int pos, int lim, int cap, // package-private
double[] hb, int offset)
{
super(mark, pos, lim, cap);
this.hb = hb;
this.offset = offset;
}
// Creates a new buffer with the given mark, position, limit, and capacity
//
DoubleBuffer(int mark, int pos, int lim, int cap) { // package-private
this(mark, pos, lim, cap, null, 0);
}
/**
* Allocates a new double buffer.
*
* <p> The new buffer's position will be zero, its limit will be its
* capacity, its mark will be undefined, and each of its elements will be
* initialized to zero. It will have a {@link #array
* </code>backing array<code>}, and its {@link #arrayOffset </code>array
* offset<code>} will be zero.
*
* @param capacity
* The new buffer's capacity, in doubles
*
* @return The new double buffer
*
* @throws IllegalArgumentException
* If the <tt>capacity</tt> is a negative integer
*/
public static DoubleBuffer allocate(int capacity) {
if (capacity < 0)
throw new IllegalArgumentException();
return new HeapDoubleBuffer(capacity, capacity);
}
/**
* Wraps a double array into a buffer.
*
* <p> The new buffer will be backed by the given double array;
* that is, modifications to the buffer will cause the array to be modified
* and vice versa. The new buffer's capacity will be
* <tt>array.length</tt>, its position will be <tt>offset</tt>, its limit
* will be <tt>offset + length</tt>, and its mark will be undefined. Its
* {@link #array </code>backing array<code>} will be the given array, and
* its {@link #arrayOffset </code>array offset<code>} will be zero. </p>
*
* @param array
* The array that will back the new buffer
*
* @param offset
* The offset of the subarray to be used; must be non-negative and
* no larger than <tt>array.length</tt>. The new buffer's position
* will be set to this value.
*
* @param length
* The length of the subarray to be used;
* must be non-negative and no larger than
* <tt>array.length - offset</tt>.
* The new buffer's limit will be set to <tt>offset + length</tt>.
*
* @return The new double buffer
*
* @throws IndexOutOfBoundsException
* If the preconditions on the <tt>offset</tt> and <tt>length</tt>
* parameters do not hold
*/
public static DoubleBuffer wrap(double[] array,
int offset, int length)
{
try {
return new HeapDoubleBuffer(array, offset, length);
} catch (IllegalArgumentException x) {
throw new IndexOutOfBoundsException();
}
}
/**
* Wraps a double array into a buffer.
*
* <p> The new buffer will be backed by the given double array;
* that is, modifications to the buffer will cause the array to be modified
* and vice versa. The new buffer's capacity and limit will be
* <tt>array.length</tt>, its position will be zero, and its mark will be
* undefined. Its {@link #array </code>backing array<code>} will be the
* given array, and its {@link #arrayOffset </code>array offset<code>} will
* be zero. </p>
*
* @param array
* The array that will back this buffer
*
* @return The new double buffer
*/
public static DoubleBuffer wrap(double[] array) {
return wrap(array, 0, array.length);
}
/**
* Creates a new double buffer whose content is a shared subsequence of
* this buffer's content.
*
* <p> The content of the new buffer will start at this buffer's current
* position. Changes to this buffer's content will be visible in the new
* buffer, and vice versa; the two buffers' position, limit, and mark
* values will be independent.
*
* <p> The new buffer's position will be zero, its capacity and its limit
* will be the number of doubles remaining in this buffer, and its mark
* will be undefined. The new buffer will be direct if, and only if, this
* buffer is direct, and it will be read-only if, and only if, this buffer
* is read-only. </p>
*
* @return The new double buffer
*/
public abstract DoubleBuffer slice();
/**
* Creates a new double buffer that shares this buffer's content.
*
* <p> The content of the new buffer will be that of this buffer. Changes
* to this buffer's content will be visible in the new buffer, and vice
* versa; the two buffers' position, limit, and mark values will be
* independent.
*
* <p> The new buffer's capacity, limit, position, and mark values will be
* identical to those of this buffer. The new buffer will be direct if,
* and only if, this buffer is direct, and it will be read-only if, and
* only if, this buffer is read-only. </p>
*
* @return The new double buffer
*/
public abstract DoubleBuffer duplicate();
/**
* Creates a new, read-only double buffer that shares this buffer's
* content.
*
* <p> The content of the new buffer will be that of this buffer. Changes
* to this buffer's content will be visible in the new buffer; the new
* buffer itself, however, will be read-only and will not allow the shared
* content to be modified. The two buffers' position, limit, and mark
* values will be independent.
*
* <p> The new buffer's capacity, limit, position, and mark values will be
* identical to those of this buffer.
*
* <p> If this buffer is itself read-only then this method behaves in
* exactly the same way as the {@link #duplicate duplicate} method. </p>
*
* @return The new, read-only double buffer
*/
public abstract DoubleBuffer asReadOnlyBuffer();
// -- Singleton get/put methods --
/**
* Relative <i>get</i> method. Reads the double at this buffer's
* current position, and then increments the position. </p>
*
* @return The double at the buffer's current position
*
* @throws BufferUnderflowException
* If the buffer's current position is not smaller than its limit
*/
public abstract double get();
/**
* Relative <i>put</i> method <i>(optional operation)</i>.
*
* <p> Writes the given double into this buffer at the current
* position, and then increments the position. </p>
*
* @param d
* The double to be written
*
* @return This buffer
*
* @throws BufferOverflowException
* If this buffer's current position is not smaller than its limit
*
* @throws ReadOnlyBufferException
* If this buffer is read-only
*/
public abstract DoubleBuffer put(double d);
/**
* Absolute <i>get</i> method. Reads the double at the given
* index. </p>
*
* @param index
* The index from which the double will be read
*
* @return The double at the given index
*
* @throws IndexOutOfBoundsException
* If <tt>index</tt> is negative
* or not smaller than the buffer's limit
*/
public abstract double get(int index);
/**
* Absolute <i>put</i> method <i>(optional operation)</i>.
*
* <p> Writes the given double into this buffer at the given
* index. </p>
*
* @param index
* The index at which the double will be written
*
* @param d
* The double value to be written
*
* @return This buffer
*
* @throws IndexOutOfBoundsException
* If <tt>index</tt> is negative
* or not smaller than the buffer's limit
*
* @throws ReadOnlyBufferException
* If this buffer is read-only
*/
public abstract DoubleBuffer put(int index, double d);
// -- Bulk get operations --
/**
* Relative bulk <i>get</i> method.
*
* <p> This method transfers doubles from this buffer into the given
* destination array. If there are fewer doubles remaining in the
* buffer than are required to satisfy the request, that is, if
* <tt>length</tt> <tt>></tt> <tt>remaining()</tt>, then no
* doubles are transferred and a {@link BufferUnderflowException} is
* thrown.
*
* <p> Otherwise, this method copies <tt>length</tt> doubles from this
* buffer into the given array, starting at the current position of this
* buffer and at the given offset in the array. The position of this
* buffer is then incremented by <tt>length</tt>.
*
* <p> In other words, an invocation of this method of the form
* <tt>src.get(dst, off, len)</tt> has exactly the same effect as
* the loop
*
* <pre>
* for (int i = off; i < off + len; i++)
* dst[i] = src.get(); </pre>
*
* except that it first checks that there are sufficient doubles in
* this buffer and it is potentially much more efficient. </p>
*
* @param dst
* The array into which doubles are to be written
*
* @param offset
* The offset within the array of the first double to be
* written; must be non-negative and no larger than
* <tt>dst.length</tt>
*
* @param length
* The maximum number of doubles to be written to the given
* array; must be non-negative and no larger than
* <tt>dst.length - offset</tt>
*
* @return This buffer
*
* @throws BufferUnderflowException
* If there are fewer than <tt>length</tt> doubles
* remaining in this buffer
*
* @throws IndexOutOfBoundsException
* If the preconditions on the <tt>offset</tt> and <tt>length</tt>
* parameters do not hold
*/
public DoubleBuffer get(double[] dst, int offset, int length) {
checkBounds(offset, length, dst.length);
if (length > remaining())
throw new BufferUnderflowException();
int end = offset + length;
for (int i = offset; i < end; i++)
dst[i] = get();
return this;
}
/**
* Relative bulk <i>get</i> method.
*
* <p> This method transfers doubles from this buffer into the given
* destination array. An invocation of this method of the form
* <tt>src.get(a)</tt> behaves in exactly the same way as the invocation
*
* <pre>
* src.get(a, 0, a.length) </pre>
*
* @return This buffer
*
* @throws BufferUnderflowException
* If there are fewer than <tt>length</tt> doubles
* remaining in this buffer
*/
public DoubleBuffer get(double[] dst) {
return get(dst, 0, dst.length);
}
// -- Bulk put operations --
/**
* Relative bulk <i>put</i> method <i>(optional operation)</i>.
*
* <p> This method transfers the doubles remaining in the given source
* buffer into this buffer. If there are more doubles remaining in the
* source buffer than in this buffer, that is, if
* <tt>src.remaining()</tt> <tt>></tt> <tt>remaining()</tt>,
* then no doubles are transferred and a {@link
* BufferOverflowException} is thrown.
*
* <p> Otherwise, this method copies
* <i>n</i> = <tt>src.remaining()</tt> doubles from the given
* buffer into this buffer, starting at each buffer's current position.
* The positions of both buffers are then incremented by <i>n</i>.
*
* <p> In other words, an invocation of this method of the form
* <tt>dst.put(src)</tt> has exactly the same effect as the loop
*
* <pre>
* while (src.hasRemaining())
* dst.put(src.get()); </pre>
*
* except that it first checks that there is sufficient space in this
* buffer and it is potentially much more efficient. </p>
*
* @param src
* The source buffer from which doubles are to be read;
* must not be this buffer
*
* @return This buffer
*
* @throws BufferOverflowException
* If there is insufficient space in this buffer
* for the remaining doubles in the source buffer
*
* @throws IllegalArgumentException
* If the source buffer is this buffer
*
* @throws ReadOnlyBufferException
* If this buffer is read-only
*/
public DoubleBuffer put(DoubleBuffer src) {
if (src == this)
throw new IllegalArgumentException();
int n = src.remaining();
if (n > remaining())
throw new BufferOverflowException();
for (int i = 0; i < n; i++)
put(src.get());
return this;
}
/**
* Relative bulk <i>put</i> method <i>(optional operation)</i>.
*
* <p> This method transfers doubles into this buffer from the given
* source array. If there are more doubles to be copied from the array
* than remain in this buffer, that is, if
* <tt>length</tt> <tt>></tt> <tt>remaining()</tt>, then no
* doubles are transferred and a {@link BufferOverflowException} is
* thrown.
*
* <p> Otherwise, this method copies <tt>length</tt> doubles from the
* given array into this buffer, starting at the given offset in the array
* and at the current position of this buffer. The position of this buffer
* is then incremented by <tt>length</tt>.
*
* <p> In other words, an invocation of this method of the form
* <tt>dst.put(src, off, len)</tt> has exactly the same effect as
* the loop
*
* <pre>
* for (int i = off; i < off + len; i++)
* dst.put(a[i]); </pre>
*
* except that it first checks that there is sufficient space in this
* buffer and it is potentially much more efficient. </p>
*
* @param src
* The array from which doubles are to be read
*
* @param offset
* The offset within the array of the first double to be read;
* must be non-negative and no larger than <tt>array.length</tt>
*
* @param length
* The number of doubles to be read from the given array;
* must be non-negative and no larger than
* <tt>array.length - offset</tt>
*
* @return This buffer
*
* @throws BufferOverflowException
* If there is insufficient space in this buffer
*
* @throws IndexOutOfBoundsException
* If the preconditions on the <tt>offset</tt> and <tt>length</tt>
* parameters do not hold
*
* @throws ReadOnlyBufferException
* If this buffer is read-only
*/
public DoubleBuffer put(double[] src, int offset, int length) {
checkBounds(offset, length, src.length);
if (length > remaining())
throw new BufferOverflowException();
int end = offset + length;
for (int i = offset; i < end; i++)
this.put(src[i]);
return this;
}
/**
* Relative bulk <i>put</i> method <i>(optional operation)</i>.
*
* <p> This method transfers the entire content of the given source
* double array into this buffer. An invocation of this method of the
* form <tt>dst.put(a)</tt> behaves in exactly the same way as the
* invocation
*
* <pre>
* dst.put(a, 0, a.length) </pre>
*
* @return This buffer
*
* @throws BufferOverflowException
* If there is insufficient space in this buffer
*
* @throws ReadOnlyBufferException
* If this buffer is read-only
*/
public final DoubleBuffer put(double[] src) {
return put(src, 0, src.length);
}
// -- Other stuff --
/**
* Tells whether or not this buffer is backed by an accessible double
* array.
*
* <p> If this method returns <tt>true</tt> then the {@link #array() array}
* and {@link #arrayOffset() arrayOffset} methods may safely be invoked.
* </p>
*
* @return <tt>true</tt> if, and only if, this buffer
* is backed by an array and is not read-only
*/
public final boolean hasArray() {
return (hb != null) && !isReadOnly;
}
/**
* Returns the double array that backs this
* buffer <i>(optional operation)</i>.
*
* <p> Modifications to this buffer's content will cause the returned
* array's content to be modified, and vice versa.
*
* <p> Invoke the {@link #hasArray hasArray} method before invoking this
* method in order to ensure that this buffer has an accessible backing
* array. </p>
*
* @return The array that backs this buffer
*
* @throws ReadOnlyBufferException
* If this buffer is backed by an array but is read-only
*
* @throws UnsupportedOperationException
* If this buffer is not backed by an accessible array
*/
public final double[] array() {
if (hb == null)
throw new UnsupportedOperationException();
if (isReadOnly)
throw new ReadOnlyBufferException();
return hb;
}
/**
* Returns the offset within this buffer's backing array of the first
* element of the buffer <i>(optional operation)</i>.
*
* <p> If this buffer is backed by an array then buffer position <i>p</i>
* corresponds to array index <i>p</i> + <tt>arrayOffset()</tt>.
*
* <p> Invoke the {@link #hasArray hasArray} method before invoking this
* method in order to ensure that this buffer has an accessible backing
* array. </p>
*
* @return The offset within this buffer's array
* of the first element of the buffer
*
* @throws ReadOnlyBufferException
* If this buffer is backed by an array but is read-only
*
* @throws UnsupportedOperationException
* If this buffer is not backed by an accessible array
*/
public final int arrayOffset() {
if (hb == null)
throw new UnsupportedOperationException();
if (isReadOnly)
throw new ReadOnlyBufferException();
return offset;
}
/**
* Compacts this buffer <i>(optional operation)</i>.
*
* <p> The doubles between the buffer's current position and its limit,
* if any, are copied to the beginning of the buffer. That is, the
* double at index <i>p</i> = <tt>position()</tt> is copied
* to index zero, the double at index <i>p</i> + 1 is copied
* to index one, and so forth until the double at index
* <tt>limit()</tt> - 1 is copied to index
* <i>n</i> = <tt>limit()</tt> - <tt>1</tt> - <i>p</i>.
* The buffer's position is then set to <i>n+1</i> and its limit is set to
* its capacity. The mark, if defined, is discarded.
*
* <p> The buffer's position is set to the number of doubles copied,
* rather than to zero, so that an invocation of this method can be
* followed immediately by an invocation of another relative <i>put</i>
* method. </p>
*
*
* @return This buffer
*
* @throws ReadOnlyBufferException
* If this buffer is read-only
*/
public abstract DoubleBuffer compact();
/**
* Tells whether or not this double buffer is direct. </p>
*
* @return <tt>true</tt> if, and only if, this buffer is direct
*/
public abstract boolean isDirect();
/**
* Returns a string summarizing the state of this buffer. </p>
*
* @return A summary string
*/
public String toString() {
StringBuffer sb = new StringBuffer();
sb.append(getClass().getName());
sb.append("[pos=");
sb.append(position());
sb.append(" lim=");
sb.append(limit());
sb.append(" cap=");
sb.append(capacity());
sb.append("]");
return sb.toString();
}
/**
* Returns the current hash code of this buffer.
*
* <p> The hash code of a double buffer depends only upon its remaining
* elements; that is, upon the elements from <tt>position()</tt> up to, and
* including, the element at <tt>limit()</tt> - <tt>1</tt>.
*
* <p> Because buffer hash codes are content-dependent, it is inadvisable
* to use buffers as keys in hash maps or similar data structures unless it
* is known that their contents will not change. </p>
*
* @return The current hash code of this buffer
*/
public int hashCode() {
int h = 1;
int p = position();
for (int i = limit() - 1; i >= p; i--)
h = 31 * h + (int)get(i);
return h;
}
/**
* Tells whether or not this buffer is equal to another object.
*
* <p> Two double buffers are equal if, and only if,
*
* <p><ol>
*
* <li><p> They have the same element type, </p></li>
*
* <li><p> They have the same number of remaining elements, and
* </p></li>
*
* <li><p> The two sequences of remaining elements, considered
* independently of their starting positions, are pointwise equal.
* This method considers two double elements {@code a} and {@code b}
* to be equal if
* {@code (a == b) || (Double.isNaN(a) && Double.isNaN(b))}.
* The values {@code -0.0} and {@code +0.0} are considered to be
* equal, unlike {@link Double#equals(Object)}.
* </p></li>
*
* </ol>
*
* <p> A double buffer is not equal to any other type of object. </p>
*
* @param ob The object to which this buffer is to be compared
*
* @return <tt>true</tt> if, and only if, this buffer is equal to the
* given object
*/
public boolean equals(Object ob) {
if (this == ob)
return true;
if (!(ob instanceof DoubleBuffer))
return false;
DoubleBuffer that = (DoubleBuffer)ob;
if (this.remaining() != that.remaining())
return false;
int p = this.position();
for (int i = this.limit() - 1, j = that.limit() - 1; i >= p; i--, j--)
if (!equals(this.get(i), that.get(j)))
return false;
return true;
}
private static boolean equals(double x, double y) {
return (x == y) || (Double.isNaN(x) && Double.isNaN(y));
}
/**
* Compares this buffer to another.
*
* <p> Two double buffers are compared by comparing their sequences of
* remaining elements lexicographically, without regard to the starting
* position of each sequence within its corresponding buffer.
* Pairs of {@code double} elements are compared as if by invoking
* {@link Double#compare(double,double)}, except that
* {@code -0.0} and {@code 0.0} are considered to be equal.
* {@code Double.NaN} is considered by this method to be equal
* to itself and greater than all other {@code double} values
* (including {@code Double.POSITIVE_INFINITY}).
*
* <p> A double buffer is not comparable to any other type of object.
*
* @return A negative integer, zero, or a positive integer as this buffer
* is less than, equal to, or greater than the given buffer
*/
public int compareTo(DoubleBuffer that) {
int n = this.position() + Math.min(this.remaining(), that.remaining());
for (int i = this.position(), j = that.position(); i < n; i++, j++) {
int cmp = compare(this.get(i), that.get(j));
if (cmp != 0)
return cmp;
}
return this.remaining() - that.remaining();
}
private static int compare(double x, double y) {
return ((x < y) ? -1 :
(x > y) ? +1 :
(x == y) ? 0 :
Double.isNaN(x) ? (Double.isNaN(y) ? 0 : +1) : -1);
}
// -- Other char stuff --
// -- Other byte stuff: Access to binary data --
/**
* Retrieves this buffer's byte order.
*
* <p> The byte order of a double buffer created by allocation or by
* wrapping an existing <tt>double</tt> array is the {@link
* ByteOrder#nativeOrder </code>native order<code>} of the underlying
* hardware. The byte order of a double buffer created as a <a
* href="ByteBuffer.html#views">view</a> of a byte buffer is that of the
* byte buffer at the moment that the view is created. </p>
*
* @return This buffer's byte order
*/
public abstract ByteOrder order();
}
| [
"zhaoxina@gmail.com"
] | zhaoxina@gmail.com |
dc2493c35dc55ddfea8063a64786d475e13964fd | 8a98577c5995449677ede2cbe1cc408c324efacc | /Big_Clone_Bench_files_used/bcb_reduced/3/selected/416876.java | 4d2995fa7c33421e834d662bd8ecf423a8bd3c11 | [
"MIT"
] | permissive | pombredanne/lsh-for-source-code | 9363cc0c9a8ddf16550ae4764859fa60186351dd | fac9adfbd98a4d73122a8fc1a0e0cc4f45e9dcd4 | refs/heads/master | 2020-08-05T02:28:55.370949 | 2017-10-18T23:57:08 | 2017-10-18T23:57:08 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 10,999 | java | package org.apache.fop.pdf;
import java.io.PrintWriter;
import java.io.UnsupportedEncodingException;
import java.util.Enumeration;
import java.util.Vector;
import java.util.Hashtable;
import java.security.MessageDigest;
import java.security.NoSuchAlgorithmException;
import java.security.InvalidKeyException;
import javax.crypto.Cipher;
import javax.crypto.spec.SecretKeySpec;
import javax.crypto.IllegalBlockSizeException;
import javax.crypto.BadPaddingException;
import javax.crypto.NoSuchPaddingException;
import java.util.Random;
/**
* class representing a /Filter /Standard object.
*
*/
public class PDFEncryption extends PDFObject {
private class EncryptionFilter extends PDFFilter {
PDFEncryption encryption;
int number;
int generation;
/** The constructor for the internal PDFEncryption filter
* @param encryption The encryption object to use
* @param number The number of the object to be encrypted
* @param generation The generation of the object to be encrypted
*/
public EncryptionFilter(PDFEncryption encryption, int number, int generation) {
super();
this.encryption = encryption;
this.number = number;
this.generation = generation;
}
/** return a PDF string representation of the filter. In this
* case no filter name is passed.
* @return The filter name, blank in this case
*/
public String getName() {
return "";
}
/** return a parameter dictionary for this filter, or null
* @return The parameter dictionary. In this case, null.
*/
public String getDecodeParms() {
return null;
}
/** encode the given data with the filter
* @param data The data to be encrypted
* @return The encrypted data
*/
public byte[] encode(byte[] data) {
return encryption.encryptData(data, number, generation);
}
}
static final char[] pad = { 0x28, 0xBF, 0x4E, 0x5E, 0x4E, 0x75, 0x8A, 0x41, 0x64, 0x00, 0x4E, 0x56, 0xFF, 0xFA, 0x01, 0x08, 0x2E, 0x2E, 0x00, 0xB6, 0xD0, 0x68, 0x3E, 0x80, 0x2F, 0x0C, 0xA9, 0xFE, 0x64, 0x53, 0x69, 0x7A };
static final char[] digits = { '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F' };
/** Value of PRINT permission
*/
public static final int PERMISSION_PRINT = 4;
/** Value of content editting permission
*/
public static final int PERMISSION_EDIT_CONTENT = 8;
/** Value of content extraction permission
*/
public static final int PERMISSION_COPY_CONTENT = 16;
/** Value of annotation editting permission
*/
public static final int PERMISSION_EDIT_ANNOTATIONS = 32;
MessageDigest digest = null;
Cipher cipher = null;
Random random = new Random();
String userPassword = "";
String ownerPassword = "";
boolean allowPrint = true;
boolean allowCopyContent = true;
boolean allowEditContent = true;
boolean allowEditAnnotations = true;
byte[] fileID = null;
byte[] encryptionKey = null;
String dictionary = null;
/**
* create a /Filter /Standard object.
*
* @param number the object's number
*/
public PDFEncryption(int number) {
super(number);
try {
digest = MessageDigest.getInstance("MD5");
cipher = Cipher.getInstance("RC4");
} catch (NoSuchAlgorithmException e) {
throw new IllegalStateException(e.getMessage());
} catch (NoSuchPaddingException e) {
throw new IllegalStateException(e.getMessage());
}
}
/** This method allows the setting of the user password
* @param value The string to use as the user password. It may be blank but not null.
*/
public void setUserPassword(String value) {
this.userPassword = value;
}
/** Returns the current user password
* @return The user password
*/
public String getUserPassword() {
return this.userPassword;
}
/** Sets the owner password for the PDF
* @param value The owner password
*/
public void setOwnerPassword(String value) {
this.ownerPassword = value;
}
/** Returns the owner password for the PDF
* @return The owner password
*/
public String getOwnerPassword() {
return this.ownerPassword;
}
/** Set whether the document will allow printing.
* @param value The new permision value
*/
public void setAllowPrint(boolean value) {
this.allowPrint = value;
}
/** Set whether the document will allow the content to be extracted
* @param value The new permission value
*/
public void setAllowCopyContent(boolean value) {
this.allowCopyContent = value;
}
/** Set whether the document will allow content editting
* @param value The new permission value
*/
public void setAllowEditContent(boolean value) {
this.allowEditContent = value;
}
/** Set whether the document will allow annotation modificcations
* @param value The new permission value
*/
public void setAllowEditAnnotation(boolean value) {
this.allowEditAnnotations = value;
}
private byte[] prepPassword(String password) {
byte[] obuffer = new byte[32];
byte[] pbuffer = password.getBytes();
int i = 0;
int j = 0;
while (i < obuffer.length && i < pbuffer.length) {
obuffer[i] = pbuffer[i];
i++;
}
while (i < obuffer.length) {
obuffer[i++] = (byte) pad[j++];
}
return obuffer;
}
private String toHex(byte[] value) {
StringBuffer buffer = new StringBuffer();
for (int i = 0; i < value.length; i++) {
buffer.append(digits[(value[i] >>> 4) & 0x0F]);
buffer.append(digits[value[i] & 0x0F]);
}
return buffer.toString();
}
/** Returns the document file ID
* @return The file ID
*/
public byte[] getFileID() {
if (fileID == null) {
fileID = new byte[16];
random.nextBytes(fileID);
}
return fileID;
}
/** This method returns the indexed file ID
* @param index The index to access the file ID
* @return The file ID
*/
public String getFileID(int index) {
if (index == 1) {
return toHex(getFileID());
}
byte[] id = new byte[16];
random.nextBytes(id);
return toHex(id);
}
private byte[] encryptWithKey(byte[] data, byte[] key) {
try {
SecretKeySpec keyspec = new SecretKeySpec(key, "RC4");
cipher.init(Cipher.ENCRYPT_MODE, keyspec);
return cipher.doFinal(data);
} catch (IllegalBlockSizeException e) {
throw new IllegalStateException(e.getMessage());
} catch (BadPaddingException e) {
throw new IllegalStateException(e.getMessage());
} catch (InvalidKeyException e) {
throw new IllegalStateException(e.getMessage());
}
}
private byte[] encryptWithHash(byte[] data, byte[] hash, int size) {
hash = digest.digest(hash);
byte[] key = new byte[size];
for (int i = 0; i < size; i++) {
key[i] = hash[i];
}
return encryptWithKey(data, key);
}
/** This method initializes the encryption algorithms and values
*/
public void init() {
byte[] oValue;
if (ownerPassword.length() > 0) {
oValue = encryptWithHash(prepPassword(userPassword), prepPassword(ownerPassword), 5);
} else {
oValue = encryptWithHash(prepPassword(userPassword), prepPassword(userPassword), 5);
}
int permissions = -4;
if (!allowPrint) {
permissions -= PERMISSION_PRINT;
}
if (!allowCopyContent) {
permissions -= PERMISSION_COPY_CONTENT;
}
if (!allowEditContent) {
permissions -= PERMISSION_EDIT_CONTENT;
}
if (!allowEditAnnotations) {
permissions -= PERMISSION_EDIT_ANNOTATIONS;
}
digest.update(prepPassword(userPassword));
digest.update(oValue);
digest.update((byte) (permissions >>> 0));
digest.update((byte) (permissions >>> 8));
digest.update((byte) (permissions >>> 16));
digest.update((byte) (permissions >>> 24));
digest.update(getFileID());
byte[] hash = digest.digest();
this.encryptionKey = new byte[5];
for (int i = 0; i < 5; i++) {
this.encryptionKey[i] = hash[i];
}
byte[] uValue = encryptWithKey(prepPassword(""), this.encryptionKey);
this.dictionary = this.number + " " + this.generation + " obj\n<< /Filter /Standard\n" + "/V 1" + "/R 2" + "/Length 40" + "/P " + permissions + "\n" + "/O <" + toHex(oValue) + ">\n" + "/U <" + toHex(uValue) + ">\n" + ">>\n" + "endobj\n";
}
/** This method encrypts the passed data using the generated keys.
* @param data The data to be encrypted
* @param number The block number
* @param generation The block generation
* @return The encrypted data
*/
public byte[] encryptData(byte[] data, int number, int generation) {
if (this.encryptionKey == null) {
throw new IllegalStateException("PDF Encryption has not been initialized");
}
byte[] hash = new byte[this.encryptionKey.length + 5];
int i = 0;
while (i < this.encryptionKey.length) {
hash[i] = this.encryptionKey[i];
i++;
}
hash[i++] = (byte) (number >>> 0);
hash[i++] = (byte) (number >>> 8);
hash[i++] = (byte) (number >>> 16);
hash[i++] = (byte) (generation >>> 0);
hash[i++] = (byte) (generation >>> 8);
;
return encryptWithHash(data, hash, hash.length);
}
/** Creates PDFFilter for the encryption object
* @param number The object number
* @param generation The objects generation
* @return The resulting filter
*/
public PDFFilter makeFilter(int number, int generation) {
return new EncryptionFilter(this, number, generation);
}
/**
* represent the object in PDF
*
* @return the PDF
*/
public byte[] toPDF() throws IllegalStateException {
if (this.dictionary == null) {
throw new IllegalStateException("PDF Encryption has not been initialized");
}
try {
return this.dictionary.getBytes(PDFDocument.ENCODING);
} catch (UnsupportedEncodingException ue) {
return this.dictionary.getBytes();
}
}
public static boolean encryptionAvailable() {
return true;
}
}
| [
"nishima@mymail.vcu.edu"
] | nishima@mymail.vcu.edu |
b151b7f1411c464e1e4a3a52f69f517567ad4869 | 0825d87d459b829dd68ae2cfb30bc0ba26028a69 | /pesrsonal/src/androidTest/java/com/zl/modular/pesrsonal/ExampleInstrumentedTest.java | 5a0356f0b3dd1de37872fc8275b10df4c9aa83d2 | [] | no_license | LeiboyNotes/Moduler | c16941f2c857a8337db9a40835f1cdf2618da42c | c4cc41702e279ba4e0549f84dda8c00e8b64d5d9 | refs/heads/master | 2020-09-04T01:41:02.586126 | 2019-11-14T09:31:05 | 2019-11-14T09:31:05 | 219,631,462 | 1 | 0 | null | null | null | null | UTF-8 | Java | false | false | 724 | java | package com.zl.modular.pesrsonal;
import android.content.Context;
import androidx.test.InstrumentationRegistry;
import androidx.test.runner.AndroidJUnit4;
import org.junit.Test;
import org.junit.runner.RunWith;
import static org.junit.Assert.*;
/**
* Instrumented test, which will execute on an Android device.
*
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
*/
@RunWith(AndroidJUnit4.class)
public class ExampleInstrumentedTest {
@Test
public void useAppContext() {
// Context of the app under test.
Context appContext = InstrumentationRegistry.getTargetContext();
assertEquals("com.zl.modular.pesrsonal.test", appContext.getPackageName());
}
}
| [
"zhanlei@womob.com"
] | zhanlei@womob.com |
1375bb2c40a9aeb722355b84b797dfeecf2a73ba | 67fb83e240e36d24323078966eebabbef31e6eb1 | /src/main/java/net/avalith/carDriver/controllers/LicenseController.java | dc6ff5b89f4d2718d3822fa97125e8af9cc74c5f | [] | no_license | mauro8792/RentCar | f20a2811bb9cb7e5caea048139e4adae426ac2c2 | 3ff14cac7562b53a52a9eb053d84ccc364f339ae | refs/heads/master | 2022-12-02T08:44:51.653445 | 2020-08-12T01:47:31 | 2020-08-12T01:47:31 | 286,889,354 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,431 | java | package net.avalith.carDriver.controllers;
import net.avalith.carDriver.models.License;
import net.avalith.carDriver.models.dtos.requests.LicenseDtoRequest;
import net.avalith.carDriver.models.dtos.requests.LicenseDtoRequestUpdate;
import net.avalith.carDriver.models.dtos.responses.LicenseDtoResponse;
import net.avalith.carDriver.services.LicenseService;
import net.avalith.carDriver.utils.Routes;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.HttpStatus;
import org.springframework.http.MediaType;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import javax.validation.Valid;
import java.util.List;
import java.util.stream.Collectors;
@RestController
@RequestMapping(value = Routes.LICENSE)
public class LicenseController {
@Autowired
private LicenseService licenseService;
@PostMapping(consumes = {MediaType.APPLICATION_JSON_VALUE})
public ResponseEntity<LicenseDtoResponse> save(@RequestBody @Valid LicenseDtoRequest license){
return ResponseEntity.status(HttpStatus.CREATED).body(new LicenseDtoResponse(licenseService.save(license)));
}
@GetMapping(produces = {MediaType.APPLICATION_JSON_VALUE})
public ResponseEntity<List<LicenseDtoResponse>> getAll(){
List<License> licenses = licenseService.getAll();
if (licenses.isEmpty())
return ResponseEntity.noContent().build();
List<LicenseDtoResponse> licenseResponses = licenses.stream()
.map(LicenseDtoResponse::new)
.collect(Collectors.toList());
return ResponseEntity.ok(licenseResponses);
}
@PutMapping(value = Routes.LICENSE_UPDATE, consumes = {MediaType.APPLICATION_JSON_VALUE})
public ResponseEntity<LicenseDtoResponse> updateExpirationDate(@PathVariable(value = "number") String number, @RequestBody @Valid LicenseDtoRequestUpdate license){
return ResponseEntity.ok(new LicenseDtoResponse(licenseService.updateExpirationDate(number, license)));
}
}
| [
"mauro8792yini@gmail.com"
] | mauro8792yini@gmail.com |
82f35461ca27fc72117e07d34d9ca41ef9f856b1 | a3fe4f5b1ffcc0b1cb2e673744f109e4ce04264b | /src/com/ju/japro/structalg/ten/test/Parcal5.java | ba4c98a74830fcac9522355abd2ad813ef0b33b7 | [] | no_license | zhanglschn/japro | 2df3d37dfe9426afb00a175e2800a1348dcaf144 | 8f2b5c4893c280ec8e2834d7abfdb2df7da8f4c8 | refs/heads/master | 2020-03-18T14:18:42.601302 | 2018-05-25T10:37:29 | 2018-05-25T10:37:29 | 134,841,451 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 97 | java | package com.ju.japro.structalg.ten.test;
public interface Parcal5 {
public String getLabel();
} | [
"zhanglangsheng@juzix.io"
] | zhanglangsheng@juzix.io |
e044e7f71a254c8684b8f28e67628e840db6fb28 | a8ed461fa72d167c3a112b01e7fe1d6dcc568160 | /app/src/main/java/com/example/dxcfitnesstracker/data/profile/profiledata/ProfileData.java | b0bb32cf6655f77dd62f0220d23fef8544f8fe28 | [] | no_license | PriyankaS21/FitnessTracker | febf79cac05b4b3b2fbd7761a379067b1d69a7e3 | 9b97a5b1956ad2a7388ca62376ae4a022c93e13e | refs/heads/master | 2023-03-07T03:55:15.088519 | 2021-02-12T14:32:33 | 2021-02-12T14:32:33 | 250,181,317 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 477 | java | package com.example.dxcfitnesstracker.data.profile.profiledata;
import com.example.dxcfitnesstracker.R;
public class ProfileData {
public static String[] list_string = {"Personal Information", "Step size", "Step goal", "Step count", "Notification(on/off)", "Instruction"};
public static Integer[] drawableArray = {R.drawable.ic_person, R.drawable.traning, R.drawable.ic_goal_target, R.drawable.ic_step_count, R.drawable.ic_notification, R.drawable.ic_instruction};
}
| [
"Priyanka.Singh@united.com"
] | Priyanka.Singh@united.com |
b7d8a5e365f32201dfd7884e2a2c5648d094e1aa | 71e706b443c680748e0eac6f1489ada183825553 | /src/xyz/robbie/tabula/IllegalTurnException.java | f830ffdbc9393a8abca7011c58fe09c171bf5ba9 | [] | no_license | robzwolf/tabulaIJ_refresh | eb180d449108e363c0601412385f00a18bc64278 | 8504d922fa23e19717777e73a85079c03cdcf399 | refs/heads/master | 2021-01-20T01:25:14.466542 | 2017-05-01T15:53:48 | 2017-05-01T15:53:48 | 89,274,557 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 164 | java | package xyz.robbie.tabula;
public class IllegalTurnException extends Exception {
public IllegalTurnException(String message) {
super(message);
}
}
| [
"robzwolf@gmail.com"
] | robzwolf@gmail.com |
a7e177d247a507b19d7744029d2083b84c3fa27a | a8a216f75677770fd8e15e8591a61f8c9eee0183 | /src/Models/Bullet.java | 33ef792a90e6b6cb981522b58a2374107707ff84 | [] | no_license | wba25/PLC | a925f791e3c2709e92fbd2abee695a26400a4c8a | 40856df39e1348e6f3b6ea3b1efe5534e0b35248 | refs/heads/master | 2021-08-24T03:04:26.835094 | 2017-12-07T19:46:52 | 2017-12-07T19:46:52 | 110,713,547 | 1 | 0 | null | null | null | null | UTF-8 | Java | false | false | 827 | java | package Models;
public class Bullet extends Sprite {
private final int BOARD_WIDTH = 410;
private final int BOARD_HEIGHT = 330;
private final int speed = 5;
private int vertical_direction;
private int horizontal_direction;
public Bullet(int x, int y, int vertical, int horizontal) {
super(x, y);
this.vertical_direction = vertical;
this.horizontal_direction = horizontal;
initBullet();
}
private void initBullet() {
loadImage("src/Assets/Game/Bullet.png");
getImageDimensions();
}
public void move() {
x += speed * horizontal_direction;
y += speed * vertical_direction;
if ((x > BOARD_WIDTH) || (x < 0))
vis = false;
if ((y > BOARD_HEIGHT) || (y < 0))
vis = false;
}
} | [
"wba@cin.ufpe.br"
] | wba@cin.ufpe.br |
50958ab832eb087d5bc1b926c9866cff6a0aa997 | 8dadce08a76ce387608951673fc0364feaa9a06a | /flexodesktop/externalmodels/flexoexecutionmodel/src/main/java/org/openflexo/foundation/exec/EndOperationNodeActivation.java | 67ea4e479ab946c285ad02da4e6fd4d4348024f0 | [] | no_license | melbarra/openflexo | b8e1a97d73a9edebad198df4e776d396ae8e9a09 | 9b2d8efe1982ec8f64dee8c43a2e7207594853f3 | refs/heads/master | 2021-01-24T02:22:47.141424 | 2012-03-12T00:15:57 | 2012-03-12T00:15:57 | 2,756,256 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,087 | java | /*
* (c) Copyright 2010-2011 AgileBirds
*
* This file is part of OpenFlexo.
*
* OpenFlexo is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* OpenFlexo 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 OpenFlexo. If not, see <http://www.gnu.org/licenses/>.
*
*/
package org.openflexo.foundation.exec;
import org.openflexo.antar.ControlGraph;
import org.openflexo.foundation.exec.inst.DeleteActivityTask;
import org.openflexo.foundation.exec.inst.DestroyRemainingTokensForActivity;
import org.openflexo.foundation.wkf.node.FlexoPreCondition;
import org.openflexo.foundation.wkf.node.OperationNode;
public class EndOperationNodeActivation extends NodeActivation<OperationNode> {
public EndOperationNodeActivation(OperationNode node, FlexoPreCondition pre)
{
super(node,pre);
}
public EndOperationNodeActivation(OperationNode node)
{
super(node);
}
@Override
public ControlGraph makeSpecificControlGraph(boolean interprocedural) throws NotSupportedException, InvalidModelException
{
ControlGraph DESTROY_REMAINING_TOKEN = new DestroyRemainingTokensForActivity(getNode().getAbstractActivityNode());
ControlGraph DELETE_ACTIVITY_TASK = new DeleteActivityTask(getNode().getAbstractActivityNode());
return makeSequentialControlGraph(
DESTROY_REMAINING_TOKEN,
DELETE_ACTIVITY_TASK);
}
/**
* Override parent method: we don't try here to activate a node above
*/
@Override
protected ControlGraph makeControlGraphCommonPostlude(boolean interprocedural) throws NotSupportedException, InvalidModelException
{
return NodeDesactivation.desactivateNode(getNode(),interprocedural);
}
}
| [
"guillaume.polet@gmail.com"
] | guillaume.polet@gmail.com |
c9ed9e3c2550d483c76e22565a5d539fd13e7b32 | 834612938187e69bbe895fada65b9503af34a042 | /src/main/java/com/innovativeapps/filehandling/Library.java | 5d6bd849786d99580054c37c2b5cc2ded4a86868 | [] | no_license | famojuro/file-handling-api | 6c77bbfa17a53e3f674d8e476a331947a64920ff | 0ec8009704b8006b0291f2477d4b9aa29dea6191 | refs/heads/master | 2023-04-18T22:32:22.748613 | 2021-05-07T09:09:04 | 2021-05-07T09:09:04 | 363,886,362 | 0 | 0 | null | 2021-05-07T09:09:05 | 2021-05-03T09:59:30 | Shell | UTF-8 | Java | false | false | 208 | java | /*
* This Java source file was generated by the Gradle 'init' task.
*/
package com.innovativeapps.filehandling;
public class Library {
public boolean someLibraryMethod() {
return true;
}
}
| [
"adeniyifamojuro@gmail.com"
] | adeniyifamojuro@gmail.com |
385cec1b233abb07cf2991b74565d4857866db30 | 4dd5b958c891cfe4304008eb8236fc9c23345e35 | /ttmanager/tt-manager-pojo/src/main/java/com/cyk/ttshop/pojo/po/TbOrderItemExample.java | 5ce4eb0a02fd84061ba751de406e1b2852f16053 | [] | no_license | chenyongkui/shop | b9a24dfa91414064357f5021aed513cc7132c74b | 1706c3d3b761ccc93dc3fb072594be65b20e8a2c | refs/heads/master | 2021-07-22T01:57:26.610562 | 2017-10-27T12:35:11 | 2017-10-27T12:35:11 | 107,413,779 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 22,436 | java | package com.cyk.ttshop.pojo.po;
import java.util.ArrayList;
import java.util.List;
public class TbOrderItemExample {
protected String orderByClause;
protected boolean distinct;
protected List<Criteria> oredCriteria;
public TbOrderItemExample() {
oredCriteria = new ArrayList<Criteria>();
}
public void setOrderByClause(String orderByClause) {
this.orderByClause = orderByClause;
}
public String getOrderByClause() {
return orderByClause;
}
public void setDistinct(boolean distinct) {
this.distinct = distinct;
}
public boolean isDistinct() {
return distinct;
}
public List<Criteria> getOredCriteria() {
return oredCriteria;
}
public void or(Criteria criteria) {
oredCriteria.add(criteria);
}
public Criteria or() {
Criteria criteria = createCriteriaInternal();
oredCriteria.add(criteria);
return criteria;
}
public Criteria createCriteria() {
Criteria criteria = createCriteriaInternal();
if (oredCriteria.size() == 0) {
oredCriteria.add(criteria);
}
return criteria;
}
protected Criteria createCriteriaInternal() {
Criteria criteria = new Criteria();
return criteria;
}
public void clear() {
oredCriteria.clear();
orderByClause = null;
distinct = false;
}
protected abstract static class GeneratedCriteria {
protected List<Criterion> criteria;
protected GeneratedCriteria() {
super();
criteria = new ArrayList<Criterion>();
}
public boolean isValid() {
return criteria.size() > 0;
}
public List<Criterion> getAllCriteria() {
return criteria;
}
public List<Criterion> getCriteria() {
return criteria;
}
protected void addCriterion(String condition) {
if (condition == null) {
throw new RuntimeException("Value for condition cannot be null");
}
criteria.add(new Criterion(condition));
}
protected void addCriterion(String condition, Object value, String property) {
if (value == null) {
throw new RuntimeException("Value for " + property + " cannot be null");
}
criteria.add(new Criterion(condition, value));
}
protected void addCriterion(String condition, Object value1, Object value2, String property) {
if (value1 == null || value2 == null) {
throw new RuntimeException("Between values for " + property + " cannot be null");
}
criteria.add(new Criterion(condition, value1, value2));
}
public Criteria andIdIsNull() {
addCriterion("id is null");
return (Criteria) this;
}
public Criteria andIdIsNotNull() {
addCriterion("id is not null");
return (Criteria) this;
}
public Criteria andIdEqualTo(String value) {
addCriterion("id =", value, "id");
return (Criteria) this;
}
public Criteria andIdNotEqualTo(String value) {
addCriterion("id <>", value, "id");
return (Criteria) this;
}
public Criteria andIdGreaterThan(String value) {
addCriterion("id >", value, "id");
return (Criteria) this;
}
public Criteria andIdGreaterThanOrEqualTo(String value) {
addCriterion("id >=", value, "id");
return (Criteria) this;
}
public Criteria andIdLessThan(String value) {
addCriterion("id <", value, "id");
return (Criteria) this;
}
public Criteria andIdLessThanOrEqualTo(String value) {
addCriterion("id <=", value, "id");
return (Criteria) this;
}
public Criteria andIdLike(String value) {
addCriterion("id like", value, "id");
return (Criteria) this;
}
public Criteria andIdNotLike(String value) {
addCriterion("id not like", value, "id");
return (Criteria) this;
}
public Criteria andIdIn(List<String> values) {
addCriterion("id in", values, "id");
return (Criteria) this;
}
public Criteria andIdNotIn(List<String> values) {
addCriterion("id not in", values, "id");
return (Criteria) this;
}
public Criteria andIdBetween(String value1, String value2) {
addCriterion("id between", value1, value2, "id");
return (Criteria) this;
}
public Criteria andIdNotBetween(String value1, String value2) {
addCriterion("id not between", value1, value2, "id");
return (Criteria) this;
}
public Criteria andItemIdIsNull() {
addCriterion("item_id is null");
return (Criteria) this;
}
public Criteria andItemIdIsNotNull() {
addCriterion("item_id is not null");
return (Criteria) this;
}
public Criteria andItemIdEqualTo(String value) {
addCriterion("item_id =", value, "itemId");
return (Criteria) this;
}
public Criteria andItemIdNotEqualTo(String value) {
addCriterion("item_id <>", value, "itemId");
return (Criteria) this;
}
public Criteria andItemIdGreaterThan(String value) {
addCriterion("item_id >", value, "itemId");
return (Criteria) this;
}
public Criteria andItemIdGreaterThanOrEqualTo(String value) {
addCriterion("item_id >=", value, "itemId");
return (Criteria) this;
}
public Criteria andItemIdLessThan(String value) {
addCriterion("item_id <", value, "itemId");
return (Criteria) this;
}
public Criteria andItemIdLessThanOrEqualTo(String value) {
addCriterion("item_id <=", value, "itemId");
return (Criteria) this;
}
public Criteria andItemIdLike(String value) {
addCriterion("item_id like", value, "itemId");
return (Criteria) this;
}
public Criteria andItemIdNotLike(String value) {
addCriterion("item_id not like", value, "itemId");
return (Criteria) this;
}
public Criteria andItemIdIn(List<String> values) {
addCriterion("item_id in", values, "itemId");
return (Criteria) this;
}
public Criteria andItemIdNotIn(List<String> values) {
addCriterion("item_id not in", values, "itemId");
return (Criteria) this;
}
public Criteria andItemIdBetween(String value1, String value2) {
addCriterion("item_id between", value1, value2, "itemId");
return (Criteria) this;
}
public Criteria andItemIdNotBetween(String value1, String value2) {
addCriterion("item_id not between", value1, value2, "itemId");
return (Criteria) this;
}
public Criteria andOrderIdIsNull() {
addCriterion("order_id is null");
return (Criteria) this;
}
public Criteria andOrderIdIsNotNull() {
addCriterion("order_id is not null");
return (Criteria) this;
}
public Criteria andOrderIdEqualTo(String value) {
addCriterion("order_id =", value, "orderId");
return (Criteria) this;
}
public Criteria andOrderIdNotEqualTo(String value) {
addCriterion("order_id <>", value, "orderId");
return (Criteria) this;
}
public Criteria andOrderIdGreaterThan(String value) {
addCriterion("order_id >", value, "orderId");
return (Criteria) this;
}
public Criteria andOrderIdGreaterThanOrEqualTo(String value) {
addCriterion("order_id >=", value, "orderId");
return (Criteria) this;
}
public Criteria andOrderIdLessThan(String value) {
addCriterion("order_id <", value, "orderId");
return (Criteria) this;
}
public Criteria andOrderIdLessThanOrEqualTo(String value) {
addCriterion("order_id <=", value, "orderId");
return (Criteria) this;
}
public Criteria andOrderIdLike(String value) {
addCriterion("order_id like", value, "orderId");
return (Criteria) this;
}
public Criteria andOrderIdNotLike(String value) {
addCriterion("order_id not like", value, "orderId");
return (Criteria) this;
}
public Criteria andOrderIdIn(List<String> values) {
addCriterion("order_id in", values, "orderId");
return (Criteria) this;
}
public Criteria andOrderIdNotIn(List<String> values) {
addCriterion("order_id not in", values, "orderId");
return (Criteria) this;
}
public Criteria andOrderIdBetween(String value1, String value2) {
addCriterion("order_id between", value1, value2, "orderId");
return (Criteria) this;
}
public Criteria andOrderIdNotBetween(String value1, String value2) {
addCriterion("order_id not between", value1, value2, "orderId");
return (Criteria) this;
}
public Criteria andNumIsNull() {
addCriterion("num is null");
return (Criteria) this;
}
public Criteria andNumIsNotNull() {
addCriterion("num is not null");
return (Criteria) this;
}
public Criteria andNumEqualTo(Integer value) {
addCriterion("num =", value, "num");
return (Criteria) this;
}
public Criteria andNumNotEqualTo(Integer value) {
addCriterion("num <>", value, "num");
return (Criteria) this;
}
public Criteria andNumGreaterThan(Integer value) {
addCriterion("num >", value, "num");
return (Criteria) this;
}
public Criteria andNumGreaterThanOrEqualTo(Integer value) {
addCriterion("num >=", value, "num");
return (Criteria) this;
}
public Criteria andNumLessThan(Integer value) {
addCriterion("num <", value, "num");
return (Criteria) this;
}
public Criteria andNumLessThanOrEqualTo(Integer value) {
addCriterion("num <=", value, "num");
return (Criteria) this;
}
public Criteria andNumIn(List<Integer> values) {
addCriterion("num in", values, "num");
return (Criteria) this;
}
public Criteria andNumNotIn(List<Integer> values) {
addCriterion("num not in", values, "num");
return (Criteria) this;
}
public Criteria andNumBetween(Integer value1, Integer value2) {
addCriterion("num between", value1, value2, "num");
return (Criteria) this;
}
public Criteria andNumNotBetween(Integer value1, Integer value2) {
addCriterion("num not between", value1, value2, "num");
return (Criteria) this;
}
public Criteria andTitleIsNull() {
addCriterion("title is null");
return (Criteria) this;
}
public Criteria andTitleIsNotNull() {
addCriterion("title is not null");
return (Criteria) this;
}
public Criteria andTitleEqualTo(String value) {
addCriterion("title =", value, "title");
return (Criteria) this;
}
public Criteria andTitleNotEqualTo(String value) {
addCriterion("title <>", value, "title");
return (Criteria) this;
}
public Criteria andTitleGreaterThan(String value) {
addCriterion("title >", value, "title");
return (Criteria) this;
}
public Criteria andTitleGreaterThanOrEqualTo(String value) {
addCriterion("title >=", value, "title");
return (Criteria) this;
}
public Criteria andTitleLessThan(String value) {
addCriterion("title <", value, "title");
return (Criteria) this;
}
public Criteria andTitleLessThanOrEqualTo(String value) {
addCriterion("title <=", value, "title");
return (Criteria) this;
}
public Criteria andTitleLike(String value) {
addCriterion("title like", value, "title");
return (Criteria) this;
}
public Criteria andTitleNotLike(String value) {
addCriterion("title not like", value, "title");
return (Criteria) this;
}
public Criteria andTitleIn(List<String> values) {
addCriterion("title in", values, "title");
return (Criteria) this;
}
public Criteria andTitleNotIn(List<String> values) {
addCriterion("title not in", values, "title");
return (Criteria) this;
}
public Criteria andTitleBetween(String value1, String value2) {
addCriterion("title between", value1, value2, "title");
return (Criteria) this;
}
public Criteria andTitleNotBetween(String value1, String value2) {
addCriterion("title not between", value1, value2, "title");
return (Criteria) this;
}
public Criteria andPriceIsNull() {
addCriterion("price is null");
return (Criteria) this;
}
public Criteria andPriceIsNotNull() {
addCriterion("price is not null");
return (Criteria) this;
}
public Criteria andPriceEqualTo(Long value) {
addCriterion("price =", value, "price");
return (Criteria) this;
}
public Criteria andPriceNotEqualTo(Long value) {
addCriterion("price <>", value, "price");
return (Criteria) this;
}
public Criteria andPriceGreaterThan(Long value) {
addCriterion("price >", value, "price");
return (Criteria) this;
}
public Criteria andPriceGreaterThanOrEqualTo(Long value) {
addCriterion("price >=", value, "price");
return (Criteria) this;
}
public Criteria andPriceLessThan(Long value) {
addCriterion("price <", value, "price");
return (Criteria) this;
}
public Criteria andPriceLessThanOrEqualTo(Long value) {
addCriterion("price <=", value, "price");
return (Criteria) this;
}
public Criteria andPriceIn(List<Long> values) {
addCriterion("price in", values, "price");
return (Criteria) this;
}
public Criteria andPriceNotIn(List<Long> values) {
addCriterion("price not in", values, "price");
return (Criteria) this;
}
public Criteria andPriceBetween(Long value1, Long value2) {
addCriterion("price between", value1, value2, "price");
return (Criteria) this;
}
public Criteria andPriceNotBetween(Long value1, Long value2) {
addCriterion("price not between", value1, value2, "price");
return (Criteria) this;
}
public Criteria andTotalFeeIsNull() {
addCriterion("total_fee is null");
return (Criteria) this;
}
public Criteria andTotalFeeIsNotNull() {
addCriterion("total_fee is not null");
return (Criteria) this;
}
public Criteria andTotalFeeEqualTo(Long value) {
addCriterion("total_fee =", value, "totalFee");
return (Criteria) this;
}
public Criteria andTotalFeeNotEqualTo(Long value) {
addCriterion("total_fee <>", value, "totalFee");
return (Criteria) this;
}
public Criteria andTotalFeeGreaterThan(Long value) {
addCriterion("total_fee >", value, "totalFee");
return (Criteria) this;
}
public Criteria andTotalFeeGreaterThanOrEqualTo(Long value) {
addCriterion("total_fee >=", value, "totalFee");
return (Criteria) this;
}
public Criteria andTotalFeeLessThan(Long value) {
addCriterion("total_fee <", value, "totalFee");
return (Criteria) this;
}
public Criteria andTotalFeeLessThanOrEqualTo(Long value) {
addCriterion("total_fee <=", value, "totalFee");
return (Criteria) this;
}
public Criteria andTotalFeeIn(List<Long> values) {
addCriterion("total_fee in", values, "totalFee");
return (Criteria) this;
}
public Criteria andTotalFeeNotIn(List<Long> values) {
addCriterion("total_fee not in", values, "totalFee");
return (Criteria) this;
}
public Criteria andTotalFeeBetween(Long value1, Long value2) {
addCriterion("total_fee between", value1, value2, "totalFee");
return (Criteria) this;
}
public Criteria andTotalFeeNotBetween(Long value1, Long value2) {
addCriterion("total_fee not between", value1, value2, "totalFee");
return (Criteria) this;
}
public Criteria andPicPathIsNull() {
addCriterion("pic_path is null");
return (Criteria) this;
}
public Criteria andPicPathIsNotNull() {
addCriterion("pic_path is not null");
return (Criteria) this;
}
public Criteria andPicPathEqualTo(String value) {
addCriterion("pic_path =", value, "picPath");
return (Criteria) this;
}
public Criteria andPicPathNotEqualTo(String value) {
addCriterion("pic_path <>", value, "picPath");
return (Criteria) this;
}
public Criteria andPicPathGreaterThan(String value) {
addCriterion("pic_path >", value, "picPath");
return (Criteria) this;
}
public Criteria andPicPathGreaterThanOrEqualTo(String value) {
addCriterion("pic_path >=", value, "picPath");
return (Criteria) this;
}
public Criteria andPicPathLessThan(String value) {
addCriterion("pic_path <", value, "picPath");
return (Criteria) this;
}
public Criteria andPicPathLessThanOrEqualTo(String value) {
addCriterion("pic_path <=", value, "picPath");
return (Criteria) this;
}
public Criteria andPicPathLike(String value) {
addCriterion("pic_path like", value, "picPath");
return (Criteria) this;
}
public Criteria andPicPathNotLike(String value) {
addCriterion("pic_path not like", value, "picPath");
return (Criteria) this;
}
public Criteria andPicPathIn(List<String> values) {
addCriterion("pic_path in", values, "picPath");
return (Criteria) this;
}
public Criteria andPicPathNotIn(List<String> values) {
addCriterion("pic_path not in", values, "picPath");
return (Criteria) this;
}
public Criteria andPicPathBetween(String value1, String value2) {
addCriterion("pic_path between", value1, value2, "picPath");
return (Criteria) this;
}
public Criteria andPicPathNotBetween(String value1, String value2) {
addCriterion("pic_path not between", value1, value2, "picPath");
return (Criteria) this;
}
}
public static class Criteria extends GeneratedCriteria {
protected Criteria() {
super();
}
}
public static class Criterion {
private String condition;
private Object value;
private Object secondValue;
private boolean noValue;
private boolean singleValue;
private boolean betweenValue;
private boolean listValue;
private String typeHandler;
public String getCondition() {
return condition;
}
public Object getValue() {
return value;
}
public Object getSecondValue() {
return secondValue;
}
public boolean isNoValue() {
return noValue;
}
public boolean isSingleValue() {
return singleValue;
}
public boolean isBetweenValue() {
return betweenValue;
}
public boolean isListValue() {
return listValue;
}
public String getTypeHandler() {
return typeHandler;
}
protected Criterion(String condition) {
super();
this.condition = condition;
this.typeHandler = null;
this.noValue = true;
}
protected Criterion(String condition, Object value, String typeHandler) {
super();
this.condition = condition;
this.value = value;
this.typeHandler = typeHandler;
if (value instanceof List<?>) {
this.listValue = true;
} else {
this.singleValue = true;
}
}
protected Criterion(String condition, Object value) {
this(condition, value, null);
}
protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
super();
this.condition = condition;
this.value = value;
this.secondValue = secondValue;
this.typeHandler = typeHandler;
this.betweenValue = true;
}
protected Criterion(String condition, Object value, Object secondValue) {
this(condition, value, secondValue, null);
}
}
} | [
"1017898004@qq.com"
] | 1017898004@qq.com |
bed4692d0f414ba75504c89ccca5065c1ca67074 | 9c564ab7a6a640b3de571df053d153d6dc96ec47 | /src/main/java/com/hgys/iptv/repository/UserRepository.java | 95f805c089588767abe2b8cc8b48fff4d5a721d8 | [
"MIT"
] | permissive | nemoyn/iptv_sas | 7c73458bdefbc4e5e5f516697fd7582d43dc93a8 | 9dd4b9a758bbd6e382761446d5af72adc3802939 | refs/heads/master | 2022-01-08T05:31:08.598269 | 2019-06-09T05:42:39 | 2019-06-09T05:42:39 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 766 | java | package com.hgys.iptv.repository;
import com.hgys.iptv.model.User;
import org.springframework.data.jpa.repository.Modifying;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;
import javax.transaction.Transactional;
public interface UserRepository extends BaseRepository<User,Integer>{
//根据用户名返回用户对象
User findByUsername(String name);
Integer countByUsername(String username);
//UPDATE sys_user SET isdelete = 1, username="ddd" WHERE id = 11
@Query(value = "update User set isdelete = 1,username=:newName WHERE id = :pk")
@Modifying
@Transactional
void logicDelete(@Param("newName") String newName,
@Param("pk")int id) ;
}
| [
"786917861@qq.com"
] | 786917861@qq.com |
6b78ed9b6ec67cfbc7f7ef4dec2e20da3565d429 | 396100b9d7665b31a2eeff13c9a4ab39d0009b26 | /src/test/java/com/johnny/springjpa/test/PersonRepositoryTests.java | 60cdf5a68a2ea2a1b59aeb9dc0a3cb01021939a4 | [] | no_license | johnnydoamaral/spring_jpa | 606f7a3da39de4e43119072a96f2f9b6274a99a1 | 55f78e84f8845bfadd05fb844a3d023def716e65 | refs/heads/master | 2020-04-25T18:14:31.946831 | 2019-02-27T19:44:05 | 2019-02-27T19:44:05 | 172,977,736 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,926 | java | package com.johnny.springjpa.test;
import static org.junit.Assert.assertThat;
import java.util.Date;
import static org.hamcrest.CoreMatchers.*;
import static org.hamcrest.Matchers.empty;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringRunner;
import com.johnny.springjpa.model.Person;
import com.johnny.springjpa.repository.PersonRepository;
@RunWith(SpringRunner.class)
@SpringBootTest
public class PersonRepositoryTests {
@Autowired
PersonRepository repository;
@Test
public void testFindAll() {
assertThat(repository.findAllPersons(), is(not(empty())));
}
@Test
public void testFindById() {
assertThat(repository.findPersonById(1001), is(not(nullValue())));
}
@Test
public void testFindByName() {
assertThat(repository.findPersonByName("Johnny"), is(not(empty())));
assertThat(repository.findPersonByName("JOHNNY"), is(not(empty())));
assertThat(repository.findPersonByName("johnny"), is(not(empty())));
assertThat(repository.findPersonByName("someInexistentName"), is(empty()));
}
@Test
public void testFindByLocation() {
assertThat(repository.findPersonByLocation("Brazil"), is(not(empty())));
assertThat(repository.findPersonByLocation("BRAZIL"), is(not(empty())));
assertThat(repository.findPersonByLocation("brazil"), is(not(empty())));
assertThat(repository.findPersonByLocation("someInexistentLocation"), is(empty()));
}
@Test
public void testCreatePerson() {
Person newPerson = new Person("Mark", "Germany", new Date());
int newPersonId = repository.createPerson(newPerson).getId();
assertThat(repository.findPersonById(newPersonId).getName(), equalTo(newPerson.getName()));
assertThat(repository.findPersonById(newPersonId).getLocation(), equalTo(newPerson.getLocation()));
}
@Test
public void testUpdatePerson() {
Person newPerson = new Person("Donald", "Australia", new Date());
int newPersonId = repository.createPerson(newPerson).getId();
assertThat(repository.findPersonById(newPersonId).getName(), equalTo("Donald"));
assertThat(repository.findPersonById(newPersonId).getLocation(), equalTo("Australia"));
String newName = "Hugh", newLocation = "Malta";
newPerson = repository.findPersonById(newPersonId);
newPerson.setName(newName);
newPerson.setLocation(newLocation);
Person updatedPerson = repository.updatePerson(newPerson);
assertThat(updatedPerson.getName(), equalTo(newName));
assertThat(updatedPerson.getLocation(), equalTo(newLocation));
}
@Test
public void testDeletePerson() {
Person newPerson = new Person("Roger", "Cyprus", new Date());
int newPersonId = repository.createPerson(newPerson).getId();
repository.deletePersonById(newPersonId);
assertThat(repository.findPersonById(newPersonId), is(nullValue()));
}
}
| [
"Johnny@Johnnys-MacBook-Pro.local"
] | Johnny@Johnnys-MacBook-Pro.local |
e27eab770e5d71b5477831d6d04f21b391e3ceab | d052b08c4fa3cf36cbb713e8aabaa57dd9d59be6 | /app/src/main/java/com/example/piyushravi/finalapartment/RepairManage.java | 73709097eca29f4c4819d1451d71e993c0ac2584 | [] | no_license | jimacoff/ApartmentManagement | fa82b0aeeca170c87c42f4027c0ed1b448b3c4dc | 3805f19edc1930598bf0a14bfab8269e0ad53de7 | refs/heads/master | 2020-04-02T22:55:01.768297 | 2016-05-24T21:44:41 | 2016-05-24T21:44:41 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 777 | java | package com.example.piyushravi.finalapartment;
import android.support.v4.app.NavUtils;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.MenuItem;
public class RepairManage extends AppCompatActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
getSupportActionBar().setTitle(R.string.repair_request);
setContentView(R.layout.activity_repair_request);
}
public boolean onOptionsItemSelected(MenuItem item) {
switch (item.getItemId()) {
case android.R.id.home:
NavUtils.navigateUpFromSameTask(this);
return true;
}
return super.onOptionsItemSelected(item);
}
}
| [
"sowmyan5585@gmail.com"
] | sowmyan5585@gmail.com |
343a512a394c2cf63492d3e4e12af798314562de | cdf71ca8b701cb49a43afd22d3f04d62ce832498 | /src/main/java/eu/leads/api/m36/model/FunM36JsonParams.java | e50d23ca018131016cf5b0e6d77810542c85aa55 | [] | no_license | pskorupinski/leads-wgs-integration-m24 | c80b0208cfe2ebcfb68775aa0502c966751bb85a | 96a4bf537fe488607af7559db2b669866bb16d6f | refs/heads/master | 2020-05-17T02:15:05.157173 | 2015-11-12T15:57:52 | 2015-11-12T15:57:52 | 26,504,953 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,975 | java | package eu.leads.api.m36.model;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
import org.hamcrest.core.IsInstanceOf;
import org.json.JSONArray;
import org.json.JSONException;
import org.json.JSONObject;
import eu.leads.api.m24.FunctionalityAbstParams;
public class FunM36JsonParams extends FunctionalityAbstParams {
private Map<String, Object> map;
public FunM36JsonParams(JSONObject json) {
map = jsonToMap(json);
}
public <T> T getParameter(String key, Class<T> valueType) {
Object obj = map.get(key);
if(valueType.isInstance(obj))
return (T) obj;
else
return null;
}
public static Map<String, Object> jsonToMap(JSONObject json) throws JSONException {
Map<String, Object> retMap = new HashMap<String, Object>();
if(json != JSONObject.NULL) {
retMap = toMap(json);
}
return retMap;
}
public static Map<String, Object> toMap(JSONObject object) throws JSONException {
Map<String, Object> map = new HashMap<String, Object>();
Iterator<String> keysItr = object.keys();
while(keysItr.hasNext()) {
String key = keysItr.next();
Object value = object.get(key);
if(value instanceof JSONArray) {
value = toList((JSONArray) value);
}
else if(value instanceof JSONObject) {
value = toMap((JSONObject) value);
}
map.put(key, value);
}
return map;
}
public static List<Object> toList(JSONArray array) throws JSONException {
List<Object> list = new ArrayList<Object>();
for(int i = 0; i < array.length(); i++) {
Object value = array.get(i);
if(value instanceof JSONArray) {
value = toList((JSONArray) value);
}
else if(value instanceof JSONObject) {
value = toMap((JSONObject) value);
}
list.add(value);
}
return list;
}
}
| [
"pawel.skorupinski@gmail.com"
] | pawel.skorupinski@gmail.com |
a5afb7bb215083cfef1bec36b85bdb6c9c44dfe0 | e7ae866af623e117a7512f827fe6be8a0f85c114 | /Restkeeper/restkeeper_common/src/main/java/com/restkeeper/constants/OrderDetailType.java | 126836e6e2cd1a085cffbeb195576c15129c358d | [] | no_license | zhanzhewan/codes | d32f2fea264cced205f01718420abcccf9e469ae | b3312001545715d04817b250adcb72d8e882a153 | refs/heads/master | 2023-04-21T21:25:29.075964 | 2021-05-20T16:31:38 | 2021-05-20T16:31:38 | 369,271,085 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 411 | java | package com.restkeeper.constants;
import lombok.Getter;
/**
* 菜品订单类型
*/
@Getter
public enum OrderDetailType {
NORMAL_DISH(1,"正常下单"),
PRESENT_DISH(2,"赠菜"),
RETURN_DISH(3,"退菜"),
PLUS_DISH(4,"加菜");
private Integer type;
private String desc;
OrderDetailType(Integer type, String desc) {
this.type = type;
this.desc = desc;
}
}
| [
"5289886+kobe_zzw@user.noreply.gitee.com"
] | 5289886+kobe_zzw@user.noreply.gitee.com |
869fbf420135ce0697796d39e79eae950a90e666 | ebafbaaf156fe563f565301704b88ad64719aef4 | /controllersvc/src/main/java/com/emc/storageos/volumecontroller/impl/smis/job/SmisBlockSnapshotSessionLinkTargetGroupJob.java | 87a6bffd47509c24f37e6f080ecf1822464af996 | [] | no_license | SuzyWu2014/coprhd-controller | 086ae1043c2c0fefd644e7d4192c982ffbeda533 | 5a5e0ecc1d54cd387514f588768e2a918c819aa7 | refs/heads/master | 2021-01-21T09:42:31.339289 | 2016-09-30T19:21:02 | 2016-09-30T19:21:02 | 46,948,031 | 1 | 0 | null | 2015-11-26T21:45:46 | 2015-11-26T21:45:46 | null | UTF-8 | Java | false | false | 11,380 | java | package com.emc.storageos.volumecontroller.impl.smis.job;
import com.emc.storageos.db.client.DbClient;
import com.emc.storageos.db.client.model.BlockObject;
import com.emc.storageos.db.client.model.BlockSnapshot;
import com.emc.storageos.db.client.model.StorageSystem;
import com.emc.storageos.volumecontroller.JobContext;
import com.emc.storageos.volumecontroller.TaskCompleter;
import com.emc.storageos.volumecontroller.impl.NativeGUIDGenerator;
import com.emc.storageos.volumecontroller.impl.smis.CIMConnectionFactory;
import com.emc.storageos.volumecontroller.impl.smis.CIMPropertyFactory;
import com.emc.storageos.volumecontroller.impl.smis.SmisConstants;
import com.google.common.collect.Lists;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import javax.cim.CIMInstance;
import javax.cim.CIMObjectPath;
import javax.wbem.CloseableIterator;
import javax.wbem.WBEMException;
import javax.wbem.client.WBEMClient;
import java.net.URI;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
import static com.emc.storageos.volumecontroller.impl.smis.SmisConstants.CIM_STORAGE_VOLUME;
import static com.emc.storageos.volumecontroller.impl.smis.SmisConstants.CP_DEVICE_ID;
import static com.emc.storageos.volumecontroller.impl.smis.SmisConstants.CP_EMC_RG_SOURCE_INSTANCE_ID;
import static com.emc.storageos.volumecontroller.impl.smis.SmisConstants.CP_EMC_RG_TARGET_INSTANCE_ID;
import static com.emc.storageos.volumecontroller.impl.smis.SmisConstants.CP_SV_SOURCE_DEVICE_ID;
import static com.emc.storageos.volumecontroller.impl.smis.SmisConstants.CP_SV_TARGET_DEVICE_ID;
import static com.emc.storageos.volumecontroller.impl.smis.SmisConstants.PS_REPLICA_PAIR_VIEW;
/**
*
* ViPR Job created when an underlying CIM job is created to create
* and link a new target volume group to a group snapshot point-in-time
* copy represented in ViPR by a BlockSnapshotSession instance.
*
* @author Ian Bibby
*/
public class SmisBlockSnapshotSessionLinkTargetGroupJob extends SmisSnapShotJob {
private static final Logger log = LoggerFactory.getLogger(SmisBlockSnapshotSessionLinkTargetGroupJob.class);
private static final String JOB_NAME = SmisBlockSnapshotSessionLinkTargetGroupJob.class.getSimpleName();
private Map<String, URI> srcNativeIdToSnapshotMap;
private String sourceGroupName;
private String targetGroupName;
private String snapSessionInstance;
public SmisBlockSnapshotSessionLinkTargetGroupJob(CIMObjectPath cimJob, URI storageSystem, TaskCompleter taskCompleter) {
super(cimJob, storageSystem, taskCompleter, JOB_NAME);
}
public void setSrcNativeIdToSnapshotMap(Map<String, URI> srcNativeIdToSnapshotMap) {
this.srcNativeIdToSnapshotMap = srcNativeIdToSnapshotMap;
}
public void setSourceGroupName(String sourceGroupName) {
this.sourceGroupName = sourceGroupName;
}
public void setTargetGroupName(String targetGroupName) {
this.targetGroupName = targetGroupName;
}
public void setSnapSessionInstance(String snapSessionInstance) {
this.snapSessionInstance = snapSessionInstance;
}
@Override
public void updateStatus(JobContext jobContext) throws Exception {
JobStatus jobStatus = getJobStatus();
try {
switch(jobStatus) {
case IN_PROGRESS:
return;
case SUCCESS:
processJobSuccess(jobContext);
break;
case FAILED:
case FATAL_ERROR:
processJobFailure(jobContext);
break;
}
} finally {
super.updateStatus(jobContext);
}
}
private void processJobSuccess(JobContext jobContext) throws Exception {
DbClient dbClient = jobContext.getDbClient();
try {
CIMConnectionFactory cimConnectionFactory = jobContext.getCimConnectionFactory();
WBEMClient client = getWBEMClient(dbClient, cimConnectionFactory);
CIMObjectPath targetRepGrpPath = getAssociatedTargetReplicationGroupPath(client);
log.info("Processing target replication group: {}", targetRepGrpPath);
List<CIMObjectPath> replicaPairViews = getAssociatedReplicaPairViews(client, targetRepGrpPath);
for (CIMObjectPath replicaPairViewPath : replicaPairViews) {
log.info("Processing replica pair view instance: {}", replicaPairViewPath);
CIMInstance replicaPairView = client.getInstance(replicaPairViewPath, false, false, PS_REPLICA_PAIR_VIEW);
// Verify that ReplicaPairView references our groups
String srcGrpInstance = getInstancePropertyValue(replicaPairView, CP_EMC_RG_SOURCE_INSTANCE_ID);
String tgtGrpInstance = getInstancePropertyValue(replicaPairView, CP_EMC_RG_TARGET_INSTANCE_ID);
// ReplicaPairView references src/tgt replication groups as <symm-id>+<group-name>, hence #contains
if (!srcGrpInstance.contains(sourceGroupName) || !tgtGrpInstance.contains(targetGroupName)) {
log.warn("ReplicaPairView did not match source/target groups: {}/{}",
sourceGroupName, targetGroupName);
continue;
}
String srcIdProp = (String) replicaPairView.getPropertyValue(CP_SV_SOURCE_DEVICE_ID);
String tgtIdProp = (String) replicaPairView.getPropertyValue(CP_SV_TARGET_DEVICE_ID);
if (srcNativeIdToSnapshotMap.containsKey(srcIdProp)) {
URI blockSnapshotURI = srcNativeIdToSnapshotMap.get(srcIdProp);
BlockSnapshot snapshot = dbClient.queryObject(BlockSnapshot.class, blockSnapshotURI);
BlockObject sourceObj = BlockObject.fetch(dbClient, snapshot.getParent().getURI());
CIMObjectPath volumePath = getAssociatedTargetVolume(client, replicaPairViewPath, tgtIdProp);
CIMInstance volume = client.getInstance(volumePath, false, false, null);
String volumeElementName = CIMPropertyFactory.getPropertyValue(volume, SmisConstants.CP_ELEMENT_NAME);
log.info("volumeElementName: {}", volumeElementName);
String volumeWWN = CIMPropertyFactory.getPropertyValue(volume, SmisConstants.CP_WWN_NAME);
log.info("volumeWWN: {}", volumeWWN);
String volumeAltName = CIMPropertyFactory.getPropertyValue(volume, SmisConstants.CP_NAME);
log.info("volumeAltName: {}", volumeAltName);
StorageSystem system = dbClient.queryObject(StorageSystem.class, getStorageSystemURI());
snapshot.setNativeId(tgtIdProp);
snapshot.setNativeGuid(NativeGUIDGenerator.generateNativeGuid(system, snapshot));
snapshot.setDeviceLabel(volumeElementName);
snapshot.setInactive(false);
snapshot.setIsSyncActive(Boolean.TRUE);
snapshot.setCreationTime(Calendar.getInstance());
snapshot.setWWN(volumeWWN.toUpperCase());
snapshot.setAlternateName(volumeAltName);
snapshot.setSettingsInstance(snapSessionInstance);
snapshot.setReplicationGroupInstance(tgtGrpInstance);
commonSnapshotUpdate(snapshot, volume, client, system, sourceObj.getNativeId(), tgtIdProp, false, dbClient);
log.info(String
.format("For target volume path %1$s, going to set blocksnapshot %2$s nativeId to %3$s (%4$s). Associated volume is %5$s (%6$s)",
volumePath.toString(), snapshot.getId().toString(), tgtIdProp,
volumeElementName, sourceObj.getNativeId(), sourceObj.getDeviceLabel()));
dbClient.updateObject(snapshot);
}
}
} catch (Exception e) {
setPostProcessingErrorStatus("Internal error in link snapshot session target group job status processing: "
+ e.getMessage());
log.error("Internal error in link snapshot session target group job status processing", e);
throw e;
}
}
private void processJobFailure(JobContext jobContext) {
log.info("Failed to link target group {} to source snap session group {}", targetGroupName, sourceGroupName);
DbClient dbClient = jobContext.getDbClient();
Iterator<BlockSnapshot> iterator = dbClient.queryIterativeObjects(BlockSnapshot.class,
srcNativeIdToSnapshotMap.values());
ArrayList<BlockSnapshot> snapshots = Lists.newArrayList(iterator);
for (BlockSnapshot snapshot : snapshots) {
snapshot.setInactive(true);
}
dbClient.updateObject(snapshots);
}
private List<CIMObjectPath> getAssociatedReplicaPairViews(WBEMClient client, CIMObjectPath targetRepGrpPath) throws WBEMException {
CloseableIterator<CIMObjectPath> it = null;
List<CIMObjectPath> result = new ArrayList<>();
try {
it = client.associatorNames(targetRepGrpPath, null, SmisConstants.SE_REPLICA_PAIR_VIEW, null, null);
while (it.hasNext()) {
result.add(it.next());
}
return result;
} finally {
if (it != null) {
it.close();
}
}
}
private CIMObjectPath getAssociatedTargetReplicationGroupPath(WBEMClient client) throws WBEMException {
CloseableIterator<CIMObjectPath> it = null;
try {
it = client.associatorNames(getCimJob(), null, SmisConstants.SE_REPLICATION_GROUP, null, null);
// Only one group is expected.
if (it.hasNext()) {
return it.next();
}
} finally {
if (it != null) {
it.close();
}
}
throw new IllegalStateException("Expected a single target replication group but found none");
}
private CIMObjectPath getAssociatedTargetVolume(WBEMClient client, CIMObjectPath replicaPairView,
String targetDeviceId) throws WBEMException {
CloseableIterator<CIMObjectPath> it = null;
try {
it = client.associatorNames(replicaPairView, null, CIM_STORAGE_VOLUME, null, null);
while (it.hasNext()) {
CIMObjectPath volume = it.next();
String deviceId = volume.getKeyValue(CP_DEVICE_ID).toString();
if (targetDeviceId.equals(deviceId)) {
return volume;
}
}
} finally {
if (it != null) {
it.close();
}
}
throw new IllegalStateException(
String.format("Expected an associated volume with nativeID %s but found none", targetDeviceId));
}
private String getInstancePropertyValue(CIMInstance instance, String propertyName) {
Object value = instance.getPropertyValue(propertyName);
return value == null ? "" : value.toString();
}
}
| [
"ian.bibby@emc.com"
] | ian.bibby@emc.com |
8fa7482034ea4c2343465dba8d2215fdb9b0ea82 | b00f8606ecb2c6061478b6f7d3abf57142af1a48 | /workspace/workspace/notionsBase/src/boucle/TableMultiplication.java | 932b09e6ba4ef30e0230f786bc1d413f6be628f1 | [] | no_license | xYouPoPx/Eclipse | 2cb9659f95dc26da03e2756b707711c2cfb51fc7 | f3bda2a478d76f589261c8e98f4b4c5b81d41ad6 | refs/heads/master | 2020-09-13T08:20:09.311402 | 2016-08-23T12:37:06 | 2016-08-23T12:37:06 | 66,364,422 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 495 | java | /**
*
*/
package boucle;
import java.util.Scanner;
/**
* @author ycourteau
*
*/
public class TableMultiplication {
/**
* @param args
*/
public static void main(String[] args) {
int val;
int compt = 0;
Scanner scan = new Scanner(System.in);
System.out.println("Entrez un nombre pour faire afficher sa table de multiplication");
val = scan.nextInt();
while(compt <= 10){
System.out.println(val + " x " + compt + " = " + (val * compt));
compt++;
}
}
}
| [
"yolaine.courteau@videotron.ca"
] | yolaine.courteau@videotron.ca |
12ae959d21c68280849d14e6813f7f61a904b2a0 | e37e1598f0640667b7f7d4354acffb8a7f5ee55b | /code/src/main/java/ui/contentpanel/AddRelationDialog.java | 041ac18d1b93b70338d508cf58033a756355cfdf | [] | no_license | mrramazani/ood_code_repository | b1aa68b7f791a04e89e50bf3d9471a8f16158034 | a215570b637e18fd7862c9ef85c975015fdaad64 | refs/heads/master | 2020-12-30T10:23:05.678918 | 2015-08-25T01:11:16 | 2015-08-25T01:11:16 | 40,107,495 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 3,332 | java | package ui.contentpanel;
import content.Content;
import content.ContentCatalogue;
import content.RelationShipType;
import content.Relationship;
import user.ActivityType;
import user.User;
import user.UserActivityLog;
import user.UserCatalogue;
import javax.swing.*;
import java.awt.event.*;
import java.util.Date;
public class AddRelationDialog extends JDialog {
private JPanel contentPane;
private JButton buttonOK;
private JButton buttonCancel;
private JTextField firstContent;
private JTextField secondContent;
private JComboBox comboBox1;
private Content first;
private Content second;
private User user;
public AddRelationDialog() {
initUI();
}
private void initUI() {
setSize(400, 600);
setTitle("ایجاد یک رابطه ی بین محتوایی");
setContentPane(contentPane);
setModal(true);
getRootPane().setDefaultButton(buttonOK);
buttonOK.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent e) {
addRelation();
}
});
buttonCancel.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent e) {
onCancel();
}
});
for (RelationShipType x: RelationShipType.values())
comboBox1.addItem(x);
setDefaultCloseOperation(DO_NOTHING_ON_CLOSE);
addWindowListener(new WindowAdapter() {
public void windowClosing(WindowEvent e) {
onCancel();
}
});
contentPane.registerKeyboardAction(new ActionListener() {
public void actionPerformed(ActionEvent e) {
onCancel();
}
}, KeyStroke.getKeyStroke(KeyEvent.VK_ESCAPE, 0), JComponent.WHEN_ANCESTOR_OF_FOCUSED_COMPONENT);
}
public AddRelationDialog(Content first, User user) {
this.first = first;
this.user = user;
initUI();
firstContent.setText(first.getName());
firstContent.setEnabled(false);
}
public Content getFirst() {
return first;
}
public void setFirst(Content first) {
this.first = first;
}
public Content getSecond() {
return second;
}
public void setSecond(Content second) {
this.second = second;
}
public User getUser() {
return user;
}
public void setUser(User user) {
this.user = user;
}
private void addRelation() {
ContentCatalogue contentCatalogue = new ContentCatalogue();
UserCatalogue userCatalogue = new UserCatalogue();
Content content2 = contentCatalogue.search(secondContent.getText());
if (content2 == null) {
JOptionPane.showMessageDialog(this, "محتوای دوم وجود ندارد");
dispose();
}
this.second = content2;
contentCatalogue.addRelation(new Relationship(first, second, (RelationShipType)comboBox1.getSelectedItem()));
userCatalogue.addUserActivity(new UserActivityLog(user, ActivityType.UPDATE, new Date(), "ایجاد رابطه برای محتواهای " + first.getName() + ", " + second.getName()));
dispose();
}
private void onCancel() {
dispose();
}
}
| [
"mrramazani@yahoo.com"
] | mrramazani@yahoo.com |
541e2bcc8a9356e72876e6cee543a8b677da6716 | d275b1dda701a81a006b1c831271fbb4e70a7789 | /src/test/java/org/tvbookmarks/app/web/rest/AuditResourceIT.java | 3577b5dd07b8c83938ae98615459aa377a236a01 | [] | no_license | fabriz4/JhipsterProject | c4578293e4da3b074faef6ec2818579a4799221e | f69f3625316d1369f549f847062750c24a10f58c | refs/heads/master | 2022-12-22T05:33:14.631195 | 2020-05-28T13:25:43 | 2020-05-28T13:25:43 | 234,276,876 | 2 | 0 | null | 2022-12-16T05:03:57 | 2020-01-16T08:57:57 | Java | UTF-8 | Java | false | false | 6,635 | java | package org.tvbookmarks.app.web.rest;
import org.tvbookmarks.app.TvBookMarksApp;
import org.tvbookmarks.app.config.audit.AuditEventConverter;
import org.tvbookmarks.app.domain.PersistentAuditEvent;
import org.tvbookmarks.app.repository.PersistenceAuditEventRepository;
import org.tvbookmarks.app.service.AuditEventService;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
import org.mockito.MockitoAnnotations;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.data.web.PageableHandlerMethodArgumentResolver;
import org.springframework.format.support.FormattingConversionService;
import org.springframework.http.MediaType;
import org.springframework.http.converter.json.MappingJackson2HttpMessageConverter;
import org.springframework.test.web.servlet.MockMvc;
import org.springframework.test.web.servlet.setup.MockMvcBuilders;
import org.springframework.transaction.annotation.Transactional;
import java.time.Instant;
import static org.assertj.core.api.AssertionsForClassTypes.assertThat;
import static org.hamcrest.Matchers.hasItem;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.*;
/**
* Integration tests for the {@link AuditResource} REST controller.
*/
@SpringBootTest(classes = TvBookMarksApp.class)
@Transactional
public class AuditResourceIT {
private static final String SAMPLE_PRINCIPAL = "SAMPLE_PRINCIPAL";
private static final String SAMPLE_TYPE = "SAMPLE_TYPE";
private static final Instant SAMPLE_TIMESTAMP = Instant.parse("2015-08-04T10:11:30Z");
private static final long SECONDS_PER_DAY = 60 * 60 * 24;
@Autowired
private PersistenceAuditEventRepository auditEventRepository;
@Autowired
private AuditEventConverter auditEventConverter;
@Autowired
private MappingJackson2HttpMessageConverter jacksonMessageConverter;
@Autowired
@Qualifier("mvcConversionService")
private FormattingConversionService formattingConversionService;
@Autowired
private PageableHandlerMethodArgumentResolver pageableArgumentResolver;
private PersistentAuditEvent auditEvent;
private MockMvc restAuditMockMvc;
@BeforeEach
public void setup() {
MockitoAnnotations.initMocks(this);
AuditEventService auditEventService =
new AuditEventService(auditEventRepository, auditEventConverter);
AuditResource auditResource = new AuditResource(auditEventService);
this.restAuditMockMvc = MockMvcBuilders.standaloneSetup(auditResource)
.setCustomArgumentResolvers(pageableArgumentResolver)
.setConversionService(formattingConversionService)
.setMessageConverters(jacksonMessageConverter).build();
}
@BeforeEach
public void initTest() {
auditEventRepository.deleteAll();
auditEvent = new PersistentAuditEvent();
auditEvent.setAuditEventType(SAMPLE_TYPE);
auditEvent.setPrincipal(SAMPLE_PRINCIPAL);
auditEvent.setAuditEventDate(SAMPLE_TIMESTAMP);
}
@Test
public void getAllAudits() throws Exception {
// Initialize the database
auditEventRepository.save(auditEvent);
// Get all the audits
restAuditMockMvc.perform(get("/management/audits"))
.andExpect(status().isOk())
.andExpect(content().contentType(MediaType.APPLICATION_JSON_UTF8_VALUE))
.andExpect(jsonPath("$.[*].principal").value(hasItem(SAMPLE_PRINCIPAL)));
}
@Test
public void getAudit() throws Exception {
// Initialize the database
auditEventRepository.save(auditEvent);
// Get the audit
restAuditMockMvc.perform(get("/management/audits/{id}", auditEvent.getId()))
.andExpect(status().isOk())
.andExpect(content().contentType(MediaType.APPLICATION_JSON_UTF8_VALUE))
.andExpect(jsonPath("$.principal").value(SAMPLE_PRINCIPAL));
}
@Test
public void getAuditsByDate() throws Exception {
// Initialize the database
auditEventRepository.save(auditEvent);
// Generate dates for selecting audits by date, making sure the period will contain the audit
String fromDate = SAMPLE_TIMESTAMP.minusSeconds(SECONDS_PER_DAY).toString().substring(0, 10);
String toDate = SAMPLE_TIMESTAMP.plusSeconds(SECONDS_PER_DAY).toString().substring(0, 10);
// Get the audit
restAuditMockMvc.perform(get("/management/audits?fromDate="+fromDate+"&toDate="+toDate))
.andExpect(status().isOk())
.andExpect(content().contentType(MediaType.APPLICATION_JSON_UTF8_VALUE))
.andExpect(jsonPath("$.[*].principal").value(hasItem(SAMPLE_PRINCIPAL)));
}
@Test
public void getNonExistingAuditsByDate() throws Exception {
// Initialize the database
auditEventRepository.save(auditEvent);
// Generate dates for selecting audits by date, making sure the period will not contain the sample audit
String fromDate = SAMPLE_TIMESTAMP.minusSeconds(2*SECONDS_PER_DAY).toString().substring(0, 10);
String toDate = SAMPLE_TIMESTAMP.minusSeconds(SECONDS_PER_DAY).toString().substring(0, 10);
// Query audits but expect no results
restAuditMockMvc.perform(get("/management/audits?fromDate=" + fromDate + "&toDate=" + toDate))
.andExpect(status().isOk())
.andExpect(content().contentType(MediaType.APPLICATION_JSON_UTF8_VALUE))
.andExpect(header().string("X-Total-Count", "0"));
}
@Test
public void getNonExistingAudit() throws Exception {
// Get the audit
restAuditMockMvc.perform(get("/management/audits/{id}", Long.MAX_VALUE))
.andExpect(status().isNotFound());
}
@Test
@Transactional
public void testPersistentAuditEventEquals() throws Exception {
TestUtil.equalsVerifier(PersistentAuditEvent.class);
PersistentAuditEvent auditEvent1 = new PersistentAuditEvent();
auditEvent1.setId(1L);
PersistentAuditEvent auditEvent2 = new PersistentAuditEvent();
auditEvent2.setId(auditEvent1.getId());
assertThat(auditEvent1).isEqualTo(auditEvent2);
auditEvent2.setId(2L);
assertThat(auditEvent1).isNotEqualTo(auditEvent2);
auditEvent1.setId(null);
assertThat(auditEvent1).isNotEqualTo(auditEvent2);
}
}
| [
"luca.petralia@aitho.it"
] | luca.petralia@aitho.it |
c399177d58119490d62b883e957a1573cb522bfa | 06216b5c8a0510c989908027967dc0b5aaafefef | /PhatTrienHeThongTichHop1/Lab3_Bai2_RMI/src/ClientRMILab3Bai2/Client.java | bede4d5b23eab0ad9eb112ddecdbe89be16c3100 | [] | no_license | tuansieunhan2000/PhatTrienHeThongTichHop | f4465c79451ab591ae594b3e2e51cc012e201558 | bdf16253db5a857f8fa033cb8cf76b6bdae1aa04 | refs/heads/master | 2023-03-08T09:38:49.572711 | 2020-10-27T03:01:30 | 2020-10-27T03:01:30 | 301,596,554 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 789 | java | package ClientRMILab3Bai2;
import java.io.IOException;
import java.net.MalformedURLException;
import java.rmi.Naming;
import java.rmi.NotBoundException;
import java.rmi.RemoteException;
import java.util.Scanner;
import javax.naming.NameAlreadyBoundException;
import javax.swing.JOptionPane;
import InterfaceLab3Bai2.XuLy;
public class Client {
private static XuLy look_up;
public static void main(String[] args) throws NotBoundException, IOException {
// TODO Auto-generated method stub
XuLy xuLy = (XuLy) Naming.lookup("rmi://localhost/xuLy");
System.out.println("Nhap ten quyen sach can tim: ");
Scanner scanner = new Scanner(System.in);
String txt=scanner.nextLine();
String response = look_up.TextSearch(txt);
JOptionPane.showMessageDialog(null, response);
}
}
| [
"trananhtuan.kg2000@gmail.com"
] | trananhtuan.kg2000@gmail.com |
03b3bb0533c6cc7a77eb070da427c97563e622ee | fa91450deb625cda070e82d5c31770be5ca1dec6 | /Diff-Raw-Data/14/14_dfba9c6863552cd3613cf3fbb053ef9e23989efe/Frontend/14_dfba9c6863552cd3613cf3fbb053ef9e23989efe_Frontend_s.java | 776685c2398523d96cb4f3cc7f640b028bad1868 | [] | no_license | zhongxingyu/Seer | 48e7e5197624d7afa94d23f849f8ea2075bcaec0 | c11a3109fdfca9be337e509ecb2c085b60076213 | refs/heads/master | 2023-07-06T12:48:55.516692 | 2023-06-22T07:55:56 | 2023-06-22T07:55:56 | 259,613,157 | 6 | 2 | null | 2023-06-22T07:55:57 | 2020-04-28T11:07:49 | null | UTF-8 | Java | false | false | 2,895 | java | /*
* Copyright (c) 2009-2010, IETR/INSA of Rennes
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* * Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
* * Neither the name of the IETR/INSA of Rennes nor the names of its
* contributors may be used to endorse or promote products derived from this
* software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY
* WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*/
package net.sf.orcc.frontend;
import java.io.File;
import java.util.List;
import net.sf.orcc.OrccException;
import net.sf.orcc.OrccRuntimeException;
import net.sf.orcc.cal.cal.AstActor;
import net.sf.orcc.ir.Actor;
import net.sf.orcc.ir.serialize.IRWriter;
import org.eclipse.emf.ecore.resource.Resource.Diagnostic;
import com.google.inject.Inject;
/**
* This class defines an RVC-CAL front-end.
*
* @author Matthieu Wipliez
*
*/
public class Frontend {
@Inject
private AstTransformer astTransformer;
/**
* output folder
*/
private File outputFolder;
public Frontend() {
}
public void compile(String file, AstActor astActor) throws OrccException {
// only compile if actor has no errors
List<Diagnostic> errors = astActor.eResource().getErrors();
if (errors.isEmpty()) {
try {
Actor actor = astTransformer.transform(file, astActor);
new IRWriter(actor).write(outputFolder.toString());
} catch (OrccRuntimeException e) {
throw new OrccException(e.getMessage(), e);
}
}
}
public void setOutputFolder(String outputFolder) {
this.outputFolder = new File(outputFolder);
}
}
| [
"yuzhongxing88@gmail.com"
] | yuzhongxing88@gmail.com |
5d793aba33e7a75d864306d3b33b6c76de5349f5 | e5f0f957a4ab209cb7148c97759619c835b4d014 | /src/main/java/com/example/user/controller/UserController.java | cb4fed354424a8c727e08c14ad8d5a5e14e6484d | [] | no_license | Shin-JungYeon/demo | aadbd8c097763baca7724798f3494d55892a436f | 0cc23d2390c2be7f98d5fb8be2deee7301e2ed0c | refs/heads/master | 2022-11-26T05:59:14.830923 | 2022-07-25T07:39:20 | 2022-07-25T07:39:20 | 247,005,710 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 520 | java | package com.example.user.controller;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
@Controller
public class UserController {
/**
* 사용자 페이지 이동 ( 새로고침 시 사용 됨 )
*/
@RequestMapping(value ={ "/user/**"}, method = RequestMethod.GET)
public String getUserIndex() {
System.out.println("나 탄당");
return "user/index";
}
}
| [
"ssjy11@gmail.com"
] | ssjy11@gmail.com |
132d26994f7f0706085c84199924720fe0451c3f | 2258ae8f4b5e018d189e4eb6cb95e81007932885 | /STARS/sense.diagram/src/sense/diagram/part/SenseDiagramUpdateCommand.java | 4d34f9f17b24a9b47fa8e28aa247c182751b164f | [] | no_license | utwente-fmt/STARS | f918aeb3006e1aa855532ab0f6d677a9a2524d40 | be225fcffd06f941d685b0beecadfa710938407f | refs/heads/master | 2021-01-10T02:04:14.319098 | 2016-04-11T09:48:14 | 2016-04-11T09:48:14 | 53,322,719 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,194 | java | /*
*
*/
package sense.diagram.part;
import java.util.Iterator;
import java.util.List;
import org.eclipse.core.commands.ExecutionEvent;
import org.eclipse.core.commands.ExecutionException;
import org.eclipse.core.commands.IHandler;
import org.eclipse.core.commands.IHandlerListener;
import org.eclipse.emf.ecore.EObject;
import org.eclipse.gef.EditPart;
import org.eclipse.gmf.runtime.diagram.ui.editpolicies.CanonicalEditPolicy;
import org.eclipse.gmf.runtime.notation.View;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.ui.PlatformUI;
/**
* @generated
*/
public class SenseDiagramUpdateCommand implements IHandler {
/**
* @generated
*/
public void addHandlerListener(IHandlerListener handlerListener) {
}
/**
* @generated
*/
public void dispose() {
}
/**
* @generated
*/
public Object execute(ExecutionEvent event) throws ExecutionException {
ISelection selection = PlatformUI.getWorkbench()
.getActiveWorkbenchWindow().getSelectionService()
.getSelection();
if (selection instanceof IStructuredSelection) {
IStructuredSelection structuredSelection = (IStructuredSelection) selection;
if (structuredSelection.size() != 1) {
return null;
}
if (structuredSelection.getFirstElement() instanceof EditPart
&& ((EditPart) structuredSelection.getFirstElement())
.getModel() instanceof View) {
EObject modelElement = ((View) ((EditPart) structuredSelection
.getFirstElement()).getModel()).getElement();
List editPolicies = CanonicalEditPolicy
.getRegisteredEditPolicies(modelElement);
for (Iterator it = editPolicies.iterator(); it.hasNext();) {
CanonicalEditPolicy nextEditPolicy = (CanonicalEditPolicy) it
.next();
nextEditPolicy.refresh();
}
}
}
return null;
}
/**
* @generated
*/
public boolean isEnabled() {
return true;
}
/**
* @generated
*/
public boolean isHandled() {
return true;
}
/**
* @generated
*/
public void removeHandlerListener(IHandlerListener handlerListener) {
}
}
| [
"jjgmeijer@gmail.com"
] | jjgmeijer@gmail.com |
098df247f7cc713571e7ee429b790c7d51dbb9aa | 1fc4de4330efc7e561f5d71566963e5dc799c6db | /src/main/java/com/devebot/opflow/exception/OpflowRequestTimeoutException.java | 4d6f33d83bfc0acfd01f62cc48a9b7c13d7535a9 | [] | no_license | opflow/opflow-java | 1f156b408f87e4c5073dce4b501804674214729a | c1e2e5127574075d39e3231fbffde8bc8df621ff | refs/heads/master | 2022-09-30T03:51:23.087455 | 2020-07-07T04:02:33 | 2020-07-07T04:02:33 | 98,799,394 | 5 | 4 | null | 2022-08-18T19:06:25 | 2017-07-30T13:30:21 | Java | UTF-8 | Java | false | false | 703 | java | package com.devebot.opflow.exception;
/**
*
* @author drupalex
*/
public class OpflowRequestTimeoutException extends OpflowOperationException {
public OpflowRequestTimeoutException() {
}
public OpflowRequestTimeoutException(String message) {
super(message);
}
public OpflowRequestTimeoutException(String message, Throwable cause) {
super(message, cause);
}
public OpflowRequestTimeoutException(Throwable cause) {
super(cause);
}
public OpflowRequestTimeoutException(String message, Throwable cause, boolean enableSuppression, boolean writableStackTrace) {
super(message, cause, enableSuppression, writableStackTrace);
}
}
| [
"pnhung177@acegik.net"
] | pnhung177@acegik.net |
7d44f60e78ef1050f48254e5cc85de36db84f36f | 929f13780c6d173845cce613b982e0a77a84fd25 | /examples/src/main/java/fr/bmartel/speedtest/examples/FixedTimeUploadExample.java | 03d5d9d636997e0f5572a6afd5affc3f5e3712ca | [
"MIT"
] | permissive | richard457/speed-test-lib | 671cef555f059afdeeea27225d759af49c933ab4 | 74c8f593f904c5186b2949b8a6f0bc7b726cc136 | refs/heads/master | 2021-06-21T04:42:56.619086 | 2017-07-18T19:08:21 | 2017-07-18T19:08:21 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 3,699 | java | /*
* The MIT License (MIT)
* <p/>
* Copyright (c) 2016-2017 Bertrand Martel
* <p/>
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
* <p/>
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
* <p/>
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
package fr.bmartel.speedtest.examples;
import fr.bmartel.speedtest.SpeedTestReport;
import fr.bmartel.speedtest.SpeedTestSocket;
import fr.bmartel.speedtest.inter.ISpeedTestListener;
import fr.bmartel.speedtest.model.SpeedTestError;
import fr.bmartel.speedtest.model.SpeedTestMode;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
/**
* Begin to upload a file from server & stop uploading when test duration is elapsed.
*
* @author Bertrand Martel
*/
public class FixedTimeUploadExample {
/**
* spedd examples server uri.
*/
private static final String SPEED_TEST_SERVER_URI_UL = "http://2.testdebit.info/";
/**
* upload 10Mo file size.
*/
private static final int FILE_SIZE = 100000000;
/**
* amount of time between each speed test reports set to 1s.
*/
private static final int REPORT_INTERVAL = 1000;
/**
* speed test duration set to 15s.
*/
private static final int SPEED_TEST_DURATION = 15000;
/**
* logger.
*/
private final static Logger LOGGER = LogManager.getLogger(FixedTimeUploadExample.class.getName());
/**
* Fixed time upload example main.
*
* @param args no args required
*/
public static void main(final String[] args) {
final SpeedTestSocket speedTestSocket = new SpeedTestSocket();
//speedTestSocket.setUploadStorageType(UploadStorageType.FILE_STORAGE);
speedTestSocket.addSpeedTestListener(new ISpeedTestListener() {
@Override
public void onError(final SpeedTestError speedTestError, final String errorMessage) {
if (LOGGER.isErrorEnabled()) {
LOGGER.error(errorMessage);
}
}
@Override
public void onCompletion(final SpeedTestReport report) {
//called when upload is finished
LogUtils.logFinishedTask(SpeedTestMode.UPLOAD, report.getTotalPacketSize(),
report.getTransferRateBit(),
report.getTransferRateOctet(), LOGGER);
}
@Override
public void onProgress(final float percent, final SpeedTestReport uploadReport) {
//notify progress
LogUtils.logSpeedTestReport(uploadReport, LOGGER);
}
});
speedTestSocket.startFixedUpload(SPEED_TEST_SERVER_URI_UL,
FILE_SIZE, SPEED_TEST_DURATION, REPORT_INTERVAL);
}
}
| [
"bmartel.fr@gmail.com"
] | bmartel.fr@gmail.com |
2a974ba602d8cd64ac69663330d4ab4593dcf15a | 21eb7e70c8f95034b6d0b5c264af1951f64617bb | /workathome/src/com/udemy/genericchallenge/CricketTeam.java | 02f59259fa1c28fd14451b8c0108c6ca2fde5a3a | [] | no_license | aacshwin/dsa-practice | d5fe2bbf4ce381705ae920a4c9a0c670da2e54b6 | bed7e7b2c08901b477e91ce47403687a4f0a65e5 | refs/heads/master | 2023-09-01T15:25:28.160356 | 2021-10-27T11:50:33 | 2021-10-27T11:50:33 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 175 | java | package com.udemy.genericchallenge;
public class CricketTeam extends Team{
public CricketTeam(String name) {
super(name);
// TODO Auto-generated constructor stub
}
}
| [
"aacshwinravichandran@Aacshwins-MacBook-Pro.local"
] | aacshwinravichandran@Aacshwins-MacBook-Pro.local |
55726bf80dca4210e46f5950754b977bfec4f593 | c389bf3d279f19b5125470de0719e98abc8eb72b | /AdapterPattern_Practice_Birds/src/Turkey.java | 989934fca19c01dcf6cd4c6d5aa2e70fc7fe0baf | [] | no_license | brianroytman/DesignPatternsPractice | 89af74a89decf113d0404749c41fd4590898cf80 | e77f6b4c6f549430d3ac660965c1fcb0200563f0 | refs/heads/master | 2021-01-10T12:52:16.067258 | 2015-10-26T20:09:53 | 2015-10-26T20:09:53 | 44,923,106 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 74 | java |
public interface Turkey {
public void gobble();
public void fly();
}
| [
"brian.roytman@gmail.com"
] | brian.roytman@gmail.com |
28a5066e77b354fa4efe95983638aebdf2bfa54a | 616c89d821dad7641e2a60bb3f1e99dff35fd2e1 | /src/main/java/com/autentia/tutorials/fsm/CustomAction.java | 68428f617da0f6ff82c1b10c7bd90f49196d32cf | [] | no_license | DVentas/FSM | 478004550a684b5db7b76d2f9965374eb4d4acac | 5048304d5fc6f4a351bc9856534a4f2e7cceac0c | refs/heads/master | 2021-01-04T02:36:09.344572 | 2014-02-04T14:16:24 | 2014-02-04T14:16:24 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,016 | java | package com.autentia.tutorials.fsm;
import java.util.Collection;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.commons.scxml.ErrorReporter;
import org.apache.commons.scxml.EventDispatcher;
import org.apache.commons.scxml.SCInstance;
import org.apache.commons.scxml.SCXMLExpressionException;
import org.apache.commons.scxml.model.Action;
import org.apache.commons.scxml.model.ModelException;
public class CustomAction extends Action{
private static final Log LOGGER = LogFactory.getLog(CustomAction.class);
private static final long serialVersionUID = 1L;
String action;
public CustomAction(String action){
super();
this.action = action;
}
@Override
public void execute(EventDispatcher evtDispatcher, ErrorReporter errRep,
SCInstance scInstance, Log appLog, Collection derivedEvents)
throws ModelException, SCXMLExpressionException {
LOGGER.info(action);
}
public void setAction(String action){
this.action = action;
}
}
| [
"dventas@autentia.com"
] | dventas@autentia.com |
e8f2676374a28b55e572b3a3c4648e64d530abfc | c2b15f5121704eab2a21ce43cfccaf52737cabd2 | /src/main/java/com/w2m/superheros/configuration/SpringFoxConfig.java | 7967e1406a818ece0f2e7a6794623f3b993e7d86 | [] | no_license | rmartinez6/superheros | a24ca55f746d1ad9bcafb7af388b983befa9d9a3 | 6840c735b52c95de887fa83c5f71f8b37bbfcb01 | refs/heads/main | 2023-05-31T00:03:04.951586 | 2021-06-14T03:06:10 | 2021-06-14T03:06:10 | 375,052,627 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,371 | java | package com.w2m.superheros.configuration;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import springfox.documentation.builders.ApiInfoBuilder;
import springfox.documentation.builders.PathSelectors;
import springfox.documentation.builders.RequestHandlerSelectors;
import springfox.documentation.service.ApiInfo;
import springfox.documentation.service.Contact;
import springfox.documentation.spi.DocumentationType;
import springfox.documentation.spring.web.plugins.Docket;
@Configuration
public class SpringFoxConfig {
@Bean
public Docket api() {
return new Docket(DocumentationType.SWAGGER_2)
.select()
.apis(RequestHandlerSelectors.basePackage("com.w2m.superheros.controller"))
.paths(PathSelectors.any())
.build()
.apiInfo(getApiInfo());
}
private ApiInfo getApiInfo() {
return new ApiInfoBuilder()
.title("Spring Boot REST API by SuperHeros")
.version("1.0.0")
.license("Apache License Version 2.0")
.licenseUrl("https://www.apache.org/licenses/LICENSE-2.0\"")
.contact(new Contact("Rodrigo Martinez", "https://github.com/rmartinez6/superheros", "rdmartinez6@gmail.com"))
.build();
}
}
| [
"rmartinez@MacBook-Pro-de-rodrigo.local"
] | rmartinez@MacBook-Pro-de-rodrigo.local |
0ec360446af05867c61aa26d0e04be4de494eef1 | 87ffef047a2e9807a4787e250fe6b3c7a31062e1 | /src/main/java/cinema/model/Order.java | 821458f301ea01f8c70793ce0f81fb68f3d762b3 | [] | no_license | Mzuha/cinema-service | 776eb225ea3b0745dda333dfa4d60048764c07fa | 000957663b76422b338abb787b046e2393f24090 | refs/heads/main | 2023-07-25T15:23:27.565211 | 2021-08-30T14:25:55 | 2021-08-30T14:25:55 | 394,948,953 | 2 | 0 | null | 2021-08-30T14:25:56 | 2021-08-11T10:22:53 | Java | UTF-8 | Java | false | false | 1,535 | java | package cinema.model;
import java.time.LocalDateTime;
import java.util.List;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;
import javax.persistence.Table;
@Entity
@Table(name = "orders")
public class Order {
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Long id;
@OneToMany
private List<Ticket> tickets;
@Column(name = "order_time")
private LocalDateTime orderTime;
@ManyToOne
@JoinColumn(name = "user_id")
private User user;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public List<Ticket> getTickets() {
return tickets;
}
public void setTickets(List<Ticket> tickets) {
this.tickets = tickets;
}
public LocalDateTime getOrderTime() {
return orderTime;
}
public void setOrderTime(LocalDateTime orderTime) {
this.orderTime = orderTime;
}
public User getUser() {
return user;
}
public void setUser(User user) {
this.user = user;
}
@Override
public String toString() {
return "Order{"
+ "id=" + id
+ ", tickets=" + tickets
+ ", orderTime=" + orderTime
+ ", user=" + user + '}';
}
}
| [
"vovabilodon@gmail.com"
] | vovabilodon@gmail.com |
cd5024add6b0600855dcaa0f39d9c745785ceeee | 94cc4b6461adcae77c6d046d3811a131e8dd03f5 | /portal-usuarios/src/main/java/com/dev/services/impl/ServiceHistorialImpl.java | 159a8883cfb8ba6796aa76954cfbfd277b32dff8 | [
"Apache-2.0"
] | permissive | jpnouchi/proyecto2 | 53d1781a622ec6e37912110b3fb600c5013824be | fe75d10e516e0659c245557d4e3301653bcdac02 | refs/heads/master | 2021-01-23T08:15:40.530156 | 2014-08-25T02:28:30 | 2014-08-25T02:28:30 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,803 | java | package com.dev.services.impl;
import com.dev.domain.mapper.UsuarioMapper;
import com.dev.domain.model.Filtro;
import com.dev.domain.model.Historial;
import com.dev.services.ServiceHistorial;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;
/**
* Created with IntelliJ IDEA.
* User: jpnouchi
* Date: 15/08/14
* Time: 06:56
* To change this template use File | Settings | File Templates.
*/
@Service
public class ServiceHistorialImpl implements ServiceHistorial {
@Autowired
private UsuarioMapper usuarioMapper;
@Override
public Historial get(int id) {
return null; //To change body of implemented methods use File | Settings | File Templates.
}
@Override
public List<Historial> getAll() {
return null; //To change body of implemented methods use File | Settings | File Templates.
}
@Override
public void save(Historial historial) {
//To change body of implemented methods use File | Settings | File Templates.
}
@Override
public void update(Historial historial) {
//To change body of implemented methods use File | Settings | File Templates.
}
@Override
public void delete(Historial historial) {
//To change body of implemented methods use File | Settings | File Templates.
}
@Override
public List<Historial> findHistorial(Filtro filtro) {
return usuarioMapper.findHistorial(filtro); //To change body of implemented methods use File | Settings | File Templates.
}
@Override
public void addHistorial(Historial historial) {
//To change body of implemented methods use File | Settings | File Templates.
usuarioMapper.addHistorial(historial);
}
}
| [
"jpnouchi@gmail.com"
] | jpnouchi@gmail.com |
5946eb6c4f162343487bb9b22e2d6fad9d719d25 | 6521cd19048c28034f794a7344dd44e91be588fc | /src/com/company/algoritms/examples/heap/Heap.java | 5d7a4476b55832894595da356c42040e61ac7208 | [] | no_license | jegius/algoritmsjava | d6056d06f05c8b8e786442d66e691cfb0a8656b0 | 4b20dc578d1a49e0dc86df44b18a3499207a3bac | refs/heads/master | 2020-05-30T18:23:01.894315 | 2019-08-18T23:29:24 | 2019-08-18T23:29:24 | 189,896,302 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 4,940 | java | package com.company.algoritms.examples.heap;
import com.company.algoritms.examples.ExampleCollection;
/**
* Частный случай бинарного дерева. Все операции выполняются за время O(log N).
* Можно использовать для сортировки, вкладывая элементы методом insert и удаляя методом remove
* извлекаться из пирамиды элементы будут в отсортированном виде. Эффективность соритровки с
* помощью пирамиды O(n * log N) Основная задержка идет на врмемя перемешиня элементов вверх. Преимущество
* пирамидальной сортировки перед мысторй соритровкой в том что немотря на то что она немного медленнее, она
* всегда выполняется за одно и тоже время, в то время как быстрая сортировка в некоторых случаех может выполняться
* за время O(pow(2, N))
* */
public class Heap implements ExampleCollection<Long> {
private Node<Long>[] heapArray;
private int maxSize;
private int currentSize;
public Heap(int maxSize) {
this.maxSize = maxSize;
this.currentSize = 0;
this.heapArray = new Node[maxSize];
}
public boolean isEmpty() {
return currentSize == 0;
}
public boolean insert(int key, Long data) {
if (currentSize == maxSize) {
return false;
}
Node<Long> newNode = new Node(key, data);
heapArray[currentSize] = newNode;
trickleUp(currentSize++);
return true;
}
public Node remove() {
Node root = heapArray[0];
heapArray[0] = heapArray[--currentSize];
trickleDown(0);
return root;
}
@Override
public void insert(Long value) {
insert(value.intValue(), (long) (Math.random() * 100));
}
public boolean change(int index, int newValue) {
if (index < 0 || index >= currentSize) {
return false;
}
long oldValue = heapArray[index].getKey();
heapArray[index].setKey(newValue);
if (oldValue < newValue) {
trickleUp(index);
} else {
trickleDown(index);
}
return true;
}
public void display() {
System.out.print("HeapArray: ");
for (int index = 0; index < currentSize; index++) {
if (heapArray[index] != null) {
System.out.print(heapArray[index].getKey() + " ");
} else {
System.out.print("-- ");
}
}
System.out.println();
int blanks = 32;
int itmsPerRow = 1;
int column = 0;
int index = 0;
String dots = "............................";
System.out.println(dots + dots);
while (currentSize > 0) {
if (column == 0) {
for (int innerIndex = 0; innerIndex < blanks; innerIndex++) {
System.out.print(' ');
}
}
System.out.print(heapArray[index].getKey());
if (++index == currentSize) {
break;
}
if (++column == itmsPerRow) {
blanks /= 2;
itmsPerRow *= 2;
column = 0;
System.out.println();
} else {
for (int innerIndex = 0; innerIndex < blanks * 2 - 2; innerIndex++) {
System.out.print(' ');
}
}
}
System.out.println("\n" + dots + dots);
}
private void trickleDown(int index) {
int largerChild;
Node top = heapArray[index];
while (index < currentSize / 2) {
int leftChild = 2 * index + 1;
int rightChild = leftChild + 1;
if (rightChild < currentSize &&
heapArray[leftChild].getKey() < heapArray[rightChild].getKey()) {
largerChild = rightChild;
} else {
largerChild = leftChild;
}
if (top.getKey() >= heapArray[largerChild].getKey()) {
break;
}
heapArray[index] = heapArray[largerChild];
index = largerChild;
}
heapArray[index] = top;
}
private void trickleUp(int index) {
int parent = (index - 1) / 2;
Node bottom = heapArray[index];
while (index > 0 && heapArray[parent].getKey() < bottom.getKey()) {
heapArray[index] = heapArray[parent];
index = parent;
parent = (parent - 1) / 2;
}
heapArray[index] = bottom;
}
}
| [
"jegius@gmail.com"
] | jegius@gmail.com |
233d7b92b27ad632a3856acbbd960ba79cbb298e | e0bc2f5563ccf72946f7ea8ed21ed1438144b398 | /app/src/main/java/com/example/kouveepetshop/api/ApiPengadaan.java | b006f09e6ad5694288b4f61e778ce4d7fdc2a58e | [] | no_license | mirokub/KouveePetShop | c401d3990b229dfb1acfe883492cbc6fdafd923f | 255d1f200544481a859de38e3e3f980ab3defaca | refs/heads/master | 2021-03-26T07:35:45.858115 | 2020-06-12T03:48:02 | 2020-06-12T03:48:02 | 247,684,620 | 0 | 0 | null | 2020-06-12T03:48:03 | 2020-03-16T11:26:27 | Java | UTF-8 | Java | false | false | 3,187 | java | package com.example.kouveepetshop.api;
import com.example.kouveepetshop.model.DetailPengadaanModel;
import com.example.kouveepetshop.model.DetailPenjualanProdukModel;
import com.example.kouveepetshop.model.PengadaanModel;
import com.example.kouveepetshop.model.PenjualanProdukModel;
import com.example.kouveepetshop.result.pengadaan.ResultDetailPengadaan;
import com.example.kouveepetshop.result.pengadaan.ResultOneDetailPengadaan;
import com.example.kouveepetshop.result.pengadaan.ResultOnePengadaan;
import com.example.kouveepetshop.result.pengadaan.ResultPengadaan;
import com.example.kouveepetshop.result.penjualan_produk.ResultDetailProduk;
import com.example.kouveepetshop.result.penjualan_produk.ResultOneDetailProduk;
import com.example.kouveepetshop.result.penjualan_produk.ResultOnePenjualanProduk;
import com.example.kouveepetshop.result.penjualan_produk.ResultPenjualanProduk;
import com.example.kouveepetshop.result.produk.ResultProduk;
import okhttp3.ResponseBody;
import retrofit2.Call;
import retrofit2.http.Body;
import retrofit2.http.DELETE;
import retrofit2.http.Field;
import retrofit2.http.FormUrlEncoded;
import retrofit2.http.GET;
import retrofit2.http.POST;
import retrofit2.http.PUT;
import retrofit2.http.Path;
public interface ApiPengadaan {
//Pengadaan Produk
@GET("pengadaan")
Call<ResultPengadaan> getAll();
@GET("notification")
Call<ResultProduk> getNotification();
@GET("pengadaan/{id}")
Call<ResultOnePengadaan> getPengadaan(@Path("id") String id);
@POST("pengadaan")
Call<ResultOnePengadaan> createPengadaan(@Body PengadaanModel pengadaanModel);
@PUT("pengadaan/{id}")
Call<ResultOnePengadaan> updatePengadaan(@Path("id") String id,
@Body PengadaanModel pengadaanModel);
@PUT("pengadaan/updateTotal/{id}")
@FormUrlEncoded
Call<ResultOnePengadaan> updateTotal(@Path("id") String nomor_pengadaan,
@Field("total") String total);
@PUT("pengadaan/delete/{id}")
@FormUrlEncoded
Call<ResultOnePengadaan> deletePengadaan(@Path("id") String id,
@Field("pic") String pic);
@PUT("pengadaan/konfirmasi/{id}")
Call<ResultOnePengadaan> confirmationPengadaan(@Path("id") String id);
//Detail Pengadaan Produk
@GET("detail_pengadaan/getByTransaction/{id}")
Call<ResultDetailPengadaan> getAllDetail(@Path("id") String nomor_pengadaan);
@GET("detail_pengadaan/{id}")
Call<ResultOneDetailPengadaan> getDetail(@Path("id") String id_detail);
@POST("detail_pengadaan")
Call<ResultOneDetailPengadaan> createDetail(@Body DetailPengadaanModel detailPengadaanModel);
@PUT("detail_pengadaan/{id}")
Call<ResultOneDetailPengadaan> updateDetail(@Path("id") String id_detail,
@Body DetailPengadaanModel detailPengadaanModel);
@DELETE("detail_pengadaan/{id}")
Call<ResultOneDetailPengadaan> deleteDetail(@Path("id") String id_detail);
//Surat Pemesanan
@GET("pengadaan/surat/print/{id}")
Call<ResponseBody> printSuratPemesanan(@Path("id") String id);
}
| [
"="
] | = |
33920c63c45f566c5f4ae904dd80cfd2fd096f0c | d36ff1fb94bd19ad9897fa31baadfb5621396d5f | /nfvo/openbaton-libs/vnfm-sdk/src/main/java/org/openbaton/common/vnfm_sdk/interfaces/VNFFaultManagement.java | 6e8995b024ecde3dbb80e130386ca217ddf8f256 | [
"Apache-2.0"
] | permissive | nextworks-it/NXW-MANO | 97b03a373e4a1ae3e2b3a77cc19663864b3ebba3 | a94330b30d14e8616557c39b2d609e58961edd2a | refs/heads/master | 2021-01-11T14:45:35.671195 | 2019-07-25T13:06:04 | 2019-07-25T13:06:04 | 80,210,700 | 1 | 0 | null | 2019-07-25T13:06:06 | 2017-01-27T13:46:01 | Java | UTF-8 | Java | false | false | 973 | java | /*
* Copyright (c) 2016 Open Baton (http://www.openbaton.org)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
package org.openbaton.common.vnfm_sdk.interfaces;
/** Created by mpa on 05/05/15. */
public interface VNFFaultManagement {
/** This operation allows collecting VNF application-layer fault information. */
void getFaultInformation();
/** This operation allows providing application-layer fault notifications. */
void notifyFault();
}
| [
"g.bernini@nextworks.it"
] | g.bernini@nextworks.it |
b5f7483fa9651e8fe70070d89cfc74493bec2e34 | d2ec57598c338498027c2ecbcbb8af675667596b | /src/myfaces-core-module-2.1.10/impl/src/main/java/org/apache/myfaces/config/element/FacesConfigExtension.java | 7ee0dabeaf51daa81b25f410e9e9d36dacb2ec17 | [
"Apache-2.0"
] | permissive | JavaQualitasCorpus/myfaces_core-2.1.10 | abf6152e3b26d905eff87f27109e9de1585073b5 | 10c9f2d038dd91c0b4f78ba9ad9ed44b20fb55c3 | refs/heads/master | 2023-08-12T09:29:23.551395 | 2020-06-02T18:06:36 | 2020-06-02T18:06:36 | 167,005,005 | 0 | 0 | Apache-2.0 | 2022-07-01T21:24:07 | 2019-01-22T14:08:49 | Java | UTF-8 | Java | false | false | 1,104 | java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.myfaces.config.element;
import java.io.Serializable;
import java.util.List;
/**
*
* @author Leonardo Uribe
* @since 2.1.0
*/
public abstract class FacesConfigExtension implements Serializable
{
public abstract List<FaceletsProcessing> getFaceletsProcessingList();
}
| [
"taibi@sonar-scheduler.rd.tut.fi"
] | taibi@sonar-scheduler.rd.tut.fi |
249edf1d2ca6d1aaeb1a632f801cdd73a6fa4924 | b4434f2247573d970cc662cdee4b4443eb786224 | /transportation/etl_code/AcceptableRoads/src/AcceptableRoadsMapper2.java | 41cd488230ddb5b2ceb18fff6da4d5c87b2e73bf | [] | no_license | Ulbert/U.S.-Infrastructure-Analysis | 394949acb50005719af69d638cab25fdf8d30d7b | 5befd41ecff780adf9ac972f937812d531104359 | refs/heads/main | 2023-08-15T13:05:50.637177 | 2021-09-21T22:01:55 | 2021-09-21T22:01:55 | 408,985,606 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 705 | java | import org.apache.hadoop.io.LongWritable;
import org.apache.hadoop.io.Text;
import org.apache.hadoop.mapreduce.Mapper;
import java.io.IOException;
import java.util.HashMap;
import java.util.Map;
public class AcceptableRoadsMapper2 extends Mapper<LongWritable, Text, Text, Text> {
@Override
public void map(LongWritable key, Text value, Context context) throws IOException, InterruptedException {
String[] split_line = value.toString().split(",");
if(split_line[0].equals("State")) return;
// maps all entries by their state
context.write(new Text(split_line[0].toLowerCase().replaceAll(" ", "")),
new Text(String.valueOf(split_line[1])));
}
}
| [
"ma4759@nyu.edu"
] | ma4759@nyu.edu |
8f1f059e7826481ca0d7a695483c157615cb3a9e | 69029d670e90e9622208dd4707e0057f300198c3 | /src/main/java/guru/springframework/domain/UnitOfMeasure.java | cf81599906525a7d5ee9cf40f7375e9d29f594cb | [] | no_license | danielquina/spring5-recipe-app | 9ee831aa2077074239025c50b4455d0d684d64f2 | da036d5217acc1c8146699e681b914682b000a40 | refs/heads/master | 2022-11-23T03:30:26.205320 | 2020-07-30T21:02:35 | 2020-07-30T21:02:35 | 258,855,645 | 0 | 0 | null | 2020-07-28T19:41:40 | 2020-04-25T19:20:54 | Java | UTF-8 | Java | false | false | 369 | java | package guru.springframework.domain;
import lombok.Data;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
@Data
@Entity
public class UnitOfMeasure {
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Long id;
private String description;
}
| [
"danielquina@gmail.com"
] | danielquina@gmail.com |
6be0b346131974c7c6b88a124bcd769183687731 | 2a5a567c911a102be5ab6537c66b729c1033df70 | /src/com/aggfi/digest/server/botty/digestbotty/model/ComplReplyProb.java | 61663897850dd7ad48ceab76ca0f7cdf13cbfbe8 | [] | no_license | vega113/DigestBottyNGadget | c55cbcabbc218b854e9c3862c7261f8cfe41739b | 5b80803375fe00176ec8af418f48f01a42f540b6 | refs/heads/master | 2021-01-01T18:17:43.800574 | 2010-10-16T09:54:56 | 2010-10-16T09:54:56 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 2,738 | java | package com.aggfi.digest.server.botty.digestbotty.model;
import java.util.Collection;
import java.util.Date;
import java.util.Iterator;
import java.util.Map;
import javax.jdo.annotations.IdGeneratorStrategy;
import javax.jdo.annotations.IdentityType;
import javax.jdo.annotations.PersistenceCapable;
import javax.jdo.annotations.Persistent;
import javax.jdo.annotations.PrimaryKey;
import com.aggfi.digest.server.botty.digestbotty.utils.InfluenceUtils;
import com.google.gson.annotations.Expose;
@PersistenceCapable(identityType = IdentityType.APPLICATION, detachable = "true")
public class ComplReplyProb {
@PrimaryKey
@Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY)
@Expose
private Long id;
@Expose
@Persistent
String projectId;
@Expose
@Persistent
Date forDate;
@Expose
@Persistent
String forDateStr;
@Expose
@Persistent(serialized = "true", defaultFetchGroup = "true")
Map<String,Double> complProbMap;
public ComplReplyProb(String projectId, Date forDate,
Map<String, Double> complProbMap) {
super();
this.projectId = projectId;
this.forDate = forDate;
this.complProbMap = complProbMap;
this.forDateStr = InfluenceUtils.getSdf().format(forDate);
}
@Override
public String toString() {
final int maxLen = 10;
StringBuilder builder = new StringBuilder();
builder.append("ComplReplyProb [id=");
builder.append(id);
builder.append(", projectId=");
builder.append(projectId);
builder.append(", forDate=");
builder.append(forDate);
builder.append(", forDateStr=");
builder.append(forDateStr);
builder.append(", complProbMap=");
builder.append(complProbMap != null ? toString(complProbMap.entrySet(),
maxLen) : null);
builder.append("]");
return builder.toString();
}
private String toString(Collection<?> collection, int maxLen) {
StringBuilder builder = new StringBuilder();
builder.append("[");
int i = 0;
for (Iterator<?> iterator = collection.iterator(); iterator.hasNext()
&& i < maxLen; i++) {
if (i > 0)
builder.append(", ");
builder.append(iterator.next());
}
builder.append("]");
return builder.toString();
}
public String getForDateStr() {
return forDateStr;
}
public void setForDateStr(String forDateStr) {
this.forDateStr = forDateStr;
}
public String getProjectId() {
return projectId;
}
public void setProjectId(String projectId) {
this.projectId = projectId;
}
public Date getForDate() {
return forDate;
}
public void setForDate(Date forDate) {
this.forDate = forDate;
}
public Map<String, Double> getComplProbMap() {
return complProbMap;
}
public void setComplProbMap(Map<String, Double> complProbMap) {
this.complProbMap = complProbMap;
}
public Long getId() {
return id;
}
}
| [
"vega113@gmail.com"
] | vega113@gmail.com |
ca607b3bc85f289e9c0c94e7692f58bc8e0f0ba6 | 4a6616ef1043adcc72a4981c60ca34c9f792786e | /app/src/main/java/com/catchmybus/MainActivity.java | e2151adcdd3f5e327f45a859de43376d35d95641 | [] | no_license | limekin/cmb | 51fd7639d654e8656a36ea67ecefeb1ce2786191 | 16b55417a770858a91b6c3d8ba9aa36962a0ccf7 | refs/heads/master | 2021-01-18T22:38:19.229591 | 2017-04-28T07:38:12 | 2017-04-28T07:38:12 | 87,064,079 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 6,579 | java | package com.catchmybus;
import android.content.Context;
import android.content.Intent;
import android.content.SharedPreferences;
import android.os.Bundle;
import android.support.design.widget.FloatingActionButton;
import android.support.design.widget.Snackbar;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.widget.Toolbar;
import android.util.Log;
import android.view.View;
import android.view.Menu;
import android.view.MenuItem;
import android.widget.EditText;
import android.widget.Toast;
import com.android.volley.Request;
import com.android.volley.RequestQueue;
import com.android.volley.Response;
import com.android.volley.VolleyError;
import com.android.volley.toolbox.JsonObjectRequest;
import com.android.volley.toolbox.Volley;
import com.catchmybus.settings.AppSettings;
import org.json.JSONException;
import org.json.JSONObject;
public class MainActivity extends AppCompatActivity {
private EditText usernameE, passwordE;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
// Check if the user is already logged in.
checkAuth();
setRefs();
}
@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
public boolean onOptionsItemSelected(MenuItem item) {
// Handle action bar item clicks here. The action bar will
// automatically handle clicks on the Home/Up button, so long
// as you specify a parent activity in AndroidManifest.xml.
int id = item.getItemId();
//noinspection SimplifiableIfStatement
return super.onOptionsItemSelected(item);
}
public void showLogin(View view) {
Intent intent = new Intent(this, LoginActivity.class);
this.startActivity(intent);
}
public void showRegister(View view) {
Intent intent = new Intent(this, RegisterActivity.class);
this.startActivity(intent);
}
// CHecks if the user is already logged in.
public void checkAuth() {
SharedPreferences pref = this.getSharedPreferences(AppSettings.prefFile,
Context.MODE_PRIVATE);
if(! pref.getString("token", "none").equals("none")) {
String userType = pref.getString("user_type", "none");
Intent intent = null;
switch(userType) {
case "user":
intent = new Intent(this, UserActivity.class);
break;
case "worker":
intent = new Intent(this, WorkerActivity.class);
break;
}
this.startActivity(intent);
}
}
public void setRefs() {
usernameE = (EditText) findViewById(R.id.username);
passwordE = (EditText) findViewById(R.id.password);
}
public void handleLogin(View view) {
if(! validate()) return;
String username = usernameE.getText().toString(),
password = passwordE.getText().toString();
RequestQueue queue = Volley.newRequestQueue(this);
String url = AppSettings.apiUrl + "/core/login.php";
JSONObject data = new JSONObject();
try {
data.put("password", password);
data.put("username", username);
} catch (JSONException e) {
e.printStackTrace();
}
JsonObjectRequest request = new JsonObjectRequest(
Request.Method.POST,
url,
data,
new Response.Listener<JSONObject>() {
@Override
public void onResponse(JSONObject response) {
try {
if (response.has("error")) {
Toast t = Toast.makeText(MainActivity.this, response.getString("error"), Toast.LENGTH_LONG);
t.show();
return;
}
MainActivity.this.loginCallback(response);
} catch (JSONException e) {
e.printStackTrace();
}
}
},
new Response.ErrorListener() {
@Override
public void onErrorResponse(VolleyError error) {
if (error.getMessage() != null)
Log.i("RESPONSE", error.getMessage());
}
}
);
// Send the request.
queue.add(request);
Log.i("REQUEST", "Request send");
}
// Save the user id and token.
public void loginCallback(JSONObject data) throws JSONException {
String token = data.getJSONObject("data").getString("token");
String userId = data.getJSONObject("data").getString("user_id");
String userType = data.getJSONObject("data").getString("user_type");
SharedPreferences pref = this.getSharedPreferences(AppSettings.prefFile, Context.MODE_PRIVATE);
SharedPreferences.Editor editor = pref.edit();
editor.putString("token", token);
editor.putString("user_id", userId);
editor.putString("user_type", userType);
editor.commit();
Intent intent = null;
switch(userType) {
case "user":
intent = new Intent(this, UserActivity.class);
break;
case "worker":
intent = new Intent(this, WorkerActivity.class);
break;
}
this.startActivity(intent);
}
public boolean validate() {
String username = usernameE.getText().toString(),
password = passwordE.getText().toString();
if(username.trim().isEmpty()) {
Snackbar snackbar = Snackbar.make(findViewById(R.id.container),
"Your username is empty.",
Snackbar.LENGTH_LONG);
snackbar.show();
return false;
}
if(password.trim().isEmpty()) {
Snackbar snackbar = Snackbar.make(findViewById(R.id.container),
"Your password is empty.",
Snackbar.LENGTH_LONG);
snackbar.show();
return false;
}
return true;
}
}
| [
"kevintjayan@gmail.com"
] | kevintjayan@gmail.com |
378cecd21db35f879bca5b73702528dfa88e7947 | 31a3b3d03997a770401e038d20bf9806c7484269 | /Sorter/src/olefoens/sorter/Main.java | a2c894c738064f72d9aa6b214cc239a609f83cff | [] | no_license | foens/LegoSorter | c90ddb13ffa0d8dedb5ae263493a2361e7cdc781 | 4414db6d31a7b6108cc722aea2b1e2fda4f0b965 | refs/heads/master | 2020-05-30T10:12:05.247384 | 2013-06-25T09:02:18 | 2013-06-25T09:02:18 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,653 | java | package olefoens.sorter;
import lejos.nxt.*;
import lejos.nxt.addon.RCXLightSensor;
import lejos.util.Delay;
import olefoens.axlesorter.AxleSorter;
import olefoens.beamcounter.*;
import olefoens.communication.ClientRole;
import olefoens.communication.Communicator;
import java.io.IOException;
public class Main
{
/**
* If you want to run the Sorter without bluetooth communication, set this to true
*/
public static final boolean NO_MASTER_MODE = false;
public static void main(String[] args) throws InterruptedException
{
Button.ESCAPE.addButtonListener(new ButtonListener()
{
public void buttonPressed(Button b){ System.exit(0);}
public void buttonReleased(Button b){}
});
LightSensor floodLight = new LightSensor(SensorPort.S1);
LightSensor sensor = new LightSensor(SensorPort.S2);
BeltDrive beltDrive = new BeltDrive();
beltDrive.addBeltMotor(new BeltMotorDescription(Motor.B, DriveDirection.FORWARD));
beltDrive.addBeltMotor(new BeltMotorDescription(Motor.C, DriveDirection.REVERSE));
try
{
Communicator master = NO_MASTER_MODE ? null : Communicator.acceptConnectionFromMaster(ClientRole.Sorter);
BeamHoleCounter bhc = new BeamHoleCounter(floodLight, sensor, beltDrive);
AxleSorter axleSorter = new AxleSorter(Motor.A, new RCXLightSensor(SensorPort.S3), new RCXLightSensor(SensorPort.S4));
BeamAxleSorter beamAxleSorter = new BeamAxleSorter(bhc, master, axleSorter);
if(NO_MASTER_MODE)
beamAxleSorter.stopAndStartSorters();
else
beamAxleSorter.startSystem();
} catch(IOException e)
{
LCD.clear();
LCD.drawString("IOException!", 0, 0);
Delay.msDelay(10000);
}
}
}
| [
"kfoens@gmail.com"
] | kfoens@gmail.com |
000a818d4847a2087d53a1996ca9249a4cb29216 | b9889bc2c57927a8dd83062b6b53e3d424e8add5 | /de.bht.fpa.mail.s778455.imapnavigation/src/de/bht/fpa/mail/s778455/imapnavigation/composite/IMAPItem.java | ec5ba61c6cb750be1f8382033afbb5f5b9ef21f7 | [] | no_license | sasfeld/FPA_SS2012 | 47c126aa88896d398a2a7845d5816bcc5c513567 | 9d2797555f8a31f5630fa06109a204da87f92934 | refs/heads/master | 2020-04-06T06:48:14.478093 | 2012-06-18T16:59:08 | 2012-06-18T16:59:08 | null | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 488 | java | package de.bht.fpa.mail.s778455.imapnavigation.composite;
/**
* The abstract component class. - transparency
*
* @author Sascha Feldmann
*
*/
public abstract class IMAPItem {
/**
* Check if the element has children.
*
* @return true if the element has children.
*/
public abstract boolean hasChildren();
/**
* Return an array of children.
*
* @return an array of children.
*/
public abstract IMAPItem[] getChildren();
}
| [
"sascha.feldmann@gmx.de"
] | sascha.feldmann@gmx.de |
479a4860abed527176e92c4363af73f5c8f59bf7 | a45df4f5506f30e26b7c721a138592fe0db076b9 | /app/src/main/java/com/ibring_driver/provider/Activity/AddCarDetails.java | af6d2cfa4501b37c99d69e007aea16011519bfb6 | [] | no_license | ravinakapila55/IBringDriverApp | 650966541607de3bf4528c7b4afb43d7fc7b706d | 94d94274f99d4d0d2e167cdefcb2a82006c66604 | refs/heads/master | 2023-02-26T18:55:38.308572 | 2021-01-18T12:08:48 | 2021-01-18T12:08:48 | 336,325,193 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 61,067 | java | package com.ibring_driver.provider.Activity;
import android.app.Activity;
import android.app.AlertDialog;
import android.content.Context;
import android.content.Intent;
import android.graphics.Color;
import android.graphics.drawable.ColorDrawable;
import android.os.Build;
import android.os.Bundle;
import android.os.Handler;
import android.util.Log;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.view.WindowManager;
import android.widget.AdapterView;
import android.widget.ArrayAdapter;
import android.widget.EditText;
import android.widget.ImageView;
import android.widget.RelativeLayout;
import android.widget.Spinner;
import android.widget.TextView;
import android.widget.Toast;
import androidx.annotation.Nullable;
import androidx.appcompat.app.AppCompatActivity;
import androidx.constraintlayout.widget.ConstraintLayout;
import com.android.volley.AuthFailureError;
import com.android.volley.NetworkResponse;
import com.android.volley.Request;
import com.android.volley.Response;
import com.android.volley.VolleyError;
import com.android.volley.toolbox.JsonObjectRequest;
import com.ibring_driver.provider.Constant.URLHelper;
import com.ibring_driver.provider.Helper.AppHelper;
import com.ibring_driver.provider.Helper.ConnectionHelper;
import com.ibring_driver.provider.Helper.CustomDialog;
import com.ibring_driver.provider.Helper.SharedHelper;
import com.ibring_driver.provider.Models.BrandList;
import com.ibring_driver.provider.Models.CabType;
import com.ibring_driver.provider.Models.CapacityList;
import com.ibring_driver.provider.Models.MatrixServices;
import com.ibring_driver.provider.Models.ModelList;
import com.ibring_driver.provider.Models.OtherServices;
import com.ibring_driver.provider.R;
import com.ibring_driver.provider.Utils.KeyHelper;
import com.ibring_driver.provider.Utils.Utilities;
import com.ibring_driver.provider.XuberServicesApplication;
import com.ibring_driver.provider.retrofit.RetrofitResponse;
import com.ibring_driver.provider.retrofit.RetrofitService;
import org.json.JSONArray;
import org.json.JSONException;
import org.json.JSONObject;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.Map;
import static com.ibring_driver.provider.XuberServicesApplication.trimMessage;
public class AddCarDetails extends AppCompatActivity implements RetrofitResponse
{
public Context context = AddCarDetails.this;
public Activity activity = AddCarDetails.this;
String TAG = "AddCarDetails";
String device_token, device_UDID;
ImageView backArrow;
CustomDialog customDialog;
ConnectionHelper helper;
String key = "";
String soacialId = "";
Boolean isInternet;
Utilities utils = new Utilities();
XuberServicesApplication xuberServicesApplication;
public Spinner SpCabType, SpBrand, SpModel, SpCapacity, SpColor;
RelativeLayout lnrRegister;
EditText etNumber;
ImageView ivBack;
ConstraintLayout cc_food;
ConstraintLayout ccServices;
ConstraintLayout cc_carDetails;
String serviceIdOldScreen="";
String[] color = {"Select Color", "Red", "Blue", "Black", "Pink", "Brown", "White", "Other"};
String[] capacityListSpinner = {"Select Capacity", "4", "5", "6", "7"};
String[] modelllll = {"Select Model"};
String[] cabType = {"Select Car Type"};
String[] capacity = {"Select Capacity"};
ArrayList<CabType> cablist = new ArrayList<>();
ArrayList<String> cablistName = new ArrayList<>();
ArrayList<BrandList> brandsList = new ArrayList<>();
ArrayList<String> brandListName = new ArrayList<>();
ArrayList<ModelList> modelsList = new ArrayList<>();
ArrayList<String> modelListName = new ArrayList<>();
ArrayList<CapacityList> capacityList = new ArrayList<>();
ArrayList<String> capacityListName = new ArrayList<>();
RelativeLayout rlService, rlSubService;
Spinner sp_service, sp_sub_service;
TextView tvLogin11;
EditText etVehicleName,etVehicleNumber;
@Override
protected void onCreate(@Nullable Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
/*
getWindow().addFlags(WindowManager.LayoutParams.FLAG_DRAWS_SYSTEM_BAR_BACKGROUNDS);
getWindow().clearFlags(WindowManager.LayoutParams.FLAG_TRANSLUCENT_STATUS);
*/
/*
getWindow().setStatusBarColor(ContextCompat.getColor(AddCarDetails.this, R.color.colorPrimary));
getWindow().setNavigationBarColor(ContextCompat.getColor(AddCarDetails.this, R.color.colorPrimary));
*/
}
setContentView(R.layout.add_car_details);
rlService = (RelativeLayout) findViewById(R.id.rlService);
rlSubService = (RelativeLayout) findViewById(R.id.rlSubService);
sp_service = (Spinner) findViewById(R.id.sp_service);
sp_sub_service = (Spinner) findViewById(R.id.sp_sub_service);
etVehicleName = (EditText) findViewById(R.id.etVehicleName);
etVehicleNumber = (EditText) findViewById(R.id.etVehicleNumber);
findViewById();
if (getIntent().hasExtra("key"))
{
key = getIntent().getExtras().getString("key");
serviceIdOldScreen = getIntent().getExtras().getString("service");
if (key.equalsIgnoreCase("direct"))
{
ccServices.setVisibility(View.GONE);
if (serviceIdOldScreen.equalsIgnoreCase("18"))
{
cc_food.setVisibility(View.VISIBLE);
cc_carDetails.setVisibility(View.GONE);
}
else
{
cc_food.setVisibility(View.GONE);
cc_carDetails.setVisibility(View.VISIBLE);
}
}
else
{
//todo social logins
soacialId = getIntent().getExtras().getString("social_id");
ccServices.setVisibility(View.VISIBLE);
callServiceList();
}
}
xuberServicesApplication = (XuberServicesApplication) getApplication();
Log.e("Fname ", xuberServicesApplication.signupData.getFname());
Log.e("Lname ", xuberServicesApplication.signupData.getLname());
Log.e("Email ", xuberServicesApplication.signupData.getEmail());
Log.e("Password ", xuberServicesApplication.signupData.getPassword());
Log.e("Phone ", xuberServicesApplication.signupData.getPhone());
GetToken();
setCarCapacity();
setColor();
callcabType();
callbRANDlIST();
}
public void callServiceList()
{
new RetrofitService(this, this, URLHelper.GET_APP_SERVICES,
105, 1, "1").callService(true);
}
public void GetToken()
{
try
{
if (!SharedHelper.getKey(context, "device_token").equals("") &&
SharedHelper.getKey(context, "device_token") != null) {
device_token = SharedHelper.getKey(context, "device_token");
Log.e("@#@#@", "device token" + device_token);
utils.print(TAG, "GCM Registration Token: " + device_token);
} else {
device_token = "COULD NOT GET FCM TOKEN";
utils.print(TAG, "Failed to complete token refresh: " + device_token);
}
}
catch (Exception e)
{
device_token = "COULD NOT GET FCM TOKEN";
utils.print(TAG, "Failed to complete token refresh");
}
try {
device_UDID = android.provider.Settings.Secure.getString(getContentResolver(), android.provider.Settings.Secure.ANDROID_ID);
Log.e("@#@#@", "device uid" + device_UDID);
utils.print(TAG, "Device UDID:" + device_UDID);
}
catch (Exception e)
{
device_UDID = "COULD NOT GET UDID";
e.printStackTrace();
utils.print(TAG, "Failed to complete device UDID");
}
}
public void GoToMainActivity()
{
Intent mainIntent = new Intent(AddCarDetails.this, Home.class);
mainIntent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TASK | Intent.FLAG_ACTIVITY_NEW_TASK);
startActivity(mainIntent);
AddCarDetails.this.finish();
}
public void GoToMainActivity1()
{
Intent mainIntent = new Intent(AddCarDetails.this, ActivityPassword.class);
mainIntent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TASK | Intent.FLAG_ACTIVITY_NEW_TASK);
startActivity(mainIntent);
AddCarDetails.this.finish();
}
public void setColor() {
ArrayAdapter<String> adapter = new ArrayAdapter<String>(this, R.layout.custom_spinner, color);
SpColor.setAdapter(adapter);
SpColor.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() {
@Override
public void onItemSelected(AdapterView<?> parent, View view, int position, long id) {
if (position == 0) {
colorSelect = "";
Log.e("colorSelect ", colorSelect);
} else {
colorSelect = SpColor.getSelectedItem() + "";
Log.e("colorSelect ", colorSelect);
}
}
@Override
public void onNothingSelected(AdapterView<?> parent) {
}
});
}
public void setCarCapacity()
{
ArrayAdapter<String> adapter = new ArrayAdapter<String>(this, R.layout.custom_spinner, capacityListSpinner);
SpCapacity.setAdapter(adapter);
SpCapacity.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() {
@Override
public void onItemSelected(AdapterView<?> parent, View view, int position, long id) {
if (position == 0) {
capacityId = "";
Log.e("colorSelect ", capacityId);
} else {
capacityId = SpCapacity.getSelectedItem() + "";
Log.e("colorSelect ", capacityId);
}
}
@Override
public void onNothingSelected(AdapterView<?> parent) {
}
});
}
public void callcabType()
{
new RetrofitService(this, this, URLHelper.GET_CAB_TYPE,
500, 1, "1").callService(true);
}
public void callbRANDlIST()
{
new RetrofitService(this, this, URLHelper.GET_BRAND_LIST,
1000, 1, "1").callService(true);
}
public void callCapacityList(String modelIddd) {
try {
JSONObject param = new JSONObject();
param.put("model_id", modelIddd);
Log.e("callCapacityListModel ", param.toString());
new RetrofitService(this, this,
URLHelper.GET_CAPACITY_LIST, param, 2000, 2, "1").
callService(true);
} catch (Exception ex) {
ex.printStackTrace();
}
}
public void callModelList(String brandId)
{
try
{
JSONObject param = new JSONObject();
param.put("brand_id", brandId);
Log.e("callModelList ", param.toString());
new RetrofitService(this, this,
URLHelper.GET_MODEL_LIST, param, 1500, 2, "1").
callService(true);
} catch (Exception ex)
{
ex.printStackTrace();
}
}
public void callRegisterrrr()
{
try
{
JSONObject object=new JSONObject();
object.put("device_type", "android");
object.put("device_id", device_UDID);
String serviceIddd="";
if (key.equalsIgnoreCase("direct"))
{
serviceIddd= xuberServicesApplication.signupData.getService_id();
object.put("service_id", xuberServicesApplication.signupData.getService_id());
object.put("service_type", xuberServicesApplication.signupData.getService_type());
}
else
{
serviceIddd=serviceID;
object.put("service_id", serviceID);
object.put("service_type", serviceType);
object.put("social_unique_id", soacialId);
object.put("login_by", key);
}
object.put("device_token", "" + device_token);
object.put("login_by", "manual");
//for food module
if (serviceIddd.equalsIgnoreCase("18"))
{
object.put("vehicle_number", etVehicleNumber.getText().toString().trim());
object.put("vehicle_name", etVehicleName.getText().toString().trim());
}
else {
object.put("car_number", etNumber.getText().toString().trim());
object.put("car_brand", brandId);
object.put("car_model", modelId);
object.put("car_capacity", capacityId);
object.put("car_color", colorSelect);
object.put("cab_type_id", cabTypeID);
}
object.put("first_name", xuberServicesApplication.signupData.getFname());
object.put("last_name", xuberServicesApplication.signupData.getLname());
object.put("email", xuberServicesApplication.signupData.getEmail());
object.put("password", xuberServicesApplication.signupData.getPassword());
object.put("password_confirmation", xuberServicesApplication.signupData.getPassword());
object.put("mobile", xuberServicesApplication.signupData.getPhone());
Log.e("registerrrrParams ", "" + object);
new RetrofitService(this, this, URLHelper.REGISTER ,
object,
100, 2,"1").callService(true);
}
catch (Exception ex)
{
ex.printStackTrace();
}
}
private void registerAPI()
{
customDialog = new CustomDialog(AddCarDetails.this);
customDialog.setCancelable(false);
customDialog.show();
JSONObject object = new JSONObject();
try {
object.put("device_type", "android");
object.put("device_id", device_UDID);
if (key.equalsIgnoreCase("direct"))
{
object.put("service_id", xuberServicesApplication.signupData.getService_type());
}
else
{
object.put("service_id", serviceID);
object.put("social_unique_id", soacialId);
object.put("login_by", key);
}
object.put("device_token", "" + device_token);
object.put("login_by", "manual");
object.put("first_name", xuberServicesApplication.signupData.getFname());
object.put("last_name", xuberServicesApplication.signupData.getLname());
object.put("email", xuberServicesApplication.signupData.getEmail());
object.put("password", xuberServicesApplication.signupData.getPassword());
object.put("password_confirmation", xuberServicesApplication.signupData.getPassword());
object.put("mobile", xuberServicesApplication.signupData.getPhone());
object.put("car_number", etNumber.getText().toString().trim());
object.put("car_brand", brandId);
object.put("car_model", modelId);
object.put("car_capacity", capacityId);
object.put("car_color", colorSelect);
object.put("cab_type_id", cabTypeID);
Log.e("InputToRegisterAPI", "" + object.toString());
}
catch (JSONException e)
{
e.printStackTrace();
}
JsonObjectRequest jsonObjectRequest = new JsonObjectRequest(Request.Method.POST, URLHelper.REGISTER, object,
new Response.Listener<JSONObject>()
{
@Override
public void onResponse(JSONObject response)
{
customDialog.dismiss();
utils.print("SignInResponse", response.toString());
SharedHelper.putKey(AddCarDetails.this, "email", xuberServicesApplication.signupData.getEmail());
SharedHelper.putKey(AddCarDetails.this, "password", xuberServicesApplication.signupData.getPassword());
signIn();
}
},
new Response.ErrorListener()
{
@Override
public void onErrorResponse(VolleyError error) {
utils.print("InsideError ", "" + error);
customDialog.dismiss();
String json = null;
String Message;
NetworkResponse response = error.networkResponse;
if (response != null && response.data != null) {
utils.print("MyTest", "" + error);
utils.print("MyTestError", "" + error.networkResponse);
utils.print("MyTestError1", "" + response.statusCode);
try {
JSONObject errorObj = new JSONObject(new String(response.data));
if (response.statusCode == 400 || response.statusCode == 405 || response.statusCode == 500) {
try
{
// displayMessage(errorObj.optString("message"));
Toast.makeText(AddCarDetails.this, errorObj.optString("message"),
Toast.LENGTH_SHORT).show();
} catch (Exception e)
{
// displayMessage(getString(R.string.something_went_wrong));
Toast.makeText(AddCarDetails.this, getString(R.string.something_went_wrong),
Toast.LENGTH_SHORT).show();
}
} else if (response.statusCode == 401)
{
try
{
if (errorObj.optString("message").equalsIgnoreCase("invalid_token"))
{
//Call Refresh token
}
else
{
// displayMessage(errorObj.optString("message"));
Toast.makeText(AddCarDetails.this, errorObj.optString("message"), Toast.LENGTH_SHORT).show();
}
}
catch (Exception e)
{
// displayMessage(getString(R.string.something_went_wrong));
Toast.makeText(AddCarDetails.this, getString(R.string.something_went_wrong), Toast.LENGTH_SHORT).show();
}
}
else if (response.statusCode == 422)
{
json = trimMessage(new String(response.data));
if (json != "" && json != null)
{
// displayMessage(json);
Toast.makeText(AddCarDetails.this, json, Toast.LENGTH_SHORT).show();
}
else
{
// displayMessage(getString(R.string.please_try_again));
Toast.makeText(AddCarDetails.this, getString(R.string.please_try_again),
Toast.LENGTH_SHORT).show();
}
}
else
{
// displayMessage(getString(R.string.please_try_again));
Toast.makeText(AddCarDetails.this, getString(R.string.please_try_again),
Toast.LENGTH_SHORT).show();
}
}
catch (Exception e)
{
// displayMessage(getString(R.string.something_went_wrong));
Toast.makeText(AddCarDetails.this, getString(R.string.something_went_wrong),
Toast.LENGTH_SHORT).show();
}
}
}
}) {
@Override
public Map<String, String> getHeaders() throws AuthFailureError {
HashMap<String, String> headers = new HashMap<String, String>();
headers.put("X-Requested-With", "XMLHttpRequest");
return headers;
}
};
XuberServicesApplication.getInstance().addToRequestQueue(jsonObjectRequest);
}
public void showVerificationPopUp()
{
AlertDialog.Builder dialogBuilder = new AlertDialog.Builder(this);
LayoutInflater inflater = getLayoutInflater();
View dialogView = inflater.inflate(R.layout.payment_done_success, null);
TextView tvLabel=(TextView)dialogView.findViewById(R.id.tvLabel);
TextView tvCancel=(TextView)dialogView.findViewById(R.id.tvCancel);
TextView tvOk=(TextView)dialogView.findViewById(R.id.tvOk);
ImageView ivLabel=(ImageView) dialogView.findViewById(R.id.ivLabel);
dialogBuilder.setView(dialogView);
dialogBuilder.setCancelable(false);
final AlertDialog alertDialog = dialogBuilder.create();
alertDialog.getWindow().setBackgroundDrawable(new ColorDrawable(android.graphics.Color.TRANSPARENT));
int width = WindowManager.LayoutParams.WRAP_CONTENT;
int height = WindowManager.LayoutParams.WRAP_CONTENT;
tvLabel.setText("A verification e-mail has been sent. \n please check to activate your account");
tvCancel.setVisibility(View.GONE);
tvOk.setVisibility(View.GONE);
ivLabel.setImageDrawable(getResources().getDrawable(R.drawable.cancel_req_icon));
new Handler().postDelayed(new Runnable() {
@Override
public void run() {
GoToMainActivity1();
}
},3000);
alertDialog.show();
}
public void signIn() {
customDialog = new CustomDialog(AddCarDetails.this);
customDialog.setCancelable(false);
customDialog.show();
JSONObject object = new JSONObject();
try {
object.put("grant_type", "password");
object.put("client_id", URLHelper.CLIENT_ID);
object.put("client_secret", URLHelper.CLIENT_SECRET_KEY);
object.put("device_type", "android");
object.put("device_id", device_UDID);
object.put("device_token", device_token);
object.put("email", SharedHelper.getKey(AddCarDetails.this, "email"));
object.put("password", SharedHelper.getKey(AddCarDetails.this, "password"));
object.put("scope", "");
utils.print("InputToLoginAPI", "" + object);
} catch (JSONException e) {
e.printStackTrace();
}
JsonObjectRequest jsonObjectRequest = new JsonObjectRequest(Request.Method.POST, URLHelper.LOGIN, object,
new Response.Listener<JSONObject>() {
@Override
public void onResponse(JSONObject response) {
customDialog.dismiss();
utils.print("SignUpResponse", response.toString());
SharedHelper.putKey(context, "settings", "no");
SharedHelper.putKey(context, "access_token", response.optString("access_token"));
SharedHelper.putKey(context, "refresh_token", response.optString("refresh_token"));
SharedHelper.putKey(context, "token_type", response.optString("token_type"));
getProfile();
}
}, new Response.ErrorListener() {
@Override
public void onErrorResponse(VolleyError error) {
customDialog.dismiss();
String json = null;
NetworkResponse response = error.networkResponse;
if (response != null && response.data != null) {
try {
JSONObject errorObj = new JSONObject(new String(response.data));
if (response.statusCode == 400 || response.statusCode == 405 || response.statusCode == 500) {
try {
// displayMessage(errorObj.optString("message"));
Toast.makeText(AddCarDetails.this, errorObj.optString("message"),
Toast.LENGTH_SHORT).show();
} catch (Exception e) {
// displayMessage(getString(R.string.something_went_wrong));
Toast.makeText(AddCarDetails.this, getString(R.string.something_went_wrong),
Toast.LENGTH_SHORT).show();
}
} else if (response.statusCode == 401) {
try {
if (errorObj.optString("message").equalsIgnoreCase("invalid_token")) {
//Call Refresh token
} else {
// displayMessage(errorObj.optString("message"));
Toast.makeText(AddCarDetails.this, errorObj.optString("message"),
Toast.LENGTH_SHORT).show();
}
} catch (Exception e) {
// displayMessage(getString(R.string.something_went_wrong));
Toast.makeText(AddCarDetails.this, getString(R.string.something_went_wrong),
Toast.LENGTH_SHORT).show();
}
} else if (response.statusCode == 422) {
json = trimMessage(new String(response.data));
if (json != "" && json != null) {
// displayMessage(json);
Toast.makeText(AddCarDetails.this, json, Toast.LENGTH_SHORT).show();
} else {
// displayMessage(getString(R.string.please_try_again));
Toast.makeText(AddCarDetails.this, getString(R.string.please_try_again),
Toast.LENGTH_SHORT).show();
}
} else {
// displayMessage(getString(R.string.please_try_again));
Toast.makeText(AddCarDetails.this, getString(R.string.please_try_again),
Toast.LENGTH_SHORT).show();
}
} catch (Exception e) {
// displayMessage(getString(R.string.something_went_wrong));
Toast.makeText(AddCarDetails.this, getString(R.string.something_went_wrong),
Toast.LENGTH_SHORT).show();
}
}
}
}) {
@Override
public Map<String, String> getHeaders() throws AuthFailureError {
HashMap<String, String> headers = new HashMap<String, String>();
headers.put("X-Requested-With", "XMLHttpRequest");
return headers;
}
};
XuberServicesApplication.getInstance().addToRequestQueue(jsonObjectRequest);
}
public void getProfile()
{
customDialog = new CustomDialog(AddCarDetails.this);
customDialog.setCancelable(false);
customDialog.show();
JSONObject object = new JSONObject();
JsonObjectRequest jsonObjectRequest = new JsonObjectRequest(Request.Method.GET,
URLHelper.PROVIDER_PROFILE, object, new Response.Listener<JSONObject>() {
@Override
public void onResponse(JSONObject response) {
customDialog.dismiss();
utils.print("GetProfile", response.toString());
SharedHelper.putKey(AddCarDetails.this, "id", response.optString("id"));
SharedHelper.putKey(AddCarDetails.this, "first_name", response.optString("first_name"));
SharedHelper.putKey(AddCarDetails.this, "last_name", response.optString("last_name"));
SharedHelper.putKey(AddCarDetails.this, "email", response.optString("email"));
SharedHelper.putKey(context, "description", response.optString("description"));
SharedHelper.putKey(AddCarDetails.this, "picture", AppHelper.getImageUrl(response.optString("picture")));
SharedHelper.putKey(AddCarDetails.this, "gender", response.optString("gender"));
SharedHelper.putKey(AddCarDetails.this, "mobile", response.optString("mobile"));
SharedHelper.putKey(AddCarDetails.this, "wallet_balance", response.optString("wallet_balance"));
SharedHelper.putKey(AddCarDetails.this, "payment_mode", response.optString("payment_mode"));
if (!response.optString("currency").equalsIgnoreCase("") || !response.optString("currency").equalsIgnoreCase("null")) {
SharedHelper.putKey(context, "currency", response.optString("currency"));
} else {
SharedHelper.putKey(context, "currency", "$");
}
SharedHelper.putKey(AddCarDetails.this, "loggedIn", getString(R.string.True));
GoToMainActivity();
//GoToSettingsStart();
}
}, new Response.ErrorListener() {
@Override
public void onErrorResponse(VolleyError error) {
customDialog.dismiss();
String json = null;
String Message;
NetworkResponse response = error.networkResponse;
if (response != null && response.data != null) {
try {
JSONObject errorObj = new JSONObject(new String(response.data));
if (response.statusCode == 400 || response.statusCode == 405 || response.statusCode == 500) {
try {
// displayMessage(errorObj.optString("message"));
Toast.makeText(AddCarDetails.this, errorObj.optString("message"), Toast.LENGTH_SHORT).show();
} catch (Exception e) {
// displayMessage(getString(R.string.something_went_wrong));
Toast.makeText(AddCarDetails.this, getString(R.string.something_went_wrong), Toast.LENGTH_SHORT).show();
}
} else if (response.statusCode == 401) {
try {
if (errorObj.optString("message").equalsIgnoreCase("invalid_token")) {
//Call Refresh token
} else {
// displayMessage(errorObj.optString("message"));
Toast.makeText(AddCarDetails.this, errorObj.optString("message"), Toast.LENGTH_SHORT).show();
}
} catch (Exception e) {
// displayMessage(getString(R.string.something_went_wrong));
Toast.makeText(AddCarDetails.this, getString(R.string.something_went_wrong), Toast.LENGTH_SHORT).show();
}
} else if (response.statusCode == 422) {
json = trimMessage(new String(response.data));
if (json != "" && json != null) {
// displayMessage(json);
Toast.makeText(AddCarDetails.this, json, Toast.LENGTH_SHORT).show();
} else {
// displayMessage(getString(R.string.please_try_again));
Toast.makeText(AddCarDetails.this, getString(R.string.please_try_again), Toast.LENGTH_SHORT).show();
}
} else {
// displayMessage(getString(R.string.please_try_again));
Toast.makeText(AddCarDetails.this, getString(R.string.please_try_again), Toast.LENGTH_SHORT).show();
}
} catch (Exception e) {
// displayMessage(getString(R.string.something_went_wrong));
Toast.makeText(AddCarDetails.this, getString(R.string.something_went_wrong), Toast.LENGTH_SHORT).show();
}
}
}
}) {
@Override
public Map<String, String> getHeaders() throws AuthFailureError {
HashMap<String, String> headers = new HashMap<String, String>();
headers.put("X-Requested-With", "XMLHttpRequest");
headers.put("Authorization", "" + "Bearer" + " " + SharedHelper.getKey(AddCarDetails.this, KeyHelper.KEY_ACCESS_TOKEN));
return headers;
}
};
XuberServicesApplication.getInstance().addToRequestQueue(jsonObjectRequest);
}
public void findViewById() {
SpCabType = (Spinner) findViewById(R.id.SpCabType);
SpBrand = (Spinner) findViewById(R.id.SpBrand);
SpModel = (Spinner) findViewById(R.id.SpModel);
SpCapacity = (Spinner) findViewById(R.id.SpCapacity);
SpColor = (Spinner) findViewById(R.id.SpColor);
lnrRegister = (RelativeLayout) findViewById(R.id.lnrRegister);
etNumber = (EditText) findViewById(R.id.etNumber);
ivBack = (ImageView) findViewById(R.id.ivBack);
tvLogin11 = (TextView) findViewById(R.id.tvLogin11);
cc_food = (ConstraintLayout) findViewById(R.id.cc_food);
ccServices = (ConstraintLayout) findViewById(R.id.ccServices);
cc_carDetails = (ConstraintLayout) findViewById(R.id.cc_carDetails);
ivBack.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view)
{
onBackPressed();
}
});
tvLogin11.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view)
{
Intent intent = new Intent(AddCarDetails.this, ActivityPassword.class);
startActivity(intent);
}
});
ArrayAdapter<String> adapter11 = new ArrayAdapter<String>(this, R.layout.custom_spinner, cabType);
SpCabType.setAdapter(adapter11);
ArrayAdapter<String> adapter = new ArrayAdapter<String>(
this, R.layout.custom_spinner, modelllll);
SpModel.setAdapter(adapter);
ArrayAdapter<String> adapter23 = new ArrayAdapter<String>(this, R.layout.custom_spinner, capacity);
SpCapacity.setAdapter(adapter23);
helper = new ConnectionHelper(context);
isInternet = helper.isConnectingToInternet();
lnrRegister.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
Utilities.hideKeypad(AddCarDetails.this, lnrRegister);
if (checkValidations())
{
// registerAPI();
callRegisterrrr();
}
}
});
}
public boolean checkValidations() {
if (key.equalsIgnoreCase("direct"))
{
if (serviceIdOldScreen.equalsIgnoreCase("18"))
{
if (etVehicleName.getText().toString().trim().isEmpty())
{
Toast.makeText(this, "Vehicle Name can't be empty", Toast.LENGTH_SHORT).show();
return false;
}
else if (etVehicleNumber.getText().toString().trim().isEmpty())
{
Toast.makeText(this, "Vehicle Number can't be empty", Toast.LENGTH_SHORT).show();
return false;
}
} else {
if (cabTypeID.equalsIgnoreCase(""))
{
Toast.makeText(this, "Please choose a Cab Type", Toast.LENGTH_SHORT).show();
return false;
}
else if (etNumber.getText().toString().trim().isEmpty())
{
Toast.makeText(this, "Plate number can't be empty", Toast.LENGTH_SHORT).show();
return false;
} else if (etNumber.getText().toString().length()<5)
{
Toast.makeText(this, "Plate number must be atleast 5 digits long", Toast.LENGTH_SHORT).show();
return false;
}
else if (brandId.equalsIgnoreCase(""))
{
Toast.makeText(this, "Please choose your car brand", Toast.LENGTH_SHORT).show();
return false;
}
else if (modelId.equalsIgnoreCase(""))
{
Toast.makeText(this, "Choose the model of your car", Toast.LENGTH_SHORT).show();
return false;
} else if (capacityId.equalsIgnoreCase(""))
{
Toast.makeText(this, "Please choose capacity", Toast.LENGTH_SHORT).show();
return false;
} else if (colorSelect.equalsIgnoreCase(""))
{
Toast.makeText(this, "Please Choose your car color", Toast.LENGTH_SHORT).show();
return false;
}
}
}
return true;
}
@Override
public void onResponse(int RequestCode, String response) {
switch (RequestCode) {
case 500:
Log.e("CabTYpeList ", response);
try {
cablist.clear();
cablistName.clear();
JSONArray jsonArray = new JSONArray(response);
Log.e("jsonArrayLength ", jsonArray.length() + "");
cablistName.add("Select Cab Type");
if (jsonArray.length() > 0) {
for (int i = 0; i < jsonArray.length(); i++) {
JSONObject cabJson = jsonArray.getJSONObject(i);
CabType cabType = new CabType();
cabType.setId(cabJson.getString("id"));
cabType.setName(cabJson.getString("cab_name"));
cabType.setPrice(cabJson.getString("price"));
cabType.setImage(cabJson.getString("image"));
cablist.add(cabType);
cablistName.add(cabJson.getString("cab_name"));
}
}
Log.e("cablist ", cablist.size() + "");
Log.e("CabNameListSize ", cablistName.size() + "");
ArrayAdapter<String> adapter = new ArrayAdapter<String>(this, R.layout.custom_spinner, cablistName);
SpCabType.setAdapter(adapter);
SpCabType.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener()
{
@Override
public void onItemSelected(AdapterView<?> parent, View view, int position, long id)
{
if (position == 0)
{
cabTypeID = "";
Log.e("cabTypeID ", cabTypeID);
} else
{
cabTypeID = cablist.get(position - 1).getId() + "";
Log.e("cabTypeID ", cabTypeID);
}
}
@Override
public void onNothingSelected(AdapterView<?> parent)
{
}
});
}
catch (JSONException e)
{
e.printStackTrace();
}
break;
case 1000:
Log.e("BrandList ", response);
try {
brandsList.clear();
brandListName.clear();
JSONObject jsonObject = new JSONObject(response);
if (jsonObject.getString("status").equalsIgnoreCase("success")) {
JSONArray jsonArray = jsonObject.getJSONArray("result");
Log.e("jsonArrayLength ", jsonArray.length() + "");
brandListName.add("Select Brand");
if (jsonArray.length() > 0) {
for (int i = 0; i < jsonArray.length(); i++) {
JSONObject cabJson = jsonArray.getJSONObject(i);
BrandList brandList = new BrandList();
brandList.setId(cabJson.getString("id"));
brandList.setBrandName(cabJson.getString("brand_name"));
brandsList.add(brandList);
brandListName.add(cabJson.getString("brand_name"));
}
}
Log.e("brandsList ", brandsList.size() + "");
Log.e("brandListName ", brandListName.size() + "");
ArrayAdapter<String> adapter = new ArrayAdapter<String>(this, R.layout.custom_spinner, brandListName);
SpBrand.setAdapter(adapter);
SpBrand.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() {
@Override
public void onItemSelected(AdapterView<?> parent, View view, int position, long id) {
if (position == 0) {
brandId = "";
Log.e("brandId ", brandId);
} else {
brandId = brandsList.get(position - 1).getId() + "";
Log.e("brandId ", brandId);
callModelList(brandId);
}
}
@Override
public void onNothingSelected(AdapterView<?> parent) {
}
});
}
} catch (JSONException e) {
e.printStackTrace();
}
break;
case 1500:
Log.e("ModelList ", response);
try {
JSONObject jsonObject = new JSONObject(response);
if (jsonObject.getString("status").equalsIgnoreCase("success")) {
modelsList.clear();
modelListName.clear();
JSONArray jsonArray = jsonObject.getJSONArray("result");
Log.e("jsonArrayLength ", jsonArray.length() + "");
modelListName.add("Select Model");
if (jsonArray.length() > 0) {
for (int i = 0; i < jsonArray.length(); i++) {
JSONObject cabJson = jsonArray.getJSONObject(i);
ModelList modelList = new ModelList();
modelList.setId(cabJson.getString("id"));
modelList.setName(cabJson.getString("model_name"));
modelsList.add(modelList);
modelListName.add(cabJson.getString("model_name"));
}
}
Log.e("modelsList ", modelsList.size() + "");
Log.e("modelListName ", modelListName.size() + "");
ArrayAdapter<String> adapter = new ArrayAdapter<String>(this,
R.layout.custom_spinner, modelListName);
SpModel.setAdapter(adapter);
SpModel.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() {
@Override
public void onItemSelected(AdapterView<?> parent, View view, int position, long id) {
if (position == 0) {
modelId = "";
Log.e("modelId ", modelId);
} else {
modelId = modelsList.get(position - 1).getId() + "";
Log.e("modelId ", modelId);
// callCapacityList(modelId);
}
}
@Override
public void onNothingSelected(AdapterView<?> parent) {
}
});
}
} catch (JSONException e) {
e.printStackTrace();
}
break;
case 2000:
Log.e("capacityList ", response);
try {
JSONObject jsonObject = new JSONObject(response);
if (jsonObject.getString("status").equalsIgnoreCase("success")) {
capacityList.clear();
capacityListName.clear();
JSONArray jsonArray = jsonObject.getJSONArray("result");
Log.e("jsonArrayLength ", jsonArray.length() + "");
capacityListName.add("Select Capacity");
if (jsonArray.length() > 0) {
for (int i = 0; i < jsonArray.length(); i++) {
JSONObject cabJson = jsonArray.getJSONObject(i);
CapacityList list = new CapacityList();
list.setId(cabJson.getString("id"));
list.setName(cabJson.getString("cc_name"));
capacityList.add(list);
capacityListName.add(cabJson.getString("cc_name"));
}
}
Log.e("capacityList ", capacityList.size() + "");
Log.e("capacityListName ", capacityListName.size() + "");
ArrayAdapter<String> adapter = new ArrayAdapter<String>
(this, R.layout.custom_spinner, capacityListName);
SpCapacity.setAdapter(adapter);
SpCapacity.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() {
@Override
public void onItemSelected(AdapterView<?> parent, View view, int position, long id) {
if (position == 0) {
capacityId = "";
Log.e("capacityId ", capacityId);
} else {
capacityId = capacityList.get(position - 1).getId() + "";
Log.e("capacityId ", capacityId);
}
}
@Override
public void onNothingSelected(AdapterView<?> parent) {
}
});
}
} catch (JSONException e) {
e.printStackTrace();
}
break;
case 105:
Log.e("ResponseServiceList ", response);
try {
JSONObject jsonObject = new JSONObject(response);
Log.e("jsonObject ", jsonObject.toString());
listMatrix.clear();
matrixName.clear();
listOthersd.clear();
otherName.clear();
matrixName.add("Choose a Service");
otherName.add("Choose Other Services");
JSONArray matrix = jsonObject.getJSONArray("matrix");
if (matrix.length() > 0) {
for (int i = 0; i < matrix.length(); i++) {
MatrixServices matrixServices = new MatrixServices();
JSONObject jsonObject1 = matrix.getJSONObject(i);
matrixServices.setId(jsonObject1.getString("id"));
matrixServices.setName(jsonObject1.getString("service_types"));
listMatrix.add(matrixServices);
// matrixName.add(jsonObject1.getString("service_types"));
matrixName.add(jsonObject1.getString("name"));
}
}
JSONArray others = jsonObject.getJSONArray("others");
if (others.length() > 0) {
for (int j = 0; j < others.length(); j++) {
OtherServices other = new OtherServices();
JSONObject jsonObject1 = others.getJSONObject(j);
other.setId(jsonObject1.getString("id"));
other.setName(jsonObject1.getString("name"));
listOthersd.add(other);
otherName.add(jsonObject1.getString("name"));
}
}
matrixName.add(4, "Others");
ArrayAdapter<String> adapter = new ArrayAdapter<String>(this, R.layout.custom_spinner, matrixName);
sp_service.setAdapter(adapter);
final ArrayAdapter<String> spinnerArrayAdapter1 = new ArrayAdapter<String>(
this, R.layout.custom_spinner, matrixName) {
@Override
public View getDropDownView(int position, View convertView,
ViewGroup parent) {
View view = super.getDropDownView(position, convertView, parent);
TextView tv = (TextView) view;
if (position == 0) {
// Set the item text color
tv.setTextColor(Color.parseColor("#091046"));
} else {
// Set the alternate item text color
tv.setTextColor(Color.parseColor("#091046"));
}
return view;
}
};
spinnerArrayAdapter1.setDropDownViewResource(R.layout.custom_spinner);
sp_service.setAdapter(spinnerArrayAdapter1);
sp_service.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() {
@Override
public void onItemSelected(AdapterView<?> parent, View view, int position, long id) {
if (position == matrixName.size() - 1)
{
serviceID = "";
sp_sub_service.setVisibility(View.VISIBLE);
rlSubService.setVisibility(View.VISIBLE);
Log.e("Serviceid ", serviceID);
Log.e("SubServiceLisdt ", listOthersd.size() + "");
Log.e("name ", otherName.size() + "");
setSubServiceAdapter();
} else {
if (position == 0) {
serviceID = "";
Log.e("Serviceid ", serviceID);
serviceType = "";
Log.e("serviceType ", serviceType);
} else {
serviceID = listMatrix.get(position - 1).getId() + "";
Log.e("Serviceid ", serviceID);
serviceType = listMatrix.get(position - 1).getName() + "";
Log.e("serviceType ", serviceType);
sp_sub_service.setVisibility(View.GONE);
rlSubService.setVisibility(View.GONE);
}
if (key.equalsIgnoreCase("google"))
{
if (serviceID.equalsIgnoreCase("18"))
{
cc_food.setVisibility(View.VISIBLE);
cc_carDetails.setVisibility(View.GONE);
} else if (serviceID.equalsIgnoreCase("19"))
{
cc_food.setVisibility(View.GONE);
cc_carDetails.setVisibility(View.GONE);
}
else
{
cc_food.setVisibility(View.GONE);
cc_carDetails.setVisibility(View.VISIBLE);
}
}else if (key.equalsIgnoreCase("facebook"))
{
if (serviceID.equalsIgnoreCase("18"))
{
cc_food.setVisibility(View.VISIBLE);
cc_carDetails.setVisibility(View.GONE);
}
else if (serviceID.equalsIgnoreCase("19"))
{
cc_food.setVisibility(View.GONE);
cc_carDetails.setVisibility(View.GONE);
}
else
{
cc_food.setVisibility(View.GONE);
cc_carDetails.setVisibility(View.VISIBLE);
}
}
}
}
@Override
public void onNothingSelected(AdapterView<?> parent)
{
}
});
} catch (Exception ex) {
ex.printStackTrace();
}
break;
case 100:
try {
Log.e("SignUpResponseeeee ", response.toString());
JSONObject jsonObject=new JSONObject(response);
if (jsonObject.has("status"))
{
if (jsonObject.getString("status").equalsIgnoreCase("error"))
{
Toast.makeText(this, jsonObject.getString("message"), Toast.LENGTH_SHORT).show();
// showVerificationPopUp();
}
else
{
showVerificationPopUp();
}
}
else
{
if (jsonObject.has("error"))
{
Toast.makeText(this, jsonObject.getString("error"), Toast.LENGTH_SHORT).show();
}
}
/*
else {
if (jsonObject.has("email"))
{
showVerificationPopUp();
}
else {
Toast.makeText(this, jsonObject.getString("error"), Toast.LENGTH_SHORT).show();
}
*//*SharedHelper.putKey(context, "access_token", jsonObject.optString("access_token"));
SharedHelper.putKey(context, "refresh_token", jsonObject.optString("refresh_token"));
SharedHelper.putKey(context, "token_type", jsonObject.optString("token_type"));
getProfile();*//*
}*/
}
catch (Exception ex)
{
ex.printStackTrace();
}
break;
}
}
String cabTypeID = "";
String brandId = "";
String modelId = "";
String capacityId = "";
String colorSelect = "";
public void setSubServiceAdapter()
{
ArrayAdapter<String> adapter = new ArrayAdapter<String>(
AddCarDetails.this, R.layout.custom_spinner, otherName);
sp_sub_service.setAdapter(adapter);
final ArrayAdapter<String> spinnerArrayAdapter1 = new ArrayAdapter<String>(
AddCarDetails.this,R.layout.custom_spinner,otherName)
{
@Override
public View getDropDownView(int position, View convertView,
ViewGroup parent)
{
View view = super.getDropDownView(position, convertView, parent);
TextView tv = (TextView) view;
if(position ==0)
{
// Set the item text color
tv.setTextColor(Color.parseColor("#091046"));
}
else
{
// Set the alternate item text color
tv.setTextColor(Color.parseColor("#091046"));
}
return view;
}
};
spinnerArrayAdapter1.setDropDownViewResource(R.layout.custom_spinner);
sp_sub_service.setAdapter(spinnerArrayAdapter1);
sp_sub_service.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener()
{
@Override
public void onItemSelected(AdapterView<?> parent, View view, int position, long id)
{
if (position==0)
{
serviceID="";
Log.e("Serviceid ",serviceID);
}
else
{
serviceID=listOthersd.get(position-1).getId()+"";
Log.e("Serviceid ",serviceID);
}
}
@Override
public void onNothingSelected(AdapterView<?> parent)
{
}
});
}
ArrayList<MatrixServices> listMatrix=new ArrayList<>();
ArrayList<String> matrixName=new ArrayList<>();
ArrayList<OtherServices> listOthersd=new ArrayList<>();
ArrayList<String> otherName=new ArrayList<>();
String serviceID="";
String serviceType="";
}
| [
"ravina_kapila@esferasoft.com"
] | ravina_kapila@esferasoft.com |
b86cf84a97f4b127c23dee08a7ea5092664eb52c | abeb77a282459b509f07b0ed2e60c6f60507f62f | /frameWidget/build/generated/source/r/androidTest/debug/android/support/design/R.java | c4b8aedcf0b1d81bd516a12584e1be59cf154d77 | [] | no_license | phx1314/Borrow12 | 2e972eb36b6e3cef00746ce7aa33c5b26835083d | 5039d1c0c5018108b99fa92f8afddfea7e78891e | refs/heads/master | 2020-08-27T02:33:56.897204 | 2019-10-24T05:42:10 | 2019-10-24T05:42:10 | 217,219,492 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 115,619 | java | /* AUTO-GENERATED FILE. DO NOT MODIFY.
*
* This class was automatically generated by the
* aapt tool from the resource data it found. It
* should not be modified by hand.
*/
package android.support.design;
public final class R {
public static final class anim {
public static final int abc_fade_in = 0x7f050000;
public static final int abc_fade_out = 0x7f050001;
public static final int abc_grow_fade_in_from_bottom = 0x7f050002;
public static final int abc_popup_enter = 0x7f050003;
public static final int abc_popup_exit = 0x7f050004;
public static final int abc_shrink_fade_out_from_bottom = 0x7f050005;
public static final int abc_slide_in_bottom = 0x7f050006;
public static final int abc_slide_in_top = 0x7f050007;
public static final int abc_slide_out_bottom = 0x7f050008;
public static final int abc_slide_out_top = 0x7f050009;
public static final int design_appbar_state_list_animator = 0x7f05000d;
public static final int design_bottom_sheet_slide_in = 0x7f05000e;
public static final int design_bottom_sheet_slide_out = 0x7f05000f;
public static final int design_fab_in = 0x7f050010;
public static final int design_fab_out = 0x7f050011;
public static final int design_snackbar_in = 0x7f050012;
public static final int design_snackbar_out = 0x7f050013;
}
public static final class attr {
public static final int actionBarDivider = 0x7f010054;
public static final int actionBarItemBackground = 0x7f010055;
public static final int actionBarPopupTheme = 0x7f01004e;
public static final int actionBarSize = 0x7f010053;
public static final int actionBarSplitStyle = 0x7f010050;
public static final int actionBarStyle = 0x7f01004f;
public static final int actionBarTabBarStyle = 0x7f01004a;
public static final int actionBarTabStyle = 0x7f010049;
public static final int actionBarTabTextStyle = 0x7f01004b;
public static final int actionBarTheme = 0x7f010051;
public static final int actionBarWidgetTheme = 0x7f010052;
public static final int actionButtonStyle = 0x7f01006f;
public static final int actionDropDownStyle = 0x7f01006b;
public static final int actionLayout = 0x7f010108;
public static final int actionMenuTextAppearance = 0x7f010056;
public static final int actionMenuTextColor = 0x7f010057;
public static final int actionModeBackground = 0x7f01005a;
public static final int actionModeCloseButtonStyle = 0x7f010059;
public static final int actionModeCloseDrawable = 0x7f01005c;
public static final int actionModeCopyDrawable = 0x7f01005e;
public static final int actionModeCutDrawable = 0x7f01005d;
public static final int actionModeFindDrawable = 0x7f010062;
public static final int actionModePasteDrawable = 0x7f01005f;
public static final int actionModePopupWindowStyle = 0x7f010064;
public static final int actionModeSelectAllDrawable = 0x7f010060;
public static final int actionModeShareDrawable = 0x7f010061;
public static final int actionModeSplitBackground = 0x7f01005b;
public static final int actionModeStyle = 0x7f010058;
public static final int actionModeWebSearchDrawable = 0x7f010063;
public static final int actionOverflowButtonStyle = 0x7f01004c;
public static final int actionOverflowMenuStyle = 0x7f01004d;
public static final int actionProviderClass = 0x7f01010a;
public static final int actionViewClass = 0x7f010109;
public static final int activityChooserViewStyle = 0x7f010077;
public static final int alertDialogButtonGroupStyle = 0x7f01009b;
public static final int alertDialogCenterButtons = 0x7f01009c;
public static final int alertDialogStyle = 0x7f01009a;
public static final int alertDialogTheme = 0x7f01009d;
public static final int allowStacking = 0x7f0100bf;
public static final int alpha = 0x7f0100d6;
public static final int arrowHeadLength = 0x7f0100eb;
public static final int arrowShaftLength = 0x7f0100ec;
public static final int autoCompleteTextViewStyle = 0x7f0100a2;
public static final int background = 0x7f01001b;
public static final int backgroundSplit = 0x7f01001d;
public static final int backgroundStacked = 0x7f01001c;
public static final int backgroundTint = 0x7f01018f;
public static final int backgroundTintMode = 0x7f010190;
public static final int barLength = 0x7f0100ed;
public static final int behavior_hideable = 0x7f0100bd;
public static final int behavior_overlapTop = 0x7f01011f;
public static final int behavior_peekHeight = 0x7f0100bc;
public static final int behavior_skipCollapsed = 0x7f0100be;
public static final int borderWidth = 0x7f0100f9;
public static final int borderlessButtonStyle = 0x7f010074;
public static final int bottomSheetDialogTheme = 0x7f0100e4;
public static final int bottomSheetStyle = 0x7f0100e5;
public static final int buttonBarButtonStyle = 0x7f010071;
public static final int buttonBarNegativeButtonStyle = 0x7f0100a0;
public static final int buttonBarNeutralButtonStyle = 0x7f0100a1;
public static final int buttonBarPositiveButtonStyle = 0x7f01009f;
public static final int buttonBarStyle = 0x7f010070;
public static final int buttonGravity = 0x7f010181;
public static final int buttonPanelSideLayout = 0x7f010030;
public static final int buttonStyle = 0x7f0100a3;
public static final int buttonStyleSmall = 0x7f0100a4;
public static final int buttonTint = 0x7f0100d7;
public static final int buttonTintMode = 0x7f0100d8;
public static final int checkboxStyle = 0x7f0100a5;
public static final int checkedTextViewStyle = 0x7f0100a6;
public static final int closeIcon = 0x7f010124;
public static final int closeItemLayout = 0x7f01002d;
public static final int collapseContentDescription = 0x7f010183;
public static final int collapseIcon = 0x7f010182;
public static final int collapsedTitleGravity = 0x7f0100d1;
public static final int collapsedTitleTextAppearance = 0x7f0100cb;
public static final int color = 0x7f0100e7;
public static final int colorAccent = 0x7f010092;
public static final int colorBackgroundFloating = 0x7f010099;
public static final int colorButtonNormal = 0x7f010096;
public static final int colorControlActivated = 0x7f010094;
public static final int colorControlHighlight = 0x7f010095;
public static final int colorControlNormal = 0x7f010093;
public static final int colorPrimary = 0x7f010090;
public static final int colorPrimaryDark = 0x7f010091;
public static final int colorSwitchThumbNormal = 0x7f010097;
public static final int commitIcon = 0x7f010129;
public static final int contentInsetEnd = 0x7f010026;
public static final int contentInsetEndWithActions = 0x7f01002a;
public static final int contentInsetLeft = 0x7f010027;
public static final int contentInsetRight = 0x7f010028;
public static final int contentInsetStart = 0x7f010025;
public static final int contentInsetStartWithNavigation = 0x7f010029;
public static final int contentScrim = 0x7f0100cc;
public static final int controlBackground = 0x7f010098;
public static final int counterEnabled = 0x7f010168;
public static final int counterMaxLength = 0x7f010169;
public static final int counterOverflowTextAppearance = 0x7f01016b;
public static final int counterTextAppearance = 0x7f01016a;
public static final int customNavigationLayout = 0x7f01001e;
public static final int defaultQueryHint = 0x7f010123;
public static final int dialogPreferredPadding = 0x7f010069;
public static final int dialogTheme = 0x7f010068;
public static final int displayOptions = 0x7f010014;
public static final int divider = 0x7f01001a;
public static final int dividerHorizontal = 0x7f010076;
public static final int dividerPadding = 0x7f010106;
public static final int dividerVertical = 0x7f010075;
public static final int drawableSize = 0x7f0100e9;
public static final int drawerArrowStyle = 0x7f010003;
public static final int dropDownListViewStyle = 0x7f010088;
public static final int dropdownListPreferredItemHeight = 0x7f01006c;
public static final int editTextBackground = 0x7f01007d;
public static final int editTextColor = 0x7f01007c;
public static final int editTextStyle = 0x7f0100a7;
public static final int elevation = 0x7f01002b;
public static final int errorEnabled = 0x7f010166;
public static final int errorTextAppearance = 0x7f010167;
public static final int expandActivityOverflowButtonDrawable = 0x7f01002f;
public static final int expanded = 0x7f010035;
public static final int expandedTitleGravity = 0x7f0100d2;
public static final int expandedTitleMargin = 0x7f0100c5;
public static final int expandedTitleMarginBottom = 0x7f0100c9;
public static final int expandedTitleMarginEnd = 0x7f0100c8;
public static final int expandedTitleMarginStart = 0x7f0100c6;
public static final int expandedTitleMarginTop = 0x7f0100c7;
public static final int expandedTitleTextAppearance = 0x7f0100ca;
public static final int fabSize = 0x7f0100f7;
public static final int foregroundInsidePadding = 0x7f0100fb;
public static final int gapBetweenBars = 0x7f0100ea;
public static final int goIcon = 0x7f010125;
public static final int headerLayout = 0x7f010117;
public static final int height = 0x7f010004;
public static final int hideOnContentScroll = 0x7f010024;
public static final int hintAnimationEnabled = 0x7f01016c;
public static final int hintEnabled = 0x7f010165;
public static final int hintTextAppearance = 0x7f010164;
public static final int homeAsUpIndicator = 0x7f01006e;
public static final int homeLayout = 0x7f01001f;
public static final int icon = 0x7f010018;
public static final int iconifiedByDefault = 0x7f010121;
public static final int imageButtonStyle = 0x7f01007e;
public static final int indeterminateProgressStyle = 0x7f010021;
public static final int initialActivityCount = 0x7f01002e;
public static final int insetForeground = 0x7f01011e;
public static final int isLightTheme = 0x7f010005;
public static final int itemBackground = 0x7f010115;
public static final int itemIconTint = 0x7f010113;
public static final int itemPadding = 0x7f010023;
public static final int itemTextAppearance = 0x7f010116;
public static final int itemTextColor = 0x7f010114;
public static final int keylines = 0x7f0100d9;
public static final int layout = 0x7f010120;
public static final int layoutManager = 0x7f01011a;
public static final int layout_anchor = 0x7f0100dc;
public static final int layout_anchorGravity = 0x7f0100de;
public static final int layout_behavior = 0x7f0100db;
public static final int layout_collapseMode = 0x7f0100d4;
public static final int layout_collapseParallaxMultiplier = 0x7f0100d5;
public static final int layout_keyline = 0x7f0100dd;
public static final int layout_scrollFlags = 0x7f010038;
public static final int layout_scrollInterpolator = 0x7f010039;
public static final int listChoiceBackgroundIndicator = 0x7f01008f;
public static final int listDividerAlertDialog = 0x7f01006a;
public static final int listItemLayout = 0x7f010034;
public static final int listLayout = 0x7f010031;
public static final int listMenuViewStyle = 0x7f0100af;
public static final int listPopupWindowStyle = 0x7f010089;
public static final int listPreferredItemHeight = 0x7f010083;
public static final int listPreferredItemHeightLarge = 0x7f010085;
public static final int listPreferredItemHeightSmall = 0x7f010084;
public static final int listPreferredItemPaddingLeft = 0x7f010086;
public static final int listPreferredItemPaddingRight = 0x7f010087;
public static final int logo = 0x7f010019;
public static final int logoDescription = 0x7f010186;
public static final int maxActionInlineWidth = 0x7f01013b;
public static final int maxButtonHeight = 0x7f010180;
public static final int measureWithLargestChild = 0x7f010104;
public static final int menu = 0x7f010112;
public static final int multiChoiceItemLayout = 0x7f010032;
public static final int navigationContentDescription = 0x7f010185;
public static final int navigationIcon = 0x7f010184;
public static final int navigationMode = 0x7f010013;
public static final int overlapAnchor = 0x7f010118;
public static final int paddingEnd = 0x7f01018d;
public static final int paddingStart = 0x7f01018c;
public static final int panelBackground = 0x7f01008c;
public static final int panelMenuListTheme = 0x7f01008e;
public static final int panelMenuListWidth = 0x7f01008d;
public static final int popupMenuStyle = 0x7f01007a;
public static final int popupTheme = 0x7f01002c;
public static final int popupWindowStyle = 0x7f01007b;
public static final int preserveIconSpacing = 0x7f01010b;
public static final int pressedTranslationZ = 0x7f0100f8;
public static final int progressBarPadding = 0x7f010022;
public static final int progressBarStyle = 0x7f010020;
public static final int queryBackground = 0x7f01012b;
public static final int queryHint = 0x7f010122;
public static final int radioButtonStyle = 0x7f0100a8;
public static final int ratingBarStyle = 0x7f0100a9;
public static final int ratingBarStyleIndicator = 0x7f0100aa;
public static final int ratingBarStyleSmall = 0x7f0100ab;
public static final int reverseLayout = 0x7f01011c;
public static final int rippleColor = 0x7f0100f6;
public static final int scrimAnimationDuration = 0x7f0100d0;
public static final int scrimVisibleHeightTrigger = 0x7f0100cf;
public static final int searchHintIcon = 0x7f010127;
public static final int searchIcon = 0x7f010126;
public static final int searchViewStyle = 0x7f010082;
public static final int seekBarStyle = 0x7f0100ac;
public static final int selectableItemBackground = 0x7f010072;
public static final int selectableItemBackgroundBorderless = 0x7f010073;
public static final int showAsAction = 0x7f010107;
public static final int showDividers = 0x7f010105;
public static final int showText = 0x7f010153;
public static final int singleChoiceItemLayout = 0x7f010033;
public static final int spanCount = 0x7f01011b;
public static final int spinBars = 0x7f0100e8;
public static final int spinnerDropDownItemStyle = 0x7f01006d;
public static final int spinnerStyle = 0x7f0100ad;
public static final int splitTrack = 0x7f010152;
public static final int srcCompat = 0x7f01003a;
public static final int stackFromEnd = 0x7f01011d;
public static final int state_above_anchor = 0x7f010119;
public static final int state_collapsed = 0x7f010036;
public static final int state_collapsible = 0x7f010037;
public static final int statusBarBackground = 0x7f0100da;
public static final int statusBarScrim = 0x7f0100cd;
public static final int subMenuArrow = 0x7f01010c;
public static final int submitBackground = 0x7f01012c;
public static final int subtitle = 0x7f010015;
public static final int subtitleTextAppearance = 0x7f010179;
public static final int subtitleTextColor = 0x7f010188;
public static final int subtitleTextStyle = 0x7f010017;
public static final int suggestionRowLayout = 0x7f01012a;
public static final int switchMinWidth = 0x7f010150;
public static final int switchPadding = 0x7f010151;
public static final int switchStyle = 0x7f0100ae;
public static final int switchTextAppearance = 0x7f01014f;
public static final int tabBackground = 0x7f010157;
public static final int tabContentStart = 0x7f010156;
public static final int tabGravity = 0x7f010159;
public static final int tabIndicatorColor = 0x7f010154;
public static final int tabIndicatorHeight = 0x7f010155;
public static final int tabMaxWidth = 0x7f01015b;
public static final int tabMinWidth = 0x7f01015a;
public static final int tabMode = 0x7f010158;
public static final int tabPadding = 0x7f010163;
public static final int tabPaddingBottom = 0x7f010162;
public static final int tabPaddingEnd = 0x7f010161;
public static final int tabPaddingStart = 0x7f01015f;
public static final int tabPaddingTop = 0x7f010160;
public static final int tabSelectedTextColor = 0x7f01015e;
public static final int tabTextAppearance = 0x7f01015c;
public static final int tabTextColor = 0x7f01015d;
public static final int textAllCaps = 0x7f01003e;
public static final int textAppearanceLargePopupMenu = 0x7f010065;
public static final int textAppearanceListItem = 0x7f01008a;
public static final int textAppearanceListItemSmall = 0x7f01008b;
public static final int textAppearancePopupMenuHeader = 0x7f010067;
public static final int textAppearanceSearchResultSubtitle = 0x7f010080;
public static final int textAppearanceSearchResultTitle = 0x7f01007f;
public static final int textAppearanceSmallPopupMenu = 0x7f010066;
public static final int textColorAlertDialogListItem = 0x7f01009e;
public static final int textColorError = 0x7f0100e6;
public static final int textColorSearchUrl = 0x7f010081;
public static final int theme = 0x7f01018e;
public static final int thickness = 0x7f0100ee;
public static final int thumbTextPadding = 0x7f01014e;
public static final int thumbTint = 0x7f010149;
public static final int thumbTintMode = 0x7f01014a;
public static final int tickMark = 0x7f01003b;
public static final int tickMarkTint = 0x7f01003c;
public static final int tickMarkTintMode = 0x7f01003d;
public static final int title = 0x7f010008;
public static final int titleEnabled = 0x7f0100d3;
public static final int titleMargin = 0x7f01017a;
public static final int titleMarginBottom = 0x7f01017e;
public static final int titleMarginEnd = 0x7f01017c;
public static final int titleMarginStart = 0x7f01017b;
public static final int titleMarginTop = 0x7f01017d;
public static final int titleMargins = 0x7f01017f;
public static final int titleTextAppearance = 0x7f010178;
public static final int titleTextColor = 0x7f010187;
public static final int titleTextStyle = 0x7f010016;
public static final int toolbarId = 0x7f0100ce;
public static final int toolbarNavigationButtonStyle = 0x7f010079;
public static final int toolbarStyle = 0x7f010078;
public static final int track = 0x7f01014b;
public static final int trackTint = 0x7f01014c;
public static final int trackTintMode = 0x7f01014d;
public static final int useCompatPadding = 0x7f0100fa;
public static final int voiceIcon = 0x7f010128;
public static final int windowActionBar = 0x7f01003f;
public static final int windowActionBarOverlay = 0x7f010041;
public static final int windowActionModeOverlay = 0x7f010042;
public static final int windowFixedHeightMajor = 0x7f010046;
public static final int windowFixedHeightMinor = 0x7f010044;
public static final int windowFixedWidthMajor = 0x7f010043;
public static final int windowFixedWidthMinor = 0x7f010045;
public static final int windowMinWidthMajor = 0x7f010047;
public static final int windowMinWidthMinor = 0x7f010048;
public static final int windowNoTitle = 0x7f010040;
}
public static final class bool {
public static final int abc_action_bar_embed_tabs = 0x7f0c0000;
public static final int abc_allow_stacked_button_bar = 0x7f0c0001;
public static final int abc_config_actionMenuItemAllCaps = 0x7f0c0002;
public static final int abc_config_closeDialogWhenTouchOutside = 0x7f0c0003;
public static final int abc_config_showMenuShortcutsWhenKeyboardPresent = 0x7f0c0004;
}
public static final class color {
public static final int abc_background_cache_hint_selector_material_dark = 0x7f0e00dd;
public static final int abc_background_cache_hint_selector_material_light = 0x7f0e00de;
public static final int abc_btn_colored_borderless_text_material = 0x7f0e00df;
public static final int abc_color_highlight_material = 0x7f0e00e0;
public static final int abc_input_method_navigation_guard = 0x7f0e0008;
public static final int abc_primary_text_disable_only_material_dark = 0x7f0e00e1;
public static final int abc_primary_text_disable_only_material_light = 0x7f0e00e2;
public static final int abc_primary_text_material_dark = 0x7f0e00e3;
public static final int abc_primary_text_material_light = 0x7f0e00e4;
public static final int abc_search_url_text = 0x7f0e00e5;
public static final int abc_search_url_text_normal = 0x7f0e0009;
public static final int abc_search_url_text_pressed = 0x7f0e000a;
public static final int abc_search_url_text_selected = 0x7f0e000b;
public static final int abc_secondary_text_material_dark = 0x7f0e00e6;
public static final int abc_secondary_text_material_light = 0x7f0e00e7;
public static final int abc_tint_btn_checkable = 0x7f0e00e8;
public static final int abc_tint_default = 0x7f0e00e9;
public static final int abc_tint_edittext = 0x7f0e00ea;
public static final int abc_tint_seek_thumb = 0x7f0e00eb;
public static final int abc_tint_spinner = 0x7f0e00ec;
public static final int abc_tint_switch_thumb = 0x7f0e00ed;
public static final int abc_tint_switch_track = 0x7f0e00ee;
public static final int accent_material_dark = 0x7f0e000c;
public static final int accent_material_light = 0x7f0e000d;
public static final int background_floating_material_dark = 0x7f0e0012;
public static final int background_floating_material_light = 0x7f0e0013;
public static final int background_material_dark = 0x7f0e0014;
public static final int background_material_light = 0x7f0e0015;
public static final int bright_foreground_disabled_material_dark = 0x7f0e0024;
public static final int bright_foreground_disabled_material_light = 0x7f0e0025;
public static final int bright_foreground_inverse_material_dark = 0x7f0e0026;
public static final int bright_foreground_inverse_material_light = 0x7f0e0027;
public static final int bright_foreground_material_dark = 0x7f0e0028;
public static final int bright_foreground_material_light = 0x7f0e0029;
public static final int button_material_dark = 0x7f0e003d;
public static final int button_material_light = 0x7f0e003e;
public static final int design_fab_shadow_end_color = 0x7f0e005d;
public static final int design_fab_shadow_mid_color = 0x7f0e005e;
public static final int design_fab_shadow_start_color = 0x7f0e005f;
public static final int design_fab_stroke_end_inner_color = 0x7f0e0060;
public static final int design_fab_stroke_end_outer_color = 0x7f0e0061;
public static final int design_fab_stroke_top_inner_color = 0x7f0e0062;
public static final int design_fab_stroke_top_outer_color = 0x7f0e0063;
public static final int design_snackbar_background_color = 0x7f0e0064;
public static final int design_textinput_error_color_dark = 0x7f0e0065;
public static final int design_textinput_error_color_light = 0x7f0e0066;
public static final int dim_foreground_disabled_material_dark = 0x7f0e0067;
public static final int dim_foreground_disabled_material_light = 0x7f0e0068;
public static final int dim_foreground_material_dark = 0x7f0e0069;
public static final int dim_foreground_material_light = 0x7f0e006a;
public static final int foreground_material_dark = 0x7f0e006d;
public static final int foreground_material_light = 0x7f0e006e;
public static final int highlighted_text_material_dark = 0x7f0e0075;
public static final int highlighted_text_material_light = 0x7f0e0076;
public static final int hint_foreground_material_dark = 0x7f0e0077;
public static final int hint_foreground_material_light = 0x7f0e0078;
public static final int material_blue_grey_800 = 0x7f0e007c;
public static final int material_blue_grey_900 = 0x7f0e007d;
public static final int material_blue_grey_950 = 0x7f0e007e;
public static final int material_deep_teal_200 = 0x7f0e007f;
public static final int material_deep_teal_500 = 0x7f0e0080;
public static final int material_grey_100 = 0x7f0e0081;
public static final int material_grey_300 = 0x7f0e0082;
public static final int material_grey_50 = 0x7f0e0083;
public static final int material_grey_600 = 0x7f0e0084;
public static final int material_grey_800 = 0x7f0e0085;
public static final int material_grey_850 = 0x7f0e0086;
public static final int material_grey_900 = 0x7f0e0087;
public static final int primary_dark_material_dark = 0x7f0e0092;
public static final int primary_dark_material_light = 0x7f0e0093;
public static final int primary_material_dark = 0x7f0e0094;
public static final int primary_material_light = 0x7f0e0095;
public static final int primary_text_default_material_dark = 0x7f0e0096;
public static final int primary_text_default_material_light = 0x7f0e0097;
public static final int primary_text_disabled_material_dark = 0x7f0e0098;
public static final int primary_text_disabled_material_light = 0x7f0e0099;
public static final int ripple_material_dark = 0x7f0e009a;
public static final int ripple_material_light = 0x7f0e009b;
public static final int secondary_text_default_material_dark = 0x7f0e009c;
public static final int secondary_text_default_material_light = 0x7f0e009d;
public static final int secondary_text_disabled_material_dark = 0x7f0e009e;
public static final int secondary_text_disabled_material_light = 0x7f0e009f;
public static final int switch_thumb_disabled_material_dark = 0x7f0e00ab;
public static final int switch_thumb_disabled_material_light = 0x7f0e00ac;
public static final int switch_thumb_material_dark = 0x7f0e00ef;
public static final int switch_thumb_material_light = 0x7f0e00f0;
public static final int switch_thumb_normal_material_dark = 0x7f0e00ad;
public static final int switch_thumb_normal_material_light = 0x7f0e00ae;
}
public static final class dimen {
public static final int abc_action_bar_content_inset_material = 0x7f0a002c;
public static final int abc_action_bar_content_inset_with_nav = 0x7f0a002d;
public static final int abc_action_bar_default_height_material = 0x7f0a0001;
public static final int abc_action_bar_default_padding_end_material = 0x7f0a002e;
public static final int abc_action_bar_default_padding_start_material = 0x7f0a002f;
public static final int abc_action_bar_icon_vertical_padding_material = 0x7f0a0039;
public static final int abc_action_bar_overflow_padding_end_material = 0x7f0a003a;
public static final int abc_action_bar_overflow_padding_start_material = 0x7f0a003b;
public static final int abc_action_bar_progress_bar_size = 0x7f0a0002;
public static final int abc_action_bar_stacked_max_height = 0x7f0a003c;
public static final int abc_action_bar_stacked_tab_max_width = 0x7f0a003d;
public static final int abc_action_bar_subtitle_bottom_margin_material = 0x7f0a003e;
public static final int abc_action_bar_subtitle_top_margin_material = 0x7f0a003f;
public static final int abc_action_button_min_height_material = 0x7f0a0040;
public static final int abc_action_button_min_width_material = 0x7f0a0041;
public static final int abc_action_button_min_width_overflow_material = 0x7f0a0042;
public static final int abc_alert_dialog_button_bar_height = 0x7f0a0000;
public static final int abc_button_inset_horizontal_material = 0x7f0a0043;
public static final int abc_button_inset_vertical_material = 0x7f0a0044;
public static final int abc_button_padding_horizontal_material = 0x7f0a0045;
public static final int abc_button_padding_vertical_material = 0x7f0a0046;
public static final int abc_cascading_menus_min_smallest_width = 0x7f0a0047;
public static final int abc_config_prefDialogWidth = 0x7f0a0005;
public static final int abc_control_corner_material = 0x7f0a0048;
public static final int abc_control_inset_material = 0x7f0a0049;
public static final int abc_control_padding_material = 0x7f0a004a;
public static final int abc_dialog_fixed_height_major = 0x7f0a0006;
public static final int abc_dialog_fixed_height_minor = 0x7f0a0007;
public static final int abc_dialog_fixed_width_major = 0x7f0a0008;
public static final int abc_dialog_fixed_width_minor = 0x7f0a0009;
public static final int abc_dialog_list_padding_vertical_material = 0x7f0a004b;
public static final int abc_dialog_min_width_major = 0x7f0a000a;
public static final int abc_dialog_min_width_minor = 0x7f0a000b;
public static final int abc_dialog_padding_material = 0x7f0a004c;
public static final int abc_dialog_padding_top_material = 0x7f0a004d;
public static final int abc_disabled_alpha_material_dark = 0x7f0a004e;
public static final int abc_disabled_alpha_material_light = 0x7f0a004f;
public static final int abc_dropdownitem_icon_width = 0x7f0a0050;
public static final int abc_dropdownitem_text_padding_left = 0x7f0a0051;
public static final int abc_dropdownitem_text_padding_right = 0x7f0a0052;
public static final int abc_edit_text_inset_bottom_material = 0x7f0a0053;
public static final int abc_edit_text_inset_horizontal_material = 0x7f0a0054;
public static final int abc_edit_text_inset_top_material = 0x7f0a0055;
public static final int abc_floating_window_z = 0x7f0a0056;
public static final int abc_list_item_padding_horizontal_material = 0x7f0a0057;
public static final int abc_panel_menu_list_width = 0x7f0a0058;
public static final int abc_progress_bar_height_material = 0x7f0a0059;
public static final int abc_search_view_preferred_height = 0x7f0a005a;
public static final int abc_search_view_preferred_width = 0x7f0a005b;
public static final int abc_seekbar_track_background_height_material = 0x7f0a005c;
public static final int abc_seekbar_track_progress_height_material = 0x7f0a005d;
public static final int abc_select_dialog_padding_start_material = 0x7f0a005e;
public static final int abc_switch_padding = 0x7f0a0038;
public static final int abc_text_size_body_1_material = 0x7f0a005f;
public static final int abc_text_size_body_2_material = 0x7f0a0060;
public static final int abc_text_size_button_material = 0x7f0a0061;
public static final int abc_text_size_caption_material = 0x7f0a0062;
public static final int abc_text_size_display_1_material = 0x7f0a0063;
public static final int abc_text_size_display_2_material = 0x7f0a0064;
public static final int abc_text_size_display_3_material = 0x7f0a0065;
public static final int abc_text_size_display_4_material = 0x7f0a0066;
public static final int abc_text_size_headline_material = 0x7f0a0067;
public static final int abc_text_size_large_material = 0x7f0a0068;
public static final int abc_text_size_medium_material = 0x7f0a0069;
public static final int abc_text_size_menu_header_material = 0x7f0a006a;
public static final int abc_text_size_menu_material = 0x7f0a006b;
public static final int abc_text_size_small_material = 0x7f0a006c;
public static final int abc_text_size_subhead_material = 0x7f0a006d;
public static final int abc_text_size_subtitle_material_toolbar = 0x7f0a0003;
public static final int abc_text_size_title_material = 0x7f0a006e;
public static final int abc_text_size_title_material_toolbar = 0x7f0a0004;
public static final int design_appbar_elevation = 0x7f0a0081;
public static final int design_bottom_sheet_modal_elevation = 0x7f0a0082;
public static final int design_bottom_sheet_modal_peek_height = 0x7f0a0083;
public static final int design_fab_border_width = 0x7f0a0084;
public static final int design_fab_elevation = 0x7f0a0085;
public static final int design_fab_image_size = 0x7f0a0086;
public static final int design_fab_size_mini = 0x7f0a0087;
public static final int design_fab_size_normal = 0x7f0a0088;
public static final int design_fab_translation_z_pressed = 0x7f0a0089;
public static final int design_navigation_elevation = 0x7f0a008a;
public static final int design_navigation_icon_padding = 0x7f0a008b;
public static final int design_navigation_icon_size = 0x7f0a008c;
public static final int design_navigation_max_width = 0x7f0a0030;
public static final int design_navigation_padding_bottom = 0x7f0a008d;
public static final int design_navigation_separator_vertical_padding = 0x7f0a008e;
public static final int design_snackbar_action_inline_max_width = 0x7f0a0031;
public static final int design_snackbar_background_corner_radius = 0x7f0a0032;
public static final int design_snackbar_elevation = 0x7f0a008f;
public static final int design_snackbar_extra_spacing_horizontal = 0x7f0a0033;
public static final int design_snackbar_max_width = 0x7f0a0034;
public static final int design_snackbar_min_width = 0x7f0a0035;
public static final int design_snackbar_padding_horizontal = 0x7f0a0090;
public static final int design_snackbar_padding_vertical = 0x7f0a0091;
public static final int design_snackbar_padding_vertical_2lines = 0x7f0a0036;
public static final int design_snackbar_text_size = 0x7f0a0092;
public static final int design_tab_max_width = 0x7f0a0093;
public static final int design_tab_scrollable_min_width = 0x7f0a0037;
public static final int design_tab_text_size = 0x7f0a0094;
public static final int design_tab_text_size_2line = 0x7f0a0095;
public static final int disabled_alpha_material_dark = 0x7f0a0096;
public static final int disabled_alpha_material_light = 0x7f0a0097;
public static final int highlight_alpha_material_colored = 0x7f0a0098;
public static final int highlight_alpha_material_dark = 0x7f0a0099;
public static final int highlight_alpha_material_light = 0x7f0a009a;
public static final int item_touch_helper_max_drag_scroll_per_frame = 0x7f0a009b;
public static final int item_touch_helper_swipe_escape_max_velocity = 0x7f0a009c;
public static final int item_touch_helper_swipe_escape_velocity = 0x7f0a009d;
public static final int notification_large_icon_height = 0x7f0a009e;
public static final int notification_large_icon_width = 0x7f0a009f;
public static final int notification_subtext_size = 0x7f0a00a0;
}
public static final class drawable {
public static final int abc_ab_share_pack_mtrl_alpha = 0x7f020000;
public static final int abc_action_bar_item_background_material = 0x7f020001;
public static final int abc_btn_borderless_material = 0x7f020002;
public static final int abc_btn_check_material = 0x7f020003;
public static final int abc_btn_check_to_on_mtrl_000 = 0x7f020004;
public static final int abc_btn_check_to_on_mtrl_015 = 0x7f020005;
public static final int abc_btn_colored_material = 0x7f020006;
public static final int abc_btn_default_mtrl_shape = 0x7f020007;
public static final int abc_btn_radio_material = 0x7f020008;
public static final int abc_btn_radio_to_on_mtrl_000 = 0x7f020009;
public static final int abc_btn_radio_to_on_mtrl_015 = 0x7f02000a;
public static final int abc_btn_switch_to_on_mtrl_00001 = 0x7f02000b;
public static final int abc_btn_switch_to_on_mtrl_00012 = 0x7f02000c;
public static final int abc_cab_background_internal_bg = 0x7f02000d;
public static final int abc_cab_background_top_material = 0x7f02000e;
public static final int abc_cab_background_top_mtrl_alpha = 0x7f02000f;
public static final int abc_control_background_material = 0x7f020010;
public static final int abc_dialog_material_background = 0x7f020011;
public static final int abc_edit_text_material = 0x7f020012;
public static final int abc_ic_ab_back_material = 0x7f020013;
public static final int abc_ic_arrow_drop_right_black_24dp = 0x7f020014;
public static final int abc_ic_clear_material = 0x7f020015;
public static final int abc_ic_commit_search_api_mtrl_alpha = 0x7f020016;
public static final int abc_ic_go_search_api_material = 0x7f020017;
public static final int abc_ic_menu_copy_mtrl_am_alpha = 0x7f020018;
public static final int abc_ic_menu_cut_mtrl_alpha = 0x7f020019;
public static final int abc_ic_menu_overflow_material = 0x7f02001a;
public static final int abc_ic_menu_paste_mtrl_am_alpha = 0x7f02001b;
public static final int abc_ic_menu_selectall_mtrl_alpha = 0x7f02001c;
public static final int abc_ic_menu_share_mtrl_alpha = 0x7f02001d;
public static final int abc_ic_search_api_material = 0x7f02001e;
public static final int abc_ic_star_black_16dp = 0x7f02001f;
public static final int abc_ic_star_black_36dp = 0x7f020020;
public static final int abc_ic_star_black_48dp = 0x7f020021;
public static final int abc_ic_star_half_black_16dp = 0x7f020022;
public static final int abc_ic_star_half_black_36dp = 0x7f020023;
public static final int abc_ic_star_half_black_48dp = 0x7f020024;
public static final int abc_ic_voice_search_api_material = 0x7f020025;
public static final int abc_item_background_holo_dark = 0x7f020026;
public static final int abc_item_background_holo_light = 0x7f020027;
public static final int abc_list_divider_mtrl_alpha = 0x7f020028;
public static final int abc_list_focused_holo = 0x7f020029;
public static final int abc_list_longpressed_holo = 0x7f02002a;
public static final int abc_list_pressed_holo_dark = 0x7f02002b;
public static final int abc_list_pressed_holo_light = 0x7f02002c;
public static final int abc_list_selector_background_transition_holo_dark = 0x7f02002d;
public static final int abc_list_selector_background_transition_holo_light = 0x7f02002e;
public static final int abc_list_selector_disabled_holo_dark = 0x7f02002f;
public static final int abc_list_selector_disabled_holo_light = 0x7f020030;
public static final int abc_list_selector_holo_dark = 0x7f020031;
public static final int abc_list_selector_holo_light = 0x7f020032;
public static final int abc_menu_hardkey_panel_mtrl_mult = 0x7f020033;
public static final int abc_popup_background_mtrl_mult = 0x7f020034;
public static final int abc_ratingbar_indicator_material = 0x7f020035;
public static final int abc_ratingbar_material = 0x7f020036;
public static final int abc_ratingbar_small_material = 0x7f020037;
public static final int abc_scrubber_control_off_mtrl_alpha = 0x7f020038;
public static final int abc_scrubber_control_to_pressed_mtrl_000 = 0x7f020039;
public static final int abc_scrubber_control_to_pressed_mtrl_005 = 0x7f02003a;
public static final int abc_scrubber_primary_mtrl_alpha = 0x7f02003b;
public static final int abc_scrubber_track_mtrl_alpha = 0x7f02003c;
public static final int abc_seekbar_thumb_material = 0x7f02003d;
public static final int abc_seekbar_tick_mark_material = 0x7f02003e;
public static final int abc_seekbar_track_material = 0x7f02003f;
public static final int abc_spinner_mtrl_am_alpha = 0x7f020040;
public static final int abc_spinner_textfield_background_material = 0x7f020041;
public static final int abc_switch_thumb_material = 0x7f020042;
public static final int abc_switch_track_mtrl_alpha = 0x7f020043;
public static final int abc_tab_indicator_material = 0x7f020044;
public static final int abc_tab_indicator_mtrl_alpha = 0x7f020045;
public static final int abc_text_cursor_material = 0x7f020046;
public static final int abc_textfield_activated_mtrl_alpha = 0x7f020047;
public static final int abc_textfield_default_mtrl_alpha = 0x7f020048;
public static final int abc_textfield_search_activated_mtrl_alpha = 0x7f020049;
public static final int abc_textfield_search_default_mtrl_alpha = 0x7f02004a;
public static final int abc_textfield_search_material = 0x7f02004b;
public static final int design_fab_background = 0x7f020093;
public static final int design_snackbar_background = 0x7f020094;
public static final int notification_template_icon_bg = 0x7f0200d1;
}
public static final class id {
public static final int action0 = 0x7f0f00ee;
public static final int action_bar = 0x7f0f007d;
public static final int action_bar_activity_content = 0x7f0f0000;
public static final int action_bar_container = 0x7f0f007c;
public static final int action_bar_root = 0x7f0f0078;
public static final int action_bar_spinner = 0x7f0f0001;
public static final int action_bar_subtitle = 0x7f0f005d;
public static final int action_bar_title = 0x7f0f005c;
public static final int action_context_bar = 0x7f0f007e;
public static final int action_divider = 0x7f0f00f2;
public static final int action_menu_divider = 0x7f0f0002;
public static final int action_menu_presenter = 0x7f0f0003;
public static final int action_mode_bar = 0x7f0f007a;
public static final int action_mode_bar_stub = 0x7f0f0079;
public static final int action_mode_close_button = 0x7f0f005e;
public static final int activity_chooser_view_content = 0x7f0f005f;
public static final int add = 0x7f0f001f;
public static final int alertTitle = 0x7f0f006b;
public static final int always = 0x7f0f004c;
public static final int auto = 0x7f0f0039;
public static final int beginning = 0x7f0f004a;
public static final int bottom = 0x7f0f0026;
public static final int buttonPanel = 0x7f0f0066;
public static final int cancel_action = 0x7f0f00ef;
public static final int center = 0x7f0f0027;
public static final int center_horizontal = 0x7f0f0028;
public static final int center_vertical = 0x7f0f0029;
public static final int checkbox = 0x7f0f0074;
public static final int chronometer = 0x7f0f00f5;
public static final int clip_horizontal = 0x7f0f0032;
public static final int clip_vertical = 0x7f0f0033;
public static final int collapseActionView = 0x7f0f004d;
public static final int contentPanel = 0x7f0f006c;
public static final int custom = 0x7f0f0072;
public static final int customPanel = 0x7f0f0071;
public static final int decor_content_parent = 0x7f0f007b;
public static final int default_activity_button = 0x7f0f0062;
public static final int design_bottom_sheet = 0x7f0f00ac;
public static final int design_menu_item_action_area = 0x7f0f00b3;
public static final int design_menu_item_action_area_stub = 0x7f0f00b2;
public static final int design_menu_item_text = 0x7f0f00b1;
public static final int design_navigation_view = 0x7f0f00b0;
public static final int disableHome = 0x7f0f0013;
public static final int edit_query = 0x7f0f007f;
public static final int end = 0x7f0f002a;
public static final int end_padder = 0x7f0f00f9;
public static final int enterAlways = 0x7f0f001a;
public static final int enterAlwaysCollapsed = 0x7f0f001b;
public static final int exitUntilCollapsed = 0x7f0f001c;
public static final int expand_activities_button = 0x7f0f0060;
public static final int expanded_menu = 0x7f0f0073;
public static final int fill = 0x7f0f0034;
public static final int fill_horizontal = 0x7f0f0035;
public static final int fill_vertical = 0x7f0f002b;
public static final int fixed = 0x7f0f0054;
public static final int home = 0x7f0f0006;
public static final int homeAsUp = 0x7f0f0014;
public static final int icon = 0x7f0f0064;
public static final int ifRoom = 0x7f0f004e;
public static final int image = 0x7f0f0061;
public static final int info = 0x7f0f00f8;
public static final int item_touch_helper_previous_elevation = 0x7f0f0007;
public static final int left = 0x7f0f002c;
public static final int line1 = 0x7f0f00f3;
public static final int line3 = 0x7f0f00f7;
public static final int listMode = 0x7f0f0010;
public static final int list_item = 0x7f0f0063;
public static final int media_actions = 0x7f0f00f1;
public static final int middle = 0x7f0f004b;
public static final int mini = 0x7f0f003a;
public static final int multiply = 0x7f0f0020;
public static final int navigation_header_container = 0x7f0f00af;
public static final int never = 0x7f0f004f;
public static final int none = 0x7f0f0015;
public static final int normal = 0x7f0f0011;
public static final int parallax = 0x7f0f0030;
public static final int parentPanel = 0x7f0f0068;
public static final int pin = 0x7f0f0031;
public static final int progress_circular = 0x7f0f0008;
public static final int progress_horizontal = 0x7f0f0009;
public static final int radio = 0x7f0f0076;
public static final int right = 0x7f0f002d;
public static final int screen = 0x7f0f0021;
public static final int scroll = 0x7f0f001d;
public static final int scrollIndicatorDown = 0x7f0f0070;
public static final int scrollIndicatorUp = 0x7f0f006d;
public static final int scrollView = 0x7f0f006e;
public static final int scrollable = 0x7f0f0055;
public static final int search_badge = 0x7f0f0081;
public static final int search_bar = 0x7f0f0080;
public static final int search_button = 0x7f0f0082;
public static final int search_close_btn = 0x7f0f0087;
public static final int search_edit_frame = 0x7f0f0083;
public static final int search_go_btn = 0x7f0f0089;
public static final int search_mag_icon = 0x7f0f0084;
public static final int search_plate = 0x7f0f0085;
public static final int search_src_text = 0x7f0f0086;
public static final int search_voice_btn = 0x7f0f008a;
public static final int select_dialog_listview = 0x7f0f008b;
public static final int shortcut = 0x7f0f0075;
public static final int showCustom = 0x7f0f0016;
public static final int showHome = 0x7f0f0017;
public static final int showTitle = 0x7f0f0018;
public static final int snackbar_action = 0x7f0f00ae;
public static final int snackbar_text = 0x7f0f00ad;
public static final int snap = 0x7f0f001e;
public static final int spacer = 0x7f0f0067;
public static final int split_action_bar = 0x7f0f000b;
public static final int src_atop = 0x7f0f0022;
public static final int src_in = 0x7f0f0023;
public static final int src_over = 0x7f0f0024;
public static final int start = 0x7f0f002e;
public static final int status_bar_latest_event_content = 0x7f0f00f0;
public static final int submenuarrow = 0x7f0f0077;
public static final int submit_area = 0x7f0f0088;
public static final int tabMode = 0x7f0f0012;
public static final int text = 0x7f0f00e0;
public static final int text2 = 0x7f0f00f6;
public static final int textSpacerNoButtons = 0x7f0f006f;
public static final int time = 0x7f0f00f4;
public static final int title = 0x7f0f0065;
public static final int title_template = 0x7f0f006a;
public static final int top = 0x7f0f002f;
public static final int topPanel = 0x7f0f0069;
public static final int touch_outside = 0x7f0f00ab;
public static final int up = 0x7f0f000e;
public static final int useLogo = 0x7f0f0019;
public static final int view_offset_helper = 0x7f0f000f;
public static final int withText = 0x7f0f0050;
public static final int wrap_content = 0x7f0f0025;
}
public static final class integer {
public static final int abc_config_activityDefaultDur = 0x7f0d0001;
public static final int abc_config_activityShortDur = 0x7f0d0002;
public static final int bottom_sheet_slide_duration = 0x7f0d0003;
public static final int cancel_button_image_alpha = 0x7f0d0004;
public static final int design_snackbar_text_max_lines = 0x7f0d0000;
public static final int status_bar_notification_info_maxnum = 0x7f0d000a;
}
public static final class layout {
public static final int abc_action_bar_title_item = 0x7f040000;
public static final int abc_action_bar_up_container = 0x7f040001;
public static final int abc_action_bar_view_list_nav_layout = 0x7f040002;
public static final int abc_action_menu_item_layout = 0x7f040003;
public static final int abc_action_menu_layout = 0x7f040004;
public static final int abc_action_mode_bar = 0x7f040005;
public static final int abc_action_mode_close_item_material = 0x7f040006;
public static final int abc_activity_chooser_view = 0x7f040007;
public static final int abc_activity_chooser_view_list_item = 0x7f040008;
public static final int abc_alert_dialog_button_bar_material = 0x7f040009;
public static final int abc_alert_dialog_material = 0x7f04000a;
public static final int abc_dialog_title_material = 0x7f04000b;
public static final int abc_expanded_menu_layout = 0x7f04000c;
public static final int abc_list_menu_item_checkbox = 0x7f04000d;
public static final int abc_list_menu_item_icon = 0x7f04000e;
public static final int abc_list_menu_item_layout = 0x7f04000f;
public static final int abc_list_menu_item_radio = 0x7f040010;
public static final int abc_popup_menu_header_item_layout = 0x7f040011;
public static final int abc_popup_menu_item_layout = 0x7f040012;
public static final int abc_screen_content_include = 0x7f040013;
public static final int abc_screen_simple = 0x7f040014;
public static final int abc_screen_simple_overlay_action_mode = 0x7f040015;
public static final int abc_screen_toolbar = 0x7f040016;
public static final int abc_search_dropdown_item_icons_2line = 0x7f040017;
public static final int abc_search_view = 0x7f040018;
public static final int abc_select_dialog_material = 0x7f040019;
public static final int design_bottom_sheet_dialog = 0x7f04002e;
public static final int design_layout_snackbar = 0x7f04002f;
public static final int design_layout_snackbar_include = 0x7f040030;
public static final int design_layout_tab_icon = 0x7f040031;
public static final int design_layout_tab_text = 0x7f040032;
public static final int design_menu_item_action_area = 0x7f040033;
public static final int design_navigation_item = 0x7f040034;
public static final int design_navigation_item_header = 0x7f040035;
public static final int design_navigation_item_separator = 0x7f040036;
public static final int design_navigation_item_subheader = 0x7f040037;
public static final int design_navigation_menu = 0x7f040038;
public static final int design_navigation_menu_item = 0x7f040039;
public static final int notification_media_action = 0x7f040052;
public static final int notification_media_cancel_action = 0x7f040053;
public static final int notification_template_big_media = 0x7f040054;
public static final int notification_template_big_media_narrow = 0x7f040055;
public static final int notification_template_lines = 0x7f040056;
public static final int notification_template_media = 0x7f040057;
public static final int notification_template_part_chronometer = 0x7f040058;
public static final int notification_template_part_time = 0x7f040059;
public static final int select_dialog_item_material = 0x7f04005e;
public static final int select_dialog_multichoice_material = 0x7f04005f;
public static final int select_dialog_singlechoice_material = 0x7f040060;
public static final int support_simple_spinner_dropdown_item = 0x7f040064;
}
public static final class string {
public static final int abc_action_bar_home_description = 0x7f080000;
public static final int abc_action_bar_home_description_format = 0x7f080001;
public static final int abc_action_bar_home_subtitle_description_format = 0x7f080002;
public static final int abc_action_bar_up_description = 0x7f080003;
public static final int abc_action_menu_overflow_description = 0x7f080004;
public static final int abc_action_mode_done = 0x7f080005;
public static final int abc_activity_chooser_view_see_all = 0x7f080006;
public static final int abc_activitychooserview_choose_application = 0x7f080007;
public static final int abc_capital_off = 0x7f080008;
public static final int abc_capital_on = 0x7f080009;
public static final int abc_font_family_body_1_material = 0x7f08002e;
public static final int abc_font_family_body_2_material = 0x7f08002f;
public static final int abc_font_family_button_material = 0x7f080030;
public static final int abc_font_family_caption_material = 0x7f080031;
public static final int abc_font_family_display_1_material = 0x7f080032;
public static final int abc_font_family_display_2_material = 0x7f080033;
public static final int abc_font_family_display_3_material = 0x7f080034;
public static final int abc_font_family_display_4_material = 0x7f080035;
public static final int abc_font_family_headline_material = 0x7f080036;
public static final int abc_font_family_menu_material = 0x7f080037;
public static final int abc_font_family_subhead_material = 0x7f080038;
public static final int abc_font_family_title_material = 0x7f080039;
public static final int abc_search_hint = 0x7f08000a;
public static final int abc_searchview_description_clear = 0x7f08000b;
public static final int abc_searchview_description_query = 0x7f08000c;
public static final int abc_searchview_description_search = 0x7f08000d;
public static final int abc_searchview_description_submit = 0x7f08000e;
public static final int abc_searchview_description_voice = 0x7f08000f;
public static final int abc_shareactionprovider_share_with = 0x7f080010;
public static final int abc_shareactionprovider_share_with_application = 0x7f080011;
public static final int abc_toolbar_collapse_description = 0x7f080012;
public static final int appbar_scrolling_view_behavior = 0x7f08003c;
public static final int bottom_sheet_behavior = 0x7f08003d;
public static final int character_counter_pattern = 0x7f08003e;
public static final int status_bar_notification_info_overflow = 0x7f080013;
}
public static final class style {
public static final int AlertDialog_AppCompat = 0x7f0b0092;
public static final int AlertDialog_AppCompat_Light = 0x7f0b0093;
public static final int Animation_AppCompat_Dialog = 0x7f0b0094;
public static final int Animation_AppCompat_DropDownUp = 0x7f0b0095;
public static final int Animation_Design_BottomSheetDialog = 0x7f0b0096;
public static final int Base_AlertDialog_AppCompat = 0x7f0b009b;
public static final int Base_AlertDialog_AppCompat_Light = 0x7f0b009c;
public static final int Base_Animation_AppCompat_Dialog = 0x7f0b009d;
public static final int Base_Animation_AppCompat_DropDownUp = 0x7f0b009e;
public static final int Base_DialogWindowTitleBackground_AppCompat = 0x7f0b00a0;
public static final int Base_DialogWindowTitle_AppCompat = 0x7f0b009f;
public static final int Base_TextAppearance_AppCompat = 0x7f0b003f;
public static final int Base_TextAppearance_AppCompat_Body1 = 0x7f0b0040;
public static final int Base_TextAppearance_AppCompat_Body2 = 0x7f0b0041;
public static final int Base_TextAppearance_AppCompat_Button = 0x7f0b0023;
public static final int Base_TextAppearance_AppCompat_Caption = 0x7f0b0042;
public static final int Base_TextAppearance_AppCompat_Display1 = 0x7f0b0043;
public static final int Base_TextAppearance_AppCompat_Display2 = 0x7f0b0044;
public static final int Base_TextAppearance_AppCompat_Display3 = 0x7f0b0045;
public static final int Base_TextAppearance_AppCompat_Display4 = 0x7f0b0046;
public static final int Base_TextAppearance_AppCompat_Headline = 0x7f0b0047;
public static final int Base_TextAppearance_AppCompat_Inverse = 0x7f0b000c;
public static final int Base_TextAppearance_AppCompat_Large = 0x7f0b0048;
public static final int Base_TextAppearance_AppCompat_Large_Inverse = 0x7f0b000d;
public static final int Base_TextAppearance_AppCompat_Light_Widget_PopupMenu_Large = 0x7f0b0049;
public static final int Base_TextAppearance_AppCompat_Light_Widget_PopupMenu_Small = 0x7f0b004a;
public static final int Base_TextAppearance_AppCompat_Medium = 0x7f0b004b;
public static final int Base_TextAppearance_AppCompat_Medium_Inverse = 0x7f0b000e;
public static final int Base_TextAppearance_AppCompat_Menu = 0x7f0b004c;
public static final int Base_TextAppearance_AppCompat_SearchResult = 0x7f0b00a1;
public static final int Base_TextAppearance_AppCompat_SearchResult_Subtitle = 0x7f0b004d;
public static final int Base_TextAppearance_AppCompat_SearchResult_Title = 0x7f0b004e;
public static final int Base_TextAppearance_AppCompat_Small = 0x7f0b004f;
public static final int Base_TextAppearance_AppCompat_Small_Inverse = 0x7f0b000f;
public static final int Base_TextAppearance_AppCompat_Subhead = 0x7f0b0050;
public static final int Base_TextAppearance_AppCompat_Subhead_Inverse = 0x7f0b0010;
public static final int Base_TextAppearance_AppCompat_Title = 0x7f0b0051;
public static final int Base_TextAppearance_AppCompat_Title_Inverse = 0x7f0b0011;
public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Menu = 0x7f0b008b;
public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Subtitle = 0x7f0b0052;
public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Subtitle_Inverse = 0x7f0b0053;
public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Title = 0x7f0b0054;
public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Title_Inverse = 0x7f0b0055;
public static final int Base_TextAppearance_AppCompat_Widget_ActionMode_Subtitle = 0x7f0b0056;
public static final int Base_TextAppearance_AppCompat_Widget_ActionMode_Title = 0x7f0b0057;
public static final int Base_TextAppearance_AppCompat_Widget_Button = 0x7f0b0058;
public static final int Base_TextAppearance_AppCompat_Widget_Button_Inverse = 0x7f0b008c;
public static final int Base_TextAppearance_AppCompat_Widget_DropDownItem = 0x7f0b00a2;
public static final int Base_TextAppearance_AppCompat_Widget_PopupMenu_Header = 0x7f0b0059;
public static final int Base_TextAppearance_AppCompat_Widget_PopupMenu_Large = 0x7f0b005a;
public static final int Base_TextAppearance_AppCompat_Widget_PopupMenu_Small = 0x7f0b005b;
public static final int Base_TextAppearance_AppCompat_Widget_Switch = 0x7f0b005c;
public static final int Base_TextAppearance_AppCompat_Widget_TextView_SpinnerItem = 0x7f0b005d;
public static final int Base_TextAppearance_Widget_AppCompat_ExpandedMenu_Item = 0x7f0b00a3;
public static final int Base_TextAppearance_Widget_AppCompat_Toolbar_Subtitle = 0x7f0b005e;
public static final int Base_TextAppearance_Widget_AppCompat_Toolbar_Title = 0x7f0b005f;
public static final int Base_ThemeOverlay_AppCompat = 0x7f0b00ac;
public static final int Base_ThemeOverlay_AppCompat_ActionBar = 0x7f0b00ad;
public static final int Base_ThemeOverlay_AppCompat_Dark = 0x7f0b00ae;
public static final int Base_ThemeOverlay_AppCompat_Dark_ActionBar = 0x7f0b00af;
public static final int Base_ThemeOverlay_AppCompat_Dialog = 0x7f0b0014;
public static final int Base_ThemeOverlay_AppCompat_Dialog_Alert = 0x7f0b00b0;
public static final int Base_ThemeOverlay_AppCompat_Light = 0x7f0b00b1;
public static final int Base_Theme_AppCompat = 0x7f0b0060;
public static final int Base_Theme_AppCompat_CompactMenu = 0x7f0b00a4;
public static final int Base_Theme_AppCompat_Dialog = 0x7f0b0012;
public static final int Base_Theme_AppCompat_DialogWhenLarge = 0x7f0b0002;
public static final int Base_Theme_AppCompat_Dialog_Alert = 0x7f0b00a5;
public static final int Base_Theme_AppCompat_Dialog_FixedSize = 0x7f0b00a6;
public static final int Base_Theme_AppCompat_Dialog_MinWidth = 0x7f0b00a7;
public static final int Base_Theme_AppCompat_Light = 0x7f0b0061;
public static final int Base_Theme_AppCompat_Light_DarkActionBar = 0x7f0b00a8;
public static final int Base_Theme_AppCompat_Light_Dialog = 0x7f0b0013;
public static final int Base_Theme_AppCompat_Light_DialogWhenLarge = 0x7f0b0003;
public static final int Base_Theme_AppCompat_Light_Dialog_Alert = 0x7f0b00a9;
public static final int Base_Theme_AppCompat_Light_Dialog_FixedSize = 0x7f0b00aa;
public static final int Base_Theme_AppCompat_Light_Dialog_MinWidth = 0x7f0b00ab;
public static final int Base_V11_ThemeOverlay_AppCompat_Dialog = 0x7f0b0017;
public static final int Base_V11_Theme_AppCompat_Dialog = 0x7f0b0015;
public static final int Base_V11_Theme_AppCompat_Light_Dialog = 0x7f0b0016;
public static final int Base_V12_Widget_AppCompat_AutoCompleteTextView = 0x7f0b001f;
public static final int Base_V12_Widget_AppCompat_EditText = 0x7f0b0020;
public static final int Base_V21_ThemeOverlay_AppCompat_Dialog = 0x7f0b0066;
public static final int Base_V21_Theme_AppCompat = 0x7f0b0062;
public static final int Base_V21_Theme_AppCompat_Dialog = 0x7f0b0063;
public static final int Base_V21_Theme_AppCompat_Light = 0x7f0b0064;
public static final int Base_V21_Theme_AppCompat_Light_Dialog = 0x7f0b0065;
public static final int Base_V22_Theme_AppCompat = 0x7f0b0089;
public static final int Base_V22_Theme_AppCompat_Light = 0x7f0b008a;
public static final int Base_V23_Theme_AppCompat = 0x7f0b008d;
public static final int Base_V23_Theme_AppCompat_Light = 0x7f0b008e;
public static final int Base_V7_ThemeOverlay_AppCompat_Dialog = 0x7f0b00b6;
public static final int Base_V7_Theme_AppCompat = 0x7f0b00b2;
public static final int Base_V7_Theme_AppCompat_Dialog = 0x7f0b00b3;
public static final int Base_V7_Theme_AppCompat_Light = 0x7f0b00b4;
public static final int Base_V7_Theme_AppCompat_Light_Dialog = 0x7f0b00b5;
public static final int Base_V7_Widget_AppCompat_AutoCompleteTextView = 0x7f0b00b7;
public static final int Base_V7_Widget_AppCompat_EditText = 0x7f0b00b8;
public static final int Base_Widget_AppCompat_ActionBar = 0x7f0b00b9;
public static final int Base_Widget_AppCompat_ActionBar_Solid = 0x7f0b00ba;
public static final int Base_Widget_AppCompat_ActionBar_TabBar = 0x7f0b00bb;
public static final int Base_Widget_AppCompat_ActionBar_TabText = 0x7f0b0067;
public static final int Base_Widget_AppCompat_ActionBar_TabView = 0x7f0b0068;
public static final int Base_Widget_AppCompat_ActionButton = 0x7f0b0069;
public static final int Base_Widget_AppCompat_ActionButton_CloseMode = 0x7f0b006a;
public static final int Base_Widget_AppCompat_ActionButton_Overflow = 0x7f0b006b;
public static final int Base_Widget_AppCompat_ActionMode = 0x7f0b00bc;
public static final int Base_Widget_AppCompat_ActivityChooserView = 0x7f0b00bd;
public static final int Base_Widget_AppCompat_AutoCompleteTextView = 0x7f0b0021;
public static final int Base_Widget_AppCompat_Button = 0x7f0b006c;
public static final int Base_Widget_AppCompat_ButtonBar = 0x7f0b0070;
public static final int Base_Widget_AppCompat_ButtonBar_AlertDialog = 0x7f0b00bf;
public static final int Base_Widget_AppCompat_Button_Borderless = 0x7f0b006d;
public static final int Base_Widget_AppCompat_Button_Borderless_Colored = 0x7f0b006e;
public static final int Base_Widget_AppCompat_Button_ButtonBar_AlertDialog = 0x7f0b00be;
public static final int Base_Widget_AppCompat_Button_Colored = 0x7f0b008f;
public static final int Base_Widget_AppCompat_Button_Small = 0x7f0b006f;
public static final int Base_Widget_AppCompat_CompoundButton_CheckBox = 0x7f0b0071;
public static final int Base_Widget_AppCompat_CompoundButton_RadioButton = 0x7f0b0072;
public static final int Base_Widget_AppCompat_CompoundButton_Switch = 0x7f0b00c0;
public static final int Base_Widget_AppCompat_DrawerArrowToggle = 0x7f0b0000;
public static final int Base_Widget_AppCompat_DrawerArrowToggle_Common = 0x7f0b00c1;
public static final int Base_Widget_AppCompat_DropDownItem_Spinner = 0x7f0b0073;
public static final int Base_Widget_AppCompat_EditText = 0x7f0b0022;
public static final int Base_Widget_AppCompat_ImageButton = 0x7f0b0074;
public static final int Base_Widget_AppCompat_Light_ActionBar = 0x7f0b00c2;
public static final int Base_Widget_AppCompat_Light_ActionBar_Solid = 0x7f0b00c3;
public static final int Base_Widget_AppCompat_Light_ActionBar_TabBar = 0x7f0b00c4;
public static final int Base_Widget_AppCompat_Light_ActionBar_TabText = 0x7f0b0075;
public static final int Base_Widget_AppCompat_Light_ActionBar_TabText_Inverse = 0x7f0b0076;
public static final int Base_Widget_AppCompat_Light_ActionBar_TabView = 0x7f0b0077;
public static final int Base_Widget_AppCompat_Light_PopupMenu = 0x7f0b0078;
public static final int Base_Widget_AppCompat_Light_PopupMenu_Overflow = 0x7f0b0079;
public static final int Base_Widget_AppCompat_ListMenuView = 0x7f0b00c5;
public static final int Base_Widget_AppCompat_ListPopupWindow = 0x7f0b007a;
public static final int Base_Widget_AppCompat_ListView = 0x7f0b007b;
public static final int Base_Widget_AppCompat_ListView_DropDown = 0x7f0b007c;
public static final int Base_Widget_AppCompat_ListView_Menu = 0x7f0b007d;
public static final int Base_Widget_AppCompat_PopupMenu = 0x7f0b007e;
public static final int Base_Widget_AppCompat_PopupMenu_Overflow = 0x7f0b007f;
public static final int Base_Widget_AppCompat_PopupWindow = 0x7f0b00c6;
public static final int Base_Widget_AppCompat_ProgressBar = 0x7f0b0018;
public static final int Base_Widget_AppCompat_ProgressBar_Horizontal = 0x7f0b0019;
public static final int Base_Widget_AppCompat_RatingBar = 0x7f0b0080;
public static final int Base_Widget_AppCompat_RatingBar_Indicator = 0x7f0b0090;
public static final int Base_Widget_AppCompat_RatingBar_Small = 0x7f0b0091;
public static final int Base_Widget_AppCompat_SearchView = 0x7f0b00c7;
public static final int Base_Widget_AppCompat_SearchView_ActionBar = 0x7f0b00c8;
public static final int Base_Widget_AppCompat_SeekBar = 0x7f0b0081;
public static final int Base_Widget_AppCompat_SeekBar_Discrete = 0x7f0b00c9;
public static final int Base_Widget_AppCompat_Spinner = 0x7f0b0082;
public static final int Base_Widget_AppCompat_Spinner_Underlined = 0x7f0b0004;
public static final int Base_Widget_AppCompat_TextView_SpinnerItem = 0x7f0b0083;
public static final int Base_Widget_AppCompat_Toolbar = 0x7f0b00ca;
public static final int Base_Widget_AppCompat_Toolbar_Button_Navigation = 0x7f0b0084;
public static final int Base_Widget_Design_AppBarLayout = 0x7f0b00cb;
public static final int Base_Widget_Design_TabLayout = 0x7f0b00cc;
public static final int Platform_AppCompat = 0x7f0b001a;
public static final int Platform_AppCompat_Light = 0x7f0b001b;
public static final int Platform_ThemeOverlay_AppCompat = 0x7f0b0085;
public static final int Platform_ThemeOverlay_AppCompat_Dark = 0x7f0b0086;
public static final int Platform_ThemeOverlay_AppCompat_Light = 0x7f0b0087;
public static final int Platform_V11_AppCompat = 0x7f0b001c;
public static final int Platform_V11_AppCompat_Light = 0x7f0b001d;
public static final int Platform_V14_AppCompat = 0x7f0b0024;
public static final int Platform_V14_AppCompat_Light = 0x7f0b0025;
public static final int Platform_Widget_AppCompat_Spinner = 0x7f0b001e;
public static final int RtlOverlay_DialogWindowTitle_AppCompat = 0x7f0b0031;
public static final int RtlOverlay_Widget_AppCompat_ActionBar_TitleItem = 0x7f0b0032;
public static final int RtlOverlay_Widget_AppCompat_DialogTitle_Icon = 0x7f0b0033;
public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem = 0x7f0b0034;
public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem_InternalGroup = 0x7f0b0035;
public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem_Text = 0x7f0b0036;
public static final int RtlOverlay_Widget_AppCompat_SearchView_MagIcon = 0x7f0b003c;
public static final int RtlOverlay_Widget_AppCompat_Search_DropDown = 0x7f0b0037;
public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Icon1 = 0x7f0b0038;
public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Icon2 = 0x7f0b0039;
public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Query = 0x7f0b003a;
public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Text = 0x7f0b003b;
public static final int RtlUnderlay_Widget_AppCompat_ActionButton = 0x7f0b003d;
public static final int RtlUnderlay_Widget_AppCompat_ActionButton_Overflow = 0x7f0b003e;
public static final int TextAppearance_AppCompat = 0x7f0b00d8;
public static final int TextAppearance_AppCompat_Body1 = 0x7f0b00d9;
public static final int TextAppearance_AppCompat_Body2 = 0x7f0b00da;
public static final int TextAppearance_AppCompat_Button = 0x7f0b00db;
public static final int TextAppearance_AppCompat_Caption = 0x7f0b00dc;
public static final int TextAppearance_AppCompat_Display1 = 0x7f0b00dd;
public static final int TextAppearance_AppCompat_Display2 = 0x7f0b00de;
public static final int TextAppearance_AppCompat_Display3 = 0x7f0b00df;
public static final int TextAppearance_AppCompat_Display4 = 0x7f0b00e0;
public static final int TextAppearance_AppCompat_Headline = 0x7f0b00e1;
public static final int TextAppearance_AppCompat_Inverse = 0x7f0b00e2;
public static final int TextAppearance_AppCompat_Large = 0x7f0b00e3;
public static final int TextAppearance_AppCompat_Large_Inverse = 0x7f0b00e4;
public static final int TextAppearance_AppCompat_Light_SearchResult_Subtitle = 0x7f0b00e5;
public static final int TextAppearance_AppCompat_Light_SearchResult_Title = 0x7f0b00e6;
public static final int TextAppearance_AppCompat_Light_Widget_PopupMenu_Large = 0x7f0b00e7;
public static final int TextAppearance_AppCompat_Light_Widget_PopupMenu_Small = 0x7f0b00e8;
public static final int TextAppearance_AppCompat_Medium = 0x7f0b00e9;
public static final int TextAppearance_AppCompat_Medium_Inverse = 0x7f0b00ea;
public static final int TextAppearance_AppCompat_Menu = 0x7f0b00eb;
public static final int TextAppearance_AppCompat_SearchResult_Subtitle = 0x7f0b00ec;
public static final int TextAppearance_AppCompat_SearchResult_Title = 0x7f0b00ed;
public static final int TextAppearance_AppCompat_Small = 0x7f0b00ee;
public static final int TextAppearance_AppCompat_Small_Inverse = 0x7f0b00ef;
public static final int TextAppearance_AppCompat_Subhead = 0x7f0b00f0;
public static final int TextAppearance_AppCompat_Subhead_Inverse = 0x7f0b00f1;
public static final int TextAppearance_AppCompat_Title = 0x7f0b00f2;
public static final int TextAppearance_AppCompat_Title_Inverse = 0x7f0b00f3;
public static final int TextAppearance_AppCompat_Widget_ActionBar_Menu = 0x7f0b00f4;
public static final int TextAppearance_AppCompat_Widget_ActionBar_Subtitle = 0x7f0b00f5;
public static final int TextAppearance_AppCompat_Widget_ActionBar_Subtitle_Inverse = 0x7f0b00f6;
public static final int TextAppearance_AppCompat_Widget_ActionBar_Title = 0x7f0b00f7;
public static final int TextAppearance_AppCompat_Widget_ActionBar_Title_Inverse = 0x7f0b00f8;
public static final int TextAppearance_AppCompat_Widget_ActionMode_Subtitle = 0x7f0b00f9;
public static final int TextAppearance_AppCompat_Widget_ActionMode_Subtitle_Inverse = 0x7f0b00fa;
public static final int TextAppearance_AppCompat_Widget_ActionMode_Title = 0x7f0b00fb;
public static final int TextAppearance_AppCompat_Widget_ActionMode_Title_Inverse = 0x7f0b00fc;
public static final int TextAppearance_AppCompat_Widget_Button = 0x7f0b00fd;
public static final int TextAppearance_AppCompat_Widget_Button_Inverse = 0x7f0b00fe;
public static final int TextAppearance_AppCompat_Widget_DropDownItem = 0x7f0b00ff;
public static final int TextAppearance_AppCompat_Widget_PopupMenu_Header = 0x7f0b0100;
public static final int TextAppearance_AppCompat_Widget_PopupMenu_Large = 0x7f0b0101;
public static final int TextAppearance_AppCompat_Widget_PopupMenu_Small = 0x7f0b0102;
public static final int TextAppearance_AppCompat_Widget_Switch = 0x7f0b0103;
public static final int TextAppearance_AppCompat_Widget_TextView_SpinnerItem = 0x7f0b0104;
public static final int TextAppearance_Design_CollapsingToolbar_Expanded = 0x7f0b0105;
public static final int TextAppearance_Design_Counter = 0x7f0b0106;
public static final int TextAppearance_Design_Counter_Overflow = 0x7f0b0107;
public static final int TextAppearance_Design_Error = 0x7f0b0108;
public static final int TextAppearance_Design_Hint = 0x7f0b0109;
public static final int TextAppearance_Design_Snackbar_Message = 0x7f0b010a;
public static final int TextAppearance_Design_Tab = 0x7f0b010b;
public static final int TextAppearance_StatusBar_EventContent = 0x7f0b0026;
public static final int TextAppearance_StatusBar_EventContent_Info = 0x7f0b0027;
public static final int TextAppearance_StatusBar_EventContent_Line2 = 0x7f0b0028;
public static final int TextAppearance_StatusBar_EventContent_Time = 0x7f0b0029;
public static final int TextAppearance_StatusBar_EventContent_Title = 0x7f0b002a;
public static final int TextAppearance_Widget_AppCompat_ExpandedMenu_Item = 0x7f0b010d;
public static final int TextAppearance_Widget_AppCompat_Toolbar_Subtitle = 0x7f0b010e;
public static final int TextAppearance_Widget_AppCompat_Toolbar_Title = 0x7f0b010f;
public static final int ThemeOverlay_AppCompat = 0x7f0b0125;
public static final int ThemeOverlay_AppCompat_ActionBar = 0x7f0b0126;
public static final int ThemeOverlay_AppCompat_Dark = 0x7f0b0127;
public static final int ThemeOverlay_AppCompat_Dark_ActionBar = 0x7f0b0128;
public static final int ThemeOverlay_AppCompat_Dialog = 0x7f0b0129;
public static final int ThemeOverlay_AppCompat_Dialog_Alert = 0x7f0b012a;
public static final int ThemeOverlay_AppCompat_Light = 0x7f0b012b;
public static final int Theme_AppCompat = 0x7f0b0110;
public static final int Theme_AppCompat_CompactMenu = 0x7f0b0111;
public static final int Theme_AppCompat_DayNight = 0x7f0b0005;
public static final int Theme_AppCompat_DayNight_DarkActionBar = 0x7f0b0006;
public static final int Theme_AppCompat_DayNight_Dialog = 0x7f0b0007;
public static final int Theme_AppCompat_DayNight_DialogWhenLarge = 0x7f0b000a;
public static final int Theme_AppCompat_DayNight_Dialog_Alert = 0x7f0b0008;
public static final int Theme_AppCompat_DayNight_Dialog_MinWidth = 0x7f0b0009;
public static final int Theme_AppCompat_DayNight_NoActionBar = 0x7f0b000b;
public static final int Theme_AppCompat_Dialog = 0x7f0b0112;
public static final int Theme_AppCompat_DialogWhenLarge = 0x7f0b0115;
public static final int Theme_AppCompat_Dialog_Alert = 0x7f0b0113;
public static final int Theme_AppCompat_Dialog_MinWidth = 0x7f0b0114;
public static final int Theme_AppCompat_Light = 0x7f0b0116;
public static final int Theme_AppCompat_Light_DarkActionBar = 0x7f0b0117;
public static final int Theme_AppCompat_Light_Dialog = 0x7f0b0118;
public static final int Theme_AppCompat_Light_DialogWhenLarge = 0x7f0b011b;
public static final int Theme_AppCompat_Light_Dialog_Alert = 0x7f0b0119;
public static final int Theme_AppCompat_Light_Dialog_MinWidth = 0x7f0b011a;
public static final int Theme_AppCompat_Light_NoActionBar = 0x7f0b011c;
public static final int Theme_AppCompat_NoActionBar = 0x7f0b011d;
public static final int Theme_Design = 0x7f0b011e;
public static final int Theme_Design_BottomSheetDialog = 0x7f0b011f;
public static final int Theme_Design_Light = 0x7f0b0120;
public static final int Theme_Design_Light_BottomSheetDialog = 0x7f0b0121;
public static final int Theme_Design_Light_NoActionBar = 0x7f0b0122;
public static final int Theme_Design_NoActionBar = 0x7f0b0123;
public static final int Widget_AppCompat_ActionBar = 0x7f0b0133;
public static final int Widget_AppCompat_ActionBar_Solid = 0x7f0b0134;
public static final int Widget_AppCompat_ActionBar_TabBar = 0x7f0b0135;
public static final int Widget_AppCompat_ActionBar_TabText = 0x7f0b0136;
public static final int Widget_AppCompat_ActionBar_TabView = 0x7f0b0137;
public static final int Widget_AppCompat_ActionButton = 0x7f0b0138;
public static final int Widget_AppCompat_ActionButton_CloseMode = 0x7f0b0139;
public static final int Widget_AppCompat_ActionButton_Overflow = 0x7f0b013a;
public static final int Widget_AppCompat_ActionMode = 0x7f0b013b;
public static final int Widget_AppCompat_ActivityChooserView = 0x7f0b013c;
public static final int Widget_AppCompat_AutoCompleteTextView = 0x7f0b013d;
public static final int Widget_AppCompat_Button = 0x7f0b013e;
public static final int Widget_AppCompat_ButtonBar = 0x7f0b0144;
public static final int Widget_AppCompat_ButtonBar_AlertDialog = 0x7f0b0145;
public static final int Widget_AppCompat_Button_Borderless = 0x7f0b013f;
public static final int Widget_AppCompat_Button_Borderless_Colored = 0x7f0b0140;
public static final int Widget_AppCompat_Button_ButtonBar_AlertDialog = 0x7f0b0141;
public static final int Widget_AppCompat_Button_Colored = 0x7f0b0142;
public static final int Widget_AppCompat_Button_Small = 0x7f0b0143;
public static final int Widget_AppCompat_CompoundButton_CheckBox = 0x7f0b0146;
public static final int Widget_AppCompat_CompoundButton_RadioButton = 0x7f0b0147;
public static final int Widget_AppCompat_CompoundButton_Switch = 0x7f0b0148;
public static final int Widget_AppCompat_DrawerArrowToggle = 0x7f0b0149;
public static final int Widget_AppCompat_DropDownItem_Spinner = 0x7f0b014a;
public static final int Widget_AppCompat_EditText = 0x7f0b014b;
public static final int Widget_AppCompat_ImageButton = 0x7f0b014c;
public static final int Widget_AppCompat_Light_ActionBar = 0x7f0b014d;
public static final int Widget_AppCompat_Light_ActionBar_Solid = 0x7f0b014e;
public static final int Widget_AppCompat_Light_ActionBar_Solid_Inverse = 0x7f0b014f;
public static final int Widget_AppCompat_Light_ActionBar_TabBar = 0x7f0b0150;
public static final int Widget_AppCompat_Light_ActionBar_TabBar_Inverse = 0x7f0b0151;
public static final int Widget_AppCompat_Light_ActionBar_TabText = 0x7f0b0152;
public static final int Widget_AppCompat_Light_ActionBar_TabText_Inverse = 0x7f0b0153;
public static final int Widget_AppCompat_Light_ActionBar_TabView = 0x7f0b0154;
public static final int Widget_AppCompat_Light_ActionBar_TabView_Inverse = 0x7f0b0155;
public static final int Widget_AppCompat_Light_ActionButton = 0x7f0b0156;
public static final int Widget_AppCompat_Light_ActionButton_CloseMode = 0x7f0b0157;
public static final int Widget_AppCompat_Light_ActionButton_Overflow = 0x7f0b0158;
public static final int Widget_AppCompat_Light_ActionMode_Inverse = 0x7f0b0159;
public static final int Widget_AppCompat_Light_ActivityChooserView = 0x7f0b015a;
public static final int Widget_AppCompat_Light_AutoCompleteTextView = 0x7f0b015b;
public static final int Widget_AppCompat_Light_DropDownItem_Spinner = 0x7f0b015c;
public static final int Widget_AppCompat_Light_ListPopupWindow = 0x7f0b015d;
public static final int Widget_AppCompat_Light_ListView_DropDown = 0x7f0b015e;
public static final int Widget_AppCompat_Light_PopupMenu = 0x7f0b015f;
public static final int Widget_AppCompat_Light_PopupMenu_Overflow = 0x7f0b0160;
public static final int Widget_AppCompat_Light_SearchView = 0x7f0b0161;
public static final int Widget_AppCompat_Light_Spinner_DropDown_ActionBar = 0x7f0b0162;
public static final int Widget_AppCompat_ListMenuView = 0x7f0b0163;
public static final int Widget_AppCompat_ListPopupWindow = 0x7f0b0164;
public static final int Widget_AppCompat_ListView = 0x7f0b0165;
public static final int Widget_AppCompat_ListView_DropDown = 0x7f0b0166;
public static final int Widget_AppCompat_ListView_Menu = 0x7f0b0167;
public static final int Widget_AppCompat_PopupMenu = 0x7f0b0168;
public static final int Widget_AppCompat_PopupMenu_Overflow = 0x7f0b0169;
public static final int Widget_AppCompat_PopupWindow = 0x7f0b016a;
public static final int Widget_AppCompat_ProgressBar = 0x7f0b016b;
public static final int Widget_AppCompat_ProgressBar_Horizontal = 0x7f0b016c;
public static final int Widget_AppCompat_RatingBar = 0x7f0b016d;
public static final int Widget_AppCompat_RatingBar_Indicator = 0x7f0b016e;
public static final int Widget_AppCompat_RatingBar_Small = 0x7f0b016f;
public static final int Widget_AppCompat_SearchView = 0x7f0b0170;
public static final int Widget_AppCompat_SearchView_ActionBar = 0x7f0b0171;
public static final int Widget_AppCompat_SeekBar = 0x7f0b0172;
public static final int Widget_AppCompat_SeekBar_Discrete = 0x7f0b0173;
public static final int Widget_AppCompat_Spinner = 0x7f0b0174;
public static final int Widget_AppCompat_Spinner_DropDown = 0x7f0b0175;
public static final int Widget_AppCompat_Spinner_DropDown_ActionBar = 0x7f0b0176;
public static final int Widget_AppCompat_Spinner_Underlined = 0x7f0b0177;
public static final int Widget_AppCompat_TextView_SpinnerItem = 0x7f0b0178;
public static final int Widget_AppCompat_Toolbar = 0x7f0b0179;
public static final int Widget_AppCompat_Toolbar_Button_Navigation = 0x7f0b017a;
public static final int Widget_Design_AppBarLayout = 0x7f0b0088;
public static final int Widget_Design_BottomSheet_Modal = 0x7f0b017b;
public static final int Widget_Design_CollapsingToolbar = 0x7f0b017c;
public static final int Widget_Design_CoordinatorLayout = 0x7f0b017d;
public static final int Widget_Design_FloatingActionButton = 0x7f0b017e;
public static final int Widget_Design_NavigationView = 0x7f0b017f;
public static final int Widget_Design_ScrimInsetsFrameLayout = 0x7f0b0180;
public static final int Widget_Design_Snackbar = 0x7f0b0181;
public static final int Widget_Design_TabLayout = 0x7f0b0001;
public static final int Widget_Design_TextInputLayout = 0x7f0b0182;
}
public static final class styleable {
public static final int[] ActionBar = { 0x7f010004, 0x7f010008, 0x7f010013, 0x7f010014, 0x7f010015, 0x7f010016, 0x7f010017, 0x7f010018, 0x7f010019, 0x7f01001a, 0x7f01001b, 0x7f01001c, 0x7f01001d, 0x7f01001e, 0x7f01001f, 0x7f010020, 0x7f010021, 0x7f010022, 0x7f010023, 0x7f010024, 0x7f010025, 0x7f010026, 0x7f010027, 0x7f010028, 0x7f010029, 0x7f01002a, 0x7f01002b, 0x7f01002c, 0x7f01006e };
public static final int[] ActionBarLayout = { 0x010100b3 };
public static final int ActionBarLayout_android_layout_gravity = 0;
public static final int ActionBar_background = 10;
public static final int ActionBar_backgroundSplit = 12;
public static final int ActionBar_backgroundStacked = 11;
public static final int ActionBar_contentInsetEnd = 21;
public static final int ActionBar_contentInsetEndWithActions = 25;
public static final int ActionBar_contentInsetLeft = 22;
public static final int ActionBar_contentInsetRight = 23;
public static final int ActionBar_contentInsetStart = 20;
public static final int ActionBar_contentInsetStartWithNavigation = 24;
public static final int ActionBar_customNavigationLayout = 13;
public static final int ActionBar_displayOptions = 3;
public static final int ActionBar_divider = 9;
public static final int ActionBar_elevation = 26;
public static final int ActionBar_height = 0;
public static final int ActionBar_hideOnContentScroll = 19;
public static final int ActionBar_homeAsUpIndicator = 28;
public static final int ActionBar_homeLayout = 14;
public static final int ActionBar_icon = 7;
public static final int ActionBar_indeterminateProgressStyle = 16;
public static final int ActionBar_itemPadding = 18;
public static final int ActionBar_logo = 8;
public static final int ActionBar_navigationMode = 2;
public static final int ActionBar_popupTheme = 27;
public static final int ActionBar_progressBarPadding = 17;
public static final int ActionBar_progressBarStyle = 15;
public static final int ActionBar_subtitle = 4;
public static final int ActionBar_subtitleTextStyle = 6;
public static final int ActionBar_title = 1;
public static final int ActionBar_titleTextStyle = 5;
public static final int[] ActionMenuItemView = { 0x0101013f };
public static final int ActionMenuItemView_android_minWidth = 0;
public static final int[] ActionMenuView = { };
public static final int[] ActionMode = { 0x7f010004, 0x7f010016, 0x7f010017, 0x7f01001b, 0x7f01001d, 0x7f01002d };
public static final int ActionMode_background = 3;
public static final int ActionMode_backgroundSplit = 4;
public static final int ActionMode_closeItemLayout = 5;
public static final int ActionMode_height = 0;
public static final int ActionMode_subtitleTextStyle = 2;
public static final int ActionMode_titleTextStyle = 1;
public static final int[] ActivityChooserView = { 0x7f01002e, 0x7f01002f };
public static final int ActivityChooserView_expandActivityOverflowButtonDrawable = 1;
public static final int ActivityChooserView_initialActivityCount = 0;
public static final int[] AlertDialog = { 0x010100f2, 0x7f010030, 0x7f010031, 0x7f010032, 0x7f010033, 0x7f010034 };
public static final int AlertDialog_android_layout = 0;
public static final int AlertDialog_buttonPanelSideLayout = 1;
public static final int AlertDialog_listItemLayout = 5;
public static final int AlertDialog_listLayout = 2;
public static final int AlertDialog_multiChoiceItemLayout = 3;
public static final int AlertDialog_singleChoiceItemLayout = 4;
public static final int[] AppBarLayout = { 0x010100d4, 0x7f01002b, 0x7f010035 };
public static final int[] AppBarLayoutStates = { 0x7f010036, 0x7f010037 };
public static final int AppBarLayoutStates_state_collapsed = 0;
public static final int AppBarLayoutStates_state_collapsible = 1;
public static final int[] AppBarLayout_Layout = { 0x7f010038, 0x7f010039 };
public static final int AppBarLayout_Layout_layout_scrollFlags = 0;
public static final int AppBarLayout_Layout_layout_scrollInterpolator = 1;
public static final int AppBarLayout_android_background = 0;
public static final int AppBarLayout_elevation = 1;
public static final int AppBarLayout_expanded = 2;
public static final int[] AppCompatImageView = { 0x01010119, 0x7f01003a };
public static final int AppCompatImageView_android_src = 0;
public static final int AppCompatImageView_srcCompat = 1;
public static final int[] AppCompatSeekBar = { 0x01010142, 0x7f01003b, 0x7f01003c, 0x7f01003d };
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 = { 0x01010034, 0x0101016d, 0x0101016e, 0x0101016f, 0x01010170, 0x01010392, 0x01010393 };
public static final int AppCompatTextHelper_android_drawableBottom = 2;
public static final int AppCompatTextHelper_android_drawableEnd = 6;
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_drawableTop = 1;
public static final int AppCompatTextHelper_android_textAppearance = 0;
public static final int[] AppCompatTextView = { 0x01010034, 0x7f01003e };
public static final int AppCompatTextView_android_textAppearance = 0;
public static final int AppCompatTextView_textAllCaps = 1;
public static final int[] AppCompatTheme = { 0x01010057, 0x010100ae, 0x7f01003f, 0x7f010040, 0x7f010041, 0x7f010042, 0x7f010043, 0x7f010044, 0x7f010045, 0x7f010046, 0x7f010047, 0x7f010048, 0x7f010049, 0x7f01004a, 0x7f01004b, 0x7f01004c, 0x7f01004d, 0x7f01004e, 0x7f01004f, 0x7f010050, 0x7f010051, 0x7f010052, 0x7f010053, 0x7f010054, 0x7f010055, 0x7f010056, 0x7f010057, 0x7f010058, 0x7f010059, 0x7f01005a, 0x7f01005b, 0x7f01005c, 0x7f01005d, 0x7f01005e, 0x7f01005f, 0x7f010060, 0x7f010061, 0x7f010062, 0x7f010063, 0x7f010064, 0x7f010065, 0x7f010066, 0x7f010067, 0x7f010068, 0x7f010069, 0x7f01006a, 0x7f01006b, 0x7f01006c, 0x7f01006d, 0x7f01006e, 0x7f01006f, 0x7f010070, 0x7f010071, 0x7f010072, 0x7f010073, 0x7f010074, 0x7f010075, 0x7f010076, 0x7f010077, 0x7f010078, 0x7f010079, 0x7f01007a, 0x7f01007b, 0x7f01007c, 0x7f01007d, 0x7f01007e, 0x7f01007f, 0x7f010080, 0x7f010081, 0x7f010082, 0x7f010083, 0x7f010084, 0x7f010085, 0x7f010086, 0x7f010087, 0x7f010088, 0x7f010089, 0x7f01008a, 0x7f01008b, 0x7f01008c, 0x7f01008d, 0x7f01008e, 0x7f01008f, 0x7f010090, 0x7f010091, 0x7f010092, 0x7f010093, 0x7f010094, 0x7f010095, 0x7f010096, 0x7f010097, 0x7f010098, 0x7f010099, 0x7f01009a, 0x7f01009b, 0x7f01009c, 0x7f01009d, 0x7f01009e, 0x7f01009f, 0x7f0100a0, 0x7f0100a1, 0x7f0100a2, 0x7f0100a3, 0x7f0100a4, 0x7f0100a5, 0x7f0100a6, 0x7f0100a7, 0x7f0100a8, 0x7f0100a9, 0x7f0100aa, 0x7f0100ab, 0x7f0100ac, 0x7f0100ad, 0x7f0100ae, 0x7f0100af };
public static final int AppCompatTheme_actionBarDivider = 23;
public static final int AppCompatTheme_actionBarItemBackground = 24;
public static final int AppCompatTheme_actionBarPopupTheme = 17;
public static final int AppCompatTheme_actionBarSize = 22;
public static final int AppCompatTheme_actionBarSplitStyle = 19;
public static final int AppCompatTheme_actionBarStyle = 18;
public static final int AppCompatTheme_actionBarTabBarStyle = 13;
public static final int AppCompatTheme_actionBarTabStyle = 12;
public static final int AppCompatTheme_actionBarTabTextStyle = 14;
public static final int AppCompatTheme_actionBarTheme = 20;
public static final int AppCompatTheme_actionBarWidgetTheme = 21;
public static final int AppCompatTheme_actionButtonStyle = 50;
public static final int AppCompatTheme_actionDropDownStyle = 46;
public static final int AppCompatTheme_actionMenuTextAppearance = 25;
public static final int AppCompatTheme_actionMenuTextColor = 26;
public static final int AppCompatTheme_actionModeBackground = 29;
public static final int AppCompatTheme_actionModeCloseButtonStyle = 28;
public static final int AppCompatTheme_actionModeCloseDrawable = 31;
public static final int AppCompatTheme_actionModeCopyDrawable = 33;
public static final int AppCompatTheme_actionModeCutDrawable = 32;
public static final int AppCompatTheme_actionModeFindDrawable = 37;
public static final int AppCompatTheme_actionModePasteDrawable = 34;
public static final int AppCompatTheme_actionModePopupWindowStyle = 39;
public static final int AppCompatTheme_actionModeSelectAllDrawable = 35;
public static final int AppCompatTheme_actionModeShareDrawable = 36;
public static final int AppCompatTheme_actionModeSplitBackground = 30;
public static final int AppCompatTheme_actionModeStyle = 27;
public static final int AppCompatTheme_actionModeWebSearchDrawable = 38;
public static final int AppCompatTheme_actionOverflowButtonStyle = 15;
public static final int AppCompatTheme_actionOverflowMenuStyle = 16;
public static final int AppCompatTheme_activityChooserViewStyle = 58;
public static final int AppCompatTheme_alertDialogButtonGroupStyle = 94;
public static final int AppCompatTheme_alertDialogCenterButtons = 95;
public static final int AppCompatTheme_alertDialogStyle = 93;
public static final int AppCompatTheme_alertDialogTheme = 96;
public static final int AppCompatTheme_android_windowAnimationStyle = 1;
public static final int AppCompatTheme_android_windowIsFloating = 0;
public static final int AppCompatTheme_autoCompleteTextViewStyle = 101;
public static final int AppCompatTheme_borderlessButtonStyle = 55;
public static final int AppCompatTheme_buttonBarButtonStyle = 52;
public static final int AppCompatTheme_buttonBarNegativeButtonStyle = 99;
public static final int AppCompatTheme_buttonBarNeutralButtonStyle = 100;
public static final int AppCompatTheme_buttonBarPositiveButtonStyle = 98;
public static final int AppCompatTheme_buttonBarStyle = 51;
public static final int AppCompatTheme_buttonStyle = 102;
public static final int AppCompatTheme_buttonStyleSmall = 103;
public static final int AppCompatTheme_checkboxStyle = 104;
public static final int AppCompatTheme_checkedTextViewStyle = 105;
public static final int AppCompatTheme_colorAccent = 85;
public static final int AppCompatTheme_colorBackgroundFloating = 92;
public static final int AppCompatTheme_colorButtonNormal = 89;
public static final int AppCompatTheme_colorControlActivated = 87;
public static final int AppCompatTheme_colorControlHighlight = 88;
public static final int AppCompatTheme_colorControlNormal = 86;
public static final int AppCompatTheme_colorPrimary = 83;
public static final int AppCompatTheme_colorPrimaryDark = 84;
public static final int AppCompatTheme_colorSwitchThumbNormal = 90;
public static final int AppCompatTheme_controlBackground = 91;
public static final int AppCompatTheme_dialogPreferredPadding = 44;
public static final int AppCompatTheme_dialogTheme = 43;
public static final int AppCompatTheme_dividerHorizontal = 57;
public static final int AppCompatTheme_dividerVertical = 56;
public static final int AppCompatTheme_dropDownListViewStyle = 75;
public static final int AppCompatTheme_dropdownListPreferredItemHeight = 47;
public static final int AppCompatTheme_editTextBackground = 64;
public static final int AppCompatTheme_editTextColor = 63;
public static final int AppCompatTheme_editTextStyle = 106;
public static final int AppCompatTheme_homeAsUpIndicator = 49;
public static final int AppCompatTheme_imageButtonStyle = 65;
public static final int AppCompatTheme_listChoiceBackgroundIndicator = 82;
public static final int AppCompatTheme_listDividerAlertDialog = 45;
public static final int AppCompatTheme_listMenuViewStyle = 114;
public static final int AppCompatTheme_listPopupWindowStyle = 76;
public static final int AppCompatTheme_listPreferredItemHeight = 70;
public static final int AppCompatTheme_listPreferredItemHeightLarge = 72;
public static final int AppCompatTheme_listPreferredItemHeightSmall = 71;
public static final int AppCompatTheme_listPreferredItemPaddingLeft = 73;
public static final int AppCompatTheme_listPreferredItemPaddingRight = 74;
public static final int AppCompatTheme_panelBackground = 79;
public static final int AppCompatTheme_panelMenuListTheme = 81;
public static final int AppCompatTheme_panelMenuListWidth = 80;
public static final int AppCompatTheme_popupMenuStyle = 61;
public static final int AppCompatTheme_popupWindowStyle = 62;
public static final int AppCompatTheme_radioButtonStyle = 107;
public static final int AppCompatTheme_ratingBarStyle = 108;
public static final int AppCompatTheme_ratingBarStyleIndicator = 109;
public static final int AppCompatTheme_ratingBarStyleSmall = 110;
public static final int AppCompatTheme_searchViewStyle = 69;
public static final int AppCompatTheme_seekBarStyle = 111;
public static final int AppCompatTheme_selectableItemBackground = 53;
public static final int AppCompatTheme_selectableItemBackgroundBorderless = 54;
public static final int AppCompatTheme_spinnerDropDownItemStyle = 48;
public static final int AppCompatTheme_spinnerStyle = 112;
public static final int AppCompatTheme_switchStyle = 113;
public static final int AppCompatTheme_textAppearanceLargePopupMenu = 40;
public static final int AppCompatTheme_textAppearanceListItem = 77;
public static final int AppCompatTheme_textAppearanceListItemSmall = 78;
public static final int AppCompatTheme_textAppearancePopupMenuHeader = 42;
public static final int AppCompatTheme_textAppearanceSearchResultSubtitle = 67;
public static final int AppCompatTheme_textAppearanceSearchResultTitle = 66;
public static final int AppCompatTheme_textAppearanceSmallPopupMenu = 41;
public static final int AppCompatTheme_textColorAlertDialogListItem = 97;
public static final int AppCompatTheme_textColorSearchUrl = 68;
public static final int AppCompatTheme_toolbarNavigationButtonStyle = 60;
public static final int AppCompatTheme_toolbarStyle = 59;
public static final int AppCompatTheme_windowActionBar = 2;
public static final int AppCompatTheme_windowActionBarOverlay = 4;
public static final int AppCompatTheme_windowActionModeOverlay = 5;
public static final int AppCompatTheme_windowFixedHeightMajor = 9;
public static final int AppCompatTheme_windowFixedHeightMinor = 7;
public static final int AppCompatTheme_windowFixedWidthMajor = 6;
public static final int AppCompatTheme_windowFixedWidthMinor = 8;
public static final int AppCompatTheme_windowMinWidthMajor = 10;
public static final int AppCompatTheme_windowMinWidthMinor = 11;
public static final int AppCompatTheme_windowNoTitle = 3;
public static final int[] BottomSheetBehavior_Layout = { 0x7f0100bc, 0x7f0100bd, 0x7f0100be };
public static final int BottomSheetBehavior_Layout_behavior_hideable = 1;
public static final int BottomSheetBehavior_Layout_behavior_peekHeight = 0;
public static final int BottomSheetBehavior_Layout_behavior_skipCollapsed = 2;
public static final int[] ButtonBarLayout = { 0x7f0100bf };
public static final int ButtonBarLayout_allowStacking = 0;
public static final int[] CollapsingToolbarLayout = { 0x7f010008, 0x7f0100c5, 0x7f0100c6, 0x7f0100c7, 0x7f0100c8, 0x7f0100c9, 0x7f0100ca, 0x7f0100cb, 0x7f0100cc, 0x7f0100cd, 0x7f0100ce, 0x7f0100cf, 0x7f0100d0, 0x7f0100d1, 0x7f0100d2, 0x7f0100d3 };
public static final int[] CollapsingToolbarLayout_Layout = { 0x7f0100d4, 0x7f0100d5 };
public static final int CollapsingToolbarLayout_Layout_layout_collapseMode = 0;
public static final int CollapsingToolbarLayout_Layout_layout_collapseParallaxMultiplier = 1;
public static final int CollapsingToolbarLayout_collapsedTitleGravity = 13;
public static final int CollapsingToolbarLayout_collapsedTitleTextAppearance = 7;
public static final int CollapsingToolbarLayout_contentScrim = 8;
public static final int CollapsingToolbarLayout_expandedTitleGravity = 14;
public static final int CollapsingToolbarLayout_expandedTitleMargin = 1;
public static final int CollapsingToolbarLayout_expandedTitleMarginBottom = 5;
public static final int CollapsingToolbarLayout_expandedTitleMarginEnd = 4;
public static final int CollapsingToolbarLayout_expandedTitleMarginStart = 2;
public static final int CollapsingToolbarLayout_expandedTitleMarginTop = 3;
public static final int CollapsingToolbarLayout_expandedTitleTextAppearance = 6;
public static final int CollapsingToolbarLayout_scrimAnimationDuration = 12;
public static final int CollapsingToolbarLayout_scrimVisibleHeightTrigger = 11;
public static final int CollapsingToolbarLayout_statusBarScrim = 9;
public static final int CollapsingToolbarLayout_title = 0;
public static final int CollapsingToolbarLayout_titleEnabled = 15;
public static final int CollapsingToolbarLayout_toolbarId = 10;
public static final int[] ColorStateListItem = { 0x010101a5, 0x0101031f, 0x7f0100d6 };
public static final int ColorStateListItem_alpha = 2;
public static final int ColorStateListItem_android_alpha = 1;
public static final int ColorStateListItem_android_color = 0;
public static final int[] CompoundButton = { 0x01010107, 0x7f0100d7, 0x7f0100d8 };
public static final int CompoundButton_android_button = 0;
public static final int CompoundButton_buttonTint = 1;
public static final int CompoundButton_buttonTintMode = 2;
public static final int[] CoordinatorLayout = { 0x7f0100d9, 0x7f0100da };
public static final int[] CoordinatorLayout_Layout = { 0x010100b3, 0x7f0100db, 0x7f0100dc, 0x7f0100dd, 0x7f0100de };
public static final int CoordinatorLayout_Layout_android_layout_gravity = 0;
public static final int CoordinatorLayout_Layout_layout_anchor = 2;
public static final int CoordinatorLayout_Layout_layout_anchorGravity = 4;
public static final int CoordinatorLayout_Layout_layout_behavior = 1;
public static final int CoordinatorLayout_Layout_layout_keyline = 3;
public static final int CoordinatorLayout_keylines = 0;
public static final int CoordinatorLayout_statusBarBackground = 1;
public static final int[] DesignTheme = { 0x7f0100e4, 0x7f0100e5, 0x7f0100e6 };
public static final int DesignTheme_bottomSheetDialogTheme = 0;
public static final int DesignTheme_bottomSheetStyle = 1;
public static final int DesignTheme_textColorError = 2;
public static final int[] DrawerArrowToggle = { 0x7f0100e7, 0x7f0100e8, 0x7f0100e9, 0x7f0100ea, 0x7f0100eb, 0x7f0100ec, 0x7f0100ed, 0x7f0100ee };
public static final int DrawerArrowToggle_arrowHeadLength = 4;
public static final int DrawerArrowToggle_arrowShaftLength = 5;
public static final int DrawerArrowToggle_barLength = 6;
public static final int DrawerArrowToggle_color = 0;
public static final int DrawerArrowToggle_drawableSize = 2;
public static final int DrawerArrowToggle_gapBetweenBars = 3;
public static final int DrawerArrowToggle_spinBars = 1;
public static final int DrawerArrowToggle_thickness = 7;
public static final int[] FloatingActionButton = { 0x7f01002b, 0x7f0100f6, 0x7f0100f7, 0x7f0100f8, 0x7f0100f9, 0x7f0100fa, 0x7f01018f, 0x7f010190 };
public static final int FloatingActionButton_backgroundTint = 6;
public static final int FloatingActionButton_backgroundTintMode = 7;
public static final int FloatingActionButton_borderWidth = 4;
public static final int FloatingActionButton_elevation = 0;
public static final int FloatingActionButton_fabSize = 2;
public static final int FloatingActionButton_pressedTranslationZ = 3;
public static final int FloatingActionButton_rippleColor = 1;
public static final int FloatingActionButton_useCompatPadding = 5;
public static final int[] ForegroundLinearLayout = { 0x01010109, 0x01010200, 0x7f0100fb };
public static final int ForegroundLinearLayout_android_foreground = 0;
public static final int ForegroundLinearLayout_android_foregroundGravity = 1;
public static final int ForegroundLinearLayout_foregroundInsidePadding = 2;
public static final int[] LinearLayoutCompat = { 0x010100af, 0x010100c4, 0x01010126, 0x01010127, 0x01010128, 0x7f01001a, 0x7f010104, 0x7f010105, 0x7f010106 };
public static final int[] LinearLayoutCompat_Layout = { 0x010100b3, 0x010100f4, 0x010100f5, 0x01010181 };
public static final int LinearLayoutCompat_Layout_android_layout_gravity = 0;
public static final int LinearLayoutCompat_Layout_android_layout_height = 2;
public static final int LinearLayoutCompat_Layout_android_layout_weight = 3;
public static final int LinearLayoutCompat_Layout_android_layout_width = 1;
public static final int LinearLayoutCompat_android_baselineAligned = 2;
public static final int LinearLayoutCompat_android_baselineAlignedChildIndex = 3;
public static final int LinearLayoutCompat_android_gravity = 0;
public static final int LinearLayoutCompat_android_orientation = 1;
public static final int LinearLayoutCompat_android_weightSum = 4;
public static final int LinearLayoutCompat_divider = 5;
public static final int LinearLayoutCompat_dividerPadding = 8;
public static final int LinearLayoutCompat_measureWithLargestChild = 6;
public static final int LinearLayoutCompat_showDividers = 7;
public static final int[] ListPopupWindow = { 0x010102ac, 0x010102ad };
public static final int ListPopupWindow_android_dropDownHorizontalOffset = 0;
public static final int ListPopupWindow_android_dropDownVerticalOffset = 1;
public static final int[] MenuGroup = { 0x0101000e, 0x010100d0, 0x01010194, 0x010101de, 0x010101df, 0x010101e0 };
public static final int MenuGroup_android_checkableBehavior = 5;
public static final int MenuGroup_android_enabled = 0;
public static final int MenuGroup_android_id = 1;
public static final int MenuGroup_android_menuCategory = 3;
public static final int MenuGroup_android_orderInCategory = 4;
public static final int MenuGroup_android_visible = 2;
public static final int[] MenuItem = { 0x01010002, 0x0101000e, 0x010100d0, 0x01010106, 0x01010194, 0x010101de, 0x010101df, 0x010101e1, 0x010101e2, 0x010101e3, 0x010101e4, 0x010101e5, 0x0101026f, 0x7f010107, 0x7f010108, 0x7f010109, 0x7f01010a };
public static final int MenuItem_actionLayout = 14;
public static final int MenuItem_actionProviderClass = 16;
public static final int MenuItem_actionViewClass = 15;
public static final int MenuItem_android_alphabeticShortcut = 9;
public static final int MenuItem_android_checkable = 11;
public static final int MenuItem_android_checked = 3;
public static final int MenuItem_android_enabled = 1;
public static final int MenuItem_android_icon = 0;
public static final int MenuItem_android_id = 2;
public static final int MenuItem_android_menuCategory = 5;
public static final int MenuItem_android_numericShortcut = 10;
public static final int MenuItem_android_onClick = 12;
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_visible = 4;
public static final int MenuItem_showAsAction = 13;
public static final int[] MenuView = { 0x010100ae, 0x0101012c, 0x0101012d, 0x0101012e, 0x0101012f, 0x01010130, 0x01010131, 0x7f01010b, 0x7f01010c };
public static final int MenuView_android_headerBackground = 4;
public static final int MenuView_android_horizontalDivider = 2;
public static final int MenuView_android_itemBackground = 5;
public static final int MenuView_android_itemIconDisabledAlpha = 6;
public static final int MenuView_android_itemTextAppearance = 1;
public static final int MenuView_android_verticalDivider = 3;
public static final int MenuView_android_windowAnimationStyle = 0;
public static final int MenuView_preserveIconSpacing = 7;
public static final int MenuView_subMenuArrow = 8;
public static final int[] NavigationView = { 0x010100d4, 0x010100dd, 0x0101011f, 0x7f01002b, 0x7f010112, 0x7f010113, 0x7f010114, 0x7f010115, 0x7f010116, 0x7f010117 };
public static final int NavigationView_android_background = 0;
public static final int NavigationView_android_fitsSystemWindows = 1;
public static final int NavigationView_android_maxWidth = 2;
public static final int NavigationView_elevation = 3;
public static final int NavigationView_headerLayout = 9;
public static final int NavigationView_itemBackground = 7;
public static final int NavigationView_itemIconTint = 5;
public static final int NavigationView_itemTextAppearance = 8;
public static final int NavigationView_itemTextColor = 6;
public static final int NavigationView_menu = 4;
public static final int[] PopupWindow = { 0x01010176, 0x010102c9, 0x7f010118 };
public static final int[] PopupWindowBackgroundState = { 0x7f010119 };
public static final int PopupWindowBackgroundState_state_above_anchor = 0;
public static final int PopupWindow_android_popupAnimationStyle = 1;
public static final int PopupWindow_android_popupBackground = 0;
public static final int PopupWindow_overlapAnchor = 2;
public static final int[] RecyclerView = { 0x010100c4, 0x010100f1, 0x7f01011a, 0x7f01011b, 0x7f01011c, 0x7f01011d };
public static final int RecyclerView_android_descendantFocusability = 1;
public static final int RecyclerView_android_orientation = 0;
public static final int RecyclerView_layoutManager = 2;
public static final int RecyclerView_reverseLayout = 4;
public static final int RecyclerView_spanCount = 3;
public static final int RecyclerView_stackFromEnd = 5;
public static final int[] ScrimInsetsFrameLayout = { 0x7f01011e };
public static final int ScrimInsetsFrameLayout_insetForeground = 0;
public static final int[] ScrollingViewBehavior_Layout = { 0x7f01011f };
public static final int ScrollingViewBehavior_Layout_behavior_overlapTop = 0;
public static final int[] SearchView = { 0x010100da, 0x0101011f, 0x01010220, 0x01010264, 0x7f010120, 0x7f010121, 0x7f010122, 0x7f010123, 0x7f010124, 0x7f010125, 0x7f010126, 0x7f010127, 0x7f010128, 0x7f010129, 0x7f01012a, 0x7f01012b, 0x7f01012c };
public static final int SearchView_android_focusable = 0;
public static final int SearchView_android_imeOptions = 3;
public static final int SearchView_android_inputType = 2;
public static final int SearchView_android_maxWidth = 1;
public static final int SearchView_closeIcon = 8;
public static final int SearchView_commitIcon = 13;
public static final int SearchView_defaultQueryHint = 7;
public static final int SearchView_goIcon = 9;
public static final int SearchView_iconifiedByDefault = 5;
public static final int SearchView_layout = 4;
public static final int SearchView_queryBackground = 15;
public static final int SearchView_queryHint = 6;
public static final int SearchView_searchHintIcon = 11;
public static final int SearchView_searchIcon = 10;
public static final int SearchView_submitBackground = 16;
public static final int SearchView_suggestionRowLayout = 14;
public static final int SearchView_voiceIcon = 12;
public static final int[] SnackbarLayout = { 0x0101011f, 0x7f01002b, 0x7f01013b };
public static final int SnackbarLayout_android_maxWidth = 0;
public static final int SnackbarLayout_elevation = 1;
public static final int SnackbarLayout_maxActionInlineWidth = 2;
public static final int[] Spinner = { 0x010100b2, 0x01010176, 0x0101017b, 0x01010262, 0x7f01002c };
public static final int Spinner_android_dropDownWidth = 3;
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_popupTheme = 4;
public static final int[] SwitchCompat = { 0x01010124, 0x01010125, 0x01010142, 0x7f010149, 0x7f01014a, 0x7f01014b, 0x7f01014c, 0x7f01014d, 0x7f01014e, 0x7f01014f, 0x7f010150, 0x7f010151, 0x7f010152, 0x7f010153 };
public static final int SwitchCompat_android_textOff = 1;
public static final int SwitchCompat_android_textOn = 0;
public static final int SwitchCompat_android_thumb = 2;
public static final int SwitchCompat_showText = 13;
public static final int SwitchCompat_splitTrack = 12;
public static final int SwitchCompat_switchMinWidth = 10;
public static final int SwitchCompat_switchPadding = 11;
public static final int SwitchCompat_switchTextAppearance = 9;
public static final int SwitchCompat_thumbTextPadding = 8;
public static final int SwitchCompat_thumbTint = 3;
public static final int SwitchCompat_thumbTintMode = 4;
public static final int SwitchCompat_track = 5;
public static final int SwitchCompat_trackTint = 6;
public static final int SwitchCompat_trackTintMode = 7;
public static final int[] TabItem = { 0x01010002, 0x010100f2, 0x0101014f };
public static final int TabItem_android_icon = 0;
public static final int TabItem_android_layout = 1;
public static final int TabItem_android_text = 2;
public static final int[] TabLayout = { 0x7f010154, 0x7f010155, 0x7f010156, 0x7f010157, 0x7f010158, 0x7f010159, 0x7f01015a, 0x7f01015b, 0x7f01015c, 0x7f01015d, 0x7f01015e, 0x7f01015f, 0x7f010160, 0x7f010161, 0x7f010162, 0x7f010163 };
public static final int TabLayout_tabBackground = 3;
public static final int TabLayout_tabContentStart = 2;
public static final int TabLayout_tabGravity = 5;
public static final int TabLayout_tabIndicatorColor = 0;
public static final int TabLayout_tabIndicatorHeight = 1;
public static final int TabLayout_tabMaxWidth = 7;
public static final int TabLayout_tabMinWidth = 6;
public static final int TabLayout_tabMode = 4;
public static final int TabLayout_tabPadding = 15;
public static final int TabLayout_tabPaddingBottom = 14;
public static final int TabLayout_tabPaddingEnd = 13;
public static final int TabLayout_tabPaddingStart = 11;
public static final int TabLayout_tabPaddingTop = 12;
public static final int TabLayout_tabSelectedTextColor = 10;
public static final int TabLayout_tabTextAppearance = 8;
public static final int TabLayout_tabTextColor = 9;
public static final int[] TextAppearance = { 0x01010095, 0x01010096, 0x01010097, 0x01010098, 0x01010161, 0x01010162, 0x01010163, 0x01010164, 0x7f01003e };
public static final int TextAppearance_android_shadowColor = 4;
public static final int TextAppearance_android_shadowDx = 5;
public static final int TextAppearance_android_shadowDy = 6;
public static final int TextAppearance_android_shadowRadius = 7;
public static final int TextAppearance_android_textColor = 3;
public static final int TextAppearance_android_textSize = 0;
public static final int TextAppearance_android_textStyle = 2;
public static final int TextAppearance_android_typeface = 1;
public static final int TextAppearance_textAllCaps = 8;
public static final int[] TextInputLayout = { 0x0101009a, 0x01010150, 0x7f010164, 0x7f010165, 0x7f010166, 0x7f010167, 0x7f010168, 0x7f010169, 0x7f01016a, 0x7f01016b, 0x7f01016c };
public static final int TextInputLayout_android_hint = 1;
public static final int TextInputLayout_android_textColorHint = 0;
public static final int TextInputLayout_counterEnabled = 6;
public static final int TextInputLayout_counterMaxLength = 7;
public static final int TextInputLayout_counterOverflowTextAppearance = 9;
public static final int TextInputLayout_counterTextAppearance = 8;
public static final int TextInputLayout_errorEnabled = 4;
public static final int TextInputLayout_errorTextAppearance = 5;
public static final int TextInputLayout_hintAnimationEnabled = 10;
public static final int TextInputLayout_hintEnabled = 3;
public static final int TextInputLayout_hintTextAppearance = 2;
public static final int[] Toolbar = { 0x010100af, 0x01010140, 0x7f010008, 0x7f010015, 0x7f010019, 0x7f010025, 0x7f010026, 0x7f010027, 0x7f010028, 0x7f010029, 0x7f01002a, 0x7f01002c, 0x7f010178, 0x7f010179, 0x7f01017a, 0x7f01017b, 0x7f01017c, 0x7f01017d, 0x7f01017e, 0x7f01017f, 0x7f010180, 0x7f010181, 0x7f010182, 0x7f010183, 0x7f010184, 0x7f010185, 0x7f010186, 0x7f010187, 0x7f010188 };
public static final int Toolbar_android_gravity = 0;
public static final int Toolbar_android_minHeight = 1;
public static final int Toolbar_buttonGravity = 21;
public static final int Toolbar_collapseContentDescription = 23;
public static final int Toolbar_collapseIcon = 22;
public static final int Toolbar_contentInsetEnd = 6;
public static final int Toolbar_contentInsetEndWithActions = 10;
public static final int Toolbar_contentInsetLeft = 7;
public static final int Toolbar_contentInsetRight = 8;
public static final int Toolbar_contentInsetStart = 5;
public static final int Toolbar_contentInsetStartWithNavigation = 9;
public static final int Toolbar_logo = 4;
public static final int Toolbar_logoDescription = 26;
public static final int Toolbar_maxButtonHeight = 20;
public static final int Toolbar_navigationContentDescription = 25;
public static final int Toolbar_navigationIcon = 24;
public static final int Toolbar_popupTheme = 11;
public static final int Toolbar_subtitle = 3;
public static final int Toolbar_subtitleTextAppearance = 13;
public static final int Toolbar_subtitleTextColor = 28;
public static final int Toolbar_title = 2;
public static final int Toolbar_titleMargin = 14;
public static final int Toolbar_titleMarginBottom = 18;
public static final int Toolbar_titleMarginEnd = 16;
public static final int Toolbar_titleMarginStart = 15;
public static final int Toolbar_titleMarginTop = 17;
public static final int Toolbar_titleMargins = 19;
public static final int Toolbar_titleTextAppearance = 12;
public static final int Toolbar_titleTextColor = 27;
public static final int[] View = { 0x01010000, 0x010100da, 0x7f01018c, 0x7f01018d, 0x7f01018e };
public static final int[] ViewBackgroundHelper = { 0x010100d4, 0x7f01018f, 0x7f010190 };
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 = { 0x010100d0, 0x010100f2, 0x010100f3 };
public static final int ViewStubCompat_android_id = 0;
public static final int ViewStubCompat_android_inflatedId = 2;
public static final int ViewStubCompat_android_layout = 1;
public static final int View_android_focusable = 1;
public static final int View_android_theme = 0;
public static final int View_paddingEnd = 3;
public static final int View_paddingStart = 2;
public static final int View_theme = 4;
}
}
| [
"1163096519@qq.com"
] | 1163096519@qq.com |
3d0cb7c6ea9f9b429f69d5baa980bb5875a4a1b7 | b78dd0b60a978c9eedde7b10bf89778a423cc811 | /src/main/java/com/github/dusv03/adventura_dragon_knight/logika/ActionHelp.java | 1a19ef19af65baaa211f710f906f497266fb566c | [] | no_license | dusv03/adventura-dragon-knight | 67b866a2e60fb8a4a880738b4f1de3644402af13 | 0d2c8748d17c4daea7efe985a0a95a339a829aed | refs/heads/master | 2021-04-18T19:16:30.445399 | 2018-04-09T20:47:13 | 2018-04-09T20:47:13 | 126,700,046 | 0 | 0 | null | null | null | null | UTF-8 | Java | false | false | 1,690 | java | /* The file is saved in UTF-8 codepage.
* Check: «Stereotype», Section mark-§, Copyright-©, Alpha-α, Beta-β, Smile-☺
*/
package com.github.dusv03.adventura_dragon_knight.logika;
import java.util.Collection;
import java.util.stream.Collectors;
import com.github.dusv03.adventura_dragon_knight.logika.Hra;
import com.github.dusv03.adventura_dragon_knight.logika.IPrikaz;
import static com.github.dusv03.adventura_dragon_knight.logika.Texts.*;
/*******************************************************************************
*
* @author dusv03
*
*/
public class ActionHelp
extends APrikaz
{
private final Hra hra;
private static final String NAZEV = pPOMOC;
/***************************************************************************
* Creates the action instance for ...
*/
public ActionHelp(Hra hra)
{
super (pPOMOC,
"Vypíše základní nápovědu a seznam dostupných příkazů.");
this.hra = hra;
}
@Override
public String proved(String... arguments)
{
Collection<IPrikaz> commands = hra.vratSeznam().vratPrikazy();
String result = commands.stream()
.map(cmd -> cmd.getNazev() + "\n" + cmd.getPopis())
.collect(Collectors.joining
("\n\n", zNÁPOVĚDA,"\n"));
return result;
}
//\IP== INSTANCE PRIVATE AND AUXILIARY METHODS =================================
//##############################################################################
//\NT== NESTED DATA TYPES ======================================================
}
| [
"vladi@DESKTOP-7FM7DJJ"
] | vladi@DESKTOP-7FM7DJJ |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.