|
|
|
@@ -73,6 +73,8 @@ type |
|
|
|
destructor Destroy; override; |
|
|
|
|
|
|
|
function GetEnumerator: TSectionEnumerator; |
|
|
|
procedure Clear; |
|
|
|
procedure Assign(Source: TutlMCFSection); |
|
|
|
|
|
|
|
property ValueCount: integer read GetValueCount; |
|
|
|
property ValueNameAt[Index: integer]: string read GetValueName; |
|
|
|
@@ -294,6 +296,28 @@ begin |
|
|
|
result := TSectionEnumerator.Create(FSections); |
|
|
|
end; |
|
|
|
|
|
|
|
procedure TutlMCFSection.Clear; |
|
|
|
begin |
|
|
|
ClearSections; |
|
|
|
ClearValues; |
|
|
|
end; |
|
|
|
|
|
|
|
procedure TutlMCFSection.Assign(Source: TutlMCFSection); |
|
|
|
var |
|
|
|
ms: TMemoryStream; |
|
|
|
begin |
|
|
|
Clear; |
|
|
|
ms:= TMemoryStream.Create; |
|
|
|
try |
|
|
|
Source.SaveData(ms, '', leNone); |
|
|
|
ms.Position:= 0; |
|
|
|
LoadData(ms, leNone, 0); |
|
|
|
finally |
|
|
|
FreeAndNil(ms); |
|
|
|
end; |
|
|
|
end; |
|
|
|
|
|
|
|
|
|
|
|
function TutlMCFSection.GetSectionCount: integer; |
|
|
|
begin |
|
|
|
Result:= FSections.Count; |
|
|
|
|