--- a/trunk/json/json-pac/Functions/JSON_TO_STRUCT/Value/svnobj
+++ b/trunk/json/json-pac/Functions/JSON_TO_STRUCT/Value/svnobj
@@ -1,7 +1,7 @@
-Gx_lù!0…jüo’jOPA‡Šl+System.StringL{f8a58466-d7f6-439f-bbb8-d4600e41d099}ImplementationL{3b83b776-fb25-43b8-99f2-3c507c9143fc}TextDocumentL{f3878285-8e4f-490b-bb1b-9acbb7eb04db}TextLinesL{a5de0b0b-1cb5-4913-ac21-9d70293ec00d}	Id
-longTagText
Ò(*=======================================================================================================Value()ªfound a ":" character, possible next characters are any combination of the following:,{ begin another object&[ begin a new arrayH" or a number or letter: value found°after all { and [ are found, and if any were found, the next thing will be a name stringºloop through until a value is found, incrementing obj_level or array definitions as necessaryÔ========================================================================================================*)œbufferposition:= bufferposition + 1;	//start searching after the ":" character6FOR valueloop:= 1 TO 20 DO †//loop through the next 20 characters (maximum) looking for a valueH	CASE JSONString^[bufferposition] OF		^	ASCII.OPEN_BRACE:// {, beginning of new object 		OpenObject();	*		lookforname:= TRUE;	 b	ASCII.OPEN_BRACKET:	// [, beginning of new array!		OpenArray();"
-	ELSE#*		IF lookforname THEN$¤		//a new object or array was found, and all nested objects have already been looped through, therefore this buffer position must start a new name%î		//there is no value here, so exit this loop, main loop should now continue at the name, and parse its name:value pair&			EXIT;'		END_IF(x		IF (JSONString^[bufferposition] = ASCII.DOUBLE_QUOTE) THEN)l		//value starts with a quote character--quoted string*z			value_start:= bufferposition + 1;	//value follows : and "	+		ELSE,|			value_start:= bufferposition;	//value immediately follows :-‚		FOR j:= value_start TO (value_start+GPL_JSON.MAX_VALUE_SIZE) DO.b			IF (JSONString^[j] = ASCII.DOUBLE_QUOTE)  THEN/d			//end of value is is found at the closing quote0.				value_stop:= j - 1;1°				bufferposition:= j + 1;	//main loop can resume at the next character after the quote2				EXIT;3ü			ELSIF (JSONString^[j] = ASCII.COMMA) OR (JSONString^[j] = ASCII.CLOSE_BRACE) OR (JSONString^[j] = ASCII.CLOSE_BRACKET) THEN4Z			//end of value is is found at , or }, or ]5¨				bufferposition:= j;	//main loop can resume at the next character after the value6			END_IF7l			IF (j = (value_start+GPL_JSON.MAX_VALUE_SIZE)) THEN8z			//no closing quote was found after MAXVALUESIZE characters9&				ErrorHandler();:		END_FOR	;2		//clear previous string<		SysMemSet(=X			pDest:= ADR(NameValue[obj_level].Value), >"			udiValue:= 0, ?`			udiCount:= SIZEOF(NameValue[obj_level].Value)@		);A`		//copy buffer to temporary value (string type)B		SysMemCpy(CR			pSrc:= ADR(JSONString^[value_start]), DV			udiCount:= (value_stop+1) - value_start E
-		);	Fà		findname:= TRUE;		//there is a name:value pair in the NameValue array, check for a match with a local variableG		EXIT;H	END_CASEIEND_FORJInterfaceKL{a9ed5b7e-75c5-4651-af16-d2c27e98cb94}LMETHOD ValueMVARN&	valueloop:		UDINT;O&	lookforname:	BOOL;P	j:				UDINT;QEND_VARÐÐÐEEÐÐ	
+Gx_lu#!0…jüot”N=>ÙH¬ùüSystem.StringL{f8a58466-d7f6-439f-bbb8-d4600e41d099}ImplementationL{3b83b776-fb25-43b8-99f2-3c507c9143fc}TextDocumentL{f3878285-8e4f-490b-bb1b-9acbb7eb04db}TextLinesL{a5de0b0b-1cb5-4913-ac21-9d70293ec00d}	Id
+longTagText
Ò(*=======================================================================================================Value()ªfound a ":" character, possible next characters are any combination of the following:,{ begin another object&[ begin a new arrayH" or a number or letter: value found°after all { and [ are found, and if any were found, the next thing will be a name stringºloop through until a value is found, incrementing obj_level or array definitions as necessaryÔ========================================================================================================*)œbufferposition:= bufferposition + 1;	//start searching after the ":" character†//loop through the next 20 characters (maximum) looking for a valueTWHILE (bufferposition < JSONStringSize) DOH	CASE JSONString^[bufferposition] OF		0	ASCII.CR:	// '$r', skipJ		bufferposition := bufferposition+1;		CONTINUE;0	ASCII.LF:	// '$n', skip 4	ASCII.SPACE:	// ' ', skip!^	ASCII.OPEN_BRACE:// {, beginning of new object" 		OpenObject();	#*		lookforname:= TRUE;$	%b	ASCII.OPEN_BRACKET:	// [, beginning of new array&		OpenArray();'
+	ELSE(*		IF lookforname THEN)¤		//a new object or array was found, and all nested objects have already been looped through, therefore this buffer position must start a new name*î		//there is no value here, so exit this loop, main loop should now continue at the name, and parse its name:value pair+			EXIT;,		END_IF-x		IF (JSONString^[bufferposition] = ASCII.DOUBLE_QUOTE) THEN.l		//value starts with a quote character--quoted string/x			value_start:= bufferposition + 1;	//value follows : and "02			quotedstring := TRUE;	1		ELSE2|			value_start:= bufferposition;	//value immediately follows :3‚		FOR j:= value_start TO (value_start+GPL_JSON.MAX_VALUE_SIZE) DO4&			IF skipnext THEN5,				skipnext := FALSE;6b			ELSIF (JSONString^[j] = ASCII.BACKSLASH)  THEN7P				// on backslash, escape the next one8*				skipnext := TRUE;9h			ELSIF (JSONString^[j] = ASCII.DOUBLE_QUOTE)  THEN:d			//end of value is is found at the closing quote;.				value_stop:= j - 1;<°				bufferposition:= j + 1;	//main loop can resume at the next character after the quote=				EXIT;>ª			ELSIF ((JSONString^[j] = ASCII.COMMA) OR (JSONString^[j] = ASCII.CLOSE_BRACE) OR (JSONString^[j] = ASCII.CLOSE_BRACKET)) AND NOT quotedstring THEN?Z			//end of value is is found at , or }, or ]@¨				bufferposition:= j;	//main loop can resume at the next character after the valueA			END_IFBl			IF (j = (value_start+GPL_JSON.MAX_VALUE_SIZE)) THENCz			//no closing quote was found after MAXVALUESIZE charactersD&				ErrorHandler();E		END_FOR	F2		//clear previous stringG		SysMemSet(HX			pDest:= ADR(NameValue[obj_level].Value), I"			udiValue:= 0, J`			udiCount:= SIZEOF(NameValue[obj_level].Value)K		);L`		//copy buffer to temporary value (string type)M		SysMemCpy(NR			pSrc:= ADR(JSONString^[value_start]), OV			udiCount:= (value_stop+1) - value_start P
+		);	Qà		findname:= TRUE;		//there is a name:value pair in the NameValue array, check for a match with a local variableR		EXIT;S	END_CASETEND_WHILEUInterfaceVL{a9ed5b7e-75c5-4651-af16-d2c27e98cb94}WMETHOD ValueXVARY&	lookforname:	BOOL;Z	j:				UDINT;["	skipnext:		BOOL;\(	quotedstring:	BOOL;]END_VARÐÐÐEUÐÐ	
 ­8ÚÐ-
ÐÐ	
 ­9ÚÐ-ÐÐ	
 ­?ÚÐ-ÐÐ	
@@ -13,68 +13,85 @@
 ­ˆÚÐ-ÐÐ	
 ­‡ÚÐ-ÐÐ	
 ­†ÚÐ-ÐÐ	
-­…ÚÐ-ÐÐ	
-­HÚÐ-ÐÐ	
+­HÚÐ-ÐÐ	
+­¥ÚÐ-ÐÐ	
 ­IÚÐ-ÐÐ	
 ­KÚÐ-ÐÐ	
-­PÚÐ-ÐÐ	
-­ŒÚÐ-ÐÐ	
-­LÚÐ-ÐÐ	
-­QÚÐ-ÐÐ	
-­RÚÐ- ÐÐ	
-­ÚÐ-!ÐÐ	
+­œÚÐ-ÐÐ	
+­£ÚÐ-ÐÐ	
+­¤ÚÐ-ÐÐ	
+­ ÚÐ-ÐÐ	
+­¡ÚÐ-ÐÐ	
+­¢ÚÐ-ÐÐ	
+­ŸÚÐ- ÐÐ	
+­›ÚÐ-ÐÐ	
+­™ÚÐ-ÐÐ	
+­šÚÐ-ÐÐ	
+­˜ÚÐ-!ÐÐ	
+­ŒÚÐ-"ÐÐ	
+­LÚÐ-#ÐÐ	
+­QÚÐ-$ÐÐ	
+­RÚÐ-%ÐÐ	
+­ÚÐ-&ÐÐ	
 ­MÚÐ-ÐÐ	
-­ŽÚÐ-"ÐÐ	
-­’ÚÐ-#ÐÐ	
-­”ÚÐ-$ÐÐ	
-­ÚÐ-%ÐÐ	
-­ÚÐ-&ÐÐ	
-­‘ÚÐ-'ÐÐ	
+­ŽÚÐ-'ÐÐ	
+­’ÚÐ-(ÐÐ	
+­”ÚÐ-)ÐÐ	
+­ÚÐ-*ÐÐ	
+­ÚÐ-+ÐÐ	
+­‘ÚÐ-,ÐÐ	
 ­SÚÐ-ÐÐ	
-­YÚÐ-(ÐÐ	
-­ZÚÐ-)ÐÐ	
-­[ÚÐ-*ÐÐ	
-­\ÚÐ-+ÐÐ	
-­]ÚÐ-,ÐÐ	
-­^ÚÐ-'ÐÐ	
-­_ÚÐ--ÐÐ	
-­`ÚÐ-.ÐÐ	
-­aÚÐ-/ÐÐ	
-­bÚÐ-0ÐÐ	
-­cÚÐ-1ÐÐ	
-­dÚÐ-2ÐÐ	
-­eÚÐ-3ÐÐ	
-­fÚÐ-4ÐÐ	
-­gÚÐ-0ÐÐ	
-­hÚÐ-5ÐÐ	
-­iÚÐ-2ÐÐ	
-­jÚÐ-6ÐÐ	
-­kÚÐ-7ÐÐ	
-­lÚÐ-8ÐÐ	
-­pÚÐ-9ÐÐ	
-­qÚÐ-6ÐÐ	
-­rÚÐ-:ÐÐ	
+­YÚÐ--ÐÐ	
+­ZÚÐ-.ÐÐ	
+­[ÚÐ-/ÐÐ	
+­µÚÐ-0ÐÐ	
+­\ÚÐ-1ÐÐ	
+­]ÚÐ-2ÐÐ	
+­^ÚÐ-,ÐÐ	
+­_ÚÐ-3ÐÐ	
+­´ÚÐ-4ÐÐ	
+­²ÚÐ-5ÐÐ	
+­¦ÚÐ-6ÐÐ	
+­³ÚÐ-7ÐÐ	
+­°ÚÐ-8ÐÐ	
+­¸ÚÐ-9ÐÐ	
+­¬ÚÐ-:ÐÐ	
+­­ÚÐ-;ÐÐ	
+­®ÚÐ-<ÐÐ	
+­¯ÚÐ-=ÐÐ	
+­eÚÐ->ÐÐ	
+­fÚÐ-?ÐÐ	
+­gÚÐ-;ÐÐ	
+­hÚÐ-@ÐÐ	
+­iÚÐ-=ÐÐ	
+­jÚÐ-AÐÐ	
+­kÚÐ-BÐÐ	
+­lÚÐ-CÐÐ	
+­pÚÐ-DÐÐ	
+­qÚÐ-AÐÐ	
+­rÚÐ-EÐÐ	
 ­sÚÐ-ÐÐ	
-­tÚÐ-;ÐÐ	
-­uÚÐ-<ÐÐ	
-­vÚÐ-=ÐÐ	
-­wÚÐ->ÐÐ	
-­xÚÐ-?ÐÐ	
-­yÚÐ-@ÐÐ	
-­zÚÐ-AÐÐ	
-­{ÚÐ-BÐÐ	
-­|ÚÐ-=ÐÐ	
-­}ÚÐ-CÐÐ	
-­~ÚÐ-DÐÐ	
-­ÚÐ-EÐÐ	
-­€ÚÐ-FÐÐ	
-­TÚÐ-GÐÐ	
-­‚ÚÐ-HÐÐ	
-­ÚÐ-IÐJKÐEÐÐ	
-­ÚÐ-LÐÐ	
-­ƒÚÐ-MÐÐ	
-­•ÚÐ-NÐÐ	
-­–ÚÐ-OÐÐ	
-­„ÚÐ-PÐÐ	
-­ÚÐ-QÐÐ	
+­tÚÐ-FÐÐ	
+­uÚÐ-GÐÐ	
+­vÚÐ-HÐÐ	
+­wÚÐ-IÐÐ	
+­xÚÐ-JÐÐ	
+­yÚÐ-KÐÐ	
+­zÚÐ-LÐÐ	
+­{ÚÐ-MÐÐ	
+­|ÚÐ-HÐÐ	
+­}ÚÐ-NÐÐ	
+­~ÚÐ-OÐÐ	
+­ÚÐ-PÐÐ	
+­€ÚÐ-QÐÐ	
+­TÚÐ-RÐÐ	
+­‚ÚÐ-SÐÐ	
+­ÚÐ-TÐUVÐEÐÐ	
+­ÚÐ-WÐÐ	
+­ƒÚÐ-XÐÐ	
+­–ÚÐ-YÐÐ	
+­„ÚÐ-ZÐÐ	
+­±ÚÐ-[ÐÐ	
+­¶ÚÐ-\ÐÐ	
+­ÚÐ-]ÐÐ	
 ­ÚÐ-
\ No newline at end of file