Complex classes like Configuration often do a lot of different things. To break such a class down, we need to identify a cohesive component within that class. A common approach to find such a component is to look for fields/methods that share the same prefixes, or suffixes. You can also have a look at the cohesion graph to spot any un-connected, or weakly-connected components.
Once you have determined the fields that belong together, you can apply the Extract Class refactoring. If the component makes sense as a sub-class, Extract Subclass is also a candidate, and is often faster.
While breaking up the class, it is a good idea to analyze how other classes use Configuration, and based on these observations, apply Extract Interface, too.
1 | <?php |
||
49 | class Configuration implements ConfigurationInterface, ListenerAwareConfigurationInterface |
||
50 | { |
||
51 | |||
52 | /** |
||
53 | * The default PID filename to use. |
||
54 | * |
||
55 | * @var string |
||
56 | */ |
||
57 | const PID_FILENAME = 'importer.pid'; |
||
58 | |||
59 | /** |
||
60 | * Trait that provides CSV configuration functionality. |
||
61 | * |
||
62 | * @var \TechDivision\Import\Configuration\Jms\Configuration\CsvTrait |
||
63 | */ |
||
64 | use CsvTrait; |
||
65 | |||
66 | /** |
||
67 | * Trait that provides CSV configuration functionality. |
||
68 | * |
||
69 | * @var \TechDivision\Import\Configuration\Jms\Configuration\ParamsTrait |
||
70 | */ |
||
71 | use ParamsTrait; |
||
72 | |||
73 | /** |
||
74 | * Trait that provides CSV configuration functionality. |
||
75 | * |
||
76 | * @var \TechDivision\Import\Configuration\Jms\Configuration\ListenersTrait |
||
77 | */ |
||
78 | use ListenersTrait; |
||
79 | |||
80 | /** |
||
81 | * The array with the available database types. |
||
82 | * |
||
83 | * @var array |
||
84 | * @Exclude |
||
85 | */ |
||
86 | protected $availableDatabaseTypes = array( |
||
87 | DatabaseConfigurationInterface::TYPE_MYSQL, |
||
88 | DatabaseConfigurationInterface::TYPE_REDIS |
||
89 | ); |
||
90 | |||
91 | /** |
||
92 | * Mapping for boolean values passed on the console. |
||
93 | * |
||
94 | * @var array |
||
95 | * @Exclude |
||
96 | */ |
||
97 | protected $booleanMapping = array( |
||
98 | 'true' => true, |
||
99 | 'false' => false, |
||
100 | '1' => true, |
||
101 | '0' => false, |
||
102 | 'on' => true, |
||
103 | 'off' => false |
||
104 | ); |
||
105 | |||
106 | /** |
||
107 | * The serial that will be passed as commandline option (can not be specified in configuration file). |
||
108 | * |
||
109 | * @var string |
||
110 | * @Exclude |
||
111 | */ |
||
112 | protected $serial; |
||
113 | |||
114 | /** |
||
115 | * The application's unique DI identifier. |
||
116 | * |
||
117 | * @var string |
||
118 | * @Type("string") |
||
119 | * @SerializedName("id") |
||
120 | */ |
||
121 | protected $id; |
||
122 | |||
123 | /** |
||
124 | * The system name to use. |
||
125 | * |
||
126 | * @var string |
||
127 | * @Type("string") |
||
128 | * @SerializedName("system-name") |
||
129 | */ |
||
130 | protected $systemName; |
||
131 | |||
132 | /** |
||
133 | * The operation name to use. |
||
134 | * |
||
135 | * @var string |
||
136 | * @Type("string") |
||
137 | * @SerializedName("operation-name") |
||
138 | */ |
||
139 | protected $operationName; |
||
140 | |||
141 | /** |
||
142 | * The entity type code to use. |
||
143 | * |
||
144 | * @var string |
||
145 | * @Type("string") |
||
146 | * @SerializedName("entity-type-code") |
||
147 | */ |
||
148 | protected $entityTypeCode; |
||
149 | |||
150 | /** |
||
151 | * The Magento installation directory. |
||
152 | * |
||
153 | * @var string |
||
154 | * @Type("string") |
||
155 | * @SerializedName("installation-dir") |
||
156 | */ |
||
157 | protected $installationDir; |
||
158 | |||
159 | /** |
||
160 | * The source directory that has to be watched for new files. |
||
161 | * |
||
162 | * @var string |
||
163 | * @Type("string") |
||
164 | * @SerializedName("source-dir") |
||
165 | */ |
||
166 | protected $sourceDir; |
||
167 | |||
168 | /** |
||
169 | * The target directory with the files that has been imported. |
||
170 | * |
||
171 | * @var string |
||
172 | * @Type("string") |
||
173 | * @SerializedName("target-dir") |
||
174 | */ |
||
175 | protected $targetDir; |
||
176 | |||
177 | /** |
||
178 | * The Magento edition, EE or CE. |
||
179 | * |
||
180 | * @var string |
||
181 | * @Type("string") |
||
182 | * @SerializedName("magento-edition") |
||
183 | */ |
||
184 | protected $magentoEdition = 'CE'; |
||
185 | |||
186 | /** |
||
187 | * The Magento version, e. g. 2.1.0. |
||
188 | * |
||
189 | * @var string |
||
190 | * @Type("string") |
||
191 | * @SerializedName("magento-version") |
||
192 | */ |
||
193 | protected $magentoVersion = '2.1.2'; |
||
194 | |||
195 | /** |
||
196 | * ArrayCollection with the information of the configured databases. |
||
197 | * |
||
198 | * @var \Doctrine\Common\Collections\ArrayCollection |
||
199 | * @Type("ArrayCollection<TechDivision\Import\Configuration\Jms\Configuration\Database>") |
||
200 | */ |
||
201 | protected $databases; |
||
202 | |||
203 | /** |
||
204 | * ArrayCollection with the information of the configured loggers. |
||
205 | * |
||
206 | * @var \Doctrine\Common\Collections\ArrayCollection |
||
207 | * @Type("ArrayCollection<TechDivision\Import\Configuration\Jms\Configuration\Logger>") |
||
208 | */ |
||
209 | protected $loggers; |
||
210 | |||
211 | /** |
||
212 | * ArrayCollection with the information of the configured operations. |
||
213 | * |
||
214 | * @var \Doctrine\Common\Collections\ArrayCollection |
||
215 | * @Type("ArrayCollection<TechDivision\Import\Configuration\Jms\Configuration\Operation>") |
||
216 | */ |
||
217 | protected $operations; |
||
218 | |||
219 | /** |
||
220 | * The subject's multiple field delimiter character for fields with multiple values, defaults to (,). |
||
221 | * |
||
222 | * @var string |
||
223 | * @Type("string") |
||
224 | * @SerializedName("multiple-field-delimiter") |
||
225 | */ |
||
226 | protected $multipleFieldDelimiter = ','; |
||
227 | |||
228 | /** |
||
229 | * The subject's multiple value delimiter character for fields with multiple values, defaults to (|). |
||
230 | * |
||
231 | * @var string |
||
232 | * @Type("string") |
||
233 | * @SerializedName("multiple-value-delimiter") |
||
234 | */ |
||
235 | protected $multipleValueDelimiter = '|'; |
||
236 | |||
237 | /** |
||
238 | * The flag to signal that the subject has to use the strict mode or not. |
||
239 | * |
||
240 | * @var boolean |
||
241 | * @Type("boolean") |
||
242 | * @SerializedName("strict-mode") |
||
243 | */ |
||
244 | protected $strictMode; |
||
245 | |||
246 | /** |
||
247 | * The flag whether or not the import artefacts have to be archived. |
||
248 | * |
||
249 | * @var boolean |
||
250 | * @Type("boolean") |
||
251 | * @SerializedName("archive-artefacts") |
||
252 | */ |
||
253 | protected $archiveArtefacts; |
||
254 | |||
255 | /** |
||
256 | * The directory where the archives will be stored. |
||
257 | * |
||
258 | * @var string |
||
259 | * @Type("string") |
||
260 | * @SerializedName("archive-dir") |
||
261 | */ |
||
262 | protected $archiveDir; |
||
263 | |||
264 | /** |
||
265 | * The flag to signal that the subject has to use the debug mode or not. |
||
266 | * |
||
267 | * @var boolean |
||
268 | * @Type("boolean") |
||
269 | * @SerializedName("debug-mode") |
||
270 | */ |
||
271 | protected $debugMode = false; |
||
272 | |||
273 | /** |
||
274 | * The log level to use (see Monolog documentation). |
||
275 | * |
||
276 | * @var string |
||
277 | * @Type("string") |
||
278 | * @SerializedName("log-level") |
||
279 | */ |
||
280 | protected $logLevel = LogLevel::INFO; |
||
281 | |||
282 | /** |
||
283 | * The explicit DB ID to use. |
||
284 | * |
||
285 | * @var string |
||
286 | * @Type("string") |
||
287 | * @SerializedName("use-db-id") |
||
288 | */ |
||
289 | protected $useDbId; |
||
290 | |||
291 | /** |
||
292 | * The explicit PID filename to use. |
||
293 | * |
||
294 | * @var string |
||
295 | * @Type("string") |
||
296 | * @SerializedName("pid-filename") |
||
297 | */ |
||
298 | protected $pidFilename; |
||
299 | |||
300 | /** |
||
301 | * The collection with the paths to additional vendor directories. |
||
302 | * |
||
303 | * @var \Doctrine\Common\Collections\ArrayCollection |
||
304 | * @Type("ArrayCollection<TechDivision\Import\Configuration\Jms\Configuration\VendorDir>") |
||
305 | * @SerializedName("additional-vendor-dirs") |
||
306 | */ |
||
307 | protected $additionalVendorDirs; |
||
308 | |||
309 | /** |
||
310 | * The array with the Magento Edition specific extension libraries. |
||
311 | * |
||
312 | * @var array |
||
313 | * @Type("array") |
||
314 | * @SerializedName("extension-libraries") |
||
315 | */ |
||
316 | protected $extensionLibraries = array(); |
||
317 | |||
318 | /** |
||
319 | * The array with the custom header mappings. |
||
320 | * |
||
321 | * @var array |
||
322 | * @Type("array") |
||
323 | * @SerializedName("header-mappings") |
||
324 | */ |
||
325 | protected $headerMappings = array(); |
||
326 | |||
327 | /** |
||
328 | * The array with the custom image types. |
||
329 | * |
||
330 | * @var array |
||
331 | * @Type("array") |
||
332 | * @SerializedName("image-types") |
||
333 | */ |
||
334 | protected $imageTypes = array(); |
||
335 | |||
336 | /** |
||
337 | * The flag to signal that the import should be wrapped within a single transation or not. |
||
338 | * |
||
339 | * @var boolean |
||
340 | * @Type("boolean") |
||
341 | * @SerializedName("single-transaction") |
||
342 | */ |
||
343 | protected $singleTransaction = false; |
||
344 | |||
345 | /** |
||
346 | * The flag to signal that the cache should be enabled or not. |
||
347 | * |
||
348 | * @var boolean |
||
349 | * @Type("boolean") |
||
350 | * @SerializedName("cache-enabled") |
||
351 | */ |
||
352 | protected $cacheEnabled = true; |
||
353 | |||
354 | /** |
||
355 | * ArrayCollection with the information of the configured aliases. |
||
356 | * |
||
357 | * @var \Doctrine\Common\Collections\ArrayCollection |
||
358 | * @Type("ArrayCollection<TechDivision\Import\Configuration\Jms\Configuration\Alias>") |
||
359 | */ |
||
360 | protected $aliases; |
||
361 | |||
362 | /** |
||
363 | * ArrayCollection with the information of the configured caches. |
||
364 | * |
||
365 | * @var \Doctrine\Common\Collections\ArrayCollection |
||
366 | * @Type("ArrayCollection<TechDivision\Import\Configuration\Jms\Configuration\Cache>") |
||
367 | */ |
||
368 | protected $caches; |
||
369 | |||
370 | /** |
||
371 | * Return's the array with the plugins of the operation to use. |
||
372 | * |
||
373 | * @return \Doctrine\Common\Collections\ArrayCollection The ArrayCollection with the plugins |
||
374 | * @throws \Exception Is thrown, if no plugins are available for the actual operation |
||
375 | */ |
||
376 | public function getPlugins() |
||
390 | |||
391 | /** |
||
392 | * Map's the passed value to a boolean. |
||
393 | * |
||
394 | * @param string $value The value to map |
||
395 | * |
||
396 | * @return boolean The mapped value |
||
397 | * @throws \Exception Is thrown, if the value can't be mapped |
||
398 | */ |
||
399 | public function mapBoolean($value) |
||
410 | |||
411 | /** |
||
412 | * Return's the operation, initialize from the actual operation name. |
||
413 | * |
||
414 | * @return \TechDivision\Import\Configuration\OperationConfigurationInterface The operation instance |
||
415 | */ |
||
416 | public function getOperation() |
||
420 | |||
421 | /** |
||
422 | * Return's the application's unique DI identifier. |
||
423 | * |
||
424 | * @return string The application's unique DI identifier |
||
425 | */ |
||
426 | public function getId() |
||
430 | |||
431 | /** |
||
432 | * Return's the operation name that has to be used. |
||
433 | * |
||
434 | * @param string $operationName The operation name that has to be used |
||
435 | * |
||
436 | * @return void |
||
437 | */ |
||
438 | public function setOperationName($operationName) |
||
442 | |||
443 | /** |
||
444 | * Return's the operation name that has to be used. |
||
445 | * |
||
446 | * @return string The operation name that has to be used |
||
447 | */ |
||
448 | public function getOperationName() |
||
452 | |||
453 | /** |
||
454 | * Set's the Magento installation directory. |
||
455 | * |
||
456 | * @param string $installationDir The Magento installation directory |
||
457 | * |
||
458 | * @return void |
||
459 | */ |
||
460 | public function setInstallationDir($installationDir) |
||
464 | |||
465 | /** |
||
466 | * Return's the Magento installation directory. |
||
467 | * |
||
468 | * @return string The Magento installation directory |
||
469 | */ |
||
470 | public function getInstallationDir() |
||
474 | |||
475 | /** |
||
476 | * Set's the source directory that has to be watched for new files. |
||
477 | * |
||
478 | * @param string $sourceDir The source directory |
||
479 | * |
||
480 | * @return void |
||
481 | */ |
||
482 | public function setSourceDir($sourceDir) |
||
486 | |||
487 | /** |
||
488 | * Return's the source directory that has to be watched for new files. |
||
489 | * |
||
490 | * @return string The source directory |
||
491 | */ |
||
492 | public function getSourceDir() |
||
496 | |||
497 | /** |
||
498 | * Set's the target directory with the files that has been imported. |
||
499 | * |
||
500 | * @param string $targetDir The target directory |
||
501 | * |
||
502 | * @return void |
||
503 | */ |
||
504 | public function setTargetDir($targetDir) |
||
508 | |||
509 | /** |
||
510 | * Return's the target directory with the files that has been imported. |
||
511 | * |
||
512 | * @return string The target directory |
||
513 | */ |
||
514 | public function getTargetDir() |
||
518 | |||
519 | /** |
||
520 | * Set's the Magento edition, EE or CE. |
||
521 | * |
||
522 | * @param string $magentoEdition The Magento edition |
||
523 | * |
||
524 | * @return void |
||
525 | */ |
||
526 | public function setMagentoEdition($magentoEdition) |
||
530 | |||
531 | /** |
||
532 | * Return's the Magento edition, EE or CE. |
||
533 | * |
||
534 | * @return string The Magento edition |
||
535 | */ |
||
536 | public function getMagentoEdition() |
||
540 | |||
541 | /** |
||
542 | * Return's the Magento version, e. g. 2.1.0. |
||
543 | * |
||
544 | * @param string $magentoVersion The Magento version |
||
545 | * |
||
546 | * @return void |
||
547 | */ |
||
548 | public function setMagentoVersion($magentoVersion) |
||
552 | |||
553 | /** |
||
554 | * Return's the Magento version, e. g. 2.1.0. |
||
555 | * |
||
556 | * @return string The Magento version |
||
557 | */ |
||
558 | public function getMagentoVersion() |
||
562 | |||
563 | /** |
||
564 | * Return's the entity type code to be used. |
||
565 | * |
||
566 | * @return string The entity type code to be used |
||
567 | */ |
||
568 | public function getEntityTypeCode() |
||
572 | |||
573 | /** |
||
574 | * Set's the entity type code to be used. |
||
575 | * |
||
576 | * @param string $entityTypeCode The entity type code |
||
577 | * |
||
578 | * @return void |
||
579 | */ |
||
580 | public function setEntityTypeCode($entityTypeCode) |
||
584 | |||
585 | /** |
||
586 | * Return's the multiple field delimiter character to use, default value is comma (,). |
||
587 | * |
||
588 | * @return string The multiple field delimiter character |
||
589 | */ |
||
590 | public function getMultipleFieldDelimiter() |
||
594 | |||
595 | /** |
||
596 | * Return's the multiple value delimiter character to use, default value is comma (|). |
||
597 | * |
||
598 | * @return string The multiple value delimiter character |
||
599 | */ |
||
600 | public function getMultipleValueDelimiter() |
||
604 | |||
605 | /** |
||
606 | * Queries whether or not strict mode is enabled or not, default is TRUE. |
||
607 | * |
||
608 | * @return boolean TRUE if strict mode is enabled, else FALSE |
||
609 | */ |
||
610 | public function isStrictMode() |
||
614 | |||
615 | /** |
||
616 | * Remove's all configured database configuration. |
||
617 | * |
||
618 | * @return void |
||
619 | */ |
||
620 | public function clearDatabases() |
||
624 | |||
625 | /** |
||
626 | * Add's the passed database configuration. |
||
627 | * |
||
628 | * @param \TechDivision\Import\Configuration\DatabaseConfigurationInterface $database The database configuration |
||
629 | * |
||
630 | * @return void |
||
631 | */ |
||
632 | public function addDatabase(DatabaseConfigurationInterface $database) |
||
636 | |||
637 | /** |
||
638 | * Return's the number database configurations. |
||
639 | * |
||
640 | * @return integer The number of database configurations |
||
641 | */ |
||
642 | public function countDatabases() |
||
646 | |||
647 | /** |
||
648 | * Return's the database configuration with the passed ID. |
||
649 | * |
||
650 | * @param string $id The ID of the database connection to return |
||
651 | * |
||
652 | * @return \TechDivision\Import\Configuration\DatabaseConfigurationInterface The database configuration |
||
653 | * @throws \Exception Is thrown, if no database configuration is available |
||
654 | */ |
||
655 | public function getDatabaseById($id) |
||
669 | |||
670 | /** |
||
671 | * Return's the databases for the given type. |
||
672 | * |
||
673 | * @param string $type The database type to return the configurations for |
||
674 | * |
||
675 | * @return \Doctrine\Common\Collections\Collection The collection with the database configurations |
||
676 | */ |
||
677 | public function getDatabasesByType($type) |
||
694 | |||
695 | /** |
||
696 | * Query's whether or not the passed database configuration has a valid type. |
||
697 | * |
||
698 | * @param \TechDivision\Import\Configuration\DatabaseConfigurationInterface $database The database configuration |
||
699 | * |
||
700 | * @return boolean TRUE if the passed database configuration has a valid type, else FALSE |
||
701 | */ |
||
702 | protected function isValidDatabaseType(DatabaseConfigurationInterface $database) |
||
706 | |||
707 | /** |
||
708 | * Return's the database configuration. |
||
709 | * |
||
710 | * If an explicit DB ID is specified, the method tries to return the database with this ID. If |
||
711 | * the database configuration is NOT available, an execption is thrown. |
||
712 | * |
||
713 | * If no explicit DB ID is specified, the method tries to return the default database configuration, |
||
714 | * if not available the first one. |
||
715 | * |
||
716 | * @return \TechDivision\Import\Configuration\DatabaseConfigurationInterface The database configuration |
||
717 | * @throws \Exception Is thrown, if no database configuration is available |
||
718 | */ |
||
719 | public function getDatabase() |
||
743 | |||
744 | /** |
||
745 | * Return's the ArrayCollection with the configured operations. |
||
746 | * |
||
747 | * @return \Doctrine\Common\Collections\ArrayCollection The ArrayCollection with the operations |
||
748 | */ |
||
749 | public function getOperations() |
||
753 | |||
754 | /** |
||
755 | * Return's the ArrayCollection with the configured loggers. |
||
756 | * |
||
757 | * @return \Doctrine\Common\Collections\ArrayCollection The ArrayCollection with the loggers |
||
758 | */ |
||
759 | public function getLoggers() |
||
763 | |||
764 | /** |
||
765 | * Set's the flag that import artefacts have to be archived or not. |
||
766 | * |
||
767 | * @param boolean $archiveArtefacts TRUE if artefacts have to be archived, else FALSE |
||
768 | * |
||
769 | * @return void |
||
770 | */ |
||
771 | public function setArchiveArtefacts($archiveArtefacts) |
||
775 | |||
776 | /** |
||
777 | * Return's the TRUE if the import artefacts have to be archived. |
||
778 | * |
||
779 | * @return boolean TRUE if the import artefacts have to be archived |
||
780 | */ |
||
781 | public function haveArchiveArtefacts() |
||
785 | |||
786 | /** |
||
787 | * The directory where the archives will be stored. |
||
788 | * |
||
789 | * @param string $archiveDir The archive directory |
||
790 | * |
||
791 | * @return void |
||
792 | */ |
||
793 | public function setArchiveDir($archiveDir) |
||
797 | |||
798 | /** |
||
799 | * The directory where the archives will be stored. |
||
800 | * |
||
801 | * @return string The archive directory |
||
802 | */ |
||
803 | public function getArchiveDir() |
||
807 | |||
808 | /** |
||
809 | * Set's the debug mode. |
||
810 | * |
||
811 | * @param boolean $debugMode TRUE if debug mode is enabled, else FALSE |
||
812 | * |
||
813 | * @return void |
||
814 | */ |
||
815 | public function setDebugMode($debugMode) |
||
819 | |||
820 | /** |
||
821 | * Queries whether or not debug mode is enabled or not, default is TRUE. |
||
822 | * |
||
823 | * @return boolean TRUE if debug mode is enabled, else FALSE |
||
824 | */ |
||
825 | public function isDebugMode() |
||
829 | |||
830 | /** |
||
831 | * Set's the log level to use. |
||
832 | * |
||
833 | * @param string $logLevel The log level to use |
||
834 | * |
||
835 | * @return void |
||
836 | */ |
||
837 | public function setLogLevel($logLevel) |
||
841 | |||
842 | /** |
||
843 | * Return's the log level to use. |
||
844 | * |
||
845 | * @return string The log level to use |
||
846 | */ |
||
847 | public function getLogLevel() |
||
851 | |||
852 | /** |
||
853 | * Set's the explicit DB ID to use. |
||
854 | * |
||
855 | * @param string $useDbId The explicit DB ID to use |
||
856 | * |
||
857 | * @return void |
||
858 | */ |
||
859 | public function setUseDbId($useDbId) |
||
863 | |||
864 | /** |
||
865 | * Return's the explicit DB ID to use. |
||
866 | * |
||
867 | * @return string The explicit DB ID to use |
||
868 | */ |
||
869 | public function getUseDbId() |
||
873 | |||
874 | /** |
||
875 | * Set's the PID filename to use. |
||
876 | * |
||
877 | * @param string $pidFilename The PID filename to use |
||
878 | * |
||
879 | * @return void |
||
880 | */ |
||
881 | public function setPidFilename($pidFilename) |
||
885 | |||
886 | /** |
||
887 | * Return's the PID filename to use. |
||
888 | * |
||
889 | * @return string The PID filename to use |
||
890 | */ |
||
891 | public function getPidFilename() |
||
895 | |||
896 | /** |
||
897 | * Set's the systemm name to be used. |
||
898 | * |
||
899 | * @param string $systemName The system name to be used |
||
900 | * |
||
901 | * @return void |
||
902 | */ |
||
903 | public function setSystemName($systemName) |
||
907 | |||
908 | /** |
||
909 | * Return's the systemm name to be used. |
||
910 | * |
||
911 | * @return string The system name to be used |
||
912 | */ |
||
913 | public function getSystemName() |
||
917 | |||
918 | /** |
||
919 | * Set's the collection with the path of the Magento Edition specific extension libraries. |
||
920 | * |
||
921 | * @param array $extensionLibraries The paths of the Magento Edition specific extension libraries |
||
922 | * |
||
923 | * @return void |
||
924 | */ |
||
925 | public function setExtensionLibraries(array $extensionLibraries) |
||
929 | |||
930 | /** |
||
931 | * Return's an array with the path of the Magento Edition specific extension libraries. |
||
932 | * |
||
933 | * @return array The paths of the Magento Edition specific extension libraries |
||
934 | */ |
||
935 | public function getExtensionLibraries() |
||
939 | |||
940 | /** |
||
941 | * Return's a collection with the path to additional vendor directories. |
||
942 | * |
||
943 | * @return \Doctrine\Common\Collections\ArrayCollection The paths to additional vendor directories |
||
944 | */ |
||
945 | public function getAdditionalVendorDirs() |
||
949 | |||
950 | /** |
||
951 | * Lifecycle callback that will be invoked after deserialization. |
||
952 | * |
||
953 | * @return void |
||
954 | * @PostDeserialize |
||
955 | */ |
||
956 | public function postDeserialize() |
||
984 | |||
985 | /** |
||
986 | * The array with the subject's custom header mappings. |
||
987 | * |
||
988 | * @return array The custom header mappings |
||
989 | */ |
||
990 | public function getHeaderMappings() |
||
1004 | |||
1005 | /** |
||
1006 | * The array with the subject's custom image types. |
||
1007 | * |
||
1008 | * @return array The custom image types |
||
1009 | */ |
||
1010 | public function getImageTypes() |
||
1024 | |||
1025 | /** |
||
1026 | * Set's the flag that decides whether or not the import should be wrapped within a single transaction. |
||
1027 | * |
||
1028 | * @param boolean $singleTransaction TRUE if the import should be wrapped in a single transation, else FALSE |
||
1029 | * |
||
1030 | * @return void |
||
1031 | */ |
||
1032 | public function setSingleTransaction($singleTransaction) |
||
1036 | |||
1037 | /** |
||
1038 | * Whether or not the import should be wrapped within a single transation. |
||
1039 | * |
||
1040 | * @return boolean TRUE if the import should be wrapped in a single transation, else FALSE |
||
1041 | */ |
||
1042 | public function isSingleTransaction() |
||
1046 | |||
1047 | /** |
||
1048 | * Set's the flag that decides whether or not the the cache has been enabled. |
||
1049 | * |
||
1050 | * @param boolean $cacheEnabled TRUE if the cache has been enabled, else FALSE |
||
1051 | * |
||
1052 | * @return void |
||
1053 | */ |
||
1054 | public function setCacheEnabled($cacheEnabled) |
||
1058 | |||
1059 | /** |
||
1060 | * Whether or not the cache functionality should be enabled. |
||
1061 | * |
||
1062 | * @return boolean TRUE if the cache has to be enabled, else FALSE |
||
1063 | */ |
||
1064 | public function isCacheEnabled() |
||
1068 | |||
1069 | /** |
||
1070 | * Set's the passed serial from the commandline to the configuration. |
||
1071 | * |
||
1072 | * @param string $serial The serial from the commandline |
||
1073 | * |
||
1074 | * @return void |
||
1075 | */ |
||
1076 | public function setSerial($serial) |
||
1080 | |||
1081 | /** |
||
1082 | * Return's the serial from the commandline. |
||
1083 | * |
||
1084 | * @return string The serial |
||
1085 | */ |
||
1086 | public function getSerial() |
||
1090 | |||
1091 | /** |
||
1092 | * Return's the configuration for the caches. |
||
1093 | * |
||
1094 | * @return \Doctrine\Common\Collections\ArrayCollection The cache configurations |
||
1095 | */ |
||
1096 | public function getCaches() |
||
1107 | |||
1108 | /** |
||
1109 | * Return's the cache configuration for the passed type. |
||
1110 | * |
||
1111 | * @param string $type The cache type to return the configuation for |
||
1112 | * |
||
1113 | * @return \TechDivision\Import\Configuration\CacheConfigurationInterface The cache configuration |
||
1114 | */ |
||
1115 | public function getCacheByType($type) |
||
1129 | |||
1130 | /** |
||
1131 | * Return's the alias configuration. |
||
1132 | * |
||
1133 | * @return \Doctrine\Common\Collections\ArrayCollection The alias configuration |
||
1134 | */ |
||
1135 | public function getAliases() |
||
1139 | } |
||
1140 |