1、通过一个Data.java实例类,能够实现全局数据保存,这里就不多说了,学Java的都知道。2、Android特有的Application,是应用的入口,执行贯穿整个app执行过程,能够在这个类中定义全局变量public class baseApplication extends Applica...
分类:
移动开发 时间:
2014-06-27 21:28:16
阅读次数:
256
昨天开始写,用户密码修改,把原来的登录 注册调整了下。中间有些细节。封装获取session中用户信息的方法的时候,我犹豫了很久。class IndexBaseController extends Comm{ protected $userInfo; //session 判断 前置函数 ...
分类:
其他好文 时间:
2014-06-26 22:41:32
阅读次数:
344
php 面向对象编程1:创建类 classvar; }}//SimpleClass::displyVar();$obje1=new SimpleClass();$obje1->displyVar();?>2: 类的继承 extends city; echo ""; ...
分类:
Web程序 时间:
2014-06-26 21:16:39
阅读次数:
335
import java.awt.*;import javax.swing.*;import java.awt.event.*;public class Calculator extends JFrame implements ActionListener{ private static...
分类:
编程语言 时间:
2014-06-26 17:14:16
阅读次数:
350
ServiceRegist.javaimport java.rmi.Remote;import java.rmi.RemoteException;public interface ServiceRegist extends Remote{ public user login(String user....
分类:
编程语言 时间:
2014-06-26 16:05:17
阅读次数:
223
TokenStream extends AttributeSource implements Closeable:
incrementToken,end,reset,close
Tokenizer直接继承至TokenStream,其输入input是一个reader
TokenFilter也直接继承TokenStream,但input是一个TokenStream。
TokenStreamCo...
分类:
其他好文 时间:
2014-06-26 13:19:13
阅读次数:
177
1、首先列出代码
Base.java
public class Base
{
Base() {
preProcess();
}
void preProcess() {}
}
Derived.java
public class Derived extends Base
{
public String whenAmIS...
分类:
编程语言 时间:
2014-06-26 13:14:44
阅读次数:
196
1:MyServicepublic class MyService extends IntentService{ AlarmManager alarmManager = null; PendingIntent alarmIntent = null; public MySe...
分类:
移动开发 时间:
2014-06-25 19:16:20
阅读次数:
261
一、通过View实现自定义视图通过构造函数创建可视界面public class MyView extends View { // Constructor required for in-code creation public MyView(Context context) { super...
分类:
其他好文 时间:
2014-06-25 11:26:33
阅读次数:
269
1)游戏图层设计:public class WellcomeLayer extends CCLayer { public WellcomeLayer() { this.setIsTouchEnabled(true); CCSprite background1 = CCSprite.sprite(.....
分类:
移动开发 时间:
2014-06-25 00:40:48
阅读次数:
373