1919
2020/**
2121 * @property SaveOptions $saveOptions
22+ *
23+ * @deprecated
2224 */
2325trait LegacyTrait
2426{
2527 /**
2628 * @return bool
27- *
28- * @deprecated
2929 */
3030 public function getSegmentBuildingHookEnabled ()
3131 {
32+ trigger_deprecation (
33+ 'pimcore/customer-data-framework ' ,
34+ '1.3.17 ' ,
35+ sprintf ('%s is deprecated. ' , __METHOD__ )
36+ );
37+
3238 return $ this ->saveOptions ->isOnSaveSegmentBuildersEnabled ();
3339 }
3440
3541 /**
3642 * @param bool $segmentBuildingHookEnabled
3743 *
3844 * @return $this
39- *
40- * @deprecated
4145 */
4246 public function setSegmentBuildingHookEnabled ($ segmentBuildingHookEnabled )
4347 {
48+ trigger_deprecation (
49+ 'pimcore/customer-data-framework ' ,
50+ '1.3.17 ' ,
51+ sprintf ('%s is deprecated. ' , __METHOD__ )
52+ );
53+
4454 if ($ segmentBuildingHookEnabled ) {
4555 $ this ->saveOptions ->enableOnSaveSegmentBuilders ();
4656 } else {
@@ -52,23 +62,31 @@ public function setSegmentBuildingHookEnabled($segmentBuildingHookEnabled)
5262
5363 /**
5464 * @return bool
55- *
56- * @deprecated
5765 */
5866 public function getCustomerSaveValidatorEnabled ()
5967 {
68+ trigger_deprecation (
69+ 'pimcore/customer-data-framework ' ,
70+ '1.3.17 ' ,
71+ sprintf ('%s is deprecated. ' , __METHOD__ )
72+ );
73+
6074 return $ this ->saveOptions ->isValidatorEnabled ();
6175 }
6276
6377 /**
6478 * @param bool $customerSaveValidatorEnabled
6579 *
6680 * @return $this
67- *
68- * @deprecated
6981 */
7082 public function setCustomerSaveValidatorEnabled ($ customerSaveValidatorEnabled )
7183 {
84+ trigger_deprecation (
85+ 'pimcore/customer-data-framework ' ,
86+ '1.3.17 ' ,
87+ sprintf ('%s is deprecated. ' , __METHOD__ )
88+ );
89+
7290 if ($ customerSaveValidatorEnabled ) {
7391 $ this ->saveOptions ->enableValidator ();
7492 } else {
@@ -80,23 +98,31 @@ public function setCustomerSaveValidatorEnabled($customerSaveValidatorEnabled)
8098
8199 /**
82100 * @return bool
83- *
84- * @deprecated
85101 */
86102 public function isDisableSaveHandlers ()
87103 {
104+ trigger_deprecation (
105+ 'pimcore/customer-data-framework ' ,
106+ '1.3.17 ' ,
107+ sprintf ('%s is deprecated. ' , __METHOD__ )
108+ );
109+
88110 return !$ this ->saveOptions ->isSaveHandlersExecutionEnabled ();
89111 }
90112
91113 /**
92114 * @param bool $disableSaveHandlers
93115 *
94116 * @return $this
95- *
96- * @deprecated
97117 */
98118 public function setDisableSaveHandlers ($ disableSaveHandlers )
99119 {
120+ trigger_deprecation (
121+ 'pimcore/customer-data-framework ' ,
122+ '1.3.17 ' ,
123+ sprintf ('%s is deprecated. ' , __METHOD__ )
124+ );
125+
100126 if ($ disableSaveHandlers ) {
101127 $ this ->saveOptions ->disableSaveHandlers ();
102128 } else {
@@ -108,23 +134,31 @@ public function setDisableSaveHandlers($disableSaveHandlers)
108134
109135 /**
110136 * @return bool
111- *
112- * @deprecated
113137 */
114138 public function isDisableDuplicateIndex ()
115139 {
140+ trigger_deprecation (
141+ 'pimcore/customer-data-framework ' ,
142+ '1.3.17 ' ,
143+ sprintf ('%s is deprecated. ' , __METHOD__ )
144+ );
145+
116146 return !$ this ->saveOptions ->isDuplicatesIndexEnabled ();
117147 }
118148
119149 /**
120150 * @param bool $disableDuplicateIndex
121151 *
122152 * @return $this
123- *
124- * @deprecated
125153 */
126154 public function setDisableDuplicateIndex ($ disableDuplicateIndex )
127155 {
156+ trigger_deprecation (
157+ 'pimcore/customer-data-framework ' ,
158+ '1.3.17 ' ,
159+ sprintf ('%s is deprecated. ' , __METHOD__ )
160+ );
161+
128162 if ($ disableDuplicateIndex ) {
129163 $ this ->saveOptions ->disableDuplicatesIndex ();
130164 } else {
@@ -136,23 +170,31 @@ public function setDisableDuplicateIndex($disableDuplicateIndex)
136170
137171 /**
138172 * @return bool
139- *
140- * @deprecated
141173 */
142174 public function isDisableQueue ()
143175 {
176+ trigger_deprecation (
177+ 'pimcore/customer-data-framework ' ,
178+ '1.3.17 ' ,
179+ sprintf ('%s is deprecated. ' , __METHOD__ )
180+ );
181+
144182 return !$ this ->saveOptions ->isSegmentBuilderQueueEnabled ();
145183 }
146184
147185 /**
148186 * @param bool $disableQueue
149187 *
150188 * @return $this
151- *
152- * @deprecated
153189 */
154190 public function setDisableQueue ($ disableQueue )
155191 {
192+ trigger_deprecation (
193+ 'pimcore/customer-data-framework ' ,
194+ '1.3.17 ' ,
195+ sprintf ('%s is deprecated. ' , __METHOD__ )
196+ );
197+
156198 if ($ disableQueue ) {
157199 $ this ->saveOptions ->disableSegmentBuilderQueue ();
158200 } else {
@@ -167,14 +209,15 @@ public function setDisableQueue($disableQueue)
167209 * @param bool $disableVersions
168210 *
169211 * @return mixed
170- *
171- * @deprecated
172212 */
173213 public function saveWithDisabledHooks (CustomerInterface $ customer , $ disableVersions = false )
174214 {
175- /**
176- * @var SaveOptions $options
177- */
215+ trigger_deprecation (
216+ 'pimcore/customer-data-framework ' ,
217+ '1.3.17 ' ,
218+ sprintf ('%s is deprecated. ' , __METHOD__ )
219+ );
220+
178221 $ options = $ this ->getSaveOptions (true );
179222 $ options
180223 ->disableValidator ()
0 commit comments