Total Grid Function ConceptGrid FunctionsMutable Grid Function ConceptContainer Grid Function Concept

Container Grid Function Concept

Description

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.

Refinement of

Mutable Grid Function
STL Assignable

Notation

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.

Associated types

None, exept those defined in Mutable Grid Function

Valid Expressions

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);    

Expression semantics

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

Complexity Guarantees

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.

Refinements

Total Grid Function  
Partial Grid Function

Models
Notes
See also

Grid Element Function   Grid Function   Mutable Grid Function  


Guntram Berti


Total Grid Function ConceptGrid FunctionsMutable Grid Function ConceptContainer Grid Function Concept