001// -------------------------------------------------------------------------------- 002// Copyright 2002-2024 Echo Three, LLC 003// 004// Licensed under the Apache License, Version 2.0 (the "License"); 005// you may not use this file except in compliance with the License. 006// You may obtain a copy of the License at 007// 008// http://www.apache.org/licenses/LICENSE-2.0 009// 010// Unless required by applicable law or agreed to in writing, software 011// distributed under the License is distributed on an "AS IS" BASIS, 012// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013// See the License for the specific language governing permissions and 014// limitations under the License. 015// -------------------------------------------------------------------------------- 016 017package com.echothree.model.control.employee.server.transfer; 018 019import com.echothree.model.control.employee.server.control.EmployeeControl; 020import com.echothree.model.data.user.server.entity.UserVisit; 021import com.echothree.util.server.transfer.BaseTransferCaches; 022 023public class EmployeeTransferCaches 024 extends BaseTransferCaches { 025 026 protected EmployeeControl employeeControl; 027 028 protected EmployeeTypeTransferCache employeeTypeTransferCache; 029 protected EmployeeTypeDescriptionTransferCache employeeTypeDescriptionTransferCache; 030 protected EmployeeTransferCache employeeTransferCache; 031 protected ResponsibilityTypeTransferCache responsibilityTypeTransferCache; 032 protected ResponsibilityTypeDescriptionTransferCache responsibilityTypeDescriptionTransferCache; 033 protected SkillTypeTransferCache skillTypeTransferCache; 034 protected SkillTypeDescriptionTransferCache skillTypeDescriptionTransferCache; 035 protected LeaveTypeTransferCache leaveTypeTransferCache; 036 protected LeaveTypeDescriptionTransferCache leaveTypeDescriptionTransferCache; 037 protected LeaveReasonTransferCache leaveReasonTransferCache; 038 protected LeaveReasonDescriptionTransferCache leaveReasonDescriptionTransferCache; 039 protected LeaveTransferCache leaveTransferCache; 040 protected TerminationReasonTransferCache terminationReasonTransferCache; 041 protected TerminationReasonDescriptionTransferCache terminationReasonDescriptionTransferCache; 042 protected TerminationTypeTransferCache terminationTypeTransferCache; 043 protected TerminationTypeDescriptionTransferCache terminationTypeDescriptionTransferCache; 044 protected EmploymentTransferCache employmentTransferCache; 045 protected PartyResponsibilityTransferCache partyResponsibilityTransferCache; 046 protected PartySkillTransferCache partySkillTransferCache; 047 048 /** Creates a new instance of EmployeeTransferCaches */ 049 public EmployeeTransferCaches(UserVisit userVisit, EmployeeControl employeeControl) { 050 super(userVisit); 051 052 this.employeeControl = employeeControl; 053 } 054 055 public EmployeeTypeTransferCache getEmployeeTypeTransferCache() { 056 if(employeeTypeTransferCache == null) 057 employeeTypeTransferCache = new EmployeeTypeTransferCache(userVisit, employeeControl); 058 059 return employeeTypeTransferCache; 060 } 061 062 public EmployeeTypeDescriptionTransferCache getEmployeeTypeDescriptionTransferCache() { 063 if(employeeTypeDescriptionTransferCache == null) 064 employeeTypeDescriptionTransferCache = new EmployeeTypeDescriptionTransferCache(userVisit, employeeControl); 065 066 return employeeTypeDescriptionTransferCache; 067 } 068 069 public EmployeeTransferCache getEmployeeTransferCache() { 070 if(employeeTransferCache == null) { 071 employeeTransferCache = new EmployeeTransferCache(userVisit, employeeControl); 072 } 073 074 return employeeTransferCache; 075 } 076 077 public ResponsibilityTypeTransferCache getResponsibilityTypeTransferCache() { 078 if(responsibilityTypeTransferCache == null) { 079 responsibilityTypeTransferCache = new ResponsibilityTypeTransferCache(userVisit, employeeControl); 080 } 081 082 return responsibilityTypeTransferCache; 083 } 084 085 public ResponsibilityTypeDescriptionTransferCache getResponsibilityTypeDescriptionTransferCache() { 086 if(responsibilityTypeDescriptionTransferCache == null) { 087 responsibilityTypeDescriptionTransferCache = new ResponsibilityTypeDescriptionTransferCache(userVisit, employeeControl); 088 } 089 090 return responsibilityTypeDescriptionTransferCache; 091 } 092 093 public SkillTypeTransferCache getSkillTypeTransferCache() { 094 if(skillTypeTransferCache == null) { 095 skillTypeTransferCache = new SkillTypeTransferCache(userVisit, employeeControl); 096 } 097 098 return skillTypeTransferCache; 099 } 100 101 public SkillTypeDescriptionTransferCache getSkillTypeDescriptionTransferCache() { 102 if(skillTypeDescriptionTransferCache == null) { 103 skillTypeDescriptionTransferCache = new SkillTypeDescriptionTransferCache(userVisit, employeeControl); 104 } 105 106 return skillTypeDescriptionTransferCache; 107 } 108 109 public LeaveTypeTransferCache getLeaveTypeTransferCache() { 110 if(leaveTypeTransferCache == null) { 111 leaveTypeTransferCache = new LeaveTypeTransferCache(userVisit, employeeControl); 112 } 113 114 return leaveTypeTransferCache; 115 } 116 117 public LeaveTypeDescriptionTransferCache getLeaveTypeDescriptionTransferCache() { 118 if(leaveTypeDescriptionTransferCache == null) { 119 leaveTypeDescriptionTransferCache = new LeaveTypeDescriptionTransferCache(userVisit, employeeControl); 120 } 121 122 return leaveTypeDescriptionTransferCache; 123 } 124 125 public LeaveReasonTransferCache getLeaveReasonTransferCache() { 126 if(leaveReasonTransferCache == null) { 127 leaveReasonTransferCache = new LeaveReasonTransferCache(userVisit, employeeControl); 128 } 129 130 return leaveReasonTransferCache; 131 } 132 133 public LeaveReasonDescriptionTransferCache getLeaveReasonDescriptionTransferCache() { 134 if(leaveReasonDescriptionTransferCache == null) { 135 leaveReasonDescriptionTransferCache = new LeaveReasonDescriptionTransferCache(userVisit, employeeControl); 136 } 137 138 return leaveReasonDescriptionTransferCache; 139 } 140 141 public LeaveTransferCache getLeaveTransferCache() { 142 if(leaveTransferCache == null) { 143 leaveTransferCache = new LeaveTransferCache(userVisit, employeeControl); 144 } 145 146 return leaveTransferCache; 147 } 148 149 public TerminationReasonTransferCache getTerminationReasonTransferCache() { 150 if(terminationReasonTransferCache == null) { 151 terminationReasonTransferCache = new TerminationReasonTransferCache(userVisit, employeeControl); 152 } 153 154 return terminationReasonTransferCache; 155 } 156 157 public TerminationReasonDescriptionTransferCache getTerminationReasonDescriptionTransferCache() { 158 if(terminationReasonDescriptionTransferCache == null) { 159 terminationReasonDescriptionTransferCache = new TerminationReasonDescriptionTransferCache(userVisit, employeeControl); 160 } 161 162 return terminationReasonDescriptionTransferCache; 163 } 164 165 public TerminationTypeTransferCache getTerminationTypeTransferCache() { 166 if(terminationTypeTransferCache == null) { 167 terminationTypeTransferCache = new TerminationTypeTransferCache(userVisit, employeeControl); 168 } 169 170 return terminationTypeTransferCache; 171 } 172 173 public TerminationTypeDescriptionTransferCache getTerminationTypeDescriptionTransferCache() { 174 if(terminationTypeDescriptionTransferCache == null) { 175 terminationTypeDescriptionTransferCache = new TerminationTypeDescriptionTransferCache(userVisit, employeeControl); 176 } 177 178 return terminationTypeDescriptionTransferCache; 179 } 180 181 public EmploymentTransferCache getEmploymentTransferCache() { 182 if(employmentTransferCache == null) { 183 employmentTransferCache = new EmploymentTransferCache(userVisit, employeeControl); 184 } 185 186 return employmentTransferCache; 187 } 188 189 public PartyResponsibilityTransferCache getPartyResponsibilityTransferCache() { 190 if(partyResponsibilityTransferCache == null) { 191 partyResponsibilityTransferCache = new PartyResponsibilityTransferCache(userVisit, employeeControl); 192 } 193 194 return partyResponsibilityTransferCache; 195 } 196 197 public PartySkillTransferCache getPartySkillTransferCache() { 198 if(partySkillTransferCache == null) { 199 partySkillTransferCache = new PartySkillTransferCache(userVisit, employeeControl); 200 } 201 202 return partySkillTransferCache; 203 } 204 205}