This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.example; | |
import java.util.List; | |
import twitter4j.Status; | |
import twitter4j.Twitter; | |
import twitter4j.TwitterException; | |
import twitter4j.TwitterFactory; | |
import twitter4j.conf.ConfigurationBuilder; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==== | |
// 特権ユーザーとしてアプリケーションを再実行するサンプル | |
// - アプリケーション実行時に特権ユーザーの認証ダイアログが表示されます | |
// - 認証後に特権ユーザーとして自身を起動します | |
// - 本サンプルは非特権ユーザーのアプリケーションは終了させずに戻り値を取得しています | |
// | |
// (参考) | |
// Authorization Services C Reference | Mac Developer Library | |
// https://developer.apple.com/library/mac/documentation/Security/Reference/authorization_ref/Reference/reference.html | |
// ==== |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#import <Foundation/Foundation.h> | |
#define TIMEOUT_INTERVAL 10 | |
@interface HttpRequestDelegate : NSObject<NSURLConnectionDelegate> { | |
NSURLConnection *connection; | |
NSMutableData *receivedData; | |
NSURLResponse *responseData; | |
BOOL synchronousOperationComplete; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 自動生成されるInitInstance関数 | |
BOOL InitInstance(HINSTANCE hInstance, int nCmdShow) { | |
HWND hWnd; | |
// グローバル変数にインスタンス処理を設定する | |
hInst = hInstance; | |
// ウィンドウを生成する | |
hWnd = CreateWindow(szWindowClass, szTitle, WS_OVERLAPPEDWINDOW, | |
CW_USEDEFAULT, 0, CW_USEDEFAULT, 0, NULL, NULL, hInstance, NULL); | |
// 通知領域にアイコンを追加する | |
NOTIFYICONDATA notif; |