Esempio n. 1
0
        /// <summary>
        /// Loads a study using the specified parameters.
        /// </summary>
        /// <remarks>After this method is executed, the image viewer's <see cref="StudyTree"/>
        /// will be populated with the appropriate <see cref="Study"/>, <see cref="Series"/>
        /// and <see cref="Sop"/> objects.
        ///
        /// By default, the Framework provides an implementation of
        /// <see cref="IStudyLoader"/> called <b>LocalStoreStudyLoader</b> which loads
        /// studies from the local database.  If you have implemented your own
        /// <see cref="IStudyLoader"/> and want to load a study using that implementation,
        /// just pass in the name provided by <see cref="IStudyLoader.Name"/> as the source.
        /// </remarks>
        /// <param name="loadStudyArgs">A <see cref="LoadStudyArgs"/> object containing information about the study to be loaded.</param>
        /// <exception cref="InUseLoadStudyException">The specified study is in use and cannot be opened at this time.</exception>
        /// <exception cref="NearlineLoadStudyException">The specified study is nearline and cannot be opened at this time.</exception>
        /// <exception cref="OfflineLoadStudyException">The specified study is offline and cannot be opened at this time.</exception>
        /// <exception cref="NotFoundLoadStudyException">The specified study could not be found.</exception>
        /// <exception cref="LoadStudyException">One or more images could not be opened, or an unspecified error has occurred.</exception>
        /// <exception cref="StudyLoaderNotFoundException">The specified <see cref="IStudyLoader"/> could not be found.</exception>
        public void LoadStudy(LoadStudyArgs loadStudyArgs)
        {
            SynchronizationContext context = _uiThreadSynchronizationContext ?? SynchronizationContext.Current;

            using (SingleStudyLoader loader = new SingleStudyLoader(context, this, loadStudyArgs))
            {
                loader.LoadStudy();
                if (loader.Error != null)
                {
                    throw loader.Error;
                }
            }
        }
Esempio n. 2
0
 internal StudyLoadFailedEventArgs(LoadStudyArgs loadArgs, Exception error)
 {
     this.LoadArgs = loadArgs;
     this.Error    = error;
 }
Esempio n. 3
0
 public SingleStudyLoader(SynchronizationContext uiThreadContext, ImageViewerComponent viewer, LoadStudyArgs args)
     : this(uiThreadContext, viewer)
 {
     _args = args;
 }
 public void LoadStudy(LoadStudyArgs loadStudyArgs)
 {
 }