FileParser Class Reference

File parser - parse essence from a sequential set of files. More...

#include <essence.h>

Inheritance diagram for FileParser:

ListOfFiles RefCount IRefCount List of all members.

Public Member Functions

 FileParser (std::string FileName="")
 Construct a FileParser and optionally set a single source filename pattern.
ParserDescriptorListPtr IdentifyEssence (void)
 Identify the essence type in the first file in the set of possible files.
EssenceParser::WrappingConfigList ListWrappingOptions (bool AllowMultiples, ParserDescriptorListPtr PDList, WrappingOption::WrapType ForceWrap=WrappingOption::None)
 Produce a list of available wrapping options.
EssenceParser::WrappingConfigList ListWrappingOptions (ParserDescriptorListPtr PDList, WrappingOption::WrapType ForceWrap=WrappingOption::None)
 Produce a list of available wrapping options.
EssenceParser::WrappingConfigList ListWrappingOptions (bool AllowMultiples, ParserDescriptorListPtr PDList, Rational ForceEditRate, WrappingOption::WrapType ForceWrap=WrappingOption::None)
 Produce a list of available wrapping options.
EssenceParser::WrappingConfigList ListWrappingOptions (ParserDescriptorListPtr PDList, Rational ForceEditRate, WrappingOption::WrapType ForceWrap=WrappingOption::None)
 Produce a list of available wrapping options.
EssenceParser::WrappingConfigPtr SelectWrappingOption (ParserDescriptorListPtr PDList, WrappingOption::WrapType ForceWrap=WrappingOption::None)
 Select the best wrapping option without a forced edit rate.
EssenceParser::WrappingConfigPtr SelectWrappingOption (ParserDescriptorListPtr PDList, Rational ForceEditRate, WrappingOption::WrapType ForceWrap=WrappingOption::None)
 Select the best wrapping option with a forced edit rate.
EssenceParser::WrappingConfigPtr SelectWrappingOption (bool AllowMultiples, ParserDescriptorListPtr PDList, WrappingOption::WrapType ForceWrap=WrappingOption::None)
 Select the best wrapping option without a forced edit rate.
EssenceParser::WrappingConfigPtr SelectWrappingOption (bool AllowMultiples, ParserDescriptorListPtr PDList, Rational ForceEditRate, WrappingOption::WrapType ForceWrap=WrappingOption::None)
 Select the best wrapping option with a forced edit rate.
void SelectWrappingOption (EssenceParser::WrappingConfigPtr Config)
 Select the specified wrapping options.
void Use (UInt32 Stream, WrappingOptionPtr &UseWrapping)
 Set a wrapping option for this essence.
EssenceSourcePtr GetEssenceSource (UInt32 Stream)
 Return the sequential EssenceSource for the main stream (already aquired internally, so no need to use the stream ID).
EssenceSourcePtr GetSubSource (UInt32 Stream)
 Build an EssenceSource to read from the specified sub-stream.
bool OpenFile (void)
 Open the current file (any new-file handler will already have been called).
void CloseFile (void)
 Close the current file.
bool IsFileOpen (void)
 Is the current file open?

Protected Types

typedef std::list< SubStreamInfoSubStreamList
 A list of sub-stream sources, with associated properties.

Protected Member Functions

bool GetFirstSource (void)
 Set the sequential source to use the EssenceSource from the currently open and identified source file.
bool GetNextSource (void)
 Set the sequential source to use an EssenceSource from the next available source file.

Protected Attributes

bool CurrentFileOpen
 True if we have a file open for processing.
FileHandle CurrentFile
 The current file being processed.
EssenceSubParserPtr SubParser
 The sub-parser selected for parsing this sourceessence.
UInt32 CurrentStream
 The currently selected stream in the source essence.
MDObjectPtr CurrentDescriptor
 Pointer to the essence descriptor for the currently selected stream.
WrappingOptionPtr CurrentWrapping
 The currently selected wrapping options.
EssenceSourceParent SeqSource
 This parser's sequential source - which perversely owns the parser!
DataChunkPtr PendingData
 Any pending data from the main stream held over from a previous file is a sub-stream read caused a change of file.
SubStreamList SubStreams
 A list of sub-stream sources.

Friends

class SequentialEssenceSource

Classes

class  SequentialEssenceSource
 Essence Source that manages a sequence of essence sources from a list of file patterns. More...
struct  SubStreamInfo
 Information about a substream. More...

Detailed Description

File parser - parse essence from a sequential set of files.


Member Typedef Documentation

typedef std::list<SubStreamInfo> SubStreamList [protected]

A list of sub-stream sources, with associated properties.


Constructor & Destructor Documentation

FileParser ( std::string  FileName = ""  )  [inline]

Construct a FileParser and optionally set a single source filename pattern.


Member Function Documentation

