TypedString :: assign - Assign typed string value
Several ways of assigning string values to a typed string are supported. When assigning a typed string by passing a string value, the string type is determined from the string value passed.
Implementation overview
- Create copy for typed string
TypedString :: assign ( cTypedString ) - Create typed string from string
TypedString :: assign ( cString )
Implementation details
-
Create copy for typed string
odaba::TypedString & TypedString  :: assign ( odaba::TypedString &cTypedString )
The function duplicates the string value and the type definition from the typed string passed in cTypedString. When the type definition is valid, the string will be converted into the internal format.
- cTypedString
- Typed string
A typed string string contains data in the object interchange format (OIF). Typed strings are used for passing key or instance values.
to list
- cTypedString
- Typed string
-
Create typed string from string
odaba::TypedString & TypedString  :: assign ( odaba::String &cString )
The function creates a typed string from the string value passed in cString. The string is copied to the typed string. The string type is determined for the string value. When the string does not correspond to any type, the function throws an exception.
The string value is not validated when creating the type string, but will be validated later on, when applying to a complex data type.
- cString
- Constant string object
When iPosition exceeds the string length or when the string is empty, the the function returns -1 (lower).
to list
- cString
- Constant string object