home *** CD-ROM | disk | FTP | other *** search
- {#Z+}
- (*(10U&l12D(s4099T&k2S*)
- {***************************************************************************}
- {** Program : NWACCNTG **}
- {***************************************************************************}
- {** Version : 1.53 ** Started : 11/11/91 ** Ended : / / **}
- {***************************************************************************}
- {******************************** Description ******************************}
- {***************************************************************************}
- {** OOP library for Netware API **}
- {** **}
- {** This unit forms the second level object : ACCOUNTING **}
- {** This object is a descandent of : NETWARE **}
- {** **}
- {** **}
- {** **}
- {** **}
- {***************************************************************************}
- {******************************** Information ******************************}
- {***************************************************************************}
- {** Provides Netware Accounting Services. **}
- {** **}
- {** **}
- {** **}
- {** This code is (c) 1991 - 1994 Antonio Covelli. ALL RIGHTS RESERVED. **}
- {** Portions (c) Novell Inc, **}
- {** **}
- {** **}
- {***************************************************************************}
-
- {$I NETWARE.INC}
- {#Z-}
-
- UNIT NWACCNTG;
-
- INTERFACE
-
- USES
-
- nwvar,
- netware;
-
- TYPE
-
- PAccountingOBJ = ^AccountingOBJ;
- AccountingOBJ = OBJECT (NetwareOBJ)
-
- { This object provides Netware Accounting Services API's. }
-
- FUNCTION GetAccountStatus (BinderyObjectType : WORD;
- BinderyObjectName : TObjectName;
- VAR Balance, Limit : LONGINT;
- VAR Holds : TLongint32Array) : WORD;
- { Allows a server to get an account status at the time of the request. No
- audit record is generated. }
- {#F}
- {}
- { BinderyObjectType: type of object }
- { BinderyObjectName: name of object }
- { Balance : contains the current balance available }
- { Limit : contains the credit limit }
- { Holds : contains all objects with an account hold and the
- amount on hold}
- {#F}
-
- FUNCTION SubmitAccountCharge (BinderyObjectType : WORD;
- BinderyObjectName : TObjectName;
- ServiceType : WORD;
- ChargeAmount,
- HoldCancelAmount : LONGINT;
- CommentType : WORD;
- Comment : TString255) : WORD;
- { Allows a server to submit a charge to an account. The charge is subtracted
- from the object's account balance, and an audit record is generated. The
- HoldCancelAmount is the same as the amount specified in the previous
- corresponding SubmitAccountHold. If no SubmitAccountHold was made then
- HoldCancelAmount is 0. }
- {#F}
- {}
- { BinderyObjectType: type of object }
- { BinderyObjectName: name of object }
- { ServiceType : type of service being charged for. Usually assigned by
- Novell }
- { ChargeAmount : amount of charge (cost) to be submitted }
- { HoldCancelAmount : see above for details of this parameter }
- { CommentType : type of comment being charge for. Usually assigned by
- Novell. Values above $8000 are reserved for experimental
- purposes. See Comment Types in NWVAR.PAS for more
- information }
- { Comment : note to store in the audit file }
- {#F}
-
- FUNCTION SubmitAccountHold (BinderyObjectType : WORD;
- BinderyObjectName : TObjectName;
- ReserveAmount : LONGINT) : WORD;
- { Allows a server to hold an amount, pending a subsequent charge to the
- object's account. The amount, along with the requesting server's object
- ID is recorded in the object's ACCOUNT_HOLDS property. If the requesting
- server has an outstanding hold, the new hold amount is added to that
- server's outstanding hold amount.
-
- A server can back out a hold by calling SubmitAccountHold with the inverse
- of the amount originally held. A server can also partially back out holds
- by specifying smaller amounts. To clear all holds, a server can submit a
- hold with the amount set to 0. }
- {#F}
- {}
- { BinderyObjectType: type of object }
- { BinderyObjectName: name of object }
- { ReserveAmount : amount of charge (cost) to be reserved }
- {#F}
-
- FUNCTION SubmitAccountNote (BinderyObjectType : WORD;
- BinderyObjectName : TObjectName;
- ServiceType, CommentType : WORD;
- Comment : TString255) : WORD;
- { Allows a server to record a note about the object's account activities in
- the audit file. EG. When the object logs in. }
- {#F}
- {}
- { BinderyObjectType: type of object }
- { BinderyObjectName: name of object }
- { ServiceType : type of service being charged for. Usually assigned by
- Novell }
- { CommentType : type of comment being charge for. Usually assigned by
- Novell. Values above $8000 are reserved for experimental
- purposes. See Comment Types in NWVAR.PAS for more
- information }
- { Comment : Note to store in the audit file }
- {#F}
-
- DESTRUCTOR Done; VIRTUAL;
-
- END;
-
-