Main Page | Modules | Class Hierarchy | Class List | File List | Class Members | File Members

SDIFEntity - Directory

The frame directory. More...

Classes

struct  Easdif::SDIFLocation
 A class that hold information about a single frame in an SDIF File. More...
class  Easdif::SDIFEntity::FRIterator< CONST >
 bidrectional iterator More...

Typedefs

typedef std::list< SDIFLocation > Easdif::Directory
 SDIF Frame Directory tpye describing the contents of an SDIF File.
typedef FRIterator< 0 > Easdif::SDIFEntity::iterator
typedef FRIterator< 1 > Easdif::SDIFEntity::const_iterator

Functions

const_iterator Easdif::SDIFEntity::begin () const
 begin iterator
iterator Easdif::SDIFEntity::begin ()
 begin iterator
const_iterator Easdif::SDIFEntity::end () const
 end iterator
iterator Easdif::SDIFEntity::end ()
 SDIFEntity::iterator to end of file.
const SDIFLocation & Easdif::SDIFEntity::currLoc () const
 Get Current Location.
const_iterator Easdif::SDIFEntity::current () const
 Get SDIFEntity::const_iterator pointing to current file position.
iterator Easdif::SDIFEntity::current ()
 Get SDIFEntity::iterator pointing to current file position.
const DirectoryEasdif::SDIFEntity::GetDirectory () const
 get Easdif::Directory of current SDIF File
bool Easdif::SDIFEntity::EnableFrameDir ()
 enable Easdif::Directory for current file
bool Easdif::SDIFEntity::IsFrameDir () const
void Easdif::SDIFEntity::PrintFrameDir () const
const SDIFLocation & Easdif::SDIFEntity::FRIterator::GetLoc ()
const SDIFLocation & Easdif::SDIFEntity::FRIterator::GetLoc () const
 Easdif::SDIFEntity::FRIterator::FRIterator ()
 Easdif::SDIFEntity::FRIterator::FRIterator (const FRIterator< CONST > &in)
 Easdif::SDIFEntity::FRIterator::FRIterator (const FRIterator< swap_const < CONST >::CONSTINV > &in)
 Easdif::SDIFEntity::FRIterator::FRIterator (const SDIFEntity *_ent, Directory::iterator &it, bool forceend)
 const constructor from entity pointer and directory iterator
 Easdif::SDIFEntity::FRIterator::FRIterator (SDIFEntity *_ent, Directory::iterator &it, bool forceend)
 constructor from entity pointer and directory iterator
FRIterator & Easdif::SDIFEntity::FRIterator::operator++ ()
 increment iterator
FRIterator Easdif::SDIFEntity::FRIterator::operator++ (int)
 postfix increment iterator
FRIterator & Easdif::SDIFEntity::FRIterator::operator-- ()
 decrement iterator
FRIterator Easdif::SDIFEntity::FRIterator::operator-- (int)
 postfix decrement iterator
reference Easdif::SDIFEntity::FRIterator::operator * ()
 dereference
const reference Easdif::SDIFEntity::FRIterator::operator * () const
 dereference
pointer Easdif::SDIFEntity::FRIterator::operator-> () const
 member access
pointer Easdif::SDIFEntity::FRIterator::operator-> ()
 member access
bool Easdif::SDIFEntity::FRIterator::GotoPos () throw (SDIFSeekError)
 seek file read pointer position to the frame the iterator point's to

Detailed Description

The frame directory.

The sdif directory assembles the frame information about a file that has been opend for reading. It is created on the fly while reading the file if the function Easdif::SDIFEntity::EnableFrameDir() has been called. This function can be called only right after opening the file to prevent any missing frames. The content of the directory will be updated when the file is read. It contains a struct Easdif::SDIFLocation entry for all the frames and matrices that have been selected when the directoy has been enabled. The directory contains the information found in the frame header as well as the list of selected matrices in the frame using the SDIF selection that is valid at the time when EnableFrameDir() has ben called.

