-
公式ドキュメント(日本語訳版) -- http://www.playframework-ja.org/documentation/2.1.5/Home --- 「はじめに」 --- 「Java 開発者のための Play」
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
/** | |
* Copyright (c) 2014 pistatium | |
* | |
* This software is released under the MIT License. | |
* | |
* http://opensource.org/licenses/mit-license.php | |
*/ | |
import java.util.*; | |
import java.lang.Math; |
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
verifyCmd() { | |
for cmd in ${@}; do | |
if [ -z "$(which $cmd)" ]; then | |
echo "$cmd not found in PATH: $PATH" | |
return 1 | |
fi | |
done | |
} | |
: ${GOOGLE_BUCKET_ID?"Need to set GOOGLE_BUCKET_ID"} |
Kotlinで気持ちいい!と思ったけど、落選した項目
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
{ | |
"01": { | |
"id": "01", | |
"name": "北海道", | |
"short": "北海道", | |
"kana": "ホッカイドウ", | |
"en": "hokkaido", | |
"area": { | |
"id": 1, | |
"name": "北海道・東北" |
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
CIFilter *resizeFilter = [CIFilter filterWithName:@"CILanczosScaleTransform"]; | |
[resizeFilter setValue:ciImage forKey:@"inputImage"]; | |
[resizeFilter setValue:[NSNumber numberWithFloat:1.0f] forKey:@"inputAspectRatio"]; | |
[resizeFilter setValue:[NSNumber numberWithFloat:xRatio] forKey:@"inputScale"]; | |
CIFilter *cropFilter = [CIFilter filterWithName:@"CICrop"]; | |
CIVector *cropRect = [CIVector vectorWithX:rect.origin.x Y:rect.origin.y Z:rect.size.width W:rect.size.height]; | |
[cropFilter setValue:resizeFilter.outputImage forKey:@"inputImage"]; | |
[cropFilter setValue:cropRect forKey:@"inputRectangle"]; | |
CIImage *croppedImage = cropFilter.outputImage; |
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 android.support.v7.widget.RecyclerView; | |
import android.view.View; | |
import android.view.ViewGroup; | |
import android.widget.Button; | |
import android.widget.TextView; | |
/** | |
* Created by khaled bakhtiari on 10/26/2014. | |
* <a href="http://about.me/kh.bakhtiari"> | |
*/ |
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 android.view.LayoutInflater; | |
import android.view.View; | |
import android.view.ViewGroup; | |
import com.example.Foo; | |
import com.example.RecycledPagerAdapter; | |
public class FooAdapter extends RecycledPagerAdapter<FooViewHolder> { |
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 android.annotation.SuppressLint | |
import android.os.Bundle | |
import android.os.Parcelable | |
import android.support.v4.app.Fragment | |
import android.support.v4.app.FragmentManager | |
import android.support.v4.app.FragmentTransaction | |
import android.support.v4.view.PagerAdapter | |
import android.view.View | |
import android.view.ViewGroup |
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
extension Sequence { | |
func groupBy<G: Hashable>(closure: (Iterator.Element)->G) -> [G: [Iterator.Element]] { | |
var results = [G: Array<Iterator.Element>]() | |
forEach { | |
let key = closure($0) | |
if var array = results[key] { | |
array.append($0) |
OlderNewer