Loading...
Searching...
No Matches
QoreDataField.qc.dox.h
// -*- mode: c++; indent-tabs-mode: nil -*-
// assume local scope for variables, do not use "$" signs
// require type definitions everywhere
// enable all warnings
namespace DataProvider {
class QoreDataField : public AbstractDataField {
public:
protected:
string name;
string display_name;
*string short_desc;
*string desc;
AbstractDataProviderType type;
auto example_value;
public:
constructor(hash<auto> h);
constructor(Qore::Reflection::TypedHashMember mem);
constructor(string name, *string desc, Type type, auto default_value, *softlist<auto> allowed_values, *bool multiselect, *bool allowed_values_creatable);
constructor(string name, *string desc, AbstractDataProviderType type, auto default_value, *softlist<auto> allowed_values, *bool multiselect, *bool allowed_values_creatable);
string getName();
string getDisplayName();
*string getShortDescription();
*string getDescription();
AbstractDataProviderType getType();
appendDescription(string separator, string new_desc);
AbstractDataField getSoftType();
AbstractDataField getOrNothingType();
AbstractDataField getMandatoryType();
AbstractDataField updateFieldType(AbstractDataProviderType type);
auto getExampleValue(*hash<string, bool> emap, *string fname);
hash<DataFieldInfo> getConfigInfo();
protected:
AbstractDataField getNewFieldType(AbstractDataProviderType new_type);
public:
protected:
static checkString(bool required, hash<auto> h, ...);
public:
protected:
static checkHash(bool required, hash<auto> h, ...);
public:
};
};
DataProvider::AbstractDataField
describes a data type based on a hashdecl
Definition AbstractDataField.qc.dox.h:74
DataProvider::AbstractDataField::multiselect
bool multiselect
Are allowed values elements of the list's element type that indicate what values the list can have?
Definition AbstractDataField.qc.dox.h:82
DataProvider::AbstractDataField::allowed_values_creatable
*bool allowed_values_creatable
Does the field accept values not defined in allowed_values too?
Definition AbstractDataField.qc.dox.h:88
DataProvider::AbstractDataField::default_value
auto default_value
the default value for the field, if any
Definition AbstractDataField.qc.dox.h:79
DataProvider::AbstractDataField::allowed_values
list< hash< AllowedValueInfo > > allowed_values
for enum fields; raw allowed values
Definition AbstractDataField.qc.dox.h:85
DataProvider::AbstractDataProviderType
describes a data type
Definition AbstractDataProviderType.qc.dox.h:139
DataProvider::QoreDataField
describes a data type based on a hashdecl
Definition QoreDataField.qc.dox.h:34
DataProvider::QoreDataField::short_desc
*string short_desc
Short description of the field.
Definition QoreDataField.qc.dox.h:45
DataProvider::QoreDataField::example_value
auto example_value
Example value for the field.
Definition QoreDataField.qc.dox.h:54
DataProvider::QoreDataField::display_name
string display_name
Display name of the field.
Definition QoreDataField.qc.dox.h:42
DataProvider::QoreDataField::constructor
constructor(hash< auto > h)
creates the field from the argument
DataProvider::QoreDataField::desc
*string desc
description of the field
Definition QoreDataField.qc.dox.h:48
DataProvider::QoreDataField::getType
AbstractDataProviderType getType()
returns the type of the field
DataProvider::QoreDataField::getOrNothingType
AbstractDataField getOrNothingType()
returns a field with an "or nothing" type equivalent to the current type
DataProvider::QoreDataField::getName
string getName()
returns the name of the field
DataProvider::QoreDataField::updateFieldType
AbstractDataField updateFieldType(AbstractDataProviderType type)
Updates the field type.
DataProvider::QoreDataField::checkString
static checkString(bool required, hash< auto > h,...)
Checks for string values in a hash.
DataProvider::QoreDataField::constructor
constructor(Qore::Reflection::TypedHashMember mem)
creates the field from the argument
DataProvider::QoreDataField::getDescription
*string getDescription()
returns the description, if any
DataProvider::QoreDataField::getDisplayName
string getDisplayName()
Returns the display name of the field.
DataProvider::QoreDataField::checkHash
static checkHash(bool required, hash< auto > h,...)
Checks for hash values in a hash.
DataProvider::QoreDataField::getShortDescription
*string getShortDescription()
Returns the short description, if any.
DataProvider::QoreDataField::getSoftType
AbstractDataField getSoftType()
returns a field with a "soft" type equivalent to the current type
DataProvider::QoreDataField::constructor
constructor(string name, *string desc, Type type, auto default_value, *softlist< auto > allowed_values, *bool multiselect, *bool allowed_values_creatable)
creates the field from the arguments
DataProvider::QoreDataField::constructor
constructor(string name, *string desc, AbstractDataProviderType type, auto default_value, *softlist< auto > allowed_values, *bool multiselect, *bool allowed_values_creatable)
creates the field from the arguments
DataProvider::QoreDataField::name
string name
Name of the field.
Definition QoreDataField.qc.dox.h:39
DataProvider::QoreDataField::getExampleValue
auto getExampleValue(*hash< string, bool > emap, *string fname)
Returns any example value for the field, if present.
DataProvider::QoreDataField::appendDescription
appendDescription(string separator, string new_desc)
adds a string to the description
DataProvider::QoreDataField::getMandatoryType
AbstractDataField getMandatoryType()
Returns a mandatory (i.e. not "or nothing") field equivalent to the current field.
DataProvider::QoreDataField::type
AbstractDataProviderType type
field type
Definition QoreDataField.qc.dox.h:51
DataProvider::QoreDataField::getNewFieldType
AbstractDataField getNewFieldType(AbstractDataProviderType new_type)
returns a field with the new type
DataProvider::QoreDataField::getConfigInfo
hash< DataFieldInfo > getConfigInfo()
returns information about the field
DataProvider
Qore AbstractDataField class definition.
Definition AbstractDataField.qc.dox.h:27