Σ
: アルファベット(有限集合)Ω = Σ ∪ { [, ]}
Ω^*
:Ω
上の語全体からなる集合L_p
:Ω
上の言語 (括弧言語)- 基底 :
Σ
の元と空語λ
- 帰納ステップ :
u
,v
がL_p
の元ならばuv
と[u]
はL_p
の元
- 基底 :
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
public void concatEager() { | |
final TestSubscriber<List<String>> testSubscriber = new TestSubscriber<>(); | |
final long startTime = new Date().getTime(); | |
System.out.println("Start."); | |
Observable.concatEager( // | |
asyncObservable("uno", 4), // | |
asyncObservable("dos", 3), // |
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
public abstract class RetrofitSingleSubscriber<T> extends SingleSubscriber<T> { | |
public abstract void onHttpError(HttpException e); | |
public abstract void onNonHttpError(Throwable e); | |
@Override public void onError(Throwable error) { | |
if (error instanceof HttpException) { | |
onHttpError((HttpException) error); | |
} else { |
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
// in android :p | |
private void printFib(int l) { | |
fib(l).subscribe(new Action1<List<Long>>() { | |
@Override | |
public void call(List<Long> fib) { | |
Log.v(TAG, fib.toString()); | |
} | |
}); | |
} |
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 secret | |
import android.content.Context; | |
import android.graphics.Bitmap; | |
import android.graphics.drawable.BitmapDrawable; | |
import android.os.Bundle; | |
import android.util.Log; | |
import android.view.View; | |
import android.view.ViewGroup; | |
import android.webkit.WebView; |
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
<?xml version="1.0" encoding="utf-8"?> | |
<layer-list xmlns:android="http://schemas.android.com/apk/res/android"> | |
<item android:id="@android:id/background"> | |
<shape android:shape="line"> | |
<stroke | |
android:width="4dp" | |
android:color="#474747" | |
/> |
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
pulic static void logd(String format, Object... args) { | |
Log.d(TAG, String.format(Locale.getDefault(), format, args)); | |
} |
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
public static long copyFileStream(FileInputStream is, FileOutputStream os) | |
throws IOException { | |
FileChannel srcChannel = null; | |
FileChannel destChannel = null; | |
try { | |
srcChannel = is.getChannel(); | |
destChannel = os.getChannel(); | |
return srcChannel.transferTo(0, srcChannel.size(), destChannel); | |
} finally { |
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
public static Twitter getTwitter(Context ctx) { | |
InputStream is = null; | |
TwitterFactory tf; | |
try { | |
is = ctx.getResources().getAssets().open("twitter4j.properties"); | |
PropertyConfiguration conf = new PropertyConfiguration(is); | |
tf = new TwitterFactory(conf); | |
} catch (IOException e) { | |
tf = new TwitterFactory(); |
##ListView読み込み
- 件数指定
- 自動・手動
- 追加ボタン・オーバースクロール
- リストアイテム非同期読み込みとか
##AsyncTask
- 結果のコールバック
NewerOlder