2 * Copyright (C) 2007 EDIT
3 * European Distributed Institute of Taxonomy
4 * http://www.e-taxonomy.eu
6 * The contents of this file are subject to the Mozilla Public License Version 1.1
7 * See LICENSE.TXT at the top of this package for the full license terms.
10 package eu
.etaxonomy
.cdm
.api
.facade
;
12 import java
.util
.List
;
14 import org
.apache
.log4j
.Logger
;
16 import eu
.etaxonomy
.cdm
.api
.service
.IOccurrenceService
;
22 public class DerivedUnitFacadeConfigurator
{
23 @SuppressWarnings("unused")
24 private static final Logger logger
= Logger
.getLogger(DerivedUnitFacadeConfigurator
.class);
27 public static DerivedUnitFacadeConfigurator
NewInstance(){
28 return new DerivedUnitFacadeConfigurator();
32 private boolean moveFieldObjectMediaToGallery
= false;
34 private boolean moveDerivedUnitMediaToGallery
= false;
36 private boolean throwExceptionForNonSpecimenPreservationMethodRequest
= true;
38 private boolean firePropertyChangeEvents
= true;
41 //needed if inititialization via property paths is required
42 private IOccurrenceService occurrenceService
;
44 //for object initialization
45 private List
<String
> propertyPaths
;
48 private DerivedUnitFacadeConfigurator(){
52 // ************************ GETTER / SETTER **********************************
54 public void setMoveFieldObjectMediaToGallery(
55 boolean moveFieldObjectMediaToGallery
) {
56 this.moveFieldObjectMediaToGallery
= moveFieldObjectMediaToGallery
;
59 public boolean isMoveFieldObjectMediaToGallery() {
60 return moveFieldObjectMediaToGallery
;
63 public void setMoveDerivedUnitMediaToGallery(
64 boolean moveDerivedUnitMediaToGallery
) {
65 this.moveDerivedUnitMediaToGallery
= moveDerivedUnitMediaToGallery
;
68 public boolean isMoveDerivedUnitMediaToGallery() {
69 return moveDerivedUnitMediaToGallery
;
72 public void setOccurrenceService(IOccurrenceService occurrenceService
) {
73 this.occurrenceService
= occurrenceService
;
78 * Needed for object initialization.
79 * @see #getPropertyPaths()
82 public IOccurrenceService
getOccurrenceService() {
83 return occurrenceService
;
86 public void setPropertyPaths(List
<String
> propertyPaths
) {
87 this.propertyPaths
= propertyPaths
;
91 * Needed for object initialization.
92 * Also requires to set occurrence service
93 * @see #getOccurrenceService()
96 public List
<String
> getPropertyPaths() {
101 * @param throwExceptionForNonSpecimenPreservationMethodRequest the throwExceptionForNonSpecimenPreservationMethodRequest to set
103 public void setThrowExceptionForNonSpecimenPreservationMethodRequest(
104 boolean throwExceptionForNonSpecimenPreservationMethodRequest
) {
105 this.throwExceptionForNonSpecimenPreservationMethodRequest
= throwExceptionForNonSpecimenPreservationMethodRequest
;
109 * @return the throwExceptionForNonSpecimenPreservationMethodRequest
111 public boolean isThrowExceptionForNonSpecimenPreservationMethodRequest() {
112 return throwExceptionForNonSpecimenPreservationMethodRequest
;
115 public void setFirePropertyChangeEvents(boolean firePropertyChangeEvents
) {
116 this.firePropertyChangeEvents
= firePropertyChangeEvents
;
119 public boolean isFirePropertyChangeEvents() {
120 return firePropertyChangeEvents
;