Package topo :: Package base :: Module sheetview :: Class SheetView
[hide private]
[frames] | no frames]

Class SheetView

source code


A SheetView is constructed from a matrix of values, a bounding box for that matrix, and a name. There are two major ways to create a SheetView: one is from a single matrix of data from a single sheet, the other is by combining the matrices from multiple matrices or SheetViews.
Nested Classes [hide private]

Inherited from param.parameterized.Parameterized: __metaclass__

Instance Methods [hide private]
 
__init__(self, (term_1, term_2), src_name=None, precedence=0.0, timestamp=-1, row_precedence=0.5, **params)
For __init__(self, input_tuple, **params), there are three types of input_tuples:
source code
 
view(self)
Return the requested view as a (matrix, bbox) tuple.
source code
 
sum_maps(self, maps)
Convert the list of (matrix, bbox) tuples into a single matrix and another bounding box.
source code

Inherited from param.parameterized.Parameterized: __getstate__, __repr__, __setstate__, __str__, debug, defaults, force_new_dynamic_value, get_param_values, get_value_generator, inspect_value, message, print_param_values, script_repr, set_default, set_dynamic_time_fn, set_param, state_pop, state_push, verbose, warning

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

Class Methods [hide private]

Inherited from param.parameterized.Parameterized: params, print_param_defaults

Class Variables [hide private]
  cyclic = param.Boolean(default= False, doc= """Whether or not ...
Whether or not the values in this View's matrix represent a cyclic dimension.
  norm_factor = param.Parameter(None, doc= """If cyclic is True,...
If cyclic is True, this value is the cyclic range.
  name = <param.parameterized.String object at 0xa9c1dec>
String identifier for this object.

Inherited from param.parameterized.Parameterized: print_level

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, (term_1, term_2), src_name=None, precedence=0.0, timestamp=-1, row_precedence=0.5, **params)
(Constructor)

source code 

For __init__(self, input_tuple, **params), there are three types of input_tuples:

(matrix_data, matrix_bbox)
This form locks the value of the sheetview to a single matrix. Terminating case of a composite SheetView.

(operation, [tuple_list])

'operation' is performed on the matrices collected from tuple_list. See the list of valid operations in operations.keys().

Each tuple in the tuple_list is one of the following:

(SheetView, None)
    Another SheetView may be passed in to create nested plots.
(matrix_data, bounding_box)
    Static matrix data complete with bounding box.
(Sheet, sheet_view_name)
    This gets sheet_name.sheet_view(sheet_view_name) each time
    the current SheetView has its data requested by .view().

(Sheet, sheet_view_name)

Degenerate case that will pull data from another SheetView and not do any additional processing. Don't yet know a use for this case, but documented for possible future use.
Overrides: object.__init__

view(self)

source code 

Return the requested view as a (matrix, bbox) tuple.

If the constructor was given multiple maps, the view must be built before being returned, which may lock in new views of data from the specified sheets.

Inputs are in the variable self._view_list which is a list of tuples, with each tuple being a matrix and a bounding box, or a sheet and a map name. The sequence cannot be dumped into maps just once because the raw maps may have changed, so other sheets must be queried for the data repeatedly.

sum_maps(self, maps)

source code 

Convert the list of (matrix, bbox) tuples into a single matrix and another bounding box. Not a protected function as it could prove useful to other areas of the simulator.

THIS MUST BE EXPANDED IN THE FUTURE TO MAKE PROPER USE OF THE BOUNDING BOX INFORMATION. CURRENT (8/04) IMPLEMENTATION PASSES THE FIRST MAP IN THE LIST AS THE BOUNDING BOX FOR THE CONSTRUCTED VIEW.

WOULD HAVE DONE AN ADD/INTERSECTION/UNION, BUT BOUNDINGREGION DOES NOT YET SUPPORT SUCH OPERATIONS.


Class Variable Details [hide private]

cyclic

Whether or not the values in this View's matrix represent a cyclic dimension.
Value:
param.Boolean(default= False, doc= """Whether or not the values in this View's mat\
rix represent a cyclic dimension.""")

norm_factor

If cyclic is True, this value is the cyclic range.
Value:
param.Parameter(None, doc= """If cyclic is True, this value is the cyclic range.""\
")