Finalise() 정적인 개인적인 메소드

Makes sure that the IsNew property on LedgerBook EntryLines is not set to true, as it will be when they are newly created. Also ensures the StoredInAccount property for each ledger is set.
static private Finalise ( LedgerBook book, bool unlock = false ) : void
book BudgetAnalyser.Engine.Ledger.LedgerBook
unlock bool
리턴 void
예제 #1
0
        public LedgerBookTestHarness BuildTestHarness(IReconciliationBuilder reconciliationBuilder)
        {
            var book = new LedgerBookTestHarness(reconciliationBuilder)
            {
                Name       = Name,
                Modified   = Modified,
                StorageKey = StorageKey
            };

            book.SetReconciliations(this.reconciliations);

            LedgerBookTestData.Finalise(book, this.lockWhenFinished);
            return(book);
        }
예제 #2
0
        public LedgerBook Build()
        {
            var book = new LedgerBook(new ReconciliationBuilder(new FakeLogger()))
            {
                Name       = Name,
                Modified   = Modified,
                StorageKey = StorageKey
            };

            book.SetReconciliations(this.reconciliations);
            if (book.Reconciliations.None())
            {
                this.ledgerBuckets.ForEach(l => book.AddLedger(l));
            }

            LedgerBookTestData.Finalise(book, this.lockWhenFinished);
            return(book);
        }