OTB  9.0.0
Orfeo Toolbox
otbExtendedFilenameToReaderOptions.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2005-2022 Centre National d'Etudes Spatiales (CNES)
3  *
4  * This file is part of Orfeo Toolbox
5  *
6  * https://www.orfeo-toolbox.org/
7  *
8  * Licensed under the Apache License, Version 2.0 (the "License");
9  * you may not use this file except in compliance with the License.
10  * You may obtain a copy of the License at
11  *
12  * http://www.apache.org/licenses/LICENSE-2.0
13  *
14  * Unless required by applicable law or agreed to in writing, software
15  * distributed under the License is distributed on an "AS IS" BASIS,
16  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17  * See the License for the specific language governing permissions and
18  * limitations under the License.
19  */
20 
21 #ifndef otbExtendedFilenameToReaderOptions_h
22 #define otbExtendedFilenameToReaderOptions_h
23 
25 #include <string>
26 
27 namespace otb
28 {
29 
53 {
54 public:
57  typedef itk::SmartPointer<Self> Pointer;
58  typedef itk::SmartPointer<const Self> ConstPointer;
60 
62  itkNewMacro(Self);
63 
65  typedef FNameHelperType::OptionMapType MapType;
66  typedef MapType::iterator MapIteratorType;
67 
69  struct OptionType
70  {
71  std::pair<bool, std::string> simpleFileName;
72  std::pair<bool, std::string> extGEOMFileName;
73  std::pair<bool, unsigned int> subDatasetIndex;
74  std::pair<bool, unsigned int> resolutionFactor;
75  std::pair<bool, bool> skipCarto;
76  std::pair<bool, bool> skipGeom;
77  std::pair<bool, bool> skipRpcTag;
78  std::pair<bool, std::string> bandRange;
79  std::vector<std::string> optionList;
80  };
81 
83  void SetExtendedFileName(const char* extFname) override;
84 
85  void SetExtendedFileName(const std::string& extFname) override;
86 
87  /* Get Methods */
88  bool SimpleFileNameIsSet() const;
89  bool ExtGEOMFileNameIsSet() const;
90  const char* GetExtGEOMFileName() const;
91  bool SubDatasetIndexIsSet() const;
92  unsigned int GetSubDatasetIndex() const;
93  bool ResolutionFactorIsSet() const;
94  unsigned int GetResolutionFactor() const;
95  bool SkipCartoIsSet() const;
96  bool GetSkipCarto() const;
97  bool SkipGeomIsSet() const;
98  bool GetSkipGeom() const;
99  bool SkipRpcTagIsSet() const;
100  bool GetSkipRpcTag() const;
101  std::string GetBandRange() const;
102 
104  bool BandRangeIsSet() const;
105 
106 protected:
109  {
110  }
111 
112 private:
113  ExtendedFilenameToReaderOptions(const Self&) = delete;
114  void operator=(const Self&) = delete;
115 
117 };
118 } // end namespace otb
119 
120 #endif // otbExtendedFilenameToReaderOptions_h
otb::ExtendedFilenameToReaderOptions::MapIteratorType
MapType::iterator MapIteratorType
Definition: otbExtendedFilenameToReaderOptions.h:66
otb::ExtendedFilenameToReaderOptions
Converts an extended filename to reader options.
Definition: otbExtendedFilenameToReaderOptions.h:52
otb::ExtendedFilenameToReaderOptions::OptionType::optionList
std::vector< std::string > optionList
Definition: otbExtendedFilenameToReaderOptions.h:79
otb::ExtendedFilenameToReaderOptions::OptionType::resolutionFactor
std::pair< bool, unsigned int > resolutionFactor
Definition: otbExtendedFilenameToReaderOptions.h:74
otb::ExtendedFilenameToReaderOptions::OptionType::subDatasetIndex
std::pair< bool, unsigned int > subDatasetIndex
Definition: otbExtendedFilenameToReaderOptions.h:73
otb::ExtendedFilenameToReaderOptions::OptionType::skipCarto
std::pair< bool, bool > skipCarto
Definition: otbExtendedFilenameToReaderOptions.h:75
otb
The "otb" namespace contains all Orfeo Toolbox (OTB) classes.
Definition: otbJoinContainer.h:32
otb::ExtendedFilenameToReaderOptions::Pointer
itk::SmartPointer< Self > Pointer
Definition: otbExtendedFilenameToReaderOptions.h:57
otb::ExtendedFilenameHelper::Superclass
itk::Object Superclass
Definition: otbExtendedFilenameHelper.h:51
otb::ExtendedFilenameToReaderOptions::OptionType::bandRange
std::pair< bool, std::string > bandRange
Definition: otbExtendedFilenameToReaderOptions.h:78
otb::ExtendedFilenameHelper
Helper to handle extended filenames.
Definition: otbExtendedFilenameHelper.h:44
otb::ExtendedFilenameToReaderOptions::Superclass
ExtendedFilenameHelper Superclass
Definition: otbExtendedFilenameToReaderOptions.h:59
otb::ExtendedFilenameToReaderOptions::Self
ExtendedFilenameToReaderOptions Self
Definition: otbExtendedFilenameToReaderOptions.h:56
otb::ExtendedFilenameToReaderOptions::OptionType::skipGeom
std::pair< bool, bool > skipGeom
Definition: otbExtendedFilenameToReaderOptions.h:76
otbExtendedFilenameHelper.h
otb::ExtendedFilenameToReaderOptions::OptionType::simpleFileName
std::pair< bool, std::string > simpleFileName
Definition: otbExtendedFilenameToReaderOptions.h:71
otb::ExtendedFilenameToReaderOptions::ConstPointer
itk::SmartPointer< const Self > ConstPointer
Definition: otbExtendedFilenameToReaderOptions.h:58
otb::ExtendedFilenameToReaderOptions::m_Options
OptionType m_Options
Definition: otbExtendedFilenameToReaderOptions.h:116
otb::ExtendedFilenameToReaderOptions::OptionType
Definition: otbExtendedFilenameToReaderOptions.h:69
otb::ExtendedFilenameToReaderOptions::FNameHelperType
Superclass FNameHelperType
Definition: otbExtendedFilenameToReaderOptions.h:62
otb::ExtendedFilenameToReaderOptions::~ExtendedFilenameToReaderOptions
~ExtendedFilenameToReaderOptions() override
Definition: otbExtendedFilenameToReaderOptions.h:108
otb::ExtendedFilenameToReaderOptions::OptionType::skipRpcTag
std::pair< bool, bool > skipRpcTag
Definition: otbExtendedFilenameToReaderOptions.h:77
otb::ExtendedFilenameToReaderOptions::MapType
FNameHelperType::OptionMapType MapType
Definition: otbExtendedFilenameToReaderOptions.h:65
otb::ExtendedFilenameToReaderOptions::OptionType::extGEOMFileName
std::pair< bool, std::string > extGEOMFileName
Definition: otbExtendedFilenameToReaderOptions.h:72