Qore DataProvider Module Reference  1.0.2
HashDataType.qc.dox.h
1 // -*- mode: c++; indent-tabs-mode: nil -*-
3 
25 // assume local scope for variables, do not use "$" signs
26 // require type definitions everywhere
28 // enable all warnings
29 
30 
32 namespace DataProvider {
34 class HashDataType : public QoreDataType {
35 
36 public:
37 protected:
39  string name;
40 
42  hash<string, AbstractDataField> fields;
43 
44 public:
45 
47  constructor(string name = AutoHashType.getName(), *hash<auto> options) ;
48 
49 
51  constructor(Type base_type, *string name, *hash<auto> options) ;
52 
53 
55  constructor(string name = AutoHashType.getName(), hash<string, AbstractDataField> fields, *hash<auto> options)
56  ;
57 
58 
60  string getName();
61 
62 
64 
70  auto acceptsValue(auto value);
71 
72 
75 
76 
79 
80 
82  *hash<string, AbstractDataField> getFields();
83 
84 
86 
89 
90 
92 
95 
96 };
97 };
DataProvider::AbstractDataProviderType
describes a data type
Definition: AbstractDataProviderType.qc.dox.h:161
DataProvider::AbstractDataField
describes a data type based on a hashdecl
Definition: AbstractDataField.qc.dox.h:49
DataProvider
Qore AbstractDataField class definition.
Definition: AbstractDataField.qc.dox.h:32
DataProvider::HashDataType::getSoftType
AbstractDataProviderType getSoftType()
returns a "soft" type equivalent to the current type
DataProvider::HashDataType::fields
hash< string, AbstractDataField > fields
fields
Definition: HashDataType.qc.dox.h:42
DataProvider::HashDataType::constructor
constructor(string name=AutoHashType.getName(), hash< string, AbstractDataField > fields, *hash< auto > options)
creates the object from the given record description and assigns the name as the type
DataProvider::HashDataType::acceptsValue
auto acceptsValue(auto value)
returns the value if the value can be assigned to the type
DataProvider::HashDataType::constructor
constructor(string name=AutoHashType.getName(), *hash< auto > options)
creates the object and assigns the name as the type
DataProvider::AbstractDataProviderType::options
hash< auto > options
type options
Definition: AbstractDataProviderType.qc.dox.h:169
DataProvider::HashDataType::name
string name
the name of the type
Definition: HashDataType.qc.dox.h:39
DataProvider::HashDataType::getField
*AbstractDataField getField(string name)
returns the given field, if present, or NOTHING if not
DataProvider::HashDataType
describes a data type based on a hash
Definition: HashDataType.qc.dox.h:34
DataProvider::HashDataType::constructor
constructor(Type base_type, *string name, *hash< auto > options)
creates the object and assigns the name as the given name or the base type's name
DataProvider::HashDataType::getName
string getName()
returns the type name
DataProvider::HashDataType::getFields
*hash< string, AbstractDataField > getFields()
returns the fields of the data structure; if any
DataProvider::HashDataType::addField
addField(AbstractDataField field)
adds a field to the type
DataProvider::HashDataType::getOrNothingType
AbstractDataProviderType getOrNothingType()
returns an "or nothing" type equivalent to the current type
DataProvider::QoreDataType
describes a data type based on a Qore data type
Definition: QoreDataType.qc.dox.h:37