15#include "matpack_concepts.h"
34template <
typename OutputStream,
typename Container>
36 for (
typename Container::const_iterator it = container.begin();
37 it != container.end();
67 [[nodiscard]] Index
nelem()
const;
74 [[nodiscard]]
bool is_output(Index var)
const;
79 void print(ostream& os,
const String& indent)
const;
91 [[nodiscard]] std::shared_ptr<Workspace>
workspace()
const;
99 [[nodiscard]] std::pair<ArrayOfIndex, ArrayOfIndex>
get_global_inout()
const;
102 std::weak_ptr<Workspace>
ws;
138 bool internal =
false);
140 [[nodiscard]] Index
Id()
const {
return mid; }
194 void print(ostream& os,
const String& indent)
const;
ArrayOfAgenda deepcopy_if(Workspace &ws, const ArrayOfAgenda &agendas)
Same as Agenda member method but for an entire array.
void PrintWsvNames(OutputStream &outstream, const Workspace &ws, const Container &container)
Print list of WSV names to output stream.
This file contains the definition of Array.
bool mchecked
Flag indicating that the agenda was checked for consistency.
bool has_same_origin(const Workspace &ws2) const
void print(ostream &os, const String &indent) const
Print an agenda.
std::weak_ptr< Workspace > ws
const ArrayOfIndex & get_output2push() const
void append(const String &methodname, const TokVal &keywordvalue)
Appends methods to an agenda.
String name() const
Agenda name.
void execute(Workspace &ws_in) const
Execute an agenda.
bool has_method(const String &methodname) const
Check if method is in Agenda.
void set_workspace(Workspace &x)
bool is_output(Index var) const
Check if given variable is agenda output.
bool main_agenda
Is set to true if this is the main agenda.
void set_methods(const Array< MRecord > &ml)
void check(Workspace &ws_in, const Verbosity &verbosity)
Checks consistency of an agenda.
bool is_input(Workspace &ws_in, Index var) const
Check if given variable is agenda input.
const ArrayOfIndex & get_output2dup() const
Agenda & operator=(const Agenda &x)
std::pair< ArrayOfIndex, ArrayOfIndex > get_global_inout() const
Get index lists of global input and output variables from agenda_data of this agenda.
void set_outputs_to_push_and_dup(const Verbosity &verbosity)
Retrieve indexes of all input and output WSVs.
void push_back(const MRecord &n)
Append a new method to end of list.
Agenda deepcopy_if(Workspace &) const
Creates a deep copy of the agenda if necessary (i.e., different workspace)!
friend ostream & operator<<(ostream &os, const Agenda &a)
Output operator for Agenda.
void resize(Index n)
Resize the method list.
ArrayOfIndex moutput_push
std::shared_ptr< Workspace > workspace() const
Agenda(const Agenda &x)=default
void set_name(const String &nname)
Set agenda name.
const Array< MRecord > & Methods() const
bool is_main_agenda() const
Index nelem() const
Return the number of agenda elements.
This can be used to make arrays out of anything.
Agenda mtasks
An agenda, which can be given in the controlfile instead of keywords.
const ArrayOfIndex & In() const
ArrayOfIndex minput
Input workspace variables.
void set_workspace(Workspace &x)
MRecord & operator=(const MRecord &x)
Assignment operator for MRecord.
const TokVal & SetValue() const
friend ostream & operator<<(ostream &os, const MRecord &a)
Output operator for MRecord.
const Agenda & Tasks() const
void print(ostream &os, const String &indent) const
Print an MRecord.
bool minternal
Flag if this method is called internally by the engine.
MRecord deepcopy_if(Workspace &) const
Creates a deep copy of the method if necessary (i.e., different workspace)!
ArrayOfIndex moutput
Output workspace variables.
void ginput_only(ArrayOfIndex &ginonly) const
Get list of generic input only WSVs.
bool isInternal() const
Indicates the origin of this method.
const ArrayOfIndex & Out() const
MRecord(const MRecord &x)=default
TokVal msetvalue
Keyword value for Set methods.
void PrintWsvName(OutputStream &outstream, Index i) const
Print WSV name to output stream.
Helper macros for debugging.
Declarations having to do with the four output streams.
This file contains the definition of String, the ARTS string class.
This file contains the Workspace class.