Medical Imaging Interaction Toolkit
2016.11.0
Medical Imaging Interaction Toolkit
|
#include <mitkFileReaderRegistry.h>
Public Types | |
typedef us::ServiceReference< IFileReader > | ReaderReference |
Public Member Functions | |
FileReaderRegistry () | |
~FileReaderRegistry () | |
mitk::IFileReader * | GetReader (const ReaderReference &ref, us::ModuleContext *context=us::GetModuleContext()) |
std::vector< mitk::IFileReader * > | GetReaders (const MimeType &mimeType, us::ModuleContext *context=us::GetModuleContext()) |
void | UngetReader (mitk::IFileReader *reader) |
void | UngetReaders (const std::vector< mitk::IFileReader * > &readers) |
Static Public Member Functions | |
static MimeType | GetMimeTypeForFile (const std::string &path, us::ModuleContext *context=us::GetModuleContext()) |
Get the highest ranked mime-type for the given file name. More... | |
static std::vector< ReaderReference > | GetReferences (const MimeType &mimeType, us::ModuleContext *context=us::GetModuleContext()) |
Provides convenient access to mitk::IFileReader instances and reading files into mitk::BaseData types.
Definition at line 43 of file mitkFileReaderRegistry.h.
Definition at line 46 of file mitkFileReaderRegistry.h.
mitk::FileReaderRegistry::FileReaderRegistry | ( | ) |
Definition at line 30 of file mitkFileReaderRegistry.cpp.
mitk::FileReaderRegistry::~FileReaderRegistry | ( | ) |
Definition at line 34 of file mitkFileReaderRegistry.cpp.
|
static |
Get the highest ranked mime-type for the given file name.
extension | A file name extension without a leading dot. |
context |
extension
in its extension list. Definition at line 42 of file mitkFileReaderRegistry.cpp.
References mitk::CoreServices::GetMimeTypeProvider(), mitk::IMimeTypeProvider::GetMimeTypesForFile(), and mitkThrow.
Referenced by mitkPointSetReaderTest().
mitk::IFileReader * mitk::FileReaderRegistry::GetReader | ( | const ReaderReference & | ref, |
us::ModuleContext * | context = us::GetModuleContext() |
||
) |
Definition at line 73 of file mitkFileReaderRegistry.cpp.
References us::GetModuleContext(), and us::ServiceObjects< S >::GetService().
Referenced by mitk::IOUtil::Load().
std::vector< mitk::IFileReader * > mitk::FileReaderRegistry::GetReaders | ( | const MimeType & | mimeType, |
us::ModuleContext * | context = us::GetModuleContext() |
||
) |
Definition at line 85 of file mitkFileReaderRegistry.cpp.
References us::GetModuleContext(), us::ServiceObjects< S >::GetService(), and mitk::MimeType::IsValid().
Referenced by mitkPointSetReaderTest().
|
static |
Definition at line 62 of file mitkFileReaderRegistry.cpp.
References us::GetModuleContext(), mitk::MimeType::GetName(), us::ServiceConstants::OBJECTCLASS(), and mitk::IFileIO::PROP_MIMETYPE().
Referenced by mitk::IOUtil::Load().
void mitk::FileReaderRegistry::UngetReader | ( | mitk::IFileReader * | reader | ) |
Definition at line 115 of file mitkFileReaderRegistry.cpp.
void mitk::FileReaderRegistry::UngetReaders | ( | const std::vector< mitk::IFileReader * > & | readers | ) |
Definition at line 126 of file mitkFileReaderRegistry.cpp.