The internal directory can be obtained by means of Easdif::SDIFEntity::GetDirectory(). The use of the frame iterators Easdif::SDIFEntity::iterator and Easdif::SDIFEntity::const_iterator rely on the directory, so you need to enable the directory if you want to use the iterators.

The use of selection requires some attention. As long as the FrameDirectory is not enabled the Selection functions SDIFEntity - Selection work on the low level selection that has been initialized by the file name based selection. After the framedirectory has been enabled only the following functions are allowed: Easdif::SDIFEntity::RestrictMatrixSelection(const SelectionSet<SdifSignature>& sigs), and Easdif::SDIFEntity::RestrictFrameSelection(const SelectionSet<SdifSignature>& sigs) Easdif::SDIFEntity::RestrictStreamSelection(const SelectionSet<SdifSignature>& sigs) Easdif::SDIFEntity::ReestablishStreamSelection(), Easdif::SDIFEntity::ReestablishFrameSelection(), Easdif::SDIFEntity::ReestablishMatrixSelection().

The restrict function create a selection that contains the intersection of the existing selection and the set of elements that is given as argument. A result of such a restriction may be an empty set, which is signaled either as a set containing The reestablish functions will reestablish the selection that has ben active when the frame directory has been initiialized.


Typedef Documentation

typedef FRIterator<0> Easdif::SDIFEntity::iterator [inherited]
 

sdifentity iterator type

typedef FRIterator<1> Easdif::SDIFEntity::const_iterator [inherited]
 

sdifentity iterator type


Function Documentation

const_iterator Easdif::SDIFEntity::begin  )  const [inline, inherited]
 

begin iterator

Returns:
const_iterator to first selected frame of entity

iterator Easdif::SDIFEntity::begin  )  [inline, inherited]
 

begin iterator

Returns:
iterator to first selected frame of entity

const_iterator Easdif::SDIFEntity::end  )  const [inline, inherited]
 

end iterator

Returns:
const_iterator to first selected frame of entity

iterator Easdif::SDIFEntity::end  )  [inline, inherited]
 

SDIFEntity::iterator to end of file.

Returns:
iterator to first selected frame of entity

const SDIFLocation& Easdif::SDIFEntity::currLoc  )  const [inline, inherited]
 

Get Current Location.

Returns:
Reference to SDIFLocation at current file position

const_iterator Easdif::SDIFEntity::current  )  const [inline, inherited]
 

Get SDIFEntity::const_iterator pointing to current file position.

Returns:
A const iterator referencing the current file position

iterator Easdif::SDIFEntity::current  )  [inline, inherited]
 

Get SDIFEntity::iterator pointing to current file position.

Returns:
A iterator referencing the current file position

const Directory& Easdif::SDIFEntity::GetDirectory  )  const [inline, inherited]
 

get Easdif::Directory of current SDIF File

Returns:
reference to Easdif::Directory of current file as has been read so far.

bool Easdif::SDIFEntity::EnableFrameDir  )  [inherited]
 

enable Easdif::Directory for current file

If enabled the entity will internally keep track of the positions of all frames and thereby allow to quickly reposition to a desired frame by specifying the requested Frame time.

EnableFrameDir can be called only for files opened for reading and only if no data frame has yet been read. The

Returns:
true if directoy can be created

bool Easdif::SDIFEntity::IsFrameDir  )  const [inline, inherited]
 

true if frame Directory is enabled

void Easdif::SDIFEntity::PrintFrameDir  )  const [inherited]
 

dump content of Frame Directory to stderr

template<int CONST>
const SDIFLocation& Easdif::SDIFEntity::FRIterator< CONST >::GetLoc  )  [inline, inherited]
 

get the SDIFLocation for the iterators current frame position

template<int CONST>
const SDIFLocation& Easdif::SDIFEntity::FRIterator< CONST >::GetLoc  )  const [inline, inherited]
 

get the SDIFLocation for the iterators current frame position

template<int CONST>
Easdif::SDIFEntity::FRIterator< CONST >::FRIterator  )  [inline, inherited]
 

constructor

template<int CONST>
Easdif::SDIFEntity::FRIterator< CONST >::FRIterator const FRIterator< CONST > &  in  )  [inline, inherited]
 

