code stringlengths 1 2.01M | repo_name stringlengths 3 62 | path stringlengths 1 267 | language stringclasses 231
values | license stringclasses 13
values | size int64 1 2.01M |
|---|---|---|---|---|---|
//
// main.m
// SimpleHTTPClient
//
// Created by Robbie Hanson on 7/5/11.
// Copyright 2011 __MyCompanyName__. All rights reserved.
//
#import <Cocoa/Cocoa.h>
int main(int argc, char *argv[])
{
return NSApplicationMain(argc, (const char **)argv);
}
| zzymoon-cocoaasyncsocket | GCD/Xcode/SimpleHTTPClient/Desktop/SimpleHTTPClient/main.m | Objective-C | oos | 257 |
#import <Cocoa/Cocoa.h>
@class GCDAsyncSocket;
@interface SimpleHTTPClientAppDelegate : NSObject <NSApplicationDelegate> {
@private
GCDAsyncSocket *asyncSocket;
NSWindow *window;
}
@property (assign) IBOutlet NSWindow *window;
@end
| zzymoon-cocoaasyncsocket | GCD/Xcode/SimpleHTTPClient/Desktop/SimpleHTTPClient/SimpleHTTPClientAppDelegate.h | Objective-C | oos | 241 |
#import <Cocoa/Cocoa.h>
@class GCDAsyncSocket;
@interface CertTestAppDelegate : NSObject <NSApplicationDelegate>
{
GCDAsyncSocket *asyncSocket;
NSWindow *window;
}
@property (assign) IBOutlet NSWindow *window;
- (IBAction)printCert:(id)sender;
@end
| zzymoon-cocoaasyncsocket | GCD/Xcode/CertTest/CertTestAppDelegate.h | Objective-C | oos | 257 |
//
// X509Certificate.m
//
// This class is in the public domain.
// Originally created by Robbie Hanson on Mon Jan 26 2009.
// Updated and maintained by Deusty Designs and the Mac development community.
//
// http://code.google.com/p/cocoaasyncsocket/
//
// This class is largely derived from Apple's sample c... | zzymoon-cocoaasyncsocket | GCD/Xcode/CertTest/X509Certificate.m | Objective-C | oos | 13,704 |
//
// X509Certificate.h
//
// This class is in the public domain.
// Originally created by Robbie Hanson on Mon Jan 26 2009.
// Updated and maintained by Deusty Designs and the Mac development community.
//
// http://code.google.com/p/cocoaasyncsocket/
//
// This class is largely derived from Apple's sample c... | zzymoon-cocoaasyncsocket | GCD/Xcode/CertTest/X509Certificate.h | Objective-C | oos | 1,855 |
#import "CertTestAppDelegate.h"
#import "GCDAsyncSocket.h"
#import "X509Certificate.h"
#import "DDLog.h"
#import "DDTTYLogger.h"
// Debug levels: off, error, warn, info, verbose
static const int ddLogLevel = LOG_LEVEL_INFO;
@implementation CertTestAppDelegate
@synthesize window;
- (id)init
{
if ((self = [super in... | zzymoon-cocoaasyncsocket | GCD/Xcode/CertTest/CertTestAppDelegate.m | Objective-C | oos | 3,624 |
//
// main.m
// CertTest
//
// Created by Robbie Hanson on 11/4/10.
// Copyright 2010 __MyCompanyName__. All rights reserved.
//
#import <Cocoa/Cocoa.h>
int main(int argc, char *argv[])
{
return NSApplicationMain(argc, (const char **) argv);
}
| zzymoon-cocoaasyncsocket | GCD/Xcode/CertTest/main.m | Objective-C | oos | 255 |
#import "BonjourClientAppDelegate.h"
#import "GCDAsyncSocket.h"
#import "DDLog.h"
#import "DDTTYLogger.h"
#import "DDASLLogger.h"
// Log levels: off, error, warn, info, verbose
static const int ddLogLevel = LOG_LEVEL_VERBOSE;
@interface BonjourClientAppDelegate (Private)
- (void)connectToNextAddress;
@end
#pragma ma... | zzymoon-cocoaasyncsocket | GCD/Xcode/BonjourClient/BonjourClientAppDelegate.m | Objective-C | oos | 3,598 |
#import <Cocoa/Cocoa.h>
@class GCDAsyncSocket;
@interface BonjourClientAppDelegate : NSObject <NSApplicationDelegate, NSNetServiceBrowserDelegate, NSNetServiceDelegate>
{
NSNetServiceBrowser *netServiceBrowser;
NSNetService *serverService;
NSMutableArray *serverAddresses;
GCDAsyncSocket *asyncSocket;
BOOL conne... | zzymoon-cocoaasyncsocket | GCD/Xcode/BonjourClient/BonjourClientAppDelegate.h | Objective-C | oos | 402 |
//
// main.m
// BonjourClient
//
// Created by Robbie Hanson on 1/27/11.
// Copyright 2011 Voalte. All rights reserved.
//
#import <Cocoa/Cocoa.h>
int main(int argc, char *argv[])
{
return NSApplicationMain(argc, (const char **) argv);
}
| zzymoon-cocoaasyncsocket | GCD/Xcode/BonjourClient/main.m | Objective-C | oos | 249 |
#import "BonjourServerAppDelegate.h"
#import "GCDAsyncSocket.h"
#import "DDLog.h"
#import "DDTTYLogger.h"
#import "DDASLLogger.h"
// Log levels: off, error, warn, info, verbose
static const int ddLogLevel = LOG_LEVEL_VERBOSE;
@implementation BonjourServerAppDelegate
@synthesize window;
- (void)applicationDidFinish... | zzymoon-cocoaasyncsocket | GCD/Xcode/BonjourServer/BonjourServerAppDelegate.m | Objective-C | oos | 2,984 |
#import <Cocoa/Cocoa.h>
@class GCDAsyncSocket;
@interface BonjourServerAppDelegate : NSObject <NSApplicationDelegate, NSNetServiceDelegate>
{
NSNetService *netService;
GCDAsyncSocket *asyncSocket;
NSMutableArray *connectedSockets;
NSWindow *window;
}
@property (assign) IBOutlet NSWindow *window;
@end
| zzymoon-cocoaasyncsocket | GCD/Xcode/BonjourServer/BonjourServerAppDelegate.h | Objective-C | oos | 313 |
//
// main.m
// BonjourServer
//
// Created by Robbie Hanson on 1/27/11.
// Copyright 2011 Voalte. All rights reserved.
//
#import <Cocoa/Cocoa.h>
int main(int argc, char *argv[])
{
return NSApplicationMain(argc, (const char **) argv);
}
| zzymoon-cocoaasyncsocket | GCD/Xcode/BonjourServer/main.m | Objective-C | oos | 249 |
#!/bin/bash
# 打开apache.http调试信息
adb shell setprop log.tag.org.apache.http VERBOSE
adb shell setprop log.tag.org.apache.http.wire VERBOSE
adb shell setprop log.tag.org.apache.http.headers VERBOSE
echo "Enable Debug"
| zzys3228-fanfou | tools/openHttpDebug.sh | Shell | asf20 | 229 |
package com.markupartist.android.widget;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import android.content.Context;
import android.util.AttributeSet;
import android.util.Log;
import android.view.GestureDetector;
import android.view.LayoutInflater;
import android.view.MotionEv... | zzys3228-fanfou | src/com/markupartist/android/widget/PullToRefreshListView.java | Java | asf20 | 15,869 |
package com.ch_linghu.fanfoudroid;
import java.text.ParseException;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.List;
import android.content.Context;
import android.content.Intent;
import android.content.SharedPreferences;
import android.database.Cursor;
import android.graphics.B... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/DmActivity.java | Java | asf20 | 17,743 |
package com.ch_linghu.fanfoudroid;
import java.text.MessageFormat;
import java.util.List;
import android.content.Intent;
import android.os.Bundle;
import android.view.ContextMenu;
import android.view.ContextMenu.ContextMenuInfo;
import android.view.View;
import android.widget.AdapterView;
import android.widget.Adapte... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/FollowingActivity.java | Java | asf20 | 3,452 |
/*
* Copyright (C) 2009 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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/LoginActivity.java | Java | asf20 | 10,605 |
package com.ch_linghu.fanfoudroid.data;
import com.ch_linghu.fanfoudroid.fanfou.DirectMessage;
import com.ch_linghu.fanfoudroid.fanfou.User;
import com.ch_linghu.fanfoudroid.util.TextHelper;
public class Dm extends Message {
@SuppressWarnings("unused")
private static final String TAG = "Dm";
public bool... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/data/Dm.java | Java | asf20 | 851 |
package com.ch_linghu.fanfoudroid.data;
import java.util.Date;
public class Message {
public String id;
public String screenName;
public String text;
public String profileImageUrl;
public Date createdAt;
public String userId;
public String favorited;
public String truncated;
public String inRe... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/data/Message.java | Java | asf20 | 501 |
package com.ch_linghu.fanfoudroid.data;
import android.database.Cursor;
public interface BaseContent {
long insert();
int delete();
int update();
Cursor select();
}
| zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/data/BaseContent.java | Java | asf20 | 174 |
package com.ch_linghu.fanfoudroid.data;
import java.util.Date;
import android.os.Parcel;
import android.os.Parcelable;
public class User implements Parcelable {
public String id;
public String name;
public String screenName;
public String location;
public String description;
public String profil... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/data/User.java | Java | asf20 | 2,793 |
/*
* Copyright (C) 2009 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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/data/Tweet.java | Java | asf20 | 6,268 |
package com.ch_linghu.fanfoudroid.db;
/**
* All information of status table
*
*/
public final class StatusTablesInfo {
} | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/db/StatusTablesInfo.java | Java | asf20 | 126 |
package com.ch_linghu.fanfoudroid.db;
import android.database.Cursor;
import android.provider.BaseColumns;
import android.util.Log;
import com.ch_linghu.fanfoudroid.data.Tweet;
import com.ch_linghu.fanfoudroid.util.DateTimeHelper;
/**
* Table - Statuses <br />
* <br />
* 为节省流量,故此表不保证本地数据库中所有消息具有前后连贯性, 而只确保最新的MAX_... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/db/StatusTable.java | Java | asf20 | 6,291 |
package com.ch_linghu.fanfoudroid.db;
import android.database.Cursor;
import android.provider.BaseColumns;
import android.util.Log;
import com.ch_linghu.fanfoudroid.data.User;
public final class UserInfoTable implements BaseColumns {
public static final String TAG = "UserInfoTable";
public static fin... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/db/UserInfoTable.java | Java | asf20 | 4,342 |
package com.ch_linghu.fanfoudroid.db;
import java.io.File;
import java.text.DateFormat;
import java.text.SimpleDateFormat;
import java.util.List;
import java.util.Locale;
import android.content.ContentValues;
import android.content.Context;
import android.content.SharedPreferences;
import android.database.Cursor;
imp... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/db/TwitterDatabase.java | Java | asf20 | 34,712 |
package com.ch_linghu.fanfoudroid.db;
import java.text.ParseException;
import android.database.Cursor;
import android.provider.BaseColumns;
import android.util.Log;
import com.ch_linghu.fanfoudroid.data.User;
/**
* Table - Followers
*
*/
public final class FollowTable implements BaseColumns {
public static fi... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/db/FollowTable.java | Java | asf20 | 4,341 |
package com.ch_linghu.fanfoudroid.db;
import java.text.ParseException;
import android.database.Cursor;
import android.provider.BaseColumns;
import android.util.Log;
import com.ch_linghu.fanfoudroid.data.Dm;
/**
* Table - Direct Messages
*
*/
public final class MessageTable implements BaseColumns {
public stat... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/db/MessageTable.java | Java | asf20 | 3,028 |
/*
* Copyright (C) 2009 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 agree... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/StatusActivity.java | Java | asf20 | 23,198 |
/*
* Copyright (C) 2009 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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/PreferencesActivity.java | Java | asf20 | 2,768 |
package com.ch_linghu.fanfoudroid;
import java.util.HashSet;
//import org.acra.ReportingInteractionMode;
//import org.acra.annotation.ReportsCrashes;
import android.app.Application;
import android.content.Context;
import android.content.SharedPreferences;
import android.database.Cursor;
import android.net... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/TwitterApplication.java | Java | asf20 | 8,108 |
/*
* Copyright (C) 2009 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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/service/TwitterService.java | Java | asf20 | 16,138 |
package com.ch_linghu.fanfoudroid.service;
import java.text.DateFormat;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.GregorianCalendar;
import java.util.List;
import android.app.AlarmManager;
import android.app.PendingIntent;
import android.app.... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/service/WidgetService.java | Java | asf20 | 4,879 |
package com.ch_linghu.fanfoudroid.service;
import java.util.List;
import android.content.Context;
import android.location.Criteria;
import android.location.Location;
import android.location.LocationListener;
import android.location.LocationManager;
import android.os.Bundle;
import android.util.Log;
/**
* Location S... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/service/LocationService.java | Java | asf20 | 3,207 |
/*
* Copyright (C) 2009 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 agree... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/service/BootReceiver.java | Java | asf20 | 1,225 |
package com.ch_linghu.fanfoudroid.service;
public interface IService {
void startService();
void stopService();
}
| zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/service/IService.java | Java | asf20 | 118 |
package com.ch_linghu.fanfoudroid.http;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.Reader;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import org.apache.http.HttpEntity;
import org.apache.http.HttpResponse... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/http/Response.java | Java | asf20 | 5,123 |
package com.ch_linghu.fanfoudroid.http;
/**
* HTTP StatusCode is not 200
*/
public class HttpException extends Exception {
private int statusCode = -1;
public HttpException(String msg) {
super(msg);
}
public HttpException(Exception cause) {
super(cause);
}
public HttpException(String msg, int statusCode... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/http/HttpException.java | Java | asf20 | 640 |
package com.ch_linghu.fanfoudroid.http;
import java.io.File;
import java.io.IOException;
import java.io.InputStream;
import java.io.UnsupportedEncodingException;
import java.net.URI;
import java.net.URISyntaxException;
import java.net.URLEncoder;
import java.util.ArrayList;
import java.util.zip.GZIPInputStream;
impor... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/http/HttpClient.java | Java | asf20 | 24,743 |
package com.ch_linghu.fanfoudroid.http;
import java.util.HashMap;
import java.util.Map;
public class HTMLEntity {
public static String escape(String original) {
StringBuffer buf = new StringBuffer(original);
escape(buf);
return buf.toString();
}
public static void escape(StringBuffer original) {
int index... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/http/HTMLEntity.java | Java | asf20 | 23,227 |
/*
* Copyright (C) 2009 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 agree... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/MentionActivity.java | Java | asf20 | 3,471 |
package com.ch_linghu.fanfoudroid;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.List;
import android.app.SearchManager;
import android.content.Intent;
import android.os.Bundle;
import android.text.TextUtils;
import android.util.Log;
import android.view.Menu;
import android.view.V... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/SearchResultActivity.java | Java | asf20 | 9,651 |
package com.ch_linghu.fanfoudroid.db2;
import android.content.Context;
import android.database.SQLException;
import android.database.sqlite.SQLiteDatabase;
import android.database.sqlite.SQLiteOpenHelper;
import android.util.Log;
import com.ch_linghu.fanfoudroid.db2.FanContent.*;
public class FanDatabase {
private ... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/db2/FanDatabase.java | Java | asf20 | 3,309 |
package com.ch_linghu.fanfoudroid.db2;
import java.util.ArrayList;
import java.util.Arrays;
import android.content.ContentValues;
import android.database.Cursor;
import android.database.sqlite.SQLiteDatabase;
import android.util.Log;
/**
* Wrapper of SQliteDatabse#query, OOP style.
*
* Usage: -------------------... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/db2/Query.java | Java | asf20 | 7,915 |
package com.ch_linghu.fanfoudroid.db2;
import java.util.zip.CheckedOutputStream;
import android.R.color;
public abstract class FanContent {
/**
* 消息表 消息表存放消息本身
*
* @author phoenix
*
*/
public static class StatusesTable {
public static final String TABLE_NAME = "t_statuses";
public static class Co... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/db2/FanContent.java | Java | asf20 | 11,166 |
package com.ch_linghu.fanfoudroid;
import java.util.ArrayList;
import java.util.List;
import android.content.Intent;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.widget.ListView;
import android.widget.ProgressBar;
import com.ch_linghu.fanfoudroid.data.Tweet;
... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/UserTimelineActivity.java | Java | asf20 | 11,270 |
package com.ch_linghu.fanfoudroid.util;
import java.text.DecimalFormat;
import java.text.NumberFormat;
import java.util.Arrays;
import java.util.HashMap;
import android.util.Log;
import com.ch_linghu.fanfoudroid.TwitterApplication;
/**
* Debug Timer
*
* Usage: -------------------------------- DebugTimer.start()... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/util/DebugTimer.java | Java | asf20 | 3,972 |
package com.ch_linghu.fanfoudroid.util;
import java.text.DateFormat;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.Date;
import java.util.Locale;
import android.util.Log;
import com.ch_linghu.fanfoudroid.R;
import com.ch_linghu.fanfoudroid.TwitterAppl... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/util/DateTimeHelper.java | Java | asf20 | 3,060 |
package com.ch_linghu.fanfoudroid.util;
import java.io.InputStream;
import java.io.OutputStream;
public class StreamUtils {
public static void CopyStream(InputStream is, OutputStream os) {
final int buffer_size = 1024;
try {
byte[] bytes = new byte[buffer_size];
for (;;) {
int count = is.rea... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/util/StreamUtils.java | Java | asf20 | 458 |
package com.ch_linghu.fanfoudroid.util;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import android.t... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/util/TextHelper.java | Java | asf20 | 4,585 |
package com.ch_linghu.fanfoudroid.util;
import java.io.File;
import java.io.IOException;
import android.os.Environment;
/**
* 对SD卡文件的管理
*
* @author ch.linghu
*
*/
public class FileHelper {
private static final String TAG = "FileHelper";
private static final String BASE_PATH = "fanfoudroid";
public static... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/util/FileHelper.java | Java | asf20 | 778 |
package com.ch_linghu.fanfoudroid.fanfou;
/**
* An exception class that will be thrown when WeiboAPI calls are failed.<br>
* In case the Fanfou server returned HTTP error code, you can get the HTTP
* status code using getStatusCode() method.
*/
public class WeiboException extends Exception {
private int statusCod... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/WeiboException.java | Java | asf20 | 887 |
/*
Copyright (c) 2007-2009, Yusuke Yamamoto
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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/RetweetDetails.java | Java | asf20 | 5,531 |
/*
Copyright (c) 2007-2009, Yusuke Yamamoto
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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/Configuration.java | Java | asf20 | 10,823 |
/*
Copyright (c) 2007-2009, Yusuke Yamamoto
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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/Paging.java | Java | asf20 | 3,505 |
/*
Copyright (c) 2007-2009, Yusuke Yamamoto
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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/Trends.java | Java | asf20 | 5,799 |
/*
Copyright (c) 2007-2009, Yusuke Yamamoto
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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/Trend.java | Java | asf20 | 3,047 |
/*
Copyright (c) 2007-2009, Yusuke Yamamoto
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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/QueryResult.java | Java | asf20 | 5,759 |
/*
Copyright (c) 2007-2009, Yusuke Yamamoto
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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/Weibo.java | Java | asf20 | 60,114 |
/*
* UserObjectWapper.java created on 2010-7-28 上午08:48:35 by bwl (Liu Daoru)
*/
package com.ch_linghu.fanfoudroid.fanfou;
import java.io.Serializable;
import java.util.List;
/**
* 对User对象列表进行的包装,以支持cursor相关信息传递
*
* @author liudaoru - daoru at sina.com.cn
*/
public class UserWapper implements Se... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/UserWapper.java | Java | asf20 | 1,286 |
/*
Copyright (c) 2007-2009, Yusuke Yamamoto
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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/Photo.java | Java | asf20 | 3,073 |
/*
Copyright (c) 2007-2009
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 discla... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/Query.java | Java | asf20 | 6,257 |
/*
Copyright (c) 2007-2009, Yusuke Yamamoto
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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/WeiboResponse.java | Java | asf20 | 8,202 |
/*
Copyright (c) 2007-2009, Yusuke Yamamoto
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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/SavedSearch.java | Java | asf20 | 4,541 |
/*
Copyright (c) 2007-2009, Yusuke Yamamoto
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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/DirectMessage.java | Java | asf20 | 6,727 |
/*
Copyright (c) 2007-2009, Yusuke Yamamoto
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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/WeiboSupport.java | Java | asf20 | 2,420 |
/*
Copyright (c) 2007-2009, Yusuke Yamamoto
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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/User.java | Java | asf20 | 22,419 |
/*
Copyright (c) 2007-2009, Yusuke Yamamoto
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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/RefuseError.java | Java | asf20 | 4,216 |
/*
Copyright (c) 2007-2009, Yusuke Yamamoto
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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/Status.java | Java | asf20 | 11,959 |
/*
Copyright (c) 2007-2009, Yusuke Yamamoto
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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/IDs.java | Java | asf20 | 4,386 |
/*
Copyright (c) 2007-2009, Yusuke Yamamoto
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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/fanfou/RateLimitStatus.java | Java | asf20 | 3,814 |
package com.ch_linghu.fanfoudroid;
import java.util.ArrayList;
import java.util.List;
import android.database.Cursor;
import android.os.Bundle;
import com.ch_linghu.fanfoudroid.data.Tweet;
import com.ch_linghu.fanfoudroid.db.StatusTable;
import com.ch_linghu.fanfoudroid.fanfou.Status;
import com.ch_linghu.fanfoudroi... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/BrowseActivity.java | Java | asf20 | 2,120 |
package com.ch_linghu.fanfoudroid.data2;
public class Photo {
private String thumburl;
private String imageurl;
private String largeurl;
public Photo() {
}
public String getThumburl() {
return thumburl;
}
public void setThumburl(String thumburl) {
this.thumburl = thumburl;
}
public String getImageurl... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/data2/Photo.java | Java | asf20 | 702 |
package com.ch_linghu.fanfoudroid.data2;
import java.util.Date;
public class User {
private String id;
private String name;
private String screen_name;
private String location;
private String desription;
private String profile_image_url;
private String url;
private boolean isProtected;
private int friends_co... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/data2/User.java | Java | asf20 | 3,686 |
package com.ch_linghu.fanfoudroid.data2;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Locale;
import java.util.TimeZone;
public class DataUtils {
static SimpleDateFormat sdf = new SimpleDateFormat(
"EEE MMM dd HH:mm:ss z yyyy", Locale.US);
public st... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/data2/DataUtils.java | Java | asf20 | 531 |
package com.ch_linghu.fanfoudroid.data2;
import java.util.Date;
public class Status {
private Date created_at;
private String id;
private String text;
private String source;
private boolean truncated;
private String in_reply_to_status_id;
private String in_reply_to_user_id;
private boolean favorited;
privat... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/data2/Status.java | Java | asf20 | 3,510 |
/*
* Copyright (C) 2009 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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/app/ImageManager.java | Java | asf20 | 13,800 |
package com.ch_linghu.fanfoudroid.app;
import android.graphics.Bitmap;
import android.widget.ImageView;
import com.ch_linghu.fanfoudroid.TwitterApplication;
import com.ch_linghu.fanfoudroid.app.LazyImageLoader.ImageLoaderCallback;
public class SimpleImageLoader {
public static void display(final ImageView imageVie... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/app/SimpleImageLoader.java | Java | asf20 | 789 |
package com.ch_linghu.fanfoudroid.app;
import java.lang.Thread.State;
import java.util.ArrayList;
import java.util.List;
import java.util.concurrent.ArrayBlockingQueue;
import java.util.concurrent.BlockingQueue;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.TimeUnit;
import android.graphi... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/app/LazyImageLoader.java | Java | asf20 | 5,467 |
/*
* Copyright (C) 2009 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... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/app/Preferences.java | Java | asf20 | 2,768 |
package com.ch_linghu.fanfoudroid.app;
import java.util.HashMap;
import android.graphics.Bitmap;
public class MemoryImageCache implements ImageCache {
private HashMap<String, Bitmap> mCache;
public MemoryImageCache() {
mCache = new HashMap<String, Bitmap>();
}
@Override
public Bitmap get(Str... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/app/MemoryImageCache.java | Java | asf20 | 785 |
package com.ch_linghu.fanfoudroid.app;
import android.text.Spannable;
import android.text.method.LinkMovementMethod;
import android.text.method.MovementMethod;
import android.view.MotionEvent;
import android.widget.TextView;
public class TestMovementMethod extends LinkMovementMethod {
private double mY;
... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/app/TestMovementMethod.java | Java | asf20 | 1,229 |
package com.ch_linghu.fanfoudroid.app;
import android.graphics.Bitmap;
import com.ch_linghu.fanfoudroid.R;
import com.ch_linghu.fanfoudroid.TwitterApplication;
public interface ImageCache {
public static Bitmap mDefaultBitmap = ImageManager
.drawableToBitmap(TwitterApplication.mContext.getResources()
... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/app/ImageCache.java | Java | asf20 | 457 |
package com.ch_linghu.fanfoudroid.app;
import android.app.Activity;
import android.content.Intent;
import android.widget.Toast;
import com.ch_linghu.fanfoudroid.LoginActivity;
import com.ch_linghu.fanfoudroid.R;
import com.ch_linghu.fanfoudroid.fanfou.RefuseError;
import com.ch_linghu.fanfoudroid.http.HttpAuthExcepti... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/app/ExceptionHandler.java | Java | asf20 | 1,794 |
package com.ch_linghu.fanfoudroid;
import java.util.ArrayList;
import java.util.List;
import android.app.ActivityManager;
import android.app.ActivityManager.RunningServiceInfo;
import android.app.PendingIntent;
import android.appwidget.AppWidgetManager;
import android.appwidget.AppWidgetProvider;
import and... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/FanfouWidget.java | Java | asf20 | 8,139 |
package com.ch_linghu.fanfoudroid;
import java.text.MessageFormat;
import android.app.AlertDialog;
import android.app.AlertDialog.Builder;
import android.app.Dialog;
import android.app.ProgressDialog;
import android.content.ContentValues;
import android.content.DialogInterface;
import android.content.Intent;
import a... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/ProfileActivity.java | Java | asf20 | 20,034 |
/*
* Copyright (C) 2009 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 agree... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/WriteActivity.java | Java | asf20 | 24,239 |
/*
* Copyright (C) 2009 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 agree... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/FavoritesActivity.java | Java | asf20 | 4,647 |
package com.ch_linghu.fanfoudroid;
import android.app.Activity;
import android.app.PendingIntent;
import android.content.ComponentName;
import android.content.Intent;
import android.content.pm.ActivityInfo;
import android.content.pm.PackageInfo;
import android.content.pm.PackageManager.NameNotFoundException;
import an... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/AboutActivity.java | Java | asf20 | 2,485 |
package com.ch_linghu.fanfoudroid.dao;
import java.util.ArrayList;
import java.util.List;
import android.content.ContentValues;
import android.database.Cursor;
import android.database.sqlite.SQLiteDatabase;
import android.database.sqlite.SQLiteOpenHelper;
/**
* Database Helper
*
* @see SQLiteDatabase
*/
public ... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/dao/SQLiteTemplate.java | Java | asf20 | 4,913 |
package com.ch_linghu.fanfoudroid.dao;
import java.util.List;
import android.content.ContentValues;
import android.content.Context;
import android.database.Cursor;
import android.database.sqlite.SQLiteDatabase;
import android.text.TextUtils;
import android.util.Log;
import com.ch_linghu.fanfoudroid.dao.SQLiteTemplat... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/dao/StatusDAO.java | Java | asf20 | 9,581 |
package com.ch_linghu.fanfoudroid.task;
public enum TaskResult {
OK, FAILED, CANCELLED,
NOT_FOLLOWED_ERROR, IO_ERROR, AUTH_ERROR
} | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/task/TaskResult.java | Java | asf20 | 134 |
package com.ch_linghu.fanfoudroid.task;
import android.app.ProgressDialog;
import android.content.Context;
import android.util.Log;
import android.widget.Toast;
import com.ch_linghu.fanfoudroid.ui.base.WithHeaderActivity;
public abstract class TaskFeedback {
private static TaskFeedback _instance = null;
public st... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/task/TaskFeedback.java | Java | asf20 | 3,972 |
package com.ch_linghu.fanfoudroid.task;
public abstract class TaskAdapter implements TaskListener {
public abstract String getName();
public void onPreExecute(GenericTask task) {
};
public void onPostExecute(GenericTask task, TaskResult result) {
};
public void onProgressUpdate(GenericTask task, Object param... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/task/TaskAdapter.java | Java | asf20 | 380 |
package com.ch_linghu.fanfoudroid.task;
import android.util.Log;
import com.ch_linghu.fanfoudroid.TwitterApplication;
import com.ch_linghu.fanfoudroid.data.Tweet;
import com.ch_linghu.fanfoudroid.db.StatusTable;
import com.ch_linghu.fanfoudroid.http.HttpException;
import com.ch_linghu.fanfoudroid.ui.base.BaseActivity... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/task/TweetCommonTask.java | Java | asf20 | 2,875 |
package com.ch_linghu.fanfoudroid.task;
import java.util.HashMap;
import org.json.JSONException;
import com.ch_linghu.fanfoudroid.http.HttpException;
/**
* 暂未使用,待观察是否今后需要此类
*
* @author lds
*
*/
public class TaskParams {
private HashMap<String, Object> params = null;
public TaskParams() {
params = new H... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/task/TaskParams.java | Java | asf20 | 3,044 |
package com.ch_linghu.fanfoudroid.task;
public interface TaskListener {
String getName();
void onPreExecute(GenericTask task);
void onPostExecute(GenericTask task, TaskResult result);
void onProgressUpdate(GenericTask task, Object param);
void onCancelled(GenericTask task);
}
| zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/task/TaskListener.java | Java | asf20 | 287 |
package com.ch_linghu.fanfoudroid.task;
import java.util.Observable;
import java.util.Observer;
import android.os.AsyncTask;
import android.util.Log;
import android.widget.Toast;
import com.ch_linghu.fanfoudroid.TwitterApplication;
import com.ch_linghu.fanfoudroid.ui.module.Feedback;
public abstract class GenericTa... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/task/GenericTask.java | Java | asf20 | 2,559 |
package com.ch_linghu.fanfoudroid.task;
import java.util.Observable;
import java.util.Observer;
import android.util.Log;
public class TaskManager extends Observable {
private static final String TAG = "TaskManager";
public static final Integer CANCEL_ALL = 1;
public void cancelAll() {
Log.d(TAG, "All task Can... | zzys3228-fanfou | src/com/ch_linghu/fanfoudroid/task/TaskManager.java | Java | asf20 | 451 |