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
-- master - slaver 主从流复制 | |
-- 什么情况下才会对流复制造成影响 | |
-- 主从数据不一致,或者从库上有的对象,主库又新建相同的对象 | |
-- tables | |
SELECT * FROM user_tables | |
SELECT * FROM user_tab_comments WHERE table_name = upper(:name) | |
SELECT lower(t.column_name) column_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
# IPV4 | |
## github | |
207.97.227.245 www.github.com | |
203.208.39.22 webcache.googleusercontent.com | |
203.208.39.22 mail.google.com | |
203.208.39.22 reader.google.com | |
203.208.39.22 www.google.com.hk |
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
// notes: http://jsperf.com/transloc-getters | |
// http://www.bytearray.org/?p=711 | |
// testing in Nodejs console | |
function Bits() { | |
this._buffer = 0; | |
this._length = 0; | |
// 写入时虚拟指针 | |
this._wpointer = 0; |
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 Job = { | |
data : [ | |
"We are glad to see you here. This site is dedicated to", | |
"poetry and to the people who make poetry possible", | |
"poets and their readers. FamousPoetsAndPoems.com is", | |
"a free poetry site. On our site you can find a large", | |
"collection of poems and quotes from over 631 poets", | |
"Read and Enjoy Poetry", | |
"I, too, sing America", |
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
<?php | |
function e($str){echo $str , "\n";} | |
class AOP | |
{ | |
static function getInstance() | |
{ | |
$args = func_get_args(); | |
$class = array_shift($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
### | |
design: | |
- base library // 基础库 | |
- application core // 管理页面应用,页面管理中心 | |
- sandbox // 沙箱,连接 app , 提供各 module 之间通信的沙箱通道 | |
- module // 可以独立运行、可以即拔即插、对系统不造成影响 | |
- component // 不可独立运行、依赖于系统 | |
- js/css // 并行、依赖加载 | |
browser: |
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 AOP(obj, advice) { | |
this._instance = obj; | |
this._advice = advice; | |
} | |
AOP.prototype = { | |
_method: null, | |
_params: null, | |
result: null, | |
setAdviceResult: function(result) { | |
this.result = result; |
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 number = 10; | |
var showNumber = function () { | |
alert(number); | |
} | |
(function () { | |
number = 20; | |
showNumber(); | |
})() |
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
!-[1,] | |
var IE6 = false /*@cc_on || @_jscript_version < 5.7 @*/; | |
var isMSIE = /*@cc_on!@*/false; |
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
/* | |
Notes: | |
Observer Event Pub/Sub | |
add → bind → subscribe | |
remove → unbind → unsubscribe | |
notify → trigger → publish | |
topic → type → topic | |
*/ | |
/** | |
* Observer Class |