https://docwiki.embarcadero.com/Libraries/Sydney/en/System.Classes.TReader
InsertComponent RegisterClasses ObjectTextToBinary
ReadComponent WriteComponent
VclRtl
ReadComponentRes
WriteComponentRes
TFileStream – 處理文件。
TStringStream - 內存中的字符串操作。
TMemoryStream - 使用內存緩衝區。
TWinSocketStream - 通過套接字連接讀取和寫入。
TOleStream - 使用 COM 接口進行讀寫。
TBufferedFileStream
TMemoryStream 是一種在動態內存中存儲數據的流。
TWinSocketStream 是一個流,它為應用程序提供讀寫套接字連接的服務。
TOleStream 通過 OLE 對象提供的流接口來讀寫信息。TActiveXControl
System.BlockWrite - RAD Studio API Documentation
https://docwiki.embarcadero.com/RADStudio/Sydney/en/Structured_Types_(Delphi)
Standard Routines and Input-Output
https://docwiki.embarcadero.com/RADStudio/Sydney/en/Standard_Routines_and_Input-Output
System.TTextRec
https://docwiki.embarcadero.com/Libraries/Sydney/en/System.TTextRec
System.SysUtils.TSearchRec
Using the Eof and Bof Properties
System.TFileRec - RAD Studio API Documentation
System.Net.Mime.TMultipartFormData Form data encoded as a MIME multipart message following the HTML 4 standard.
https://docwiki.embarcadero.com/RADStudio/Sydney/en/Using_an_HTTP_Client
https://docwiki.embarcadero.com/Libraries/Sydney/en/System.Net.Mime.TMultipartFormData
delphi ObjectTextToBinary ComponentToString
ObjectBinaryToText ObjectTextToBinary ObjectResourceToText ObjectTextToResource ReadResHeader
ComponentToString (Delphi) - RAD Studio Code Examples
System.Classes.ObjectTextToBinary - Embarcadero DocWiki
TObjectTextEncoding
var
m : TMemoryStream;
f : TFileStream;
begin
f := TFileStream.Create('c:\testdfm.abnt',fmOpenRead);
m := TMemoryStream.Create;
try
ObjectTextToBinary(f,m);
m.Position := 0;
dxRibbon1.Free;
form2.DestroyComponents;
m.ReadComponent(self);
dxRecalculateNonClientPart(Handle);
finally
m.Free;
f.Free;
end;
end;
BinStream:TMemoryStream;
StrStream: TStringStream;
BinStream := TMemoryStream.Create;
StrStream := TStringStream.Create(s);
BinStream.WriteComponent(組件);
BinStream.Seek(0, soFromBeginning);
ObjectBinaryToText(BinStream, StrStream);
StrStream.Seek(0, soFromBeginning);
結果:= StrStream.DataString;
StrStream.Free;
BinStream.Free
function StringToComponentProc(Value: string): TComponent;
StrStream: TStringStream;
BinStream:TMemoryStream;
StrStream := TStringStream.Create(Value);
BinStream := TMemoryStream.Create;
ObjectTextToBinary(StrStream, BinStream);
BinStream.Seek(0, soFromBeginning);
結果:= BinStream.ReadComponent(nil);
Memo1.Text:= ComponentToStringProc(ScrollBar1);
ScrollBar1.Free;
ScrollBar1:= (StringToComponentProc(Memo1.Text) as TMyScrollBar);
ScrollBar1.Parent:= Form1;
ScrollBar1.Visible:= TRUE;
程序 TForm1.FormCreate(Sender: TObject);
ScrollBar1:= TMyScrollBar.Create(Form1);
ScrollBar1.Parent:= Form1;
ScrollBar1.Visible:= TRUE;
ScrollBar1.Top:= 48;
ScrollBar1.Left:= 250;
ScrollBar1.Name:= 'Ricksbar';
https://flylib.com/books/en/2.37.1/core_library_classes.html
沒有留言:
張貼留言