Post Reply 
New Version: 2018.02.12 1.4.1.13441
02-22-2018, 08:33 PM (This post was last modified: 02-22-2018 08:37 PM by Han.)
Post: #34
RE: New Version: 2018.02.12 1.4.1.13441
If you have a collection of different "structures" for records, you can declare them with constants:

RecordType1:={ { "Name", "DOB", "SS#", "Gender" } };
RecordType2:={ { "Name", "Salary", "DateOfHire"} };
...

To "declare" a new record, use:

AFiles("NewRecord"):=RecordType1;

which creates an app variable named NewRecord whose data structure is RecordType1.

You can even expand upon the post above and add in a second list that contains the data types, and have the records actually start at the third position onward within each record list.

So even though HPPPL does not have classes and structures, you can implement them fairly easily.

Graph 3D | QPI | SolveSys
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: New Version: 2018.02.12 1.4.1.13441 - Han - 02-22-2018 08:33 PM



User(s) browsing this thread: 1 Guest(s)