vtkSMLoadStateOptionsProxy.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: ParaView
4  Module: vtkSMLoadStateOptionsProxy.h
5 
6  Copyright (c) Kitware, Inc.
7  All rights reserved.
8  See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
37 #ifndef vtkSMLoadStateOptionsProxy_h
38 #define vtkSMLoadStateOptionsProxy_h
39 
40 #include "vtkNew.h" // for vtkNew
41 #include "vtkRemotingServerManagerModule.h" //needed for exports
42 #include "vtkSMProxy.h"
43 #include <vector> // needed for std::vector
44 
46 {
47 public:
50  void PrintSelf(ostream& os, vtkIndent indent) override;
51 
56  virtual bool PrepareToLoad(const char* statefilename);
57 
62  virtual bool HasDataFiles();
63 
68  virtual bool Load();
69 
70  enum
71  {
72  USE_FILES_FROM_STATE = 0,
73  USE_DATA_DIRECTORY = 1,
74  CHOOSE_FILES_EXPLICITLY = 2
75  };
76 
80  vtkSMProperty* FindProperty(const char* name, int id, const char* pname);
81 
86  vtkSMProperty* FindLegacyProperty(const char* sanitizedName);
87 
91  bool IsPropertyModified(int id, const char* pname);
92 
97  std::string GetReaderName(int id) const;
98 
99 protected:
101  ~vtkSMLoadStateOptionsProxy() override;
102 
113  bool LocateFilesInDirectory(
114  std::vector<std::string>& filepaths, int path, bool clearFilenameIfNotFound);
115 
116  vtkSetStringMacro(StateFileName);
117  char* StateFileName;
118 
123 
129 
135 
136 private:
137  class vtkInternals;
138  vtkInternals* Internals;
139 
141  void operator=(const vtkSMLoadStateOptionsProxy&) = delete;
142 };
143 
144 #endif
proxy for state loading options
void PrintSelf(ostream &os, vtkIndent indent) override
#define VTKREMOTINGSERVERMANAGER_EXPORT
superclass for all SM properties
static vtkSMProxy * New()
proxy for a VTK object(s) on a server
Definition: vtkSMProxy.h:152
void operator=(const vtkSMProxy &)=delete
vtkSMProxyInternals * Internals
Definition: vtkSMProxy.h:1013
bool OnlyUseFilesInDataDirectory
When this is set to true, USE_DATA_DIRECTORY mode will fail when a file is not in the data directory ...
int DataFileOptions
The three options for how to specify the data file locations.
int PathMatchingThreshold
When the number of parent directories for a file series reaches this number assume it will match for ...