Class TOrderedItem

DescriptionHierarchyFieldsMethodsProperties

Unit

Declaration

type TOrderedItem = class(TCollectionItem)

Description

TOrderedItem is designed to allow TOrderedCollection to identify changed and new items during TOrderedCollection.Assign.

Hierarchy

Overview

Fields

Private FForeignId: integer;
Private FAlwaysAssignForeignId: boolean;
Private FInsertionNeeded: boolean;

Methods

Protected function Model: TBaseModel;
Protected function IsSame(AnotherItem: TOrderedItem): boolean; virtual; abstract;
Protected procedure InvalidateModel; virtual;
Protected procedure SetBooleanProperty(var AField: boolean; const NewValue: boolean);
Protected procedure SetIntegerProperty(var AField: Integer; const NewValue: Integer);
Protected procedure SetRealProperty(var AField: double; const NewValue: double);
Protected procedure SetCaseSensitiveStringProperty(var AField: string; const NewValue: string);
Protected procedure SetCaseInsensitiveStringProperty(var AField: string; NewValue: string);
Public procedure Assign(Source: TPersistent); override;
Public constructor Create(Collection: TCollection); override;

Properties

Protected property AlwaysAssignForeignId: boolean read FAlwaysAssignForeignId write FAlwaysAssignForeignId;

Description

Fields

Private FForeignId: integer;

FForeignId is the ID of a TOrderedItem that has been assigned to this TOrderedItem. If no TOrderedItem has been assigned to it, FForeignId is -1.

Private FAlwaysAssignForeignId: boolean;

See AlwaysAssignForeignId.

Private FInsertionNeeded: boolean;
 

Methods

Protected function Model: TBaseModel;
 
Protected function IsSame(AnotherItem: TOrderedItem): boolean; virtual; abstract;

IsSame tests whether another TOrderedItem is identical to the current one.

Protected procedure InvalidateModel; virtual;

InvalidateModel invalidates the model.

See also
InvalidateModel
InvalidateModel invalidates the model.
Invalidate
Call Invalidate to indicate that the model has changed in some important respect.
Protected procedure SetBooleanProperty(var AField: boolean; const NewValue: boolean);
 
Protected procedure SetIntegerProperty(var AField: Integer; const NewValue: Integer);
 
Protected procedure SetRealProperty(var AField: double; const NewValue: double);
 
Protected procedure SetCaseSensitiveStringProperty(var AField: string; const NewValue: string);
 
Protected procedure SetCaseInsensitiveStringProperty(var AField: string; NewValue: string);
 
Public procedure Assign(Source: TPersistent); override;

Assign copies Source to the current TOrderedItem. It will also assign FForeignId if AlwaysAssignForeignId is True or IsSame returns False.

Public constructor Create(Collection: TCollection); override;

Create creates and instance of TOrderedItem and sets FForeignId to -1.

Properties

Protected property AlwaysAssignForeignId: boolean read FAlwaysAssignForeignId write FAlwaysAssignForeignId;

if AlwaysAssignForeignId is True, FForeignId will always be assigned during Assign. Otherwise, FForeignId will only be assigned if IsSame returns False. AlwaysAssignForeignId is set to True in TModflowParamItem and TGlobalVariableItem.


Generated by PasDoc 0.12.1 on 2013-05-13 15:41:54