public ChromatogramLibrary(ChromatogramLibrarySpec chromatogramLibrarySpec, IStreamManager streamManager)
     : this(chromatogramLibrarySpec)
 {
     _streamManager        = streamManager;
     _pooledSessionFactory = new PooledSessionFactory(streamManager.ConnectionPool, typeof(ChromLibEntity),
                                                      chromatogramLibrarySpec.FilePath);
 }
示例#2
0
 public ChromatogramLibrary(ChromatogramLibrarySpec chromatogramLibrarySpec) : base(chromatogramLibrarySpec)
 {
     LibrarySpec = chromatogramLibrarySpec;
     FilePath    = LibrarySpec.FilePath;
     CachePath   = Path.Combine(PathEx.GetDirectoryName(FilePath) ?? string.Empty,
                                Path.GetFileNameWithoutExtension(FilePath) + EXT_CACHE);
     _libraryIrts        = new ChromatogramLibraryIrt[0];
     _librarySourceFiles = new ChromatogramLibrarySourceInfo[0];
 }
示例#3
0
        public static ChromatogramLibrary LoadFromDatabase(ChromatogramLibrarySpec chromatogramLibrarySpec, ILoadMonitor loadMonitor)
        {
            var library = new ChromatogramLibrary(chromatogramLibrarySpec, loadMonitor.StreamManager);

            if (library.Load(loadMonitor))
            {
                return(library);
            }
            return(null);
        }