code stringlengths 3 1.18M | language stringclasses 1
value |
|---|---|
package com.netnewera.l1.ls;
import com.thoughtworks.xstream.annotations.XStreamAlias;
@XStreamAlias("ANS")
public class LsCtxt {
}
| Java |
package com.netnewera.l1.ls;
import com.thoughtworks.xstream.annotations.XStreamAlias;
import com.thoughtworks.xstream.annotations.XStreamAsAttribute;
@XStreamAlias("lrdr")
public class Lrdr {
@XStreamAsAttribute()
@XStreamAlias("ver")
private String ver="1.0.0";
@XStreamAlias("original_id")
private S... | Java |
package com.netnewera.l1.ls;
public class LsSvcResult {
}
| Java |
package com.netnewera.l1.ls;
import com.thoughtworks.xstream.annotations.XStreamAlias;
import com.thoughtworks.xstream.annotations.XStreamAsAttribute;
@XStreamAlias("ls_hdr")
public class LsHdr {
@XStreamAsAttribute()
@XStreamAlias("ver")
private String ver="1.0.0";
@XStreamAlias("id")
private Stri... | Java |
/**
*
*/
package cn.gz.zoomtech.common;
import java.io.FileReader;
import java.io.LineNumberReader;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
/**
*
* @author Administrator
*
*/
public class LogTool {
private static final Log log = LogFactor... | Java |
package cn.gz.zoomtech.common;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.Date;
/**
* @author chenhui
*/
public class DateUtil{
public DateUtil(){}
/**
*
* package_name: cn.gz.zoomtech.common
* file_name: DateUtil... | Java |
package cn.gz.zoomtech.common;
import java.io.File;
import java.security.MessageDigest;
import java.text.DecimalFormat;
import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.Date;
//import org.apache.log4j.Logger;
public class Tools {
// private static final Logger log = Log... | Java |
/**
*
*/
package cn.gz.zoomtech.common.db;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.logicalcobwebs.proxool.configuration.JAXPCo... | Java |
package cn.gz.zoomtech.common.db;
import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.util.ArrayList;
import java.util.List;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import cn.gz.lbs.entity.CmsUser;
impo... | Java |
package cn.gz.zoomtech.common.db;
public class CellInfo {
// create table t_cell_gsm_gx / t_cell_wcdma_gx
// (
// city VARCHAR2(20),--城市
// cell_name VARCHAR2(90),--基站名称
// cell_lac VARCHAR2(20) not null,--小区LAC
// cell_ci VARCHAR2(20) not null,--小区CI
// cellx ... | Java |
package cn.gz.zoomtech.common;
import java.io.BufferedInputStream;
import java.io.BufferedWriter;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.OutputStreamWriter;
import java.net.HttpURLCon... | Java |
package cn.gz.zoomtech.common;
public class ByteUtil {
/**
* 固定长度字符串,不足长度则右补二进制0,此类型字符串定义的最大长度不包括结束符’\0’的长度
* @param str
* @param len
* @return
*/
public static byte[] getBytes(String str,int len){
byte[] bytes = null;
if(str!=null){
int strLen = str.length();
if(strLen<len){... | Java |
package cn.gz.zoomtech.common;
import java.security.MessageDigest;
import java.security.NoSuchAlgorithmException;
import java.text.SimpleDateFormat;
import java.util.Date;
import org.apache.log4j.Logger;
public class MessageUtil {
private static final Logger log = Logger.getLogger(MessageUtil.class);
... | Java |
package cn.gz.zoomtech.common;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
public class ToolBean {
private static final Log log = LogFactory.getLog(ToolBean.class);
/**
*
* 功能描述: 过滤掉字符串中左边的0字符,返回表示数量的字符串
*
* @param str
* @return
* @author chenh... | Java |
package cn.gz.zoomtech.common;
public class MessageParameter {
public static String SYSTEM_ID = "test001"; // 业务应用标识
public static String PASSWORD = "test"; // 业务应用登录密码
public static String SYSTEM_TYPE = "ATI";// 业务应用类型,此处取值ATI
public static int INTERFACE_VERSION = 0x10;// 接口版本,目前为0x10
// stat... | Java |
package cn.gz.zoomtech.common;
/**
* 通信格式转换
* Java和一些windows编程语言如c、c++、delphi所写的网络程序进行通讯时,需要进行相应的转换
* 高、低字节之间的转换
* windows的字节序为低字节开头
* linux,unix的字节序为高字节开头
* java则无论平台变化,都是高字节开头
* @author Administrator
*
*/
public class FormatTransfer {
/**
*
* package_name: cn.gz... | Java |
package cn.gz.zoomtech.common;
import org.apache.commons.configuration.CompositeConfiguration;
import org.apache.commons.configuration.PropertiesConfiguration;
import org.apache.commons.configuration.reloading.FileChangedReloadingStrategy;
import org.apache.commons.lang.builder.ToStringBuilder;
import org.apache... | Java |
package cn.gz.lbs.service;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import cn.gz.zoomtech.common.db.DbHandle;
public class SPDayCountBlankService {
private static final Log log = LogFactory.getLog(SPDayCountBlankService.class);
private static boolean isRunning... | Java |
package cn.gz.lbs.jobs;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.http.client.HttpClient;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.entity.Strin... | Java |
package cn.gz.lbs.jobs;
import java.util.Date;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.quartz.JobExecutionContext;
import org.quartz.JobExecutionException;
import org.quartz.StatefulJob;
import cn.gz.lbs.service.SPDayCountBlankService;
import cn.gz.z... | Java |
package cn.gz.lbs.jobs;
import java.util.Collection;
import java.util.Iterator;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.quartz.JobExecutionContext;
import org.quartz.JobExecutionException;
import org.quartz.Scheduler;
import org.quartz.StatefulJob;
... | Java |
package cn.gz.lbs.servlet;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.Enumeration;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServlet... | Java |
package cn.gz.lbs.servlet;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.Enumeration;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServlet... | Java |
package cn.gz.lbs.main;
import org.apache.commons.configuration.CompositeConfiguration;
import org.apache.log4j.Logger;
import cn.gz.zoomtech.common.ConfManager;
import com.netnewera.l1.ans.Ans;
import com.netnewera.l1.ans.Lia;
import net.sf.ehcache.Cache;
import net.sf.ehcache.CacheManager;
import net.... | Java |
package cn.gz.lbs.main;
import java.util.ArrayList;
import java.util.List;
import javax.servlet.ServletContextEvent;
import javax.servlet.ServletContextListener;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.quartz.Scheduler;
import org.quartz.SchedulerE... | Java |
package cn.gz.lbs.main;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import java.util.Properties;
import org.apache.commons.configuration.CompositeConfiguration;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.quartz.JobDetail;
im... | Java |
package cn.gz.lbs.glsc;
import java.util.ArrayList;
import java.util.List;
import org.apache.commons.configuration.CompositeConfiguration;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import com.netnewera.l1.ans.Ans;
import com.netnewera.l1.ans.Lia;
import com.netne... | Java |
package cn.gz.lbs.glsc;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.Enumeration;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletRes... | Java |
package cn.gz.lbs.glsc;
import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.List;
import org.apache.commons.configuration.CompositeConfiguration;
import org.apache.http.HttpEntity;
import org.apache.http.HttpResponse;
import org.apache.http.client.HttpClient;
import org.apache.htt... | Java |
package cn.gz.lbs.entity;
import java.util.Date;
/**
* CmsUser entity
*
*/
public class CmsUser implements java.io.Serializable {
//Table Fields
// ID NUMBER not null,
// LOGIN_NAME VARCHAR2(20),
// LOGIN_PASS VARCHAR2(60),
// CREATOR_ID NUMBER not null,
// USER_NAME VARCHAR2(100),
/... | Java |
package cn.gz.lbs.entity;
import java.util.Date;
/**
* TLbsHistory entity. @author MyEclipse Persistence Tools
*/
public class TLbsHistory implements java.io.Serializable {
//*********** Table Fields
// ID NUMBER not null,
// USER_ID NUMBER not null,
// MDN VARCHAR2(20),
// CREATE_TIM... | Java |
package cn.gz.lbs.entity;
/**
* 从周期定位请求LTR中取出部分参数,构成立即定位请求需要的参数实体类
* @author Administrator
*
*/
public class LirNeedEntity {
private int reqId;
private String reqPlatform; //非必选参数,增加REQ_PLATFORM是为了区别高精度/粗定位请求【填1】,当定位请求中不带此element时,系统默认转gpsOne定位
// ORIGINATOR 构造需要的
private String orid;
priv... | Java |
/*
* Copyright 2013 Google 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... | Java |
/*
* Copyright (C) 2013 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... | Java |
/*
* Copyright 2013 Google 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... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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... | Java |
/*
* Copyright 2012 Google 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... | Java |
/*
* Copyright 2012 Google 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... | Java |
/*
* Copyright 2012 Google 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... | Java |
/** Automatically generated file. DO NOT MODIFY */
package com.google.android.gcm;
public final class BuildConfig {
public final static boolean DEBUG = true;
} | Java |
/*
* Copyright 2012 Google 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... | Java |
/*
* Copyright 2012 Google 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... | Java |
/*
* Copyright 2012 Google 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... | Java |
/*
* Copyright 2012 Google 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... | Java |
/*
* Copyright 2012 Google 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... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
/*
* Copyright 2012 Google 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 w... | Java |
package org.syrus.animotion;
import java.util.HashMap;
public class Properties<K> extends HashMap<K,Object> {
/*public Object get (K key) {
return super.get(key);
}*/
public void set (K key, Object value) {
this.put(key, value);
}
}
| Java |
package org.syrus.animotion;
import java.util.HashMap;
import java.util.Iterator;
public class AnimotionManager<T> {
private HashMap<Class,T> managers = new HashMap<Class,T>();
public void addManager (T manager) {
Iterator iterator = ((AnimotionManagerClass)manager).supportedClasses().iterator();
while (iterato... | Java |
package org.syrus.animotion;
import java.util.Enumeration;
import java.util.HashMap;
import java.util.Iterator;
import org.syrus.animotion.AnimateThread;
import org.syrus.animotion.fx.Setter;
public class AnimateObject<T> implements FxListener {
protected T objectPrevAnimation;
protected AnimateThread animation;
... | Java |
package org.syrus.animotion;
import java.util.EventObject;
public class FxEvent extends EventObject {
public FxEvent (Object source) {
super(source);
}
} | Java |
package org.syrus.animotion;
public interface Easing {
// t: current time, b: beginning value, c: Total change in value, d: duration
public double getValue(double t, double b, double c, double d);
} | Java |
package org.syrus.animotion;
import java.util.EventListener;
public interface FxListener extends EventListener {
void fxChange (FxEvent e);
void fxComplete (FxEvent e);
}
| Java |
package org.syrus.animotion;
import java.awt.Color;
import java.lang.reflect.Array;
import java.util.Arrays;
import java.util.Date;
import java.util.HashMap;
import java.util.Timer;
import java.util.Vector;
import org.syrus.animotion.easing.*;
import org.syrus.animotion.fx.*;
import org.syrus.animotion.fx.interpolato... | Java |
package org.syrus.animotion;
import java.util.Enumeration;
import java.util.HashMap;
import java.util.Iterator;
import org.syrus.animotion.AnimateThread;
import org.syrus.animotion.fx.Setter;
public class AnimateElement implements FxListener {
protected HashMap<Object, Object> propertiesPrevAnimation;
protected Ha... | Java |
package org.syrus.animotion;
import java.util.HashMap;
import java.util.Vector;
import org.syrus.animotion.fx.Setter;
public class Elemotion {
protected AnimateElement animation = new AnimateElement(this);
protected Properties properties = new Properties();
public Elemotion property (int key, Object value) {
/... | Java |
package org.syrus.animotion;
import java.util.Vector;
public interface AnimotionManagerClass {
public Vector<Class> supportedClasses ();
}
| Java |
package org.syrus.animotion;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.PaintEvent;
import org.eclipse.swt.events.PaintListener;
import org.eclipse.swt.widgets.Composite;
public abstract class ElemotionSWT extends Elemotion implements PaintListener {
public Composite composite;
public ElemotionSWT (C... | Java |
package org.syrus.animotion;
import java.util.ArrayList;
import java.util.Date;
import java.util.Hashtable;
import java.util.Iterator;
import org.syrus.animotion.fx.Interpolator;
public class Fx<T> {
public T start;
public T end;
private float state;
private Interpolator interpolator;
private long startTime;
p... | Java |
package org.syrus.animotion.easing;
import org.syrus.animotion.Easing;
public class LinearTween implements Easing {
@Override
public double getValue (double t, double b, double c, double d) {
return c*t/d + b;
}
}
| Java |
package org.syrus.animotion.easing;
import org.syrus.animotion.Easing;
public class EaseInOutQuad implements Easing {
@Override
public double getValue (double t, double b, double c, double d) {
return -c *(t/=d)*(t-2) + b;
}
}
| Java |
package org.syrus.animotion.easing;
import org.syrus.animotion.Easing;
public class EaseInElastic implements Easing {
double p = 0;
@Override
public double getValue (double t, double b, double c, double d) {
float s=1.70158f;
if (p == 0) p = d*.3;
double a = c;
if (t==0) return b; if ((t/=d)==1) return b+... | Java |
package org.syrus.animotion.easing;
import org.syrus.animotion.Easing;
public class EaseOutQuad implements Easing {
@Override
public double getValue (double t, double b, double c, double d) {
if ((t/=d/2) < 1) return c/2*t*t + b;
return -c/2 * ((--t)*(t-2) - 1) + b;
}
}
| Java |
package org.syrus.animotion.easing;
import org.syrus.animotion.Easing;
public class EaseInQuad implements Easing {
@Override
public double getValue (double t, double b, double c, double d) {
return c*(t/=d)*t + b;
}
}
| Java |
package org.syrus.animotion.fx.interpolators;
import java.util.Vector;
import org.syrus.animotion.fx.Interpolator;
abstract public class CoreInterpolator<T> implements Interpolator<T> {
private Vector<Class> supported = new Vector<Class>();
final public void addSupportedClass (Class theClass) {
this.supported.ad... | Java |
package org.syrus.animotion.fx.setters;
import java.util.Vector;
import org.eclipse.swt.widgets.Control;
import org.syrus.animotion.fx.Setter;
public class SWTSetter extends CoreSetter<Control> {
public SWTSetter(Control control) {
this.addSupportedClass(Control.class);
}
public Object get(Control control, Obje... | Java |
package org.syrus.animotion.fx.setters;
import org.syrus.animotion.Elemotion;
public class ElemotionSetter extends CoreSetter<Elemotion> {
public ElemotionSetter() {
this.addSupportedClass(Elemotion.class);
}
public Object get(Elemotion element, Object key) {
return element.property((Integer)key);
}
public ... | Java |
package org.syrus.animotion.fx.setters;
import java.util.Vector;
import org.syrus.animotion.AnimotionManagerClass;
import org.syrus.animotion.fx.Setter;
abstract public class CoreSetter<T> implements Setter<T>, AnimotionManagerClass {
protected T element;
private Vector<Class> supported = new Vector<Class>();
fi... | Java |
package org.syrus.animotion.fx;
import org.syrus.animotion.AnimotionManagerClass;
public interface Interpolator<T> extends AnimotionManagerClass {
public T doStep (T start, T end, double state);
}
| Java |
package org.syrus.animotion.fx;
public interface Setter<T> {
public void set (T element, Object key, Object value);
public Object get (T element, Object key);
}
| Java |
package org.syrus.animotion;
import java.util.Iterator;
import java.util.Vector;
public class AnimateThread extends Thread {
Vector <Fx> fx = new Vector<Fx>();
Vector <Fx> completedFx = new Vector<Fx>();
int fps = 80;
public AnimateThread () {
}
public void setFps (int fps) {
this.fps = fps;
}
public void... | Java |
package au.com.twosquared.tools;
import java.util.ArrayList;
public class Shop extends ArrayList<Item> {
int money;
public void buy(Inventory inv, int ID, int amount) {
for (Item i : this) {
if (i.getID() == ID) {
if ((money -= amount) < 0) {
System.out.println("You don't have enough mon... | Java |
package au.com.twosquared.tools;
public class Random {
private static java.util.Random rnd = new java.util.Random();
/**
* Returns an integer between min and max
*
* @param min
* minimum value, inclusive
* @param max
* maximum value exclusive
* @return a number bet... | Java |
package au.com.twosquared.tools;
public class Item {
private int ID;
private String name;
private int cost;
private int amount;
private String description;
public Item(int ID, String name, int cost, int amount, String description){
this.ID = ID;
this.name = name;
this.cost = cost;
this.... | Java |
package au.com.twosquared.tools;
import java.util.ArrayList;
public class Inventory extends ArrayList<Item> {
public Item getInventory(int ID){
for (Item i : this){
if (i.getID() == ID){
return i;
}else error; //Dont remember how to return an error Derp
}
}
public void addInventory(i... | Java |
package au.com.twosquared.animalfarm.map;
import java.util.ArrayList;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;
import au.com.twosquared.animalfarm.sprites.Image;
/**
* Defines the tiles and map of the game including functions which interact with
* the map
*
* @author Jan Martin <jan.martin... | Java |
package au.com.twosquared.animalfarm.sprites;
import com.badlogic.gdx.Gdx;
import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.graphics.g2d.TextureRegion;
// Just a wrapper, I can't stand working with something called textureregion though...
/**
* Loads and manages images
*
* @author Jan M... | Java |
package au.com.twosquared.animalfarm.sprites;
import au.com.twosquared.tools.Random;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;
/**
* Creates, manages and draws animations given a list of images
*
* @author Jan Martin <jan.martin@twosquared.com.au>
* @version 1.0 2011-15-11
* @since 2011-15-1... | Java |
package au.com.twosquared.animalfarm;
import java.util.ArrayList;
import au.com.twosquared.animalfarm.entities.EntityList;
import au.com.twosquared.animalfarm.entities.animals.bird.Chicken;
import au.com.twosquared.animalfarm.map.Map;
import au.com.twosquared.animalfarm.sprites.Animation;
import au.com.twosquared.ani... | Java |
/**
*
*/
package au.com.twosquared.animalfarm.entities;
import java.util.ArrayList;
import au.com.twosquared.animalfarm.map.Map;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;
/**
*
* Defines the functions to update and several entities within a list
*
* @author Jan Martin <jan.martin@two... | Java |
package au.com.twosquared.animalfarm.entities.animals.model;
import java.util.*;
import java.io.*;
import au.com.twosquared.animalfarm.entities.Entity;
import au.com.twosquared.animalfarm.sprites.Animation;
/**
* Contains all the variables within an Animal and enables saving the data into
* a .txt file to ... | Java |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.