BALL  1.4.79
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
molFileFactory.h
Go to the documentation of this file.
1 // -*- Mode: C++; tab-width: 2; -*-
2 // vi: set ts=2:
3 //
4 
5 #ifndef BALL_FORMAT_MOLFILEFACTORY_H
6 #define BALL_FORMAT_MOLFILEFACTORY_H
7 
8 #ifndef BALL_SYSTEM_FILE_H
9 # include <BALL/SYSTEM/file.h>
10 #endif
11 
12 namespace BALL
13 {
14 
15 class String;
16 class GenericMolFile;
17 
24 {
25  public:
39  static String getSupportedFormats();
40 
42  static bool isFileExtensionSupported(String filename);
43 
44  static GenericMolFile* open(const String& name, File::OpenMode open_mode = std::ios::in);
45 
47  static GenericMolFile* open(const String& name, File::OpenMode open_mode, String default_format, bool forced = false);
48 
50  static GenericMolFile* open(const String& name, File::OpenMode open_mode, GenericMolFile* default_format_file);
51 
52 
53 
54  private:
55 
57  static GenericMolFile* detectFormat(const String& name);
58 };
59 
60 }
61 
62 #endif //BALL_FORMAT_MOLFILEFACTORY_H
63 
std::ios::openmode OpenMode
Definition: file.h:168
#define BALL_EXPORT
Definition: COMMON/global.h:50