util.base
Files
jui 에서 공통적으로 사용하는 유틸리티 함수 모음
var _ = jui.include("util.base");
console.log(_.browser.webkit);
Properties
Methods
split array by length
Parameters
- arr : Array
 - len : Number
 
Returns
- Array
 
implements object clone
Parameters
- obj : Array/Object
복사할 객체
 
Returns
- Array
 
유니크 아이디 생성
Parameters
- key : String
prefix string
 
Returns
- String
생성된 아이디 문자열
 
Parameters
- keys : Array
 - csv : String
 - csvNumber : Number
 
Returns
- Array
 
data 를 csv 로 변환한다.
Parameters
- keys : Array
 - dataList : Array
 - dataSize : Number
 
Returns
- String
변환된 csv 문자열
 
implements date format function
yyyy : 4 digits year yy : 2 digits year y : 1 digit year
Parameters
- date : Date
 - format : String
date format string
 - utc : Object
 
Returns
- string
 
implements object deep clone
Parameters
- obj : Object
 - emit : Object
 
Returns
- *
 
Check that it matches the end of a string search string.
Parameters
- string : String
 - searchString : String
 
Returns
- Integer
position
 
implements object extend
Parameters
- origin : Object|Function
 - add : Object|Function
 - skip : Boolean
 
Returns
- Object
 
file 에서 csv 컨텐츠 로드
Parameters
- file : File
 - callback : Function
 
csv 에서 필드 얻어오기
Parameters
- fields : Array
 - csvFields : Array
 
Returns
- Array
 
프로토타입 기반의 상속 제공
Parameters
- ctor : Function
base Class
 - superCtor : Function
super Class
 
최적화된 루프 생성 (5단계로 나눔)
Parameters
- total : Number
 - context : Object (optional)
Defaults to:
null 
Returns
- Function
최적화된 루프 콜백 (index, groupIndex 2가지 파라미터를 받는다.)
 
배열을 사용해서 최적화된 루프로 생성한다.
Parameters
- data : Array
루프로 생성될 배열
 - context : Object (optional)
Defaults to:
null 
Returns
- Function
최적화된 루프 콜백 (data, index, groupIndex 3가지 파라미터를 받는다.)
 
배열의 키 기반 인덱스를 생성한다.
개별 값 별로 멀티 인덱스를 생성한다.
Parameters
- data : Array
 - keyField : String
 
Returns
- Object
생성된 인덱스
 
convert px to integer
Parameters
- px : String or Number
 
Returns
- Number
 
add event in window resize event
Parameters
- callback : Function
 - ms : Number
delay time
 
caculate callback runtime
Parameters
- name : String
 - callback : Function
 
Check that it matches the starting string search string.
Parameters
- string : String
 - searchString : String
 
Returns
- Integer
position
 
call parent method
Parameters
- method : String
parent method name
 - args : Array
 
Returns
- Mixed
 
xml 문자열로 svg datauri 생성
Parameters
- xml : String
 
Returns
- String
변환된 data uri 링크
 
parsing template string
Parameters
- html : Object
 - obj : Object
 
implement async loop without blocking ui
Parameters
- total : Object
 - context : Object
 
Returns
- Function
 
check data type
Parameters
- t : String
type string
 - v : Object
value object
 
Returns
- Boolean