qubx :: tree :: NodeInFile :: Class NodeInFile
[hide private]
[frames] | no frames]

Class NodeInFile

source code

 object --+    
          |    
NodeStorage --+
              |
             NodeInFile

Manages the attributes and data of a Node inside a NodeFile.

Instance Methods [hide private]
 
__init__(self, file, offset=0, template=None, name='')
Instantiated by Node to either manage an existing node or create a new one within file:
source code
 
get_file(self) source code
 
get_offset(self) source code
 
get_name(self) source code
 
set_name(self, x)
Changes the node's name.
source code
 
get_preload(self) source code
 
set_preload(self, x) source code
 
get_data(self) source code
 
get_dataCount(self) source code
 
get_dataSize(self) source code
 
get_dataType(self) source code
 
get_dataPos(self) source code
 
get_childPos(self) source code
 
set_childPos(self, x) source code
 
get_siblingPos(self) source code
 
set_siblingPos(self, x) source code
 
get_rowcount(self) source code
 
get_colcount(self) source code
 
get_loaded(self) source code
 
get_loadedRows(self) source code
 
get_data_item(self, i) source code
 
set_data_item(self, i, x) source code
 
map_data(self, read_only=False) source code
 
setup_data(self, type, rows, cols) source code
 
resize_data(self, nr, type_if_none) source code
 
__adjust_load(self) source code
 
clear_data(self) source code
 
set_string_data(self, s) source code
 
load_rows(self, first, last, do_read) source code
 
unload_rows(self, do_write) source code
 
read_rows(self, first, last) source code
 
write_rows(self, first, last, arr) source code
 
get_rows(self, first, last) source code
 
read(self) source code
 
write(self) source code

Inherited from NodeStorage: get_ondirtied, measure, set_clean, set_ondirtied

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]
  __childPos
  __cols
  __data
  __dataCount
  __dataPos
  __dataSize
  __dataType
  __data_in_node
  __file
  __loadedFirst
  __loadedLast
  __name
  __offset
  __preload
  __rows
  __siblingPos

Inherited from NodeStorage: OnDirtied, childPos, clean, cols, data, dataCount, dataPos, dataSize, dataType, file, loaded, loadedRows, name, offset, preload, rows, siblingPos

Inherited from object: __class__

Method Details [hide private]

__init__(self, file, offset=0, template=None, name='')
(Constructor)

source code 

Instantiated by Node to either manage an existing node or create a new one within file:

 if offset:
     reads in the node structure at offset bytes and set up access to its data
 elif template:
     creates a new node and copy its attributes and data from NodeStorage template
 else:
     creates a new empty node with name
Overrides: object.__init__

get_file(self)

source code 
Overrides: NodeStorage.get_file

get_offset(self)

source code 
Overrides: NodeStorage.get_offset

set_name(self, x)

source code 

Changes the node's name. If it's longer than the old one, the node will have to be reallocated to make room.

get_dataPos(self)

source code 
Overrides: NodeStorage.get_dataPos

get_childPos(self)

source code 
Overrides: NodeStorage.get_childPos

set_childPos(self, x)

source code 
Overrides: NodeStorage.set_childPos

get_siblingPos(self)

source code 
Overrides: NodeStorage.get_siblingPos

set_siblingPos(self, x)

source code 
Overrides: NodeStorage.set_siblingPos

get_data_item(self, i)

source code 
Overrides: NodeStorage.get_data_item

set_data_item(self, i, x)

source code 
Overrides: NodeStorage.set_data_item

map_data(self, read_only=False)

source code 
Overrides: NodeStorage.map_data

setup_data(self, type, rows, cols)

source code 
Overrides: NodeStorage.setup_data

resize_data(self, nr, type_if_none)

source code 
Overrides: NodeStorage.resize_data

clear_data(self)

source code 
Overrides: NodeStorage.clear_data

set_string_data(self, s)

source code 
Overrides: NodeStorage.set_string_data

load_rows(self, first, last, do_read)

source code 
Overrides: NodeStorage.load_rows

unload_rows(self, do_write)

source code 
Overrides: NodeStorage.unload_rows

read_rows(self, first, last)

source code 
Overrides: NodeStorage.read_rows

write_rows(self, first, last, arr)

source code 
Overrides: NodeStorage.write_rows

get_rows(self, first, last)

source code 
Overrides: NodeStorage.get_rows

read(self)

source code 
Overrides: NodeStorage.read

write(self)

source code 
Overrides: NodeStorage.write