IFinancialSystem
From Virtual World Web Wiki
The financial system is a primary layer one interface. It provides methods for working with currencies and transactions.
Remarks [edit]
Methods
- void AcquireCurrency(IConnectionIdentity identity, Guid financialCurrencyID)
- Triggers an event which can be responded to by a component to let the customer know they need to purchase more currency and provide a way to do that
- void CloseAccount(Guid financialAccountID)
- Closes a financial account
- Guid CreateAccount(Guid entityID, Guid currencyID)
- Creates a new financial account for the specified entity in the specified currency
- Guid CreateCurrency(string identifier, string symbol, string code)
- Registers a new currency with the system
- ITransaction CreateTransaction(Guid sourceEntityID, Guid currencyID)
- Begins a new transaction
- void DeleteCurrency(Guid currencyID)
- Deletes a currency. Use with care.
- Guid? FindAccount(Guid entityID, Guid currencyID)
- Gets the ID of an existing financial account owned by the specified entity
- ITransaction FindTransaction(Guid transactionID)
- Finds an existing transaction so it can be cancelled, settled, or examined
- Decimal GetBalance(Guid entityID, Guid currencyID)
- Gets the current balance of a financial account (this will not include any balance held by pending transactions)
- Decimal GetBalance(Guid financialAccountID)
- Gets the current balance of a financial account (this will not include any balance held by pending transactions)
- ICurrencyInfo GetCurrencyInfo(Guid currencyID)
- Gets a structure of information describing a currency
- IEnumerable<ICurrencyInfo> GetCurrencyInfos()
- Gtes a structure of information describing each available currency in the system
- ICurrencyInfo GetDefaultCurrencyInfo()
- Gets a structure of information describing the default currency
- ITransactionReport GetTransactionHistory(Guid entityID, Guid currencyID, TimeSpan? range = NULL, int page = 0, int pagesize = 20)
- Gets a report of transactions involving an entity
- void SetDefaultCurrency(Guid currencyID)
- Sets the currency that should be used by components when they don't know or care which currency they're working with