14 #ifndef DCARRAYPARAMETER_H 15 #define DCARRAYPARAMETER_H 37 virtual bool is_valid()
const;
40 int get_array_size()
const;
49 virtual void output_instance(std::ostream &out,
bool brief,
const std::string &prename,
50 const std::string &name,
const std::string &postname)
const;
53 bool &pack_error,
bool &range_error)
const;
55 bool &pack_error,
bool &range_error)
const;
57 virtual void unpack_string(
const char *data,
size_t length,
size_t &p,
58 std::string &value,
bool &pack_error,
bool &range_error)
const;
59 virtual void unpack_blob(
const char *data,
size_t length,
size_t &p,
60 vector_uchar &value,
bool &pack_error,
bool &range_error)
const;
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
virtual void generate_hash(HashGenerator &hashgen) const
Accumulates the properties of this type into the hash.
This is a block of data that receives the results of DCPacker.
virtual bool do_check_match_array_parameter(const DCArrayParameter *other) const
Returns true if this field matches the indicated array parameter, false otherwise.
This represents a class (or struct) object used as a parameter itself.
This is the most fundamental kind of parameter type: a single number or string, one of the DCSubatomi...
virtual void unpack_blob(const char *data, size_t length, size_t &p, vector_uchar &value, bool &pack_error, bool &range_error) const
Unpacks the current numeric or string value from the stream.
virtual bool pack_default_value(DCPackData &pack_data, bool &pack_error) const
Packs the field's specified default value (or a sensible default if no value is specified) into the s...
virtual DCPackerInterface * get_nested_field(int n) const
Returns the DCPackerInterface object that represents the nth nested field.
virtual bool do_check_match_simple_parameter(const DCSimpleParameter *other) const
Returns true if this field matches the indicated simple parameter, false otherwise.
virtual DCParameter * append_array_specification(const DCUnsignedIntRange &size)
Returns the type represented by this_type[size].
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
Represents the type specification for a single parameter within a field specification.
This represents an array of some other kind of object, meaning this parameter type accepts an arbitra...
This class generates an arbitrary hash number from a sequence of ints.
virtual bool do_check_match_class_parameter(const DCClassParameter *other) const
Returns true if this field matches the indicated class parameter, false otherwise.
virtual void unpack_string(const char *data, size_t length, size_t &p, std::string &value, bool &pack_error, bool &range_error) const
Unpacks the current numeric or string value from the stream.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
virtual int calc_num_nested_fields(size_t length_bytes) const
This flavor of get_num_nested_fields is used during unpacking.
virtual void pack_string(DCPackData &pack_data, const std::string &value, bool &pack_error, bool &range_error) const
Packs the indicated numeric or string value into the stream.
virtual void pack_blob(DCPackData &pack_data, const vector_uchar &value, bool &pack_error, bool &range_error) const
Packs the indicated numeric or string value into the stream.
virtual bool validate_num_nested_fields(int num_nested_fields) const
After a number of fields have been packed via push() .
This defines the internal interface for packing values into a DCField.