2015-10-17 12:00:05 +02:00
|
|
|
unit MainFormU;
|
|
|
|
|
|
|
|
interface
|
|
|
|
|
|
|
|
uses
|
|
|
|
Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants,
|
|
|
|
System.Classes, Vcl.Graphics,
|
2017-05-25 16:57:49 +02:00
|
|
|
Vcl.Controls, Vcl.Forms, Vcl.Dialogs, MVCFramework.Serializer.Commons, BusinessObjectsU, Vcl.StdCtrls;
|
2015-10-17 12:00:05 +02:00
|
|
|
|
|
|
|
type
|
|
|
|
TForm1 = class(TForm)
|
|
|
|
Button1: TButton;
|
|
|
|
Memo1: TMemo;
|
|
|
|
Memo2: TMemo;
|
|
|
|
procedure Button1Click(Sender: TObject);
|
|
|
|
private
|
|
|
|
{ Private declarations }
|
|
|
|
public
|
|
|
|
{ Public declarations }
|
|
|
|
end;
|
|
|
|
|
|
|
|
var
|
|
|
|
Form1: TForm1;
|
|
|
|
|
|
|
|
implementation
|
|
|
|
|
|
|
|
{$R *.dfm}
|
|
|
|
|
|
|
|
|
|
|
|
procedure TForm1.Button1Click(Sender: TObject);
|
|
|
|
var
|
|
|
|
LResponseSession: TParent;
|
|
|
|
begin
|
|
|
|
LResponseSession := Mapper.JSONObjectStringToObject<TParent>(Memo1.Lines.Text);
|
|
|
|
Memo2.Lines.Text := Mapper.ObjectToJSONObjectString(LResponseSession);
|
|
|
|
end;
|
|
|
|
|
|
|
|
end.
|