Data Access Layer

The Leadtools.Medical.Storage.Data Access Layer assembly includes classes that allow users to store, query, and modify DICOM Composite Instances.  To override this behavior, create and register your own storage data access agent that implements the IStorageDataAccessAgent interface. The IStorageDataAccessAgent has the following members: 

public interface IStorageDataAccessAgent 
   { 
      DataSet QueryPatients( MatchingParameterCollection matchingEntitiesCollection ) ; 
      DataSet QueryStudies ( MatchingParameterCollection matchingEntitiesCollection ) ; 
      DataSet QuerySeries  ( MatchingParameterCollection matchingEntitiesCollection ) ; 
      DataSet QueryCompositeInstances ( MatchingParameterCollection matchingEntitiesCollection ) ; 
 
      int MaxQueryResults {get; set;} 
       
      bool QueryCompositeInstancesAsync ( MatchingParameterCollection matchingEntitiesCollection, QueryPageInfo queryPageInfo) ; 
      void CancelQueryCompositeInstancesAsync(QueryCompositeInstancesArgs args); 
       
      event EventHandler<QueryCompositeInstancesArgs>QueryCompositeInstancesStarting; 
      event EventHandler <QueryCompositeInstancesArgs>QueryCompositeInstancesCompleted; 
       
      int FindPatientsCount           ( MatchingParameterCollection matchingEntitiesCollection ) ; 
      int FindStudiesCount            ( MatchingParameterCollection matchingEntitiesCollection ) ; 
      int FindSeriesCount             ( MatchingParameterCollection matchingEntitiesCollection ) ; 
      int FindCompositeInstancesCount ( MatchingParameterCollection matchingEntitiesCollection ) ; 
             
      bool IsPatientsExists           ( string patientID ) ; 
      bool IsStudyExists              ( string studyInstanceUID ) ; 
      bool IsSeriesExists             ( string seriesInstanceUID ) ; 
      bool IsCompositeInstancesExists ( string sopInstanceUID ) ; 
       
      void UpdateCompositeInstance ( CompositeInstanceDataSet compositeInstanceDataSet ) ; 
       
      void StoreDicom ( DicomDataSet dataSet,  
                        string referencedFileName,  
                        string retrieveAe, 
                        ReferencedImages[] images, 
                        bool updateExistentPatient,  
                        bool updateExistentStudy,  
                        bool updateExistentSeries,  
                        bool updateExistentInstances ) ; 
                         
      int DeletePatient  ( MatchingParameterCollection matchingEntitiesCollection ) ; 
      int DeleteStudy    ( MatchingParameterCollection matchingEntitiesCollection ) ; 
      int DeleteSeries   ( MatchingParameterCollection matchingEntitiesCollection ) ; 
      int DeleteInstance ( MatchingParameterCollection matchingEntitiesCollection ) ; 
       
   } 

In the Connecting the Sample Database to the LEAD Storage Server tutorial, you will create and register a MyStorageSqlDbDataAccessAgent that implements an IStorageDataAccessAgent interface. Since this tutorial will be using SQL Server 2008 as the database engine, our MyStorageSqlDbDataAccessAgent class will derive from the existing StorageSqlDbDataAccessAgent class directly (which implements IStorageDataAccessAgent), and override only the methods that prepare the SQL queries.  If you do not want to use an SQL-based database engine, your storage data access agent would be responsible for implementing the IStorageDataAccessAgent members directly.

Help Version 20.0.2020.4.3
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2020 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS Imaging, Medical, and Document