Go to the documentation of this file.
29 #ifndef LATTICES_TEMPLATTICEIMPL_H
30 #define LATTICES_TEMPLATTICEIMPL_H
34 #include <casacore/casa/aips.h>
35 #include <casacore/lattices/Lattices/Lattice.h>
36 #include <casacore/lattices/Lattices/TiledShape.h>
37 #include <casacore/tables/Tables/Table.h>
38 #include <casacore/casa/Utilities/CountedPtr.h>
137 void apply (T (*
function)(
const T&))
165 {
itsLatticePtr->setCacheSizeFromPath (sliceShape, windowStart, windowLength,
246 #ifndef CASACORE_NO_AUTO_TEMPLATES
247 #include <casacore/lattices/Lattices/TempLatticeImpl.tcc>
248 #endif //# CASACORE_NO_AUTO_TEMPLATES
IPosition doNiceCursorShape(uInt maxPixels)
Get the best cursor shape.
void apply(const Functional< T, T > &function)
IPosition shape() const
Return the shape of the Lattice including all degenerate axes.
Specify which elements to extract from an n-dimensional array.
A Vector of integers, for indexing into Array<T> objects.
uInt advisedMaxPixels() const
This function returns the recommended maximum number of pixels to include in the cursor of an iterato...
void flush(Bool fsync=False, Bool recursive=False)
Flush the table, i.e.
Bool empty() const
Test for empty.
void setMaximumCacheSize(uInt howManyPixels)
Set the maximum (allowed) cache size as indicated.
TempLatticeImpl(const TempLatticeImpl< T > &other)
The copy constructor cannot be used.
Bool isWritable() const
Is the TempLattice writable? It should be.
void flush()
Flush the data.
void reopen()
If needed, reopen a temporarily closed TempLatticeImpl.
Referenced counted pointer for constant data.
TempLatticeImpl()
The default constructor creates a TempLatticeImpl containing a default ArrayLattice object.
Map a domain object into a range object via operator().
Bool isPaged() const
Is the TempLattice paged to disk?
TempLatticeImpl< T > & operator=(const TempLatticeImpl< T > &other)
The assignment operator cannot be used.
void clearCache()
Clears and frees up the caches, but the maximum allowed cache size is unchanged from when setCacheSiz...
void init(const TiledShape &shape, Double maxMemoryInMB=-1)
Initialize the object.
Bool ok() const
Check class internals - used for debugging.
void doPutSlice(const Array< T > &sourceBuffer, const IPosition &where, const IPosition &stride)
Do the actual getting of an array of values.
~TempLatticeImpl()
The destructor removes the Lattice from memory and if necessary disk.
Bool canReferenceArray() const
Can the lattice data be referenced as an array section?
void putAt(const T &value, const IPosition &where)
T getAt(const IPosition &where) const
Get or put a single element in the lattice.
Main interface class to a read/write table.
uInt maximumCacheSize() const
Maximum size - not necessarily all used.
LatticeExprNode value(const LatticeExprNode &expr)
This function returns the value of the expression without a mask.
Abstract base class to steer lattice iterators.
this file contains all the compiler specific defines
void setCacheSizeFromPath(const IPosition &sliceShape, const IPosition &windowStart, const IPosition &windowLength, const IPosition &axisPath)
Set the cache size as to "fit" the indicated path.
void set(const T &value)
Set all of the elements in the Lattice to the given value.
The class implementing TempLattice.
void setCacheSizeInTiles(uInt howManyTiles)
Set the actual cache size for this Array to be be big enough for the indicated number of tiles.
Bool doGetSlice(Array< T > &buffer, const Slicer §ion)
Do the actual getting of an array of values.
void tempReopen() const
Do the actual reopen of the temporarily closed table (if not open already).
template <class T, class U> class vector;
String: the storage and methods of handling collections of characters.
TempLatticeImpl(const TiledShape &shape, Double maxMemoryInMB)
bool Bool
Define the standard types used by Casacore.
TempLatticeImpl(const TiledShape &shape, Int maxMemoryInMB)
Create a TempLatticeImpl of the specified shape.
void doReopen() const
Do the reopen of the table (if not open already).
void showCacheStatistics(ostream &os) const
Report on cache success.
void apply(T(*function)(const T &))
LatticeIterInterface< T > * makeIter(const LatticeNavigator &navigator, Bool useRef) const
This function is used by the LatticeIterator class to generate an iterator of the correct type for th...
void deleteTable()
Make sure that the temporary table gets deleted.
void tempClose()
Close the Lattice temporarily (if it is paged to disk).
void apply(T(*function)(T))
Replace every element, x, of the Lattice with the result of f(x).
Define the shape and tile shape.
CountedPtr< Lattice< T > > itsLatticePtr
A base class for Lattice iterators.