如何在 Delphi 中向此类数组添加项目?

How can i add an item to this kind of array in Delphi?

我有一个名为 apps 的变量,我认为它是一个动态数组:

  apps2      = array of app3;

  app3 = class(TRemotable)
  private
    Fname_: appNameType;
    Fid: appIdType;
  published
    property name_: appNameType  Index (IS_UNQL) read Fname_ write Fname_;
    property id:    appIdType    Index (IS_UNQL) read Fid write Fid;
  end;

我有一个 class inititateTechnicalRegistration,我必须将一些值传递给它的应用程序 属性。我该怎么做?

initiateTechnicalRegistration_Type = class(TRemotable)
  private
    FpartnerName: partnerNameType;
    FpartnerOrganizationIdentifier: partnerOrganizationIdentifierType;
    Fapps: apps2;
    Fapps_Specified: boolean;
    Fdescription: descriptionType;
    Fdescription_Specified: boolean;
    FcontactEmail: contactEmailType;
    FrequestedRole: Array_Of_roleType;
    FpublicKey: string;
    FpartnerAddress: partnerAddressType;
    FpartnerAddress_Specified: boolean;
    FpartnerURL: partnerURLType;
    FpartnerURL_Specified: boolean;
    procedure Setapps(Index: Integer; const Aapps2: apps2);
    function  apps_Specified(Index: Integer): boolean;
    procedure Setdescription(Index: Integer; const AdescriptionType: descriptionType);
    function  description_Specified(Index: Integer): boolean;
    procedure SetpartnerAddress(Index: Integer; const ApartnerAddressType: partnerAddressType);
    function  partnerAddress_Specified(Index: Integer): boolean;
    procedure SetpartnerURL(Index: Integer; const ApartnerURLType: partnerURLType);
    function  partnerURL_Specified(Index: Integer): boolean;
  public
    constructor Create; override;
    destructor Destroy; override;
  published
    property partnerName:                   partnerNameType                    Index (IS_UNQL) read FpartnerName write FpartnerName;
    property partnerOrganizationIdentifier: partnerOrganizationIdentifierType  Index (IS_UNQL) read FpartnerOrganizationIdentifier write FpartnerOrganizationIdentifier;
    property apps:                          apps2                              Index (IS_OPTN or IS_UNQL) read Fapps write Setapps stored apps_Specified;
    property description:                   descriptionType                    Index (IS_OPTN or IS_UNQL) read Fdescription write Setdescription stored description_Specified;
    property contactEmail:                  contactEmailType                   Index (IS_UNQL) read FcontactEmail write FcontactEmail;
    property requestedRole:                 Array_Of_roleType                  Index (IS_UNBD or IS_UNQL) read FrequestedRole write FrequestedRole;
    property publicKey:                     string                             Index (IS_UNQL) read FpublicKey write FpublicKey;
    property partnerAddress:                partnerAddressType                 Index (IS_OPTN or IS_UNQL) read FpartnerAddress write SetpartnerAddress stored partnerAddress_Specified;
    property partnerURL:                    partnerURLType                     Index (IS_OPTN or IS_UNQL) read FpartnerURL write SetpartnerURL stored partnerURL_Specified;
  end;

  initiateTechnicalRegistration = class(initiateTechnicalRegistration_Type)
  private
  published
  end;

所以我想在运行时或其他可能的方式从某个 TEdit 传递一些值给它,但我以前从未使用过这些变量,我该怎么做?

initiateTechnicalRegistration1.apps :=

在将项目添加到 Apps 数组的方法代码之后:

// Function return the index allocated in the array
function TForm1.AddApp(Value: App3): Integer;
begin
    Result := Length(FApps);
    SetLength(FApps, Result + 1);
    FApps[Result] := Value;
end;