A fish scale for dealing with dependencies on grid objects. More...
#include <FishGrid.hpp>
A fish scale for dealing with dependencies on grid objects.
VISH input objects and routines to retrieve a Grid object from a fiber bundle data set.
| Wizt::Fish< Fiber::Grid >::Fish | ( | const string & |  s = "grid",  | 
        |
| int |  prior = 2 | |||
| ) | 
Constructor, optionally pass a parameter of this grid's name (ie.
the name of the slot that will refer to a grid object).
| Fiber::Bundle::GridInfo_t Wizt::Fish< Fiber::Grid >::findMostRecentGrid | ( | GridSelector & | GS, | |
| const RefPtr< ValuePool > & | VP, | |||
| const Fiber::BundlePtr & |  SpaceTime = Fiber::BundlePtr(NullPtr()) | |||
| ) | const | 
This is a convenience function to find the most recent grid for the current time ( Fish<Slice>() or virtual function getTime() ).
This is only valid when using the GridSelector of the Fish's Grid. If you add a secondary Grid via a TypedSlot<Grid> you must not use this function for the second Grid. Use the findMostRecentGrid() function of the GridSelector instead. Here is an example when accessing one Fish Grid and a secondary Grid in an update() function of a VObject derived from a Fish<Grid>:
           GridSelector GS1, GS2; 
           MyGrid  << R >> GS1; // get the GridSelector of the inherited Fish Grid
           InGrid2 << R >> GS2; // get the GridSelector of the second Grid added with a TypedSlot<Grid>InGrid2 
           // get fish grid
           Fiber::Bundle::GridInfo_t Grid1 = findMostRecentGrid( GS1, R );
 
           // get second grid
           Fiber::BundlePtr secBP   = GS2.theSourceBundle; 
           double           sectime = getTime(R, secBP);
           Fiber::Bundle::GridInfo_t Grid2 = GS2.findMostRecentGrid( secBP, sectime ); 
| GS | Return information about the current grid selection. | |
| VP | The context relative to which this selection is to be made | |
| SpaceTime | An optional alternative spacetime from which this grid is retrieved. It will be queried under the same name and under the same time as here. | 
Referenced by Wizt::FieldObject::update().
| bool Wizt::Fish< Fiber::Grid >::IterateLevels | ( | LevelIterator & | LI, | |
| const RefPtr< ValuePool > & | Context, | |||
| const Fiber::BundlePtr & |  SpaceTime = Fiber::BundlePtr( NullPtr() ) | |||
| ) |  [inline] | 
        
Iterate over all the selected levels of a Grid via an instance of the LevelIterator.
Use code like this in a subclass derived from Fish<Field> :
struct DataExtractor : LevelIterator { override bool apply(const RefPtr<Fiber::Representation>&CartesianLevelRep, double time, int Level, const RefPtr<Fiber::Grid>&GridWithCoarsetRefinementLevel, const RefPtr<ValuePool>&Context) { return true; } } DE; IterateLevels(DE, Context);
 1.6.2