Mercurial > hg > orthanc
comparison OrthancServer/Search/DicomTagConstraint.h @ 3027:fd587cf51a89 db-changes
cont
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Tue, 18 Dec 2018 12:50:27 +0100 |
parents | 039a9d262d64 |
children | ea653ec47f31 |
comparison
equal
deleted
inserted
replaced
3025:039a9d262d64 | 3027:fd587cf51a89 |
---|---|
45 private: | 45 private: |
46 class NormalizedString; | 46 class NormalizedString; |
47 class RegularExpression; | 47 class RegularExpression; |
48 | 48 |
49 DicomTag tag_; | 49 DicomTag tag_; |
50 DicomTagType tagType_; | |
50 ConstraintType constraintType_; | 51 ConstraintType constraintType_; |
51 std::set<std::string> values_; | 52 std::set<std::string> values_; |
52 bool caseSensitive_; | 53 bool caseSensitive_; |
53 bool mandatory_; | 54 bool mandatory_; |
54 | 55 |
55 boost::shared_ptr<RegularExpression> regex_; | 56 boost::shared_ptr<RegularExpression> regex_; |
56 | 57 |
58 DicomTagConstraint() : | |
59 tag_(0, 0), | |
60 tagType_(DicomTagType_Generic) | |
61 { | |
62 } | |
63 | |
57 public: | 64 public: |
58 DicomTagConstraint(const DicomTag& tag, | 65 DicomTagConstraint(const DicomTag& tag, |
59 ConstraintType type, | 66 ConstraintType type, |
60 const std::string& value, | 67 const std::string& value, |
61 bool caseSensitive, | 68 bool caseSensitive, |
65 DicomTagConstraint(const DicomTag& tag, | 72 DicomTagConstraint(const DicomTag& tag, |
66 ConstraintType type, | 73 ConstraintType type, |
67 bool caseSensitive, | 74 bool caseSensitive, |
68 bool mandatory); | 75 bool mandatory); |
69 | 76 |
77 DicomTagConstraint* Clone() const; | |
78 | |
70 const DicomTag& GetTag() const | 79 const DicomTag& GetTag() const |
71 { | 80 { |
72 return tag_; | 81 return tag_; |
73 } | 82 } |
74 | 83 |
75 ConstraintType GetType() const | 84 DicomTagType GetTagType() const |
85 { | |
86 return tagType_; | |
87 } | |
88 | |
89 // Set by "ServerIndex::NormalizeLookup()" | |
90 void SetTagType(DicomTagType type) | |
91 { | |
92 tagType_ = type; | |
93 } | |
94 | |
95 ConstraintType GetConstraintType() const | |
76 { | 96 { |
77 return constraintType_; | 97 return constraintType_; |
78 } | 98 } |
79 | 99 |
80 bool IsCaseSensitive() const | 100 bool IsCaseSensitive() const |
81 { | 101 { |
82 return caseSensitive_; | 102 return caseSensitive_; |
103 } | |
104 | |
105 void SetCaseSensitive(bool caseSensitive) | |
106 { | |
107 caseSensitive_ = caseSensitive; | |
83 } | 108 } |
84 | 109 |
85 bool IsMandatory() const | 110 bool IsMandatory() const |
86 { | 111 { |
87 return mandatory_; | 112 return mandatory_; |