U_NAMESPACE_BEGIN class Hashtable;
U_NAMESPACE_END
/** Holder of test data and settings. Allows addressing of items by name. * For test cases, names are defined in the "Headers" section. For settings * and info data, names are keys in data. Currently, we return scalar strings * and integers and arrays of strings and integers. Arrays should be deposited * of by the user.
*/ class T_CTEST_EXPORT_API DataMap { public: virtual ~DataMap();
public: /** get the string from the DataMap. Addressed by name * @param key name of the data field. * @return a string containing the data
*/ virtualconst UnicodeString getString(constchar* key, UErrorCode &status) const = 0;
/** get the string from the DataMap. Addressed by name * parses a bundle string into an integer * @param key name of the data field. * @return an integer containing the data
*/ virtual int32_t getInt(constchar* key, UErrorCode &status) const = 0;
/** * Get a signed integer without runtime parsing. * @param key name of the data field. * @param status UErrorCode in/out parameter * @return the integer
*/ virtual int32_t getInt28(constchar* key, UErrorCode &status) const = 0;
/** * Get an unsigned integer without runtime parsing. * @param key name of the data field. * @param status UErrorCode in/out parameter * @return the integer
*/ virtual uint32_t getUInt28(constchar* key, UErrorCode &status) const = 0;
/** * Get a vector of integers without runtime parsing. * @param length output parameter for the length of the vector * @param key name of the data field. * @param status UErrorCode in/out parameter * @return the integer vector, do not delete
*/ virtualconst int32_t *getIntVector(int32_t &length, constchar *key, UErrorCode &status) const = 0;
/** * Get binary data without runtime parsing. * @param length output parameter for the length of the data * @param key name of the data field. * @param status UErrorCode in/out parameter * @return the binary data, do not delete
*/ virtualconst uint8_t *getBinary(int32_t &length, constchar *key, UErrorCode &status) const = 0;
/** get an array of strings from the DataMap. Addressed by name. * The user must dispose of it after usage, using delete. * @param key name of the data field. * @return a string array containing the data
*/ virtualconst UnicodeString* getStringArray(int32_t& count, constchar* key, UErrorCode &status) const = 0;
/** get an array of integers from the DataMap. Addressed by name. * The user must dispose of it after usage, using delete. * @param key name of the data field. * @return an integer array containing the data
*/ virtualconst int32_t* getIntArray(int32_t& count, constchar* key, UErrorCode &status) const = 0;
// ... etc ...
};
// This one is already concrete - it is going to be instantiated from // concrete data by TestData children... class T_CTEST_EXPORT_API RBDataMap : public DataMap{ private:
Hashtable *fData;
¤ Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.0.23Bemerkung:
(vorverarbeitet)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.