ParserDescriptorListPtr IdentifyEssence ( void   ) 

Identify the essence type in the first file in the set of possible files.

EssenceParser::WrappingConfigList ListWrappingOptions ( bool  AllowMultiples,
ParserDescriptorListPtr  PDList,
WrappingOption::WrapType  ForceWrap = WrappingOption::None 
) [inline]

Produce a list of available wrapping options.

EssenceParser::WrappingConfigList ListWrappingOptions ( ParserDescriptorListPtr  PDList,
WrappingOption::WrapType  ForceWrap = WrappingOption::None 
) [inline]

Produce a list of available wrapping options.

EssenceParser::WrappingConfigList ListWrappingOptions ( bool  AllowMultiples,
ParserDescriptorListPtr  PDList,
Rational  ForceEditRate,
WrappingOption::WrapType  ForceWrap = WrappingOption::None 
)

Produce a list of available wrapping options.

EssenceParser::WrappingConfigList ListWrappingOptions ( ParserDescriptorListPtr  PDList,
Rational  ForceEditRate,
WrappingOption::WrapType  ForceWrap = WrappingOption::None 
) [inline]

Produce a list of available wrapping options.

EssenceParser::WrappingConfigPtr SelectWrappingOption ( ParserDescriptorListPtr  PDList,
WrappingOption::WrapType  ForceWrap = WrappingOption::None 
) [inline]

Select the best wrapping option without a forced edit rate.

EssenceParser::WrappingConfigPtr SelectWrappingOption ( ParserDescriptorListPtr  PDList,
Rational  ForceEditRate,
WrappingOption::WrapType  ForceWrap = WrappingOption::None 
) [inline]

Select the best wrapping option with a forced edit rate.

EssenceParser::WrappingConfigPtr SelectWrappingOption ( bool  AllowMultiples,
ParserDescriptorListPtr  PDList,
WrappingOption::WrapType  ForceWrap = WrappingOption::None 
) [inline]

Select the best wrapping option without a forced edit rate.

EssenceParser::WrappingConfigPtr SelectWrappingOption ( bool  AllowMultiples,
ParserDescriptorListPtr  PDList,
Rational  ForceEditRate,
WrappingOption::WrapType  ForceWrap = WrappingOption::None 
)

Select the best wrapping option with a forced edit rate.

void SelectWrappingOption ( EssenceParser::WrappingConfigPtr  Config  ) 

Select the specified wrapping options.

void Use ( UInt32  Stream,
WrappingOptionPtr UseWrapping 
)

Set a wrapping option for this essence.

IdentifyEssence() and IdentifyWrappingOptions() must have been called first

EssenceSourcePtr GetEssenceSource ( UInt32  Stream  ) 

Return the sequential EssenceSource for the main stream (already aquired internally, so no need to use the stream ID).

EssenceSourcePtr GetSubSource ( UInt32  Stream  ) 

Build an EssenceSource to read from the specified sub-stream.

Build a new info block

bool OpenFile ( void   )  [inline, virtual]

Open the current file (any new-file handler will already have been called).

Required for ListOfFiles

Returns:
true if file open succeeded

Implements ListOfFiles.

void CloseFile ( void   )  [inline, virtual]

Close the current file.

Required for ListOfFiles

Implements ListOfFiles.

bool IsFileOpen ( void   )  [inline, virtual]

Is the current file open?

Required for ListOfFiles

Implements ListOfFiles.

bool GetFirstSource ( void   )  [protected]

Set the sequential source to use the EssenceSource from the currently open and identified source file.

Returns:
true if all OK, false if no EssenceSource available

bool GetNextSource ( void   )  [protected]

Set the sequential source to use an EssenceSource from the next available source file.

Returns:
true if all OK, false if no EssenceSource available

Must restart parsing the hard way


Friends And Related Function Documentation

friend class SequentialEssenceSource [friend]


Member Data Documentation

bool CurrentFileOpen [protected]

True if we have a file open for processing.

FileHandle CurrentFile [protected]

The current file being processed.

EssenceSubParserPtr SubParser [protected]

The sub-parser selected for parsing this sourceessence.

UInt32 CurrentStream [protected]

The currently selected stream in the source essence.

MDObjectPtr CurrentDescriptor [protected]

Pointer to the essence descriptor for the currently selected stream.

WrappingOptionPtr CurrentWrapping [protected]

The currently selected wrapping options.

EssenceSourceParent SeqSource [protected]

This parser's sequential source - which perversely owns the parser!

DataChunkPtr PendingData [protected]

Any pending data from the main stream held over from a previous file is a sub-stream read caused a change of file.

SubStreamList SubStreams [protected]

A list of sub-stream sources.


The documentation for this class was generated from the following files:
Generated on Mon Apr 2 15:20:59 2007 for MXFLib by  doxygen 1.5.1-p1