1 #ifndef __value_h__
2 #define __value_h__
3
5
7 {
12 };
13
15 {
20
21 #define FLOAT_VALUE double 22
24 {
31 T_DATE,
// INT64 - contains a 64-bit value representing the number of 100-nanosecond intervals since January 1, 1601 (UTC), a.k.a. FILETIME on Windows 32 T_CURRENCY,
// INT64 - 14.4 fixed number. E.g. dollars = int64 / 10000; 33 T_LENGTH,
// length units, value is int or float, units are VALUE_UNIT_TYPE 37 T_BYTES,
// sequence of bytes - e.g. image data 38 T_OBJECT,
// scripting object proxy (TISCRIPT/SCITER) 39 T_DOM_OBJECT // DOM object (CSSS!), use get_object_data to get HELEMENT 40 };
41
43 {
44 UT_EM = 1,
//height of the element's font. 45 UT_EX = 2,
//height of letter 'x' 47 UT_SP = 4,
//%% "springs", a.k.a. flex units 51 UT_IN = 8,
//inches (1 inch = 2.54 centimeters). 54 UT_PT = 11,
//points (1 point = 1/72 inches). 55 UT_PC = 12,
//picas (1 pica = 12 points). 60 };
61
63 {
67 DT_UTC = 0x10,
// T_DATE is known to be UTC. Otherwise it is local date/time 68 };
69
70 // Sciter or TIScript specific
72 {
79 };
80
81 // Sciter or TIScript specific
83 {
88 };
89
90 // Native functor
93
94
100
105
110
115
122
126 UINT SCAPI
ValueType(
const VALUE* pval, UINT* pType, UINT* pUnits );
127
133
139
144
150
155
160
165
170
175
182
190
198
208
213
220
222
235
244
246 {
251
252 };
253
261
270 UINT SCAPI
ValueFromString(
VALUE* pval, LPCWSTR str, UINT strLength,
/*VALUE_STRING_CVT_TYPE*/ UINT how );
271
283
296 VOID* tag = NULL );
297
299
300
301 #if defined(__cplusplus) && !defined(__value_hpp__)
302
304
305 #pragma warning( push )
306 #pragma warning(disable:4786) //identifier was truncated...
307
308 namespace json
309 {
313 }
314
315 #endif //defined(__cplusplus)
316
317 #endif
BOOL SCAPI ValueIsNativeFunctor(const VALUE *pval)
UINT SCAPI ValueToString(VALUE *pval, UINT how)
UINT SCAPI ValueType(const VALUE *pval, UINT *pType, UINT *pUnits)
UINT SCAPI ValueClear(VALUE *pval)
UINT SCAPI ValueInt64DataSet(VALUE *pval, INT64 data, UINT type, UINT units)
UINT SCAPI ValueBinaryDataSet(VALUE *pval, LPCBYTE pBytes, UINT nBytes, UINT type, UINT units)
UINT SCAPI ValueStringDataSet(VALUE *pval, LPCWSTR chars, UINT numChars, UINT units)
UINT SCAPI ValueNthElementKey(const VALUE *pval, INT n, VALUE *pretval)
std::basic_string< char > astring
UINT SCAPI ValueFromString(VALUE *pval, LPCWSTR str, UINT strLength, UINT how)
UINT SCAPI ValueEnumElements(const VALUE *pval, KeyValueCallback *penum, LPVOID param)
UINT SCAPI ValueIsolate(VALUE *pdst)
UINT SCAPI ValueNthElementValue(const VALUE *pval, INT n, VALUE *pretval)
UINT SCAPI ValueIntData(const VALUE *pval, INT *pData)
VOID NATIVE_FUNCTOR_RELEASE(VOID *tag)
VOID NATIVE_FUNCTOR_INVOKE(VOID *tag, UINT argc, const VALUE *argv, VALUE *retval)
UINT SCAPI ValueStringData(const VALUE *pval, LPCWSTR *pChars, UINT *pNumChars)
UINT SCAPI ValueFloatData(const VALUE *pval, FLOAT_VALUE *pData)
UINT SCAPI ValueNativeFunctorSet(VALUE *pval, NATIVE_FUNCTOR_INVOKE *pinvoke, NATIVE_FUNCTOR_RELEASE *prelease=NULL, VOID *tag=NULL)
UINT SCAPI ValueNthElementValueSet(VALUE *pval, INT n, const VALUE *pval_to_set)
UINT SCAPI ValueGetValueOfKey(const VALUE *pval, const VALUE *pkey, VALUE *pretval)
BOOL SC_CALLBACK KeyValueCallback(LPVOID param, const VALUE *pkey, const VALUE *pval)
UINT SCAPI ValueElementsCount(const VALUE *pval, INT *pn)
const std::vector< sciter::string > & argv()
json parsing/emission, it parses as if token '{' already recognized
UINT SCAPI ValueCompare(const VALUE *pval1, const VALUE *pval2)
UINT SCAPI ValueSetValueToKey(VALUE *pval, const VALUE *pkey, const VALUE *pval_to_set)
UINT SCAPI ValueFloatDataSet(VALUE *pval, FLOAT_VALUE data, UINT type, UINT units)
json literal parsing/emission
UINT SCAPI ValueInt64Data(const VALUE *pval, INT64 *pData)
UINT SCAPI ValueCopy(VALUE *pdst, const VALUE *psrc)
x-json parsing/emission, date is emitted as ISO8601 date literal, currency is emitted in the form DDD...
std::basic_string< WCHAR > string
UINT SCAPI ValueInvoke(const VALUE *pval, VALUE *pthis, UINT argc, const VALUE *argv, VALUE *pretval, LPCWSTR url)
UINT SCAPI ValueIntDataSet(VALUE *pval, INT data, UINT type, UINT units)
simple conversion of terminal values
UINT SCAPI ValueInit(VALUE *pval)
value.hpp VALUE C++ wrapper
UINT SCAPI ValueBinaryData(const VALUE *pval, LPCBYTE *pBytes, UINT *pnBytes)