[angular js] Module ~ factory service provider
區分這三者的不同。
peicheng 發表在 痞客邦 留言(0) 人氣(32)
有了Firebase,打造應用程式好簡單 | WIRED.tw
http://wired.tw/2012/05/23/firebase/index.html
peicheng 發表在 痞客邦 留言(0) 人氣(30)
pc_liao@tw-pcliao1[~/code/git-tools/parse_index_file]{17:06}$ ruby parse_index_file.rb ../.git/index
parse_index_file.rb:10:in `require': no such file to load -- bindata (LoadError)
from parse_index_file.rb:10
pc_liao@tw-pcliao1[~/code/git-tools/parse_index_file]{17:06}$ gem install bindata
peicheng 發表在 痞客邦 留言(0) 人氣(55)
import com.google.inject.Guice;
import com.google.inject.Inject;
import com.google.inject.Injector;
final Config config1 = injector.getInstance(ConfigFactory.class).createNew(cluster, "t1",
new HashMap<String, String>() {{
put("prop1", "val1");
}});
config1.setVersionTag("1");
config1.persist();
peicheng 發表在 痞客邦 留言(0) 人氣(11)
最近常常看這樣樣形式的 LinkedHashMap 用法
繼承 hashmap 以獲得 put method。
Methods inherited from class java.util.
HashMap clone, containsKey, entrySet, isEmpty, keySet, put, putAll, remove, size, values
peicheng 發表在 痞客邦 留言(0) 人氣(120)
Autoboxing is the automatic conversion that the Java compiler makes between the primitive types and their corresponding object wrapper classes.
For example, converting an int to an Integer, a double to a Double, and so on.
If the conversion goes the other way, this is called unboxing.
peicheng 發表在 痞客邦 留言(0) 人氣(8)
Type inference is a Java compiler's ability to look at each method invocation and corresponding declaration to determine the type argument (or arguments) that make the invocation applicable
peicheng 發表在 痞客邦 留言(0) 人氣(6)
Generic Types (The Java™ Tutorials > Learning the Java Language > Generics (Updated))
http://docs.oracle.com/javase/tutorial/java/generics/types.html
peicheng 發表在 痞客邦 留言(0) 人氣(6)
關於 @Override Annotation 的說明
限定 Override 父類方法 - Override
peicheng 發表在 痞客邦 留言(0) 人氣(43)
[js]jquery sort table by data attr 排序表格
javascript 區段加入
$(document).ready(function() {
$('.link-sort-table1').click(function(e) {
var $sort = this;
var $table = $('#sort-table1');
var $rows = $('tbody > tr',$table);
$rows.sort(function(a, b){
var keyA = parseInt($(a).attr('data-price'));
//alert(keyA);
var keyB = parseInt($(b).attr('data-price'));
if($($sort).hasClass('asc')){
return (keyA > keyB) ? 1 : 0;
} else {
return (keyA < keyB) ? 1 : 0;
}
});
$.each($rows, function(index, row){
$table.append(row);
});
e.preventDefault();
});
});
peicheng 發表在 痞客邦 留言(0) 人氣(449)