Container Grid Function Concept |
The Container Grid Function concept refines the Mutable Grid Function concept. A Container Grid Function can be created and filled with values by a client, much like a ordinary container. This of particular importance for algorithms needing temporary storage, such as boolean flags on grid elements.
Mutable Grid Function
STL Assignable
F is a type which is a model of Container Grid Function
f is an object of type F
G is shorthand for F::grid_type
g is an object of type G.
None, exept those defined in Mutable Grid Function
Name | Expression | Type requirements | return type |
Default construction | F f(); | ||
Construction from grid | F f(g); | ||
Construction and initialization | F f(g,t); | ||
Binding to grid | f.set_grid(g); |
Name | Expression | Precondition | Semantics | Postcondition |
Default construction | F f(); | default construct f |
f is unbound
write access is an error read access is an error | |
construction from grid | F f(g); | construct and bind f to g |
f is bound to g
write access is allowed read access is undefined | |
construction and initialization | F f(g,t); | construct and bind f to g, initialize all values to t |
f is bound to g
write access is allowed f(e) is equal to t for all elements e in the range of f. | |
Binding to grid | f.set_grid(g); | f is unbound | bind f to g |
f is bound to g
write access is allowed, read access is undefined |
Default construction takes constant time.
Construction from grid and construction with initalization both
take time at most O(f.size()), that is, the number of
elements of type F::element_type of g.
Total Grid Function
Partial Grid Function
Grid Element Function Grid Function Mutable Grid Function
Guntram Berti
Container Grid Function Concept |