copy constructor

template<int CONST>
Easdif::SDIFEntity::FRIterator< CONST >::FRIterator const FRIterator< swap_const < CONST >::CONSTINV > &  in  )  [inline, inherited]
 

copy constructor

template<int CONST>
Easdif::SDIFEntity::FRIterator< CONST >::FRIterator const SDIFEntity _ent,
Directory::iterator &  it,
bool  forceend
[inline, inherited]
 

const constructor from entity pointer and directory iterator

Parameters:
_ent pointer to SDIFentity
it directory iterator to use for initialization
forceend if true create iterator pointing to end of file, else create iterator pointing to current frame

template<int CONST>
Easdif::SDIFEntity::FRIterator< CONST >::FRIterator SDIFEntity _ent,
Directory::iterator &  it,
bool  forceend
[inline, inherited]
 

constructor from entity pointer and directory iterator

Parameters:
_ent pointer to SDIFentity
it directory iterator to use for initialization
forceend if true create iterator pointing to end of file, else create iterator pointing to current frame

template<int CONST>
FRIterator& Easdif::SDIFEntity::FRIterator< CONST >::operator++  )  [inline, inherited]
 

increment iterator

when returning the iterator will point to the next selected frame the frame is read and stored internally if it is parsed for the first time. Otherwise the selection operation is performed using the internal directory and the frame will be read only if the iterator will be dereferenced.

Returns:
iterator pointing to next selected frame

template<int CONST>
FRIterator Easdif::SDIFEntity::FRIterator< CONST >::operator++ int   )  [inline, inherited]
 

postfix increment iterator

when returning the iterator will point to the next selected frame the frame is read and stored internally if it is parsed for the first time. Otherwise the selection operation is performed using the internal directory and the frame will be read only if the iterator will be dereferenced.

Returns:
iterator pointing to currently selected frame

template<int CONST>
FRIterator& Easdif::SDIFEntity::FRIterator< CONST >::operator--  )  [inline, inherited]
 

decrement iterator

when returning the iterator will point to the previous selected frame the frame is read and stored internally if it is parsed for the first time. Otherwise the selection operation is performed using the internal directory and the frame will be read only if the iterator will be dereferenced.

Returns:
iterator pointing to next selected frame

template<int CONST>
FRIterator Easdif::SDIFEntity::FRIterator< CONST >::operator-- int   )  [inline, inherited]
 

postfix decrement iterator

when returning the iterator will point to the next selected frame the frame is not read and stored internally, so no real file movement is really done. Therefore iterator decrement is even possible for pipes.

Returns:
iterator pointing to currently selected frame

template<int CONST>
reference Easdif::SDIFEntity::FRIterator< CONST >::operator *  )  [inline, inherited]
 

dereference

at this point the frame the iterator is currently pointing is forced to be loaded from file

Returns:
reference to frame

template<int CONST>
const reference Easdif::SDIFEntity::FRIterator< CONST >::operator *  )  const [inline, inherited]
 

dereference

at this point the frame the iterator is currently pointing is forced to be loaded from file

Returns:
reference to frame

template<int CONST>
pointer Easdif::SDIFEntity::FRIterator< CONST >::operator->  )  const [inline, inherited]
 

member access

at this point the frame the iterator is currently pointing is forced to be loaded from file

Returns:
pointer to frame

template<int CONST>
pointer Easdif::SDIFEntity::FRIterator< CONST >::operator->  )  [inline, inherited]
 

member access

at this point the frame the iterator is currently pointing is forced to be loaded from file

Returns:
pointer to frame

template<int CONST>
bool Easdif::SDIFEntity::FRIterator< CONST >::GotoPos  )  throw (SDIFSeekError) [inline, inherited]
 

seek file read pointer position to the frame the iterator point's to

after calling GotoPos the frame signature has been read and the next sdif read will read the frame header of the next frame. Exception is thron in case of successfull seek but error reading the next frame header.

Returns:
true if position has been achieved


Generated on Tue Jan 3 15:00:56 2006 for Easdif by  doxygen 1.3.9.1