| Package: | Ext.grid |
| Defined In: | .js |
| Class: | |
| Extends: | Ext.util.Observable |
| 配置项 | 定义者 | |
|---|---|---|
| pathSeparator : String
The token used to separate paths in...
The token used to separate paths in node ids (defaults to '/').
|
Tree | |
| 属性 | 定义者 | |
|---|---|---|
|
this: Node
The node immediately following this...
The node immediately following this node in the tree, or null if there is no sibling node.
|
Tree | |
| 方法 | 定义者 | |
|---|---|---|
|
getRootNode
(
)
: Node
Returns the root node for this tree.
Returns the root node for this tree.
参数项:
|
Tree | |
setRootNode
(
Node node
)
: Node
Sets the root node for this tree.
Sets the root node for this tree.
参数项:
|
Tree | |
getNodeById
(
String id
)
: Node
Gets a node in this tree by its id.
Gets a node in this tree by its id.
参数项:
|
Tree | |
|
isLeaf
(
)
: Boolean
Returns true if this node is a leaf
Returns true if this node is a leaf
参数项:
|
Tree | |
|
isLast
(
)
: Boolean
Returns true if this node is the la...
Returns true if this node is the last child of its parent
参数项:
|
Tree | |
|
isFirst
(
)
: Boolean
Returns true if this node is the fi...
Returns true if this node is the first child of its parent
参数项:
|
Tree | |
appendChild
(
Node/Array node
)
: Node
Insert node(s) as the last child no...
Insert node(s) as the last child node of this node.
参数项:
|
Tree | |
removeChild
(
Node node
)
: Node
Removes a child node from this node.
Removes a child node from this node.
参数项:
|
Tree | |
insertBefore
(
Node node,
Node refNode
)
: Node
Inserts the first node before the s...
Inserts the first node before the second node in this nodes childNodes collection.
参数项:
|
Tree | |
|
remove
(
)
: Node
Removes this node from it's parent
Removes this node from it's parent
参数项:
|
Tree | |
item
(
Number index
)
: Node
Returns the child node at the speci...
Returns the child node at the specified index.
参数项:
|
Tree | |
replaceChild
(
Node newChild,
Node oldChild
)
: Node
Replaces one child node in this nod...
Replaces one child node in this node with another.
参数项:
|
Tree | |
indexOf
(
Node node
)
: Number
Returns the index of a child node
Returns the index of a child node
参数项:
|
Tree | |
|
getOwnerTree
(
)
: Tree
Returns the tree this node is in.
Returns the tree this node is in.
参数项:
|
Tree | |
|
getDepth
(
)
: Number
Returns depth of this node (the roo...
Returns depth of this node (the root node has a depth of 0)
参数项:
|
Tree | |
getPath
(
String attr
)
: String
Returns the path for this node. The...
Returns the path for this node. The path can be used to expand or select this node programmatically.
参数项:
|
Tree | |
bubble
(
Function fn,
Object scope,
Array args
)
Bubbles up the tree from this node,...
Bubbles up the tree from this node, calling the specified function with each node. The scope (this) of
function call will be the scope provided or the current node. The arguments to the function
will be the args provided or the current node. If the function returns false at any point,
the bubble is stopped.
参数项:
|
Tree | |
cascade
(
Function fn,
Object scope,
Array args
)
Cascades down the tree from this no...
Cascades down the tree from this node, calling the specified function with each node. The scope (this) of
function call will be the scope provided or the current node. The arguments to the function
will be the args provided or the current node. If the function returns false at any point,
the cascade is stopped on that branch.
参数项:
|
Tree | |
eachChild
(
Function fn,
Object scope,
Array args
)
Interates the child nodes of this n...
Interates the child nodes of this node, calling the specified function with each node. The scope (this) of
function call will be the scope provided or the current node. The arguments to the function
will be the args provided or the current node. If the function returns false at any point,
the iteration stops.
参数项:
|
Tree | |
findChild
(
String attribute,
Mixed value
)
: Node
Finds the first child that has the ...
Finds the first child that has the attribute with the specified value.
参数项:
|
Tree | |
findChildBy
(
Function fn,
Object scope
)
: Node
Finds the first child by a custom f...
Finds the first child by a custom function. The child matches if the function passed
returns true.
参数项:
|
Tree | |
sort
(
Function fn,
Object scope
)
Sorts this nodes children using the...
Sorts this nodes children using the supplied sort function
参数项:
|
Tree | |
contains
(
Node node
)
: Boolean
Returns true if this node is an anc...
Returns true if this node is an ancestor (at any point) of the passed node.
参数项:
|
Tree | |
isAncestor
(
Node node
)
: Boolean
Returns true if the passed node is ...
Returns true if the passed node is an ancestor (at any point) of this node.
参数项:
|
Tree | |
fireEvent
(
String eventName,
)
: Boolean
触发指定的事件,并将参数传入(至少要有事件名称)。
触发指定的事件,并将参数传入(至少要有事件名称)。
参数项:
|
Observable | |
addListener
(
String eventName,
Function handler,
[Object scope],
[Object options]
)
为该组件加入事件句柄(event handler)
为该组件加入事件句柄(event handler)
句柄函数执行时所在的作用域。句柄函数“this”的上下文。 触发事件后开始执行句柄的延时时间(invocation:the act of making a particular function start),单位:毫秒 true代表为下次事件触发加入一个要处理的句柄,然后再移除本身。 不同配搭方式的选项 一次调用加入上多个句柄(handlers) 或者是以简写的方式书写,前提是只允许同一个的作用域对象传入到所有的句柄中:
参数项:
|
Observable | |
removeListener
(
String eventName,
Function handler,
Object scope
)
移除侦听器
移除侦听器
参数项:
|
Observable | |
|
purgeListeners
(
)
从这个对象身上移除所有的侦听器
从这个对象身上移除所有的侦听器
参数项:
|
Observable | |
addEvents
(
Object object
)
定义观察者的事件。
定义观察者的事件。
参数项:
|
Observable | |
hasListener
(
String eventName
)
: Boolean
查询该对象是否有指定事件的侦听器
查询该对象是否有指定事件的侦听器
参数项:
|
Observable | |
|
suspendEvents
(
)
暂停触发所有的事件(参阅{@link #resumeEvents})
暂停触发所有的事件(参阅{@link #resumeEvents})
参数项:
|
Observable | |
|
resumeEvents
(
)
重新触发事件(参阅{@link #suspendEvents})
重新触发事件(参阅{@link #suspendEvents})
参数项:
|
Observable | |
Ext.util.Observable.prototype.on
(
String eventName,
[Object scope],
Function handler,
[Object options]
)
为该元素添加事件句柄(event handler),addListen...
为该元素添加事件句柄(event handler),addListener的简写方式 @param {String} eventName 侦听事件的类型 @param {Object} scope (可选的) 执行句柄的作用域 @param {Function} handler 事件涉及的方法 @param {Object} options (可选的) @method
参数项:
|
Observable | |
Ext.util.Observable.prototype.un
(
String eventName,
Function handler,
[Object scope]
)
移除侦听器 @param {String} eventName ...
移除侦听器 @param {String} eventName 侦听事件的类型 @param {Function} handler 事件涉及的方法 @param {Object} scope (可选的)句柄的作用域 @method
参数项:
|
Observable | |
Ext.util.Observable.capture
(
Observable o,
Function fn,
[Object scope]
)
. 开始捕捉特定的观察者。 在事件触发之前,所有的事件会...
. 开始捕捉特定的观察者。 在事件触发之前,所有的事件会以"事件名称+标准签名"的形式传入到函数(传入的参数是function类型)。 如果传入的函数执行后返回false,则接下的事件将不会触发。 @param {Observable} o 要捕捉的观察者 @param {Function} fn 要调用的函数 @param {Object} scope (可选的)函数作用域 @static
参数项:
|
Observable | |
Ext.util.Observable.releaseCapture
(
Observable o
)
从Observable身上移除所有已加入的捕捉captu...
从Observable身上移除所有已加入的捕捉captures @param {Observable} o 要释放的观察者 @static
参数项:
|
Observable | |