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.contact.server.transfer; 018 019import com.echothree.model.control.contact.server.control.ContactControl; 020import com.echothree.model.data.user.server.entity.UserVisit; 021import com.echothree.util.server.transfer.BaseTransferCaches; 022 023public class ContactTransferCaches 024 extends BaseTransferCaches { 025 026 protected ContactControl contactControl; 027 028 protected PostalAddressFormatTransferCache postalAddressFormatTransferCache; 029 protected PostalAddressElementTypeTransferCache postalAddressElementTypeTransferCache; 030 protected ContactMechanismAliasTypeTransferCache contactMechanismAliasTypeTransferCache; 031 protected ContactMechanismAliasTypeDescriptionTransferCache contactMechanismAliasTypeDescriptionTransferCache; 032 protected ContactMechanismPurposeTransferCache contactMechanismPurposeTransferCache; 033 protected ContactMechanismTypeTransferCache contactMechanismTypeTransferCache; 034 protected ContactMechanismTransferCache contactMechanismTransferCache; 035 protected ContactEmailAddressTransferCache contactEmailAddressTransferCache; 036 protected ContactPostalAddressTransferCache contactPostalAddressTransferCache; 037 protected ContactTelephoneTransferCache contactTelephoneTransferCache; 038 protected PostalAddressFormatDescriptionTransferCache postalAddressFormatDescriptionTransferCache; 039 protected PostalAddressLineTransferCache postalAddressLineTransferCache; 040 protected PostalAddressLineElementTransferCache postalAddressLineElementTransferCache; 041 protected ContactWebAddressTransferCache contactWebAddressTransferCache; 042 protected ContactMechanismAliasTransferCache contactMechanismAliasTransferCache; 043 protected PartyContactMechanismAliasTransferCache partyContactMechanismAliasTransferCache; 044 protected PartyContactMechanismPurposeTransferCache partyContactMechanismPurposeTransferCache; 045 protected PartyContactMechanismRelationshipTransferCache partyContactMechanismRelationshipTransferCache; 046 protected PartyContactMechanismTransferCache partyContactMechanismTransferCache; 047 protected ContactInet4AddressTransferCache contactInet4AddressTransferCache; 048 049 /** Creates a new instance of ContactTransferCaches */ 050 public ContactTransferCaches(UserVisit userVisit, ContactControl contactControl) { 051 super(userVisit); 052 053 this.contactControl = contactControl; 054 } 055 056 public PostalAddressFormatTransferCache getPostalAddressFormatTransferCache() { 057 if(postalAddressFormatTransferCache == null) 058 postalAddressFormatTransferCache = new PostalAddressFormatTransferCache(userVisit, contactControl); 059 060 return postalAddressFormatTransferCache; 061 } 062 063 public PostalAddressElementTypeTransferCache getPostalAddressElementTypeTransferCache() { 064 if(postalAddressElementTypeTransferCache == null) 065 postalAddressElementTypeTransferCache = new PostalAddressElementTypeTransferCache(userVisit, contactControl); 066 067 return postalAddressElementTypeTransferCache; 068 } 069 070 public ContactMechanismAliasTypeTransferCache getContactMechanismAliasTypeTransferCache() { 071 if(contactMechanismAliasTypeTransferCache == null) 072 contactMechanismAliasTypeTransferCache = new ContactMechanismAliasTypeTransferCache(userVisit, contactControl); 073 074 return contactMechanismAliasTypeTransferCache; 075 } 076 077 public ContactMechanismAliasTypeDescriptionTransferCache getContactMechanismAliasTypeDescriptionTransferCache() { 078 if(contactMechanismAliasTypeDescriptionTransferCache == null) 079 contactMechanismAliasTypeDescriptionTransferCache = new ContactMechanismAliasTypeDescriptionTransferCache(userVisit, contactControl); 080 081 return contactMechanismAliasTypeDescriptionTransferCache; 082 } 083 084 public ContactMechanismPurposeTransferCache getContactMechanismPurposeTransferCache() { 085 if(contactMechanismPurposeTransferCache == null) 086 contactMechanismPurposeTransferCache = new ContactMechanismPurposeTransferCache(userVisit, contactControl); 087 088 return contactMechanismPurposeTransferCache; 089 } 090 091 public ContactMechanismTypeTransferCache getContactMechanismTypeTransferCache() { 092 if(contactMechanismTypeTransferCache == null) 093 contactMechanismTypeTransferCache = new ContactMechanismTypeTransferCache(userVisit, contactControl); 094 095 return contactMechanismTypeTransferCache; 096 } 097 098 public ContactMechanismTransferCache getContactMechanismTransferCache() { 099 if(contactMechanismTransferCache == null) 100 contactMechanismTransferCache = new ContactMechanismTransferCache(userVisit, contactControl); 101 102 return contactMechanismTransferCache; 103 } 104 105 public ContactEmailAddressTransferCache getContactEmailAddressTransferCache() { 106 if(contactEmailAddressTransferCache == null) 107 contactEmailAddressTransferCache = new ContactEmailAddressTransferCache(userVisit, contactControl); 108 109 return contactEmailAddressTransferCache; 110 } 111 112 public ContactPostalAddressTransferCache getContactPostalAddressTransferCache() { 113 if(contactPostalAddressTransferCache == null) 114 contactPostalAddressTransferCache = new ContactPostalAddressTransferCache(userVisit, contactControl); 115 116 return contactPostalAddressTransferCache; 117 } 118 119 public ContactTelephoneTransferCache getContactTelephoneTransferCache() { 120 if(contactTelephoneTransferCache == null) 121 contactTelephoneTransferCache = new ContactTelephoneTransferCache(userVisit, contactControl); 122 123 return contactTelephoneTransferCache; 124 } 125 126 public PostalAddressFormatDescriptionTransferCache getPostalAddressFormatDescriptionTransferCache() { 127 if(postalAddressFormatDescriptionTransferCache == null) 128 postalAddressFormatDescriptionTransferCache = new PostalAddressFormatDescriptionTransferCache(userVisit, contactControl); 129 130 return postalAddressFormatDescriptionTransferCache; 131 } 132 133 public PostalAddressLineTransferCache getPostalAddressLineTransferCache() { 134 if(postalAddressLineTransferCache == null) 135 postalAddressLineTransferCache = new PostalAddressLineTransferCache(userVisit, contactControl); 136 137 return postalAddressLineTransferCache; 138 } 139 140 public PostalAddressLineElementTransferCache getPostalAddressLineElementTransferCache() { 141 if(postalAddressLineElementTransferCache == null) 142 postalAddressLineElementTransferCache = new PostalAddressLineElementTransferCache(userVisit, contactControl); 143 144 return postalAddressLineElementTransferCache; 145 } 146 147 public ContactWebAddressTransferCache getContactWebAddressTransferCache() { 148 if(contactWebAddressTransferCache == null) 149 contactWebAddressTransferCache = new ContactWebAddressTransferCache(userVisit, contactControl); 150 151 return contactWebAddressTransferCache; 152 } 153 154 public ContactMechanismAliasTransferCache getContactMechanismAliasTransferCache() { 155 if(contactMechanismAliasTransferCache == null) 156 contactMechanismAliasTransferCache = new ContactMechanismAliasTransferCache(userVisit, contactControl); 157 158 return contactMechanismAliasTransferCache; 159 } 160 161 public PartyContactMechanismAliasTransferCache getPartyContactMechanismAliasTransferCache() { 162 if(partyContactMechanismAliasTransferCache == null) 163 partyContactMechanismAliasTransferCache = new PartyContactMechanismAliasTransferCache(userVisit, contactControl); 164 165 return partyContactMechanismAliasTransferCache; 166 } 167 168 public PartyContactMechanismPurposeTransferCache getPartyContactMechanismPurposeTransferCache() { 169 if(partyContactMechanismPurposeTransferCache == null) 170 partyContactMechanismPurposeTransferCache = new PartyContactMechanismPurposeTransferCache(userVisit, contactControl); 171 172 return partyContactMechanismPurposeTransferCache; 173 } 174 175 public PartyContactMechanismRelationshipTransferCache getPartyContactMechanismRelationshipTransferCache() { 176 if(partyContactMechanismRelationshipTransferCache == null) 177 partyContactMechanismRelationshipTransferCache = new PartyContactMechanismRelationshipTransferCache(userVisit, contactControl); 178 179 return partyContactMechanismRelationshipTransferCache; 180 } 181 182 public PartyContactMechanismTransferCache getPartyContactMechanismTransferCache() { 183 if(partyContactMechanismTransferCache == null) 184 partyContactMechanismTransferCache = new PartyContactMechanismTransferCache(userVisit, contactControl); 185 186 return partyContactMechanismTransferCache; 187 } 188 189 public ContactInet4AddressTransferCache getContactInet4AddressTransferCache() { 190 if(contactInet4AddressTransferCache == null) 191 contactInet4AddressTransferCache = new ContactInet4AddressTransferCache(userVisit, contactControl); 192 193 return contactInet4AddressTransferCache; 194 } 195 196}