2017-02-07 16:48:19 +01:00
import { OHIFError } from './OHIFError' ;
/ * *
* Abstract class to fetch study metadata .
* /
export class StudyMetadataSource {
/ * *
2017-02-13 15:57:07 +01:00
* Get study metadata for a study with given study InstanceUID .
* @ param { String } studyInstanceUID Study InstanceUID .
2017-02-07 16:48:19 +01:00
* /
2017-02-13 15:57:07 +01:00
getByInstanceUID ( studyInstanceUID ) {
2017-02-07 20:44:42 +01:00
/ * *
* Please override this method on a specialized class .
* /
2017-02-13 15:57:07 +01:00
throw new OHIFError ( 'StudyMetadataSource::getByInstanceUID is not overriden. Please, override it in a specialized class. See OHIFStudyMetadataSource for example' ) ;
2017-02-07 20:44:42 +01:00
}
2017-02-07 16:48:19 +01:00
/ * *
2017-02-13 15:57:07 +01:00
* Load study info and study metadata for a given study into the viewer .
* @ param { StudySummary | StudyMetadata } study of StudySummary or StudyMetadata object .
2017-02-07 16:48:19 +01:00
* /
2017-02-13 15:57:07 +01:00
loadStudy ( study ) {
2017-02-07 20:44:42 +01:00
/ * *
* Please override this method on a specialized class .
* /
2017-02-13 15:57:07 +01:00
throw new OHIFError ( 'StudyMetadataSource::loadStudy is not overriden. Please, override it in a specialized class. See OHIFStudyMetadataSource for example' ) ;
2017-02-07 20:44:42 +01:00
}
2017-02-13 15:57:07 +01:00
}