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 asynctqtest; | |
import java.io.IOException; | |
import java.util.ArrayList; | |
import java.util.Date; | |
import java.util.List; | |
import java.util.UUID; | |
import java.util.concurrent.ExecutionException; | |
import java.util.concurrent.Future; | |
import java.util.logging.Logger; |
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
// Test Support Context | |
package aets | |
import ( | |
"appengine" | |
"appengine/taskqueue" | |
"appengine_internal" | |
tqpb "appengine_internal/taskqueue" | |
"sync" | |
"time" |
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 getmultitest | |
import ( | |
"appengine" | |
"appengine/datastore" | |
"fmt" | |
"net/http" | |
) | |
func init() { |
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 tool | |
import ( | |
"bytes" | |
) | |
func Reverse(s string) string { | |
runes := make([]rune, 0, 10) | |
for _, r := range s { | |
runes = append(runes, r) |
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
function test() { | |
var scope = angular.element(document.getElementById('test')).scope(); | |
scope.$apply(function() { | |
scope.test = 'this is test!!!'; | |
}); | |
} |
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 data | |
type s struct { | |
a, b string | |
} | |
func NewS(a, b string) s { | |
return s{a, b} | |
} |
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
var json = JSON.stringify(data, function(key, value) { | |
if (value instanceof Object === false || Object.getPrototypeOf(value) !== Object.prototype) { | |
return value; | |
} | |
var keys = Object.keys(value); | |
keys.sort(); | |
var newValue = {}; | |
keys.forEach(function(key) { | |
newValue[key] = value[key]; | |
}); |
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
memcache.JSON.Add(c, &memcache.Item{Key:"test", Object: struct { | |
Name string | |
Address string | |
} { | |
"hoge", | |
"moke", | |
}}) |
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 main | |
import ( | |
"fmt" | |
"flag" | |
"time" | |
) | |
type result struct { | |
seq int |
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 hello | |
import ( | |
"github.com/codegangsta/martini" | |
"net/http" | |
) | |
func init() { | |
m := martini.Classic() | |
m.Get("/hello/:name", func(params martini.Params, w http.ResponseWriter) string { |
NewerOlder