private CryptoMoneyTransaction getCryptoMoneyRestockTransaction( final DatabaseTableRecord cryptoMoneyRestockTransactionRecord) throws CantLoadTableToMemoryException, DatabaseOperationException, InvalidParameterException { CryptoMoneyRestockTransactionImpl cryptoMoneyRestockTransaction = new CryptoMoneyRestockTransactionImpl(); cryptoMoneyRestockTransaction.setTransactionId( cryptoMoneyRestockTransactionRecord.getUUIDValue( StockTransactionsCrpytoMoneyRestockDatabaseConstants .CRYPTO_MONEY_RESTOCK_TRANSACTION_ID_COLUMN_NAME)); cryptoMoneyRestockTransaction.setActorPublicKey( cryptoMoneyRestockTransactionRecord.getStringValue( StockTransactionsCrpytoMoneyRestockDatabaseConstants .CRYPTO_MONEY_RESTOCK_PUBLIC_KEY_ACTOR_COLUMN_NAME)); cryptoMoneyRestockTransaction.setCryptoCurrency( CryptoCurrency.getByCode( cryptoMoneyRestockTransactionRecord.getStringValue( StockTransactionsCrpytoMoneyRestockDatabaseConstants .CRYPTO_MONEY_RESTOCK_CRYPTO_CURRENCY_COLUMN_NAME))); cryptoMoneyRestockTransaction.setCbpWalletPublicKey( cryptoMoneyRestockTransactionRecord.getStringValue( StockTransactionsCrpytoMoneyRestockDatabaseConstants .CRYPTO_MONEY_RESTOCK_CBP_WALLET_PUBLIC_KEY_COLUMN_NAME)); cryptoMoneyRestockTransaction.setCryWalletPublicKey( cryptoMoneyRestockTransactionRecord.getStringValue( StockTransactionsCrpytoMoneyRestockDatabaseConstants .CRYPTO_MONEY_RESTOCK_CRY_WALLET_PUBLIC_KEY_COLUMN_NAME)); cryptoMoneyRestockTransaction.setConcept( cryptoMoneyRestockTransactionRecord.getStringValue( StockTransactionsCrpytoMoneyRestockDatabaseConstants .CRYPTO_MONEY_RESTOCK_CONCEPT_COLUMN_NAME)); cryptoMoneyRestockTransaction.setAmount( new BigDecimal( cryptoMoneyRestockTransactionRecord.getStringValue( StockTransactionsCrpytoMoneyRestockDatabaseConstants .CRYPTO_MONEY_RESTOCK_AMOUNT_COLUMN_NAME))); cryptoMoneyRestockTransaction.setTimeStamp( Timestamp.valueOf( cryptoMoneyRestockTransactionRecord.getStringValue( StockTransactionsCrpytoMoneyRestockDatabaseConstants .CRYPTO_MONEY_RESTOCK_TIMESTAMP_COLUMN_NAME))); cryptoMoneyRestockTransaction.setMemo( cryptoMoneyRestockTransactionRecord.getStringValue( StockTransactionsCrpytoMoneyRestockDatabaseConstants .CRYPTO_MONEY_RESTOCK_MEMO_COLUMN_NAME)); cryptoMoneyRestockTransaction.setTransactionStatus( TransactionStatusRestockDestock.getByCode( cryptoMoneyRestockTransactionRecord.getStringValue( StockTransactionsCrpytoMoneyRestockDatabaseConstants .CRYPTO_MONEY_RESTOCK_TRANSACTION_STATUS_COLUMN_NAME))); cryptoMoneyRestockTransaction.setPriceReference( new BigDecimal( cryptoMoneyRestockTransactionRecord.getStringValue( StockTransactionsCrpytoMoneyRestockDatabaseConstants .CRYPTO_MONEY_RESTOCK_PRICE_REFERENCE_COLUMN_NAME))); cryptoMoneyRestockTransaction.setOriginTransaction( OriginTransaction.getByCode( cryptoMoneyRestockTransactionRecord.getStringValue( StockTransactionsCrpytoMoneyRestockDatabaseConstants .CRYPTO_MONEY_RESTOCK_ORIGIN_TRANSACTION_COLUMN_NAME))); cryptoMoneyRestockTransaction.setOriginTransactionId( cryptoMoneyRestockTransactionRecord.getStringValue( StockTransactionsCrpytoMoneyRestockDatabaseConstants .CRYPTO_MONEY_RESTOCK_ORIGIN_TRANSACTION_ID_COLUMN_NAME)); cryptoMoneyRestockTransaction.setBlockchainNetworkType( BlockchainNetworkType.getByCode( cryptoMoneyRestockTransactionRecord.getStringValue( StockTransactionsCrpytoMoneyRestockDatabaseConstants .CRYPTO_MONEY_RESTOCK_BLOCK_CHAIN_NETWORK_TYPE_COLUMN_NAME))); return cryptoMoneyRestockTransaction; }
private BankMoneyTransaction getBankMoneyRestockTransaction( final DatabaseTableRecord bankMoneyRestockTransactionRecord) throws CantLoadTableToMemoryException, DatabaseOperationException, InvalidParameterException { BankMoneyRestockTransactionImpl bankMoneyRestockTransaction = new BankMoneyRestockTransactionImpl(); bankMoneyRestockTransaction.setTransactionId( bankMoneyRestockTransactionRecord.getUUIDValue( BussinessTransactionBankMoneyRestockDatabaseConstants .BANK_MONEY_RESTOCK_TRANSACTION_ID_COLUMN_NAME)); bankMoneyRestockTransaction.setActorPublicKey( bankMoneyRestockTransactionRecord.getStringValue( BussinessTransactionBankMoneyRestockDatabaseConstants .BANK_MONEY_RESTOCK_PUBLIC_KEY_ACTOR_COLUMN_NAME)); bankMoneyRestockTransaction.setFiatCurrency( FiatCurrency.getByCode( bankMoneyRestockTransactionRecord.getStringValue( BussinessTransactionBankMoneyRestockDatabaseConstants .BANK_MONEY_RESTOCK_FIAT_CURRENCY_COLUMN_NAME))); bankMoneyRestockTransaction.setCbpWalletPublicKey( bankMoneyRestockTransactionRecord.getStringValue( BussinessTransactionBankMoneyRestockDatabaseConstants .BANK_MONEY_RESTOCK_CBP_WALLET_PUBLIC_KEY_COLUMN_NAME)); bankMoneyRestockTransaction.setBnkWalletPublicKey( bankMoneyRestockTransactionRecord.getStringValue( BussinessTransactionBankMoneyRestockDatabaseConstants .BANK_MONEY_RESTOCK_BNK_WALLET_PUBLIC_KEY_COLUMN_NAME)); bankMoneyRestockTransaction.setBankAccount( bankMoneyRestockTransactionRecord.getStringValue( BussinessTransactionBankMoneyRestockDatabaseConstants .BANK_MONEY_RESTOCK_BANK_ACCOUNT_COLUMN_NAME)); bankMoneyRestockTransaction.setConcept( bankMoneyRestockTransactionRecord.getStringValue( BussinessTransactionBankMoneyRestockDatabaseConstants .BANK_MONEY_RESTOCK_CONCEPT_COLUMN_NAME)); bankMoneyRestockTransaction.setAmount( new BigDecimal( bankMoneyRestockTransactionRecord.getStringValue( BussinessTransactionBankMoneyRestockDatabaseConstants .BANK_MONEY_RESTOCK_AMOUNT_COLUMN_NAME))); bankMoneyRestockTransaction.setTimeStamp( Timestamp.valueOf( bankMoneyRestockTransactionRecord.getStringValue( BussinessTransactionBankMoneyRestockDatabaseConstants .BANK_MONEY_RESTOCK_TIMESTAMP_COLUMN_NAME))); bankMoneyRestockTransaction.setMemo( bankMoneyRestockTransactionRecord.getStringValue( BussinessTransactionBankMoneyRestockDatabaseConstants .BANK_MONEY_RESTOCK_MEMO_COLUMN_NAME)); bankMoneyRestockTransaction.setTransactionStatus( TransactionStatusRestockDestock.getByCode( bankMoneyRestockTransactionRecord.getStringValue( BussinessTransactionBankMoneyRestockDatabaseConstants .BANK_MONEY_RESTOCK_TRANSACTION_STATUS_COLUMN_NAME))); bankMoneyRestockTransaction.setPriceReference( new BigDecimal( bankMoneyRestockTransactionRecord.getStringValue( BussinessTransactionBankMoneyRestockDatabaseConstants .BANK_MONEY_RESTOCK_PRICE_REFERENCE_COLUMN_NAME))); bankMoneyRestockTransaction.setOriginTransaction( OriginTransaction.getByCode( bankMoneyRestockTransactionRecord.getStringValue( BussinessTransactionBankMoneyRestockDatabaseConstants .BANK_MONEY_RESTOCK_ORIGIN_TRANSACTION_COLUMN_NAME))); return bankMoneyRestockTransaction; }