Skip to content

Instantly share code, notes, and snippets.

Yusuke Kawata yusuke2255

Block or report user

Report or block yusuke2255

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@yusuke2255
yusuke2255 / build.gradle
Last active Aug 29, 2015
Exclude subproject's module
View build.gradle
// OK
testCompile (project(':tests:common')){
exclude group: 'junit'
}
View FreeMarkerRunner.java
package jp.test.runner;
import java.io.File;
import java.io.IOException;
import java.io.StringWriter;
import java.io.Writer;
import java.net.URISyntaxException;
import java.net.URL;
import java.util.HashMap;
import java.util.Map;
@yusuke2255
yusuke2255 / aws_vip_change.sh
Last active Aug 29, 2015
Mysql Master HAをソースからインストールするレシピ
View aws_vip_change.sh
#!/bin/bash
if [ $# -lt 2 ]; then
echo "Illegal param count.count = $#"
exit 1
fi
# High Availability IP variables
# Other node's IP to ping and VIP to swap if other node goes down
VIP_ENI_ID=eni-xxxxxxxxx
@yusuke2255
yusuke2255 / HttpClientHttpsProxyTest.java
Created Feb 12, 2014
Java HttpClient4.3でProxy(https)を使うテスト
View HttpClientHttpsProxyTest.java
import java.io.IOException;
import java.nio.charset.StandardCharsets;
import java.util.ArrayList;
import java.util.List;
import org.apache.http.Header;
import org.apache.http.HttpHost;
import org.apache.http.HttpResponse;
import org.apache.http.NameValuePair;
import org.apache.http.client.HttpClient;
@yusuke2255
yusuke2255 / HogeController.java
Last active Dec 20, 2015
Spring3.2でJsonを返すコントローラを作成。(servlet3.0でweb.xmlは使わなかったバージョン)
View HogeController.java
package jp.test.hoge.controller;
import jp.test.hoge.model.HogeModel;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
@Controller
public class HogeController {
View jstemplate-sample.js
var myJson1 = {title:"タイトル_1_ですよ。",detail:"このデータはlistデータを持ってるのです。",list:[{listTitle:"1個目なのです",attrChecked:true,attrName:"name_1"},{listTitle:"2個目なのです",attrChecked:false,attrName:"name_2"}]};
var myJson2 = {title:"タイトル_2_ですよ。",detail:"このデータはlistデータを持ってないのです。"};
function showTitle(title) {
alert(title);
};
function setTemplateData(type) {
// テンプレートの取得
var t = jstGetTemplate('template');
You can’t perform that action at this time.