Rapid generics/defaults equivalent classes for Delphi (much faster in XE7+ versions)
How to use
Include Rapid.Generics.pas unit into your project Replace Generics.Collections and Generics.Defaults units to Rapid.Generics in your uses code sections TRapidDictionary/TRapidObjectDictionary
Rapid "inline" TDictionary/TObjectDictionary equivalents with default hash codes and comparers
试了下,有内存泄露,写了个简单的的语句测试,执行报内存错,半成品 procedure TForm63.SpeedButton1Click(Sender: TObject); var i: Integer; tmp: string; dict: TRapidDictionary<Integer, string>; begin dict := TRapidDictionary<Integer, string > .Create; try
dict.Clear; // for I := 1 to 10000 * 10 do begin dict.AddOrSetValue(i, IntToStr(i * 10)); end;
if dict.TryGetValue(100, tmp) then begin Caption := tmp; end else begin Caption := 'not'; end; finally dict.Free; end; end;
----------------------------------------------
-
Z:\testgit\QDAC3>git pull origin master fatal: unable to access 'http://www.qdac.cc:1080/r/QDAC3.git/': Failed to connect to www.qdac.cc port 1080: Connection refused