test with internaljsonobject

This commit is contained in:
Daniele Teti 2020-09-10 23:48:34 +02:00
parent a0aea669ee
commit af4dc3119f

View File

@ -464,13 +464,26 @@ begin
AJsonObject.A[AName].Add(AValue.GetArrayElement(I).AsInt64); AJsonObject.A[AName].Add(AValue.GetArrayElement(I).AsInt64);
tkFloat: tkFloat:
AJsonObject.A[AName].Add(AValue.GetArrayElement(I).AsExtended); AJsonObject.A[AName].Add(AValue.GetArrayElement(I).AsExtended);
tkClass:
begin
InternalObjectToJsonObject(
AValue.GetArrayElement(I).AsObject,
AJsonObject.A[AName].AddObject,
TMVCSerializationType.stDefault,
[],
nil,
nil,
nil);
end;
else else
begin
raise EMVCSerializationException.CreateFmt raise EMVCSerializationException.CreateFmt
('Cannot serialize property or field "%s" of TypeKind tkArray or tkDynArray.', [AName]); ('Cannot serialize property or field "%s" of TypeKind tkArray or tkDynArray.', [AName]);
end; end;
end; end;
end; end;
end; end;
end;
tkUnknown: tkUnknown:
raise EMVCSerializationException.CreateFmt raise EMVCSerializationException.CreateFmt