コード例 #1
0
        public StateHash CalculateTransform(StateHash currentHash)
        {
            if (mKnownState != null)
                return mKnownState;

            using (var transform = new HashTransformer(currentHash))
            {
                foreach (var db in mDatabases.OrderBy(x => x.Name))
                {
                    transform.TransformWithFileSmart(db.BackupFilePath);
                }

                return transform.GetResult();
            }
        }
コード例 #2
0
        public StateHash RunTransform(StateHash currentHash, bool dryRun, ILog log)
        {
            if (mKnownState != null)
            {
                foreach (var db in mDatabases.OrderBy(x => x.Name))
                {
                    RestoreDatabase(db, dryRun, log);
                }

                return mKnownState;
            }

            using (var transform = new HashTransformer(currentHash))
            {
                foreach (var db in mDatabases.OrderBy(x => x.Name))
                {
                    transform.TransformWithFileSmart(db.BackupFilePath);
                    RestoreDatabase(db, dryRun, log);
                }

                return transform.GetResult();
            }
        }