USING Progress.Lang.*. USING OpenEdge.BusinessLogic.BusinessEntity. BLOCK-LEVEL ON ERROR UNDO, THROW. CLASS Customer INHERITS BusinessEntity: {"customer.i"} DEFINE DATA-SOURCE srcCustomer FOR Customer. CONSTRUCTOR PUBLIC Customer(): DEFINE VAR hDataSourceArray AS HANDLE NO-UNDO EXTENT 1. DEFINE VAR cSkipListArray AS CHAR NO-UNDO EXTENT 1. SUPER(DATASET dsCustomer:HANDLE). /* Data Source for each table in dataset. Should be in table order as defined in DataSet. */ hDataSourceArray[1] = DATA-SOURCE srcCustomer:HANDLE. /* Skip-list entry for each table in dataset. Should be in temp-table order as defined in DataSet. Each skip-list entry is a comma-separated list of field names, to be ignored in the ABL CREATE statement. */ cSkipListArray[1] = "CustNum". THIS-OBJECT:ProDataSource = hDataSourceArray. THIS-OBJECT:SkipList = cSkipListArray. END CONSTRUCTOR. METHOD PUBLIC VOID ReaddsCustomer(INPUT filter AS CHARACTER, OUTPUT DATASET dsCustomer): SUPER:ReaddsCustomer(filter). END METHOD. METHOD PUBLIC VOID CreatedsCustomer(INPUT-OUTPUT DATASET dsCustomer): DEFINE VAR hDataSet AS HANDLE NO-UNDO. hDataSet = DATASET dsCustomer:HANDLE. SUPER:CreatedsCustomer(DATASET-HANDLE hDataSet BY-REFERENCE). END METHOD. METHOD PUBLIC VOID UpdatedsCustomer(INPUT-OUTPUT DATASET dsCustomer): DEFINE VAR hDataSet AS HANDLE NO-UNDO. hDataSet = DATASET dsCustomer:HANDLE. SUPER:UpdatedsCustomer(DATASET-HANDLE hDataSet BY-REFERENCE). END METHOD. METHOD PUBLIC VOID DeletedsCustomer(INPUT-OUTPUT DATASET dsCustomer): DEFINE VAR hDataSet AS HANDLE NO-UNDO. hDataSet = DATASET dsCustomer:HANDLE. SUPER:DeletedsCustomer(DATASET-HANDLE hDataSet BY-REFERENCE). END METHOD. METHOD PUBLIC VOID SubmitdsCustomer(INPUT-OUTPUT DATASET dsCustomer): DEFINE VAR hDataSet AS HANDLE NO-UNDO. hDataSet = DATASET dsCustomer:HANDLE. SUPER:SubmitdsCustomer(DATASET-HANDLE hDataSet BY-REFERENCE). END METHOD. END CLASS. |
USING Progress.Lang.*. USING OpenEdge.BusinessLogic.BusinessEntity. BLOCK-LEVEL ON ERROR UNDO, THROW. CLASS Customer INHERITS BusinessEntity: {"customer.i"} DEFINE DATA-SOURCE srcCustomer FOR Customer. CONSTRUCTOR PUBLIC Customer(): DEFINE VAR hDataSourceArray AS HANDLE NO-UNDO EXTENT 1. DEFINE VAR cSkipListArray AS CHAR NO-UNDO EXTENT 1. SUPER(DATASET dsCustomer:HANDLE). /* Data Source for each table in dataset. Should be in table order as defined in DataSet. */ hDataSourceArray[1] = DATA-SOURCE srcCustomer:HANDLE. /* Skip-list entry for each table in dataset. Should be in temp-table order as defined in DataSet. Each skip-list entry is a comma-separated list of field names, to be ignored in the ABL CREATE statement. */ cSkipListArray[1] = "CustNum". THIS-OBJECT:ProDataSource = hDataSourceArray. THIS-OBJECT:SkipList = cSkipListArray. END CONSTRUCTOR. METHOD PUBLIC VOID ReaddsCustomer(INPUT filter AS CHARACTER, OUTPUT DATASET dsCustomer): SUPER:ReadData(filter). END METHOD. METHOD PUBLIC VOID CreatedsCustomer(INPUT-OUTPUT DATASET dsCustomer): DEFINE VAR hDataSet AS HANDLE NO-UNDO. hDataSet = DATASET dsCustomer:HANDLE. SUPER:CreateData(DATASET-HANDLE hDataSet BY-REFERENCE). END METHOD. METHOD PUBLIC VOID UpdatedsCustomer(INPUT-OUTPUT DATASET dsCustomer): DEFINE VAR hDataSet AS HANDLE NO-UNDO. hDataSet = DATASET dsCustomer:HANDLE. SUPER:UpdateData(DATASET-HANDLE hDataSet BY-REFERENCE). END METHOD. METHOD PUBLIC VOID DeletedsCustomer(INPUT-OUTPUT DATASET dsCustomer): DEFINE VAR hDataSet AS HANDLE NO-UNDO. hDataSet = DATASET dsCustomer:HANDLE. SUPER:DeleteData(DATASET-HANDLE hDataSet BY-REFERENCE). END METHOD. METHOD PUBLIC VOID SubmitdsCustomer(INPUT-OUTPUT DATASET dsCustomer): DEFINE VAR hDataSet AS HANDLE NO-UNDO. hDataSet = DATASET dsCustomer:HANDLE. SUPER:SubmitData(DATASET-HANDLE hDataSet BY-REFERENCE). END METHOD. END CLASS. |