Mercurial > hg > orthanc
diff OrthancServer/ServerJobs/SplitStudyJob.h @ 2845:218e2c864d1d
serialization of SplitStudyJob
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Fri, 28 Sep 2018 17:59:44 +0200 |
parents | 99863d6245b2 |
children | d386abc18133 |
line wrap: on
line diff
--- a/OrthancServer/ServerJobs/SplitStudyJob.h Fri Sep 28 16:48:43 2018 +0200 +++ b/OrthancServer/ServerJobs/SplitStudyJob.h Fri Sep 28 17:59:44 2018 +0200 @@ -44,24 +44,23 @@ private: typedef std::map<std::string, std::string> SeriesUidMap; typedef std::map<DicomTag, std::string> Replacements; - typedef std::set<DicomTag> Removals; ServerContext& context_; + bool keepSource_; std::string sourceStudy_; std::set<std::string> sourceSeries_; - bool keepSource_; std::string targetStudy_; std::string targetStudyUid_; SeriesUidMap targetSeries_; std::set<DicomTag> allowedTags_; DicomInstanceOrigin origin_; Replacements replacements_; - Removals removals_; + std::set<DicomTag> removals_; void CheckAllowedTag(const DicomTag& tag) const; - void Setup(const std::string& sourceStudy); + void Setup(); protected: virtual bool HandleInstance(const std::string& instance); @@ -75,9 +74,10 @@ SplitStudyJob(ServerContext& context, const Json::Value& serialized); - void SetOrigin(const DicomInstanceOrigin& origin); - - void SetOrigin(const RestApiCall& call); + const std::string& GetSourceStudy() const + { + return sourceStudy_; + } void AddSourceSeries(const std::string& series); @@ -88,18 +88,27 @@ void SetKeepSource(bool keep); - void Remove(const DicomTag& tag); - void Replace(const DicomTag& tag, const std::string& value); + void Remove(const DicomTag& tag); + + void SetOrigin(const DicomInstanceOrigin& origin); + + void SetOrigin(const RestApiCall& call); + + const DicomInstanceOrigin& GetOrigin() const + { + return origin_; + } + virtual void Stop(JobStopReason reason) { } virtual void GetJobType(std::string& target) { - target = "SplitStudyJob"; + target = "SplitStudy"; } virtual void GetPublicContent(Json::Value& value);