Search
Preparing search index...
The search index is not available
js-hierarchy
Options
All
Public
Public/Protected
All
Inherited
Externals
Only exported
Menu
Globals
js-hierarchy
SimpleNode
Class SimpleNode
A node implementation offering basic features
Hierarchy
AbstractNode
SimpleNode
Implements
Node
Index
Constructors
constructor
Properties
_log
Accessors
name
Methods
add
Child
find
Child
get
Child
ByName
get
Children
get
Data
get
Level
get
Node
ByPath
get
Node
ByPath
Array
get
Parent
get
Path
get
Path
Nodes
get
Root
is
Root
remove
Child
set
Data
set
Parent
toJSON
walk
Constructors
constructor
new
Simple
Node
(
name
?:
string
, data
?:
object
)
:
SimpleNode
Parameters
Optional
name:
string
Optional
data:
object
[
p:
string
]:
any
Returns
SimpleNode
Properties
Protected
_log
_log
:
loglevel.Logger
= null
Accessors
name
get
name
(
)
:
string
set
name
(
value
:
string
)
:
void
Returns
string
Parameters
value:
string
Returns
void
Methods
add
Child
add
Child
(
child
:
Node
, position
?:
number
)
:
Node
Parameters
child:
Node
Optional
position:
number
Returns
Node
find
Child
find
Child
(
child
:
Node
)
:
number
Parameters
child:
Node
Returns
number
get
Child
ByName
get
Child
ByName
(
name
:
string
)
:
Node
Parameters
name:
string
Returns
Node
get
Children
get
Children
(
)
:
Node
[]
Returns
Node
[]
get
Data
get
Data
(
key
:
string
)
:
any
Parameters
key:
string
Returns
any
get
Level
get
Level
(
)
:
number
Returns
number
get
Node
ByPath
get
Node
ByPath
(
path
:
string
, pathSeparator
?:
string
)
:
Bluebird
<
Node
>
Parameters
path:
string
Optional
pathSeparator:
string
Returns
Bluebird
<
Node
>
get
Node
ByPath
Array
get
Node
ByPath
Array
(
pathNodes
:
Array
<
string
>
, absolute
:
boolean
)
:
Bluebird
<
Node
>
Parameters
pathNodes:
Array
<
string
>
absolute:
boolean
Returns
Bluebird
<
Node
>
get
Parent
get
Parent
(
)
:
Node
Returns
Node
get
Path
get
Path
(
pathSeparator
?:
string
)
:
Bluebird
<
string
>
Parameters
Optional
pathSeparator:
string
Returns
Bluebird
<
string
>
get
Path
Nodes
get
Path
Nodes
(
)
:
Bluebird
<
Array
<
Node
>
>
Returns
Bluebird
<
Array
<
Node
>
>
get
Root
get
Root
(
)
:
Node
Returns
Node
is
Root
is
Root
(
)
:
boolean
Returns
boolean
remove
Child
remove
Child
(
child
:
Node
|
number
)
:
void
Parameters
child:
Node
|
number
Returns
void
set
Data
set
Data
(
key
:
string
, value
:
any
)
:
Node
Parameters
key:
string
value:
any
Returns
Node
set
Parent
set
Parent
(
node
:
Node
)
:
void
Parameters
node:
Node
Returns
void
toJSON
toJSON
(
)
:
string
Returns
string
walk
walk
(
direction
:
Direction.up
|
Direction.down
|
Direction.left
|
Direction.right
|
Direction.rootUp
|
(
Direction.up
|
Direction.down
|
Direction.left
|
Direction.right
|
Direction.rootUp
)
[]
, action
:
ActionFunction
)
:
Bluebird
<
void
>
Parameters
direction:
Direction.up
|
Direction.down
|
Direction.left
|
Direction.right
|
Direction.rootUp
|
(
Direction.up
|
Direction.down
|
Direction.left
|
Direction.right
|
Direction.rootUp
)
[]
action:
ActionFunction
Returns
Bluebird
<
void
>
Globals
Internals
Test
Externals
js-
hierarchy
Direction
Abstract
Node
Data
Not
Found
Error
Down
Walker
Empty
Path
Error
Invalid
Direction
Error
Invalid
Node
Error
Left
Walker
Node
Not
Found
Error
Right
Walker
Root
UpWalker
Simple
Node
constructor
_log
name
add
Child
find
Child
get
Child
ByName
get
Children
get
Data
get
Level
get
Node
ByPath
get
Node
ByPath
Array
get
Parent
get
Path
get
Path
Nodes
get
Root
is
Root
remove
Child
set
Data
set
Parent
toJSON
walk
Up
Walker
Node
Walker
Action
Function
Generated using
TypeDoc
A node implementation offering basic features