19 #include "dcDeclaration.h" 20 #include "dcPackerInterface.h" 40 virtual const DCSwitch *as_switch()
const;
42 const string &get_name()
const;
43 DCField *get_key_parameter()
const;
45 int get_num_cases()
const;
46 int get_case_by_value(
const string &case_value)
const;
50 string get_value(
int case_index)
const;
51 int get_num_fields(
int case_index)
const;
52 DCField *get_field(
int case_index,
int n)
const;
53 DCField *get_field_by_name(
int case_index,
const string &name)
const;
56 bool is_field_valid()
const;
57 int add_case(
const string &value);
58 void add_invalid_case();
63 const DCPackerInterface *apply_switch(
const char *value_data,
size_t length)
const;
65 virtual void output(ostream &out,
bool brief)
const;
66 virtual void write(ostream &out,
bool brief,
int indent_level)
const;
67 void output_instance(ostream &out,
bool brief,
const string &prename,
68 const string &name,
const string &postname)
const;
69 void write_instance(ostream &out,
bool brief,
int indent_level,
70 const string &prename,
const string &name,
71 const string &postname)
const;
73 virtual bool pack_default_value(
DCPackData &pack_data,
bool &pack_error)
const;
75 bool do_check_match_switch(
const DCSwitch *other)
const;
88 bool do_check_match_switch_case(
const SwitchFields *other)
const;
90 void output(ostream &out,
bool brief)
const;
91 void write(ostream &out,
bool brief,
int indent_level)
const;
98 FieldsByName _fields_by_name;
99 bool _has_default_value;
107 bool do_check_match_switch_case(
const SwitchCase *other)
const;
128 CaseFields _case_fields;
133 Fields _nested_fields;
139 CaseFields _current_fields;
144 CasesByValue _cases_by_value;
virtual void output(ostream &out) const
Write a string representation of this instance to <out>.
This is our own Panda specialization on the default STL map.
This is a block of data that receives the results of DCPacker.
A single field of a Distributed Class, either atomic or molecular.
void write(ostream &out, int indent_level) const
Write a string representation of this instance to <out>.
This represents a switch statement, which can appear inside a class body and represents two or more a...
This is our own Panda specialization on the default STL vector.
Represents the type specification for a single parameter within a field specification.
This is a common interface for a declaration in a DC file.
This class generates an arbitrary hash number from a sequence of ints.
This defines the internal interface for packing values into a DCField.