private IFolder entryFolder; // This is the folder the user requested. Metadatea can be above and below this folder public PackageHandler(IRepositoryDataAccess repositoryAccess, IMetadataDataAccess metadataAccess, IRequestClient <GetArchiveRecordsForPackageRequest> indexClient) { this.repositoryAccess = repositoryAccess; this.metadataAccess = metadataAccess; // Needing the bus here, is not ideal. But the bus is the only way to access data in the SSZ zone from the BV zone this.indexClient = indexClient; FoldersTreeList = new FolderInfoList(); }
/// <summary> /// Initializes a new instance of the <see cref="RepositoryManager" /> class. /// </summary> /// <param name="repositoryDataAccess">The repository data access.</param> /// <param name="packageValidator">A validation engine to validate the package.</param> /// <param name="handler">A handler that creates the arelda metadata XML</param> /// <param name="parameterHelper">Class to read settings parameters</param> public RepositoryManager(IRepositoryDataAccess repositoryDataAccess, IPackageValidator packageValidator, IPackageHandler handler, IParameterHelper parameterHelper, IBus bus) { this.repositoryDataAccess = repositoryDataAccess; this.packageValidator = packageValidator; this.handler = handler; this.bus = bus; syncSettings = parameterHelper.GetSetting <RepositorySyncSettings>(); ignoredFilenameRegex = syncSettings.IgnorierteDateinamenRegex.Split('\n').Select(s => s.Trim()).ToList(); }
public MainWindowViewModel(Settings settings, IRepositoryDataAccess repositoryDataAccess) { this.repositoryDataAccess = repositoryDataAccess; Repositories = new ObservableCollection<Repository>(repositoryDataAccess.GetRepositories()); Repositories.Add(new Repository("c:\\src")); // Load the persisted application settings CurrentRepository = String.IsNullOrEmpty(settings.CurrentRepository) ? Repositories.FirstOrDefault() : new Repository(settings.CurrentRepository); CurrentBranch = settings.CurrentBranch; }