Official websites use .gov
A .gov website belongs to an official government organization in the United States.

Secure .gov websites use HTTPS
A lock ( ) or https:// means you’ve safely connected to the .gov website. Share sensitive information only on official, secure websites.

Isis Developer Reference
PvlToPvlTranslationManager.h
Go to the documentation of this file.
1#ifndef PvlToPvlTranslationManager_h
2#define PvlToPvlTranslationManager_h
7
8/* SPDX-License-Identifier: CC0-1.0 */
10
11#include <fstream>
12#include <string>
13
14#include "FileName.h"
15
16namespace Isis {
17 class Pvl;
18 class PvlContainer;
19 class PvlKeyword;
65 public:
66 PvlToPvlTranslationManager(const QString &transFile);
67
68 PvlToPvlTranslationManager(std::istream &transStrm);
69
70 PvlToPvlTranslationManager(Pvl &inputLabel,
71 const QString &transFile);
72
73 PvlToPvlTranslationManager(Pvl &inputLabel,
74 std::istream &transStrm);
75
77
78 // Attempt to translate the requested output name to output value
79 // using the input name and value/default value
80 virtual QString Translate(QString translationGroupName, int findex = 0);
81
82 // Translate all translation table groups which contain "Auto"
83 void Auto(Pvl &outputLabel);
84 void Auto(Pvl &inputLabel, Pvl &outputLabel);
85
86 // Return the ith input value associated with a output name
87 virtual const PvlKeyword &InputKeyword(const QString translationGroupName) const;
88
89 // Return true if the input lable contains the translated group and key names
90 virtual bool InputHasKeyword(const QString translationGroupName);
91
92 void SetLabel(Pvl &inputLabel);
93
94 protected:
95 virtual PvlKeyword DoTranslation(const QString translationGroupName);
96 virtual const PvlContainer *GetContainer(const PvlKeyword &inputGroup) const;
97 virtual PvlContainer *CreateContainer(const QString translationGroupName, Pvl &pvl);
98 private:
99 Pvl p_fLabel;
100 };
101};
102
103#endif
LabelTranslationManager()
Constructs a default LabelTranslationManager.
Definition LabelTranslationManager.cpp:25
virtual PvlContainer * CreateContainer(const QString translationGroupName, Pvl &pvl)
Create the requsted container and any containers above it and return a reference to the container.
Definition PvlToPvlTranslationManager.cpp:352
virtual ~PvlToPvlTranslationManager()
Destroys the TranslationManager object.
Definition PvlToPvlTranslationManager.cpp:80
virtual PvlKeyword DoTranslation(const QString translationGroupName)
Translate the requested output name to output values using the input name and values or default value...
Definition PvlToPvlTranslationManager.cpp:142
virtual const PvlKeyword & InputKeyword(const QString translationGroupName) const
Returns the ith input value associated with the output name argument.
Definition PvlToPvlTranslationManager.cpp:231
virtual const PvlContainer * GetContainer(const PvlKeyword &inputGroup) const
Return a container from the input label according tund.
Definition PvlToPvlTranslationManager.cpp:303
virtual QString Translate(QString translationGroupName, int findex=0)
Returns a translated value.
Definition PvlToPvlTranslationManager.cpp:107
void SetLabel(Pvl &inputLabel)
Definition PvlToPvlTranslationManager.cpp:84
virtual bool InputHasKeyword(const QString translationGroupName)
Indicates if the input keyword corresponding to the output name exists in the label.
Definition PvlToPvlTranslationManager.cpp:282
PvlToPvlTranslationManager(const QString &transFile)
Constructs and initializes a TranslationManager object from given the Pvl translation file.
Definition PvlToPvlTranslationManager.cpp:31
void Auto(Pvl &outputLabel)
Automatically translate all the output names found in the translation table If a output name does not...
Definition PvlToPvlTranslationManager.cpp:199
This is free and unencumbered software released into the public domain.
Definition Apollo.h:16