[Overview][Constants][Types][Classes][Index] | Reference for unit 'DynHashArray' (#lcl)

# TDynHashArray.Add

Adds an item to the set/array.

## Declaration

Source position: dynhasharray.pp line 105

`public procedure TDynHashArray.Add(`
`Item: Pointer`
`);`

## Description

An example:

    uses
      {$IFDEF UNIX}{$IFDEF UseCThreads}
     cthreads,
      {$ENDIF}{$ENDIF}
      Classes, dynhasharray,strings;

    var
      A:TDynHashArray;
      s:pchar;
    begin
    A:=TDynHashArray.Create;
    s:=StrNew ('u');
    A.Add(s);
    if A.Contains(s) then
      writeln('1:it contains s.');
      writeln('1:count:',A.Count);
    A.Clear;

    if A.Contains(s) then
      writeln('2:it contains s.');
      writeln('2:count:',A.Count);
    ReadLn;
    StrDispose(s);

The latest version of this document can be found at lazarus-ccr.sourceforge.net .