libopenraw  0.3.7
Public Types | Static Public Member Functions | List of all members
OpenRaw::Internals::RawFileFactory Class Reference

Public Types

typedef std::function< RawFile *(const IO::Stream::Ptr &)> raw_file_factory_t
 
typedef std::map< RawFile::Type, raw_file_factory_t > Table
 
typedef std::map< std::string, RawFile::TypeExtensions
 

Static Public Member Functions

static const Tabletable ()
 
static const Extensions & extensions ()
 
static const char ** fileExtensions ()
 
static void registerType (RawFile::Type type, const raw_file_factory_t &fn, const char *ext)
 

Detailed Description

Definition at line 33 of file rawfilefactory.hpp.

Member Typedef Documentation

◆ Table

typedef std::map<RawFile::Type, raw_file_factory_t> OpenRaw::Internals::RawFileFactory::Table

the factory type for raw files key is the extension. file is factory method

Definition at line 40 of file rawfilefactory.hpp.

Member Function Documentation

◆ extensions()

static const Extensions& OpenRaw::Internals::RawFileFactory::extensions ( )
inlinestatic

Access the extensions table. Ensure that it has been constructed.

Definition at line 51 of file rawfilefactory.hpp.

◆ fileExtensions()

const char ** OpenRaw::Internals::RawFileFactory::fileExtensions ( )
static

access the the list of file extenstions registered.

Definition at line 78 of file rawfilefactory.cpp.

◆ registerType()

void OpenRaw::Internals::RawFileFactory::registerType ( RawFile::Type  type,
const raw_file_factory_t &  fn,
const char *  ext 
)
static

register a filetype with the factory

Parameters
typethe type of file
fnthe factory method
extthe extension associated
Note
it is safe to call this method with the same fn and type to register a different extension

Definition at line 56 of file rawfilefactory.cpp.

◆ table()

static const Table& OpenRaw::Internals::RawFileFactory::table ( )
inlinestatic

Access the table. Ensure that it has been constructed.

Definition at line 47 of file rawfilefactory.hpp.


The documentation for this class was generated from the following files: