Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Update hives.pas
polymorphesizing
  • Loading branch information
crutchy- committed Oct 31, 2014
1 parent 06f0ac5 commit 9298728
Showing 1 changed file with 18 additions and 7 deletions.
25 changes: 18 additions & 7 deletions hives.pas
Expand Up @@ -37,20 +37,22 @@ kCellPermissions = record


kHive_ancestor = class(TFPHashObject)
private
permissions : kCellPermissions;
cell_type : kCellType;
cell_properties : kCellProperties;

property items[index: string]: string;

procedure add(index: string; aValue: string);virtual;abstract;
procedure del(index: string);virtual;abstract;

protected
function getItem(index: string): string;virtual;abstract;
procedure setItem(index: string; aValue: string);virtual;abstract;

public
constructor Create; virtual;
public
procedure add(index: string; aValue: string);virtual;abstract;
procedure del(index: string);virtual;abstract;
function to_stream: string;virtual;abstract;
procedure from_stream(aStream: string);virtual;abstract;
public
property items[index: string]: string read getItem write setItem; default;
end;

kHash_hive = class(kHive_ancestor)
Expand Down Expand Up @@ -104,6 +106,15 @@ eHive_error = class(Exception);
implementation
uses strutils, sha1, kUtils, tanks;

{ kHive_ancestor }

constructor kHive_ancestor.Create;
begin
inherited;
end;

{ kHive_cluster }

function kHive_cluster.add_list_hive(name: string; permissions: kCellPermissions): boolean;
var hive: kStringList_hive;
begin
Expand Down

0 comments on commit 9298728

Please sign in to comment.