001// --------------------------------------------------------------------------------
002// Copyright 2002-2026 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.control.user.graphql.server.schema;
018
019import com.echothree.control.user.accounting.common.AccountingUtil;
020import com.echothree.control.user.accounting.server.command.GetCurrenciesCommand;
021import com.echothree.control.user.accounting.server.command.GetCurrencyCommand;
022import com.echothree.control.user.accounting.server.command.GetGlAccountCategoriesCommand;
023import com.echothree.control.user.accounting.server.command.GetGlAccountCategoryCommand;
024import com.echothree.control.user.accounting.server.command.GetGlAccountClassCommand;
025import com.echothree.control.user.accounting.server.command.GetGlAccountClassesCommand;
026import com.echothree.control.user.accounting.server.command.GetGlAccountCommand;
027import com.echothree.control.user.accounting.server.command.GetGlAccountTypeCommand;
028import com.echothree.control.user.accounting.server.command.GetGlAccountTypesCommand;
029import com.echothree.control.user.accounting.server.command.GetGlAccountsCommand;
030import com.echothree.control.user.accounting.server.command.GetGlResourceTypeCommand;
031import com.echothree.control.user.accounting.server.command.GetGlResourceTypesCommand;
032import com.echothree.control.user.accounting.server.command.GetItemAccountingCategoriesCommand;
033import com.echothree.control.user.accounting.server.command.GetItemAccountingCategoryCommand;
034import com.echothree.control.user.accounting.server.command.GetSymbolPositionCommand;
035import com.echothree.control.user.accounting.server.command.GetSymbolPositionsCommand;
036import com.echothree.control.user.accounting.server.command.GetTransactionCommand;
037import com.echothree.control.user.accounting.server.command.GetTransactionEntityRoleTypeCommand;
038import com.echothree.control.user.accounting.server.command.GetTransactionEntityRoleTypesCommand;
039import com.echothree.control.user.accounting.server.command.GetTransactionGlAccountCategoriesCommand;
040import com.echothree.control.user.accounting.server.command.GetTransactionGlAccountCategoryCommand;
041import com.echothree.control.user.accounting.server.command.GetTransactionGroupCommand;
042import com.echothree.control.user.accounting.server.command.GetTransactionGroupsCommand;
043import com.echothree.control.user.accounting.server.command.GetTransactionTimeTypeCommand;
044import com.echothree.control.user.accounting.server.command.GetTransactionTimeTypesCommand;
045import com.echothree.control.user.accounting.server.command.GetTransactionTypeCommand;
046import com.echothree.control.user.accounting.server.command.GetTransactionTypesCommand;
047import com.echothree.control.user.accounting.server.command.GetTransactionsCommand;
048import com.echothree.control.user.campaign.common.CampaignUtil;
049import com.echothree.control.user.campaign.server.command.GetCampaignCommand;
050import com.echothree.control.user.campaign.server.command.GetCampaignContentCommand;
051import com.echothree.control.user.campaign.server.command.GetCampaignContentsCommand;
052import com.echothree.control.user.campaign.server.command.GetCampaignMediumCommand;
053import com.echothree.control.user.campaign.server.command.GetCampaignMediumsCommand;
054import com.echothree.control.user.campaign.server.command.GetCampaignSourceCommand;
055import com.echothree.control.user.campaign.server.command.GetCampaignSourcesCommand;
056import com.echothree.control.user.campaign.server.command.GetCampaignTermCommand;
057import com.echothree.control.user.campaign.server.command.GetCampaignTermsCommand;
058import com.echothree.control.user.campaign.server.command.GetCampaignsCommand;
059import com.echothree.control.user.cancellationpolicy.common.CancellationPolicyUtil;
060import com.echothree.control.user.cancellationpolicy.server.command.GetCancellationKindCommand;
061import com.echothree.control.user.cancellationpolicy.server.command.GetCancellationKindsCommand;
062import com.echothree.control.user.cancellationpolicy.server.command.GetCancellationPoliciesCommand;
063import com.echothree.control.user.cancellationpolicy.server.command.GetCancellationPolicyCommand;
064import com.echothree.control.user.chain.common.ChainUtil;
065import com.echothree.control.user.chain.server.command.GetChainActionCommand;
066import com.echothree.control.user.chain.server.command.GetChainActionSetCommand;
067import com.echothree.control.user.chain.server.command.GetChainActionSetsCommand;
068import com.echothree.control.user.chain.server.command.GetChainActionTypeCommand;
069import com.echothree.control.user.chain.server.command.GetChainActionTypesCommand;
070import com.echothree.control.user.chain.server.command.GetChainActionsCommand;
071import com.echothree.control.user.chain.server.command.GetChainCommand;
072import com.echothree.control.user.chain.server.command.GetChainEntityRoleTypeCommand;
073import com.echothree.control.user.chain.server.command.GetChainEntityRoleTypesCommand;
074import com.echothree.control.user.chain.server.command.GetChainInstanceCommand;
075import com.echothree.control.user.chain.server.command.GetChainInstancesCommand;
076import com.echothree.control.user.chain.server.command.GetChainKindCommand;
077import com.echothree.control.user.chain.server.command.GetChainKindsCommand;
078import com.echothree.control.user.chain.server.command.GetChainTypeCommand;
079import com.echothree.control.user.chain.server.command.GetChainTypesCommand;
080import com.echothree.control.user.chain.server.command.GetChainsCommand;
081import com.echothree.control.user.contact.common.ContactUtil;
082import com.echothree.control.user.contact.server.command.GetContactMechanismPurposeCommand;
083import com.echothree.control.user.contact.server.command.GetContactMechanismPurposesCommand;
084import com.echothree.control.user.contactlist.common.ContactListUtil;
085import com.echothree.control.user.contactlist.server.command.GetContactListCommand;
086import com.echothree.control.user.contactlist.server.command.GetContactListContactMechanismPurposeCommand;
087import com.echothree.control.user.contactlist.server.command.GetContactListContactMechanismPurposesCommand;
088import com.echothree.control.user.contactlist.server.command.GetContactListFrequenciesCommand;
089import com.echothree.control.user.contactlist.server.command.GetContactListFrequencyCommand;
090import com.echothree.control.user.contactlist.server.command.GetContactListGroupCommand;
091import com.echothree.control.user.contactlist.server.command.GetContactListGroupsCommand;
092import com.echothree.control.user.contactlist.server.command.GetContactListTypeCommand;
093import com.echothree.control.user.contactlist.server.command.GetContactListTypesCommand;
094import com.echothree.control.user.contactlist.server.command.GetContactListsCommand;
095import com.echothree.control.user.contactlist.server.command.GetCustomerTypeContactListCommand;
096import com.echothree.control.user.contactlist.server.command.GetCustomerTypeContactListGroupCommand;
097import com.echothree.control.user.contactlist.server.command.GetCustomerTypeContactListGroupsCommand;
098import com.echothree.control.user.contactlist.server.command.GetCustomerTypeContactListsCommand;
099import com.echothree.control.user.contactlist.server.command.GetPartyContactListCommand;
100import com.echothree.control.user.contactlist.server.command.GetPartyContactListsCommand;
101import com.echothree.control.user.contactlist.server.command.GetPartyTypeContactListCommand;
102import com.echothree.control.user.contactlist.server.command.GetPartyTypeContactListGroupCommand;
103import com.echothree.control.user.contactlist.server.command.GetPartyTypeContactListGroupsCommand;
104import com.echothree.control.user.contactlist.server.command.GetPartyTypeContactListsCommand;
105import com.echothree.control.user.content.common.ContentUtil;
106import com.echothree.control.user.content.server.command.GetContentCatalogCommand;
107import com.echothree.control.user.content.server.command.GetContentCatalogItemCommand;
108import com.echothree.control.user.content.server.command.GetContentCatalogItemsCommand;
109import com.echothree.control.user.content.server.command.GetContentCatalogsCommand;
110import com.echothree.control.user.content.server.command.GetContentCategoriesCommand;
111import com.echothree.control.user.content.server.command.GetContentCategoryCommand;
112import com.echothree.control.user.content.server.command.GetContentCategoryItemCommand;
113import com.echothree.control.user.content.server.command.GetContentCategoryItemsCommand;
114import com.echothree.control.user.content.server.command.GetContentCollectionCommand;
115import com.echothree.control.user.content.server.command.GetContentCollectionsCommand;
116import com.echothree.control.user.content.server.command.GetContentPageAreaCommand;
117import com.echothree.control.user.content.server.command.GetContentPageAreaTypeCommand;
118import com.echothree.control.user.content.server.command.GetContentPageAreaTypesCommand;
119import com.echothree.control.user.content.server.command.GetContentPageAreasCommand;
120import com.echothree.control.user.content.server.command.GetContentPageCommand;
121import com.echothree.control.user.content.server.command.GetContentPageLayoutAreaCommand;
122import com.echothree.control.user.content.server.command.GetContentPageLayoutAreasCommand;
123import com.echothree.control.user.content.server.command.GetContentPageLayoutCommand;
124import com.echothree.control.user.content.server.command.GetContentPageLayoutsCommand;
125import com.echothree.control.user.content.server.command.GetContentPagesCommand;
126import com.echothree.control.user.content.server.command.GetContentSectionCommand;
127import com.echothree.control.user.content.server.command.GetContentSectionsCommand;
128import com.echothree.control.user.content.server.command.GetContentWebAddressCommand;
129import com.echothree.control.user.content.server.command.GetContentWebAddressesCommand;
130import com.echothree.control.user.core.common.CoreUtil;
131import com.echothree.control.user.core.server.command.GetAppearanceCommand;
132import com.echothree.control.user.core.server.command.GetAppearancesCommand;
133import com.echothree.control.user.core.server.command.GetColorCommand;
134import com.echothree.control.user.core.server.command.GetColorsCommand;
135import com.echothree.control.user.core.server.command.GetComponentVendorCommand;
136import com.echothree.control.user.core.server.command.GetComponentVendorsCommand;
137import com.echothree.control.user.core.server.command.GetEntityAliasCommand;
138import com.echothree.control.user.core.server.command.GetEntityAliasTypeCommand;
139import com.echothree.control.user.core.server.command.GetEntityAliasTypesCommand;
140import com.echothree.control.user.core.server.command.GetEntityAliasesCommand;
141import com.echothree.control.user.core.server.command.GetEntityAttributeCommand;
142import com.echothree.control.user.core.server.command.GetEntityAttributeEntityAttributeGroupCommand;
143import com.echothree.control.user.core.server.command.GetEntityAttributeEntityAttributeGroupsCommand;
144import com.echothree.control.user.core.server.command.GetEntityAttributeGroupCommand;
145import com.echothree.control.user.core.server.command.GetEntityAttributeGroupsCommand;
146import com.echothree.control.user.core.server.command.GetEntityAttributeTypeCommand;
147import com.echothree.control.user.core.server.command.GetEntityAttributeTypesCommand;
148import com.echothree.control.user.core.server.command.GetEntityAttributesCommand;
149import com.echothree.control.user.core.server.command.GetEntityInstanceCommand;
150import com.echothree.control.user.core.server.command.GetEntityInstancesCommand;
151import com.echothree.control.user.core.server.command.GetEntityTypeCommand;
152import com.echothree.control.user.core.server.command.GetEntityTypesCommand;
153import com.echothree.control.user.core.server.command.GetEventTypeCommand;
154import com.echothree.control.user.core.server.command.GetEventTypesCommand;
155import com.echothree.control.user.core.server.command.GetEventsCommand;
156import com.echothree.control.user.core.server.command.GetFontStyleCommand;
157import com.echothree.control.user.core.server.command.GetFontStylesCommand;
158import com.echothree.control.user.core.server.command.GetFontWeightCommand;
159import com.echothree.control.user.core.server.command.GetFontWeightsCommand;
160import com.echothree.control.user.core.server.command.GetLinkCardinalitiesCommand;
161import com.echothree.control.user.core.server.command.GetLinkCardinalityCommand;
162import com.echothree.control.user.core.server.command.GetLinkDirectionalitiesCommand;
163import com.echothree.control.user.core.server.command.GetLinkDirectionalityCommand;
164import com.echothree.control.user.core.server.command.GetLinkCommand;
165import com.echothree.control.user.core.server.command.GetLinksCommand;
166import com.echothree.control.user.core.server.command.GetLinkTypeCommand;
167import com.echothree.control.user.core.server.command.GetLinkTypeTranslationCommand;
168import com.echothree.control.user.core.server.command.GetLinkTypeTranslationsCommand;
169import com.echothree.control.user.core.server.command.GetLinkTypesCommand;
170import com.echothree.control.user.core.server.command.GetMimeTypeCommand;
171import com.echothree.control.user.core.server.command.GetMimeTypeFileExtensionCommand;
172import com.echothree.control.user.core.server.command.GetMimeTypeFileExtensionsCommand;
173import com.echothree.control.user.core.server.command.GetMimeTypeUsageTypeCommand;
174import com.echothree.control.user.core.server.command.GetMimeTypeUsageTypesCommand;
175import com.echothree.control.user.core.server.command.GetMimeTypesCommand;
176import com.echothree.control.user.core.server.command.GetTextDecorationCommand;
177import com.echothree.control.user.core.server.command.GetTextDecorationsCommand;
178import com.echothree.control.user.core.server.command.GetTextTransformationCommand;
179import com.echothree.control.user.core.server.command.GetTextTransformationsCommand;
180import com.echothree.control.user.customer.common.CustomerUtil;
181import com.echothree.control.user.customer.server.command.GetCustomerCommand;
182import com.echothree.control.user.customer.server.command.GetCustomerTypeCommand;
183import com.echothree.control.user.customer.server.command.GetCustomerTypePaymentMethodCommand;
184import com.echothree.control.user.customer.server.command.GetCustomerTypePaymentMethodsCommand;
185import com.echothree.control.user.customer.server.command.GetCustomerTypeShippingMethodCommand;
186import com.echothree.control.user.customer.server.command.GetCustomerTypeShippingMethodsCommand;
187import com.echothree.control.user.customer.server.command.GetCustomerTypesCommand;
188import com.echothree.control.user.customer.server.command.GetCustomersCommand;
189import com.echothree.control.user.employee.common.EmployeeUtil;
190import com.echothree.control.user.employee.server.command.GetEmployeeCommand;
191import com.echothree.control.user.employee.server.command.GetEmployeesCommand;
192import com.echothree.control.user.filter.common.FilterUtil;
193import com.echothree.control.user.filter.server.command.GetFilterAdjustmentAmountCommand;
194import com.echothree.control.user.filter.server.command.GetFilterAdjustmentAmountsCommand;
195import com.echothree.control.user.filter.server.command.GetFilterAdjustmentCommand;
196import com.echothree.control.user.filter.server.command.GetFilterAdjustmentFixedAmountCommand;
197import com.echothree.control.user.filter.server.command.GetFilterAdjustmentFixedAmountsCommand;
198import com.echothree.control.user.filter.server.command.GetFilterAdjustmentPercentCommand;
199import com.echothree.control.user.filter.server.command.GetFilterAdjustmentPercentsCommand;
200import com.echothree.control.user.filter.server.command.GetFilterAdjustmentSourceCommand;
201import com.echothree.control.user.filter.server.command.GetFilterAdjustmentSourcesCommand;
202import com.echothree.control.user.filter.server.command.GetFilterAdjustmentTypeCommand;
203import com.echothree.control.user.filter.server.command.GetFilterAdjustmentTypesCommand;
204import com.echothree.control.user.filter.server.command.GetFilterAdjustmentsCommand;
205import com.echothree.control.user.filter.server.command.GetFilterCommand;
206import com.echothree.control.user.filter.server.command.GetFilterEntranceStepCommand;
207import com.echothree.control.user.filter.server.command.GetFilterEntranceStepsCommand;
208import com.echothree.control.user.filter.server.command.GetFilterKindCommand;
209import com.echothree.control.user.filter.server.command.GetFilterKindsCommand;
210import com.echothree.control.user.filter.server.command.GetFilterStepCommand;
211import com.echothree.control.user.filter.server.command.GetFilterStepDestinationCommand;
212import com.echothree.control.user.filter.server.command.GetFilterStepDestinationsCommand;
213import com.echothree.control.user.filter.server.command.GetFilterStepElementCommand;
214import com.echothree.control.user.filter.server.command.GetFilterStepElementsCommand;
215import com.echothree.control.user.filter.server.command.GetFilterStepsCommand;
216import com.echothree.control.user.filter.server.command.GetFilterTypeCommand;
217import com.echothree.control.user.filter.server.command.GetFilterTypesCommand;
218import com.echothree.control.user.filter.server.command.GetFiltersCommand;
219import com.echothree.control.user.geo.common.GeoUtil;
220import com.echothree.control.user.geo.server.command.GetCitiesCommand;
221import com.echothree.control.user.geo.server.command.GetCityCommand;
222import com.echothree.control.user.geo.server.command.GetCountiesCommand;
223import com.echothree.control.user.geo.server.command.GetCountriesCommand;
224import com.echothree.control.user.geo.server.command.GetCountryCommand;
225import com.echothree.control.user.geo.server.command.GetCountyCommand;
226import com.echothree.control.user.geo.server.command.GetGeoCodeAliasCommand;
227import com.echothree.control.user.geo.server.command.GetGeoCodeAliasTypeCommand;
228import com.echothree.control.user.geo.server.command.GetGeoCodeAliasTypesCommand;
229import com.echothree.control.user.geo.server.command.GetGeoCodeAliasesCommand;
230import com.echothree.control.user.geo.server.command.GetGeoCodeCommand;
231import com.echothree.control.user.geo.server.command.GetGeoCodeCurrenciesCommand;
232import com.echothree.control.user.geo.server.command.GetGeoCodeCurrencyCommand;
233import com.echothree.control.user.geo.server.command.GetGeoCodeDateTimeFormatCommand;
234import com.echothree.control.user.geo.server.command.GetGeoCodeDateTimeFormatsCommand;
235import com.echothree.control.user.geo.server.command.GetGeoCodeLanguageCommand;
236import com.echothree.control.user.geo.server.command.GetGeoCodeLanguagesCommand;
237import com.echothree.control.user.geo.server.command.GetGeoCodeScopeCommand;
238import com.echothree.control.user.geo.server.command.GetGeoCodeScopesCommand;
239import com.echothree.control.user.geo.server.command.GetGeoCodeTimeZoneCommand;
240import com.echothree.control.user.geo.server.command.GetGeoCodeTimeZonesCommand;
241import com.echothree.control.user.geo.server.command.GetGeoCodeTypeCommand;
242import com.echothree.control.user.geo.server.command.GetGeoCodeTypesCommand;
243import com.echothree.control.user.geo.server.command.GetStateCommand;
244import com.echothree.control.user.geo.server.command.GetStatesCommand;
245import com.echothree.control.user.geo.server.command.GetZipCodeCommand;
246import com.echothree.control.user.geo.server.command.GetZipCodesCommand;
247import com.echothree.control.user.inventory.common.InventoryUtil;
248import com.echothree.control.user.inventory.server.command.GetAllocationPrioritiesCommand;
249import com.echothree.control.user.inventory.server.command.GetAllocationPriorityCommand;
250import com.echothree.control.user.inventory.server.command.GetInventoryAdjustmentTypeCommand;
251import com.echothree.control.user.inventory.server.command.GetInventoryAdjustmentTypesCommand;
252import com.echothree.control.user.inventory.server.command.GetInventoryBucketTypeCommand;
253import com.echothree.control.user.inventory.server.command.GetInventoryBucketTypesCommand;
254import com.echothree.control.user.inventory.server.command.GetInventoryConditionCommand;
255import com.echothree.control.user.inventory.server.command.GetInventoryConditionsCommand;
256import com.echothree.control.user.inventory.server.command.GetInventoryCostingMethodCommand;
257import com.echothree.control.user.inventory.server.command.GetInventoryCostingMethodsCommand;
258import com.echothree.control.user.inventory.server.command.GetInventoryCostingPoolCommand;
259import com.echothree.control.user.inventory.server.command.GetInventoryCostingPoolsCommand;
260import com.echothree.control.user.inventory.server.command.GetInventoryDispositionAdjustmentCommand;
261import com.echothree.control.user.inventory.server.command.GetInventoryDispositionAdjustmentsCommand;
262import com.echothree.control.user.inventory.server.command.GetInventoryDispositionCommand;
263import com.echothree.control.user.inventory.server.command.GetInventoryDispositionsCommand;
264import com.echothree.control.user.inventory.server.command.GetInventoryLayerBucketCommand;
265import com.echothree.control.user.inventory.server.command.GetInventoryLayerBucketsCommand;
266import com.echothree.control.user.inventory.server.command.GetInventoryLayerCommand;
267import com.echothree.control.user.inventory.server.command.GetInventoryLayersCommand;
268import com.echothree.control.user.inventory.server.command.GetInventoryLocationBucketCommand;
269import com.echothree.control.user.inventory.server.command.GetInventoryLocationBucketsCommand;
270import com.echothree.control.user.inventory.server.command.GetInventoryLocationCommand;
271import com.echothree.control.user.inventory.server.command.GetInventoryLocationGroupCommand;
272import com.echothree.control.user.inventory.server.command.GetInventoryLocationGroupsCommand;
273import com.echothree.control.user.inventory.server.command.GetInventoryLocationsCommand;
274import com.echothree.control.user.inventory.server.command.GetInventoryTransactionReasonCommand;
275import com.echothree.control.user.inventory.server.command.GetInventoryTransactionReasonsCommand;
276import com.echothree.control.user.inventory.server.command.GetInventoryTransactionRoleTypeCommand;
277import com.echothree.control.user.inventory.server.command.GetInventoryTransactionRoleTypesCommand;
278import com.echothree.control.user.inventory.server.command.GetInventoryTransactionTimeTypeCommand;
279import com.echothree.control.user.inventory.server.command.GetInventoryTransactionTimeTypesCommand;
280import com.echothree.control.user.inventory.server.command.GetInventoryTransactionTypeCommand;
281import com.echothree.control.user.inventory.server.command.GetInventoryTransactionTypesCommand;
282import com.echothree.control.user.inventory.server.command.GetLotCommand;
283import com.echothree.control.user.inventory.server.command.GetLotsCommand;
284import com.echothree.control.user.inventory.server.command.GetPartyBucketCommand;
285import com.echothree.control.user.inventory.server.command.GetPartyBucketsCommand;
286import com.echothree.control.user.inventory.server.command.GetPartyInventoryCostingMethodCommand;
287import com.echothree.control.user.inventory.server.command.GetPartyInventoryCostingMethodsCommand;
288import com.echothree.control.user.item.common.ItemUtil;
289import com.echothree.control.user.item.server.command.GetItemAliasChecksumTypeCommand;
290import com.echothree.control.user.item.server.command.GetItemAliasChecksumTypesCommand;
291import com.echothree.control.user.item.server.command.GetItemAliasCommand;
292import com.echothree.control.user.item.server.command.GetItemAliasTypeCommand;
293import com.echothree.control.user.item.server.command.GetItemAliasTypesCommand;
294import com.echothree.control.user.item.server.command.GetItemAliasesCommand;
295import com.echothree.control.user.item.server.command.GetItemCategoriesCommand;
296import com.echothree.control.user.item.server.command.GetItemCategoryCommand;
297import com.echothree.control.user.item.server.command.GetItemCommand;
298import com.echothree.control.user.item.server.command.GetItemDeliveryTypeCommand;
299import com.echothree.control.user.item.server.command.GetItemDeliveryTypesCommand;
300import com.echothree.control.user.item.server.command.GetItemDescriptionCommand;
301import com.echothree.control.user.item.server.command.GetItemDescriptionTypeCommand;
302import com.echothree.control.user.item.server.command.GetItemDescriptionTypeUseCommand;
303import com.echothree.control.user.item.server.command.GetItemDescriptionTypeUseTypeCommand;
304import com.echothree.control.user.item.server.command.GetItemDescriptionTypeUseTypesCommand;
305import com.echothree.control.user.item.server.command.GetItemDescriptionTypeUsesCommand;
306import com.echothree.control.user.item.server.command.GetItemDescriptionTypesCommand;
307import com.echothree.control.user.item.server.command.GetItemDescriptionsCommand;
308import com.echothree.control.user.item.server.command.GetItemImageTypeCommand;
309import com.echothree.control.user.item.server.command.GetItemImageTypesCommand;
310import com.echothree.control.user.item.server.command.GetItemInventoryTypeCommand;
311import com.echothree.control.user.item.server.command.GetItemInventoryTypesCommand;
312import com.echothree.control.user.item.server.command.GetItemPriceCommand;
313import com.echothree.control.user.item.server.command.GetItemPriceTypeCommand;
314import com.echothree.control.user.item.server.command.GetItemPriceTypesCommand;
315import com.echothree.control.user.item.server.command.GetItemPricesCommand;
316import com.echothree.control.user.item.server.command.GetItemTypeCommand;
317import com.echothree.control.user.item.server.command.GetItemTypesCommand;
318import com.echothree.control.user.item.server.command.GetItemUnitOfMeasureTypeCommand;
319import com.echothree.control.user.item.server.command.GetItemUnitOfMeasureTypesCommand;
320import com.echothree.control.user.item.server.command.GetItemUseTypeCommand;
321import com.echothree.control.user.item.server.command.GetItemUseTypesCommand;
322import com.echothree.control.user.item.server.command.GetItemVolumeTypeCommand;
323import com.echothree.control.user.item.server.command.GetItemVolumeTypesCommand;
324import com.echothree.control.user.item.server.command.GetItemWeightTypeCommand;
325import com.echothree.control.user.item.server.command.GetItemWeightTypesCommand;
326import com.echothree.control.user.item.server.command.GetItemsCommand;
327import com.echothree.control.user.item.server.command.GetRelatedItemCommand;
328import com.echothree.control.user.item.server.command.GetRelatedItemTypeCommand;
329import com.echothree.control.user.item.server.command.GetRelatedItemTypesCommand;
330import com.echothree.control.user.item.server.command.GetRelatedItemsCommand;
331import com.echothree.control.user.offer.common.OfferUtil;
332import com.echothree.control.user.offer.server.command.GetOfferCommand;
333import com.echothree.control.user.offer.server.command.GetOfferCustomerTypeCommand;
334import com.echothree.control.user.offer.server.command.GetOfferCustomerTypesCommand;
335import com.echothree.control.user.offer.server.command.GetOfferItemCommand;
336import com.echothree.control.user.offer.server.command.GetOfferItemPriceCommand;
337import com.echothree.control.user.offer.server.command.GetOfferItemPricesCommand;
338import com.echothree.control.user.offer.server.command.GetOfferItemsCommand;
339import com.echothree.control.user.offer.server.command.GetOfferNameElementCommand;
340import com.echothree.control.user.offer.server.command.GetOfferNameElementsCommand;
341import com.echothree.control.user.offer.server.command.GetOfferUseCommand;
342import com.echothree.control.user.offer.server.command.GetOfferUsesCommand;
343import com.echothree.control.user.offer.server.command.GetOffersCommand;
344import com.echothree.control.user.offer.server.command.GetUseCommand;
345import com.echothree.control.user.offer.server.command.GetUseNameElementCommand;
346import com.echothree.control.user.offer.server.command.GetUseNameElementsCommand;
347import com.echothree.control.user.offer.server.command.GetUseTypeCommand;
348import com.echothree.control.user.offer.server.command.GetUseTypesCommand;
349import com.echothree.control.user.offer.server.command.GetUsesCommand;
350import com.echothree.control.user.order.common.OrderUtil;
351import com.echothree.control.user.order.server.command.GetOrderPrioritiesCommand;
352import com.echothree.control.user.order.server.command.GetOrderPriorityCommand;
353import com.echothree.control.user.order.server.command.GetOrderTimeTypeCommand;
354import com.echothree.control.user.order.server.command.GetOrderTimeTypesCommand;
355import com.echothree.control.user.order.server.command.GetOrderTypeCommand;
356import com.echothree.control.user.order.server.command.GetOrderTypesCommand;
357import com.echothree.control.user.party.common.PartyUtil;
358import com.echothree.control.user.party.server.command.GetCompaniesCommand;
359import com.echothree.control.user.party.server.command.GetCompanyCommand;
360import com.echothree.control.user.party.server.command.GetDateTimeFormatCommand;
361import com.echothree.control.user.party.server.command.GetDateTimeFormatsCommand;
362import com.echothree.control.user.party.server.command.GetDepartmentCommand;
363import com.echothree.control.user.party.server.command.GetDepartmentsCommand;
364import com.echothree.control.user.party.server.command.GetDivisionCommand;
365import com.echothree.control.user.party.server.command.GetDivisionsCommand;
366import com.echothree.control.user.party.server.command.GetLanguageCommand;
367import com.echothree.control.user.party.server.command.GetLanguagesCommand;
368import com.echothree.control.user.party.server.command.GetNameSuffixesCommand;
369import com.echothree.control.user.party.server.command.GetPartiesCommand;
370import com.echothree.control.user.party.server.command.GetPartyAliasCommand;
371import com.echothree.control.user.party.server.command.GetPartyAliasTypeCommand;
372import com.echothree.control.user.party.server.command.GetPartyAliasTypesCommand;
373import com.echothree.control.user.party.server.command.GetPartyAliasesCommand;
374import com.echothree.control.user.party.server.command.GetPartyCommand;
375import com.echothree.control.user.party.server.command.GetPartyTypeCommand;
376import com.echothree.control.user.party.server.command.GetPartyTypesCommand;
377import com.echothree.control.user.party.server.command.GetPersonalTitlesCommand;
378import com.echothree.control.user.party.server.command.GetRoleTypeCommand;
379import com.echothree.control.user.party.server.command.GetRoleTypesCommand;
380import com.echothree.control.user.party.server.command.GetTimeZoneCommand;
381import com.echothree.control.user.party.server.command.GetTimeZonesCommand;
382import com.echothree.control.user.payment.common.PaymentUtil;
383import com.echothree.control.user.payment.server.command.GetPaymentMethodCommand;
384import com.echothree.control.user.payment.server.command.GetPaymentMethodTypeCommand;
385import com.echothree.control.user.payment.server.command.GetPaymentMethodTypesCommand;
386import com.echothree.control.user.payment.server.command.GetPaymentMethodsCommand;
387import com.echothree.control.user.payment.server.command.GetPaymentProcessorActionTypeCommand;
388import com.echothree.control.user.payment.server.command.GetPaymentProcessorActionTypesCommand;
389import com.echothree.control.user.payment.server.command.GetPaymentProcessorCommand;
390import com.echothree.control.user.payment.server.command.GetPaymentProcessorResultCodeCommand;
391import com.echothree.control.user.payment.server.command.GetPaymentProcessorResultCodesCommand;
392import com.echothree.control.user.payment.server.command.GetPaymentProcessorTransactionCommand;
393import com.echothree.control.user.payment.server.command.GetPaymentProcessorTransactionsCommand;
394import com.echothree.control.user.payment.server.command.GetPaymentProcessorTypeCodeCommand;
395import com.echothree.control.user.payment.server.command.GetPaymentProcessorTypeCodeTypeCommand;
396import com.echothree.control.user.payment.server.command.GetPaymentProcessorTypeCommand;
397import com.echothree.control.user.payment.server.command.GetPaymentProcessorTypesCommand;
398import com.echothree.control.user.payment.server.command.GetPaymentProcessorsCommand;
399import com.echothree.control.user.period.common.PeriodUtil;
400import com.echothree.control.user.period.server.command.GetFiscalPeriodCommand;
401import com.echothree.control.user.period.server.command.GetFiscalPeriodsCommand;
402import com.echothree.control.user.period.server.command.GetPeriodKindCommand;
403import com.echothree.control.user.period.server.command.GetPeriodKindsCommand;
404import com.echothree.control.user.period.server.command.GetPeriodTypeCommand;
405import com.echothree.control.user.period.server.command.GetPeriodTypesCommand;
406import com.echothree.control.user.queue.common.QueueUtil;
407import com.echothree.control.user.queue.server.command.GetQueueTypeCommand;
408import com.echothree.control.user.queue.server.command.GetQueueTypesCommand;
409import com.echothree.control.user.returnpolicy.common.ReturnPolicyUtil;
410import com.echothree.control.user.returnpolicy.server.command.GetReturnKindCommand;
411import com.echothree.control.user.returnpolicy.server.command.GetReturnKindsCommand;
412import com.echothree.control.user.returnpolicy.server.command.GetReturnPoliciesCommand;
413import com.echothree.control.user.returnpolicy.server.command.GetReturnPolicyCommand;
414import com.echothree.control.user.search.common.SearchUtil;
415import com.echothree.control.user.search.server.command.GetComponentVendorResultsCommand;
416import com.echothree.control.user.search.server.command.GetContentCatalogItemResultsCommand;
417import com.echothree.control.user.search.server.command.GetContentCatalogResultsCommand;
418import com.echothree.control.user.search.server.command.GetContentCategoryResultsCommand;
419import com.echothree.control.user.search.server.command.GetCustomerResultsCommand;
420import com.echothree.control.user.search.server.command.GetEmployeeResultsCommand;
421import com.echothree.control.user.search.server.command.GetEntityAliasTypeResultsCommand;
422import com.echothree.control.user.search.server.command.GetEntityAttributeGroupResultsCommand;
423import com.echothree.control.user.search.server.command.GetEntityAttributeResultsCommand;
424import com.echothree.control.user.search.server.command.GetEntityListItemResultsCommand;
425import com.echothree.control.user.search.server.command.GetEntityTypeResultsCommand;
426import com.echothree.control.user.search.server.command.GetItemResultsCommand;
427import com.echothree.control.user.search.server.command.GetSearchCheckSpellingActionTypeCommand;
428import com.echothree.control.user.search.server.command.GetSearchCheckSpellingActionTypesCommand;
429import com.echothree.control.user.search.server.command.GetSearchDefaultOperatorCommand;
430import com.echothree.control.user.search.server.command.GetSearchDefaultOperatorsCommand;
431import com.echothree.control.user.search.server.command.GetSearchKindCommand;
432import com.echothree.control.user.search.server.command.GetSearchKindsCommand;
433import com.echothree.control.user.search.server.command.GetSearchResultActionTypeCommand;
434import com.echothree.control.user.search.server.command.GetSearchResultActionTypesCommand;
435import com.echothree.control.user.search.server.command.GetSearchSortDirectionCommand;
436import com.echothree.control.user.search.server.command.GetSearchSortDirectionsCommand;
437import com.echothree.control.user.search.server.command.GetSearchSortOrderCommand;
438import com.echothree.control.user.search.server.command.GetSearchSortOrdersCommand;
439import com.echothree.control.user.search.server.command.GetSearchTypeCommand;
440import com.echothree.control.user.search.server.command.GetSearchTypesCommand;
441import com.echothree.control.user.search.server.command.GetSearchUseTypeCommand;
442import com.echothree.control.user.search.server.command.GetSearchUseTypesCommand;
443import com.echothree.control.user.search.server.command.GetShippingMethodResultsCommand;
444import com.echothree.control.user.search.server.command.GetVendorResultsCommand;
445import com.echothree.control.user.search.server.command.GetWarehouseResultsCommand;
446import com.echothree.control.user.security.common.SecurityUtil;
447import com.echothree.control.user.security.server.command.GetSecurityRoleCommand;
448import com.echothree.control.user.security.server.command.GetSecurityRoleGroupCommand;
449import com.echothree.control.user.security.server.command.GetSecurityRoleGroupsCommand;
450import com.echothree.control.user.security.server.command.GetSecurityRolesCommand;
451import com.echothree.control.user.selector.common.SelectorUtil;
452import com.echothree.control.user.selector.server.command.GetSelectorCommand;
453import com.echothree.control.user.selector.server.command.GetSelectorKindCommand;
454import com.echothree.control.user.selector.server.command.GetSelectorKindsCommand;
455import com.echothree.control.user.selector.server.command.GetSelectorTypeCommand;
456import com.echothree.control.user.selector.server.command.GetSelectorTypesCommand;
457import com.echothree.control.user.selector.server.command.GetSelectorsCommand;
458import com.echothree.control.user.sequence.common.SequenceUtil;
459import com.echothree.control.user.sequence.server.command.GetSequenceChecksumTypeCommand;
460import com.echothree.control.user.sequence.server.command.GetSequenceChecksumTypesCommand;
461import com.echothree.control.user.sequence.server.command.GetSequenceCommand;
462import com.echothree.control.user.sequence.server.command.GetSequenceEncoderTypeCommand;
463import com.echothree.control.user.sequence.server.command.GetSequenceEncoderTypesCommand;
464import com.echothree.control.user.sequence.server.command.GetSequenceTypeCommand;
465import com.echothree.control.user.sequence.server.command.GetSequenceTypesCommand;
466import com.echothree.control.user.sequence.server.command.GetSequencesCommand;
467import com.echothree.control.user.shipment.common.ShipmentUtil;
468import com.echothree.control.user.shipment.server.command.GetFreeOnBoardCommand;
469import com.echothree.control.user.shipment.server.command.GetFreeOnBoardsCommand;
470import com.echothree.control.user.shipping.common.ShippingUtil;
471import com.echothree.control.user.shipping.server.command.GetShippingMethodCommand;
472import com.echothree.control.user.shipping.server.command.GetShippingMethodsCommand;
473import com.echothree.control.user.subscription.common.SubscriptionUtil;
474import com.echothree.control.user.subscription.server.command.GetSubscriptionCommand;
475import com.echothree.control.user.subscription.server.command.GetSubscriptionKindCommand;
476import com.echothree.control.user.subscription.server.command.GetSubscriptionKindsCommand;
477import com.echothree.control.user.subscription.server.command.GetSubscriptionTypeCommand;
478import com.echothree.control.user.subscription.server.command.GetSubscriptionTypesCommand;
479import com.echothree.control.user.subscription.server.command.GetSubscriptionsCommand;
480import com.echothree.control.user.tag.common.TagUtil;
481import com.echothree.control.user.tag.server.command.GetEntityTagCommand;
482import com.echothree.control.user.tag.server.command.GetEntityTagsCommand;
483import com.echothree.control.user.tag.server.command.GetTagCommand;
484import com.echothree.control.user.tag.server.command.GetTagScopeCommand;
485import com.echothree.control.user.tag.server.command.GetTagScopeEntityTypeCommand;
486import com.echothree.control.user.tag.server.command.GetTagScopeEntityTypesCommand;
487import com.echothree.control.user.tag.server.command.GetTagScopesCommand;
488import com.echothree.control.user.tag.server.command.GetTagsCommand;
489import com.echothree.control.user.term.common.TermUtil;
490import com.echothree.control.user.term.server.command.GetTermCommand;
491import com.echothree.control.user.term.server.command.GetTermTypeCommand;
492import com.echothree.control.user.term.server.command.GetTermTypesCommand;
493import com.echothree.control.user.term.server.command.GetTermsCommand;
494import com.echothree.control.user.uom.common.UomUtil;
495import com.echothree.control.user.uom.server.command.GetUnitOfMeasureKindCommand;
496import com.echothree.control.user.uom.server.command.GetUnitOfMeasureKindUseCommand;
497import com.echothree.control.user.uom.server.command.GetUnitOfMeasureKindUseTypeCommand;
498import com.echothree.control.user.uom.server.command.GetUnitOfMeasureKindUseTypesCommand;
499import com.echothree.control.user.uom.server.command.GetUnitOfMeasureKindUsesCommand;
500import com.echothree.control.user.uom.server.command.GetUnitOfMeasureKindsCommand;
501import com.echothree.control.user.uom.server.command.GetUnitOfMeasureTypeCommand;
502import com.echothree.control.user.uom.server.command.GetUnitOfMeasureTypesCommand;
503import com.echothree.control.user.user.common.UserUtil;
504import com.echothree.control.user.user.server.command.GetRecoveryQuestionCommand;
505import com.echothree.control.user.user.server.command.GetRecoveryQuestionsCommand;
506import com.echothree.control.user.user.server.command.GetUserLoginCommand;
507import com.echothree.control.user.user.server.command.GetUserVisitGroupCommand;
508import com.echothree.control.user.user.server.command.GetUserVisitGroupsCommand;
509import com.echothree.control.user.vendor.common.VendorUtil;
510import com.echothree.control.user.vendor.server.command.GetItemPurchasingCategoriesCommand;
511import com.echothree.control.user.vendor.server.command.GetItemPurchasingCategoryCommand;
512import com.echothree.control.user.vendor.server.command.GetVendorCommand;
513import com.echothree.control.user.vendor.server.command.GetVendorItemCommand;
514import com.echothree.control.user.vendor.server.command.GetVendorItemCostCommand;
515import com.echothree.control.user.vendor.server.command.GetVendorItemCostsCommand;
516import com.echothree.control.user.vendor.server.command.GetVendorItemsCommand;
517import com.echothree.control.user.vendor.server.command.GetVendorTypeCommand;
518import com.echothree.control.user.vendor.server.command.GetVendorTypesCommand;
519import com.echothree.control.user.vendor.server.command.GetVendorsCommand;
520import com.echothree.control.user.warehouse.common.WarehouseUtil;
521import com.echothree.control.user.warehouse.server.command.GetLocationCommand;
522import com.echothree.control.user.warehouse.server.command.GetLocationNameElementCommand;
523import com.echothree.control.user.warehouse.server.command.GetLocationNameElementsCommand;
524import com.echothree.control.user.warehouse.server.command.GetLocationTypeCommand;
525import com.echothree.control.user.warehouse.server.command.GetLocationTypesCommand;
526import com.echothree.control.user.warehouse.server.command.GetLocationUseTypeCommand;
527import com.echothree.control.user.warehouse.server.command.GetLocationUseTypesCommand;
528import com.echothree.control.user.warehouse.server.command.GetLocationsCommand;
529import com.echothree.control.user.warehouse.server.command.GetWarehouseCommand;
530import com.echothree.control.user.warehouse.server.command.GetWarehouseTypeCommand;
531import com.echothree.control.user.warehouse.server.command.GetWarehouseTypesCommand;
532import com.echothree.control.user.warehouse.server.command.GetWarehousesCommand;
533import com.echothree.control.user.wishlist.common.WishlistUtil;
534import com.echothree.control.user.wishlist.server.command.GetWishlistPrioritiesCommand;
535import com.echothree.control.user.wishlist.server.command.GetWishlistPriorityCommand;
536import com.echothree.control.user.wishlist.server.command.GetWishlistTypeCommand;
537import com.echothree.control.user.wishlist.server.command.GetWishlistTypesCommand;
538import com.echothree.control.user.workflow.common.WorkflowUtil;
539import com.echothree.control.user.workflow.server.command.GetWorkflowCommand;
540import com.echothree.control.user.workflow.server.command.GetWorkflowDestinationCommand;
541import com.echothree.control.user.workflow.server.command.GetWorkflowDestinationPartyTypeCommand;
542import com.echothree.control.user.workflow.server.command.GetWorkflowDestinationPartyTypesCommand;
543import com.echothree.control.user.workflow.server.command.GetWorkflowDestinationSecurityRoleCommand;
544import com.echothree.control.user.workflow.server.command.GetWorkflowDestinationSecurityRolesCommand;
545import com.echothree.control.user.workflow.server.command.GetWorkflowDestinationSelectorCommand;
546import com.echothree.control.user.workflow.server.command.GetWorkflowDestinationSelectorsCommand;
547import com.echothree.control.user.workflow.server.command.GetWorkflowDestinationStepCommand;
548import com.echothree.control.user.workflow.server.command.GetWorkflowDestinationStepsCommand;
549import com.echothree.control.user.workflow.server.command.GetWorkflowDestinationsCommand;
550import com.echothree.control.user.workflow.server.command.GetWorkflowEntityStatusesCommand;
551import com.echothree.control.user.workflow.server.command.GetWorkflowEntityTypeCommand;
552import com.echothree.control.user.workflow.server.command.GetWorkflowEntityTypesCommand;
553import com.echothree.control.user.workflow.server.command.GetWorkflowEntranceCommand;
554import com.echothree.control.user.workflow.server.command.GetWorkflowEntrancePartyTypeCommand;
555import com.echothree.control.user.workflow.server.command.GetWorkflowEntrancePartyTypesCommand;
556import com.echothree.control.user.workflow.server.command.GetWorkflowEntranceSecurityRoleCommand;
557import com.echothree.control.user.workflow.server.command.GetWorkflowEntranceSecurityRolesCommand;
558import com.echothree.control.user.workflow.server.command.GetWorkflowEntranceSelectorCommand;
559import com.echothree.control.user.workflow.server.command.GetWorkflowEntranceSelectorsCommand;
560import com.echothree.control.user.workflow.server.command.GetWorkflowEntranceStepCommand;
561import com.echothree.control.user.workflow.server.command.GetWorkflowEntranceStepsCommand;
562import com.echothree.control.user.workflow.server.command.GetWorkflowEntrancesCommand;
563import com.echothree.control.user.workflow.server.command.GetWorkflowSelectorKindCommand;
564import com.echothree.control.user.workflow.server.command.GetWorkflowSelectorKindsCommand;
565import com.echothree.control.user.workflow.server.command.GetWorkflowStepCommand;
566import com.echothree.control.user.workflow.server.command.GetWorkflowStepTypeCommand;
567import com.echothree.control.user.workflow.server.command.GetWorkflowStepTypesCommand;
568import com.echothree.control.user.workflow.server.command.GetWorkflowStepsCommand;
569import com.echothree.control.user.workflow.server.command.GetWorkflowsCommand;
570import com.echothree.model.control.accounting.server.graphql.CurrencyObject;
571import com.echothree.model.control.accounting.server.graphql.GlAccountCategoryObject;
572import com.echothree.model.control.accounting.server.graphql.GlAccountClassObject;
573import com.echothree.model.control.accounting.server.graphql.GlAccountObject;
574import com.echothree.model.control.accounting.server.graphql.GlAccountTypeObject;
575import com.echothree.model.control.accounting.server.graphql.GlResourceTypeObject;
576import com.echothree.model.control.accounting.server.graphql.ItemAccountingCategoryObject;
577import com.echothree.model.control.accounting.server.graphql.SymbolPositionObject;
578import com.echothree.model.control.accounting.server.graphql.TransactionEntityRoleTypeObject;
579import com.echothree.model.control.accounting.server.graphql.TransactionGlAccountCategoryObject;
580import com.echothree.model.control.accounting.server.graphql.TransactionGroupObject;
581import com.echothree.model.control.accounting.server.graphql.TransactionObject;
582import com.echothree.model.control.accounting.server.graphql.TransactionTimeTypeObject;
583import com.echothree.model.control.accounting.server.graphql.TransactionTypeObject;
584import com.echothree.model.control.campaign.server.graphql.CampaignContentObject;
585import com.echothree.model.control.campaign.server.graphql.CampaignMediumObject;
586import com.echothree.model.control.campaign.server.graphql.CampaignObject;
587import com.echothree.model.control.campaign.server.graphql.CampaignSourceObject;
588import com.echothree.model.control.campaign.server.graphql.CampaignTermObject;
589import com.echothree.model.control.cancellationpolicy.server.graphql.CancellationKindObject;
590import com.echothree.model.control.cancellationpolicy.server.graphql.CancellationPolicyObject;
591import com.echothree.model.control.chain.server.graphql.ChainActionObject;
592import com.echothree.model.control.chain.server.graphql.ChainActionSetObject;
593import com.echothree.model.control.chain.server.graphql.ChainActionTypeObject;
594import com.echothree.model.control.chain.server.graphql.ChainEntityRoleTypeObject;
595import com.echothree.model.control.chain.server.graphql.ChainInstanceObject;
596import com.echothree.model.control.chain.server.graphql.ChainKindObject;
597import com.echothree.model.control.chain.server.graphql.ChainObject;
598import com.echothree.model.control.chain.server.graphql.ChainTypeObject;
599import com.echothree.model.control.contact.server.graphql.ContactMechanismPurposeObject;
600import com.echothree.model.control.contactlist.server.graphql.ContactListContactMechanismPurposeObject;
601import com.echothree.model.control.contactlist.server.graphql.ContactListFrequencyObject;
602import com.echothree.model.control.contactlist.server.graphql.ContactListGroupObject;
603import com.echothree.model.control.contactlist.server.graphql.ContactListObject;
604import com.echothree.model.control.contactlist.server.graphql.ContactListTypeObject;
605import com.echothree.model.control.contactlist.server.graphql.CustomerTypeContactListGroupObject;
606import com.echothree.model.control.contactlist.server.graphql.CustomerTypeContactListObject;
607import com.echothree.model.control.contactlist.server.graphql.PartyContactListObject;
608import com.echothree.model.control.contactlist.server.graphql.PartyTypeContactListGroupObject;
609import com.echothree.model.control.contactlist.server.graphql.PartyTypeContactListObject;
610import com.echothree.model.control.content.server.graphql.ContentCatalogItemObject;
611import com.echothree.model.control.content.server.graphql.ContentCatalogObject;
612import com.echothree.model.control.content.server.graphql.ContentCategoryItemObject;
613import com.echothree.model.control.content.server.graphql.ContentCategoryObject;
614import com.echothree.model.control.content.server.graphql.ContentCollectionObject;
615import com.echothree.model.control.content.server.graphql.ContentPageAreaObject;
616import com.echothree.model.control.content.server.graphql.ContentPageAreaTypeObject;
617import com.echothree.model.control.content.server.graphql.ContentPageLayoutAreaObject;
618import com.echothree.model.control.content.server.graphql.ContentPageLayoutObject;
619import com.echothree.model.control.content.server.graphql.ContentPageObject;
620import com.echothree.model.control.content.server.graphql.ContentSectionObject;
621import com.echothree.model.control.content.server.graphql.ContentWebAddressObject;
622import com.echothree.model.control.core.server.graphql.AppearanceObject;
623import com.echothree.model.control.core.server.graphql.ColorObject;
624import com.echothree.model.control.core.server.graphql.ComponentVendorObject;
625import com.echothree.model.control.core.server.graphql.EntityAliasObject;
626import com.echothree.model.control.core.server.graphql.EntityAliasTypeObject;
627import com.echothree.model.control.core.server.graphql.EntityAttributeEntityAttributeGroupObject;
628import com.echothree.model.control.core.server.graphql.EntityAttributeGroupObject;
629import com.echothree.model.control.core.server.graphql.EntityAttributeObject;
630import com.echothree.model.control.core.server.graphql.EntityAttributeTypeObject;
631import com.echothree.model.control.core.server.graphql.EntityInstanceObject;
632import com.echothree.model.control.core.server.graphql.EntityTypeObject;
633import com.echothree.model.control.core.server.graphql.EventObject;
634import com.echothree.model.control.core.server.graphql.EventTypeObject;
635import com.echothree.model.control.core.server.graphql.FontStyleObject;
636import com.echothree.model.control.core.server.graphql.FontWeightObject;
637import com.echothree.model.control.core.server.graphql.LinkCardinalityObject;
638import com.echothree.model.control.core.server.graphql.LinkDirectionalityObject;
639import com.echothree.model.control.core.server.graphql.LinkObject;
640import com.echothree.model.control.core.server.graphql.LinkTypeObject;
641import com.echothree.model.control.core.server.graphql.LinkTypeTranslationObject;
642import com.echothree.model.control.core.server.graphql.MimeTypeFileExtensionObject;
643import com.echothree.model.control.core.server.graphql.MimeTypeObject;
644import com.echothree.model.control.core.server.graphql.MimeTypeUsageTypeObject;
645import com.echothree.model.control.core.server.graphql.TextDecorationObject;
646import com.echothree.model.control.core.server.graphql.TextTransformationObject;
647import com.echothree.model.control.customer.server.graphql.CustomerObject;
648import com.echothree.model.control.customer.server.graphql.CustomerTypeObject;
649import com.echothree.model.control.customer.server.graphql.CustomerTypePaymentMethodObject;
650import com.echothree.model.control.customer.server.graphql.CustomerTypeShippingMethodObject;
651import com.echothree.model.control.employee.server.graphql.EmployeeObject;
652import com.echothree.model.control.filter.server.graphql.FilterAdjustmentAmountObject;
653import com.echothree.model.control.filter.server.graphql.FilterAdjustmentFixedAmountObject;
654import com.echothree.model.control.filter.server.graphql.FilterAdjustmentObject;
655import com.echothree.model.control.filter.server.graphql.FilterAdjustmentPercentObject;
656import com.echothree.model.control.filter.server.graphql.FilterAdjustmentSourceObject;
657import com.echothree.model.control.filter.server.graphql.FilterAdjustmentTypeObject;
658import com.echothree.model.control.filter.server.graphql.FilterEntranceStepObject;
659import com.echothree.model.control.filter.server.graphql.FilterKindObject;
660import com.echothree.model.control.filter.server.graphql.FilterObject;
661import com.echothree.model.control.filter.server.graphql.FilterStepDestinationObject;
662import com.echothree.model.control.filter.server.graphql.FilterStepElementObject;
663import com.echothree.model.control.filter.server.graphql.FilterStepObject;
664import com.echothree.model.control.filter.server.graphql.FilterTypeObject;
665import com.echothree.model.control.geo.server.graphql.GeoCodeAliasObject;
666import com.echothree.model.control.geo.server.graphql.GeoCodeAliasTypeObject;
667import com.echothree.model.control.geo.server.graphql.GeoCodeCurrencyObject;
668import com.echothree.model.control.geo.server.graphql.GeoCodeDateTimeFormatObject;
669import com.echothree.model.control.geo.server.graphql.GeoCodeLanguageObject;
670import com.echothree.model.control.geo.server.graphql.GeoCodeObject;
671import com.echothree.model.control.geo.server.graphql.GeoCodeScopeObject;
672import com.echothree.model.control.geo.server.graphql.GeoCodeTimeZoneObject;
673import com.echothree.model.control.geo.server.graphql.GeoCodeTypeObject;
674import com.echothree.model.control.graphql.server.graphql.count.Connections;
675import com.echothree.model.control.graphql.server.graphql.count.CountedObjects;
676import com.echothree.model.control.graphql.server.graphql.count.CountingDataConnectionFetcher;
677import com.echothree.model.control.graphql.server.graphql.count.CountingPaginatedData;
678import com.echothree.model.control.graphql.server.util.BaseGraphQl;
679import com.echothree.model.data.core.common.LinkCardinalityConstants;
680import com.echothree.model.data.core.common.LinkDirectionalityConstants;
681import com.echothree.model.data.core.common.LinkConstants;
682import com.echothree.model.data.core.common.LinkTypeConstants;
683import com.echothree.model.data.core.common.LinkTypeTranslationConstants;
684import com.echothree.model.data.core.server.entity.LinkCardinality;
685import com.echothree.model.data.core.server.entity.LinkDirectionality;
686import com.echothree.model.data.core.server.entity.Link;
687import com.echothree.model.data.core.server.entity.LinkType;
688import com.echothree.model.data.core.server.entity.LinkTypeTranslation;
689import static com.echothree.model.control.graphql.server.util.BaseGraphQl.getUserVisitPK;
690import com.echothree.model.control.graphql.server.util.count.ObjectLimiter;
691import com.echothree.model.control.inventory.server.graphql.AllocationPriorityObject;
692import com.echothree.model.control.inventory.server.graphql.InventoryAdjustmentTypeObject;
693import com.echothree.model.control.inventory.server.graphql.InventoryBucketTypeObject;
694import com.echothree.model.control.inventory.server.graphql.InventoryConditionObject;
695import com.echothree.model.control.inventory.server.graphql.InventoryCostingMethodObject;
696import com.echothree.model.control.inventory.server.graphql.InventoryCostingPoolObject;
697import com.echothree.model.control.inventory.server.graphql.InventoryDispositionAdjustmentObject;
698import com.echothree.model.control.inventory.server.graphql.InventoryDispositionObject;
699import com.echothree.model.control.inventory.server.graphql.InventoryLayerBucketObject;
700import com.echothree.model.control.inventory.server.graphql.InventoryLayerObject;
701import com.echothree.model.control.inventory.server.graphql.InventoryLocationBucketObject;
702import com.echothree.model.control.inventory.server.graphql.InventoryLocationGroupObject;
703import com.echothree.model.control.inventory.server.graphql.InventoryLocationObject;
704import com.echothree.model.control.inventory.server.graphql.InventoryTransactionReasonObject;
705import com.echothree.model.control.inventory.server.graphql.InventoryTransactionRoleTypeObject;
706import com.echothree.model.control.inventory.server.graphql.InventoryTransactionTimeTypeObject;
707import com.echothree.model.control.inventory.server.graphql.InventoryTransactionTypeObject;
708import com.echothree.model.control.inventory.server.graphql.LotObject;
709import com.echothree.model.control.inventory.server.graphql.PartyBucketObject;
710import com.echothree.model.control.inventory.server.graphql.PartyInventoryCostingMethodObject;
711import com.echothree.model.control.item.server.graphql.ItemAliasChecksumTypeObject;
712import com.echothree.model.control.item.server.graphql.ItemAliasObject;
713import com.echothree.model.control.item.server.graphql.ItemAliasTypeObject;
714import com.echothree.model.control.item.server.graphql.ItemCategoryObject;
715import com.echothree.model.control.item.server.graphql.ItemDeliveryTypeObject;
716import com.echothree.model.control.item.server.graphql.ItemDescriptionObject;
717import com.echothree.model.control.item.server.graphql.ItemDescriptionTypeObject;
718import com.echothree.model.control.item.server.graphql.ItemDescriptionTypeUseObject;
719import com.echothree.model.control.item.server.graphql.ItemDescriptionTypeUseTypeObject;
720import com.echothree.model.control.item.server.graphql.ItemImageTypeObject;
721import com.echothree.model.control.item.server.graphql.ItemInventoryTypeObject;
722import com.echothree.model.control.item.server.graphql.ItemObject;
723import com.echothree.model.control.item.server.graphql.ItemPriceObject;
724import com.echothree.model.control.item.server.graphql.ItemPriceTypeObject;
725import com.echothree.model.control.item.server.graphql.ItemTypeObject;
726import com.echothree.model.control.item.server.graphql.ItemUnitOfMeasureTypeObject;
727import com.echothree.model.control.item.server.graphql.ItemUseTypeObject;
728import com.echothree.model.control.item.server.graphql.ItemVolumeTypeObject;
729import com.echothree.model.control.item.server.graphql.ItemWeightTypeObject;
730import com.echothree.model.control.item.server.graphql.RelatedItemObject;
731import com.echothree.model.control.item.server.graphql.RelatedItemTypeObject;
732import com.echothree.model.control.offer.server.graphql.OfferCustomerTypeObject;
733import com.echothree.model.control.offer.server.graphql.OfferItemObject;
734import com.echothree.model.control.offer.server.graphql.OfferItemPriceObject;
735import com.echothree.model.control.offer.server.graphql.OfferNameElementObject;
736import com.echothree.model.control.offer.server.graphql.OfferObject;
737import com.echothree.model.control.offer.server.graphql.OfferUseObject;
738import com.echothree.model.control.offer.server.graphql.UseNameElementObject;
739import com.echothree.model.control.offer.server.graphql.UseObject;
740import com.echothree.model.control.offer.server.graphql.UseTypeObject;
741import com.echothree.model.control.order.server.graphql.OrderPriorityObject;
742import com.echothree.model.control.order.server.graphql.OrderTimeTypeObject;
743import com.echothree.model.control.order.server.graphql.OrderTypeObject;
744import com.echothree.model.control.party.server.graphql.CompanyObject;
745import com.echothree.model.control.party.server.graphql.DateTimeFormatObject;
746import com.echothree.model.control.party.server.graphql.DepartmentObject;
747import com.echothree.model.control.party.server.graphql.DivisionObject;
748import com.echothree.model.control.party.server.graphql.LanguageObject;
749import com.echothree.model.control.party.server.graphql.NameSuffixObject;
750import com.echothree.model.control.party.server.graphql.PartyAliasObject;
751import com.echothree.model.control.party.server.graphql.PartyAliasTypeObject;
752import com.echothree.model.control.party.server.graphql.PartyObject;
753import com.echothree.model.control.party.server.graphql.PartyTypeObject;
754import com.echothree.model.control.party.server.graphql.PersonalTitleObject;
755import com.echothree.model.control.party.server.graphql.RoleTypeObject;
756import com.echothree.model.control.party.server.graphql.TimeZoneObject;
757import com.echothree.model.control.payment.server.graphql.PaymentMethodObject;
758import com.echothree.model.control.payment.server.graphql.PaymentMethodTypeObject;
759import com.echothree.model.control.payment.server.graphql.PaymentProcessorActionTypeObject;
760import com.echothree.model.control.payment.server.graphql.PaymentProcessorObject;
761import com.echothree.model.control.payment.server.graphql.PaymentProcessorResultCodeObject;
762import com.echothree.model.control.payment.server.graphql.PaymentProcessorTransactionObject;
763import com.echothree.model.control.payment.server.graphql.PaymentProcessorTypeCodeObject;
764import com.echothree.model.control.payment.server.graphql.PaymentProcessorTypeCodeTypeObject;
765import com.echothree.model.control.payment.server.graphql.PaymentProcessorTypeObject;
766import com.echothree.model.control.period.server.graphql.FiscalPeriodObject;
767import com.echothree.model.control.period.server.graphql.PeriodKindObject;
768import com.echothree.model.control.period.server.graphql.PeriodTypeObject;
769import com.echothree.model.control.queue.server.graphql.QueueTypeObject;
770import com.echothree.model.control.returnpolicy.server.graphql.ReturnKindObject;
771import com.echothree.model.control.returnpolicy.server.graphql.ReturnPolicyObject;
772import com.echothree.model.control.search.server.control.SearchControl;
773import com.echothree.model.control.search.server.graphql.CheckItemSpellingObject;
774import com.echothree.model.control.search.server.graphql.ComponentVendorResultsObject;
775import com.echothree.model.control.search.server.graphql.ContentCatalogItemResultsObject;
776import com.echothree.model.control.search.server.graphql.ContentCatalogResultsObject;
777import com.echothree.model.control.search.server.graphql.ContentCategoryResultsObject;
778import com.echothree.model.control.search.server.graphql.CustomerResultsObject;
779import com.echothree.model.control.search.server.graphql.EmployeeResultsObject;
780import com.echothree.model.control.search.server.graphql.EntityAliasTypeResultsObject;
781import com.echothree.model.control.search.server.graphql.EntityAttributeGroupResultsObject;
782import com.echothree.model.control.search.server.graphql.EntityAttributeResultsObject;
783import com.echothree.model.control.search.server.graphql.EntityListItemResultsObject;
784import com.echothree.model.control.search.server.graphql.EntityTypeResultsObject;
785import com.echothree.model.control.search.server.graphql.ItemResultsObject;
786import com.echothree.model.control.search.server.graphql.SearchCheckSpellingActionTypeObject;
787import com.echothree.model.control.search.server.graphql.SearchDefaultOperatorObject;
788import com.echothree.model.control.search.server.graphql.SearchKindObject;
789import com.echothree.model.control.search.server.graphql.SearchResultActionTypeObject;
790import com.echothree.model.control.search.server.graphql.SearchSortDirectionObject;
791import com.echothree.model.control.search.server.graphql.SearchSortOrderObject;
792import com.echothree.model.control.search.server.graphql.SearchTypeObject;
793import com.echothree.model.control.search.server.graphql.SearchUseTypeObject;
794import com.echothree.model.control.search.server.graphql.ShippingMethodResultsObject;
795import com.echothree.model.control.search.server.graphql.VendorResultsObject;
796import com.echothree.model.control.search.server.graphql.WarehouseResultsObject;
797import com.echothree.model.control.security.server.graphql.SecurityRoleGroupObject;
798import com.echothree.model.control.security.server.graphql.SecurityRoleObject;
799import com.echothree.model.control.selector.server.graphql.SelectorKindObject;
800import com.echothree.model.control.selector.server.graphql.SelectorObject;
801import com.echothree.model.control.selector.server.graphql.SelectorTypeObject;
802import com.echothree.model.control.sequence.server.graphql.GetSequenceValueResultObject;
803import com.echothree.model.control.sequence.server.graphql.SequenceChecksumTypeObject;
804import com.echothree.model.control.sequence.server.graphql.SequenceEncoderTypeObject;
805import com.echothree.model.control.sequence.server.graphql.SequenceObject;
806import com.echothree.model.control.sequence.server.graphql.SequenceTypeObject;
807import com.echothree.model.control.shipment.server.graphql.FreeOnBoardObject;
808import com.echothree.model.control.shipping.server.control.ShippingControl;
809import com.echothree.model.control.shipping.server.graphql.ShippingMethodObject;
810import com.echothree.model.control.subscription.server.graphql.SubscriptionKindObject;
811import com.echothree.model.control.subscription.server.graphql.SubscriptionObject;
812import com.echothree.model.control.subscription.server.graphql.SubscriptionTypeObject;
813import com.echothree.model.control.tag.server.graphql.EntityTagObject;
814import com.echothree.model.control.tag.server.graphql.TagObject;
815import com.echothree.model.control.tag.server.graphql.TagScopeEntityTypeObject;
816import com.echothree.model.control.tag.server.graphql.TagScopeObject;
817import com.echothree.model.control.term.server.graphql.TermObject;
818import com.echothree.model.control.term.server.graphql.TermTypeObject;
819import com.echothree.model.control.uom.server.graphql.UnitOfMeasureKindObject;
820import com.echothree.model.control.uom.server.graphql.UnitOfMeasureKindUseObject;
821import com.echothree.model.control.uom.server.graphql.UnitOfMeasureKindUseTypeObject;
822import com.echothree.model.control.uom.server.graphql.UnitOfMeasureTypeObject;
823import com.echothree.model.control.user.server.graphql.RecoveryQuestionObject;
824import com.echothree.model.control.user.server.graphql.UserLoginObject;
825import com.echothree.model.control.user.server.graphql.UserSessionObject;
826import com.echothree.model.control.user.server.graphql.UserVisitGroupObject;
827import com.echothree.model.control.user.server.graphql.UserVisitObject;
828import com.echothree.model.control.vendor.server.graphql.ItemPurchasingCategoryObject;
829import com.echothree.model.control.vendor.server.graphql.VendorItemCostObject;
830import com.echothree.model.control.vendor.server.graphql.VendorItemObject;
831import com.echothree.model.control.vendor.server.graphql.VendorObject;
832import com.echothree.model.control.vendor.server.graphql.VendorTypeObject;
833import com.echothree.model.control.warehouse.server.graphql.LocationNameElementObject;
834import com.echothree.model.control.warehouse.server.graphql.LocationObject;
835import com.echothree.model.control.warehouse.server.graphql.LocationTypeObject;
836import com.echothree.model.control.warehouse.server.graphql.LocationUseTypeObject;
837import com.echothree.model.control.warehouse.server.graphql.WarehouseObject;
838import com.echothree.model.control.warehouse.server.graphql.WarehouseTypeObject;
839import com.echothree.model.control.wishlist.server.graphql.WishlistPriorityObject;
840import com.echothree.model.control.wishlist.server.graphql.WishlistTypeObject;
841import com.echothree.model.control.workflow.server.graphql.WorkflowDestinationObject;
842import com.echothree.model.control.workflow.server.graphql.WorkflowDestinationPartyTypeObject;
843import com.echothree.model.control.workflow.server.graphql.WorkflowDestinationSecurityRoleObject;
844import com.echothree.model.control.workflow.server.graphql.WorkflowDestinationSelectorObject;
845import com.echothree.model.control.workflow.server.graphql.WorkflowDestinationStepObject;
846import com.echothree.model.control.workflow.server.graphql.WorkflowEntityStatusObject;
847import com.echothree.model.control.workflow.server.graphql.WorkflowEntityTypeObject;
848import com.echothree.model.control.workflow.server.graphql.WorkflowEntranceObject;
849import com.echothree.model.control.workflow.server.graphql.WorkflowEntrancePartyTypeObject;
850import com.echothree.model.control.workflow.server.graphql.WorkflowEntranceSecurityRoleObject;
851import com.echothree.model.control.workflow.server.graphql.WorkflowEntranceSelectorObject;
852import com.echothree.model.control.workflow.server.graphql.WorkflowEntranceStepObject;
853import com.echothree.model.control.workflow.server.graphql.WorkflowObject;
854import com.echothree.model.control.workflow.server.graphql.WorkflowSelectorKindObject;
855import com.echothree.model.control.workflow.server.graphql.WorkflowStepObject;
856import com.echothree.model.control.workflow.server.graphql.WorkflowStepTypeObject;
857import com.echothree.model.data.accounting.common.CurrencyConstants;
858import com.echothree.model.data.accounting.common.GlAccountCategoryConstants;
859import com.echothree.model.data.accounting.common.GlAccountClassConstants;
860import com.echothree.model.data.accounting.common.GlAccountConstants;
861import com.echothree.model.data.accounting.common.GlAccountTypeConstants;
862import com.echothree.model.data.accounting.common.GlResourceTypeConstants;
863import com.echothree.model.data.accounting.common.ItemAccountingCategoryConstants;
864import com.echothree.model.data.accounting.common.SymbolPositionConstants;
865import com.echothree.model.data.accounting.common.TransactionConstants;
866import com.echothree.model.data.accounting.common.TransactionEntityRoleTypeConstants;
867import com.echothree.model.data.accounting.common.TransactionGlAccountCategoryConstants;
868import com.echothree.model.data.accounting.common.TransactionGroupConstants;
869import com.echothree.model.data.accounting.common.TransactionTimeTypeConstants;
870import com.echothree.model.data.accounting.common.TransactionTypeConstants;
871import com.echothree.model.data.accounting.server.entity.Currency;
872import com.echothree.model.data.accounting.server.entity.GlAccount;
873import com.echothree.model.data.accounting.server.entity.GlAccountCategory;
874import com.echothree.model.data.accounting.server.entity.GlAccountClass;
875import com.echothree.model.data.accounting.server.entity.GlAccountType;
876import com.echothree.model.data.accounting.server.entity.GlResourceType;
877import com.echothree.model.data.accounting.server.entity.ItemAccountingCategory;
878import com.echothree.model.data.accounting.server.entity.SymbolPosition;
879import com.echothree.model.data.accounting.server.entity.Transaction;
880import com.echothree.model.data.accounting.server.entity.TransactionEntityRoleType;
881import com.echothree.model.data.accounting.server.entity.TransactionGlAccountCategory;
882import com.echothree.model.data.accounting.server.entity.TransactionGroup;
883import com.echothree.model.data.accounting.server.entity.TransactionTimeType;
884import com.echothree.model.data.accounting.server.entity.TransactionType;
885import com.echothree.model.data.campaign.common.CampaignConstants;
886import com.echothree.model.data.campaign.common.CampaignContentConstants;
887import com.echothree.model.data.campaign.common.CampaignMediumConstants;
888import com.echothree.model.data.campaign.common.CampaignSourceConstants;
889import com.echothree.model.data.campaign.common.CampaignTermConstants;
890import com.echothree.model.data.campaign.server.entity.Campaign;
891import com.echothree.model.data.campaign.server.entity.CampaignContent;
892import com.echothree.model.data.campaign.server.entity.CampaignMedium;
893import com.echothree.model.data.campaign.server.entity.CampaignSource;
894import com.echothree.model.data.campaign.server.entity.CampaignTerm;
895import com.echothree.model.data.cancellationpolicy.common.CancellationKindConstants;
896import com.echothree.model.data.cancellationpolicy.common.CancellationPolicyConstants;
897import com.echothree.model.data.cancellationpolicy.server.entity.CancellationKind;
898import com.echothree.model.data.cancellationpolicy.server.entity.CancellationPolicy;
899import com.echothree.model.data.chain.common.ChainActionConstants;
900import com.echothree.model.data.chain.common.ChainActionSetConstants;
901import com.echothree.model.data.chain.common.ChainActionTypeConstants;
902import com.echothree.model.data.chain.common.ChainConstants;
903import com.echothree.model.data.chain.common.ChainEntityRoleTypeConstants;
904import com.echothree.model.data.chain.common.ChainInstanceConstants;
905import com.echothree.model.data.chain.common.ChainKindConstants;
906import com.echothree.model.data.chain.common.ChainTypeConstants;
907import com.echothree.model.data.chain.server.entity.Chain;
908import com.echothree.model.data.chain.server.entity.ChainAction;
909import com.echothree.model.data.chain.server.entity.ChainActionSet;
910import com.echothree.model.data.chain.server.entity.ChainActionType;
911import com.echothree.model.data.chain.server.entity.ChainEntityRoleType;
912import com.echothree.model.data.chain.server.entity.ChainInstance;
913import com.echothree.model.data.chain.server.entity.ChainKind;
914import com.echothree.model.data.chain.server.entity.ChainType;
915import com.echothree.model.data.contact.common.ContactMechanismPurposeConstants;
916import com.echothree.model.data.contact.server.entity.ContactMechanismPurpose;
917import com.echothree.model.data.contactlist.common.ContactListConstants;
918import com.echothree.model.data.contactlist.common.ContactListContactMechanismPurposeConstants;
919import com.echothree.model.data.contactlist.common.ContactListFrequencyConstants;
920import com.echothree.model.data.contactlist.common.ContactListGroupConstants;
921import com.echothree.model.data.contactlist.common.ContactListTypeConstants;
922import com.echothree.model.data.contactlist.common.CustomerTypeContactListConstants;
923import com.echothree.model.data.contactlist.common.CustomerTypeContactListGroupConstants;
924import com.echothree.model.data.contactlist.common.PartyContactListConstants;
925import com.echothree.model.data.contactlist.common.PartyTypeContactListConstants;
926import com.echothree.model.data.contactlist.common.PartyTypeContactListGroupConstants;
927import com.echothree.model.data.contactlist.server.entity.ContactList;
928import com.echothree.model.data.contactlist.server.entity.ContactListContactMechanismPurpose;
929import com.echothree.model.data.contactlist.server.entity.ContactListFrequency;
930import com.echothree.model.data.contactlist.server.entity.ContactListGroup;
931import com.echothree.model.data.contactlist.server.entity.ContactListType;
932import com.echothree.model.data.contactlist.server.entity.CustomerTypeContactList;
933import com.echothree.model.data.contactlist.server.entity.CustomerTypeContactListGroup;
934import com.echothree.model.data.contactlist.server.entity.PartyContactList;
935import com.echothree.model.data.contactlist.server.entity.PartyTypeContactList;
936import com.echothree.model.data.contactlist.server.entity.PartyTypeContactListGroup;
937import com.echothree.model.data.content.common.ContentCatalogConstants;
938import com.echothree.model.data.content.common.ContentCatalogItemConstants;
939import com.echothree.model.data.content.common.ContentCategoryConstants;
940import com.echothree.model.data.content.common.ContentCategoryItemConstants;
941import com.echothree.model.data.content.common.ContentCollectionConstants;
942import com.echothree.model.data.content.common.ContentPageAreaConstants;
943import com.echothree.model.data.content.common.ContentPageAreaTypeConstants;
944import com.echothree.model.data.content.common.ContentPageConstants;
945import com.echothree.model.data.content.common.ContentPageLayoutAreaConstants;
946import com.echothree.model.data.content.common.ContentPageLayoutConstants;
947import com.echothree.model.data.content.common.ContentSectionConstants;
948import com.echothree.model.data.content.common.ContentWebAddressConstants;
949import com.echothree.model.data.content.server.entity.ContentCatalog;
950import com.echothree.model.data.content.server.entity.ContentCatalogItem;
951import com.echothree.model.data.content.server.entity.ContentCategory;
952import com.echothree.model.data.content.server.entity.ContentCategoryItem;
953import com.echothree.model.data.content.server.entity.ContentCollection;
954import com.echothree.model.data.content.server.entity.ContentPage;
955import com.echothree.model.data.content.server.entity.ContentPageArea;
956import com.echothree.model.data.content.server.entity.ContentPageAreaType;
957import com.echothree.model.data.content.server.entity.ContentPageLayout;
958import com.echothree.model.data.content.server.entity.ContentPageLayoutArea;
959import com.echothree.model.data.content.server.entity.ContentSection;
960import com.echothree.model.data.content.server.entity.ContentWebAddress;
961import com.echothree.model.data.core.common.AppearanceConstants;
962import com.echothree.model.data.core.common.ColorConstants;
963import com.echothree.model.data.core.common.ComponentVendorConstants;
964import com.echothree.model.data.core.common.EntityAliasConstants;
965import com.echothree.model.data.core.common.EntityAliasTypeConstants;
966import com.echothree.model.data.core.common.EntityAttributeConstants;
967import com.echothree.model.data.core.common.EntityAttributeEntityAttributeGroupConstants;
968import com.echothree.model.data.core.common.EntityAttributeGroupConstants;
969import com.echothree.model.data.core.common.EntityAttributeTypeConstants;
970import com.echothree.model.data.core.common.EntityInstanceConstants;
971import com.echothree.model.data.core.common.EntityTypeConstants;
972import com.echothree.model.data.core.common.EventConstants;
973import com.echothree.model.data.core.common.EventTypeConstants;
974import com.echothree.model.data.core.common.FontStyleConstants;
975import com.echothree.model.data.core.common.FontWeightConstants;
976import com.echothree.model.data.core.common.MimeTypeConstants;
977import com.echothree.model.data.core.common.MimeTypeFileExtensionConstants;
978import com.echothree.model.data.core.common.TextDecorationConstants;
979import com.echothree.model.data.core.common.TextTransformationConstants;
980import com.echothree.model.data.core.server.entity.Appearance;
981import com.echothree.model.data.core.server.entity.Color;
982import com.echothree.model.data.core.server.entity.ComponentVendor;
983import com.echothree.model.data.core.server.entity.EntityAlias;
984import com.echothree.model.data.core.server.entity.EntityAliasType;
985import com.echothree.model.data.core.server.entity.EntityAttribute;
986import com.echothree.model.data.core.server.entity.EntityAttributeEntityAttributeGroup;
987import com.echothree.model.data.core.server.entity.EntityAttributeGroup;
988import com.echothree.model.data.core.server.entity.EntityAttributeType;
989import com.echothree.model.data.core.server.entity.EntityInstance;
990import com.echothree.model.data.core.server.entity.EntityType;
991import com.echothree.model.data.core.server.entity.EventType;
992import com.echothree.model.data.core.server.entity.FontStyle;
993import com.echothree.model.data.core.server.entity.FontWeight;
994import com.echothree.model.data.core.server.entity.MimeType;
995import com.echothree.model.data.core.server.entity.MimeTypeFileExtension;
996import com.echothree.model.data.core.server.entity.MimeTypeUsageType;
997import com.echothree.model.data.core.server.entity.TextDecoration;
998import com.echothree.model.data.core.server.entity.TextTransformation;
999import com.echothree.model.data.customer.common.CustomerConstants;
1000import com.echothree.model.data.customer.common.CustomerTypeConstants;
1001import com.echothree.model.data.customer.common.CustomerTypePaymentMethodConstants;
1002import com.echothree.model.data.customer.common.CustomerTypeShippingMethodConstants;
1003import com.echothree.model.data.customer.server.entity.Customer;
1004import com.echothree.model.data.customer.server.entity.CustomerType;
1005import com.echothree.model.data.customer.server.entity.CustomerTypePaymentMethod;
1006import com.echothree.model.data.customer.server.entity.CustomerTypeShippingMethod;
1007import com.echothree.model.data.employee.common.PartyEmployeeConstants;
1008import com.echothree.model.data.employee.server.entity.PartyEmployee;
1009import com.echothree.model.data.filter.common.FilterAdjustmentTypeConstants;
1010import com.echothree.model.data.filter.common.FilterConstants;
1011import com.echothree.model.data.filter.common.FilterEntranceStepConstants;
1012import com.echothree.model.data.filter.common.FilterKindConstants;
1013import com.echothree.model.data.filter.common.FilterStepConstants;
1014import com.echothree.model.data.filter.common.FilterStepDestinationConstants;
1015import com.echothree.model.data.filter.common.FilterStepElementConstants;
1016import com.echothree.model.data.filter.common.FilterTypeConstants;
1017import com.echothree.model.data.filter.server.entity.Filter;
1018import com.echothree.model.data.filter.server.entity.FilterAdjustment;
1019import com.echothree.model.data.filter.server.entity.FilterAdjustmentAmount;
1020import com.echothree.model.data.filter.server.entity.FilterAdjustmentFixedAmount;
1021import com.echothree.model.data.filter.server.entity.FilterAdjustmentPercent;
1022import com.echothree.model.data.filter.server.entity.FilterAdjustmentSource;
1023import com.echothree.model.data.filter.server.entity.FilterAdjustmentType;
1024import com.echothree.model.data.filter.server.entity.FilterEntranceStep;
1025import com.echothree.model.data.filter.server.entity.FilterKind;
1026import com.echothree.model.data.filter.server.entity.FilterStep;
1027import com.echothree.model.data.filter.server.entity.FilterStepDestination;
1028import com.echothree.model.data.filter.server.entity.FilterStepElement;
1029import com.echothree.model.data.filter.server.entity.FilterType;
1030import com.echothree.model.data.geo.common.GeoCodeAliasConstants;
1031import com.echothree.model.data.geo.common.GeoCodeAliasTypeConstants;
1032import com.echothree.model.data.geo.common.GeoCodeConstants;
1033import com.echothree.model.data.geo.common.GeoCodeCurrencyConstants;
1034import com.echothree.model.data.geo.common.GeoCodeDateTimeFormatConstants;
1035import com.echothree.model.data.geo.common.GeoCodeLanguageConstants;
1036import com.echothree.model.data.geo.common.GeoCodeScopeConstants;
1037import com.echothree.model.data.geo.common.GeoCodeTimeZoneConstants;
1038import com.echothree.model.data.geo.common.GeoCodeTypeConstants;
1039import com.echothree.model.data.geo.server.entity.GeoCode;
1040import com.echothree.model.data.geo.server.entity.GeoCodeAlias;
1041import com.echothree.model.data.geo.server.entity.GeoCodeAliasType;
1042import com.echothree.model.data.geo.server.entity.GeoCodeCurrency;
1043import com.echothree.model.data.geo.server.entity.GeoCodeDateTimeFormat;
1044import com.echothree.model.data.geo.server.entity.GeoCodeLanguage;
1045import com.echothree.model.data.geo.server.entity.GeoCodeScope;
1046import com.echothree.model.data.geo.server.entity.GeoCodeTimeZone;
1047import com.echothree.model.data.geo.server.entity.GeoCodeType;
1048import com.echothree.model.data.inventory.common.AllocationPriorityConstants;
1049import com.echothree.model.data.inventory.common.InventoryAdjustmentTypeConstants;
1050import com.echothree.model.data.inventory.common.InventoryBucketTypeConstants;
1051import com.echothree.model.data.inventory.common.InventoryConditionConstants;
1052import com.echothree.model.data.inventory.common.InventoryCostingMethodConstants;
1053import com.echothree.model.data.inventory.common.InventoryCostingPoolConstants;
1054import com.echothree.model.data.inventory.common.InventoryDispositionAdjustmentConstants;
1055import com.echothree.model.data.inventory.common.InventoryDispositionConstants;
1056import com.echothree.model.data.inventory.common.InventoryLayerBucketConstants;
1057import com.echothree.model.data.inventory.common.InventoryLayerConstants;
1058import com.echothree.model.data.inventory.common.InventoryLocationBucketConstants;
1059import com.echothree.model.data.inventory.common.InventoryLocationConstants;
1060import com.echothree.model.data.inventory.common.InventoryLocationGroupConstants;
1061import com.echothree.model.data.inventory.common.InventoryTransactionReasonConstants;
1062import com.echothree.model.data.inventory.common.InventoryTransactionRoleTypeConstants;
1063import com.echothree.model.data.inventory.common.InventoryTransactionTimeTypeConstants;
1064import com.echothree.model.data.inventory.common.InventoryTransactionTypeConstants;
1065import com.echothree.model.data.inventory.common.LotConstants;
1066import com.echothree.model.data.inventory.common.PartyBucketConstants;
1067import com.echothree.model.data.inventory.common.PartyInventoryCostingMethodConstants;
1068import com.echothree.model.data.inventory.server.entity.AllocationPriority;
1069import com.echothree.model.data.inventory.server.entity.InventoryAdjustmentType;
1070import com.echothree.model.data.inventory.server.entity.InventoryBucketType;
1071import com.echothree.model.data.inventory.server.entity.InventoryCondition;
1072import com.echothree.model.data.inventory.server.entity.InventoryCostingMethod;
1073import com.echothree.model.data.inventory.server.entity.InventoryCostingPool;
1074import com.echothree.model.data.inventory.server.entity.InventoryDisposition;
1075import com.echothree.model.data.inventory.server.entity.InventoryDispositionAdjustment;
1076import com.echothree.model.data.inventory.server.entity.InventoryLayer;
1077import com.echothree.model.data.inventory.server.entity.InventoryLayerBucket;
1078import com.echothree.model.data.inventory.server.entity.InventoryLocation;
1079import com.echothree.model.data.inventory.server.entity.InventoryLocationBucket;
1080import com.echothree.model.data.inventory.server.entity.InventoryLocationGroup;
1081import com.echothree.model.data.inventory.server.entity.InventoryTransactionReason;
1082import com.echothree.model.data.inventory.server.entity.InventoryTransactionRoleType;
1083import com.echothree.model.data.inventory.server.entity.InventoryTransactionTimeType;
1084import com.echothree.model.data.inventory.server.entity.InventoryTransactionType;
1085import com.echothree.model.data.inventory.server.entity.Lot;
1086import com.echothree.model.data.inventory.server.entity.PartyBucket;
1087import com.echothree.model.data.inventory.server.entity.PartyInventoryCostingMethod;
1088import com.echothree.model.data.item.common.ItemAliasChecksumTypeConstants;
1089import com.echothree.model.data.item.common.ItemAliasConstants;
1090import com.echothree.model.data.item.common.ItemAliasTypeConstants;
1091import com.echothree.model.data.item.common.ItemCategoryConstants;
1092import com.echothree.model.data.item.common.ItemConstants;
1093import com.echothree.model.data.item.common.ItemDeliveryTypeConstants;
1094import com.echothree.model.data.item.common.ItemDescriptionConstants;
1095import com.echothree.model.data.item.common.ItemDescriptionTypeConstants;
1096import com.echothree.model.data.item.common.ItemDescriptionTypeUseTypeConstants;
1097import com.echothree.model.data.item.common.ItemImageTypeConstants;
1098import com.echothree.model.data.item.common.ItemInventoryTypeConstants;
1099import com.echothree.model.data.item.common.ItemPriceConstants;
1100import com.echothree.model.data.item.common.ItemPriceTypeConstants;
1101import com.echothree.model.data.item.common.ItemTypeConstants;
1102import com.echothree.model.data.item.common.ItemUnitOfMeasureTypeConstants;
1103import com.echothree.model.data.item.common.ItemUseTypeConstants;
1104import com.echothree.model.data.item.common.ItemVolumeTypeConstants;
1105import com.echothree.model.data.item.common.ItemWeightTypeConstants;
1106import com.echothree.model.data.item.common.RelatedItemConstants;
1107import com.echothree.model.data.item.common.RelatedItemTypeConstants;
1108import com.echothree.model.data.item.server.entity.Item;
1109import com.echothree.model.data.item.server.entity.ItemAlias;
1110import com.echothree.model.data.item.server.entity.ItemAliasChecksumType;
1111import com.echothree.model.data.item.server.entity.ItemAliasType;
1112import com.echothree.model.data.item.server.entity.ItemCategory;
1113import com.echothree.model.data.item.server.entity.ItemDeliveryType;
1114import com.echothree.model.data.item.server.entity.ItemDescription;
1115import com.echothree.model.data.item.server.entity.ItemDescriptionType;
1116import com.echothree.model.data.item.server.entity.ItemDescriptionTypeUse;
1117import com.echothree.model.data.item.server.entity.ItemDescriptionTypeUseType;
1118import com.echothree.model.data.item.server.entity.ItemImageType;
1119import com.echothree.model.data.item.server.entity.ItemInventoryType;
1120import com.echothree.model.data.item.server.entity.ItemPrice;
1121import com.echothree.model.data.item.server.entity.ItemPriceType;
1122import com.echothree.model.data.item.server.entity.ItemType;
1123import com.echothree.model.data.item.server.entity.ItemUnitOfMeasureType;
1124import com.echothree.model.data.item.server.entity.ItemUseType;
1125import com.echothree.model.data.item.server.entity.ItemVolumeType;
1126import com.echothree.model.data.item.server.entity.ItemWeightType;
1127import com.echothree.model.data.item.server.entity.RelatedItem;
1128import com.echothree.model.data.item.server.entity.RelatedItemType;
1129import com.echothree.model.data.offer.common.OfferConstants;
1130import com.echothree.model.data.offer.common.OfferCustomerTypeConstants;
1131import com.echothree.model.data.offer.common.OfferItemConstants;
1132import com.echothree.model.data.offer.common.OfferItemPriceConstants;
1133import com.echothree.model.data.offer.common.OfferNameElementConstants;
1134import com.echothree.model.data.offer.common.UseConstants;
1135import com.echothree.model.data.offer.common.UseNameElementConstants;
1136import com.echothree.model.data.offer.common.UseTypeConstants;
1137import com.echothree.model.data.offer.server.entity.Offer;
1138import com.echothree.model.data.offer.server.entity.OfferCustomerType;
1139import com.echothree.model.data.offer.server.entity.OfferItem;
1140import com.echothree.model.data.offer.server.entity.OfferItemPrice;
1141import com.echothree.model.data.offer.server.entity.OfferNameElement;
1142import com.echothree.model.data.offer.server.entity.OfferUse;
1143import com.echothree.model.data.offer.server.entity.Use;
1144import com.echothree.model.data.offer.server.entity.UseNameElement;
1145import com.echothree.model.data.offer.server.entity.UseType;
1146import com.echothree.model.data.order.common.OrderPriorityConstants;
1147import com.echothree.model.data.order.common.OrderTimeTypeConstants;
1148import com.echothree.model.data.order.common.OrderTypeConstants;
1149import com.echothree.model.data.order.server.entity.OrderPriority;
1150import com.echothree.model.data.order.server.entity.OrderTimeType;
1151import com.echothree.model.data.order.server.entity.OrderType;
1152import com.echothree.model.data.party.common.DateTimeFormatConstants;
1153import com.echothree.model.data.party.common.LanguageConstants;
1154import com.echothree.model.data.party.common.NameSuffixConstants;
1155import com.echothree.model.data.party.common.PartyAliasTypeConstants;
1156import com.echothree.model.data.party.common.PartyCompanyConstants;
1157import com.echothree.model.data.party.common.PartyConstants;
1158import com.echothree.model.data.party.common.PartyDepartmentConstants;
1159import com.echothree.model.data.party.common.PartyDivisionConstants;
1160import com.echothree.model.data.party.common.PartyTypeConstants;
1161import com.echothree.model.data.party.common.PersonalTitleConstants;
1162import com.echothree.model.data.party.common.RoleTypeConstants;
1163import com.echothree.model.data.party.common.TimeZoneConstants;
1164import com.echothree.model.data.party.server.entity.DateTimeFormat;
1165import com.echothree.model.data.party.server.entity.Language;
1166import com.echothree.model.data.party.server.entity.Party;
1167import com.echothree.model.data.party.server.entity.PartyAlias;
1168import com.echothree.model.data.party.server.entity.PartyAliasType;
1169import com.echothree.model.data.party.server.entity.PartyCompany;
1170import com.echothree.model.data.party.server.entity.PartyDepartment;
1171import com.echothree.model.data.party.server.entity.PartyDivision;
1172import com.echothree.model.data.party.server.entity.PartyType;
1173import com.echothree.model.data.party.server.entity.RoleType;
1174import com.echothree.model.data.party.server.entity.TimeZone;
1175import com.echothree.model.data.payment.common.PaymentMethodConstants;
1176import com.echothree.model.data.payment.common.PaymentMethodTypeConstants;
1177import com.echothree.model.data.payment.common.PaymentProcessorActionTypeConstants;
1178import com.echothree.model.data.payment.common.PaymentProcessorConstants;
1179import com.echothree.model.data.payment.common.PaymentProcessorResultCodeConstants;
1180import com.echothree.model.data.payment.common.PaymentProcessorTransactionConstants;
1181import com.echothree.model.data.payment.common.PaymentProcessorTypeConstants;
1182import com.echothree.model.data.payment.server.entity.PaymentMethod;
1183import com.echothree.model.data.payment.server.entity.PaymentMethodType;
1184import com.echothree.model.data.payment.server.entity.PaymentProcessor;
1185import com.echothree.model.data.payment.server.entity.PaymentProcessorActionType;
1186import com.echothree.model.data.payment.server.entity.PaymentProcessorResultCode;
1187import com.echothree.model.data.payment.server.entity.PaymentProcessorTransaction;
1188import com.echothree.model.data.payment.server.entity.PaymentProcessorType;
1189import com.echothree.model.data.payment.server.entity.PaymentProcessorTypeCode;
1190import com.echothree.model.data.payment.server.entity.PaymentProcessorTypeCodeType;
1191import com.echothree.model.data.period.common.PeriodConstants;
1192import com.echothree.model.data.period.common.PeriodKindConstants;
1193import com.echothree.model.data.period.common.PeriodTypeConstants;
1194import com.echothree.model.data.period.server.entity.PeriodKind;
1195import com.echothree.model.data.period.server.entity.PeriodType;
1196import com.echothree.model.data.queue.common.QueueTypeConstants;
1197import com.echothree.model.data.queue.server.entity.QueueType;
1198import com.echothree.model.data.returnpolicy.common.ReturnKindConstants;
1199import com.echothree.model.data.returnpolicy.common.ReturnPolicyConstants;
1200import com.echothree.model.data.returnpolicy.server.entity.ReturnKind;
1201import com.echothree.model.data.returnpolicy.server.entity.ReturnPolicy;
1202import com.echothree.model.data.search.common.SearchCheckSpellingActionTypeConstants;
1203import com.echothree.model.data.search.common.SearchDefaultOperatorConstants;
1204import com.echothree.model.data.search.common.SearchKindConstants;
1205import com.echothree.model.data.search.common.SearchResultActionTypeConstants;
1206import com.echothree.model.data.search.common.SearchSortDirectionConstants;
1207import com.echothree.model.data.search.common.SearchSortOrderConstants;
1208import com.echothree.model.data.search.common.SearchTypeConstants;
1209import com.echothree.model.data.search.common.SearchUseTypeConstants;
1210import com.echothree.model.data.search.server.entity.SearchCheckSpellingActionType;
1211import com.echothree.model.data.search.server.entity.SearchDefaultOperator;
1212import com.echothree.model.data.search.server.entity.SearchKind;
1213import com.echothree.model.data.search.server.entity.SearchResultActionType;
1214import com.echothree.model.data.search.server.entity.SearchSortDirection;
1215import com.echothree.model.data.search.server.entity.SearchSortOrder;
1216import com.echothree.model.data.search.server.entity.SearchType;
1217import com.echothree.model.data.search.server.entity.SearchUseType;
1218import com.echothree.model.data.security.common.SecurityRoleConstants;
1219import com.echothree.model.data.security.common.SecurityRoleGroupConstants;
1220import com.echothree.model.data.security.server.entity.SecurityRole;
1221import com.echothree.model.data.security.server.entity.SecurityRoleGroup;
1222import com.echothree.model.data.selector.common.SelectorKindConstants;
1223import com.echothree.model.data.selector.common.SelectorTypeConstants;
1224import com.echothree.model.data.selector.server.entity.Selector;
1225import com.echothree.model.data.selector.server.entity.SelectorKind;
1226import com.echothree.model.data.selector.server.entity.SelectorType;
1227import com.echothree.model.data.sequence.common.SequenceChecksumTypeConstants;
1228import com.echothree.model.data.sequence.common.SequenceConstants;
1229import com.echothree.model.data.sequence.common.SequenceEncoderTypeConstants;
1230import com.echothree.model.data.sequence.common.SequenceTypeConstants;
1231import com.echothree.model.data.sequence.server.entity.Sequence;
1232import com.echothree.model.data.sequence.server.entity.SequenceChecksumType;
1233import com.echothree.model.data.sequence.server.entity.SequenceEncoderType;
1234import com.echothree.model.data.sequence.server.entity.SequenceType;
1235import com.echothree.model.data.shipment.common.FreeOnBoardConstants;
1236import com.echothree.model.data.shipment.server.entity.FreeOnBoard;
1237import com.echothree.model.data.shipping.common.ShippingMethodConstants;
1238import com.echothree.model.data.shipping.server.entity.ShippingMethod;
1239import com.echothree.model.data.subscription.common.SubscriptionConstants;
1240import com.echothree.model.data.subscription.common.SubscriptionKindConstants;
1241import com.echothree.model.data.subscription.common.SubscriptionTypeConstants;
1242import com.echothree.model.data.subscription.server.entity.Subscription;
1243import com.echothree.model.data.subscription.server.entity.SubscriptionKind;
1244import com.echothree.model.data.subscription.server.entity.SubscriptionType;
1245import com.echothree.model.data.tag.common.EntityTagConstants;
1246import com.echothree.model.data.tag.common.TagConstants;
1247import com.echothree.model.data.tag.common.TagScopeConstants;
1248import com.echothree.model.data.tag.common.TagScopeEntityTypeConstants;
1249import com.echothree.model.data.tag.server.entity.EntityTag;
1250import com.echothree.model.data.tag.server.entity.Tag;
1251import com.echothree.model.data.tag.server.entity.TagScope;
1252import com.echothree.model.data.tag.server.entity.TagScopeEntityType;
1253import com.echothree.model.data.term.common.TermConstants;
1254import com.echothree.model.data.term.common.TermTypeConstants;
1255import com.echothree.model.data.term.server.entity.Term;
1256import com.echothree.model.data.term.server.entity.TermType;
1257import com.echothree.model.data.uom.common.UnitOfMeasureKindConstants;
1258import com.echothree.model.data.uom.common.UnitOfMeasureKindUseConstants;
1259import com.echothree.model.data.uom.common.UnitOfMeasureKindUseTypeConstants;
1260import com.echothree.model.data.uom.common.UnitOfMeasureTypeConstants;
1261import com.echothree.model.data.uom.server.entity.UnitOfMeasureKind;
1262import com.echothree.model.data.uom.server.entity.UnitOfMeasureKindUse;
1263import com.echothree.model.data.uom.server.entity.UnitOfMeasureKindUseType;
1264import com.echothree.model.data.uom.server.entity.UnitOfMeasureType;
1265import com.echothree.model.data.user.common.RecoveryQuestionConstants;
1266import com.echothree.model.data.user.common.UserVisitGroupConstants;
1267import com.echothree.model.data.user.server.entity.RecoveryQuestion;
1268import com.echothree.model.data.user.server.entity.UserLogin;
1269import com.echothree.model.data.user.server.entity.UserVisitGroup;
1270import com.echothree.model.data.vendor.common.ItemPurchasingCategoryConstants;
1271import com.echothree.model.data.vendor.common.VendorConstants;
1272import com.echothree.model.data.vendor.common.VendorItemConstants;
1273import com.echothree.model.data.vendor.common.VendorItemCostConstants;
1274import com.echothree.model.data.vendor.common.VendorTypeConstants;
1275import com.echothree.model.data.vendor.server.entity.ItemPurchasingCategory;
1276import com.echothree.model.data.vendor.server.entity.Vendor;
1277import com.echothree.model.data.vendor.server.entity.VendorItem;
1278import com.echothree.model.data.vendor.server.entity.VendorItemCost;
1279import com.echothree.model.data.vendor.server.entity.VendorType;
1280import com.echothree.model.data.warehouse.common.LocationConstants;
1281import com.echothree.model.data.warehouse.common.LocationNameElementConstants;
1282import com.echothree.model.data.warehouse.common.LocationTypeConstants;
1283import com.echothree.model.data.warehouse.common.LocationUseTypeConstants;
1284import com.echothree.model.data.warehouse.common.WarehouseConstants;
1285import com.echothree.model.data.warehouse.common.WarehouseTypeConstants;
1286import com.echothree.model.data.warehouse.server.entity.Location;
1287import com.echothree.model.data.warehouse.server.entity.LocationNameElement;
1288import com.echothree.model.data.warehouse.server.entity.LocationType;
1289import com.echothree.model.data.warehouse.server.entity.LocationUseType;
1290import com.echothree.model.data.warehouse.server.entity.Warehouse;
1291import com.echothree.model.data.warehouse.server.entity.WarehouseType;
1292import com.echothree.model.data.wishlist.common.WishlistPriorityConstants;
1293import com.echothree.model.data.wishlist.common.WishlistTypeConstants;
1294import com.echothree.model.data.wishlist.server.entity.WishlistPriority;
1295import com.echothree.model.data.wishlist.server.entity.WishlistType;
1296import com.echothree.model.data.workflow.common.WorkflowConstants;
1297import com.echothree.model.data.workflow.common.WorkflowDestinationConstants;
1298import com.echothree.model.data.workflow.common.WorkflowDestinationPartyTypeConstants;
1299import com.echothree.model.data.workflow.common.WorkflowDestinationSecurityRoleConstants;
1300import com.echothree.model.data.workflow.common.WorkflowDestinationSelectorConstants;
1301import com.echothree.model.data.workflow.common.WorkflowDestinationStepConstants;
1302import com.echothree.model.data.workflow.common.WorkflowEntityStatusConstants;
1303import com.echothree.model.data.workflow.common.WorkflowEntityTypeConstants;
1304import com.echothree.model.data.workflow.common.WorkflowEntranceConstants;
1305import com.echothree.model.data.workflow.common.WorkflowEntrancePartyTypeConstants;
1306import com.echothree.model.data.workflow.common.WorkflowEntranceSecurityRoleConstants;
1307import com.echothree.model.data.workflow.common.WorkflowEntranceSelectorConstants;
1308import com.echothree.model.data.workflow.common.WorkflowEntranceStepConstants;
1309import com.echothree.model.data.workflow.common.WorkflowSelectorKindConstants;
1310import com.echothree.model.data.workflow.common.WorkflowStepConstants;
1311import com.echothree.model.data.workflow.common.WorkflowStepTypeConstants;
1312import com.echothree.model.data.workflow.server.entity.Workflow;
1313import com.echothree.model.data.workflow.server.entity.WorkflowDestination;
1314import com.echothree.model.data.workflow.server.entity.WorkflowDestinationPartyType;
1315import com.echothree.model.data.workflow.server.entity.WorkflowDestinationSecurityRole;
1316import com.echothree.model.data.workflow.server.entity.WorkflowDestinationSelector;
1317import com.echothree.model.data.workflow.server.entity.WorkflowDestinationStep;
1318import com.echothree.model.data.workflow.server.entity.WorkflowEntityType;
1319import com.echothree.model.data.workflow.server.entity.WorkflowEntrance;
1320import com.echothree.model.data.workflow.server.entity.WorkflowEntrancePartyType;
1321import com.echothree.model.data.workflow.server.entity.WorkflowEntranceSecurityRole;
1322import com.echothree.model.data.workflow.server.entity.WorkflowEntranceSelector;
1323import com.echothree.model.data.workflow.server.entity.WorkflowEntranceStep;
1324import com.echothree.model.data.workflow.server.entity.WorkflowSelectorKind;
1325import com.echothree.model.data.workflow.server.entity.WorkflowStep;
1326import com.echothree.model.data.workflow.server.entity.WorkflowStepType;
1327import com.echothree.util.server.persistence.Session;
1328import graphql.annotations.annotationTypes.GraphQLField;
1329import graphql.annotations.annotationTypes.GraphQLID;
1330import graphql.annotations.annotationTypes.GraphQLName;
1331import graphql.annotations.annotationTypes.GraphQLNonNull;
1332import graphql.annotations.connection.GraphQLConnection;
1333import graphql.schema.DataFetchingEnvironment;
1334import java.util.ArrayList;
1335import java.util.Collection;
1336import static java.util.Collections.emptyList;
1337import java.util.stream.Collectors;
1338import javax.enterprise.inject.spi.CDI;
1339import javax.naming.NamingException;
1340
1341@GraphQLName("query")
1342public interface GraphQlQueries {
1343
1344    @GraphQLField
1345    @GraphQLName("searchKind")
1346    static SearchKindObject searchKind(final DataFetchingEnvironment env,
1347            @GraphQLName("searchKindName") final String searchKindName,
1348            @GraphQLName("id") @GraphQLID final String id) {
1349        SearchKind searchKind;
1350
1351        try {
1352            var commandForm = SearchUtil.getHome().getGetSearchKindForm();
1353
1354            commandForm.setSearchKindName(searchKindName);
1355            commandForm.setUuid(id);
1356
1357            searchKind = CDI.current().select(GetSearchKindCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
1358        } catch (NamingException ex) {
1359            throw new RuntimeException(ex);
1360        }
1361
1362        return searchKind == null ? null : new SearchKindObject(searchKind);
1363    }
1364
1365    @GraphQLField
1366    @GraphQLName("searchKinds")
1367    @GraphQLNonNull
1368    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
1369    static CountingPaginatedData<SearchKindObject> searchKinds(final DataFetchingEnvironment env) {
1370        CountingPaginatedData<SearchKindObject> data;
1371
1372        try {
1373            var searchControl = Session.getModelController(SearchControl.class);
1374            var totalCount = searchControl.countSearchKinds();
1375
1376            try(var objectLimiter = new ObjectLimiter(env, SearchKindConstants.COMPONENT_VENDOR_NAME, SearchKindConstants.ENTITY_TYPE_NAME, totalCount)) {
1377                var commandForm = SearchUtil.getHome().getGetSearchKindsForm();
1378                var entities = CDI.current().select(GetSearchKindsCommand.class).get().getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1379
1380                if(entities == null) {
1381                    data = Connections.emptyConnection();
1382                } else {
1383                    var searchKinds = entities.stream().map(SearchKindObject::new).collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
1384
1385                    data = new CountedObjects<>(objectLimiter, searchKinds);
1386                }
1387            }
1388        } catch (NamingException ex) {
1389            throw new RuntimeException(ex);
1390        }
1391
1392        return data;
1393    }
1394
1395    @GraphQLField
1396    @GraphQLName("searchType")
1397    static SearchTypeObject searchType(final DataFetchingEnvironment env,
1398            @GraphQLName("searchKindName") final String searchKindName,
1399            @GraphQLName("searchTypeName") final String searchTypeName,
1400            @GraphQLName("id") @GraphQLID final String id) {
1401        SearchType searchType;
1402
1403        try {
1404            var commandForm = SearchUtil.getHome().getGetSearchTypeForm();
1405
1406            commandForm.setSearchKindName(searchKindName);
1407            commandForm.setSearchTypeName(searchTypeName);
1408            commandForm.setUuid(id);
1409
1410            searchType = CDI.current().select(GetSearchTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
1411        } catch (NamingException ex) {
1412            throw new RuntimeException(ex);
1413        }
1414
1415        return searchType == null ? null : new SearchTypeObject(searchType);
1416    }
1417
1418    @GraphQLField
1419    @GraphQLName("searchTypes")
1420    @GraphQLNonNull
1421    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
1422    static CountingPaginatedData<SearchTypeObject> searchTypes(final DataFetchingEnvironment env,
1423            @GraphQLName("searchKindName") @GraphQLNonNull final String searchKindName) {
1424        CountingPaginatedData<SearchTypeObject> data;
1425
1426        try {
1427            var commandForm = SearchUtil.getHome().getGetSearchTypesForm();
1428            var command = CDI.current().select(GetSearchTypesCommand.class).get();
1429
1430            commandForm.setSearchKindName(searchKindName);
1431
1432            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1433            if(totalEntities == null) {
1434                data = Connections.emptyConnection();
1435            } else {
1436                try(var objectLimiter = new ObjectLimiter(env, SearchTypeConstants.COMPONENT_VENDOR_NAME, SearchTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
1437                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1438
1439                    var searchTypes = entities.stream()
1440                            .map(SearchTypeObject::new)
1441                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
1442
1443                    data = new CountedObjects<>(objectLimiter, searchTypes);
1444                }
1445            }
1446        } catch (NamingException ex) {
1447            throw new RuntimeException(ex);
1448        }
1449
1450        return data;
1451    }
1452
1453    @GraphQLField
1454    @GraphQLName("searchSortOrder")
1455    static SearchSortOrderObject searchSortOrder(final DataFetchingEnvironment env,
1456            @GraphQLName("searchKindName") final String searchKindName,
1457            @GraphQLName("searchSortOrderName") final String searchSortOrderName,
1458            @GraphQLName("id") @GraphQLID final String id) {
1459        SearchSortOrder searchSortOrder;
1460
1461        try {
1462            var commandForm = SearchUtil.getHome().getGetSearchSortOrderForm();
1463
1464            commandForm.setSearchKindName(searchKindName);
1465            commandForm.setSearchSortOrderName(searchSortOrderName);
1466            commandForm.setUuid(id);
1467
1468            searchSortOrder = CDI.current().select(GetSearchSortOrderCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
1469        } catch (NamingException ex) {
1470            throw new RuntimeException(ex);
1471        }
1472
1473        return searchSortOrder == null ? null : new SearchSortOrderObject(searchSortOrder);
1474    }
1475
1476    @GraphQLField
1477    @GraphQLName("searchSortOrders")
1478    @GraphQLNonNull
1479    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
1480    static CountingPaginatedData<SearchSortOrderObject> searchSortOrders(final DataFetchingEnvironment env,
1481            @GraphQLName("searchKindName") @GraphQLNonNull final String searchKindName) {
1482        CountingPaginatedData<SearchSortOrderObject> data;
1483
1484        try {
1485            var commandForm = SearchUtil.getHome().getGetSearchSortOrdersForm();
1486            var command = CDI.current().select(GetSearchSortOrdersCommand.class).get();
1487
1488            commandForm.setSearchKindName(searchKindName);
1489
1490            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1491            if(totalEntities == null) {
1492                data = Connections.emptyConnection();
1493            } else {
1494                try(var objectLimiter = new ObjectLimiter(env, SearchSortOrderConstants.COMPONENT_VENDOR_NAME, SearchSortOrderConstants.ENTITY_TYPE_NAME, totalEntities)) {
1495                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1496
1497                    var searchSortOrders = entities.stream()
1498                            .map(SearchSortOrderObject::new)
1499                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
1500
1501                    data = new CountedObjects<>(objectLimiter, searchSortOrders);
1502                }
1503            }
1504        } catch (NamingException ex) {
1505            throw new RuntimeException(ex);
1506        }
1507
1508        return data;
1509    }
1510
1511    @GraphQLField
1512    @GraphQLName("searchUseType")
1513    static SearchUseTypeObject searchUseType(final DataFetchingEnvironment env,
1514            @GraphQLName("searchUseTypeName") final String searchUseTypeName,
1515            @GraphQLName("id") @GraphQLID final String id) {
1516        SearchUseType searchUseType;
1517
1518        try {
1519            var commandForm = SearchUtil.getHome().getGetSearchUseTypeForm();
1520
1521            commandForm.setSearchUseTypeName(searchUseTypeName);
1522            commandForm.setUuid(id);
1523
1524            searchUseType = CDI.current().select(GetSearchUseTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
1525        } catch (NamingException ex) {
1526            throw new RuntimeException(ex);
1527        }
1528
1529        return searchUseType == null ? null : new SearchUseTypeObject(searchUseType);
1530    }
1531
1532    @GraphQLField
1533    @GraphQLName("searchUseTypes")
1534    @GraphQLNonNull
1535    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
1536    static CountingPaginatedData<SearchUseTypeObject> searchUseTypes(final DataFetchingEnvironment env) {
1537        CountingPaginatedData<SearchUseTypeObject> data;
1538
1539        try {
1540            var searchControl = Session.getModelController(SearchControl.class);
1541            var totalCount = searchControl.countSearchUseTypes();
1542
1543            try(var objectLimiter = new ObjectLimiter(env, SearchUseTypeConstants.COMPONENT_VENDOR_NAME, SearchUseTypeConstants.ENTITY_TYPE_NAME, totalCount)) {
1544                var commandForm = SearchUtil.getHome().getGetSearchUseTypesForm();
1545                var entities = CDI.current().select(GetSearchUseTypesCommand.class).get().getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1546
1547                if(entities == null) {
1548                    data = Connections.emptyConnection();
1549                } else {
1550                    var searchUseTypes = entities.stream().map(SearchUseTypeObject::new).collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
1551
1552                    data = new CountedObjects<>(objectLimiter, searchUseTypes);
1553                }
1554            }
1555        } catch (NamingException ex) {
1556            throw new RuntimeException(ex);
1557        }
1558
1559        return data;
1560    }
1561
1562    @GraphQLField
1563    @GraphQLName("searchDefaultOperator")
1564    static SearchDefaultOperatorObject searchDefaultOperator(final DataFetchingEnvironment env,
1565            @GraphQLName("searchDefaultOperatorName") final String searchDefaultOperatorName,
1566            @GraphQLName("id") @GraphQLID final String id) {
1567        SearchDefaultOperator searchDefaultOperator;
1568
1569        try {
1570            var commandForm = SearchUtil.getHome().getGetSearchDefaultOperatorForm();
1571
1572            commandForm.setSearchDefaultOperatorName(searchDefaultOperatorName);
1573            commandForm.setUuid(id);
1574
1575            searchDefaultOperator = CDI.current().select(GetSearchDefaultOperatorCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
1576        } catch (NamingException ex) {
1577            throw new RuntimeException(ex);
1578        }
1579
1580        return searchDefaultOperator == null ? null : new SearchDefaultOperatorObject(searchDefaultOperator);
1581    }
1582
1583    @GraphQLField
1584    @GraphQLName("searchDefaultOperators")
1585    @GraphQLNonNull
1586    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
1587    static CountingPaginatedData<SearchDefaultOperatorObject> searchDefaultOperators(final DataFetchingEnvironment env) {
1588        CountingPaginatedData<SearchDefaultOperatorObject> data;
1589
1590        try {
1591            var searchControl = Session.getModelController(SearchControl.class);
1592            var totalCount = searchControl.countSearchDefaultOperators();
1593
1594            try(var objectLimiter = new ObjectLimiter(env, SearchDefaultOperatorConstants.COMPONENT_VENDOR_NAME, SearchDefaultOperatorConstants.ENTITY_TYPE_NAME, totalCount)) {
1595                var commandForm = SearchUtil.getHome().getGetSearchDefaultOperatorsForm();
1596                var entities = CDI.current().select(GetSearchDefaultOperatorsCommand.class).get().getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1597
1598                if(entities == null) {
1599                    data = Connections.emptyConnection();
1600                } else {
1601                    var searchDefaultOperators = entities.stream().map(SearchDefaultOperatorObject::new).collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
1602
1603                    data = new CountedObjects<>(objectLimiter, searchDefaultOperators);
1604                }
1605            }
1606        } catch (NamingException ex) {
1607            throw new RuntimeException(ex);
1608        }
1609
1610        return data;
1611    }
1612
1613    @GraphQLField
1614    @GraphQLName("searchSortDirection")
1615    static SearchSortDirectionObject searchSortDirection(final DataFetchingEnvironment env,
1616            @GraphQLName("searchSortDirectionName") final String searchSortDirectionName,
1617            @GraphQLName("id") @GraphQLID final String id) {
1618        SearchSortDirection searchSortDirection;
1619
1620        try {
1621            var commandForm = SearchUtil.getHome().getGetSearchSortDirectionForm();
1622
1623            commandForm.setSearchSortDirectionName(searchSortDirectionName);
1624            commandForm.setUuid(id);
1625
1626            searchSortDirection = CDI.current().select(GetSearchSortDirectionCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
1627        } catch (NamingException ex) {
1628            throw new RuntimeException(ex);
1629        }
1630
1631        return searchSortDirection == null ? null : new SearchSortDirectionObject(searchSortDirection);
1632    }
1633
1634    @GraphQLField
1635    @GraphQLName("searchSortDirections")
1636    @GraphQLNonNull
1637    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
1638    static CountingPaginatedData<SearchSortDirectionObject> searchSortDirections(final DataFetchingEnvironment env) {
1639        CountingPaginatedData<SearchSortDirectionObject> data;
1640
1641        try {
1642            var searchControl = Session.getModelController(SearchControl.class);
1643            var totalCount = searchControl.countSearchSortDirections();
1644
1645            try(var objectLimiter = new ObjectLimiter(env, SearchSortDirectionConstants.COMPONENT_VENDOR_NAME, SearchSortDirectionConstants.ENTITY_TYPE_NAME, totalCount)) {
1646                var commandForm = SearchUtil.getHome().getGetSearchSortDirectionsForm();
1647                var entities = CDI.current().select(GetSearchSortDirectionsCommand.class).get().getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1648
1649                if(entities == null) {
1650                    data = Connections.emptyConnection();
1651                } else {
1652                    var searchSortDirections = entities.stream().map(SearchSortDirectionObject::new).collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
1653
1654                    data = new CountedObjects<>(objectLimiter, searchSortDirections);
1655                }
1656            }
1657        } catch (NamingException ex) {
1658            throw new RuntimeException(ex);
1659        }
1660
1661        return data;
1662    }
1663
1664    @GraphQLField
1665    @GraphQLName("searchResultActionType")
1666    static SearchResultActionTypeObject searchResultActionType(final DataFetchingEnvironment env,
1667            @GraphQLName("searchResultActionTypeName") final String searchResultActionTypeName,
1668            @GraphQLName("id") @GraphQLID final String id) {
1669        SearchResultActionType searchResultActionType;
1670
1671        try {
1672            var commandForm = SearchUtil.getHome().getGetSearchResultActionTypeForm();
1673
1674            commandForm.setSearchResultActionTypeName(searchResultActionTypeName);
1675            commandForm.setUuid(id);
1676
1677            searchResultActionType = CDI.current().select(GetSearchResultActionTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
1678        } catch (NamingException ex) {
1679            throw new RuntimeException(ex);
1680        }
1681
1682        return searchResultActionType == null ? null : new SearchResultActionTypeObject(searchResultActionType);
1683    }
1684
1685    @GraphQLField
1686    @GraphQLName("searchResultActionTypes")
1687    @GraphQLNonNull
1688    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
1689    static CountingPaginatedData<SearchResultActionTypeObject> searchResultActionTypes(final DataFetchingEnvironment env) {
1690        CountingPaginatedData<SearchResultActionTypeObject> data;
1691
1692        try {
1693            var commandForm = SearchUtil.getHome().getGetSearchResultActionTypesForm();
1694            var command = CDI.current().select(GetSearchResultActionTypesCommand.class).get();
1695
1696            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1697            if(totalEntities == null) {
1698                data = Connections.emptyConnection();
1699            } else {
1700                try(var objectLimiter = new ObjectLimiter(env, SearchResultActionTypeConstants.COMPONENT_VENDOR_NAME, SearchResultActionTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
1701                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1702
1703                    var searchResultActionTypes = entities.stream()
1704                            .map(SearchResultActionTypeObject::new)
1705                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
1706
1707                    data = new CountedObjects<>(objectLimiter, searchResultActionTypes);
1708                }
1709            }
1710        } catch (NamingException ex) {
1711            throw new RuntimeException(ex);
1712        }
1713
1714        return data;
1715    }
1716
1717    @GraphQLField
1718    @GraphQLName("searchCheckSpellingActionType")
1719    static SearchCheckSpellingActionTypeObject searchCheckSpellingActionType(final DataFetchingEnvironment env,
1720            @GraphQLName("searchCheckSpellingActionTypeName") final String searchCheckSpellingActionTypeName,
1721            @GraphQLName("id") @GraphQLID final String id) {
1722        SearchCheckSpellingActionType searchCheckSpellingActionType;
1723
1724        try {
1725            var commandForm = SearchUtil.getHome().getGetSearchCheckSpellingActionTypeForm();
1726
1727            commandForm.setSearchCheckSpellingActionTypeName(searchCheckSpellingActionTypeName);
1728            commandForm.setUuid(id);
1729
1730            searchCheckSpellingActionType = CDI.current().select(GetSearchCheckSpellingActionTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
1731        } catch (NamingException ex) {
1732            throw new RuntimeException(ex);
1733        }
1734
1735        return searchCheckSpellingActionType == null ? null : new SearchCheckSpellingActionTypeObject(searchCheckSpellingActionType);
1736    }
1737
1738    @GraphQLField
1739    @GraphQLName("searchCheckSpellingActionTypes")
1740    @GraphQLNonNull
1741    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
1742    static CountingPaginatedData<SearchCheckSpellingActionTypeObject> searchCheckSpellingActionTypes(final DataFetchingEnvironment env) {
1743        CountingPaginatedData<SearchCheckSpellingActionTypeObject> data;
1744
1745        try {
1746            var commandForm = SearchUtil.getHome().getGetSearchCheckSpellingActionTypesForm();
1747            var command = CDI.current().select(GetSearchCheckSpellingActionTypesCommand.class).get();
1748
1749            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1750            if(totalEntities == null) {
1751                data = Connections.emptyConnection();
1752            } else {
1753                try(var objectLimiter = new ObjectLimiter(env, SearchCheckSpellingActionTypeConstants.COMPONENT_VENDOR_NAME, SearchCheckSpellingActionTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
1754                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1755
1756                    var searchCheckSpellingActionTypes = entities.stream()
1757                            .map(SearchCheckSpellingActionTypeObject::new)
1758                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
1759
1760                    data = new CountedObjects<>(objectLimiter, searchCheckSpellingActionTypes);
1761                }
1762            }
1763        } catch (NamingException ex) {
1764            throw new RuntimeException(ex);
1765        }
1766
1767        return data;
1768    }
1769
1770    @GraphQLField
1771    @GraphQLName("workflow")
1772    static WorkflowObject workflow(final DataFetchingEnvironment env,
1773            @GraphQLName("workflowName") final String workflowName,
1774            @GraphQLName("id") @GraphQLID final String id) {
1775        Workflow workflow;
1776
1777        try {
1778            var commandForm = WorkflowUtil.getHome().getGetWorkflowForm();
1779
1780            commandForm.setWorkflowName(workflowName);
1781            commandForm.setUuid(id);
1782
1783            workflow = CDI.current().select(GetWorkflowCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
1784        } catch (NamingException ex) {
1785            throw new RuntimeException(ex);
1786        }
1787
1788        return workflow == null ? null : new WorkflowObject(workflow);
1789    }
1790
1791    @GraphQLField
1792    @GraphQLName("workflows")
1793    @GraphQLNonNull
1794    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
1795    static CountingPaginatedData<WorkflowObject> workflows(final DataFetchingEnvironment env,
1796            @GraphQLName("selectorKindName") final String selectorKindName) {
1797        CountingPaginatedData<WorkflowObject> data;
1798
1799        try {
1800            var commandForm = WorkflowUtil.getHome().getGetWorkflowsForm();
1801            var command = CDI.current().select(GetWorkflowsCommand.class).get();
1802
1803            commandForm.setSelectorKindName(selectorKindName);
1804
1805            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1806            if(totalEntities == null) {
1807                data = Connections.emptyConnection();
1808            } else {
1809                try(var objectLimiter = new ObjectLimiter(env, WorkflowConstants.COMPONENT_VENDOR_NAME, WorkflowConstants.ENTITY_TYPE_NAME, totalEntities)) {
1810                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1811
1812                    var workflows = entities.stream()
1813                            .map(WorkflowObject::new)
1814                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
1815
1816                    data = new CountedObjects<>(objectLimiter, workflows);
1817                }
1818            }
1819        } catch (NamingException ex) {
1820            throw new RuntimeException(ex);
1821        }
1822
1823        return data;
1824    }
1825    
1826    @GraphQLField
1827    @GraphQLName("workflowEntityType")
1828    static WorkflowEntityTypeObject workflowEntityType(final DataFetchingEnvironment env,
1829            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
1830            @GraphQLName("componentVendorName") @GraphQLNonNull final String componentVendorName,
1831            @GraphQLName("entityTypeName") @GraphQLNonNull final String entityTypeName) {
1832        WorkflowEntityType workflowEntityType;
1833
1834        try {
1835            var commandForm = WorkflowUtil.getHome().getGetWorkflowEntityTypeForm();
1836
1837            commandForm.setWorkflowName(workflowName);
1838            commandForm.setComponentVendorName(componentVendorName);
1839            commandForm.setEntityTypeName(entityTypeName);
1840
1841            workflowEntityType = CDI.current().select(GetWorkflowEntityTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
1842        } catch (NamingException ex) {
1843            throw new RuntimeException(ex);
1844        }
1845
1846        return workflowEntityType == null ? null : new WorkflowEntityTypeObject(workflowEntityType);
1847    }
1848
1849    @GraphQLField
1850    @GraphQLName("workflowEntityTypes")
1851    @GraphQLNonNull
1852    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
1853    static CountingPaginatedData<WorkflowEntityTypeObject> workflowEntityTypes(final DataFetchingEnvironment env,
1854            @GraphQLName("workflowName") final String workflowName,
1855            @GraphQLName("componentVendorName") final String componentVendorName,
1856            @GraphQLName("entityTypeName") final String entityTypeName) {
1857        CountingPaginatedData<WorkflowEntityTypeObject> data;
1858
1859        try {
1860            var commandForm = WorkflowUtil.getHome().getGetWorkflowEntityTypesForm();
1861            var command = CDI.current().select(GetWorkflowEntityTypesCommand.class).get();
1862
1863            commandForm.setWorkflowName(workflowName);
1864            commandForm.setComponentVendorName(componentVendorName);
1865            commandForm.setEntityTypeName(entityTypeName);
1866
1867            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1868            if(totalEntities == null) {
1869                data = Connections.emptyConnection();
1870            } else {
1871                try(var objectLimiter = new ObjectLimiter(env, WorkflowEntityTypeConstants.COMPONENT_VENDOR_NAME, WorkflowEntityTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
1872                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1873
1874                    var workflowEntityTypes = entities.stream()
1875                            .map(WorkflowEntityTypeObject::new)
1876                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
1877
1878                    data = new CountedObjects<>(objectLimiter, workflowEntityTypes);
1879                }
1880            }
1881        } catch (NamingException ex) {
1882            throw new RuntimeException(ex);
1883        }
1884
1885        return data;
1886    }
1887
1888    @GraphQLField
1889    @GraphQLName("workflowSelectorKind")
1890    static WorkflowSelectorKindObject workflowSelectorKind(final DataFetchingEnvironment env,
1891            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
1892            @GraphQLName("selectorKindName") @GraphQLNonNull final String selectorKindName) {
1893        WorkflowSelectorKind workflowSelectorKind;
1894
1895        try {
1896            var commandForm = WorkflowUtil.getHome().getGetWorkflowSelectorKindForm();
1897
1898            commandForm.setWorkflowName(workflowName);
1899            commandForm.setSelectorKindName(selectorKindName);
1900
1901            workflowSelectorKind = CDI.current().select(GetWorkflowSelectorKindCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
1902        } catch (NamingException ex) {
1903            throw new RuntimeException(ex);
1904        }
1905
1906        return workflowSelectorKind == null ? null : new WorkflowSelectorKindObject(workflowSelectorKind);
1907    }
1908
1909    @GraphQLField
1910    @GraphQLName("workflowSelectorKinds")
1911    @GraphQLNonNull
1912    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
1913    static CountingPaginatedData<WorkflowSelectorKindObject> workflowSelectorKinds(final DataFetchingEnvironment env,
1914            @GraphQLName("workflowName") final String workflowName,
1915            @GraphQLName("selectorKindName") final String selectorKindName) {
1916        CountingPaginatedData<WorkflowSelectorKindObject> data;
1917
1918        try {
1919            var commandForm = WorkflowUtil.getHome().getGetWorkflowSelectorKindsForm();
1920            var command = CDI.current().select(GetWorkflowSelectorKindsCommand.class).get();
1921
1922            commandForm.setWorkflowName(workflowName);
1923            commandForm.setSelectorKindName(selectorKindName);
1924
1925            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1926            if(totalEntities == null) {
1927                data = Connections.emptyConnection();
1928            } else {
1929                try(var objectLimiter = new ObjectLimiter(env, WorkflowSelectorKindConstants.COMPONENT_VENDOR_NAME, WorkflowSelectorKindConstants.ENTITY_TYPE_NAME, totalEntities)) {
1930                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1931
1932                    var workflowSelectorKinds = entities.stream()
1933                            .map(WorkflowSelectorKindObject::new)
1934                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
1935
1936                    data = new CountedObjects<>(objectLimiter, workflowSelectorKinds);
1937                }
1938            }
1939        } catch (NamingException ex) {
1940            throw new RuntimeException(ex);
1941        }
1942
1943        return data;
1944    }
1945
1946    @GraphQLField
1947    @GraphQLName("workflowEntityStatuses")
1948    @GraphQLNonNull
1949    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
1950    static CountingPaginatedData<WorkflowEntityStatusObject> workflowEntityStatuses(final DataFetchingEnvironment env,
1951            @GraphQLName("workflowName") final String workflowName) {
1952        CountingPaginatedData<WorkflowEntityStatusObject> data;
1953
1954        try {
1955            var commandForm = WorkflowUtil.getHome().getGetWorkflowEntityStatusesForm();
1956            var command = CDI.current().select(GetWorkflowEntityStatusesCommand.class).get();
1957
1958            commandForm.setWorkflowName(workflowName);
1959
1960            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1961            if(totalEntities == null) {
1962                data = Connections.emptyConnection();
1963            } else {
1964                try(var objectLimiter = new ObjectLimiter(env, WorkflowEntityStatusConstants.COMPONENT_VENDOR_NAME, WorkflowEntityStatusConstants.ENTITY_TYPE_NAME, totalEntities)) {
1965                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
1966
1967                    var workflowEntityStatuses = entities.stream()
1968                            .map(WorkflowEntityStatusObject::new)
1969                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
1970
1971                    data = new CountedObjects<>(objectLimiter, workflowEntityStatuses);
1972                }
1973            }
1974        } catch (NamingException ex) {
1975            throw new RuntimeException(ex);
1976        }
1977
1978        return data;
1979    }
1980
1981    @GraphQLField
1982    @GraphQLName("workflowStep")
1983    static WorkflowStepObject workflowStep(final DataFetchingEnvironment env,
1984            @GraphQLName("workflowName") final String workflowName,
1985            @GraphQLName("workflowStepName") final String workflowStepName,
1986            @GraphQLName("id") @GraphQLID final String id) {
1987        WorkflowStep workflowStep;
1988
1989        try {
1990            var commandForm = WorkflowUtil.getHome().getGetWorkflowStepForm();
1991
1992            commandForm.setWorkflowName(workflowName);
1993            commandForm.setWorkflowStepName(workflowStepName);
1994            commandForm.setUuid(id);
1995
1996            workflowStep = CDI.current().select(GetWorkflowStepCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
1997        } catch (NamingException ex) {
1998            throw new RuntimeException(ex);
1999        }
2000
2001        return workflowStep == null ? null : new WorkflowStepObject(workflowStep);
2002    }
2003
2004    @GraphQLField
2005    @GraphQLName("workflowSteps")
2006    @GraphQLNonNull
2007    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
2008    static CountingPaginatedData<WorkflowStepObject> workflowSteps(final DataFetchingEnvironment env,
2009            @GraphQLName("workflowName") final String workflowName) {
2010        CountingPaginatedData<WorkflowStepObject> data;
2011
2012        try {
2013            var commandForm = WorkflowUtil.getHome().getGetWorkflowStepsForm();
2014            var command = CDI.current().select(GetWorkflowStepsCommand.class).get();
2015
2016            commandForm.setWorkflowName(workflowName);
2017
2018            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2019            if(totalEntities == null) {
2020                data = Connections.emptyConnection();
2021            } else {
2022                try(var objectLimiter = new ObjectLimiter(env, WorkflowStepConstants.COMPONENT_VENDOR_NAME, WorkflowStepConstants.ENTITY_TYPE_NAME, totalEntities)) {
2023                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2024
2025                    var workflowSteps = entities.stream()
2026                            .map(WorkflowStepObject::new)
2027                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
2028
2029                    data = new CountedObjects<>(objectLimiter, workflowSteps);
2030                }
2031            }
2032        } catch (NamingException ex) {
2033            throw new RuntimeException(ex);
2034        }
2035
2036        return data;
2037    }
2038    
2039    @GraphQLField
2040    @GraphQLName("workflowDestination")
2041    static WorkflowDestinationObject workflowDestination(final DataFetchingEnvironment env,
2042            @GraphQLName("workflowName") final String workflowName,
2043            @GraphQLName("workflowStepName") final String workflowStepName,
2044            @GraphQLName("workflowDestinationName") final String workflowDestinationName,
2045            @GraphQLName("id") @GraphQLID final String id) {
2046        WorkflowDestination workflowDestination;
2047
2048        try {
2049            var commandForm = WorkflowUtil.getHome().getGetWorkflowDestinationForm();
2050
2051            commandForm.setWorkflowName(workflowName);
2052            commandForm.setWorkflowStepName(workflowStepName);
2053            commandForm.setWorkflowDestinationName(workflowDestinationName);
2054            commandForm.setUuid(id);
2055
2056            workflowDestination = CDI.current().select(GetWorkflowDestinationCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
2057        } catch (NamingException ex) {
2058            throw new RuntimeException(ex);
2059        }
2060
2061        return workflowDestination == null ? null : new WorkflowDestinationObject(workflowDestination);
2062    }
2063
2064    @GraphQLField
2065    @GraphQLName("workflowDestinations")
2066    @GraphQLNonNull
2067    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
2068    static CountingPaginatedData<WorkflowDestinationObject> workflowDestinations(final DataFetchingEnvironment env,
2069            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
2070            @GraphQLName("workflowStepName") @GraphQLNonNull final String workflowStepName) {
2071        CountingPaginatedData<WorkflowDestinationObject> data;
2072
2073        try {
2074            var commandForm = WorkflowUtil.getHome().getGetWorkflowDestinationsForm();
2075            var command = CDI.current().select(GetWorkflowDestinationsCommand.class).get();
2076
2077            commandForm.setWorkflowName(workflowName);
2078            commandForm.setWorkflowStepName(workflowStepName);
2079
2080            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2081            if(totalEntities == null) {
2082                data = Connections.emptyConnection();
2083            } else {
2084                try(var objectLimiter = new ObjectLimiter(env, WorkflowDestinationConstants.COMPONENT_VENDOR_NAME, WorkflowDestinationConstants.ENTITY_TYPE_NAME, totalEntities)) {
2085                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2086
2087                    var workflowDestinations = entities.stream()
2088                            .map(WorkflowDestinationObject::new)
2089                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
2090
2091                    data = new CountedObjects<>(objectLimiter, workflowDestinations);
2092                }
2093            }
2094        } catch (NamingException ex) {
2095            throw new RuntimeException(ex);
2096        }
2097
2098        return data;
2099    }
2100
2101    @GraphQLField
2102    @GraphQLName("workflowDestinationStep")
2103    static WorkflowDestinationStepObject workflowDestinationStep(final DataFetchingEnvironment env,
2104            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
2105            @GraphQLName("workflowStepName") @GraphQLNonNull final String workflowStepName,
2106            @GraphQLName("workflowDestinationName") @GraphQLNonNull final String workflowDestinationName,
2107            @GraphQLName("destinationWorkflowName") @GraphQLNonNull final String destinationWorkflowName,
2108            @GraphQLName("destinationWorkflowStepName") @GraphQLNonNull final String destinationWorkflowStepName) {
2109        WorkflowDestinationStep workflowDestinationStep;
2110
2111        try {
2112            var commandForm = WorkflowUtil.getHome().getGetWorkflowDestinationStepForm();
2113
2114            commandForm.setWorkflowName(workflowName);
2115            commandForm.setWorkflowStepName(workflowStepName);
2116            commandForm.setWorkflowDestinationName(workflowDestinationName);
2117            commandForm.setDestinationWorkflowName(destinationWorkflowName);
2118            commandForm.setDestinationWorkflowStepName(destinationWorkflowStepName);
2119
2120            workflowDestinationStep = CDI.current().select(GetWorkflowDestinationStepCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
2121        } catch (NamingException ex) {
2122            throw new RuntimeException(ex);
2123        }
2124
2125        return workflowDestinationStep == null ? null : new WorkflowDestinationStepObject(workflowDestinationStep);
2126    }
2127
2128    @GraphQLField
2129    @GraphQLName("workflowDestinationSteps")
2130    @GraphQLNonNull
2131    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
2132    static CountingPaginatedData<WorkflowDestinationStepObject> workflowDestinationSteps(final DataFetchingEnvironment env,
2133            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
2134            @GraphQLName("workflowStepName") @GraphQLNonNull final String workflowStepName,
2135            @GraphQLName("workflowDestinationName") @GraphQLNonNull final String workflowDestinationName) {
2136        CountingPaginatedData<WorkflowDestinationStepObject> data;
2137
2138        try {
2139            var commandForm = WorkflowUtil.getHome().getGetWorkflowDestinationStepsForm();
2140            var command = CDI.current().select(GetWorkflowDestinationStepsCommand.class).get();
2141
2142            commandForm.setWorkflowName(workflowName);
2143            commandForm.setWorkflowStepName(workflowStepName);
2144            commandForm.setWorkflowDestinationName(workflowDestinationName);
2145
2146            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2147            if(totalEntities == null) {
2148                data = Connections.emptyConnection();
2149            } else {
2150                try(var objectLimiter = new ObjectLimiter(env, WorkflowDestinationStepConstants.COMPONENT_VENDOR_NAME, WorkflowDestinationStepConstants.ENTITY_TYPE_NAME, totalEntities)) {
2151                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2152
2153                    var workflowDestinationSteps = entities.stream()
2154                            .map(WorkflowDestinationStepObject::new)
2155                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
2156
2157                    data = new CountedObjects<>(objectLimiter, workflowDestinationSteps);
2158                }
2159            }
2160        } catch (NamingException ex) {
2161            throw new RuntimeException(ex);
2162        }
2163
2164        return data;
2165    }
2166
2167    @GraphQLField
2168    @GraphQLName("workflowDestinationPartyType")
2169    static WorkflowDestinationPartyTypeObject workflowDestinationPartyType(final DataFetchingEnvironment env,
2170            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
2171            @GraphQLName("workflowStepName") @GraphQLNonNull final String workflowStepName,
2172            @GraphQLName("workflowDestinationName") @GraphQLNonNull final String workflowDestinationName,
2173            @GraphQLName("partyTypeName") @GraphQLNonNull final String partyTypeName) {
2174        WorkflowDestinationPartyType workflowDestinationPartyType;
2175
2176        try {
2177            var commandForm = WorkflowUtil.getHome().getGetWorkflowDestinationPartyTypeForm();
2178
2179            commandForm.setWorkflowName(workflowName);
2180            commandForm.setWorkflowStepName(workflowStepName);
2181            commandForm.setWorkflowDestinationName(workflowDestinationName);
2182            commandForm.setPartyTypeName(partyTypeName);
2183
2184            workflowDestinationPartyType = CDI.current().select(GetWorkflowDestinationPartyTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
2185        } catch (NamingException ex) {
2186            throw new RuntimeException(ex);
2187        }
2188
2189        return workflowDestinationPartyType == null ? null : new WorkflowDestinationPartyTypeObject(workflowDestinationPartyType);
2190    }
2191
2192    @GraphQLField
2193    @GraphQLName("workflowDestinationPartyTypes")
2194    @GraphQLNonNull
2195    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
2196    static CountingPaginatedData<WorkflowDestinationPartyTypeObject> workflowDestinationPartyTypes(final DataFetchingEnvironment env,
2197            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
2198            @GraphQLName("workflowStepName") @GraphQLNonNull final String workflowStepName,
2199            @GraphQLName("workflowDestinationName") @GraphQLNonNull final String workflowDestinationName) {
2200        CountingPaginatedData<WorkflowDestinationPartyTypeObject> data;
2201
2202        try {
2203            var commandForm = WorkflowUtil.getHome().getGetWorkflowDestinationPartyTypesForm();
2204            var command = CDI.current().select(GetWorkflowDestinationPartyTypesCommand.class).get();
2205
2206            commandForm.setWorkflowName(workflowName);
2207            commandForm.setWorkflowStepName(workflowStepName);
2208            commandForm.setWorkflowDestinationName(workflowDestinationName);
2209
2210            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2211            if(totalEntities == null) {
2212                data = Connections.emptyConnection();
2213            } else {
2214                try(var objectLimiter = new ObjectLimiter(env, WorkflowDestinationPartyTypeConstants.COMPONENT_VENDOR_NAME, WorkflowDestinationPartyTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
2215                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2216
2217                    var workflowDestinationPartyTypes = entities.stream()
2218                            .map(WorkflowDestinationPartyTypeObject::new)
2219                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
2220
2221                    data = new CountedObjects<>(objectLimiter, workflowDestinationPartyTypes);
2222                }
2223            }
2224        } catch (NamingException ex) {
2225            throw new RuntimeException(ex);
2226        }
2227
2228        return data;
2229    }
2230
2231    @GraphQLField
2232    @GraphQLName("workflowDestinationSecurityRole")
2233    static WorkflowDestinationSecurityRoleObject workflowDestinationSecurityRole(final DataFetchingEnvironment env,
2234            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
2235            @GraphQLName("workflowStepName") @GraphQLNonNull final String workflowStepName,
2236            @GraphQLName("workflowDestinationName") @GraphQLNonNull final String workflowDestinationName,
2237            @GraphQLName("partyTypeName") @GraphQLNonNull final String partyTypeName,
2238            @GraphQLName("securityRoleName") @GraphQLNonNull final String securityRoleName) {
2239        WorkflowDestinationSecurityRole workflowDestinationSecurityRole;
2240
2241        try {
2242            var commandForm = WorkflowUtil.getHome().getGetWorkflowDestinationSecurityRoleForm();
2243
2244            commandForm.setWorkflowName(workflowName);
2245            commandForm.setWorkflowStepName(workflowStepName);
2246            commandForm.setWorkflowDestinationName(workflowDestinationName);
2247            commandForm.setPartyTypeName(partyTypeName);
2248            commandForm.setSecurityRoleName(securityRoleName);
2249
2250            workflowDestinationSecurityRole = CDI.current().select(GetWorkflowDestinationSecurityRoleCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
2251        } catch (NamingException ex) {
2252            throw new RuntimeException(ex);
2253        }
2254
2255        return workflowDestinationSecurityRole == null ? null : new WorkflowDestinationSecurityRoleObject(workflowDestinationSecurityRole);
2256    }
2257
2258    @GraphQLField
2259    @GraphQLName("workflowDestinationSecurityRoles")
2260    @GraphQLNonNull
2261    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
2262    static CountingPaginatedData<WorkflowDestinationSecurityRoleObject> workflowDestinationSecurityRoles(final DataFetchingEnvironment env,
2263            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
2264            @GraphQLName("workflowStepName") @GraphQLNonNull final String workflowStepName,
2265            @GraphQLName("workflowDestinationName") @GraphQLNonNull final String workflowDestinationName,
2266            @GraphQLName("partyTypeName") @GraphQLNonNull final String partyTypeName) {
2267        CountingPaginatedData<WorkflowDestinationSecurityRoleObject> data;
2268
2269        try {
2270            var commandForm = WorkflowUtil.getHome().getGetWorkflowDestinationSecurityRolesForm();
2271            var command = CDI.current().select(GetWorkflowDestinationSecurityRolesCommand.class).get();
2272
2273            commandForm.setWorkflowName(workflowName);
2274            commandForm.setWorkflowStepName(workflowStepName);
2275            commandForm.setWorkflowDestinationName(workflowDestinationName);
2276            commandForm.setPartyTypeName(partyTypeName);
2277
2278            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2279            if(totalEntities == null) {
2280                data = Connections.emptyConnection();
2281            } else {
2282                try(var objectLimiter = new ObjectLimiter(env, WorkflowDestinationSecurityRoleConstants.COMPONENT_VENDOR_NAME, WorkflowDestinationSecurityRoleConstants.ENTITY_TYPE_NAME, totalEntities)) {
2283                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2284
2285                    var workflowDestinationSecurityRoles = entities.stream()
2286                            .map(WorkflowDestinationSecurityRoleObject::new)
2287                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
2288
2289                    data = new CountedObjects<>(objectLimiter, workflowDestinationSecurityRoles);
2290                }
2291            }
2292        } catch (NamingException ex) {
2293            throw new RuntimeException(ex);
2294        }
2295
2296        return data;
2297    }
2298
2299    @GraphQLField
2300    @GraphQLName("workflowDestinationSelector")
2301    static WorkflowDestinationSelectorObject workflowDestinationSelector(final DataFetchingEnvironment env,
2302            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
2303            @GraphQLName("workflowStepName") @GraphQLNonNull final String workflowStepName,
2304            @GraphQLName("workflowDestinationName") @GraphQLNonNull final String workflowDestinationName,
2305            @GraphQLName("selectorName") @GraphQLNonNull final String selectorName) {
2306        WorkflowDestinationSelector workflowDestinationSelector;
2307
2308        try {
2309            var commandForm = WorkflowUtil.getHome().getGetWorkflowDestinationSelectorForm();
2310
2311            commandForm.setWorkflowName(workflowName);
2312            commandForm.setWorkflowStepName(workflowStepName);
2313            commandForm.setWorkflowDestinationName(workflowDestinationName);
2314            commandForm.setSelectorName(selectorName);
2315
2316            workflowDestinationSelector = CDI.current().select(GetWorkflowDestinationSelectorCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
2317        } catch (NamingException ex) {
2318            throw new RuntimeException(ex);
2319        }
2320
2321        return workflowDestinationSelector == null ? null : new WorkflowDestinationSelectorObject(workflowDestinationSelector);
2322    }
2323
2324    @GraphQLField
2325    @GraphQLName("workflowDestinationSelectors")
2326    @GraphQLNonNull
2327    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
2328    static CountingPaginatedData<WorkflowDestinationSelectorObject> workflowDestinationSelectors(final DataFetchingEnvironment env,
2329            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
2330            @GraphQLName("workflowStepName") @GraphQLNonNull final String workflowStepName,
2331            @GraphQLName("workflowDestinationName") @GraphQLNonNull final String workflowDestinationName) {
2332        CountingPaginatedData<WorkflowDestinationSelectorObject> data;
2333
2334        try {
2335            var commandForm = WorkflowUtil.getHome().getGetWorkflowDestinationSelectorsForm();
2336            var command = CDI.current().select(GetWorkflowDestinationSelectorsCommand.class).get();
2337
2338            commandForm.setWorkflowName(workflowName);
2339            commandForm.setWorkflowStepName(workflowStepName);
2340            commandForm.setWorkflowDestinationName(workflowDestinationName);
2341
2342            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2343            if(totalEntities == null) {
2344                data = Connections.emptyConnection();
2345            } else {
2346                try(var objectLimiter = new ObjectLimiter(env, WorkflowDestinationSelectorConstants.COMPONENT_VENDOR_NAME, WorkflowDestinationSelectorConstants.ENTITY_TYPE_NAME, totalEntities)) {
2347                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2348
2349                    var workflowDestinationSelectors = entities.stream()
2350                            .map(WorkflowDestinationSelectorObject::new)
2351                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
2352
2353                    data = new CountedObjects<>(objectLimiter, workflowDestinationSelectors);
2354                }
2355            }
2356        } catch (NamingException ex) {
2357            throw new RuntimeException(ex);
2358        }
2359
2360        return data;
2361    }
2362
2363    @GraphQLField
2364    @GraphQLName("workflowEntrance")
2365    static WorkflowEntranceObject workflowEntrance(final DataFetchingEnvironment env,
2366            @GraphQLName("workflowName") final String workflowName,
2367            @GraphQLName("workflowEntranceName") final String workflowEntranceName,
2368            @GraphQLName("id") @GraphQLID final String id) {
2369        WorkflowEntrance workflowEntrance;
2370
2371        try {
2372            var commandForm = WorkflowUtil.getHome().getGetWorkflowEntranceForm();
2373
2374            commandForm.setWorkflowName(workflowName);
2375            commandForm.setWorkflowEntranceName(workflowEntranceName);
2376            commandForm.setUuid(id);
2377
2378            workflowEntrance = CDI.current().select(GetWorkflowEntranceCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
2379        } catch (NamingException ex) {
2380            throw new RuntimeException(ex);
2381        }
2382
2383        return workflowEntrance == null ? null : new WorkflowEntranceObject(workflowEntrance);
2384    }
2385
2386    @GraphQLField
2387    @GraphQLName("workflowEntrances")
2388    @GraphQLNonNull
2389    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
2390    static CountingPaginatedData<WorkflowEntranceObject> workflowEntrances(final DataFetchingEnvironment env,
2391            @GraphQLName("workflowName") final String workflowName) {
2392        CountingPaginatedData<WorkflowEntranceObject> data;
2393
2394        try {
2395            var commandForm = WorkflowUtil.getHome().getGetWorkflowEntrancesForm();
2396            var command = CDI.current().select(GetWorkflowEntrancesCommand.class).get();
2397
2398            commandForm.setWorkflowName(workflowName);
2399
2400            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2401            if(totalEntities == null) {
2402                data = Connections.emptyConnection();
2403            } else {
2404                try(var objectLimiter = new ObjectLimiter(env, WorkflowEntranceConstants.COMPONENT_VENDOR_NAME, WorkflowEntranceConstants.ENTITY_TYPE_NAME, totalEntities)) {
2405                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2406
2407                    var workflowEntrances = entities.stream()
2408                            .map(WorkflowEntranceObject::new)
2409                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
2410
2411                    data = new CountedObjects<>(objectLimiter, workflowEntrances);
2412                }
2413            }
2414        } catch (NamingException ex) {
2415            throw new RuntimeException(ex);
2416        }
2417
2418        return data;
2419    }
2420
2421    @GraphQLField
2422    @GraphQLName("workflowEntranceStep")
2423    static WorkflowEntranceStepObject workflowEntranceStep(final DataFetchingEnvironment env,
2424            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
2425            @GraphQLName("workflowEntranceName") @GraphQLNonNull final String workflowEntranceName,
2426            @GraphQLName("entranceWorkflowName") @GraphQLNonNull final String entranceWorkflowName,
2427            @GraphQLName("entranceWorkflowStepName") @GraphQLNonNull final String entranceWorkflowStepName) {
2428        WorkflowEntranceStep workflowEntranceStep;
2429
2430        try {
2431            var commandForm = WorkflowUtil.getHome().getGetWorkflowEntranceStepForm();
2432
2433            commandForm.setWorkflowName(workflowName);
2434            commandForm.setWorkflowEntranceName(workflowEntranceName);
2435            commandForm.setEntranceWorkflowName(entranceWorkflowName);
2436            commandForm.setEntranceWorkflowStepName(entranceWorkflowStepName);
2437
2438            workflowEntranceStep = CDI.current().select(GetWorkflowEntranceStepCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
2439        } catch (NamingException ex) {
2440            throw new RuntimeException(ex);
2441        }
2442
2443        return workflowEntranceStep == null ? null : new WorkflowEntranceStepObject(workflowEntranceStep);
2444    }
2445
2446    @GraphQLField
2447    @GraphQLName("workflowEntranceSteps")
2448    @GraphQLNonNull
2449    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
2450    static CountingPaginatedData<WorkflowEntranceStepObject> workflowEntranceSteps(final DataFetchingEnvironment env,
2451            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
2452            @GraphQLName("workflowEntranceName") @GraphQLNonNull final String workflowEntranceName) {
2453        CountingPaginatedData<WorkflowEntranceStepObject> data;
2454
2455        try {
2456            var commandForm = WorkflowUtil.getHome().getGetWorkflowEntranceStepsForm();
2457            var command = CDI.current().select(GetWorkflowEntranceStepsCommand.class).get();
2458
2459            commandForm.setWorkflowName(workflowName);
2460            commandForm.setWorkflowEntranceName(workflowEntranceName);
2461
2462            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2463            if(totalEntities == null) {
2464                data = Connections.emptyConnection();
2465            } else {
2466                try(var objectLimiter = new ObjectLimiter(env, WorkflowEntranceStepConstants.COMPONENT_VENDOR_NAME, WorkflowEntranceStepConstants.ENTITY_TYPE_NAME, totalEntities)) {
2467                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2468
2469                    var workflowEntranceSteps = entities.stream()
2470                            .map(WorkflowEntranceStepObject::new)
2471                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
2472
2473                    data = new CountedObjects<>(objectLimiter, workflowEntranceSteps);
2474                }
2475            }
2476        } catch (NamingException ex) {
2477            throw new RuntimeException(ex);
2478        }
2479
2480        return data;
2481    }
2482
2483    @GraphQLField
2484    @GraphQLName("workflowEntrancePartyType")
2485    static WorkflowEntrancePartyTypeObject workflowEntrancePartyType(final DataFetchingEnvironment env,
2486            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
2487            @GraphQLName("workflowEntranceName") @GraphQLNonNull final String workflowEntranceName,
2488            @GraphQLName("partyTypeName") @GraphQLNonNull final String partyTypeName) {
2489        WorkflowEntrancePartyType workflowEntrancePartyType;
2490
2491        try {
2492            var commandForm = WorkflowUtil.getHome().getGetWorkflowEntrancePartyTypeForm();
2493
2494            commandForm.setWorkflowName(workflowName);
2495            commandForm.setWorkflowEntranceName(workflowEntranceName);
2496            commandForm.setPartyTypeName(partyTypeName);
2497
2498            workflowEntrancePartyType = CDI.current().select(GetWorkflowEntrancePartyTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
2499        } catch (NamingException ex) {
2500            throw new RuntimeException(ex);
2501        }
2502
2503        return workflowEntrancePartyType == null ? null : new WorkflowEntrancePartyTypeObject(workflowEntrancePartyType);
2504    }
2505
2506    @GraphQLField
2507    @GraphQLName("workflowEntrancePartyTypes")
2508    @GraphQLNonNull
2509    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
2510    static CountingPaginatedData<WorkflowEntrancePartyTypeObject> workflowEntrancePartyTypes(final DataFetchingEnvironment env,
2511            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
2512            @GraphQLName("workflowEntranceName") @GraphQLNonNull final String workflowEntranceName) {
2513        CountingPaginatedData<WorkflowEntrancePartyTypeObject> data;
2514
2515        try {
2516            var commandForm = WorkflowUtil.getHome().getGetWorkflowEntrancePartyTypesForm();
2517            var command = CDI.current().select(GetWorkflowEntrancePartyTypesCommand.class).get();
2518
2519            commandForm.setWorkflowName(workflowName);
2520            commandForm.setWorkflowEntranceName(workflowEntranceName);
2521
2522            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2523            if(totalEntities == null) {
2524                data = Connections.emptyConnection();
2525            } else {
2526                try(var objectLimiter = new ObjectLimiter(env, WorkflowEntrancePartyTypeConstants.COMPONENT_VENDOR_NAME, WorkflowEntrancePartyTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
2527                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2528
2529                    var workflowEntrancePartyTypes = entities.stream()
2530                            .map(WorkflowEntrancePartyTypeObject::new)
2531                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
2532
2533                    data = new CountedObjects<>(objectLimiter, workflowEntrancePartyTypes);
2534                }
2535            }
2536        } catch (NamingException ex) {
2537            throw new RuntimeException(ex);
2538        }
2539
2540        return data;
2541    }
2542
2543    @GraphQLField
2544    @GraphQLName("workflowEntranceSecurityRole")
2545    static WorkflowEntranceSecurityRoleObject workflowEntranceSecurityRole(final DataFetchingEnvironment env,
2546            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
2547            @GraphQLName("workflowEntranceName") @GraphQLNonNull final String workflowEntranceName,
2548            @GraphQLName("partyTypeName") @GraphQLNonNull final String partyTypeName,
2549            @GraphQLName("securityRoleName") @GraphQLNonNull final String securityRoleName) {
2550        WorkflowEntranceSecurityRole workflowEntranceSecurityRole;
2551
2552        try {
2553            var commandForm = WorkflowUtil.getHome().getGetWorkflowEntranceSecurityRoleForm();
2554
2555            commandForm.setWorkflowName(workflowName);
2556            commandForm.setWorkflowEntranceName(workflowEntranceName);
2557            commandForm.setPartyTypeName(partyTypeName);
2558            commandForm.setSecurityRoleName(securityRoleName);
2559
2560            workflowEntranceSecurityRole = CDI.current().select(GetWorkflowEntranceSecurityRoleCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
2561        } catch (NamingException ex) {
2562            throw new RuntimeException(ex);
2563        }
2564
2565        return workflowEntranceSecurityRole == null ? null : new WorkflowEntranceSecurityRoleObject(workflowEntranceSecurityRole);
2566    }
2567
2568    @GraphQLField
2569    @GraphQLName("workflowEntranceSecurityRoles")
2570    @GraphQLNonNull
2571    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
2572    static CountingPaginatedData<WorkflowEntranceSecurityRoleObject> workflowEntranceSecurityRoles(final DataFetchingEnvironment env,
2573            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
2574            @GraphQLName("workflowEntranceName") @GraphQLNonNull final String workflowEntranceName,
2575            @GraphQLName("partyTypeName") @GraphQLNonNull final String partyTypeName) {
2576        CountingPaginatedData<WorkflowEntranceSecurityRoleObject> data;
2577
2578        try {
2579            var commandForm = WorkflowUtil.getHome().getGetWorkflowEntranceSecurityRolesForm();
2580            var command = CDI.current().select(GetWorkflowEntranceSecurityRolesCommand.class).get();
2581
2582            commandForm.setWorkflowName(workflowName);
2583            commandForm.setWorkflowEntranceName(workflowEntranceName);
2584            commandForm.setPartyTypeName(partyTypeName);
2585
2586            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2587            if(totalEntities == null) {
2588                data = Connections.emptyConnection();
2589            } else {
2590                try(var objectLimiter = new ObjectLimiter(env, WorkflowEntranceSecurityRoleConstants.COMPONENT_VENDOR_NAME, WorkflowEntranceSecurityRoleConstants.ENTITY_TYPE_NAME, totalEntities)) {
2591                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2592
2593                    var workflowEntranceSecurityRoles = entities.stream()
2594                            .map(WorkflowEntranceSecurityRoleObject::new)
2595                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
2596
2597                    data = new CountedObjects<>(objectLimiter, workflowEntranceSecurityRoles);
2598                }
2599            }
2600        } catch (NamingException ex) {
2601            throw new RuntimeException(ex);
2602        }
2603
2604        return data;
2605    }
2606
2607    @GraphQLField
2608    @GraphQLName("workflowEntranceSelector")
2609    static WorkflowEntranceSelectorObject workflowEntranceSelector(final DataFetchingEnvironment env,
2610            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
2611            @GraphQLName("workflowEntranceName") @GraphQLNonNull final String workflowEntranceName,
2612            @GraphQLName("selectorName") @GraphQLNonNull final String selectorName) {
2613        WorkflowEntranceSelector workflowEntranceSelector;
2614
2615        try {
2616            var commandForm = WorkflowUtil.getHome().getGetWorkflowEntranceSelectorForm();
2617
2618            commandForm.setWorkflowName(workflowName);
2619            commandForm.setWorkflowEntranceName(workflowEntranceName);
2620            commandForm.setSelectorName(selectorName);
2621
2622            workflowEntranceSelector = CDI.current().select(GetWorkflowEntranceSelectorCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
2623        } catch (NamingException ex) {
2624            throw new RuntimeException(ex);
2625        }
2626
2627        return workflowEntranceSelector == null ? null : new WorkflowEntranceSelectorObject(workflowEntranceSelector);
2628    }
2629
2630    @GraphQLField
2631    @GraphQLName("workflowEntranceSelectors")
2632    @GraphQLNonNull
2633    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
2634    static CountingPaginatedData<WorkflowEntranceSelectorObject> workflowEntranceSelectors(final DataFetchingEnvironment env,
2635            @GraphQLName("workflowName") @GraphQLNonNull final String workflowName,
2636            @GraphQLName("workflowEntranceName") @GraphQLNonNull final String workflowEntranceName) {
2637        CountingPaginatedData<WorkflowEntranceSelectorObject> data;
2638
2639        try {
2640            var commandForm = WorkflowUtil.getHome().getGetWorkflowEntranceSelectorsForm();
2641            var command = CDI.current().select(GetWorkflowEntranceSelectorsCommand.class).get();
2642
2643            commandForm.setWorkflowName(workflowName);
2644            commandForm.setWorkflowEntranceName(workflowEntranceName);
2645
2646            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2647            if(totalEntities == null) {
2648                data = Connections.emptyConnection();
2649            } else {
2650                try(var objectLimiter = new ObjectLimiter(env, WorkflowEntranceSelectorConstants.COMPONENT_VENDOR_NAME, WorkflowEntranceSelectorConstants.ENTITY_TYPE_NAME, totalEntities)) {
2651                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2652
2653                    var workflowEntranceSelectors = entities.stream()
2654                            .map(WorkflowEntranceSelectorObject::new)
2655                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
2656
2657                    data = new CountedObjects<>(objectLimiter, workflowEntranceSelectors);
2658                }
2659            }
2660        } catch (NamingException ex) {
2661            throw new RuntimeException(ex);
2662        }
2663
2664        return data;
2665    }
2666
2667    @GraphQLField
2668    @GraphQLName("workflowStepType")
2669    static WorkflowStepTypeObject workflowStepType(final DataFetchingEnvironment env,
2670            @GraphQLName("workflowStepTypeName") final String workflowStepTypeName,
2671            @GraphQLName("id") @GraphQLID final String id) {
2672        WorkflowStepType workflowStepType;
2673
2674        try {
2675            var commandForm = WorkflowUtil.getHome().getGetWorkflowStepTypeForm();
2676
2677            commandForm.setWorkflowStepTypeName(workflowStepTypeName);
2678            commandForm.setUuid(id);
2679
2680            workflowStepType = CDI.current().select(GetWorkflowStepTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
2681        } catch (NamingException ex) {
2682            throw new RuntimeException(ex);
2683        }
2684
2685        return workflowStepType == null ? null : new WorkflowStepTypeObject(workflowStepType);
2686    }
2687
2688    @GraphQLField
2689    @GraphQLName("workflowStepTypes")
2690    @GraphQLNonNull
2691    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
2692    static CountingPaginatedData<WorkflowStepTypeObject> workflowStepTypes(final DataFetchingEnvironment env) {
2693        CountingPaginatedData<WorkflowStepTypeObject> data;
2694
2695        try {
2696            var commandForm = WorkflowUtil.getHome().getGetWorkflowStepTypesForm();
2697            var command = CDI.current().select(GetWorkflowStepTypesCommand.class).get();
2698
2699            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2700            if(totalEntities == null) {
2701                data = Connections.emptyConnection();
2702            } else {
2703                try(var objectLimiter = new ObjectLimiter(env, WorkflowStepTypeConstants.COMPONENT_VENDOR_NAME, WorkflowStepTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
2704                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2705
2706                    var workflowStepTypes = entities.stream()
2707                            .map(WorkflowStepTypeObject::new)
2708                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
2709
2710                    data = new CountedObjects<>(objectLimiter, workflowStepTypes);
2711                }
2712            }
2713        } catch (NamingException ex) {
2714            throw new RuntimeException(ex);
2715        }
2716
2717        return data;
2718    }
2719
2720    @GraphQLField
2721    @GraphQLName("sequence")
2722    static SequenceObject sequence(final DataFetchingEnvironment env,
2723            @GraphQLName("sequenceTypeName") final String sequenceTypeName,
2724            @GraphQLName("sequenceName") final String sequenceName,
2725            @GraphQLName("id") @GraphQLID final String id) {
2726        Sequence sequence;
2727
2728        try {
2729            var commandForm = SequenceUtil.getHome().getGetSequenceForm();
2730
2731            commandForm.setSequenceTypeName(sequenceTypeName);
2732            commandForm.setSequenceName(sequenceName);
2733            commandForm.setUuid(id);
2734
2735            sequence = CDI.current().select(GetSequenceCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
2736        } catch (NamingException ex) {
2737            throw new RuntimeException(ex);
2738        }
2739
2740        return sequence == null ? null : new SequenceObject(sequence);
2741    }
2742
2743    @GraphQLField
2744    @GraphQLName("sequenceValue")
2745    static GetSequenceValueResultObject sequenceValue(final DataFetchingEnvironment env,
2746            @GraphQLName("sequenceTypeName") final String sequenceTypeName,
2747            @GraphQLName("sequenceName") final String sequenceName,
2748            @GraphQLName("id") @GraphQLID final String id) {
2749        GetSequenceValueResultObject result = null;
2750
2751        try {
2752            var commandForm = SequenceUtil.getHome().getGetSequenceValueForm();
2753
2754            commandForm.setSequenceTypeName(sequenceTypeName);
2755            commandForm.setSequenceName(sequenceName);
2756            commandForm.setUuid(id);
2757
2758            var commandResult = SequenceUtil.getHome().getSequenceValue(BaseGraphQl.getUserVisitPK(env), commandForm);
2759
2760            if(!commandResult.hasErrors()) {
2761                result = new GetSequenceValueResultObject(commandResult.getExecutionResult().getResult());
2762            }
2763        } catch (NamingException ex) {
2764            throw new RuntimeException(ex);
2765        }
2766
2767        return result;
2768    }
2769
2770    @GraphQLField
2771    @GraphQLName("sequences")
2772    @GraphQLNonNull
2773    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
2774    static CountingPaginatedData<SequenceObject> sequences(final DataFetchingEnvironment env,
2775            @GraphQLName("sequenceTypeName") @GraphQLNonNull final String sequenceTypeName) {
2776        CountingPaginatedData<SequenceObject> data;
2777
2778        try {
2779            var commandForm = SequenceUtil.getHome().getGetSequencesForm();
2780            var command = CDI.current().select(GetSequencesCommand.class).get();
2781
2782            commandForm.setSequenceTypeName(sequenceTypeName);
2783
2784            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2785            if(totalEntities == null) {
2786                data = Connections.emptyConnection();
2787            } else {
2788                try(var objectLimiter = new ObjectLimiter(env, SequenceConstants.COMPONENT_VENDOR_NAME, SequenceConstants.ENTITY_TYPE_NAME, totalEntities)) {
2789                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2790
2791                    var sequences = entities.stream()
2792                            .map(SequenceObject::new)
2793                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
2794
2795                    data = new CountedObjects<>(objectLimiter, sequences);
2796                }
2797            }
2798        } catch (NamingException ex) {
2799            throw new RuntimeException(ex);
2800        }
2801
2802        return data;
2803    }
2804
2805    @GraphQLField
2806    @GraphQLName("sequenceType")
2807    static SequenceTypeObject sequenceType(final DataFetchingEnvironment env,
2808            @GraphQLName("sequenceTypeName") final String sequenceTypeName,
2809            @GraphQLName("id") @GraphQLID final String id) {
2810        SequenceType sequenceType;
2811
2812        try {
2813            var commandForm = SequenceUtil.getHome().getGetSequenceTypeForm();
2814
2815            commandForm.setSequenceTypeName(sequenceTypeName);
2816            commandForm.setUuid(id);
2817
2818            sequenceType = CDI.current().select(GetSequenceTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
2819        } catch (NamingException ex) {
2820            throw new RuntimeException(ex);
2821        }
2822
2823        return sequenceType == null ? null : new SequenceTypeObject(sequenceType);
2824    }
2825
2826    @GraphQLField
2827    @GraphQLName("sequenceTypes")
2828    @GraphQLNonNull
2829    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
2830    static CountingPaginatedData<SequenceTypeObject> sequenceTypes(final DataFetchingEnvironment env) {
2831        CountingPaginatedData<SequenceTypeObject> data;
2832
2833        try {
2834            var commandForm = SequenceUtil.getHome().getGetSequenceTypesForm();
2835            var command = CDI.current().select(GetSequenceTypesCommand.class).get();
2836
2837            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2838            if(totalEntities == null) {
2839                data = Connections.emptyConnection();
2840            } else {
2841                try(var objectLimiter = new ObjectLimiter(env, SequenceTypeConstants.COMPONENT_VENDOR_NAME, SequenceTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
2842                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2843
2844                    var sequenceTypes = entities.stream()
2845                            .map(SequenceTypeObject::new)
2846                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
2847
2848                    data = new CountedObjects<>(objectLimiter, sequenceTypes);
2849                }
2850            }
2851        } catch (NamingException ex) {
2852            throw new RuntimeException(ex);
2853        }
2854
2855        return data;
2856    }
2857
2858    @GraphQLField
2859    @GraphQLName("sequenceChecksumType")
2860    static SequenceChecksumTypeObject sequenceChecksumType(final DataFetchingEnvironment env,
2861            @GraphQLName("sequenceChecksumTypeName") @GraphQLNonNull final String sequenceChecksumTypeName) {
2862        SequenceChecksumType sequenceChecksumType;
2863
2864        try {
2865            var commandForm = SequenceUtil.getHome().getGetSequenceChecksumTypeForm();
2866
2867            commandForm.setSequenceChecksumTypeName(sequenceChecksumTypeName);
2868
2869            sequenceChecksumType = CDI.current().select(GetSequenceChecksumTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
2870        } catch (NamingException ex) {
2871            throw new RuntimeException(ex);
2872        }
2873
2874        return sequenceChecksumType == null ? null : new SequenceChecksumTypeObject(sequenceChecksumType);
2875    }
2876
2877    @GraphQLField
2878    @GraphQLName("sequenceChecksumTypes")
2879    @GraphQLNonNull
2880    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
2881    static CountingPaginatedData<SequenceChecksumTypeObject> sequenceChecksumTypes(final DataFetchingEnvironment env) {
2882        CountingPaginatedData<SequenceChecksumTypeObject> data;
2883
2884        try {
2885            var commandForm = SequenceUtil.getHome().getGetSequenceChecksumTypesForm();
2886            var command = CDI.current().select(GetSequenceChecksumTypesCommand.class).get();
2887
2888            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2889            if(totalEntities == null) {
2890                data = Connections.emptyConnection();
2891            } else {
2892                try(var objectLimiter = new ObjectLimiter(env, SequenceChecksumTypeConstants.COMPONENT_VENDOR_NAME, SequenceChecksumTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
2893                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2894
2895                    var sequenceChecksumTypes = entities.stream()
2896                            .map(SequenceChecksumTypeObject::new)
2897                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
2898
2899                    data = new CountedObjects<>(objectLimiter, sequenceChecksumTypes);
2900                }
2901            }
2902        } catch (NamingException ex) {
2903            throw new RuntimeException(ex);
2904        }
2905
2906        return data;
2907    }
2908
2909    @GraphQLField
2910    @GraphQLName("sequenceEncoderType")
2911    static SequenceEncoderTypeObject sequenceEncoderType(final DataFetchingEnvironment env,
2912            @GraphQLName("sequenceEncoderTypeName") @GraphQLNonNull final String sequenceEncoderTypeName) {
2913        SequenceEncoderType sequenceEncoderType;
2914
2915        try {
2916            var commandForm = SequenceUtil.getHome().getGetSequenceEncoderTypeForm();
2917
2918            commandForm.setSequenceEncoderTypeName(sequenceEncoderTypeName);
2919
2920            sequenceEncoderType = CDI.current().select(GetSequenceEncoderTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
2921        } catch (NamingException ex) {
2922            throw new RuntimeException(ex);
2923        }
2924
2925        return sequenceEncoderType == null ? null : new SequenceEncoderTypeObject(sequenceEncoderType);
2926    }
2927
2928    @GraphQLField
2929    @GraphQLName("sequenceEncoderTypes")
2930    @GraphQLNonNull
2931    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
2932    static CountingPaginatedData<SequenceEncoderTypeObject> sequenceEncoderTypes(final DataFetchingEnvironment env) {
2933        CountingPaginatedData<SequenceEncoderTypeObject> data;
2934
2935        try {
2936            var commandForm = SequenceUtil.getHome().getGetSequenceEncoderTypesForm();
2937            var command = CDI.current().select(GetSequenceEncoderTypesCommand.class).get();
2938
2939            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2940            if(totalEntities == null) {
2941                data = Connections.emptyConnection();
2942            } else {
2943                try(var objectLimiter = new ObjectLimiter(env, SequenceEncoderTypeConstants.COMPONENT_VENDOR_NAME, SequenceEncoderTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
2944                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2945
2946                    var sequenceEncoderTypes = entities.stream()
2947                            .map(SequenceEncoderTypeObject::new)
2948                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
2949
2950                    data = new CountedObjects<>(objectLimiter, sequenceEncoderTypes);
2951                }
2952            }
2953        } catch (NamingException ex) {
2954            throw new RuntimeException(ex);
2955        }
2956
2957        return data;
2958    }
2959
2960    @GraphQLField
2961    @GraphQLName("selectorKind")
2962    static SelectorKindObject selectorKind(final DataFetchingEnvironment env,
2963            @GraphQLName("selectorKindName") final String selectorKindName,
2964            @GraphQLName("id") @GraphQLID final String id) {
2965        SelectorKind selectorKind;
2966
2967        try {
2968            var commandForm = SelectorUtil.getHome().getGetSelectorKindForm();
2969
2970            commandForm.setSelectorKindName(selectorKindName);
2971            commandForm.setUuid(id);
2972
2973            selectorKind = CDI.current().select(GetSelectorKindCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
2974        } catch (NamingException ex) {
2975            throw new RuntimeException(ex);
2976        }
2977
2978        return selectorKind == null ? null : new SelectorKindObject(selectorKind);
2979    }
2980
2981    @GraphQLField
2982    @GraphQLName("selectorKinds")
2983    @GraphQLNonNull
2984    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
2985    static CountingPaginatedData<SelectorKindObject> selectorKinds(final DataFetchingEnvironment env) {
2986        CountingPaginatedData<SelectorKindObject> data;
2987
2988        try {
2989            var commandForm = SelectorUtil.getHome().getGetSelectorKindsForm();
2990            var command = CDI.current().select(GetSelectorKindsCommand.class).get();
2991
2992            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2993            if(totalEntities == null) {
2994                data = Connections.emptyConnection();
2995            } else {
2996                try(var objectLimiter = new ObjectLimiter(env, SelectorKindConstants.COMPONENT_VENDOR_NAME, SelectorKindConstants.ENTITY_TYPE_NAME, totalEntities)) {
2997                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
2998
2999                    var selectorKinds = entities.stream()
3000                            .map(SelectorKindObject::new)
3001                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
3002
3003                    data = new CountedObjects<>(objectLimiter, selectorKinds);
3004                }
3005            }
3006        } catch (NamingException ex) {
3007            throw new RuntimeException(ex);
3008        }
3009
3010        return data;
3011    }
3012    
3013    @GraphQLField
3014    @GraphQLName("selectorType")
3015    static SelectorTypeObject selectorType(final DataFetchingEnvironment env,
3016            @GraphQLName("selectorKindName") final String selectorKindName,
3017            @GraphQLName("selectorTypeName") final String selectorTypeName,
3018            @GraphQLName("id") @GraphQLID final String id) {
3019        SelectorType selectorType;
3020
3021        try {
3022            var commandForm = SelectorUtil.getHome().getGetSelectorTypeForm();
3023
3024            commandForm.setSelectorKindName(selectorKindName);
3025            commandForm.setSelectorTypeName(selectorTypeName);
3026            commandForm.setUuid(id);
3027
3028            selectorType = CDI.current().select(GetSelectorTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
3029        } catch (NamingException ex) {
3030            throw new RuntimeException(ex);
3031        }
3032
3033        return selectorType == null ? null : new SelectorTypeObject(selectorType);
3034    }
3035
3036    @GraphQLField
3037    @GraphQLName("selectorTypes")
3038    @GraphQLNonNull
3039    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
3040    static CountingPaginatedData<SelectorTypeObject> selectorTypes(final DataFetchingEnvironment env,
3041            @GraphQLName("selectorKindName") @GraphQLNonNull final String selectorKindName) {
3042        CountingPaginatedData<SelectorTypeObject> data;
3043
3044        try {
3045            var commandForm = SelectorUtil.getHome().getGetSelectorTypesForm();
3046            var command = CDI.current().select(GetSelectorTypesCommand.class).get();
3047
3048            commandForm.setSelectorKindName(selectorKindName);
3049
3050            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3051            if(totalEntities == null) {
3052                data = Connections.emptyConnection();
3053            } else {
3054                try(var objectLimiter = new ObjectLimiter(env, SelectorTypeConstants.COMPONENT_VENDOR_NAME, SelectorTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
3055                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3056
3057                    var selectorTypes = entities.stream()
3058                            .map(SelectorTypeObject::new)
3059                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
3060
3061                    data = new CountedObjects<>(objectLimiter, selectorTypes);
3062                }
3063            }
3064        } catch (NamingException ex) {
3065            throw new RuntimeException(ex);
3066        }
3067
3068        return data;
3069    }
3070
3071    @GraphQLField
3072    @GraphQLName("selector")
3073    static SelectorObject selector(final DataFetchingEnvironment env,
3074            @GraphQLName("selectorKindName") final String selectorKindName,
3075            @GraphQLName("selectorTypeName") final String selectorTypeName,
3076            @GraphQLName("selectorName") final String selectorName,
3077            @GraphQLName("id") @GraphQLID final String id) {
3078        Selector selector;
3079
3080        try {
3081            var commandForm = SelectorUtil.getHome().getGetSelectorForm();
3082
3083            commandForm.setSelectorKindName(selectorKindName);
3084            commandForm.setSelectorTypeName(selectorTypeName);
3085            commandForm.setSelectorName(selectorName);
3086            commandForm.setUuid(id);
3087
3088            selector = CDI.current().select(GetSelectorCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
3089        } catch (NamingException ex) {
3090            throw new RuntimeException(ex);
3091        }
3092
3093        return selector == null ? null : new SelectorObject(selector);
3094    }
3095
3096    @GraphQLField
3097    @GraphQLName("selectors")
3098    static Collection<SelectorObject> selectors(final DataFetchingEnvironment env,
3099            @GraphQLName("selectorKindName") @GraphQLNonNull final String selectorKindName,
3100            @GraphQLName("selectorTypeName") @GraphQLNonNull final String selectorTypeName) {
3101        Collection<Selector> selectors;
3102        Collection<SelectorObject> selectorObjects;
3103
3104        try {
3105            var commandForm = SelectorUtil.getHome().getGetSelectorsForm();
3106
3107            commandForm.setSelectorKindName(selectorKindName);
3108            commandForm.setSelectorTypeName(selectorTypeName);
3109
3110            selectors = CDI.current().select(GetSelectorsCommand.class).get().getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3111        } catch (NamingException ex) {
3112            throw new RuntimeException(ex);
3113        }
3114
3115        if(selectors == null) {
3116            selectorObjects = emptyList();
3117        } else {
3118            selectorObjects = new ArrayList<>(selectors.size());
3119
3120            selectors.stream()
3121                    .map(SelectorObject::new)
3122                    .forEachOrdered(selectorObjects::add);
3123        }
3124
3125        return selectorObjects;
3126    }
3127
3128    @GraphQLField
3129    @GraphQLName("filterKind")
3130    static FilterKindObject filterKind(final DataFetchingEnvironment env,
3131            @GraphQLName("filterKindName") final String filterKindName,
3132            @GraphQLName("id") @GraphQLID final String id) {
3133        FilterKind filterKind;
3134
3135        try {
3136            var commandForm = FilterUtil.getHome().getGetFilterKindForm();
3137
3138            commandForm.setFilterKindName(filterKindName);
3139            commandForm.setUuid(id);
3140
3141            filterKind = CDI.current().select(GetFilterKindCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
3142        } catch (NamingException ex) {
3143            throw new RuntimeException(ex);
3144        }
3145
3146        return filterKind == null ? null : new FilterKindObject(filterKind);
3147    }
3148
3149    @GraphQLField
3150    @GraphQLName("filterKinds")
3151    @GraphQLNonNull
3152    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
3153    static CountingPaginatedData<FilterKindObject> filterKinds(final DataFetchingEnvironment env) {
3154        CountingPaginatedData<FilterKindObject> data;
3155
3156        try {
3157            var commandForm = FilterUtil.getHome().getGetFilterKindsForm();
3158            var command = CDI.current().select(GetFilterKindsCommand.class).get();
3159
3160            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3161            if(totalEntities == null) {
3162                data = Connections.emptyConnection();
3163            } else {
3164                try(var objectLimiter = new ObjectLimiter(env, FilterKindConstants.COMPONENT_VENDOR_NAME, FilterKindConstants.ENTITY_TYPE_NAME, totalEntities)) {
3165                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3166
3167                    var filterKinds = entities.stream()
3168                            .map(FilterKindObject::new)
3169                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
3170
3171                    data = new CountedObjects<>(objectLimiter, filterKinds);
3172                }
3173            }
3174        } catch (NamingException ex) {
3175            throw new RuntimeException(ex);
3176        }
3177
3178        return data;
3179    }
3180
3181    @GraphQLField
3182    @GraphQLName("filterType")
3183    static FilterTypeObject filterType(final DataFetchingEnvironment env,
3184            @GraphQLName("filterKindName") final String filterKindName,
3185            @GraphQLName("filterTypeName") final String filterTypeName,
3186            @GraphQLName("id") @GraphQLID final String id) {
3187        FilterType filterType;
3188
3189        try {
3190            var commandForm = FilterUtil.getHome().getGetFilterTypeForm();
3191
3192            commandForm.setFilterKindName(filterKindName);
3193            commandForm.setFilterTypeName(filterTypeName);
3194            commandForm.setUuid(id);
3195
3196            filterType = CDI.current().select(GetFilterTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
3197        } catch (NamingException ex) {
3198            throw new RuntimeException(ex);
3199        }
3200
3201        return filterType == null ? null : new FilterTypeObject(filterType);
3202    }
3203
3204    @GraphQLField
3205    @GraphQLName("filterTypes")
3206    @GraphQLNonNull
3207    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
3208    static CountingPaginatedData<FilterTypeObject> filterTypes(final DataFetchingEnvironment env,
3209            @GraphQLName("filterKindName") @GraphQLNonNull final String filterKindName) {
3210        CountingPaginatedData<FilterTypeObject> data;
3211
3212        try {
3213            var commandForm = FilterUtil.getHome().getGetFilterTypesForm();
3214            var command = CDI.current().select(GetFilterTypesCommand.class).get();
3215
3216            commandForm.setFilterKindName(filterKindName);
3217
3218            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3219            if(totalEntities == null) {
3220                data = Connections.emptyConnection();
3221            } else {
3222                try(var objectLimiter = new ObjectLimiter(env, FilterTypeConstants.COMPONENT_VENDOR_NAME, FilterTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
3223                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3224
3225                    var filterTypes = entities.stream()
3226                            .map(FilterTypeObject::new)
3227                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
3228
3229                    data = new CountedObjects<>(objectLimiter, filterTypes);
3230                }
3231            }
3232        } catch (NamingException ex) {
3233            throw new RuntimeException(ex);
3234        }
3235
3236        return data;
3237    }
3238
3239    @GraphQLField
3240    @GraphQLName("filter")
3241    static FilterObject filter(final DataFetchingEnvironment env,
3242            @GraphQLName("filterKindName") final String filterKindName,
3243            @GraphQLName("filterTypeName") final String filterTypeName,
3244            @GraphQLName("filterName") final String filterName,
3245            @GraphQLName("id") @GraphQLID final String id) {
3246        Filter filter;
3247
3248        try {
3249            var commandForm = FilterUtil.getHome().getGetFilterForm();
3250
3251            commandForm.setFilterKindName(filterKindName);
3252            commandForm.setFilterTypeName(filterTypeName);
3253            commandForm.setFilterName(filterName);
3254            commandForm.setUuid(id);
3255
3256            filter = CDI.current().select(GetFilterCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
3257        } catch (NamingException ex) {
3258            throw new RuntimeException(ex);
3259        }
3260
3261        return filter == null ? null : new FilterObject(filter);
3262    }
3263
3264    @GraphQLField
3265    @GraphQLName("filters")
3266    @GraphQLNonNull
3267    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
3268    static CountingPaginatedData<FilterObject> filters(final DataFetchingEnvironment env,
3269            @GraphQLName("filterKindName") @GraphQLNonNull final String filterKindName,
3270            @GraphQLName("filterTypeName") @GraphQLNonNull final String filterTypeName) {
3271        CountingPaginatedData<FilterObject> data;
3272
3273        try {
3274            var commandForm = FilterUtil.getHome().getGetFiltersForm();
3275            var command = CDI.current().select(GetFiltersCommand.class).get();
3276
3277            commandForm.setFilterKindName(filterKindName);
3278            commandForm.setFilterTypeName(filterTypeName);
3279
3280            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3281            if(totalEntities == null) {
3282                data = Connections.emptyConnection();
3283            } else {
3284                try(var objectLimiter = new ObjectLimiter(env, FilterConstants.COMPONENT_VENDOR_NAME, FilterConstants.ENTITY_TYPE_NAME, totalEntities)) {
3285                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3286
3287                    var filters = entities.stream()
3288                            .map(FilterObject::new)
3289                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
3290
3291                    data = new CountedObjects<>(objectLimiter, filters);
3292                }
3293            }
3294        } catch (NamingException ex) {
3295            throw new RuntimeException(ex);
3296        }
3297
3298        return data;
3299    }
3300
3301    @GraphQLField
3302    @GraphQLName("filterEntranceStep")
3303    static FilterEntranceStepObject filterEntranceStep(final DataFetchingEnvironment env,
3304            @GraphQLName("filterKindName") @GraphQLNonNull final String filterKindName,
3305            @GraphQLName("filterTypeName") @GraphQLNonNull final String filterTypeName,
3306            @GraphQLName("filterName") @GraphQLNonNull final String filterName,
3307            @GraphQLName("filterStepName") @GraphQLNonNull final String filterStepName) {
3308        FilterEntranceStep filterEntranceStep;
3309
3310        try {
3311            var commandForm = FilterUtil.getHome().getGetFilterEntranceStepForm();
3312
3313            commandForm.setFilterKindName(filterKindName);
3314            commandForm.setFilterTypeName(filterTypeName);
3315            commandForm.setFilterName(filterName);
3316            commandForm.setFilterStepName(filterStepName);
3317
3318            filterEntranceStep = CDI.current().select(GetFilterEntranceStepCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
3319        } catch (NamingException ex) {
3320            throw new RuntimeException(ex);
3321        }
3322
3323        return filterEntranceStep == null ? null : new FilterEntranceStepObject(filterEntranceStep);
3324    }
3325
3326    @GraphQLField
3327    @GraphQLName("filterEntranceSteps")
3328    @GraphQLNonNull
3329    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
3330    static CountingPaginatedData<FilterEntranceStepObject> filterEntranceSteps(final DataFetchingEnvironment env,
3331            @GraphQLName("filterKindName") @GraphQLNonNull final String filterKindName,
3332            @GraphQLName("filterTypeName") @GraphQLNonNull final String filterTypeName,
3333            @GraphQLName("filterName") @GraphQLNonNull final String filterName) {
3334        CountingPaginatedData<FilterEntranceStepObject> data;
3335
3336        try {
3337            var commandForm = FilterUtil.getHome().getGetFilterEntranceStepsForm();
3338            var command = CDI.current().select(GetFilterEntranceStepsCommand.class).get();
3339
3340            commandForm.setFilterKindName(filterKindName);
3341            commandForm.setFilterTypeName(filterTypeName);
3342            commandForm.setFilterName(filterName);
3343
3344            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3345            if(totalEntities == null) {
3346                data = Connections.emptyConnection();
3347            } else {
3348                try(var objectLimiter = new ObjectLimiter(env, FilterEntranceStepConstants.COMPONENT_VENDOR_NAME, FilterEntranceStepConstants.ENTITY_TYPE_NAME, totalEntities)) {
3349                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3350
3351                    var filterEntranceSteps = entities.stream()
3352                            .map(FilterEntranceStepObject::new)
3353                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
3354
3355                    data = new CountedObjects<>(objectLimiter, filterEntranceSteps);
3356                }
3357            }
3358        } catch (NamingException ex) {
3359            throw new RuntimeException(ex);
3360        }
3361
3362        return data;
3363    }
3364
3365    @GraphQLField
3366    @GraphQLName("filterStep")
3367    static FilterStepObject filterStep(final DataFetchingEnvironment env,
3368            @GraphQLName("filterKindName") final String filterKindName,
3369            @GraphQLName("filterTypeName") final String filterTypeName,
3370            @GraphQLName("filterName") final String filterName,
3371            @GraphQLName("filterStepName") final String filterStepName,
3372            @GraphQLName("id") @GraphQLID final String id) {
3373        FilterStep filterStep;
3374
3375        try {
3376            var commandForm = FilterUtil.getHome().getGetFilterStepForm();
3377
3378            commandForm.setFilterKindName(filterKindName);
3379            commandForm.setFilterTypeName(filterTypeName);
3380            commandForm.setFilterName(filterName);
3381            commandForm.setFilterStepName(filterStepName);
3382            commandForm.setUuid(id);
3383
3384            filterStep = CDI.current().select(GetFilterStepCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
3385        } catch (NamingException ex) {
3386            throw new RuntimeException(ex);
3387        }
3388
3389        return filterStep == null ? null : new FilterStepObject(filterStep);
3390    }
3391
3392    @GraphQLField
3393    @GraphQLName("filterSteps")
3394    @GraphQLNonNull
3395    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
3396    static CountingPaginatedData<FilterStepObject> filterSteps(final DataFetchingEnvironment env,
3397            @GraphQLName("filterKindName") @GraphQLNonNull final String filterKindName,
3398            @GraphQLName("filterTypeName") @GraphQLNonNull final String filterTypeName,
3399            @GraphQLName("filterName") @GraphQLNonNull final String filterName) {
3400        CountingPaginatedData<FilterStepObject> data;
3401
3402        try {
3403            var commandForm = FilterUtil.getHome().getGetFilterStepsForm();
3404            var command = CDI.current().select(GetFilterStepsCommand.class).get();
3405
3406            commandForm.setFilterKindName(filterKindName);
3407            commandForm.setFilterTypeName(filterTypeName);
3408            commandForm.setFilterName(filterName);
3409
3410            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3411            if(totalEntities == null) {
3412                data = Connections.emptyConnection();
3413            } else {
3414                try(var objectLimiter = new ObjectLimiter(env, FilterStepConstants.COMPONENT_VENDOR_NAME, FilterStepConstants.ENTITY_TYPE_NAME, totalEntities)) {
3415                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3416
3417                    var filterSteps = entities.stream()
3418                            .map(FilterStepObject::new)
3419                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
3420
3421                    data = new CountedObjects<>(objectLimiter, filterSteps);
3422                }
3423            }
3424        } catch (NamingException ex) {
3425            throw new RuntimeException(ex);
3426        }
3427
3428        return data;
3429    }
3430
3431    @GraphQLField
3432    @GraphQLName("filterStepElement")
3433    static FilterStepElementObject filterStepElement(final DataFetchingEnvironment env,
3434            @GraphQLName("filterKindName") final String filterKindName,
3435            @GraphQLName("filterTypeName") final String filterTypeName,
3436            @GraphQLName("filterName") final String filterName,
3437            @GraphQLName("filterStepName") final String filterStepName,
3438            @GraphQLName("filterStepElementName") final String filterStepElementName,
3439            @GraphQLName("id") @GraphQLID final String id) {
3440        FilterStepElement filterStepElement;
3441
3442        try {
3443            var commandForm = FilterUtil.getHome().getGetFilterStepElementForm();
3444
3445            commandForm.setFilterKindName(filterKindName);
3446            commandForm.setFilterTypeName(filterTypeName);
3447            commandForm.setFilterName(filterName);
3448            commandForm.setFilterStepName(filterStepName);
3449            commandForm.setFilterStepElementName(filterStepElementName);
3450            commandForm.setUuid(id);
3451
3452            filterStepElement = CDI.current().select(GetFilterStepElementCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
3453        } catch (NamingException ex) {
3454            throw new RuntimeException(ex);
3455        }
3456
3457        return filterStepElement == null ? null : new FilterStepElementObject(filterStepElement);
3458    }
3459
3460    @GraphQLField
3461    @GraphQLName("filterStepElements")
3462    @GraphQLNonNull
3463    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
3464    static CountingPaginatedData<FilterStepElementObject> filterStepElements(final DataFetchingEnvironment env,
3465            @GraphQLName("filterKindName") @GraphQLNonNull final String filterKindName,
3466            @GraphQLName("filterTypeName") @GraphQLNonNull final String filterTypeName,
3467            @GraphQLName("filterName") @GraphQLNonNull final String filterName,
3468            @GraphQLName("filterStepName") @GraphQLNonNull final String filterStepName) {
3469        CountingPaginatedData<FilterStepElementObject> data;
3470
3471        try {
3472            var commandForm = FilterUtil.getHome().getGetFilterStepElementsForm();
3473            var command = CDI.current().select(GetFilterStepElementsCommand.class).get();
3474
3475            commandForm.setFilterKindName(filterKindName);
3476            commandForm.setFilterTypeName(filterTypeName);
3477            commandForm.setFilterName(filterName);
3478            commandForm.setFilterStepName(filterStepName);
3479
3480            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3481            if(totalEntities == null) {
3482                data = Connections.emptyConnection();
3483            } else {
3484                try(var objectLimiter = new ObjectLimiter(env, FilterStepElementConstants.COMPONENT_VENDOR_NAME, FilterStepElementConstants.ENTITY_TYPE_NAME, totalEntities)) {
3485                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3486
3487                    var filterStepElements = entities.stream()
3488                            .map(FilterStepElementObject::new)
3489                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
3490
3491                    data = new CountedObjects<>(objectLimiter, filterStepElements);
3492                }
3493            }
3494        } catch (NamingException ex) {
3495            throw new RuntimeException(ex);
3496        }
3497
3498        return data;
3499    }
3500
3501    @GraphQLField
3502    @GraphQLName("filterStepDestination")
3503    static FilterStepDestinationObject filterStepDestination(final DataFetchingEnvironment env,
3504            @GraphQLName("filterKindName") @GraphQLNonNull final String filterKindName,
3505            @GraphQLName("filterTypeName") @GraphQLNonNull final String filterTypeName,
3506            @GraphQLName("filterName") @GraphQLNonNull final String filterName,
3507            @GraphQLName("fromFilterStepName") @GraphQLNonNull final String fromFilterStepName,
3508            @GraphQLName("toFilterStepName") @GraphQLNonNull final String toFilterStepName) {
3509        FilterStepDestination filterStepDestination;
3510
3511        try {
3512            var commandForm = FilterUtil.getHome().getGetFilterStepDestinationForm();
3513
3514            commandForm.setFilterKindName(filterKindName);
3515            commandForm.setFilterTypeName(filterTypeName);
3516            commandForm.setFilterName(filterName);
3517            commandForm.setFromFilterStepName(fromFilterStepName);
3518            commandForm.setToFilterStepName(toFilterStepName);
3519
3520            filterStepDestination = CDI.current().select(GetFilterStepDestinationCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
3521        } catch (NamingException ex) {
3522            throw new RuntimeException(ex);
3523        }
3524
3525        return filterStepDestination == null ? null : new FilterStepDestinationObject(filterStepDestination);
3526    }
3527
3528    @GraphQLField
3529    @GraphQLName("filterStepDestinations")
3530    @GraphQLNonNull
3531    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
3532    static CountingPaginatedData<FilterStepDestinationObject> filterStepDestinations(final DataFetchingEnvironment env,
3533            @GraphQLName("filterKindName") @GraphQLNonNull final String filterKindName,
3534            @GraphQLName("filterTypeName") @GraphQLNonNull final String filterTypeName,
3535            @GraphQLName("filterName") @GraphQLNonNull final String filterName,
3536            @GraphQLName("fromFilterStepName") final String fromFilterStepName,
3537            @GraphQLName("toFilterStepName") final String toFilterStepName) {
3538        CountingPaginatedData<FilterStepDestinationObject> data;
3539
3540        try {
3541            var commandForm = FilterUtil.getHome().getGetFilterStepDestinationsForm();
3542            var command = CDI.current().select(GetFilterStepDestinationsCommand.class).get();
3543
3544            commandForm.setFilterKindName(filterKindName);
3545            commandForm.setFilterTypeName(filterTypeName);
3546            commandForm.setFilterName(filterName);
3547            commandForm.setFromFilterStepName(fromFilterStepName);
3548            commandForm.setToFilterStepName(toFilterStepName);
3549
3550            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3551            if(totalEntities == null) {
3552                data = Connections.emptyConnection();
3553            } else {
3554                try(var objectLimiter = new ObjectLimiter(env, FilterStepDestinationConstants.COMPONENT_VENDOR_NAME, FilterStepDestinationConstants.ENTITY_TYPE_NAME, totalEntities)) {
3555                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3556
3557                    var filterStepDestinations = entities.stream()
3558                            .map(FilterStepDestinationObject::new)
3559                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
3560
3561                    data = new CountedObjects<>(objectLimiter, filterStepDestinations);
3562                }
3563            }
3564        } catch (NamingException ex) {
3565            throw new RuntimeException(ex);
3566        }
3567
3568        return data;
3569    }
3570
3571    @GraphQLField
3572    @GraphQLName("filterAdjustmentSource")
3573    static FilterAdjustmentSourceObject filterAdjustmentSource(final DataFetchingEnvironment env,
3574            @GraphQLName("filterAdjustmentSourceName") @GraphQLNonNull final String filterAdjustmentSourceName) {
3575        FilterAdjustmentSource filterAdjustmentSource;
3576
3577        try {
3578            var commandForm = FilterUtil.getHome().getGetFilterAdjustmentSourceForm();
3579
3580            commandForm.setFilterAdjustmentSourceName(filterAdjustmentSourceName);
3581
3582            filterAdjustmentSource = CDI.current().select(GetFilterAdjustmentSourceCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
3583        } catch (NamingException ex) {
3584            throw new RuntimeException(ex);
3585        }
3586
3587        return filterAdjustmentSource == null ? null : new FilterAdjustmentSourceObject(filterAdjustmentSource);
3588    }
3589
3590    @GraphQLField
3591    @GraphQLName("filterAdjustmentSources")
3592    @GraphQLNonNull
3593    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
3594    static CountingPaginatedData<FilterAdjustmentSourceObject> filterAdjustmentSources(final DataFetchingEnvironment env) {
3595        CountingPaginatedData<FilterAdjustmentSourceObject> data;
3596
3597        try {
3598            var commandForm = FilterUtil.getHome().getGetFilterAdjustmentSourcesForm();
3599            var command = CDI.current().select(GetFilterAdjustmentSourcesCommand.class).get();
3600
3601            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3602            if(totalEntities == null) {
3603                data = Connections.emptyConnection();
3604            } else {
3605                try(var objectLimiter = new ObjectLimiter(env, com.echothree.model.data.filter.common.FilterAdjustmentSourceConstants.COMPONENT_VENDOR_NAME, com.echothree.model.data.filter.common.FilterAdjustmentSourceConstants.ENTITY_TYPE_NAME, totalEntities)) {
3606                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3607
3608                    var filterAdjustmentSources = entities.stream()
3609                            .map(FilterAdjustmentSourceObject::new)
3610                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
3611
3612                    data = new CountedObjects<>(objectLimiter, filterAdjustmentSources);
3613                }
3614            }
3615        } catch (NamingException ex) {
3616            throw new RuntimeException(ex);
3617        }
3618
3619        return data;
3620    }
3621
3622    @GraphQLField
3623    @GraphQLName("filterAdjustmentType")
3624    static FilterAdjustmentTypeObject filterAdjustmentType(final DataFetchingEnvironment env,
3625            @GraphQLName("filterAdjustmentTypeName") @GraphQLNonNull final String filterAdjustmentTypeName) {
3626        FilterAdjustmentType filterAdjustmentType;
3627
3628        try {
3629            var commandForm = FilterUtil.getHome().getGetFilterAdjustmentTypeForm();
3630
3631            commandForm.setFilterAdjustmentTypeName(filterAdjustmentTypeName);
3632
3633            filterAdjustmentType = CDI.current().select(GetFilterAdjustmentTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
3634        } catch (NamingException ex) {
3635            throw new RuntimeException(ex);
3636        }
3637
3638        return filterAdjustmentType == null ? null : new FilterAdjustmentTypeObject(filterAdjustmentType);
3639    }
3640
3641    @GraphQLField
3642    @GraphQLName("filterAdjustmentTypes")
3643    @GraphQLNonNull
3644    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
3645    static CountingPaginatedData<FilterAdjustmentTypeObject> filterAdjustmentTypes(final DataFetchingEnvironment env) {
3646        CountingPaginatedData<FilterAdjustmentTypeObject> data;
3647
3648        try {
3649            var commandForm = FilterUtil.getHome().getGetFilterAdjustmentTypesForm();
3650            var command = CDI.current().select(GetFilterAdjustmentTypesCommand.class).get();
3651
3652            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3653            if(totalEntities == null) {
3654                data = Connections.emptyConnection();
3655            } else {
3656                try(var objectLimiter = new ObjectLimiter(env, FilterAdjustmentTypeConstants.COMPONENT_VENDOR_NAME, FilterAdjustmentTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
3657                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3658
3659                    var filterAdjustmentTypes = entities.stream()
3660                            .map(FilterAdjustmentTypeObject::new)
3661                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
3662
3663                    data = new CountedObjects<>(objectLimiter, filterAdjustmentTypes);
3664                }
3665            }
3666        } catch (NamingException ex) {
3667            throw new RuntimeException(ex);
3668        }
3669
3670        return data;
3671    }
3672
3673    @GraphQLField
3674    @GraphQLName("filterAdjustment")
3675    static FilterAdjustmentObject filterAdjustment(final DataFetchingEnvironment env,
3676            @GraphQLName("filterKindName") final String filterKindName,
3677            @GraphQLName("filterAdjustmentName") final String filterAdjustmentName,
3678            @GraphQLName("id") @GraphQLID final String id) {
3679        FilterAdjustment filterAdjustment;
3680
3681        try {
3682            var commandForm = FilterUtil.getHome().getGetFilterAdjustmentForm();
3683
3684            commandForm.setFilterKindName(filterKindName);
3685            commandForm.setFilterAdjustmentName(filterAdjustmentName);
3686            commandForm.setUuid(id);
3687
3688            filterAdjustment = CDI.current().select(GetFilterAdjustmentCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
3689        } catch (NamingException ex) {
3690            throw new RuntimeException(ex);
3691        }
3692
3693        return filterAdjustment == null ? null : new FilterAdjustmentObject(filterAdjustment);
3694    }
3695
3696    @GraphQLField
3697    @GraphQLName("filterAdjustments")
3698    static Collection<FilterAdjustmentObject> filterAdjustments(final DataFetchingEnvironment env,
3699            @GraphQLName("filterKindName") @GraphQLNonNull final String filterKindName) {
3700        Collection<FilterAdjustment> filterAdjustments;
3701        Collection<FilterAdjustmentObject> filterAdjustmentObjects;
3702
3703        try {
3704            var commandForm = FilterUtil.getHome().getGetFilterAdjustmentsForm();
3705
3706            commandForm.setFilterKindName(filterKindName);
3707
3708            filterAdjustments = CDI.current().select(GetFilterAdjustmentsCommand.class).get().getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3709        } catch (NamingException ex) {
3710            throw new RuntimeException(ex);
3711        }
3712
3713        if(filterAdjustments == null) {
3714            filterAdjustmentObjects = emptyList();
3715        } else {
3716            filterAdjustmentObjects = new ArrayList<>(filterAdjustments.size());
3717
3718            filterAdjustments.stream()
3719                    .map(FilterAdjustmentObject::new)
3720                    .forEachOrdered(filterAdjustmentObjects::add);
3721        }
3722
3723        return filterAdjustmentObjects;
3724    }
3725
3726    @GraphQLField
3727    @GraphQLName("filterAdjustmentAmount")
3728    static FilterAdjustmentAmountObject filterAdjustmentAmount(final DataFetchingEnvironment env,
3729            @GraphQLName("filterKindName") @GraphQLNonNull final String filterKindName,
3730            @GraphQLName("filterAdjustmentName") @GraphQLNonNull final String filterAdjustmentName,
3731            @GraphQLName("unitOfMeasureName") final String unitOfMeasureName,
3732            @GraphQLName("unitOfMeasureKindName") final String unitOfMeasureKindName,
3733            @GraphQLName("unitOfMeasureTypeName") final String unitOfMeasureTypeName,
3734            @GraphQLName("currencyIsoName") @GraphQLNonNull final String currencyIsoName) {
3735        FilterAdjustmentAmount filterAdjustmentAmount;
3736
3737        try {
3738            var commandForm = FilterUtil.getHome().getGetFilterAdjustmentAmountForm();
3739
3740            commandForm.setFilterKindName(filterKindName);
3741            commandForm.setFilterAdjustmentName(filterAdjustmentName);
3742            commandForm.setUnitOfMeasureName(unitOfMeasureName);
3743            commandForm.setUnitOfMeasureKindName(unitOfMeasureKindName);
3744            commandForm.setUnitOfMeasureTypeName(unitOfMeasureTypeName);
3745            commandForm.setCurrencyIsoName(currencyIsoName);
3746
3747            filterAdjustmentAmount = CDI.current().select(GetFilterAdjustmentAmountCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
3748        } catch (NamingException ex) {
3749            throw new RuntimeException(ex);
3750        }
3751
3752        return filterAdjustmentAmount == null ? null : new FilterAdjustmentAmountObject(filterAdjustmentAmount);
3753    }
3754
3755    @GraphQLField
3756    @GraphQLName("filterAdjustmentAmounts")
3757    static Collection<FilterAdjustmentAmountObject> filterAdjustmentAmounts(final DataFetchingEnvironment env,
3758            @GraphQLName("filterKindName") @GraphQLNonNull final String filterKindName,
3759            @GraphQLName("filterAdjustmentName") @GraphQLNonNull final String filterAdjustmentName) {
3760        Collection<FilterAdjustmentAmount> filterAdjustmentAmounts;
3761        Collection<FilterAdjustmentAmountObject> filterAdjustmentAmountObjects;
3762
3763        try {
3764            var commandForm = FilterUtil.getHome().getGetFilterAdjustmentAmountsForm();
3765
3766            commandForm.setFilterKindName(filterKindName);
3767            commandForm.setFilterAdjustmentName(filterAdjustmentName);
3768
3769            filterAdjustmentAmounts = CDI.current().select(GetFilterAdjustmentAmountsCommand.class).get().getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3770        } catch (NamingException ex) {
3771            throw new RuntimeException(ex);
3772        }
3773
3774        if(filterAdjustmentAmounts == null) {
3775            filterAdjustmentAmountObjects = emptyList();
3776        } else {
3777            filterAdjustmentAmountObjects = new ArrayList<>(filterAdjustmentAmounts.size());
3778
3779            filterAdjustmentAmounts.stream()
3780                    .map(FilterAdjustmentAmountObject::new)
3781                    .forEachOrdered(filterAdjustmentAmountObjects::add);
3782        }
3783
3784        return filterAdjustmentAmountObjects;
3785    }
3786
3787    @GraphQLField
3788    @GraphQLName("filterAdjustmentFixedAmount")
3789    static FilterAdjustmentFixedAmountObject filterAdjustmentFixedAmount(final DataFetchingEnvironment env,
3790            @GraphQLName("filterKindName") @GraphQLNonNull final String filterKindName,
3791            @GraphQLName("filterAdjustmentName") @GraphQLNonNull final String filterAdjustmentName,
3792            @GraphQLName("unitOfMeasureName") final String unitOfMeasureName,
3793            @GraphQLName("unitOfMeasureKindName") final String unitOfMeasureKindName,
3794            @GraphQLName("unitOfMeasureTypeName") final String unitOfMeasureTypeName,
3795            @GraphQLName("currencyIsoName") @GraphQLNonNull final String currencyIsoName) {
3796        FilterAdjustmentFixedAmount filterAdjustmentFixedAmount;
3797
3798        try {
3799            var commandForm = FilterUtil.getHome().getGetFilterAdjustmentFixedAmountForm();
3800
3801            commandForm.setFilterKindName(filterKindName);
3802            commandForm.setFilterAdjustmentName(filterAdjustmentName);
3803            commandForm.setUnitOfMeasureName(unitOfMeasureName);
3804            commandForm.setUnitOfMeasureKindName(unitOfMeasureKindName);
3805            commandForm.setUnitOfMeasureTypeName(unitOfMeasureTypeName);
3806            commandForm.setCurrencyIsoName(currencyIsoName);
3807
3808            filterAdjustmentFixedAmount = CDI.current().select(GetFilterAdjustmentFixedAmountCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
3809        } catch (NamingException ex) {
3810            throw new RuntimeException(ex);
3811        }
3812
3813        return filterAdjustmentFixedAmount == null ? null : new FilterAdjustmentFixedAmountObject(filterAdjustmentFixedAmount);
3814    }
3815
3816    @GraphQLField
3817    @GraphQLName("filterAdjustmentFixedAmounts")
3818    static Collection<FilterAdjustmentFixedAmountObject> filterAdjustmentFixedAmounts(final DataFetchingEnvironment env,
3819            @GraphQLName("filterKindName") @GraphQLNonNull final String filterKindName,
3820            @GraphQLName("filterAdjustmentName") @GraphQLNonNull final String filterAdjustmentName) {
3821        Collection<FilterAdjustmentFixedAmount> filterAdjustmentFixedAmounts;
3822        Collection<FilterAdjustmentFixedAmountObject> filterAdjustmentFixedAmountObjects;
3823
3824        try {
3825            var commandForm = FilterUtil.getHome().getGetFilterAdjustmentFixedAmountsForm();
3826
3827            commandForm.setFilterKindName(filterKindName);
3828            commandForm.setFilterAdjustmentName(filterAdjustmentName);
3829
3830            filterAdjustmentFixedAmounts = CDI.current().select(GetFilterAdjustmentFixedAmountsCommand.class).get().getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3831        } catch (NamingException ex) {
3832            throw new RuntimeException(ex);
3833        }
3834
3835        if(filterAdjustmentFixedAmounts == null) {
3836            filterAdjustmentFixedAmountObjects = emptyList();
3837        } else {
3838            filterAdjustmentFixedAmountObjects = new ArrayList<>(filterAdjustmentFixedAmounts.size());
3839
3840            filterAdjustmentFixedAmounts.stream()
3841                    .map(FilterAdjustmentFixedAmountObject::new)
3842                    .forEachOrdered(filterAdjustmentFixedAmountObjects::add);
3843        }
3844
3845        return filterAdjustmentFixedAmountObjects;
3846    }
3847
3848    @GraphQLField
3849    @GraphQLName("filterAdjustmentPercent")
3850    static FilterAdjustmentPercentObject filterAdjustmentPercent(final DataFetchingEnvironment env,
3851            @GraphQLName("filterKindName") @GraphQLNonNull final String filterKindName,
3852            @GraphQLName("filterAdjustmentName") @GraphQLNonNull final String filterAdjustmentName,
3853            @GraphQLName("unitOfMeasureName") final String unitOfMeasureName,
3854            @GraphQLName("unitOfMeasureKindName") final String unitOfMeasureKindName,
3855            @GraphQLName("unitOfMeasureTypeName") final String unitOfMeasureTypeName,
3856            @GraphQLName("currencyIsoName") @GraphQLNonNull final String currencyIsoName) {
3857        FilterAdjustmentPercent filterAdjustmentPercent;
3858
3859        try {
3860            var commandForm = FilterUtil.getHome().getGetFilterAdjustmentPercentForm();
3861
3862            commandForm.setFilterKindName(filterKindName);
3863            commandForm.setFilterAdjustmentName(filterAdjustmentName);
3864            commandForm.setUnitOfMeasureName(unitOfMeasureName);
3865            commandForm.setUnitOfMeasureKindName(unitOfMeasureKindName);
3866            commandForm.setUnitOfMeasureTypeName(unitOfMeasureTypeName);
3867            commandForm.setCurrencyIsoName(currencyIsoName);
3868
3869            filterAdjustmentPercent = CDI.current().select(GetFilterAdjustmentPercentCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
3870        } catch (NamingException ex) {
3871            throw new RuntimeException(ex);
3872        }
3873
3874        return filterAdjustmentPercent == null ? null : new FilterAdjustmentPercentObject(filterAdjustmentPercent);
3875    }
3876
3877    @GraphQLField
3878    @GraphQLName("filterAdjustmentPercents")
3879    static Collection<FilterAdjustmentPercentObject> filterAdjustmentPercents(final DataFetchingEnvironment env,
3880            @GraphQLName("filterKindName") @GraphQLNonNull final String filterKindName,
3881            @GraphQLName("filterAdjustmentName") @GraphQLNonNull final String filterAdjustmentName) {
3882        Collection<FilterAdjustmentPercent> filterAdjustmentPercents;
3883        Collection<FilterAdjustmentPercentObject> filterAdjustmentPercentObjects;
3884
3885        try {
3886            var commandForm = FilterUtil.getHome().getGetFilterAdjustmentPercentsForm();
3887
3888            commandForm.setFilterKindName(filterKindName);
3889            commandForm.setFilterAdjustmentName(filterAdjustmentName);
3890
3891            filterAdjustmentPercents = CDI.current().select(GetFilterAdjustmentPercentsCommand.class).get().getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3892        } catch (NamingException ex) {
3893            throw new RuntimeException(ex);
3894        }
3895
3896        if(filterAdjustmentPercents == null) {
3897            filterAdjustmentPercentObjects = emptyList();
3898        } else {
3899            filterAdjustmentPercentObjects = new ArrayList<>(filterAdjustmentPercents.size());
3900
3901            filterAdjustmentPercents.stream()
3902                    .map(FilterAdjustmentPercentObject::new)
3903                    .forEachOrdered(filterAdjustmentPercentObjects::add);
3904        }
3905
3906        return filterAdjustmentPercentObjects;
3907    }
3908
3909    @GraphQLField
3910    @GraphQLName("offerUse")
3911    static OfferUseObject offerUse(final DataFetchingEnvironment env,
3912            @GraphQLName("offerName") @GraphQLNonNull final String offerName,
3913            @GraphQLName("useName") @GraphQLNonNull final String useName) {
3914        OfferUse offerUse;
3915
3916        try {
3917            var commandForm = OfferUtil.getHome().getGetOfferUseForm();
3918
3919            commandForm.setOfferName(offerName);
3920            commandForm.setUseName(useName);
3921
3922            offerUse = CDI.current().select(GetOfferUseCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
3923        } catch (NamingException ex) {
3924            throw new RuntimeException(ex);
3925        }
3926
3927        return offerUse == null ? null : new OfferUseObject(offerUse);
3928    }
3929
3930    @GraphQLField
3931    @GraphQLName("offerUses")
3932    @GraphQLNonNull
3933    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
3934    static CountingPaginatedData<OfferUseObject> offerUses(final DataFetchingEnvironment env,
3935            @GraphQLName("offerName") final String offerName,
3936            @GraphQLName("useName") final String useName) {
3937        CountingPaginatedData<OfferUseObject> data;
3938
3939        try {
3940            var commandForm = OfferUtil.getHome().getGetOfferUsesForm();
3941
3942            commandForm.setOfferName(offerName);
3943            commandForm.setUseName(useName);
3944
3945            var command = CDI.current().select(GetOfferUsesCommand.class).get();
3946
3947            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3948            if(totalEntities == null) {
3949                data = Connections.emptyConnection();
3950            } else {
3951                try(var objectLimiter = new ObjectLimiter(env, OfferConstants.COMPONENT_VENDOR_NAME, OfferConstants.ENTITY_TYPE_NAME, totalEntities)) {
3952                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
3953
3954                    var offerUses = entities.stream()
3955                            .map(OfferUseObject::new)
3956                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
3957
3958                    data = new CountedObjects<>(objectLimiter, offerUses);
3959                }
3960            }
3961        } catch (NamingException ex) {
3962            throw new RuntimeException(ex);
3963        }
3964
3965        return data;
3966    }
3967
3968    @GraphQLField
3969    @GraphQLName("offer")
3970    static OfferObject offer(final DataFetchingEnvironment env,
3971            @GraphQLName("offerName") final String offerName,
3972            @GraphQLName("id") @GraphQLID final String id) {
3973        Offer offer;
3974
3975        try {
3976            var commandForm = OfferUtil.getHome().getGetOfferForm();
3977
3978            commandForm.setOfferName(offerName);
3979            commandForm.setUuid(id);
3980
3981            offer = CDI.current().select(GetOfferCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
3982        } catch (NamingException ex) {
3983            throw new RuntimeException(ex);
3984        }
3985
3986        return offer == null ? null : new OfferObject(offer);
3987    }
3988
3989    @GraphQLField
3990    @GraphQLName("offers")
3991    @GraphQLNonNull
3992    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
3993    static CountingPaginatedData<OfferObject> offers(final DataFetchingEnvironment env) {
3994        CountingPaginatedData<OfferObject> data;
3995
3996        try {
3997            var commandForm = OfferUtil.getHome().getGetOffersForm();
3998            var command = CDI.current().select(GetOffersCommand.class).get();
3999
4000            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4001            if(totalEntities == null) {
4002                data = Connections.emptyConnection();
4003            } else {
4004                try(var objectLimiter = new ObjectLimiter(env, OfferConstants.COMPONENT_VENDOR_NAME, OfferConstants.ENTITY_TYPE_NAME, totalEntities)) {
4005                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4006
4007                    var offers = entities.stream()
4008                            .map(OfferObject::new)
4009                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4010
4011                    data = new CountedObjects<>(objectLimiter, offers);
4012                }
4013            }
4014        } catch (NamingException ex) {
4015            throw new RuntimeException(ex);
4016        }
4017
4018        return data;
4019    }
4020    
4021    @GraphQLField
4022    @GraphQLName("offerItem")
4023    static OfferItemObject offerItem(final DataFetchingEnvironment env,
4024            @GraphQLName("offerName") final String offerName,
4025            @GraphQLName("itemName") final String itemName,
4026            @GraphQLName("id") @GraphQLID final String id) {
4027        OfferItem offerItem;
4028
4029        try {
4030            var commandForm = OfferUtil.getHome().getGetOfferItemForm();
4031
4032            commandForm.setOfferName(offerName);
4033            commandForm.setItemName(itemName);
4034            commandForm.setUuid(id);
4035
4036            offerItem = CDI.current().select(GetOfferItemCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4037        } catch (NamingException ex) {
4038            throw new RuntimeException(ex);
4039        }
4040
4041        return offerItem == null ? null : new OfferItemObject(offerItem);
4042    }
4043
4044    @GraphQLField
4045    @GraphQLName("offerItems")
4046    @GraphQLNonNull
4047    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4048    static CountingPaginatedData<OfferItemObject> offerItems(final DataFetchingEnvironment env,
4049            @GraphQLName("offerName") @GraphQLNonNull final String offerName) {
4050        CountingPaginatedData<OfferItemObject> data;
4051
4052        try {
4053            var commandForm = OfferUtil.getHome().getGetOfferItemsForm();
4054            var command = CDI.current().select(GetOfferItemsCommand.class).get();
4055
4056            commandForm.setOfferName(offerName);
4057
4058            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4059            if(totalEntities == null) {
4060                data = Connections.emptyConnection();
4061            } else {
4062                try(var objectLimiter = new ObjectLimiter(env, OfferItemConstants.COMPONENT_VENDOR_NAME, OfferItemConstants.ENTITY_TYPE_NAME, totalEntities)) {
4063                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4064
4065                    var offerItemObjects = entities.stream()
4066                            .map(OfferItemObject::new)
4067                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4068
4069                    data = new CountedObjects<>(objectLimiter, offerItemObjects);
4070                }
4071            }
4072        } catch (NamingException ex) {
4073            throw new RuntimeException(ex);
4074        }
4075
4076        return data;
4077    }
4078
4079    @GraphQLField
4080    @GraphQLName("offerItemPrice")
4081    static OfferItemPriceObject offerItemPrice(final DataFetchingEnvironment env,
4082            @GraphQLName("offerName") @GraphQLNonNull final String offerName,
4083            @GraphQLName("itemName") @GraphQLNonNull final String itemName,
4084            @GraphQLName("inventoryConditionName") @GraphQLNonNull final String inventoryConditionName,
4085            @GraphQLName("unitOfMeasureTypeName") @GraphQLNonNull final String unitOfMeasureTypeName,
4086            @GraphQLName("currencyIsoName") @GraphQLNonNull final String currencyIsoName) {
4087        OfferItemPrice offerItemPrice;
4088
4089        try {
4090            var commandForm = OfferUtil.getHome().getGetOfferItemPriceForm();
4091
4092            commandForm.setOfferName(offerName);
4093            commandForm.setItemName(itemName);
4094            commandForm.setInventoryConditionName(inventoryConditionName);
4095            commandForm.setUnitOfMeasureTypeName(unitOfMeasureTypeName);
4096            commandForm.setCurrencyIsoName(currencyIsoName);
4097
4098            offerItemPrice = CDI.current().select(GetOfferItemPriceCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4099        } catch (NamingException ex) {
4100            throw new RuntimeException(ex);
4101        }
4102
4103        return offerItemPrice == null ? null : new OfferItemPriceObject(offerItemPrice);
4104    }
4105
4106    @GraphQLField
4107    @GraphQLName("offerItemPrices")
4108    @GraphQLNonNull
4109    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4110    static CountingPaginatedData<OfferItemPriceObject> offerItemPrices(final DataFetchingEnvironment env,
4111            @GraphQLName("offerName") @GraphQLNonNull final String offerName,
4112            @GraphQLName("itemName") @GraphQLNonNull final String itemName) {
4113        CountingPaginatedData<OfferItemPriceObject> data;
4114
4115        try {
4116            var commandForm = OfferUtil.getHome().getGetOfferItemPricesForm();
4117            var command = CDI.current().select(GetOfferItemPricesCommand.class).get();
4118
4119            commandForm.setOfferName(offerName);
4120            commandForm.setItemName(itemName);
4121
4122            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4123            if(totalEntities == null) {
4124                data = Connections.emptyConnection();
4125            } else {
4126                try(var objectLimiter = new ObjectLimiter(env, OfferItemPriceConstants.COMPONENT_VENDOR_NAME, OfferItemPriceConstants.ENTITY_TYPE_NAME, totalEntities)) {
4127                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4128
4129                    var offerItemPrices = entities.stream()
4130                            .map(OfferItemPriceObject::new)
4131                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4132
4133                    data = new CountedObjects<>(objectLimiter, offerItemPrices);
4134                }
4135            }
4136        } catch (NamingException ex) {
4137            throw new RuntimeException(ex);
4138        }
4139
4140        return data;
4141    }
4142
4143    @GraphQLField
4144    @GraphQLName("offerCustomerType")
4145    static OfferCustomerTypeObject offerCustomerType(final DataFetchingEnvironment env,
4146            @GraphQLName("offerName") @GraphQLNonNull final String offerName,
4147            @GraphQLName("customerTypeName") @GraphQLNonNull final String customerTypeName) {
4148        OfferCustomerType offerCustomerType;
4149
4150        try {
4151            var commandForm = OfferUtil.getHome().getGetOfferCustomerTypeForm();
4152
4153            commandForm.setOfferName(offerName);
4154            commandForm.setCustomerTypeName(customerTypeName);
4155
4156            offerCustomerType = CDI.current().select(GetOfferCustomerTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4157        } catch (NamingException ex) {
4158            throw new RuntimeException(ex);
4159        }
4160
4161        return offerCustomerType == null ? null : new OfferCustomerTypeObject(offerCustomerType);
4162    }
4163
4164    @GraphQLField
4165    @GraphQLName("offerCustomerTypes")
4166    @GraphQLNonNull
4167    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4168    static CountingPaginatedData<OfferCustomerTypeObject> offerCustomerTypes(final DataFetchingEnvironment env,
4169            @GraphQLName("offerName") final String offerName,
4170            @GraphQLName("customerTypeName") final String customerTypeName) {
4171        CountingPaginatedData<OfferCustomerTypeObject> data;
4172
4173        try {
4174            var commandForm = OfferUtil.getHome().getGetOfferCustomerTypesForm();
4175            var command = CDI.current().select(GetOfferCustomerTypesCommand.class).get();
4176
4177            commandForm.setOfferName(offerName);
4178            commandForm.setCustomerTypeName(customerTypeName);
4179
4180            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4181            if(totalEntities == null) {
4182                data = Connections.emptyConnection();
4183            } else {
4184                try(var objectLimiter = new ObjectLimiter(env, OfferCustomerTypeConstants.COMPONENT_VENDOR_NAME, OfferCustomerTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
4185                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4186
4187                    var offerCustomerTypeObjects = entities.stream()
4188                            .map(OfferCustomerTypeObject::new)
4189                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4190
4191                    data = new CountedObjects<>(objectLimiter, offerCustomerTypeObjects);
4192                }
4193            }
4194        } catch (NamingException ex) {
4195            throw new RuntimeException(ex);
4196        }
4197
4198        return data;
4199    }
4200
4201    @GraphQLField
4202    @GraphQLName("use")
4203    static UseObject use(final DataFetchingEnvironment env,
4204            @GraphQLName("useName") final String useName,
4205            @GraphQLName("id") @GraphQLID final String id) {
4206        Use use;
4207
4208        try {
4209            var commandForm = OfferUtil.getHome().getGetUseForm();
4210
4211            commandForm.setUseName(useName);
4212            commandForm.setUuid(id);
4213
4214            use = CDI.current().select(GetUseCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4215        } catch (NamingException ex) {
4216            throw new RuntimeException(ex);
4217        }
4218
4219        return use == null ? null : new UseObject(use);
4220    }
4221
4222    @GraphQLField
4223    @GraphQLName("uses")
4224    @GraphQLNonNull
4225    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4226    static CountingPaginatedData<UseObject> uses(final DataFetchingEnvironment env) {
4227        CountingPaginatedData<UseObject> data;
4228
4229        try {
4230            var commandForm = OfferUtil.getHome().getGetUsesForm();
4231            var command = CDI.current().select(GetUsesCommand.class).get();
4232
4233            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4234            if(totalEntities == null) {
4235                data = Connections.emptyConnection();
4236            } else {
4237                try(var objectLimiter = new ObjectLimiter(env, UseConstants.COMPONENT_VENDOR_NAME, UseConstants.ENTITY_TYPE_NAME, totalEntities)) {
4238                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4239
4240                    var uses = entities.stream()
4241                            .map(UseObject::new)
4242                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4243
4244                    data = new CountedObjects<>(objectLimiter, uses);
4245                }
4246            }
4247        } catch (NamingException ex) {
4248            throw new RuntimeException(ex);
4249        }
4250
4251        return data;
4252    }
4253
4254    @GraphQLField
4255    @GraphQLName("offerNameElement")
4256    static OfferNameElementObject offerNameElement(final DataFetchingEnvironment env,
4257            @GraphQLName("offerNameElementName") final String offerNameElementName,
4258            @GraphQLName("id") @GraphQLID final String id) {
4259        OfferNameElement offerNameElement;
4260
4261        try {
4262            var commandForm = OfferUtil.getHome().getGetOfferNameElementForm();
4263
4264            commandForm.setOfferNameElementName(offerNameElementName);
4265            commandForm.setUuid(id);
4266
4267            offerNameElement = CDI.current().select(GetOfferNameElementCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4268        } catch (NamingException ex) {
4269            throw new RuntimeException(ex);
4270        }
4271
4272        return offerNameElement == null ? null : new OfferNameElementObject(offerNameElement);
4273    }
4274
4275    @GraphQLField
4276    @GraphQLName("offerNameElements")
4277    @GraphQLNonNull
4278    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4279    static CountingPaginatedData<OfferNameElementObject> offerNameElements(final DataFetchingEnvironment env) {
4280        CountingPaginatedData<OfferNameElementObject> data;
4281
4282        try {
4283            var commandForm = OfferUtil.getHome().getGetOfferNameElementsForm();
4284            var command = CDI.current().select(GetOfferNameElementsCommand.class).get();
4285
4286            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4287            if(totalEntities == null) {
4288                data = Connections.emptyConnection();
4289            } else {
4290                try(var objectLimiter = new ObjectLimiter(env, OfferNameElementConstants.COMPONENT_VENDOR_NAME, OfferNameElementConstants.ENTITY_TYPE_NAME, totalEntities)) {
4291                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4292
4293                    var offerNameElementObjects = entities.stream()
4294                            .map(OfferNameElementObject::new)
4295                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4296
4297                    data = new CountedObjects<>(objectLimiter, offerNameElementObjects);
4298                }
4299            }
4300        } catch (NamingException ex) {
4301            throw new RuntimeException(ex);
4302        }
4303
4304        return data;
4305    }
4306
4307    @GraphQLField
4308    @GraphQLName("useNameElement")
4309    static UseNameElementObject useNameElement(final DataFetchingEnvironment env,
4310            @GraphQLName("useNameElementName") final String useNameElementName,
4311            @GraphQLName("id") @GraphQLID final String id) {
4312        UseNameElement useNameElement;
4313
4314        try {
4315            var commandForm = OfferUtil.getHome().getGetUseNameElementForm();
4316
4317            commandForm.setUseNameElementName(useNameElementName);
4318            commandForm.setUuid(id);
4319
4320            useNameElement = CDI.current().select(GetUseNameElementCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4321        } catch (NamingException ex) {
4322            throw new RuntimeException(ex);
4323        }
4324
4325        return useNameElement == null ? null : new UseNameElementObject(useNameElement);
4326    }
4327
4328    @GraphQLField
4329    @GraphQLName("useNameElements")
4330    @GraphQLNonNull
4331    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4332    static CountingPaginatedData<UseNameElementObject> useNameElements(final DataFetchingEnvironment env) {
4333        CountingPaginatedData<UseNameElementObject> data;
4334
4335        try {
4336            var commandForm = OfferUtil.getHome().getGetUseNameElementsForm();
4337            var command = CDI.current().select(GetUseNameElementsCommand.class).get();
4338
4339            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4340            if(totalEntities == null) {
4341                data = Connections.emptyConnection();
4342            } else {
4343                try(var objectLimiter = new ObjectLimiter(env, UseNameElementConstants.COMPONENT_VENDOR_NAME, UseNameElementConstants.ENTITY_TYPE_NAME, totalEntities)) {
4344                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4345
4346                    var useNameElementObjects = entities.stream()
4347                            .map(UseNameElementObject::new)
4348                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4349
4350                    data = new CountedObjects<>(objectLimiter, useNameElementObjects);
4351                }
4352            }
4353        } catch (NamingException ex) {
4354            throw new RuntimeException(ex);
4355        }
4356
4357        return data;
4358    }
4359
4360    @GraphQLField
4361    @GraphQLName("useType")
4362    static UseTypeObject useType(final DataFetchingEnvironment env,
4363            @GraphQLName("useTypeName") final String useTypeName,
4364            @GraphQLName("id") @GraphQLID final String id) {
4365        UseType useType;
4366
4367        try {
4368            var commandForm = OfferUtil.getHome().getGetUseTypeForm();
4369
4370            commandForm.setUseTypeName(useTypeName);
4371            commandForm.setUuid(id);
4372
4373            useType = CDI.current().select(GetUseTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4374        } catch (NamingException ex) {
4375            throw new RuntimeException(ex);
4376        }
4377
4378        return useType == null ? null : new UseTypeObject(useType);
4379    }
4380
4381    @GraphQLField
4382    @GraphQLName("useTypes")
4383    @GraphQLNonNull
4384    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4385    static CountingPaginatedData<UseTypeObject> useTypes(final DataFetchingEnvironment env) {
4386        CountingPaginatedData<UseTypeObject> data;
4387
4388        try {
4389            var commandForm = OfferUtil.getHome().getGetUseTypesForm();
4390            var command = CDI.current().select(GetUseTypesCommand.class).get();
4391
4392            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4393            if(totalEntities == null) {
4394                data = Connections.emptyConnection();
4395            } else {
4396                try(var objectLimiter = new ObjectLimiter(env, UseTypeConstants.COMPONENT_VENDOR_NAME, UseTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
4397                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4398
4399                    var useTypes = entities.stream()
4400                            .map(UseTypeObject::new)
4401                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4402
4403                    data = new CountedObjects<>(objectLimiter, useTypes);
4404                }
4405            }
4406        } catch (NamingException ex) {
4407            throw new RuntimeException(ex);
4408        }
4409
4410        return data;
4411    }
4412
4413    @GraphQLField
4414    @GraphQLName("freeOnBoard")
4415    static FreeOnBoardObject freeOnBoard(final DataFetchingEnvironment env,
4416            @GraphQLName("freeOnBoardName") final String freeOnBoardName,
4417            @GraphQLName("id") @GraphQLID final String id) {
4418        FreeOnBoard freeOnBoard;
4419
4420        try {
4421            var commandForm = ShipmentUtil.getHome().getGetFreeOnBoardForm();
4422
4423            commandForm.setFreeOnBoardName(freeOnBoardName);
4424            commandForm.setUuid(id);
4425
4426            freeOnBoard = CDI.current().select(GetFreeOnBoardCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4427        } catch (NamingException ex) {
4428            throw new RuntimeException(ex);
4429        }
4430
4431        return freeOnBoard == null ? null : new FreeOnBoardObject(freeOnBoard);
4432    }
4433
4434    @GraphQLField
4435    @GraphQLName("freeOnBoards")
4436    @GraphQLNonNull
4437    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4438    static CountingPaginatedData<FreeOnBoardObject> freeOnBoards(final DataFetchingEnvironment env) {
4439        CountingPaginatedData<FreeOnBoardObject> data;
4440
4441        try {
4442            var commandForm = ShipmentUtil.getHome().getGetFreeOnBoardsForm();
4443            var command = CDI.current().select(GetFreeOnBoardsCommand.class).get();
4444
4445            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4446            if(totalEntities == null) {
4447                data = Connections.emptyConnection();
4448            } else {
4449                try(var objectLimiter = new ObjectLimiter(env, FreeOnBoardConstants.COMPONENT_VENDOR_NAME, FreeOnBoardConstants.ENTITY_TYPE_NAME, totalEntities)) {
4450                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4451
4452                    var freeOnBoards = entities.stream()
4453                            .map(FreeOnBoardObject::new)
4454                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4455
4456                    data = new CountedObjects<>(objectLimiter, freeOnBoards);
4457                }
4458            }
4459        } catch (NamingException ex) {
4460            throw new RuntimeException(ex);
4461        }
4462
4463        return data;
4464    }
4465
4466    @GraphQLField
4467    @GraphQLName("paymentProcessorTypeCodeType")
4468    static PaymentProcessorTypeCodeTypeObject paymentProcessorTypeCodeType(final DataFetchingEnvironment env,
4469            @GraphQLName("paymentProcessorTypeName") final String paymentProcessorTypeName,
4470            @GraphQLName("paymentProcessorTypeCodeTypeName") final String paymentProcessorTypeCodeTypeName,
4471            @GraphQLName("id") @GraphQLID final String id) {
4472        PaymentProcessorTypeCodeType paymentProcessorTypeCodeType;
4473
4474        try {
4475            var commandForm = PaymentUtil.getHome().getGetPaymentProcessorTypeCodeTypeForm();
4476
4477            commandForm.setPaymentProcessorTypeName(paymentProcessorTypeName);
4478            commandForm.setPaymentProcessorTypeCodeTypeName(paymentProcessorTypeCodeTypeName);
4479            commandForm.setUuid(id);
4480
4481            paymentProcessorTypeCodeType = CDI.current().select(GetPaymentProcessorTypeCodeTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4482        } catch (NamingException ex) {
4483            throw new RuntimeException(ex);
4484        }
4485
4486        return paymentProcessorTypeCodeType == null ? null : new PaymentProcessorTypeCodeTypeObject(paymentProcessorTypeCodeType);
4487    }
4488
4489    @GraphQLField
4490    @GraphQLName("paymentProcessorTypeCode")
4491    static PaymentProcessorTypeCodeObject paymentProcessorTypeCode(final DataFetchingEnvironment env,
4492            @GraphQLName("paymentProcessorTypeName") final String paymentProcessorTypeName,
4493            @GraphQLName("paymentProcessorTypeCodeTypeName") final String paymentProcessorTypeCodeTypeName,
4494            @GraphQLName("paymentProcessorTypeCodeName") final String paymentProcessorTypeCodeName,
4495            @GraphQLName("id") @GraphQLID final String id) {
4496        PaymentProcessorTypeCode paymentProcessorTypeCode;
4497
4498        try {
4499            var commandForm = PaymentUtil.getHome().getGetPaymentProcessorTypeCodeForm();
4500
4501            commandForm.setPaymentProcessorTypeName(paymentProcessorTypeName);
4502            commandForm.setPaymentProcessorTypeCodeTypeName(paymentProcessorTypeCodeTypeName);
4503            commandForm.setPaymentProcessorTypeCodeName(paymentProcessorTypeCodeName);
4504            commandForm.setUuid(id);
4505
4506            paymentProcessorTypeCode = CDI.current().select(GetPaymentProcessorTypeCodeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4507        } catch (NamingException ex) {
4508            throw new RuntimeException(ex);
4509        }
4510
4511        return paymentProcessorTypeCode == null ? null : new PaymentProcessorTypeCodeObject(paymentProcessorTypeCode);
4512    }
4513
4514    @GraphQLField
4515    @GraphQLName("paymentProcessorTransaction")
4516    static PaymentProcessorTransactionObject paymentProcessorTransaction(final DataFetchingEnvironment env,
4517            @GraphQLName("paymentProcessorTransactionName") final String paymentProcessorTransactionName,
4518            @GraphQLName("id") @GraphQLID final String id) {
4519        PaymentProcessorTransaction paymentProcessorTransaction;
4520
4521        try {
4522            var commandForm = PaymentUtil.getHome().getGetPaymentProcessorTransactionForm();
4523
4524            commandForm.setPaymentProcessorTransactionName(paymentProcessorTransactionName);
4525            commandForm.setUuid(id);
4526
4527            paymentProcessorTransaction = CDI.current().select(GetPaymentProcessorTransactionCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4528        } catch (NamingException ex) {
4529            throw new RuntimeException(ex);
4530        }
4531
4532        return paymentProcessorTransaction == null ? null : new PaymentProcessorTransactionObject(paymentProcessorTransaction);
4533    }
4534
4535    @GraphQLField
4536    @GraphQLName("paymentProcessorTransactions")
4537    @GraphQLNonNull
4538    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4539    static CountingPaginatedData<PaymentProcessorTransactionObject> paymentProcessorTransactions(final DataFetchingEnvironment env) {
4540        CountingPaginatedData<PaymentProcessorTransactionObject> data;
4541
4542        try {
4543            var commandForm = PaymentUtil.getHome().getGetPaymentProcessorTransactionsForm();
4544            var command = CDI.current().select(GetPaymentProcessorTransactionsCommand.class).get();
4545
4546            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4547            if(totalEntities == null) {
4548                data = Connections.emptyConnection();
4549            } else {
4550                try(var objectLimiter = new ObjectLimiter(env, PaymentProcessorTransactionConstants.COMPONENT_VENDOR_NAME, PaymentProcessorTransactionConstants.ENTITY_TYPE_NAME, totalEntities)) {
4551                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4552
4553                    var paymentProcessorTransactions = entities.stream()
4554                            .map(PaymentProcessorTransactionObject::new)
4555                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4556
4557                    data = new CountedObjects<>(objectLimiter, paymentProcessorTransactions);
4558                }
4559            }
4560        } catch (NamingException ex) {
4561            throw new RuntimeException(ex);
4562        }
4563
4564        return data;
4565    }
4566
4567    @GraphQLField
4568    @GraphQLName("paymentProcessor")
4569    static PaymentProcessorObject paymentProcessor(final DataFetchingEnvironment env,
4570            @GraphQLName("paymentProcessorName") final String paymentProcessorName,
4571            @GraphQLName("id") @GraphQLID final String id) {
4572        PaymentProcessor paymentProcessor;
4573
4574        try {
4575            var commandForm = PaymentUtil.getHome().getGetPaymentProcessorForm();
4576
4577            commandForm.setPaymentProcessorName(paymentProcessorName);
4578            commandForm.setUuid(id);
4579
4580            paymentProcessor = CDI.current().select(GetPaymentProcessorCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4581        } catch (NamingException ex) {
4582            throw new RuntimeException(ex);
4583        }
4584
4585        return paymentProcessor == null ? null : new PaymentProcessorObject(paymentProcessor);
4586    }
4587
4588    @GraphQLField
4589    @GraphQLName("paymentProcessors")
4590    @GraphQLNonNull
4591    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4592    static CountingPaginatedData<PaymentProcessorObject> paymentProcessors(final DataFetchingEnvironment env) {
4593        CountingPaginatedData<PaymentProcessorObject> data;
4594
4595        try {
4596            var commandForm = PaymentUtil.getHome().getGetPaymentProcessorsForm();
4597            var command = CDI.current().select(GetPaymentProcessorsCommand.class).get();
4598
4599            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4600            if(totalEntities == null) {
4601                data = Connections.emptyConnection();
4602            } else {
4603                try(var objectLimiter = new ObjectLimiter(env, PaymentProcessorConstants.COMPONENT_VENDOR_NAME, PaymentProcessorConstants.ENTITY_TYPE_NAME, totalEntities)) {
4604                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4605
4606                    var paymentProcessors = entities.stream()
4607                            .map(PaymentProcessorObject::new)
4608                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4609
4610                    data = new CountedObjects<>(objectLimiter, paymentProcessors);
4611                }
4612            }
4613        } catch (NamingException ex) {
4614            throw new RuntimeException(ex);
4615        }
4616
4617        return data;
4618    }
4619
4620    @GraphQLField
4621    @GraphQLName("paymentProcessorType")
4622    static PaymentProcessorTypeObject paymentProcessorType(final DataFetchingEnvironment env,
4623            @GraphQLName("paymentProcessorTypeName") final String paymentProcessorTypeName,
4624            @GraphQLName("id") @GraphQLID final String id) {
4625        PaymentProcessorType paymentProcessorType;
4626
4627        try {
4628            var commandForm = PaymentUtil.getHome().getGetPaymentProcessorTypeForm();
4629
4630            commandForm.setPaymentProcessorTypeName(paymentProcessorTypeName);
4631            commandForm.setUuid(id);
4632
4633            paymentProcessorType = CDI.current().select(GetPaymentProcessorTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4634        } catch (NamingException ex) {
4635            throw new RuntimeException(ex);
4636        }
4637
4638        return paymentProcessorType == null ? null : new PaymentProcessorTypeObject(paymentProcessorType);
4639    }
4640
4641    @GraphQLField
4642    @GraphQLName("paymentProcessorTypes")
4643    @GraphQLNonNull
4644    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4645    static CountingPaginatedData<PaymentProcessorTypeObject> paymentProcessorTypes(final DataFetchingEnvironment env) {
4646        CountingPaginatedData<PaymentProcessorTypeObject> data;
4647
4648        try {
4649            var commandForm = PaymentUtil.getHome().getGetPaymentProcessorTypesForm();
4650            var command = CDI.current().select(GetPaymentProcessorTypesCommand.class).get();
4651
4652            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4653            if(totalEntities == null) {
4654                data = Connections.emptyConnection();
4655            } else {
4656                try(var objectLimiter = new ObjectLimiter(env, PaymentProcessorTypeConstants.COMPONENT_VENDOR_NAME, PaymentProcessorTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
4657                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4658
4659                    var paymentProcessorTypes = entities.stream()
4660                            .map(PaymentProcessorTypeObject::new)
4661                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4662
4663                    data = new CountedObjects<>(objectLimiter, paymentProcessorTypes);
4664                }
4665            }
4666        } catch (NamingException ex) {
4667            throw new RuntimeException(ex);
4668        }
4669
4670        return data;
4671    }
4672
4673    @GraphQLField
4674    @GraphQLName("paymentMethodType")
4675    static PaymentMethodTypeObject paymentMethodType(final DataFetchingEnvironment env,
4676            @GraphQLName("paymentMethodTypeName") final String paymentMethodTypeName,
4677            @GraphQLName("id") @GraphQLID final String id) {
4678        PaymentMethodType paymentMethodType;
4679
4680        try {
4681            var commandForm = PaymentUtil.getHome().getGetPaymentMethodTypeForm();
4682
4683            commandForm.setPaymentMethodTypeName(paymentMethodTypeName);
4684            commandForm.setUuid(id);
4685
4686            paymentMethodType = CDI.current().select(GetPaymentMethodTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4687        } catch (NamingException ex) {
4688            throw new RuntimeException(ex);
4689        }
4690
4691        return paymentMethodType == null ? null : new PaymentMethodTypeObject(paymentMethodType);
4692    }
4693
4694    @GraphQLField
4695    @GraphQLName("paymentMethodTypes")
4696    @GraphQLNonNull
4697    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4698    static CountingPaginatedData<PaymentMethodTypeObject> paymentMethodTypes(final DataFetchingEnvironment env) {
4699        CountingPaginatedData<PaymentMethodTypeObject> data;
4700
4701        try {
4702            var commandForm = PaymentUtil.getHome().getGetPaymentMethodTypesForm();
4703            var command = CDI.current().select(GetPaymentMethodTypesCommand.class).get();
4704
4705            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4706            if(totalEntities == null) {
4707                data = Connections.emptyConnection();
4708            } else {
4709                try(var objectLimiter = new ObjectLimiter(env, PaymentMethodTypeConstants.COMPONENT_VENDOR_NAME, PaymentMethodTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
4710                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4711
4712                    var paymentMethodTypes = entities.stream()
4713                            .map(PaymentMethodTypeObject::new)
4714                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4715
4716                    data = new CountedObjects<>(objectLimiter, paymentMethodTypes);
4717                }
4718            }
4719        } catch (NamingException ex) {
4720            throw new RuntimeException(ex);
4721        }
4722
4723        return data;
4724    }
4725
4726    @GraphQLField
4727    @GraphQLName("paymentMethod")
4728    static PaymentMethodObject paymentMethod(final DataFetchingEnvironment env,
4729            @GraphQLName("paymentMethodName") final String paymentMethodName) {
4730        PaymentMethod paymentMethod;
4731
4732        try {
4733            var commandForm = PaymentUtil.getHome().getGetPaymentMethodForm();
4734
4735            commandForm.setPaymentMethodName(paymentMethodName);
4736
4737            paymentMethod = CDI.current().select(GetPaymentMethodCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4738        } catch (NamingException ex) {
4739            throw new RuntimeException(ex);
4740        }
4741
4742        return paymentMethod == null ? null : new PaymentMethodObject(paymentMethod);
4743    }
4744
4745    @GraphQLField
4746    @GraphQLName("paymentMethods")
4747    @GraphQLNonNull
4748    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4749    static CountingPaginatedData<PaymentMethodObject> paymentMethods(final DataFetchingEnvironment env) {
4750        CountingPaginatedData<PaymentMethodObject> data;
4751
4752        try {
4753            var commandForm = PaymentUtil.getHome().getGetPaymentMethodsForm();
4754            var command = CDI.current().select(GetPaymentMethodsCommand.class).get();
4755
4756            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4757            if(totalEntities == null) {
4758                data = Connections.emptyConnection();
4759            } else {
4760                try(var objectLimiter = new ObjectLimiter(env, PaymentMethodConstants.COMPONENT_VENDOR_NAME, PaymentMethodConstants.ENTITY_TYPE_NAME, totalEntities)) {
4761                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4762
4763                    var paymentMethods = entities.stream()
4764                            .map(PaymentMethodObject::new)
4765                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4766
4767                    data = new CountedObjects<>(objectLimiter, paymentMethods);
4768                }
4769            }
4770        } catch (NamingException ex) {
4771            throw new RuntimeException(ex);
4772        }
4773
4774        return data;
4775    }
4776
4777    @GraphQLField
4778    @GraphQLName("paymentProcessorResultCode")
4779    static PaymentProcessorResultCodeObject paymentProcessorResultCode(final DataFetchingEnvironment env,
4780            @GraphQLName("paymentProcessorResultCodeName") final String paymentProcessorResultCodeName,
4781            @GraphQLName("id") @GraphQLID final String id) {
4782        PaymentProcessorResultCode paymentProcessorResultCode;
4783
4784        try {
4785            var commandForm = PaymentUtil.getHome().getGetPaymentProcessorResultCodeForm();
4786
4787            commandForm.setPaymentProcessorResultCodeName(paymentProcessorResultCodeName);
4788            commandForm.setUuid(id);
4789
4790            paymentProcessorResultCode = CDI.current().select(GetPaymentProcessorResultCodeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4791        } catch (NamingException ex) {
4792            throw new RuntimeException(ex);
4793        }
4794
4795        return paymentProcessorResultCode == null ? null : new PaymentProcessorResultCodeObject(paymentProcessorResultCode);
4796    }
4797
4798    @GraphQLField
4799    @GraphQLName("paymentProcessorResultCodes")
4800    @GraphQLNonNull
4801    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4802    static CountingPaginatedData<PaymentProcessorResultCodeObject> paymentProcessorResultCodes(final DataFetchingEnvironment env) {
4803        CountingPaginatedData<PaymentProcessorResultCodeObject> data;
4804
4805        try {
4806            var commandForm = PaymentUtil.getHome().getGetPaymentProcessorResultCodesForm();
4807            var command = CDI.current().select(GetPaymentProcessorResultCodesCommand.class).get();
4808
4809            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4810            if(totalEntities == null) {
4811                data = Connections.emptyConnection();
4812            } else {
4813                try(var objectLimiter = new ObjectLimiter(env, PaymentProcessorResultCodeConstants.COMPONENT_VENDOR_NAME, PaymentProcessorResultCodeConstants.ENTITY_TYPE_NAME, totalEntities)) {
4814                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4815                    var objects = entities.stream()
4816                            .map(PaymentProcessorResultCodeObject::new)
4817                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4818
4819                    data = new CountedObjects<>(objectLimiter, objects);
4820                }
4821            }
4822        } catch (NamingException ex) {
4823            throw new RuntimeException(ex);
4824        }
4825
4826        return data;
4827    }
4828
4829    @GraphQLField
4830    @GraphQLName("paymentProcessorActionType")
4831    static PaymentProcessorActionTypeObject paymentProcessorActionType(final DataFetchingEnvironment env,
4832            @GraphQLName("paymentProcessorActionTypeName") final String paymentProcessorActionTypeName,
4833            @GraphQLName("id") @GraphQLID final String id) {
4834        PaymentProcessorActionType paymentProcessorActionType;
4835
4836        try {
4837            var commandForm = PaymentUtil.getHome().getGetPaymentProcessorActionTypeForm();
4838
4839            commandForm.setPaymentProcessorActionTypeName(paymentProcessorActionTypeName);
4840            commandForm.setUuid(id);
4841
4842            paymentProcessorActionType = CDI.current().select(GetPaymentProcessorActionTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4843        } catch (NamingException ex) {
4844            throw new RuntimeException(ex);
4845        }
4846
4847        return paymentProcessorActionType == null ? null : new PaymentProcessorActionTypeObject(paymentProcessorActionType);
4848    }
4849
4850    @GraphQLField
4851    @GraphQLName("paymentProcessorActionTypes")
4852    @GraphQLNonNull
4853    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4854    static CountingPaginatedData<PaymentProcessorActionTypeObject> paymentProcessorActionTypes(final DataFetchingEnvironment env) {
4855        CountingPaginatedData<PaymentProcessorActionTypeObject> data;
4856
4857        try {
4858            var commandForm = PaymentUtil.getHome().getGetPaymentProcessorActionTypesForm();
4859            var command = CDI.current().select(GetPaymentProcessorActionTypesCommand.class).get();
4860
4861            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4862            if(totalEntities == null) {
4863                data = Connections.emptyConnection();
4864            } else {
4865                try(var objectLimiter = new ObjectLimiter(env, PaymentProcessorActionTypeConstants.COMPONENT_VENDOR_NAME, PaymentProcessorActionTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
4866                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4867                    var objects = entities.stream()
4868                            .map(PaymentProcessorActionTypeObject::new)
4869                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4870
4871                    data = new CountedObjects<>(objectLimiter, objects);
4872                }
4873            }
4874        } catch (NamingException ex) {
4875            throw new RuntimeException(ex);
4876        }
4877
4878        return data;
4879    }
4880
4881    @GraphQLField
4882    @GraphQLName("appearance")
4883    static AppearanceObject appearance(final DataFetchingEnvironment env,
4884            @GraphQLName("appearanceName") final String appearanceName,
4885            @GraphQLName("id") @GraphQLID final String id) {
4886        Appearance appearance;
4887
4888        try {
4889            var commandForm = CoreUtil.getHome().getGetAppearanceForm();
4890
4891            commandForm.setAppearanceName(appearanceName);
4892            commandForm.setUuid(id);
4893
4894            appearance = CDI.current().select(GetAppearanceCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4895        } catch (NamingException ex) {
4896            throw new RuntimeException(ex);
4897        }
4898
4899        return appearance == null ? null : new AppearanceObject(appearance);
4900    }
4901
4902    @GraphQLField
4903    @GraphQLName("appearances")
4904    @GraphQLNonNull
4905    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4906    static CountingPaginatedData<AppearanceObject> appearances(final DataFetchingEnvironment env) {
4907        CountingPaginatedData<AppearanceObject> data;
4908
4909        try {
4910            var commandForm = CoreUtil.getHome().getGetAppearancesForm();
4911            var command = CDI.current().select(GetAppearancesCommand.class).get();
4912
4913            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4914            if(totalEntities == null) {
4915                data = Connections.emptyConnection();
4916            } else {
4917                try(var objectLimiter = new ObjectLimiter(env, AppearanceConstants.COMPONENT_VENDOR_NAME, AppearanceConstants.ENTITY_TYPE_NAME, totalEntities)) {
4918                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4919
4920                    var appearances = entities.stream()
4921                            .map(AppearanceObject::new)
4922                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4923
4924                    data = new CountedObjects<>(objectLimiter, appearances);
4925                }
4926            }
4927        } catch (NamingException ex) {
4928            throw new RuntimeException(ex);
4929        }
4930
4931        return data;
4932    }
4933
4934    @GraphQLField
4935    @GraphQLName("eventType")
4936    static EventTypeObject eventType(final DataFetchingEnvironment env,
4937            @GraphQLName("eventTypeName") final String eventTypeName,
4938            @GraphQLName("id") @GraphQLID final String id) {
4939        EventType eventType;
4940
4941        try {
4942            var commandForm = CoreUtil.getHome().getGetEventTypeForm();
4943
4944            commandForm.setEventTypeName(eventTypeName);
4945            commandForm.setUuid(id);
4946
4947            eventType = CDI.current().select(GetEventTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
4948        } catch (NamingException ex) {
4949            throw new RuntimeException(ex);
4950        }
4951
4952        return eventType == null ? null : new EventTypeObject(eventType);
4953    }
4954
4955    @GraphQLField
4956    @GraphQLName("eventTypes")
4957    @GraphQLNonNull
4958    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4959    static CountingPaginatedData<EventTypeObject> eventTypes(final DataFetchingEnvironment env) {
4960        CountingPaginatedData<EventTypeObject> data;
4961
4962        try {
4963            var commandForm = CoreUtil.getHome().getGetEventTypesForm();
4964            var command = CDI.current().select(GetEventTypesCommand.class).get();
4965
4966            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4967            if(totalEntities == null) {
4968                data = Connections.emptyConnection();
4969            } else {
4970                try(var objectLimiter = new ObjectLimiter(env, EventTypeConstants.COMPONENT_VENDOR_NAME, EventTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
4971                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
4972
4973                    var eventTypes = entities.stream()
4974                            .map(EventTypeObject::new)
4975                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
4976
4977                    data = new CountedObjects<>(objectLimiter, eventTypes);
4978                }
4979            }
4980        } catch (NamingException ex) {
4981            throw new RuntimeException(ex);
4982        }
4983
4984        return data;
4985    }
4986
4987    @GraphQLField
4988    @GraphQLName("events")
4989    @GraphQLNonNull
4990    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
4991    static CountingPaginatedData<EventObject> events(final DataFetchingEnvironment env,
4992            @GraphQLName("id") final String id,
4993            @GraphQLName("createdById") final String createdById) {
4994        CountingPaginatedData<EventObject> data;
4995
4996        try {
4997            var commandForm = CoreUtil.getHome().getGetEventsForm();
4998            var command = CDI.current().select(GetEventsCommand.class).get();
4999
5000            commandForm.setUuid(id);
5001            commandForm.setCreatedByUuid(createdById);
5002
5003            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5004            if(totalEntities == null) {
5005                data = Connections.emptyConnection();
5006            } else {
5007                try(var objectLimiter = new ObjectLimiter(env, EventConstants.COMPONENT_VENDOR_NAME, EventConstants.ENTITY_TYPE_NAME, totalEntities)) {
5008                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5009
5010                    var events = entities.stream()
5011                            .map(EventObject::new)
5012                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
5013
5014                    data = new CountedObjects<>(objectLimiter, events);
5015                }
5016            }
5017        } catch (NamingException ex) {
5018            throw new RuntimeException(ex);
5019        }
5020
5021        return data;
5022    }
5023
5024    @GraphQLField
5025    @GraphQLName("entityAliasType")
5026    static EntityAliasTypeObject entityAliasType(final DataFetchingEnvironment env,
5027            @GraphQLName("componentVendorName") final String componentVendorName,
5028            @GraphQLName("entityTypeName") final String entityTypeName,
5029            @GraphQLName("entityAliasTypeName") final String entityAliasTypeName,
5030            @GraphQLName("id") @GraphQLID final String id) {
5031        EntityAliasType entityAliasType;
5032
5033        try {
5034            var commandForm = CoreUtil.getHome().getGetEntityAliasTypeForm();
5035
5036            commandForm.setComponentVendorName(componentVendorName);
5037            commandForm.setEntityTypeName(entityTypeName);
5038            commandForm.setEntityAliasTypeName(entityAliasTypeName);
5039            commandForm.setUuid(id);
5040
5041            entityAliasType = CDI.current().select(GetEntityAliasTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
5042        } catch (NamingException ex) {
5043            throw new RuntimeException(ex);
5044        }
5045
5046        return entityAliasType == null ? null : new EntityAliasTypeObject(entityAliasType, null);
5047    }
5048
5049    @GraphQLField
5050    @GraphQLName("entityAliasTypes")
5051    @GraphQLNonNull
5052    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
5053    static CountingPaginatedData<EntityAliasTypeObject> entityAliasTypes(final DataFetchingEnvironment env,
5054            @GraphQLName("componentVendorName") final String componentVendorName,
5055            @GraphQLName("entityTypeName") final String entityTypeName,
5056            @GraphQLName("id") @GraphQLID final String id) {
5057        CountingPaginatedData<EntityAliasTypeObject> data;
5058
5059        try {
5060            var commandForm = CoreUtil.getHome().getGetEntityAliasTypesForm();
5061            var command = CDI.current().select(GetEntityAliasTypesCommand.class).get();
5062
5063            commandForm.setComponentVendorName(componentVendorName);
5064            commandForm.setEntityTypeName(entityTypeName);
5065            commandForm.setUuid(id);
5066
5067            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5068            if(totalEntities == null) {
5069                data = Connections.emptyConnection();
5070            } else {
5071                try(var objectLimiter = new ObjectLimiter(env, EntityAliasTypeConstants.COMPONENT_VENDOR_NAME, EntityAliasTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
5072                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5073
5074                    var entityAliasTypes = entities.stream()
5075                            .map(entityAliasType -> new EntityAliasTypeObject(entityAliasType, null))
5076                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
5077
5078                    data = new CountedObjects<>(objectLimiter, entityAliasTypes);
5079                }
5080            }
5081        } catch (NamingException ex) {
5082            throw new RuntimeException(ex);
5083        }
5084
5085        return data;
5086    }
5087
5088    @GraphQLField
5089    @GraphQLName("entityAlias")
5090    static EntityAliasObject entityAlias(final DataFetchingEnvironment env,
5091            @GraphQLName("componentVendorName") final String componentVendorName,
5092            @GraphQLName("entityTypeName") final String entityTypeName,
5093            @GraphQLName("entityAliasTypeName") final String entityAliasTypeName,
5094            @GraphQLName("id") @GraphQLID final String id,
5095            @GraphQLName("alias") @GraphQLNonNull final String alias) {
5096        EntityAlias entityAlias;
5097
5098        try {
5099            var commandForm = CoreUtil.getHome().getGetEntityAliasForm();
5100
5101            commandForm.setComponentVendorName(componentVendorName);
5102            commandForm.setEntityTypeName(entityTypeName);
5103            commandForm.setEntityAliasTypeName(entityAliasTypeName);
5104            commandForm.setUuid(id);
5105            commandForm.setAlias(alias);
5106
5107            entityAlias = CDI.current().select(GetEntityAliasCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
5108        } catch (NamingException ex) {
5109            throw new RuntimeException(ex);
5110        }
5111
5112        return entityAlias == null ? null : new EntityAliasObject(entityAlias);
5113    }
5114
5115    @GraphQLField
5116    @GraphQLName("entityAliases")
5117    @GraphQLNonNull
5118    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
5119    static CountingPaginatedData<EntityAliasObject> entityAliases(final DataFetchingEnvironment env,
5120            @GraphQLName("componentVendorName") final String componentVendorName,
5121            @GraphQLName("entityTypeName") final String entityTypeName,
5122            @GraphQLName("entityAliasTypeName") final String entityAliasTypeName,
5123            @GraphQLName("id") @GraphQLID final String id) {
5124        CountingPaginatedData<EntityAliasObject> data;
5125
5126        try {
5127            var commandForm = CoreUtil.getHome().getGetEntityAliasesForm();
5128            var command = CDI.current().select(GetEntityAliasesCommand.class).get();
5129
5130            commandForm.setComponentVendorName(componentVendorName);
5131            commandForm.setEntityTypeName(entityTypeName);
5132            commandForm.setEntityAliasTypeName(entityAliasTypeName);
5133            commandForm.setUuid(id);
5134
5135            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5136            if(totalEntities == null) {
5137                data = Connections.emptyConnection();
5138            } else {
5139                try(var objectLimiter = new ObjectLimiter(env, EntityAliasConstants.COMPONENT_VENDOR_NAME, EntityAliasConstants.ENTITY_TYPE_NAME, totalEntities)) {
5140                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5141
5142                    var entityAliases = entities.stream()
5143                            .map(EntityAliasObject::new)
5144                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
5145
5146                    data = new CountedObjects<>(objectLimiter, entityAliases);
5147                }
5148            }
5149        } catch (NamingException ex) {
5150            throw new RuntimeException(ex);
5151        }
5152
5153        return data;
5154    }
5155
5156
5157    @GraphQLField
5158    @GraphQLName("entityAttributeGroup")
5159    static EntityAttributeGroupObject entityAttributeGroup(final DataFetchingEnvironment env,
5160            @GraphQLName("componentVendorName") final String componentVendorName,
5161            @GraphQLName("entityTypeName") final String entityTypeName,
5162            @GraphQLName("entityAttributeGroupName") final String entityAttributeGroupName,
5163            @GraphQLName("id") @GraphQLID final String id) {
5164        EntityAttributeGroup entityAttributeGroup;
5165
5166        try {
5167            var commandForm = CoreUtil.getHome().getGetEntityAttributeGroupForm();
5168            commandForm.setComponentVendorName(componentVendorName);
5169            commandForm.setEntityTypeName(entityTypeName);
5170
5171            commandForm.setEntityAttributeGroupName(entityAttributeGroupName);
5172            commandForm.setUuid(id);
5173
5174            entityAttributeGroup = CDI.current().select(GetEntityAttributeGroupCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
5175        } catch (NamingException ex) {
5176            throw new RuntimeException(ex);
5177        }
5178
5179        return entityAttributeGroup == null ? null : new EntityAttributeGroupObject(entityAttributeGroup, null);
5180    }
5181
5182    @GraphQLField
5183    @GraphQLName("entityAttributeGroups")
5184    @GraphQLNonNull
5185    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
5186    static CountingPaginatedData<EntityAttributeGroupObject> entityAttributeGroups(final DataFetchingEnvironment env,
5187            @GraphQLName("componentVendorName") @GraphQLNonNull final String componentVendorName,
5188            @GraphQLName("entityTypeName") @GraphQLNonNull final String entityTypeName) {
5189        CountingPaginatedData<EntityAttributeGroupObject> data;
5190
5191        try {
5192            var commandForm = CoreUtil.getHome().getGetEntityAttributeGroupsForm();
5193            var command = CDI.current().select(GetEntityAttributeGroupsCommand.class).get();
5194
5195            commandForm.setComponentVendorName(componentVendorName);
5196            commandForm.setEntityTypeName(entityTypeName);
5197
5198            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5199            if(totalEntities == null) {
5200                data = Connections.emptyConnection();
5201            } else {
5202                try(var objectLimiter = new ObjectLimiter(env, EntityAttributeGroupConstants.COMPONENT_VENDOR_NAME, EntityAttributeGroupConstants.ENTITY_TYPE_NAME, totalEntities)) {
5203                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5204
5205                    var entityAttributeGroups = entities.stream()
5206                            .map(entityAttributeGroup -> new EntityAttributeGroupObject(entityAttributeGroup, null))
5207                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
5208
5209                    data = new CountedObjects<>(objectLimiter, entityAttributeGroups);
5210                }
5211            }
5212        } catch (NamingException ex) {
5213            throw new RuntimeException(ex);
5214        }
5215
5216        return data;
5217    }
5218
5219    @GraphQLField
5220    @GraphQLName("entityAttribute")
5221    static EntityAttributeObject entityAttribute(final DataFetchingEnvironment env,
5222            @GraphQLName("componentVendorName") final String componentVendorName,
5223            @GraphQLName("entityTypeName") final String entityTypeName,
5224            @GraphQLName("entityAttributeName") final String entityAttributeName,
5225            @GraphQLName("id") @GraphQLID final String id) {
5226        EntityAttribute entityAttribute;
5227
5228        try {
5229            var commandForm = CoreUtil.getHome().getGetEntityAttributeForm();
5230
5231            commandForm.setComponentVendorName(componentVendorName);
5232            commandForm.setEntityTypeName(entityTypeName);
5233            commandForm.setEntityAttributeName(entityAttributeName);
5234            commandForm.setUuid(id);
5235
5236            entityAttribute = CDI.current().select(GetEntityAttributeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
5237        } catch (NamingException ex) {
5238            throw new RuntimeException(ex);
5239        }
5240
5241        return entityAttribute == null ? null : new EntityAttributeObject(entityAttribute, null);
5242    }
5243
5244    @GraphQLField
5245    @GraphQLName("entityAttributes")
5246    @GraphQLNonNull
5247    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
5248    static CountingPaginatedData<EntityAttributeObject> entityAttributes(final DataFetchingEnvironment env,
5249            @GraphQLName("componentVendorName") final String componentVendorName,
5250            @GraphQLName("entityTypeName") final String entityTypeName,
5251            @GraphQLName("entityAttributeTypeNames") final String entityAttributeTypeNames,
5252            @GraphQLName("id") @GraphQLID final String id) {
5253        CountingPaginatedData<EntityAttributeObject> data;
5254
5255        try {
5256            var commandForm = CoreUtil.getHome().getGetEntityAttributesForm();
5257            var command = CDI.current().select(GetEntityAttributesCommand.class).get();
5258
5259            commandForm.setComponentVendorName(componentVendorName);
5260            commandForm.setEntityTypeName(entityTypeName);
5261            commandForm.setEntityAttributeTypeNames(entityAttributeTypeNames);
5262            commandForm.setUuid(id);
5263
5264            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5265            if(totalEntities == null) {
5266                data = Connections.emptyConnection();
5267            } else {
5268                try(var objectLimiter = new ObjectLimiter(env, EntityAttributeConstants.COMPONENT_VENDOR_NAME, EntityAttributeConstants.ENTITY_TYPE_NAME, totalEntities)) {
5269                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5270
5271                    var entityAttributes = entities.stream()
5272                            .map(entityAttribute -> new EntityAttributeObject(entityAttribute, null))
5273                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
5274
5275                    data = new CountedObjects<>(objectLimiter, entityAttributes);
5276                }
5277            }
5278        } catch (NamingException ex) {
5279            throw new RuntimeException(ex);
5280        }
5281
5282        return data;
5283    }
5284
5285    @GraphQLField
5286    @GraphQLName("entityAttributeEntityAttributeGroup")
5287    static EntityAttributeEntityAttributeGroupObject entityAttributeEntityAttributeGroup(final DataFetchingEnvironment env,
5288            @GraphQLName("componentVendorName") @GraphQLNonNull final String componentVendorName,
5289            @GraphQLName("entityTypeName") @GraphQLNonNull final String entityTypeName,
5290            @GraphQLName("entityAttributeName") @GraphQLNonNull final String entityAttributeName,
5291            @GraphQLName("entityAttributeGroupName") @GraphQLNonNull final String entityAttributeGroupName) {
5292        EntityAttributeEntityAttributeGroup entityAttributeEntityAttributeGroup;
5293
5294        try {
5295            var commandForm = CoreUtil.getHome().getGetEntityAttributeEntityAttributeGroupForm();
5296
5297            commandForm.setComponentVendorName(componentVendorName);
5298            commandForm.setEntityTypeName(entityTypeName);
5299            commandForm.setEntityAttributeName(entityAttributeName);
5300            commandForm.setEntityAttributeGroupName(entityAttributeGroupName);
5301
5302            entityAttributeEntityAttributeGroup = CDI.current().select(GetEntityAttributeEntityAttributeGroupCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
5303        } catch (NamingException ex) {
5304            throw new RuntimeException(ex);
5305        }
5306
5307        return entityAttributeEntityAttributeGroup == null ? null : new EntityAttributeEntityAttributeGroupObject(entityAttributeEntityAttributeGroup);
5308    }
5309
5310    @GraphQLField
5311    @GraphQLName("entityAttributeEntityAttributeGroups")
5312    @GraphQLNonNull
5313    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
5314    static CountingPaginatedData<EntityAttributeEntityAttributeGroupObject> entityAttributeEntityAttributeGroups(final DataFetchingEnvironment env,
5315            @GraphQLName("componentVendorName") @GraphQLNonNull final String componentVendorName,
5316            @GraphQLName("entityTypeName") @GraphQLNonNull final String entityTypeName,
5317            @GraphQLName("entityAttributeName") final String entityAttributeName,
5318            @GraphQLName("entityAttributeGroupName") final String entityAttributeGroupName) {
5319        CountingPaginatedData<EntityAttributeEntityAttributeGroupObject> data;
5320
5321        try {
5322            var commandForm = CoreUtil.getHome().getGetEntityAttributeEntityAttributeGroupsForm();
5323            var command = CDI.current().select(GetEntityAttributeEntityAttributeGroupsCommand.class).get();
5324
5325            commandForm.setComponentVendorName(componentVendorName);
5326            commandForm.setEntityTypeName(entityTypeName);
5327            commandForm.setEntityAttributeName(entityAttributeName);
5328            commandForm.setEntityAttributeGroupName(entityAttributeGroupName);
5329
5330            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5331            if(totalEntities == null) {
5332                data = Connections.emptyConnection();
5333            } else {
5334                try(var objectLimiter = new ObjectLimiter(env, EntityAttributeEntityAttributeGroupConstants.COMPONENT_VENDOR_NAME, EntityAttributeEntityAttributeGroupConstants.ENTITY_TYPE_NAME, totalEntities)) {
5335                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5336
5337                    var entityAttributeEntityAttributeGroups = entities.stream()
5338                            .map(EntityAttributeEntityAttributeGroupObject::new)
5339                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
5340
5341                    data = new CountedObjects<>(objectLimiter, entityAttributeEntityAttributeGroups);
5342                }
5343            }
5344        } catch (NamingException ex) {
5345            throw new RuntimeException(ex);
5346        }
5347
5348        return data;
5349    }
5350
5351    @GraphQLField
5352    @GraphQLName("entityInstance")
5353    static EntityInstanceObject entityInstance(final DataFetchingEnvironment env,
5354            @GraphQLName("id") @GraphQLID @GraphQLNonNull final String id) {
5355        EntityInstance entityInstance;
5356
5357        try {
5358            var commandForm = CoreUtil.getHome().getGetEntityInstanceForm();
5359
5360            commandForm.setUuid(id);
5361
5362            entityInstance = CDI.current().select(GetEntityInstanceCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
5363        } catch (NamingException ex) {
5364            throw new RuntimeException(ex);
5365        }
5366
5367        return entityInstance == null ? null : new EntityInstanceObject(entityInstance);
5368    }
5369
5370    @GraphQLField
5371    @GraphQLName("entityInstances")
5372    @GraphQLNonNull
5373    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
5374    static CountingPaginatedData<EntityInstanceObject> entityInstances(final DataFetchingEnvironment env,
5375            @GraphQLName("componentVendorName") @GraphQLNonNull final String componentVendorName,
5376            @GraphQLName("entityTypeName") @GraphQLNonNull final String entityTypeName) {
5377        CountingPaginatedData<EntityInstanceObject> data;
5378
5379        try {
5380            var commandForm = CoreUtil.getHome().getGetEntityInstancesForm();
5381            var command = CDI.current().select(GetEntityInstancesCommand.class).get();
5382
5383            commandForm.setComponentVendorName(componentVendorName);
5384            commandForm.setEntityTypeName(entityTypeName);
5385
5386            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5387            if(totalEntities == null) {
5388                data = Connections.emptyConnection();
5389            } else {
5390                try(var objectLimiter = new ObjectLimiter(env, EntityInstanceConstants.COMPONENT_VENDOR_NAME, EntityInstanceConstants.ENTITY_TYPE_NAME, totalEntities)) {
5391                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5392
5393                    var entityInstances = entities.stream()
5394                            .map(EntityInstanceObject::new)
5395                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
5396
5397                    data = new CountedObjects<>(objectLimiter, entityInstances);
5398                }
5399            }
5400        } catch (NamingException ex) {
5401            throw new RuntimeException(ex);
5402        }
5403
5404        return data;
5405    }
5406
5407    @GraphQLField
5408    @GraphQLName("entityType")
5409    static EntityTypeObject entityType(final DataFetchingEnvironment env,
5410            @GraphQLName("componentVendorName") final String componentVendorName,
5411            @GraphQLName("entityTypeName") final String entityTypeName,
5412            @GraphQLName("id") @GraphQLID final String id) {
5413        EntityType entityType;
5414
5415        try {
5416            var commandForm = CoreUtil.getHome().getGetEntityTypeForm();
5417
5418            commandForm.setComponentVendorName(componentVendorName);
5419            commandForm.setEntityTypeName(entityTypeName);
5420            commandForm.setUuid(id);
5421
5422            entityType = CDI.current().select(GetEntityTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
5423        } catch (NamingException ex) {
5424            throw new RuntimeException(ex);
5425        }
5426
5427        return entityType == null ? null : new EntityTypeObject(entityType);
5428    }
5429
5430    @GraphQLField
5431    @GraphQLName("entityTypes")
5432    @GraphQLNonNull
5433    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
5434    static CountingPaginatedData<EntityTypeObject> entityTypes(final DataFetchingEnvironment env,
5435            @GraphQLName("componentVendorName") final String componentVendorName) {
5436        CountingPaginatedData<EntityTypeObject> data;
5437
5438        try {
5439            var commandForm = CoreUtil.getHome().getGetEntityTypesForm();
5440            var command = CDI.current().select(GetEntityTypesCommand.class).get();
5441
5442            commandForm.setComponentVendorName(componentVendorName);
5443
5444            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5445            if(totalEntities == null) {
5446                data = Connections.emptyConnection();
5447            } else {
5448                try(var objectLimiter = new ObjectLimiter(env, EntityTypeConstants.COMPONENT_VENDOR_NAME, EntityTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
5449                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5450
5451                    var entityTypes = entities.stream()
5452                            .map(EntityTypeObject::new)
5453                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
5454
5455                    data = new CountedObjects<>(objectLimiter, entityTypes);
5456                }
5457            }
5458        } catch (NamingException ex) {
5459            throw new RuntimeException(ex);
5460        }
5461
5462        return data;
5463    }
5464
5465    @GraphQLField
5466    @GraphQLName("componentVendor")
5467    static ComponentVendorObject componentVendor(final DataFetchingEnvironment env,
5468            @GraphQLName("componentVendorName") final String componentVendorName,
5469            @GraphQLName("id") @GraphQLID final String id) {
5470        ComponentVendor componentVendor;
5471
5472        try {
5473            var commandForm = CoreUtil.getHome().getGetComponentVendorForm();
5474
5475            commandForm.setComponentVendorName(componentVendorName);
5476            commandForm.setUuid(id);
5477
5478            componentVendor = CDI.current().select(GetComponentVendorCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
5479        } catch (NamingException ex) {
5480            throw new RuntimeException(ex);
5481        }
5482
5483        return componentVendor == null ? null : new ComponentVendorObject(componentVendor);
5484    }
5485
5486    @GraphQLField
5487    @GraphQLName("componentVendors")
5488    @GraphQLNonNull
5489    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
5490    static CountingPaginatedData<ComponentVendorObject> componentVendors(final DataFetchingEnvironment env) {
5491        CountingPaginatedData<ComponentVendorObject> data;
5492
5493        try {
5494            var commandForm = CoreUtil.getHome().getGetComponentVendorsForm();
5495            var command = CDI.current().select(GetComponentVendorsCommand.class).get();
5496
5497            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5498            if(totalEntities == null) {
5499                data = Connections.emptyConnection();
5500            } else {
5501                try(var objectLimiter = new ObjectLimiter(env, ComponentVendorConstants.COMPONENT_VENDOR_NAME, ComponentVendorConstants.ENTITY_TYPE_NAME, totalEntities)) {
5502                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5503
5504                    var componentVendors = entities.stream()
5505                            .map(ComponentVendorObject::new)
5506                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
5507
5508                    data = new CountedObjects<>(objectLimiter, componentVendors);
5509                }
5510            }
5511        } catch (NamingException ex) {
5512            throw new RuntimeException(ex);
5513        }
5514
5515        return data;
5516    }
5517
5518    @GraphQLField
5519    @GraphQLName("inventoryCondition")
5520    static InventoryConditionObject inventoryCondition(final DataFetchingEnvironment env,
5521            @GraphQLName("inventoryConditionName") final String inventoryConditionName,
5522            @GraphQLName("id") @GraphQLID final String id) {
5523        InventoryCondition inventoryCondition;
5524
5525        try {
5526            var commandForm = InventoryUtil.getHome().getGetInventoryConditionForm();
5527
5528            commandForm.setInventoryConditionName(inventoryConditionName);
5529            commandForm.setUuid(id);
5530
5531            inventoryCondition = CDI.current().select(GetInventoryConditionCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
5532        } catch (NamingException ex) {
5533            throw new RuntimeException(ex);
5534        }
5535
5536        return inventoryCondition == null ? null : new InventoryConditionObject(inventoryCondition);
5537    }
5538
5539    @GraphQLField
5540    @GraphQLName("inventoryConditions")
5541    @GraphQLNonNull
5542    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
5543    static CountingPaginatedData<InventoryConditionObject> inventoryConditions(final DataFetchingEnvironment env) {
5544        CountingPaginatedData<InventoryConditionObject> data;
5545
5546        try {
5547            var commandForm = InventoryUtil.getHome().getGetInventoryConditionsForm();
5548            var command = CDI.current().select(GetInventoryConditionsCommand.class).get();
5549
5550            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5551            if(totalEntities == null) {
5552                data = Connections.emptyConnection();
5553            } else {
5554                try(var objectLimiter = new ObjectLimiter(env, InventoryConditionConstants.COMPONENT_VENDOR_NAME, InventoryConditionConstants.ENTITY_TYPE_NAME, totalEntities)) {
5555                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5556
5557                    var inventoryConditions = entities.stream()
5558                            .map(InventoryConditionObject::new)
5559                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
5560
5561                    data = new CountedObjects<>(objectLimiter, inventoryConditions);
5562                }
5563            }
5564        } catch (NamingException ex) {
5565            throw new RuntimeException(ex);
5566        }
5567
5568        return data;
5569    }
5570
5571    @GraphQLField
5572    @GraphQLName("allocationPriority")
5573    static AllocationPriorityObject allocationPriority(final DataFetchingEnvironment env,
5574            @GraphQLName("allocationPriorityName") final String allocationPriorityName,
5575            @GraphQLName("id") @GraphQLID final String id) {
5576        AllocationPriority allocationPriority;
5577
5578        try {
5579            var commandForm = InventoryUtil.getHome().getGetAllocationPriorityForm();
5580
5581            commandForm.setAllocationPriorityName(allocationPriorityName);
5582            commandForm.setUuid(id);
5583
5584            allocationPriority = CDI.current().select(GetAllocationPriorityCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
5585        } catch (NamingException ex) {
5586            throw new RuntimeException(ex);
5587        }
5588
5589        return allocationPriority == null ? null : new AllocationPriorityObject(allocationPriority);
5590    }
5591
5592    @GraphQLField
5593    @GraphQLName("allocationPriorities")
5594    @GraphQLNonNull
5595    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
5596    static CountingPaginatedData<AllocationPriorityObject> allocationPriorities(final DataFetchingEnvironment env) {
5597        CountingPaginatedData<AllocationPriorityObject> data;
5598
5599        try {
5600            var commandForm = InventoryUtil.getHome().getGetAllocationPrioritiesForm();
5601            var command = CDI.current().select(GetAllocationPrioritiesCommand.class).get();
5602
5603            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5604            if(totalEntities == null) {
5605                data = Connections.emptyConnection();
5606            } else {
5607                try(var objectLimiter = new ObjectLimiter(env, AllocationPriorityConstants.COMPONENT_VENDOR_NAME, AllocationPriorityConstants.ENTITY_TYPE_NAME, totalEntities)) {
5608                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5609
5610                    var allocationPriorities = entities.stream()
5611                            .map(AllocationPriorityObject::new)
5612                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
5613
5614                    data = new CountedObjects<>(objectLimiter, allocationPriorities);
5615                }
5616            }
5617        } catch (NamingException ex) {
5618            throw new RuntimeException(ex);
5619        }
5620
5621        return data;
5622    }
5623
5624    @GraphQLField
5625    @GraphQLName("inventoryTransactionType")
5626    static InventoryTransactionTypeObject inventoryTransactionType(final DataFetchingEnvironment env,
5627            @GraphQLName("inventoryTransactionTypeName") final String inventoryTransactionTypeName,
5628            @GraphQLName("id") @GraphQLID final String id) {
5629        InventoryTransactionType inventoryTransactionType;
5630
5631        try {
5632            var commandForm = InventoryUtil.getHome().getGetInventoryTransactionTypeForm();
5633
5634            commandForm.setInventoryTransactionTypeName(inventoryTransactionTypeName);
5635            commandForm.setUuid(id);
5636
5637            inventoryTransactionType = CDI.current().select(GetInventoryTransactionTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
5638        } catch (NamingException ex) {
5639            throw new RuntimeException(ex);
5640        }
5641
5642        return inventoryTransactionType == null ? null : new InventoryTransactionTypeObject(inventoryTransactionType);
5643    }
5644
5645    @GraphQLField
5646    @GraphQLName("inventoryTransactionTypes")
5647    @GraphQLNonNull
5648    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
5649    static CountingPaginatedData<InventoryTransactionTypeObject> inventoryTransactionTypes(final DataFetchingEnvironment env) {
5650        CountingPaginatedData<InventoryTransactionTypeObject> data;
5651
5652        try {
5653            var commandForm = InventoryUtil.getHome().getGetInventoryTransactionTypesForm();
5654            var command = CDI.current().select(GetInventoryTransactionTypesCommand.class).get();
5655
5656            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5657            if(totalEntities == null) {
5658                data = Connections.emptyConnection();
5659            } else {
5660                try(var objectLimiter = new ObjectLimiter(env, InventoryTransactionTypeConstants.COMPONENT_VENDOR_NAME, InventoryTransactionTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
5661                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5662
5663                    var inventoryTransactionTypes = entities.stream()
5664                            .map(InventoryTransactionTypeObject::new)
5665                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
5666
5667                    data = new CountedObjects<>(objectLimiter, inventoryTransactionTypes);
5668                }
5669            }
5670        } catch (NamingException ex) {
5671            throw new RuntimeException(ex);
5672        }
5673
5674        return data;
5675    }
5676
5677    @GraphQLField
5678    @GraphQLName("inventoryTransactionTimeType")
5679    static InventoryTransactionTimeTypeObject inventoryTransactionTimeType(final DataFetchingEnvironment env,
5680            @GraphQLName("inventoryTransactionTypeName") final String inventoryTransactionTypeName,
5681            @GraphQLName("inventoryTransactionTimeTypeName") final String inventoryTransactionTimeTypeName,
5682            @GraphQLName("id") @GraphQLID final String id) {
5683        InventoryTransactionTimeType inventoryTransactionTimeType;
5684
5685        try {
5686            var commandForm = InventoryUtil.getHome().getGetInventoryTransactionTimeTypeForm();
5687
5688            commandForm.setInventoryTransactionTypeName(inventoryTransactionTypeName);
5689            commandForm.setInventoryTransactionTimeTypeName(inventoryTransactionTimeTypeName);
5690            commandForm.setUuid(id);
5691
5692            inventoryTransactionTimeType = 
5693                    CDI.current().select(GetInventoryTransactionTimeTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
5694        } catch (NamingException ex) {
5695            throw new RuntimeException(ex);
5696        }
5697
5698        return inventoryTransactionTimeType == null ? null : new InventoryTransactionTimeTypeObject(inventoryTransactionTimeType);
5699    }
5700
5701    @GraphQLField
5702    @GraphQLName("inventoryTransactionTimeTypes")
5703    @GraphQLNonNull
5704    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
5705    static CountingPaginatedData<InventoryTransactionTimeTypeObject> inventoryTransactionTimeTypes(final DataFetchingEnvironment env,
5706            @GraphQLName("inventoryTransactionTypeName") @GraphQLNonNull final String inventoryTransactionTypeName) {
5707        CountingPaginatedData<InventoryTransactionTimeTypeObject> data;
5708
5709        try {
5710            var commandForm = InventoryUtil.getHome().getGetInventoryTransactionTimeTypesForm();
5711            var command = CDI.current().select(GetInventoryTransactionTimeTypesCommand.class).get();
5712
5713            commandForm.setInventoryTransactionTypeName(inventoryTransactionTypeName);
5714
5715            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5716            if(totalEntities == null) {
5717                data = Connections.emptyConnection();
5718            } else {
5719                try(var objectLimiter = new ObjectLimiter(env, InventoryTransactionTimeTypeConstants.COMPONENT_VENDOR_NAME,
5720                        InventoryTransactionTimeTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
5721                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5722
5723                    var inventoryTransactionTimeTypes = entities.stream()
5724                            .map(InventoryTransactionTimeTypeObject::new)
5725                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
5726
5727                    data = new CountedObjects<>(objectLimiter, inventoryTransactionTimeTypes);
5728                }
5729            }
5730        } catch (NamingException ex) {
5731            throw new RuntimeException(ex);
5732        }
5733
5734        return data;
5735    }
5736
5737    @GraphQLField
5738    @GraphQLName("inventoryDisposition")
5739    static InventoryDispositionObject inventoryDisposition(final DataFetchingEnvironment env,
5740            @GraphQLName("inventoryTransactionTypeName") final String inventoryTransactionTypeName,
5741            @GraphQLName("inventoryDispositionName") final String inventoryDispositionName,
5742            @GraphQLName("id") @GraphQLID final String id) {
5743        InventoryDisposition inventoryDisposition;
5744
5745        try {
5746            var commandForm = InventoryUtil.getHome().getGetInventoryDispositionForm();
5747
5748            commandForm.setInventoryTransactionTypeName(inventoryTransactionTypeName);
5749            commandForm.setInventoryDispositionName(inventoryDispositionName);
5750            commandForm.setUuid(id);
5751
5752            inventoryDisposition = 
5753                    CDI.current().select(GetInventoryDispositionCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
5754        } catch (NamingException ex) {
5755            throw new RuntimeException(ex);
5756        }
5757
5758        return inventoryDisposition == null ? null : new InventoryDispositionObject(inventoryDisposition);
5759    }
5760
5761    @GraphQLField
5762    @GraphQLName("inventoryDispositions")
5763    @GraphQLNonNull
5764    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
5765    static CountingPaginatedData<InventoryDispositionObject> inventoryDispositions(final DataFetchingEnvironment env,
5766            @GraphQLName("inventoryTransactionTypeName") @GraphQLNonNull final String inventoryTransactionTypeName) {
5767        CountingPaginatedData<InventoryDispositionObject> data;
5768
5769        try {
5770            var commandForm = InventoryUtil.getHome().getGetInventoryDispositionsForm();
5771            var command = CDI.current().select(GetInventoryDispositionsCommand.class).get();
5772
5773            commandForm.setInventoryTransactionTypeName(inventoryTransactionTypeName);
5774
5775            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5776            if(totalEntities == null) {
5777                data = Connections.emptyConnection();
5778            } else {
5779                try(var objectLimiter = new ObjectLimiter(env, InventoryDispositionConstants.COMPONENT_VENDOR_NAME,
5780                        InventoryDispositionConstants.ENTITY_TYPE_NAME, totalEntities)) {
5781                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5782
5783                    var inventoryDispositions = entities.stream()
5784                            .map(InventoryDispositionObject::new)
5785                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
5786
5787                    data = new CountedObjects<>(objectLimiter, inventoryDispositions);
5788                }
5789            }
5790        } catch (NamingException ex) {
5791            throw new RuntimeException(ex);
5792        }
5793
5794        return data;
5795    }
5796
5797    @GraphQLField
5798    @GraphQLName("inventoryDispositionAdjustment")
5799    static InventoryDispositionAdjustmentObject inventoryDispositionAdjustment(final DataFetchingEnvironment env,
5800            @GraphQLName("inventoryTransactionTypeName") final String inventoryTransactionTypeName,
5801            @GraphQLName("inventoryDispositionName") final String inventoryDispositionName,
5802            @GraphQLName("inventoryDispositionAdjustmentName") final String inventoryDispositionAdjustmentName,
5803            @GraphQLName("id") @GraphQLID final String id) {
5804        InventoryDispositionAdjustment inventoryDispositionAdjustment;
5805
5806        try {
5807            var commandForm = InventoryUtil.getHome().getGetInventoryDispositionAdjustmentForm();
5808
5809            commandForm.setInventoryTransactionTypeName(inventoryTransactionTypeName);
5810            commandForm.setInventoryDispositionName(inventoryDispositionName);
5811            commandForm.setInventoryDispositionAdjustmentName(inventoryDispositionAdjustmentName);
5812            commandForm.setUuid(id);
5813
5814            inventoryDispositionAdjustment =
5815                    CDI.current().select(GetInventoryDispositionAdjustmentCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
5816        } catch (NamingException ex) {
5817            throw new RuntimeException(ex);
5818        }
5819
5820        return inventoryDispositionAdjustment == null ? null : new InventoryDispositionAdjustmentObject(inventoryDispositionAdjustment);
5821    }
5822
5823    @GraphQLField
5824    @GraphQLName("inventoryDispositionAdjustments")
5825    @GraphQLNonNull
5826    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
5827    static CountingPaginatedData<InventoryDispositionAdjustmentObject> inventoryDispositionAdjustments(final DataFetchingEnvironment env,
5828            @GraphQLName("inventoryTransactionTypeName") @GraphQLNonNull final String inventoryTransactionTypeName,
5829            @GraphQLName("inventoryDispositionName") @GraphQLNonNull final String inventoryDispositionName) {
5830        CountingPaginatedData<InventoryDispositionAdjustmentObject> data;
5831
5832        try {
5833            var commandForm = InventoryUtil.getHome().getGetInventoryDispositionAdjustmentsForm();
5834            var command = CDI.current().select(GetInventoryDispositionAdjustmentsCommand.class).get();
5835
5836            commandForm.setInventoryTransactionTypeName(inventoryTransactionTypeName);
5837            commandForm.setInventoryDispositionName(inventoryDispositionName);
5838
5839            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5840            if(totalEntities == null) {
5841                data = Connections.emptyConnection();
5842            } else {
5843                try(var objectLimiter = new ObjectLimiter(env, InventoryDispositionAdjustmentConstants.COMPONENT_VENDOR_NAME,
5844                        InventoryDispositionAdjustmentConstants.ENTITY_TYPE_NAME, totalEntities)) {
5845                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5846
5847                    var inventoryDispositionAdjustments = entities.stream()
5848                            .map(InventoryDispositionAdjustmentObject::new)
5849                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
5850
5851                    data = new CountedObjects<>(objectLimiter, inventoryDispositionAdjustments);
5852                }
5853            }
5854        } catch (NamingException ex) {
5855            throw new RuntimeException(ex);
5856        }
5857
5858        return data;
5859    }
5860
5861    @GraphQLField
5862    @GraphQLName("inventoryTransactionReason")
5863    static InventoryTransactionReasonObject inventoryTransactionReason(final DataFetchingEnvironment env,
5864            @GraphQLName("inventoryTransactionTypeName") final String inventoryTransactionTypeName,
5865            @GraphQLName("inventoryTransactionReasonName") final String inventoryTransactionReasonName,
5866            @GraphQLName("id") @GraphQLID final String id) {
5867        InventoryTransactionReason inventoryTransactionReason;
5868
5869        try {
5870            var commandForm = InventoryUtil.getHome().getGetInventoryTransactionReasonForm();
5871
5872            commandForm.setInventoryTransactionTypeName(inventoryTransactionTypeName);
5873            commandForm.setInventoryTransactionReasonName(inventoryTransactionReasonName);
5874            commandForm.setUuid(id);
5875
5876            inventoryTransactionReason = 
5877                    CDI.current().select(GetInventoryTransactionReasonCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
5878        } catch (NamingException ex) {
5879            throw new RuntimeException(ex);
5880        }
5881
5882        return inventoryTransactionReason == null ? null : new InventoryTransactionReasonObject(inventoryTransactionReason);
5883    }
5884
5885    @GraphQLField
5886    @GraphQLName("inventoryTransactionReasons")
5887    @GraphQLNonNull
5888    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
5889    static CountingPaginatedData<InventoryTransactionReasonObject> inventoryTransactionReasons(final DataFetchingEnvironment env,
5890            @GraphQLName("inventoryTransactionTypeName") @GraphQLNonNull final String inventoryTransactionTypeName) {
5891        CountingPaginatedData<InventoryTransactionReasonObject> data;
5892
5893        try {
5894            var commandForm = InventoryUtil.getHome().getGetInventoryTransactionReasonsForm();
5895            var command = CDI.current().select(GetInventoryTransactionReasonsCommand.class).get();
5896
5897            commandForm.setInventoryTransactionTypeName(inventoryTransactionTypeName);
5898
5899            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5900            if(totalEntities == null) {
5901                data = Connections.emptyConnection();
5902            } else {
5903                try(var objectLimiter = new ObjectLimiter(env, InventoryTransactionReasonConstants.COMPONENT_VENDOR_NAME,
5904                        InventoryTransactionReasonConstants.ENTITY_TYPE_NAME, totalEntities)) {
5905                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5906
5907                    var inventoryTransactionReasons = entities.stream()
5908                            .map(InventoryTransactionReasonObject::new)
5909                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
5910
5911                    data = new CountedObjects<>(objectLimiter, inventoryTransactionReasons);
5912                }
5913            }
5914        } catch (NamingException ex) {
5915            throw new RuntimeException(ex);
5916        }
5917
5918        return data;
5919    }
5920
5921    @GraphQLField
5922    @GraphQLName("inventoryTransactionRoleType")
5923    static InventoryTransactionRoleTypeObject inventoryTransactionRoleType(final DataFetchingEnvironment env,
5924            @GraphQLName("inventoryTransactionTypeName") final String inventoryTransactionTypeName,
5925            @GraphQLName("inventoryTransactionRoleTypeName") final String inventoryTransactionRoleTypeName,
5926            @GraphQLName("id") @GraphQLID final String id) {
5927        InventoryTransactionRoleType inventoryTransactionRoleType;
5928
5929        try {
5930            var commandForm = InventoryUtil.getHome().getGetInventoryTransactionRoleTypeForm();
5931
5932            commandForm.setInventoryTransactionTypeName(inventoryTransactionTypeName);
5933            commandForm.setInventoryTransactionRoleTypeName(inventoryTransactionRoleTypeName);
5934            commandForm.setUuid(id);
5935
5936            inventoryTransactionRoleType = 
5937                    CDI.current().select(GetInventoryTransactionRoleTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
5938        } catch (NamingException ex) {
5939            throw new RuntimeException(ex);
5940        }
5941
5942        return inventoryTransactionRoleType == null ? null : new InventoryTransactionRoleTypeObject(inventoryTransactionRoleType);
5943    }
5944
5945    @GraphQLField
5946    @GraphQLName("inventoryTransactionRoleTypes")
5947    @GraphQLNonNull
5948    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
5949    static CountingPaginatedData<InventoryTransactionRoleTypeObject> inventoryTransactionRoleTypes(final DataFetchingEnvironment env,
5950            @GraphQLName("inventoryTransactionTypeName") @GraphQLNonNull final String inventoryTransactionTypeName) {
5951        CountingPaginatedData<InventoryTransactionRoleTypeObject> data;
5952
5953        try {
5954            var commandForm = InventoryUtil.getHome().getGetInventoryTransactionRoleTypesForm();
5955            var command = CDI.current().select(GetInventoryTransactionRoleTypesCommand.class).get();
5956
5957            commandForm.setInventoryTransactionTypeName(inventoryTransactionTypeName);
5958
5959            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5960            if(totalEntities == null) {
5961                data = Connections.emptyConnection();
5962            } else {
5963                try(var objectLimiter = new ObjectLimiter(env, InventoryTransactionRoleTypeConstants.COMPONENT_VENDOR_NAME,
5964                        InventoryTransactionRoleTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
5965                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
5966
5967                    var inventoryTransactionRoleTypes = entities.stream()
5968                            .map(InventoryTransactionRoleTypeObject::new)
5969                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
5970
5971                    data = new CountedObjects<>(objectLimiter, inventoryTransactionRoleTypes);
5972                }
5973            }
5974        } catch (NamingException ex) {
5975            throw new RuntimeException(ex);
5976        }
5977
5978        return data;
5979    }
5980
5981    @GraphQLField
5982    @GraphQLName("inventoryAdjustmentType")
5983    static InventoryAdjustmentTypeObject inventoryAdjustmentType(final DataFetchingEnvironment env,
5984            @GraphQLName("inventoryAdjustmentTypeName") final String inventoryAdjustmentTypeName,
5985            @GraphQLName("id") @GraphQLID final String id) {
5986        InventoryAdjustmentType inventoryAdjustmentType;
5987
5988        try {
5989            var commandForm = InventoryUtil.getHome().getGetInventoryAdjustmentTypeForm();
5990
5991            commandForm.setInventoryAdjustmentTypeName(inventoryAdjustmentTypeName);
5992            commandForm.setUuid(id);
5993
5994            inventoryAdjustmentType = CDI.current().select(GetInventoryAdjustmentTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
5995        } catch (NamingException ex) {
5996            throw new RuntimeException(ex);
5997        }
5998
5999        return inventoryAdjustmentType == null ? null : new InventoryAdjustmentTypeObject(inventoryAdjustmentType);
6000    }
6001
6002    @GraphQLField
6003    @GraphQLName("inventoryAdjustmentTypes")
6004    @GraphQLNonNull
6005    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
6006    static CountingPaginatedData<InventoryAdjustmentTypeObject> inventoryAdjustmentTypes(final DataFetchingEnvironment env) {
6007        CountingPaginatedData<InventoryAdjustmentTypeObject> data;
6008
6009        try {
6010            var commandForm = InventoryUtil.getHome().getGetInventoryAdjustmentTypesForm();
6011            var command = CDI.current().select(GetInventoryAdjustmentTypesCommand.class).get();
6012
6013            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6014            if(totalEntities == null) {
6015                data = Connections.emptyConnection();
6016            } else {
6017                try(var objectLimiter = new ObjectLimiter(env, InventoryAdjustmentTypeConstants.COMPONENT_VENDOR_NAME, InventoryAdjustmentTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
6018                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6019
6020                    var inventoryAdjustmentTypes = entities.stream()
6021                            .map(InventoryAdjustmentTypeObject::new)
6022                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
6023
6024                    data = new CountedObjects<>(objectLimiter, inventoryAdjustmentTypes);
6025                }
6026            }
6027        } catch (NamingException ex) {
6028            throw new RuntimeException(ex);
6029        }
6030
6031        return data;
6032    }
6033
6034    @GraphQLField
6035    @GraphQLName("inventoryCostingMethod")
6036    static InventoryCostingMethodObject inventoryCostingMethod(final DataFetchingEnvironment env,
6037            @GraphQLName("inventoryCostingMethodName") final String inventoryCostingMethodName,
6038            @GraphQLName("id") @GraphQLID final String id) {
6039        InventoryCostingMethod inventoryCostingMethod;
6040
6041        try {
6042            var commandForm = InventoryUtil.getHome().getGetInventoryCostingMethodForm();
6043
6044            commandForm.setInventoryCostingMethodName(inventoryCostingMethodName);
6045            commandForm.setUuid(id);
6046
6047            inventoryCostingMethod = CDI.current().select(GetInventoryCostingMethodCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
6048        } catch (NamingException ex) {
6049            throw new RuntimeException(ex);
6050        }
6051
6052        return inventoryCostingMethod == null ? null : new InventoryCostingMethodObject(inventoryCostingMethod);
6053    }
6054
6055    @GraphQLField
6056    @GraphQLName("inventoryCostingMethods")
6057    @GraphQLNonNull
6058    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
6059    static CountingPaginatedData<InventoryCostingMethodObject> inventoryCostingMethods(final DataFetchingEnvironment env) {
6060        CountingPaginatedData<InventoryCostingMethodObject> data;
6061
6062        try {
6063            var commandForm = InventoryUtil.getHome().getGetInventoryCostingMethodsForm();
6064            var command = CDI.current().select(GetInventoryCostingMethodsCommand.class).get();
6065
6066            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6067            if(totalEntities == null) {
6068                data = Connections.emptyConnection();
6069            } else {
6070                try(var objectLimiter = new ObjectLimiter(env, InventoryCostingMethodConstants.COMPONENT_VENDOR_NAME, InventoryCostingMethodConstants.ENTITY_TYPE_NAME, totalEntities)) {
6071                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6072
6073                    var inventoryCostingMethods = entities.stream()
6074                            .map(InventoryCostingMethodObject::new)
6075                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
6076
6077                    data = new CountedObjects<>(objectLimiter, inventoryCostingMethods);
6078                }
6079            }
6080        } catch (NamingException ex) {
6081            throw new RuntimeException(ex);
6082        }
6083
6084        return data;
6085    }
6086
6087    @GraphQLField
6088    @GraphQLName("partyInventoryCostingMethod")
6089    static PartyInventoryCostingMethodObject partyInventoryCostingMethod(final DataFetchingEnvironment env,
6090            @GraphQLName("partyName") final String partyName,
6091            @GraphQLName("id") @GraphQLID final String id) {
6092        PartyInventoryCostingMethod partyInventoryCostingMethod;
6093
6094        try {
6095            var commandForm = InventoryUtil.getHome().getGetPartyInventoryCostingMethodForm();
6096
6097            commandForm.setPartyName(partyName);
6098            commandForm.setUuid(id);
6099
6100            partyInventoryCostingMethod = CDI.current().select(GetPartyInventoryCostingMethodCommand.class).get()
6101                    .getEntityForGraphQl(getUserVisitPK(env), commandForm);
6102        } catch (NamingException ex) {
6103            throw new RuntimeException(ex);
6104        }
6105
6106        return partyInventoryCostingMethod == null ? null
6107                : new PartyInventoryCostingMethodObject(partyInventoryCostingMethod);
6108    }
6109
6110    @GraphQLField
6111    @GraphQLName("partyInventoryCostingMethods")
6112    @GraphQLNonNull
6113    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
6114    static CountingPaginatedData<PartyInventoryCostingMethodObject> partyInventoryCostingMethods(
6115            final DataFetchingEnvironment env,
6116            @GraphQLName("inventoryCostingMethodName") final String inventoryCostingMethodName,
6117            @GraphQLName("id") @GraphQLID final String id) {
6118        CountingPaginatedData<PartyInventoryCostingMethodObject> data;
6119
6120        try {
6121            var commandForm = InventoryUtil.getHome().getGetPartyInventoryCostingMethodsForm();
6122            var command = CDI.current().select(GetPartyInventoryCostingMethodsCommand.class).get();
6123
6124            commandForm.setInventoryCostingMethodName(inventoryCostingMethodName);
6125            commandForm.setUuid(id);
6126
6127            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6128            if(totalEntities == null) {
6129                data = Connections.emptyConnection();
6130            } else {
6131                try(var objectLimiter = new ObjectLimiter(env,
6132                        PartyInventoryCostingMethodConstants.COMPONENT_VENDOR_NAME,
6133                        PartyInventoryCostingMethodConstants.ENTITY_TYPE_NAME, totalEntities)) {
6134                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6135                    var partyInventoryCostingMethods = entities.stream()
6136                            .map(PartyInventoryCostingMethodObject::new)
6137                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
6138
6139                    data = new CountedObjects<>(objectLimiter, partyInventoryCostingMethods);
6140                }
6141            }
6142        } catch (NamingException ex) {
6143            throw new RuntimeException(ex);
6144        }
6145
6146        return data;
6147    }
6148
6149    @GraphQLField
6150    @GraphQLName("inventoryBucketType")
6151    static InventoryBucketTypeObject inventoryBucketType(final DataFetchingEnvironment env,
6152            @GraphQLName("inventoryBucketTypeName") final String inventoryBucketTypeName,
6153            @GraphQLName("id") @GraphQLID final String id) {
6154        InventoryBucketType inventoryBucketType;
6155
6156        try {
6157            var commandForm = InventoryUtil.getHome().getGetInventoryBucketTypeForm();
6158
6159            commandForm.setInventoryBucketTypeName(inventoryBucketTypeName);
6160            commandForm.setUuid(id);
6161
6162            inventoryBucketType = CDI.current().select(GetInventoryBucketTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
6163        } catch (NamingException ex) {
6164            throw new RuntimeException(ex);
6165        }
6166
6167        return inventoryBucketType == null ? null : new InventoryBucketTypeObject(inventoryBucketType);
6168    }
6169
6170    @GraphQLField
6171    @GraphQLName("inventoryBucketTypes")
6172    @GraphQLNonNull
6173    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
6174    static CountingPaginatedData<InventoryBucketTypeObject> inventoryBucketTypes(final DataFetchingEnvironment env) {
6175        CountingPaginatedData<InventoryBucketTypeObject> data;
6176
6177        try {
6178            var commandForm = InventoryUtil.getHome().getGetInventoryBucketTypesForm();
6179            var command = CDI.current().select(GetInventoryBucketTypesCommand.class).get();
6180
6181            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6182            if(totalEntities == null) {
6183                data = Connections.emptyConnection();
6184            } else {
6185                try(var objectLimiter = new ObjectLimiter(env, InventoryBucketTypeConstants.COMPONENT_VENDOR_NAME, InventoryBucketTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
6186                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6187
6188                    var inventoryBucketTypes = entities.stream()
6189                            .map(InventoryBucketTypeObject::new)
6190                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
6191
6192                    data = new CountedObjects<>(objectLimiter, inventoryBucketTypes);
6193                }
6194            }
6195        } catch (NamingException ex) {
6196            throw new RuntimeException(ex);
6197        }
6198
6199        return data;
6200    }
6201
6202    @GraphQLField
6203    @GraphQLName("partyBucket")
6204    static PartyBucketObject partyBucket(final DataFetchingEnvironment env,
6205            @GraphQLName("partyName") final String partyName,
6206            @GraphQLName("companyName") final String companyName,
6207            @GraphQLName("warehouseName") final String warehouseName,
6208            @GraphQLName("itemName") @GraphQLNonNull final String itemName,
6209            @GraphQLName("unitOfMeasureTypeName") @GraphQLNonNull final String unitOfMeasureTypeName,
6210            @GraphQLName("inventoryConditionName") @GraphQLNonNull final String inventoryConditionName,
6211            @GraphQLName("inventoryBucketTypeName") @GraphQLNonNull final String inventoryBucketTypeName) {
6212        PartyBucket partyBucket;
6213
6214        try {
6215            var commandForm = InventoryUtil.getHome().getGetPartyBucketForm();
6216
6217            commandForm.setPartyName(partyName);
6218            commandForm.setCompanyName(companyName);
6219            commandForm.setWarehouseName(warehouseName);
6220            commandForm.setItemName(itemName);
6221            commandForm.setUnitOfMeasureTypeName(unitOfMeasureTypeName);
6222            commandForm.setInventoryConditionName(inventoryConditionName);
6223            commandForm.setInventoryBucketTypeName(inventoryBucketTypeName);
6224
6225            partyBucket = CDI.current().select(GetPartyBucketCommand.class).get()
6226                    .getEntityForGraphQl(getUserVisitPK(env), commandForm);
6227        } catch (NamingException ex) {
6228            throw new RuntimeException(ex);
6229        }
6230
6231        return partyBucket == null ? null : new PartyBucketObject(partyBucket);
6232    }
6233
6234    @GraphQLField
6235    @GraphQLName("partyBuckets")
6236    @GraphQLNonNull
6237    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
6238    static CountingPaginatedData<PartyBucketObject> partyBuckets(final DataFetchingEnvironment env,
6239            @GraphQLName("partyName") final String partyName,
6240            @GraphQLName("companyName") final String companyName,
6241            @GraphQLName("warehouseName") final String warehouseName,
6242            @GraphQLName("itemName") final String itemName,
6243            @GraphQLName("unitOfMeasureKindName") final String unitOfMeasureKindName,
6244            @GraphQLName("unitOfMeasureTypeName") final String unitOfMeasureTypeName,
6245            @GraphQLName("inventoryConditionName") final String inventoryConditionName,
6246            @GraphQLName("inventoryBucketTypeName") final String inventoryBucketTypeName) {
6247        CountingPaginatedData<PartyBucketObject> data;
6248
6249        try {
6250            var commandForm = InventoryUtil.getHome().getGetPartyBucketsForm();
6251            var command = CDI.current().select(GetPartyBucketsCommand.class).get();
6252
6253            commandForm.setPartyName(partyName);
6254            commandForm.setCompanyName(companyName);
6255            commandForm.setWarehouseName(warehouseName);
6256            commandForm.setItemName(itemName);
6257            commandForm.setUnitOfMeasureKindName(unitOfMeasureKindName);
6258            commandForm.setUnitOfMeasureTypeName(unitOfMeasureTypeName);
6259            commandForm.setInventoryConditionName(inventoryConditionName);
6260            commandForm.setInventoryBucketTypeName(inventoryBucketTypeName);
6261
6262            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6263            if(totalEntities == null) {
6264                data = Connections.emptyConnection();
6265            } else {
6266                try(var objectLimiter = new ObjectLimiter(env, PartyBucketConstants.COMPONENT_VENDOR_NAME,
6267                        PartyBucketConstants.ENTITY_TYPE_NAME, totalEntities)) {
6268                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6269                    var partyBuckets = entities.stream()
6270                            .map(PartyBucketObject::new)
6271                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
6272
6273                    data = new CountedObjects<>(objectLimiter, partyBuckets);
6274                }
6275            }
6276        } catch (NamingException ex) {
6277            throw new RuntimeException(ex);
6278        }
6279
6280        return data;
6281    }
6282
6283    @GraphQLField
6284    @GraphQLName("inventoryCostingPool")
6285    static InventoryCostingPoolObject inventoryCostingPool(final DataFetchingEnvironment env,
6286            @GraphQLName("partyName") final String partyName,
6287            @GraphQLName("companyName") final String companyName,
6288            @GraphQLName("itemName") final String itemName,
6289            @GraphQLName("inventoryConditionName") final String inventoryConditionName,
6290            @GraphQLName("id") @GraphQLID final String id) {
6291        InventoryCostingPool inventoryCostingPool;
6292
6293        try {
6294            var commandForm = InventoryUtil.getHome().getGetInventoryCostingPoolForm();
6295
6296            commandForm.setPartyName(partyName);
6297            commandForm.setCompanyName(companyName);
6298            commandForm.setItemName(itemName);
6299            commandForm.setInventoryConditionName(inventoryConditionName);
6300            commandForm.setUuid(id);
6301
6302            inventoryCostingPool = CDI.current().select(GetInventoryCostingPoolCommand.class).get()
6303                    .getEntityForGraphQl(getUserVisitPK(env), commandForm);
6304        } catch (NamingException ex) {
6305            throw new RuntimeException(ex);
6306        }
6307
6308        return inventoryCostingPool == null ? null : new InventoryCostingPoolObject(inventoryCostingPool);
6309    }
6310
6311    @GraphQLField
6312    @GraphQLName("inventoryCostingPools")
6313    @GraphQLNonNull
6314    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
6315    static CountingPaginatedData<InventoryCostingPoolObject> inventoryCostingPools(final DataFetchingEnvironment env,
6316            @GraphQLName("partyName") final String partyName,
6317            @GraphQLName("companyName") final String companyName,
6318            @GraphQLName("itemName") final String itemName,
6319            @GraphQLName("inventoryConditionName") final String inventoryConditionName) {
6320        CountingPaginatedData<InventoryCostingPoolObject> data;
6321
6322        try {
6323            var commandForm = InventoryUtil.getHome().getGetInventoryCostingPoolsForm();
6324            var command = CDI.current().select(GetInventoryCostingPoolsCommand.class).get();
6325
6326            commandForm.setPartyName(partyName);
6327            commandForm.setCompanyName(companyName);
6328            commandForm.setItemName(itemName);
6329            commandForm.setInventoryConditionName(inventoryConditionName);
6330
6331            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6332            if(totalEntities == null) {
6333                data = Connections.emptyConnection();
6334            } else {
6335                try(var objectLimiter = new ObjectLimiter(env, InventoryCostingPoolConstants.COMPONENT_VENDOR_NAME,
6336                        InventoryCostingPoolConstants.ENTITY_TYPE_NAME, totalEntities)) {
6337                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6338                    var inventoryCostingPools = entities.stream()
6339                            .map(InventoryCostingPoolObject::new)
6340                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
6341
6342                    data = new CountedObjects<>(objectLimiter, inventoryCostingPools);
6343                }
6344            }
6345        } catch (NamingException ex) {
6346            throw new RuntimeException(ex);
6347        }
6348
6349        return data;
6350    }
6351
6352    @GraphQLField
6353    @GraphQLName("inventoryLayer")
6354    static InventoryLayerObject inventoryLayer(final DataFetchingEnvironment env,
6355            @GraphQLName("partyName") final String partyName,
6356            @GraphQLName("companyName") final String companyName,
6357            @GraphQLName("itemName") final String itemName,
6358            @GraphQLName("inventoryConditionName") final String inventoryConditionName,
6359            @GraphQLName("inventoryLayerSequence") final String inventoryLayerSequence,
6360            @GraphQLName("id") @GraphQLID final String id) {
6361        InventoryLayer inventoryLayer;
6362
6363        try {
6364            var commandForm = InventoryUtil.getHome().getGetInventoryLayerForm();
6365
6366            commandForm.setPartyName(partyName);
6367            commandForm.setCompanyName(companyName);
6368            commandForm.setItemName(itemName);
6369            commandForm.setInventoryConditionName(inventoryConditionName);
6370            commandForm.setInventoryLayerSequence(inventoryLayerSequence);
6371            commandForm.setUuid(id);
6372
6373            inventoryLayer = CDI.current().select(GetInventoryLayerCommand.class).get()
6374                    .getEntityForGraphQl(getUserVisitPK(env), commandForm);
6375        } catch (NamingException ex) {
6376            throw new RuntimeException(ex);
6377        }
6378
6379        return inventoryLayer == null ? null : new InventoryLayerObject(inventoryLayer);
6380    }
6381
6382    @GraphQLField
6383    @GraphQLName("inventoryLayers")
6384    @GraphQLNonNull
6385    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
6386    static CountingPaginatedData<InventoryLayerObject> inventoryLayers(final DataFetchingEnvironment env,
6387            @GraphQLName("partyName") final String partyName,
6388            @GraphQLName("companyName") final String companyName,
6389            @GraphQLName("itemName") final String itemName,
6390            @GraphQLName("inventoryConditionName") final String inventoryConditionName,
6391            @GraphQLName("inventoryTransactionTypeName") final String inventoryTransactionTypeName,
6392            @GraphQLName("inventoryTransactionName") final String inventoryTransactionName,
6393            @GraphQLName("inventoryTransactionLineSequence") final String inventoryTransactionLineSequence) {
6394        CountingPaginatedData<InventoryLayerObject> data;
6395
6396        try {
6397            var commandForm = InventoryUtil.getHome().getGetInventoryLayersForm();
6398            var command = CDI.current().select(GetInventoryLayersCommand.class).get();
6399
6400            commandForm.setPartyName(partyName);
6401            commandForm.setCompanyName(companyName);
6402            commandForm.setItemName(itemName);
6403            commandForm.setInventoryConditionName(inventoryConditionName);
6404            commandForm.setInventoryTransactionTypeName(inventoryTransactionTypeName);
6405            commandForm.setInventoryTransactionName(inventoryTransactionName);
6406            commandForm.setInventoryTransactionLineSequence(inventoryTransactionLineSequence);
6407
6408            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6409            if(totalEntities == null) {
6410                data = Connections.emptyConnection();
6411            } else {
6412                try(var objectLimiter = new ObjectLimiter(env, InventoryLayerConstants.COMPONENT_VENDOR_NAME,
6413                        InventoryLayerConstants.ENTITY_TYPE_NAME, totalEntities)) {
6414                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6415                    var inventoryLayers = entities.stream()
6416                            .map(InventoryLayerObject::new)
6417                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
6418
6419                    data = new CountedObjects<>(objectLimiter, inventoryLayers);
6420                }
6421            }
6422        } catch (NamingException ex) {
6423            throw new RuntimeException(ex);
6424        }
6425
6426        return data;
6427    }
6428
6429    @GraphQLField
6430    @GraphQLName("lot")
6431    static LotObject lot(final DataFetchingEnvironment env,
6432            @GraphQLName("itemName") final String itemName,
6433            @GraphQLName("lotIdentifier") final String lotIdentifier,
6434            @GraphQLName("id") @GraphQLID final String id) {
6435        Lot lot;
6436
6437        try {
6438            var commandForm = InventoryUtil.getHome().getGetLotForm();
6439
6440            commandForm.setItemName(itemName);
6441            commandForm.setLotIdentifier(lotIdentifier);
6442            commandForm.setUuid(id);
6443
6444            lot = CDI.current().select(GetLotCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
6445        } catch (NamingException ex) {
6446            throw new RuntimeException(ex);
6447        }
6448
6449        return lot == null ? null : new LotObject(lot);
6450    }
6451
6452    @GraphQLField
6453    @GraphQLName("lots")
6454    @GraphQLNonNull
6455    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
6456    static CountingPaginatedData<LotObject> lots(final DataFetchingEnvironment env,
6457            @GraphQLName("itemName") @GraphQLNonNull final String itemName) {
6458        CountingPaginatedData<LotObject> data;
6459
6460        try {
6461            var commandForm = InventoryUtil.getHome().getGetLotsForm();
6462            var command = CDI.current().select(GetLotsCommand.class).get();
6463
6464            commandForm.setItemName(itemName);
6465
6466            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6467            if(totalEntities == null) {
6468                data = Connections.emptyConnection();
6469            } else {
6470                try(var objectLimiter = new ObjectLimiter(env, LotConstants.COMPONENT_VENDOR_NAME, LotConstants.ENTITY_TYPE_NAME, totalEntities)) {
6471                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6472
6473                    var lots = entities.stream()
6474                            .map(LotObject::new)
6475                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
6476
6477                    data = new CountedObjects<>(objectLimiter, lots);
6478                }
6479            }
6480        } catch (NamingException ex) {
6481            throw new RuntimeException(ex);
6482        }
6483
6484        return data;
6485    }
6486
6487    @GraphQLField
6488    @GraphQLName("contentPageLayout")
6489    static ContentPageLayoutObject contentPageLayout(final DataFetchingEnvironment env,
6490            @GraphQLName("contentPageLayoutName") final String contentPageLayoutName,
6491            @GraphQLName("id") @GraphQLID final String id) {
6492        ContentPageLayout contentPageLayout;
6493
6494        try {
6495            var commandForm = ContentUtil.getHome().getGetContentPageLayoutForm();
6496
6497            commandForm.setContentPageLayoutName(contentPageLayoutName);
6498            commandForm.setUuid(id);
6499
6500            contentPageLayout = CDI.current().select(GetContentPageLayoutCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
6501        } catch (NamingException ex) {
6502            throw new RuntimeException(ex);
6503        }
6504
6505        return contentPageLayout == null ? null : new ContentPageLayoutObject(contentPageLayout);
6506    }
6507
6508    @GraphQLField
6509    @GraphQLName("contentPageLayouts")
6510    @GraphQLNonNull
6511    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
6512    static CountingPaginatedData<ContentPageLayoutObject> contentPageLayouts(final DataFetchingEnvironment env) {
6513        CountingPaginatedData<ContentPageLayoutObject> data;
6514
6515        try {
6516            var commandForm = ContentUtil.getHome().getGetContentPageLayoutsForm();
6517            var command = CDI.current().select(GetContentPageLayoutsCommand.class).get();
6518
6519            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6520            if(totalEntities == null) {
6521                data = Connections.emptyConnection();
6522            } else {
6523                try(var objectLimiter = new ObjectLimiter(env, ContentPageLayoutConstants.COMPONENT_VENDOR_NAME, ContentPageLayoutConstants.ENTITY_TYPE_NAME, totalEntities)) {
6524                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6525
6526                    var contentPageLayouts = entities.stream()
6527                            .map(ContentPageLayoutObject::new)
6528                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
6529
6530                    data = new CountedObjects<>(objectLimiter, contentPageLayouts);
6531                }
6532            }
6533        } catch (NamingException ex) {
6534            throw new RuntimeException(ex);
6535        }
6536
6537        return data;
6538    }
6539
6540    @GraphQLField
6541    @GraphQLName("contentPageLayoutArea")
6542    static ContentPageLayoutAreaObject contentPageLayoutArea(final DataFetchingEnvironment env,
6543            @GraphQLName("contentCollectionName") @GraphQLNonNull final String contentCollectionName,
6544            @GraphQLName("contentSectionName") @GraphQLNonNull final String contentSectionName,
6545            @GraphQLName("contentPageName") @GraphQLNonNull final String contentPageName,
6546            @GraphQLName("sortOrder") @GraphQLNonNull final String sortOrder) {
6547        ContentPageLayoutArea contentPageLayoutArea;
6548
6549        try {
6550            var commandForm = ContentUtil.getHome().getGetContentPageLayoutAreaForm();
6551
6552            commandForm.setContentCollectionName(contentCollectionName);
6553            commandForm.setContentSectionName(contentSectionName);
6554            commandForm.setContentPageName(contentPageName);
6555            commandForm.setSortOrder(sortOrder);
6556
6557            contentPageLayoutArea = CDI.current().select(GetContentPageLayoutAreaCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
6558        } catch (NamingException ex) {
6559            throw new RuntimeException(ex);
6560        }
6561
6562        return contentPageLayoutArea == null ? null : new ContentPageLayoutAreaObject(contentPageLayoutArea);
6563    }
6564
6565    @GraphQLField
6566    @GraphQLName("contentPageLayoutAreas")
6567    @GraphQLNonNull
6568    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
6569    static CountingPaginatedData<ContentPageLayoutAreaObject> contentPageLayoutAreas(final DataFetchingEnvironment env,
6570            @GraphQLName("contentCollectionName") @GraphQLNonNull final String contentCollectionName,
6571            @GraphQLName("contentSectionName") @GraphQLNonNull final String contentSectionName,
6572            @GraphQLName("contentPageName") @GraphQLNonNull final String contentPageName) {
6573        CountingPaginatedData<ContentPageLayoutAreaObject> data;
6574
6575        try {
6576            var commandForm = ContentUtil.getHome().getGetContentPageLayoutAreasForm();
6577            var command = CDI.current().select(GetContentPageLayoutAreasCommand.class).get();
6578
6579
6580            commandForm.setContentCollectionName(contentCollectionName);
6581            commandForm.setContentSectionName(contentSectionName);
6582            commandForm.setContentPageName(contentPageName);
6583
6584            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6585            if(totalEntities == null) {
6586                data = Connections.emptyConnection();
6587            } else {
6588                try(var objectLimiter = new ObjectLimiter(env, ContentPageLayoutAreaConstants.COMPONENT_VENDOR_NAME, ContentPageLayoutAreaConstants.ENTITY_TYPE_NAME, totalEntities)) {
6589                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6590
6591                    var contentPageLayoutAreas = entities.stream()
6592                            .map(ContentPageLayoutAreaObject::new)
6593                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
6594
6595                    data = new CountedObjects<>(objectLimiter, contentPageLayoutAreas);
6596                }
6597            }
6598        } catch (NamingException ex) {
6599            throw new RuntimeException(ex);
6600        }
6601
6602        return data;
6603    }
6604
6605    @GraphQLField
6606    @GraphQLName("contentPageAreaType")
6607    static ContentPageAreaTypeObject contentPageAreaType(final DataFetchingEnvironment env,
6608            @GraphQLName("contentPageAreaTypeName") final String contentPageAreaTypeName,
6609            @GraphQLName("id") @GraphQLID final String id) {
6610        ContentPageAreaType contentPageAreaType;
6611
6612        try {
6613            var commandForm = ContentUtil.getHome().getGetContentPageAreaTypeForm();
6614
6615            commandForm.setContentPageAreaTypeName(contentPageAreaTypeName);
6616            commandForm.setUuid(id);
6617
6618            contentPageAreaType = CDI.current().select(GetContentPageAreaTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
6619        } catch (NamingException ex) {
6620            throw new RuntimeException(ex);
6621        }
6622
6623        return contentPageAreaType == null ? null : new ContentPageAreaTypeObject(contentPageAreaType);
6624    }
6625
6626    @GraphQLField
6627    @GraphQLName("contentPageAreaTypes")
6628    @GraphQLNonNull
6629    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
6630    static CountingPaginatedData<ContentPageAreaTypeObject> contentPageAreaTypes(final DataFetchingEnvironment env) {
6631        CountingPaginatedData<ContentPageAreaTypeObject> data;
6632
6633        try {
6634            var commandForm = ContentUtil.getHome().getGetContentPageAreaTypesForm();
6635            var command = CDI.current().select(GetContentPageAreaTypesCommand.class).get();
6636
6637            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6638            if(totalEntities == null) {
6639                data = Connections.emptyConnection();
6640            } else {
6641                try(var objectLimiter = new ObjectLimiter(env, ContentPageAreaTypeConstants.COMPONENT_VENDOR_NAME, ContentPageAreaTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
6642                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6643
6644                    var contentPageAreaTypes = entities.stream()
6645                            .map(ContentPageAreaTypeObject::new)
6646                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
6647
6648                    data = new CountedObjects<>(objectLimiter, contentPageAreaTypes);
6649                }
6650            }
6651        } catch (NamingException ex) {
6652            throw new RuntimeException(ex);
6653        }
6654
6655        return data;
6656    }
6657
6658    @GraphQLField
6659    @GraphQLName("contentWebAddress")
6660    static ContentWebAddressObject contentWebAddress(final DataFetchingEnvironment env,
6661            @GraphQLName("contentWebAddressName") @GraphQLNonNull final String contentWebAddressName) {
6662        ContentWebAddress contentWebAddress;
6663
6664        try {
6665            var commandForm = ContentUtil.getHome().getGetContentWebAddressForm();
6666
6667            commandForm.setContentWebAddressName(contentWebAddressName);
6668
6669            contentWebAddress = CDI.current().select(GetContentWebAddressCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
6670        } catch (NamingException ex) {
6671            throw new RuntimeException(ex);
6672        }
6673
6674        return contentWebAddress == null ? null : new ContentWebAddressObject(contentWebAddress);
6675    }
6676
6677    @GraphQLField
6678    @GraphQLName("contentWebAddresses")
6679    @GraphQLNonNull
6680    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
6681    static CountingPaginatedData<ContentWebAddressObject> contentWebAddresses(final DataFetchingEnvironment env) {
6682        CountingPaginatedData<ContentWebAddressObject> data;
6683
6684        try {
6685            var commandForm = ContentUtil.getHome().getGetContentWebAddressesForm();
6686            var command = CDI.current().select(GetContentWebAddressesCommand.class).get();
6687
6688            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6689            if(totalEntities == null) {
6690                data = Connections.emptyConnection();
6691            } else {
6692                try(var objectLimiter = new ObjectLimiter(env, ContentWebAddressConstants.COMPONENT_VENDOR_NAME, ContentWebAddressConstants.ENTITY_TYPE_NAME, totalEntities)) {
6693                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6694
6695                    var contentWebAddresses = entities.stream()
6696                            .map(ContentWebAddressObject::new)
6697                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
6698
6699                    data = new CountedObjects<>(objectLimiter, contentWebAddresses);
6700                }
6701            }
6702        } catch (NamingException ex) {
6703            throw new RuntimeException(ex);
6704        }
6705
6706        return data;
6707    }
6708
6709    @GraphQLField
6710    @GraphQLName("contentCollection")
6711    static ContentCollectionObject contentCollection(final DataFetchingEnvironment env,
6712            @GraphQLName("contentCollectionName") final String contentCollectionName) {
6713        ContentCollection contentCollection;
6714
6715        try {
6716            var commandForm = ContentUtil.getHome().getGetContentCollectionForm();
6717
6718            commandForm.setContentCollectionName(contentCollectionName);
6719
6720            contentCollection = CDI.current().select(GetContentCollectionCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
6721        } catch (NamingException ex) {
6722            throw new RuntimeException(ex);
6723        }
6724
6725        return contentCollection == null ? null : new ContentCollectionObject(contentCollection);
6726    }
6727
6728    @GraphQLField
6729    @GraphQLName("contentCollections")
6730    @GraphQLNonNull
6731    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
6732    static CountingPaginatedData<ContentCollectionObject> contentCollections(final DataFetchingEnvironment env) {
6733        CountingPaginatedData<ContentCollectionObject> data;
6734
6735        try {
6736            var commandForm = ContentUtil.getHome().getGetContentCollectionsForm();
6737            var command = CDI.current().select(GetContentCollectionsCommand.class).get();
6738
6739            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6740            if(totalEntities == null) {
6741                data = Connections.emptyConnection();
6742            } else {
6743                try(var objectLimiter = new ObjectLimiter(env, ContentCollectionConstants.COMPONENT_VENDOR_NAME, ContentCollectionConstants.ENTITY_TYPE_NAME, totalEntities)) {
6744                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6745
6746                    var contentCollections = entities.stream()
6747                            .map(ContentCollectionObject::new)
6748                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
6749
6750                    data = new CountedObjects<>(objectLimiter, contentCollections);
6751                }
6752            }
6753        } catch (NamingException ex) {
6754            throw new RuntimeException(ex);
6755        }
6756
6757        return data;
6758    }
6759    
6760    @GraphQLField
6761    @GraphQLName("contentSection")
6762    static ContentSectionObject contentSection(final DataFetchingEnvironment env,
6763            @GraphQLName("contentWebAddressName") final String contentWebAddressName,
6764            @GraphQLName("contentCollectionName") final String contentCollectionName,
6765            @GraphQLName("contentSectionName") final String contentSectionName,
6766            @GraphQLName("associateProgramName") final String associateProgramName,
6767            @GraphQLName("associateName") final String associateName,
6768            @GraphQLName("associatePartyContactMechanismName") final String associatePartyContactMechanismName) {
6769        ContentSection contentSection;
6770
6771        try {
6772            var commandForm = ContentUtil.getHome().getGetContentSectionForm();
6773
6774            commandForm.setContentWebAddressName(contentWebAddressName);
6775            commandForm.setContentCollectionName(contentCollectionName);
6776            commandForm.setContentSectionName(contentSectionName);
6777            commandForm.setAssociateProgramName(associateProgramName);
6778            commandForm.setAssociateName(associateName);
6779            commandForm.setAssociatePartyContactMechanismName(associatePartyContactMechanismName);
6780
6781            contentSection = CDI.current().select(GetContentSectionCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
6782        } catch (NamingException ex) {
6783            throw new RuntimeException(ex);
6784        }
6785
6786        return contentSection == null ? null : new ContentSectionObject(contentSection);
6787    }
6788
6789    @GraphQLField
6790    @GraphQLName("contentSections")
6791    @GraphQLNonNull
6792    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
6793    static CountingPaginatedData<ContentSectionObject> contentSections(final DataFetchingEnvironment env,
6794            @GraphQLName("contentWebAddressName") final String contentWebAddressName,
6795            @GraphQLName("contentCollectionName") final String contentCollectionName,
6796            @GraphQLName("parentContentSectionName") final String parentContentSectionName,
6797            @GraphQLName("associateProgramName") final String associateProgramName,
6798            @GraphQLName("associateName") final String associateName,
6799            @GraphQLName("associatePartyContactMechanismName") final String associatePartyContactMechanismName) {
6800        CountingPaginatedData<ContentSectionObject> data;
6801
6802        try {
6803            var commandForm = ContentUtil.getHome().getGetContentSectionsForm();
6804            var command = CDI.current().select(GetContentSectionsCommand.class).get();
6805
6806            commandForm.setContentWebAddressName(contentWebAddressName);
6807            commandForm.setContentCollectionName(contentCollectionName);
6808            commandForm.setParentContentSectionName(parentContentSectionName);
6809            commandForm.setAssociateProgramName(associateProgramName);
6810            commandForm.setAssociateName(associateName);
6811            commandForm.setAssociatePartyContactMechanismName(associatePartyContactMechanismName);
6812
6813            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6814            if(totalEntities == null) {
6815                data = Connections.emptyConnection();
6816            } else {
6817                try(var objectLimiter = new ObjectLimiter(env, ContentSectionConstants.COMPONENT_VENDOR_NAME, ContentSectionConstants.ENTITY_TYPE_NAME, totalEntities)) {
6818                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6819
6820                    var contentSections = entities.stream()
6821                            .map(ContentSectionObject::new)
6822                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
6823
6824                    data = new CountedObjects<>(objectLimiter, contentSections);
6825                }
6826            }
6827        } catch (NamingException ex) {
6828            throw new RuntimeException(ex);
6829        }
6830
6831        return data;
6832    }
6833
6834    @GraphQLField
6835    @GraphQLName("contentPage")
6836    static ContentPageObject contentPage(final DataFetchingEnvironment env,
6837            @GraphQLName("contentWebAddressName") final String contentWebAddressName,
6838            @GraphQLName("contentCollectionName") final String contentCollectionName,
6839            @GraphQLName("contentSectionName") final String contentSectionName,
6840            @GraphQLName("contentPageName") final String contentPageName,
6841            @GraphQLName("associateProgramName") final String associateProgramName,
6842            @GraphQLName("associateName") final String associateName,
6843            @GraphQLName("associatePartyContactMechanismName") final String associatePartyContactMechanismName) {
6844        ContentPage contentPage;
6845
6846        try {
6847            var commandForm = ContentUtil.getHome().getGetContentPageForm();
6848
6849            commandForm.setContentWebAddressName(contentWebAddressName);
6850            commandForm.setContentCollectionName(contentCollectionName);
6851            commandForm.setContentSectionName(contentSectionName);
6852            commandForm.setContentPageName(contentPageName);
6853            commandForm.setAssociateProgramName(associateProgramName);
6854            commandForm.setAssociateName(associateName);
6855            commandForm.setAssociatePartyContactMechanismName(associatePartyContactMechanismName);
6856
6857            contentPage = CDI.current().select(GetContentPageCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
6858        } catch (NamingException ex) {
6859            throw new RuntimeException(ex);
6860        }
6861
6862        return contentPage == null ? null : new ContentPageObject(contentPage);
6863    }
6864
6865    @GraphQLField
6866    @GraphQLName("contentPages")
6867    @GraphQLNonNull
6868    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
6869    static CountingPaginatedData<ContentPageObject> contentPages(final DataFetchingEnvironment env,
6870            @GraphQLName("contentWebAddressName") final String contentWebAddressName,
6871            @GraphQLName("contentCollectionName") final String contentCollectionName,
6872            @GraphQLName("contentSectionName") final String contentSectionName,
6873            @GraphQLName("associateProgramName") final String associateProgramName,
6874            @GraphQLName("associateName") final String associateName,
6875            @GraphQLName("associatePartyContactMechanismName") final String associatePartyContactMechanismName) {
6876        CountingPaginatedData<ContentPageObject> data;
6877
6878        try {
6879            var commandForm = ContentUtil.getHome().getGetContentPagesForm();
6880            var command = CDI.current().select(GetContentPagesCommand.class).get();
6881
6882            commandForm.setContentWebAddressName(contentWebAddressName);
6883            commandForm.setContentCollectionName(contentCollectionName);
6884            commandForm.setContentSectionName(contentSectionName);
6885            commandForm.setAssociateProgramName(associateProgramName);
6886            commandForm.setAssociateName(associateName);
6887            commandForm.setAssociatePartyContactMechanismName(associatePartyContactMechanismName);
6888
6889            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6890            if(totalEntities == null) {
6891                data = Connections.emptyConnection();
6892            } else {
6893                try(var objectLimiter = new ObjectLimiter(env, ContentPageConstants.COMPONENT_VENDOR_NAME, ContentPageConstants.ENTITY_TYPE_NAME, totalEntities)) {
6894                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6895
6896                    var contentPages = entities.stream()
6897                            .map(ContentPageObject::new)
6898                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
6899
6900                    data = new CountedObjects<>(objectLimiter, contentPages);
6901                }
6902            }
6903        } catch (NamingException ex) {
6904            throw new RuntimeException(ex);
6905        }
6906
6907        return data;
6908    }
6909
6910    @GraphQLField
6911    @GraphQLName("contentPageArea")
6912    static ContentPageAreaObject contentPageArea(final DataFetchingEnvironment env,
6913            @GraphQLName("contentCollectionName") @GraphQLNonNull final String contentCollectionName,
6914            @GraphQLName("contentSectionName") @GraphQLNonNull final String contentSectionName,
6915            @GraphQLName("contentPageName") @GraphQLNonNull final String contentPageName,
6916            @GraphQLName("sortOrder") @GraphQLNonNull final String sortOrder,
6917            @GraphQLName("languageIsoName") @GraphQLNonNull final String languageIsoName) {
6918        ContentPageArea contentPageArea;
6919
6920        try {
6921            var commandForm = ContentUtil.getHome().getGetContentPageAreaForm();
6922
6923            commandForm.setContentCollectionName(contentCollectionName);
6924            commandForm.setContentSectionName(contentSectionName);
6925            commandForm.setContentPageName(contentPageName);
6926            commandForm.setSortOrder(sortOrder);
6927            commandForm.setLanguageIsoName(languageIsoName);
6928
6929            contentPageArea = CDI.current().select(GetContentPageAreaCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
6930        } catch (NamingException ex) {
6931            throw new RuntimeException(ex);
6932        }
6933
6934        return contentPageArea == null ? null : new ContentPageAreaObject(contentPageArea);
6935    }
6936
6937    @GraphQLField
6938    @GraphQLName("contentPageAreas")
6939    @GraphQLNonNull
6940    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
6941    static CountingPaginatedData<ContentPageAreaObject> contentPageAreas(final DataFetchingEnvironment env,
6942            @GraphQLName("contentCollectionName") @GraphQLNonNull final String contentCollectionName,
6943            @GraphQLName("contentSectionName") @GraphQLNonNull final String contentSectionName,
6944            @GraphQLName("contentPageName") @GraphQLNonNull final String contentPageName) {
6945        CountingPaginatedData<ContentPageAreaObject> data;
6946
6947        try {
6948            var commandForm = ContentUtil.getHome().getGetContentPageAreasForm();
6949            var command = CDI.current().select(GetContentPageAreasCommand.class).get();
6950
6951
6952            commandForm.setContentCollectionName(contentCollectionName);
6953            commandForm.setContentSectionName(contentSectionName);
6954            commandForm.setContentPageName(contentPageName);
6955
6956            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6957            if(totalEntities == null) {
6958                data = Connections.emptyConnection();
6959            } else {
6960                try(var objectLimiter = new ObjectLimiter(env, ContentPageAreaConstants.COMPONENT_VENDOR_NAME, ContentPageAreaConstants.ENTITY_TYPE_NAME, totalEntities)) {
6961                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
6962
6963                    var contentPageAreas = entities.stream()
6964                            .map(ContentPageAreaObject::new)
6965                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
6966
6967                    data = new CountedObjects<>(objectLimiter, contentPageAreas);
6968                }
6969            }
6970        } catch (NamingException ex) {
6971            throw new RuntimeException(ex);
6972        }
6973
6974        return data;
6975    }
6976
6977
6978    @GraphQLField
6979    @GraphQLName("contentCatalog")
6980    static ContentCatalogObject contentCatalog(final DataFetchingEnvironment env,
6981            @GraphQLName("contentWebAddressName") final String contentWebAddressName,
6982            @GraphQLName("contentCollectionName") final String contentCollectionName,
6983            @GraphQLName("contentCatalogName") final String contentCatalogName,
6984            @GraphQLName("associateProgramName") final String associateProgramName,
6985            @GraphQLName("associateName") final String associateName,
6986            @GraphQLName("associatePartyContactMechanismName") final String associatePartyContactMechanismName) {
6987        ContentCatalog contentCatalog;
6988
6989        try {
6990            var commandForm = ContentUtil.getHome().getGetContentCatalogForm();
6991
6992            commandForm.setContentWebAddressName(contentWebAddressName);
6993            commandForm.setContentCollectionName(contentCollectionName);
6994            commandForm.setContentCatalogName(contentCatalogName);
6995            commandForm.setAssociateProgramName(associateProgramName);
6996            commandForm.setAssociateName(associateName);
6997            commandForm.setAssociatePartyContactMechanismName(associatePartyContactMechanismName);
6998
6999            contentCatalog = CDI.current().select(GetContentCatalogCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
7000        } catch (NamingException ex) {
7001            throw new RuntimeException(ex);
7002        }
7003
7004        return contentCatalog == null ? null : new ContentCatalogObject(contentCatalog);
7005    }
7006
7007    @GraphQLField
7008    @GraphQLName("contentCatalogs")
7009    @GraphQLNonNull
7010    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
7011    static CountingPaginatedData<ContentCatalogObject> contentCatalogs(final DataFetchingEnvironment env,
7012            @GraphQLName("contentWebAddressName") final String contentWebAddressName,
7013            @GraphQLName("contentCollectionName") final String contentCollectionName,
7014            @GraphQLName("associateProgramName") final String associateProgramName,
7015            @GraphQLName("associateName") final String associateName,
7016            @GraphQLName("associatePartyContactMechanismName") final String associatePartyContactMechanismName) {
7017        CountingPaginatedData<ContentCatalogObject> data;
7018
7019        try {
7020            var commandForm = ContentUtil.getHome().getGetContentCatalogsForm();
7021            var command = CDI.current().select(GetContentCatalogsCommand.class).get();
7022
7023            commandForm.setContentWebAddressName(contentWebAddressName);
7024            commandForm.setContentCollectionName(contentCollectionName);
7025            commandForm.setAssociateProgramName(associateProgramName);
7026            commandForm.setAssociateName(associateName);
7027            commandForm.setAssociatePartyContactMechanismName(associatePartyContactMechanismName);
7028
7029            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7030            if(totalEntities == null) {
7031                data = Connections.emptyConnection();
7032            } else {
7033                try(var objectLimiter = new ObjectLimiter(env, ContentCatalogConstants.COMPONENT_VENDOR_NAME, ContentCatalogConstants.ENTITY_TYPE_NAME, totalEntities)) {
7034                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7035
7036                    var contentCatalogs = entities.stream()
7037                            .map(ContentCatalogObject::new)
7038                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
7039
7040                    data = new CountedObjects<>(objectLimiter, contentCatalogs);
7041                }
7042            }
7043        } catch (NamingException ex) {
7044            throw new RuntimeException(ex);
7045        }
7046
7047        return data;
7048    }
7049
7050    @GraphQLField
7051    @GraphQLName("contentCatalogItem")
7052    static ContentCatalogItemObject contentCatalogItem(final DataFetchingEnvironment env,
7053            @GraphQLName("contentWebAddressName") final String contentWebAddressName,
7054            @GraphQLName("contentCollectionName") final String contentCollectionName,
7055            @GraphQLName("contentCatalogName") final String contentCatalogName,
7056            @GraphQLName("itemName") @GraphQLNonNull final String itemName,
7057            @GraphQLName("inventoryConditionName") final String inventoryConditionName,
7058            @GraphQLName("unitOfMeasureTypeName") final String unitOfMeasureTypeName,
7059            @GraphQLName("currencyIsoName") final String currencyIsoName,
7060            @GraphQLName("associateProgramName") final String associateProgramName,
7061            @GraphQLName("associateName") final String associateName,
7062            @GraphQLName("associatePartyContactMechanismName") final String associatePartyContactMechanismName) {
7063        ContentCatalogItem contentCatalogItem;
7064
7065        try {
7066            var commandForm = ContentUtil.getHome().getGetContentCatalogItemForm();
7067
7068            commandForm.setContentWebAddressName(contentWebAddressName);
7069            commandForm.setContentCollectionName(contentCollectionName);
7070            commandForm.setContentCatalogName(contentCatalogName);
7071            commandForm.setItemName(itemName);
7072            commandForm.setInventoryConditionName(inventoryConditionName);
7073            commandForm.setUnitOfMeasureTypeName(unitOfMeasureTypeName);
7074            commandForm.setCurrencyIsoName(currencyIsoName);
7075            commandForm.setAssociateProgramName(associateProgramName);
7076            commandForm.setAssociateName(associateName);
7077            commandForm.setAssociatePartyContactMechanismName(associatePartyContactMechanismName);
7078
7079            contentCatalogItem = CDI.current().select(GetContentCatalogItemCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
7080        } catch (NamingException ex) {
7081            throw new RuntimeException(ex);
7082        }
7083
7084        return contentCatalogItem == null ? null : new ContentCatalogItemObject(contentCatalogItem);
7085    }
7086
7087    @GraphQLField
7088    @GraphQLName("contentCatalogItems")
7089    @GraphQLNonNull
7090    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
7091    static CountingPaginatedData<ContentCatalogItemObject> contentCatalogItems(final DataFetchingEnvironment env,
7092            @GraphQLName("contentWebAddressName") final String contentWebAddressName,
7093            @GraphQLName("contentCollectionName") final String contentCollectionName,
7094            @GraphQLName("contentCatalogName") final String contentCatalogName,
7095            @GraphQLName("associateProgramName") final String associateProgramName,
7096            @GraphQLName("associateName") final String associateName,
7097            @GraphQLName("associatePartyContactMechanismName") final String associatePartyContactMechanismName) {
7098        CountingPaginatedData<ContentCatalogItemObject> data;
7099
7100        try {
7101            var commandForm = ContentUtil.getHome().getGetContentCatalogItemsForm();
7102            var command = CDI.current().select(GetContentCatalogItemsCommand.class).get();
7103
7104            commandForm.setContentWebAddressName(contentWebAddressName);
7105            commandForm.setContentCollectionName(contentCollectionName);
7106            commandForm.setContentCatalogName(contentCatalogName);
7107            commandForm.setAssociateProgramName(associateProgramName);
7108            commandForm.setAssociateName(associateName);
7109            commandForm.setAssociatePartyContactMechanismName(associatePartyContactMechanismName);
7110
7111            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7112            if(totalEntities == null) {
7113                data = Connections.emptyConnection();
7114            } else {
7115                try(var objectLimiter = new ObjectLimiter(env, ContentCatalogItemConstants.COMPONENT_VENDOR_NAME, ContentCatalogItemConstants.ENTITY_TYPE_NAME, totalEntities)) {
7116                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7117
7118                    var contentCatalogItems = entities.stream()
7119                            .map(ContentCatalogItemObject::new)
7120                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
7121
7122                    data = new CountedObjects<>(objectLimiter, contentCatalogItems);
7123                }
7124            }
7125        } catch (NamingException ex) {
7126            throw new RuntimeException(ex);
7127        }
7128
7129        return data;
7130    }
7131
7132    @GraphQLField
7133    @GraphQLName("contentCategory")
7134    static ContentCategoryObject contentCategory(final DataFetchingEnvironment env,
7135            @GraphQLName("contentWebAddressName") final String contentWebAddressName,
7136            @GraphQLName("contentCollectionName") final String contentCollectionName,
7137            @GraphQLName("contentCatalogName") final String contentCatalogName,
7138            @GraphQLName("contentCategoryName") final String contentCategoryName,
7139            @GraphQLName("associateProgramName") final String associateProgramName,
7140            @GraphQLName("associateName") final String associateName,
7141            @GraphQLName("associatePartyContactMechanismName") final String associatePartyContactMechanismName) {
7142        ContentCategory contentCategory;
7143
7144        try {
7145            var commandForm = ContentUtil.getHome().getGetContentCategoryForm();
7146
7147            commandForm.setContentWebAddressName(contentWebAddressName);
7148            commandForm.setContentCollectionName(contentCollectionName);
7149            commandForm.setContentCatalogName(contentCatalogName);
7150            commandForm.setContentCategoryName(contentCategoryName);
7151            commandForm.setAssociateProgramName(associateProgramName);
7152            commandForm.setAssociateName(associateName);
7153            commandForm.setAssociatePartyContactMechanismName(associatePartyContactMechanismName);
7154
7155            contentCategory = CDI.current().select(GetContentCategoryCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
7156        } catch (NamingException ex) {
7157            throw new RuntimeException(ex);
7158        }
7159
7160        return contentCategory == null ? null : new ContentCategoryObject(contentCategory);
7161    }
7162
7163    @GraphQLField
7164    @GraphQLName("contentCategories")
7165    @GraphQLNonNull
7166    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
7167    static CountingPaginatedData<ContentCategoryObject> contentCategories(final DataFetchingEnvironment env,
7168            @GraphQLName("contentWebAddressName") final String contentWebAddressName,
7169            @GraphQLName("contentCollectionName") final String contentCollectionName,
7170            @GraphQLName("contentCatalogName") final String contentCatalogName,
7171            @GraphQLName("parentContentCategoryName") final String parentContentCategoryName,
7172            @GraphQLName("associateProgramName") final String associateProgramName,
7173            @GraphQLName("associateName") final String associateName,
7174            @GraphQLName("associatePartyContactMechanismName") final String associatePartyContactMechanismName) {
7175        CountingPaginatedData<ContentCategoryObject> data;
7176
7177        try {
7178            var commandForm = ContentUtil.getHome().getGetContentCategoriesForm();
7179            var command = CDI.current().select(GetContentCategoriesCommand.class).get();
7180
7181            commandForm.setContentWebAddressName(contentWebAddressName);
7182            commandForm.setContentCollectionName(contentCollectionName);
7183            commandForm.setContentCatalogName(contentCatalogName);
7184            commandForm.setParentContentCategoryName(parentContentCategoryName);
7185            commandForm.setAssociateProgramName(associateProgramName);
7186            commandForm.setAssociateName(associateName);
7187            commandForm.setAssociatePartyContactMechanismName(associatePartyContactMechanismName);
7188
7189            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7190            if(totalEntities == null) {
7191                data = Connections.emptyConnection();
7192            } else {
7193                try(var objectLimiter = new ObjectLimiter(env, ContentCategoryConstants.COMPONENT_VENDOR_NAME, ContentCategoryConstants.ENTITY_TYPE_NAME, totalEntities)) {
7194                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7195
7196                    var contentCategories = entities.stream()
7197                            .map(ContentCategoryObject::new)
7198                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
7199
7200                    data = new CountedObjects<>(objectLimiter, contentCategories);
7201                }
7202            }
7203        } catch (NamingException ex) {
7204            throw new RuntimeException(ex);
7205        }
7206
7207        return data;
7208    }
7209
7210    @GraphQLField
7211    @GraphQLName("contentCategoryItem")
7212    static ContentCategoryItemObject contentCategoryItem(final DataFetchingEnvironment env,
7213            @GraphQLName("contentWebAddressName") final String contentWebAddressName,
7214            @GraphQLName("contentCollectionName") final String contentCollectionName,
7215            @GraphQLName("contentCatalogName") final String contentCatalogName,
7216            @GraphQLName("contentCategoryName") final String contentCategoryName,
7217            @GraphQLName("itemName") @GraphQLNonNull final String itemName,
7218            @GraphQLName("inventoryConditionName") final String inventoryConditionName,
7219            @GraphQLName("unitOfMeasureTypeName") final String unitOfMeasureTypeName,
7220            @GraphQLName("currencyIsoName") final String currencyIsoName,
7221            @GraphQLName("associateProgramName") final String associateProgramName,
7222            @GraphQLName("associateName") final String associateName,
7223            @GraphQLName("associatePartyContactMechanismName") final String associatePartyContactMechanismName) {
7224        ContentCategoryItem contentCategoryItem;
7225
7226        try {
7227            var commandForm = ContentUtil.getHome().getGetContentCategoryItemForm();
7228
7229            commandForm.setContentWebAddressName(contentWebAddressName);
7230            commandForm.setContentCollectionName(contentCollectionName);
7231            commandForm.setContentCatalogName(contentCatalogName);
7232            commandForm.setContentCategoryName(contentCategoryName);
7233            commandForm.setItemName(itemName);
7234            commandForm.setInventoryConditionName(inventoryConditionName);
7235            commandForm.setUnitOfMeasureTypeName(unitOfMeasureTypeName);
7236            commandForm.setCurrencyIsoName(currencyIsoName);
7237            commandForm.setAssociateProgramName(associateProgramName);
7238            commandForm.setAssociateName(associateName);
7239            commandForm.setAssociatePartyContactMechanismName(associatePartyContactMechanismName);
7240
7241            contentCategoryItem = CDI.current().select(GetContentCategoryItemCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
7242        } catch (NamingException ex) {
7243            throw new RuntimeException(ex);
7244        }
7245
7246        return contentCategoryItem == null ? null : new ContentCategoryItemObject(contentCategoryItem);
7247    }
7248
7249    @GraphQLField
7250    @GraphQLName("contentCategoryItems")
7251    @GraphQLNonNull
7252    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
7253    static CountingPaginatedData<ContentCategoryItemObject> contentCategoryItems(final DataFetchingEnvironment env,
7254            @GraphQLName("contentWebAddressName") final String contentWebAddressName,
7255            @GraphQLName("contentCollectionName") final String contentCollectionName,
7256            @GraphQLName("contentCatalogName") final String contentCatalogName,
7257            @GraphQLName("contentCategoryName") final String contentCategoryName,
7258            @GraphQLName("associateProgramName") final String associateProgramName,
7259            @GraphQLName("associateName") final String associateName,
7260            @GraphQLName("associatePartyContactMechanismName") final String associatePartyContactMechanismName) {
7261        CountingPaginatedData<ContentCategoryItemObject> data;
7262
7263        try {
7264            var commandForm = ContentUtil.getHome().getGetContentCategoryItemsForm();
7265            var command = CDI.current().select(GetContentCategoryItemsCommand.class).get();
7266
7267            commandForm.setContentWebAddressName(contentWebAddressName);
7268            commandForm.setContentCollectionName(contentCollectionName);
7269            commandForm.setContentCatalogName(contentCatalogName);
7270            commandForm.setContentCategoryName(contentCategoryName);
7271            commandForm.setAssociateProgramName(associateProgramName);
7272            commandForm.setAssociateName(associateName);
7273            commandForm.setAssociatePartyContactMechanismName(associatePartyContactMechanismName);
7274
7275            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7276            if(totalEntities == null) {
7277                data = Connections.emptyConnection();
7278            } else {
7279                try(var objectLimiter = new ObjectLimiter(env, ContentCategoryItemConstants.COMPONENT_VENDOR_NAME, ContentCategoryItemConstants.ENTITY_TYPE_NAME, totalEntities)) {
7280                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7281
7282                    var contentCategoryItems = entities.stream()
7283                            .map(ContentCategoryItemObject::new)
7284                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
7285
7286                    data = new CountedObjects<>(objectLimiter, contentCategoryItems);
7287                }
7288            }
7289        } catch (NamingException ex) {
7290            throw new RuntimeException(ex);
7291        }
7292
7293        return data;
7294    }
7295
7296    @GraphQLField
7297    @GraphQLName("mimeTypeFileExtension")
7298    static MimeTypeFileExtensionObject mimeTypeFileExtension(final DataFetchingEnvironment env,
7299            @GraphQLName("fileExtension") @GraphQLNonNull final String fileExtension) {
7300        MimeTypeFileExtension mimeTypeFileExtension;
7301
7302        try {
7303            var commandForm = CoreUtil.getHome().getGetMimeTypeFileExtensionForm();
7304
7305            commandForm.setFileExtension(fileExtension);
7306
7307            mimeTypeFileExtension = CDI.current().select(GetMimeTypeFileExtensionCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
7308        } catch (NamingException ex) {
7309            throw new RuntimeException(ex);
7310        }
7311
7312        return mimeTypeFileExtension == null ? null : new MimeTypeFileExtensionObject(mimeTypeFileExtension);
7313    }
7314
7315    @GraphQLField
7316    @GraphQLName("mimeTypeFileExtensions")
7317    @GraphQLNonNull
7318    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
7319    static CountingPaginatedData<MimeTypeFileExtensionObject> mimeTypeFileExtensions(final DataFetchingEnvironment env) {
7320        CountingPaginatedData<MimeTypeFileExtensionObject> data;
7321
7322        try {
7323            var commandForm = CoreUtil.getHome().getGetMimeTypeFileExtensionsForm();
7324            var command = CDI.current().select(GetMimeTypeFileExtensionsCommand.class).get();
7325
7326            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7327            if(totalEntities == null) {
7328                data = Connections.emptyConnection();
7329            } else {
7330                try(var objectLimiter = new ObjectLimiter(env, MimeTypeFileExtensionConstants.COMPONENT_VENDOR_NAME, MimeTypeFileExtensionConstants.ENTITY_TYPE_NAME, totalEntities)) {
7331                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7332                    var mimeTypeFileExtensionObjects = entities.stream().map(MimeTypeFileExtensionObject::new).collect(Collectors.toList());
7333
7334                    data = new CountedObjects<>(objectLimiter, mimeTypeFileExtensionObjects);
7335                }
7336            }
7337        } catch (NamingException ex) {
7338            throw new RuntimeException(ex);
7339        }
7340
7341        return data;
7342    }
7343
7344    @GraphQLField
7345    @GraphQLName("mimeTypeUsageType")
7346    static MimeTypeUsageTypeObject mimeTypeUsageType(final DataFetchingEnvironment env,
7347            @GraphQLName("mimeTypeUsageTypeName") @GraphQLNonNull final String mimeTypeUsageTypeName) {
7348        MimeTypeUsageType mimeTypeUsageType;
7349
7350        try {
7351            var commandForm = CoreUtil.getHome().getGetMimeTypeUsageTypeForm();
7352
7353            commandForm.setMimeTypeUsageTypeName(mimeTypeUsageTypeName);
7354
7355            mimeTypeUsageType = CDI.current().select(GetMimeTypeUsageTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
7356        } catch (NamingException ex) {
7357            throw new RuntimeException(ex);
7358        }
7359
7360        return mimeTypeUsageType == null ? null : new MimeTypeUsageTypeObject(mimeTypeUsageType);
7361    }
7362
7363    @GraphQLField
7364    @GraphQLName("mimeTypeUsageTypes")
7365    @GraphQLNonNull
7366    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
7367    static CountingPaginatedData<MimeTypeUsageTypeObject> mimeTypeUsageTypes(final DataFetchingEnvironment env) {
7368        CountingPaginatedData<MimeTypeUsageTypeObject> data;
7369
7370        try {
7371            var commandForm = CoreUtil.getHome().getGetMimeTypeUsageTypesForm();
7372            var command = CDI.current().select(GetMimeTypeUsageTypesCommand.class).get();
7373
7374            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7375            if(totalEntities == null) {
7376                data = Connections.emptyConnection();
7377            } else {
7378                try(var objectLimiter = new ObjectLimiter(env, com.echothree.model.data.core.common.MimeTypeUsageTypeConstants.COMPONENT_VENDOR_NAME, com.echothree.model.data.core.common.MimeTypeUsageTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
7379                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7380
7381                    var mimeTypeUsageTypes = entities.stream()
7382                            .map(MimeTypeUsageTypeObject::new)
7383                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
7384
7385                    data = new CountedObjects<>(objectLimiter, mimeTypeUsageTypes);
7386                }
7387            }
7388        } catch (NamingException ex) {
7389            throw new RuntimeException(ex);
7390        }
7391
7392        return data;
7393    }
7394
7395    @GraphQLField
7396    @GraphQLName("mimeType")
7397    static MimeTypeObject mimeType(final DataFetchingEnvironment env,
7398            @GraphQLName("mimeTypeName") @GraphQLNonNull final String mimeTypeName) {
7399        MimeType mimeType;
7400
7401        try {
7402            var commandForm = CoreUtil.getHome().getGetMimeTypeForm();
7403
7404            commandForm.setMimeTypeName(mimeTypeName);
7405
7406            mimeType = CDI.current().select(GetMimeTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
7407        } catch (NamingException ex) {
7408            throw new RuntimeException(ex);
7409        }
7410
7411        return mimeType == null ? null : new MimeTypeObject(mimeType);
7412    }
7413
7414    @GraphQLField
7415    @GraphQLName("mimeTypes")
7416    @GraphQLNonNull
7417    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
7418    static CountingPaginatedData<MimeTypeObject> mimeTypes(final DataFetchingEnvironment env,
7419            @GraphQLName("mimeTypeUsageTypeName") final String mimeTypeUsageTypeName) {
7420        CountingPaginatedData<MimeTypeObject> data;
7421
7422        try {
7423            var commandForm = CoreUtil.getHome().getGetMimeTypesForm();
7424            var command = CDI.current().select(GetMimeTypesCommand.class).get();
7425
7426            commandForm.setMimeTypeUsageTypeName(mimeTypeUsageTypeName);
7427
7428            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7429            if(totalEntities == null) {
7430                data = Connections.emptyConnection();
7431            } else {
7432                try(var objectLimiter = new ObjectLimiter(env, MimeTypeConstants.COMPONENT_VENDOR_NAME, MimeTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
7433                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7434
7435                    var mimeTypes = entities.stream()
7436                            .map(MimeTypeObject::new)
7437                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
7438
7439                    data = new CountedObjects<>(objectLimiter, mimeTypes);
7440                }
7441            }
7442        } catch (NamingException ex) {
7443            throw new RuntimeException(ex);
7444        }
7445
7446        return data;
7447    }
7448
7449    @GraphQLField
7450    @GraphQLName("queueType")
7451    static QueueTypeObject queueType(final DataFetchingEnvironment env,
7452            @GraphQLName("queueTypeName") @GraphQLNonNull final String queueTypeName) {
7453        QueueType queueType;
7454
7455        try {
7456            var commandForm = QueueUtil.getHome().getGetQueueTypeForm();
7457
7458            commandForm.setQueueTypeName(queueTypeName);
7459
7460            queueType = CDI.current().select(GetQueueTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
7461        } catch (NamingException ex) {
7462            throw new RuntimeException(ex);
7463        }
7464
7465        return queueType == null ? null : new QueueTypeObject(queueType);
7466    }
7467
7468    @GraphQLField
7469    @GraphQLName("queueTypes")
7470    @GraphQLNonNull
7471    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
7472    static CountingPaginatedData<QueueTypeObject> queueTypes(final DataFetchingEnvironment env) {
7473        CountingPaginatedData<QueueTypeObject> data;
7474
7475        try {
7476            var commandForm = QueueUtil.getHome().getGetQueueTypesForm();
7477            var command = CDI.current().select(GetQueueTypesCommand.class).get();
7478
7479            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7480            if(totalEntities == null) {
7481                data = Connections.emptyConnection();
7482            } else {
7483                try(var objectLimiter = new ObjectLimiter(env, QueueTypeConstants.COMPONENT_VENDOR_NAME, QueueTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
7484                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7485
7486                    var queueTypes = entities.stream()
7487                            .map(QueueTypeObject::new)
7488                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
7489
7490                    data = new CountedObjects<>(objectLimiter, queueTypes);
7491                }
7492            }
7493        } catch (NamingException ex) {
7494            throw new RuntimeException(ex);
7495        }
7496
7497        return data;
7498    }
7499
7500    @GraphQLField
7501    @GraphQLName("unitOfMeasureKindUse")
7502    static UnitOfMeasureKindUseObject unitOfMeasureKindUse(final DataFetchingEnvironment env,
7503            @GraphQLName("unitOfMeasureKindUseTypeName") @GraphQLNonNull final String unitOfMeasureKindUseTypeName,
7504            @GraphQLName("unitOfMeasureKindName") @GraphQLNonNull final String unitOfMeasureKindName) {
7505        UnitOfMeasureKindUse unitOfMeasureKindUse;
7506
7507        try {
7508            var commandForm = UomUtil.getHome().getGetUnitOfMeasureKindUseForm();
7509
7510            commandForm.setUnitOfMeasureKindUseTypeName(unitOfMeasureKindUseTypeName);
7511            commandForm.setUnitOfMeasureKindName(unitOfMeasureKindName);
7512
7513            unitOfMeasureKindUse = CDI.current().select(GetUnitOfMeasureKindUseCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
7514        } catch (NamingException ex) {
7515            throw new RuntimeException(ex);
7516        }
7517
7518        return unitOfMeasureKindUse == null ? null : new UnitOfMeasureKindUseObject(unitOfMeasureKindUse);
7519    }
7520
7521    @GraphQLField
7522    @GraphQLName("unitOfMeasureKindUses")
7523    @GraphQLNonNull
7524    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
7525    static CountingPaginatedData<UnitOfMeasureKindUseObject> unitOfMeasureKindUses(final DataFetchingEnvironment env,
7526            @GraphQLName("unitOfMeasureKindUseTypeName") final String unitOfMeasureKindUseTypeName,
7527            @GraphQLName("unitOfMeasureKindName") final String unitOfMeasureKindName) {
7528        CountingPaginatedData<UnitOfMeasureKindUseObject> data;
7529
7530        try {
7531            var commandForm = UomUtil.getHome().getGetUnitOfMeasureKindUsesForm();
7532            var command = CDI.current().select(GetUnitOfMeasureKindUsesCommand.class).get();
7533
7534            commandForm.setUnitOfMeasureKindUseTypeName(unitOfMeasureKindUseTypeName);
7535            commandForm.setUnitOfMeasureKindName(unitOfMeasureKindName);
7536
7537            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7538            if(totalEntities == null) {
7539                data = Connections.emptyConnection();
7540            } else {
7541                try(var objectLimiter = new ObjectLimiter(env, UnitOfMeasureKindUseConstants.COMPONENT_VENDOR_NAME, UnitOfMeasureKindUseConstants.ENTITY_TYPE_NAME, totalEntities)) {
7542                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7543
7544                    var unitOfMeasureKindUses = entities.stream()
7545                            .map(UnitOfMeasureKindUseObject::new)
7546                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
7547
7548                    data = new CountedObjects<>(objectLimiter, unitOfMeasureKindUses);
7549                }
7550            }
7551        } catch (NamingException ex) {
7552            throw new RuntimeException(ex);
7553        }
7554
7555        return data;
7556    }
7557
7558    @GraphQLField
7559    @GraphQLName("unitOfMeasureType")
7560    static UnitOfMeasureTypeObject unitOfMeasureType(final DataFetchingEnvironment env,
7561            @GraphQLName("unitOfMeasureKindName") @GraphQLNonNull final String unitOfMeasureKindName,
7562            @GraphQLName("unitOfMeasureTypeName") @GraphQLNonNull final String unitOfMeasureTypeName) {
7563        UnitOfMeasureType unitOfMeasureType;
7564
7565        try {
7566            var commandForm = UomUtil.getHome().getGetUnitOfMeasureTypeForm();
7567
7568            commandForm.setUnitOfMeasureKindName(unitOfMeasureKindName);
7569            commandForm.setUnitOfMeasureTypeName(unitOfMeasureTypeName);
7570
7571            unitOfMeasureType = CDI.current().select(GetUnitOfMeasureTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
7572        } catch (NamingException ex) {
7573            throw new RuntimeException(ex);
7574        }
7575
7576        return unitOfMeasureType == null ? null : new UnitOfMeasureTypeObject(unitOfMeasureType);
7577    }
7578
7579    @GraphQLField
7580    @GraphQLName("unitOfMeasureTypes")
7581    @GraphQLNonNull
7582    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
7583    static CountingPaginatedData<UnitOfMeasureTypeObject> unitOfMeasureTypes(final DataFetchingEnvironment env,
7584            @GraphQLName("unitOfMeasureKindName") @GraphQLNonNull final String unitOfMeasureKindName) {
7585        CountingPaginatedData<UnitOfMeasureTypeObject> data;
7586
7587        try {
7588            var commandForm = UomUtil.getHome().getGetUnitOfMeasureTypesForm();
7589            var command = CDI.current().select(GetUnitOfMeasureTypesCommand.class).get();
7590
7591            commandForm.setUnitOfMeasureKindName(unitOfMeasureKindName);
7592
7593            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7594            if(totalEntities == null) {
7595                data = Connections.emptyConnection();
7596            } else {
7597                try(var objectLimiter = new ObjectLimiter(env, UnitOfMeasureTypeConstants.COMPONENT_VENDOR_NAME, UnitOfMeasureTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
7598                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7599
7600                    var unitOfMeasureTypes = entities.stream()
7601                            .map(UnitOfMeasureTypeObject::new)
7602                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
7603
7604                    data = new CountedObjects<>(objectLimiter, unitOfMeasureTypes);
7605                }
7606            }
7607        } catch (NamingException ex) {
7608            throw new RuntimeException(ex);
7609        }
7610
7611        return data;
7612    }
7613
7614    @GraphQLField
7615    @GraphQLName("unitOfMeasureKind")
7616    static UnitOfMeasureKindObject unitOfMeasureKind(final DataFetchingEnvironment env,
7617            @GraphQLName("unitOfMeasureKindName") @GraphQLNonNull final String unitOfMeasureKindName) {
7618        UnitOfMeasureKind unitOfMeasureKind;
7619
7620        try {
7621            var commandForm = UomUtil.getHome().getGetUnitOfMeasureKindForm();
7622
7623            commandForm.setUnitOfMeasureKindName(unitOfMeasureKindName);
7624
7625            unitOfMeasureKind = CDI.current().select(GetUnitOfMeasureKindCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
7626        } catch (NamingException ex) {
7627            throw new RuntimeException(ex);
7628        }
7629
7630        return unitOfMeasureKind == null ? null : new UnitOfMeasureKindObject(unitOfMeasureKind);
7631    }
7632
7633    @GraphQLField
7634    @GraphQLName("unitOfMeasureKinds")
7635    @GraphQLNonNull
7636    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
7637    static CountingPaginatedData<UnitOfMeasureKindObject> unitOfMeasureKinds(final DataFetchingEnvironment env) {
7638        CountingPaginatedData<UnitOfMeasureKindObject> data;
7639
7640        try {
7641            var commandForm = UomUtil.getHome().getGetUnitOfMeasureKindsForm();
7642            var command = CDI.current().select(GetUnitOfMeasureKindsCommand.class).get();
7643
7644            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7645            if(totalEntities == null) {
7646                data = Connections.emptyConnection();
7647            } else {
7648                try(var objectLimiter = new ObjectLimiter(env, UnitOfMeasureKindConstants.COMPONENT_VENDOR_NAME, UnitOfMeasureKindConstants.ENTITY_TYPE_NAME, totalEntities)) {
7649                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7650
7651                    var unitOfMeasureKinds = entities.stream()
7652                            .map(UnitOfMeasureKindObject::new)
7653                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
7654
7655                    data = new CountedObjects<>(objectLimiter, unitOfMeasureKinds);
7656                }
7657            }
7658        } catch (NamingException ex) {
7659            throw new RuntimeException(ex);
7660        }
7661
7662        return data;
7663    }
7664
7665    @GraphQLField
7666    @GraphQLName("unitOfMeasureKindUseType")
7667    static UnitOfMeasureKindUseTypeObject unitOfMeasureKindUseType(final DataFetchingEnvironment env,
7668            @GraphQLName("unitOfMeasureKindUseTypeName") @GraphQLNonNull final String unitOfMeasureKindUseTypeName) {
7669        UnitOfMeasureKindUseType unitOfMeasureKindUseType;
7670
7671        try {
7672            var commandForm = UomUtil.getHome().getGetUnitOfMeasureKindUseTypeForm();
7673
7674            commandForm.setUnitOfMeasureKindUseTypeName(unitOfMeasureKindUseTypeName);
7675
7676            unitOfMeasureKindUseType = CDI.current().select(GetUnitOfMeasureKindUseTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
7677        } catch (NamingException ex) {
7678            throw new RuntimeException(ex);
7679        }
7680
7681        return unitOfMeasureKindUseType == null ? null : new UnitOfMeasureKindUseTypeObject(unitOfMeasureKindUseType);
7682    }
7683
7684    @GraphQLField
7685    @GraphQLName("unitOfMeasureKindUseTypes")
7686    @GraphQLNonNull
7687    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
7688    static CountingPaginatedData<UnitOfMeasureKindUseTypeObject> unitOfMeasureKindUseTypes(final DataFetchingEnvironment env) {
7689        CountingPaginatedData<UnitOfMeasureKindUseTypeObject> data;
7690
7691        try {
7692            var commandForm = UomUtil.getHome().getGetUnitOfMeasureKindUseTypesForm();
7693            var command = CDI.current().select(GetUnitOfMeasureKindUseTypesCommand.class).get();
7694
7695            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7696            if(totalEntities == null) {
7697                data = Connections.emptyConnection();
7698            } else {
7699                try(var objectLimiter = new ObjectLimiter(env, UnitOfMeasureKindUseTypeConstants.COMPONENT_VENDOR_NAME, UnitOfMeasureKindUseTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
7700                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7701
7702                    var objects = entities.stream()
7703                            .map(UnitOfMeasureKindUseTypeObject::new)
7704                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
7705
7706                    data = new CountedObjects<>(objectLimiter, objects);
7707                }
7708            }
7709        } catch (NamingException ex) {
7710            throw new RuntimeException(ex);
7711        }
7712
7713        return data;
7714    }
7715
7716    @GraphQLField
7717    @GraphQLName("entityAttributeType")
7718    static EntityAttributeTypeObject entityAttributeType(final DataFetchingEnvironment env,
7719            @GraphQLName("entityAttributeTypeName") @GraphQLNonNull final String entityAttributeTypeName) {
7720        EntityAttributeType entityAttributeType;
7721
7722        try {
7723            var commandForm = CoreUtil.getHome().getGetEntityAttributeTypeForm();
7724
7725            commandForm.setEntityAttributeTypeName(entityAttributeTypeName);
7726
7727            entityAttributeType = CDI.current().select(GetEntityAttributeTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
7728        } catch (NamingException ex) {
7729            throw new RuntimeException(ex);
7730        }
7731
7732        return entityAttributeType == null ? null : new EntityAttributeTypeObject(entityAttributeType);
7733    }
7734
7735    @GraphQLField
7736    @GraphQLName("entityAttributeTypes")
7737    @GraphQLNonNull
7738    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
7739    static CountingPaginatedData<EntityAttributeTypeObject> entityAttributeTypes(final DataFetchingEnvironment env) {
7740        CountingPaginatedData<EntityAttributeTypeObject> data;
7741
7742        try {
7743            var commandForm = CoreUtil.getHome().getGetEntityAttributeTypesForm();
7744            var command = CDI.current().select(GetEntityAttributeTypesCommand.class).get();
7745
7746            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7747            if(totalEntities == null) {
7748                data = Connections.emptyConnection();
7749            } else {
7750                try(var objectLimiter = new ObjectLimiter(env, EntityAttributeTypeConstants.COMPONENT_VENDOR_NAME, EntityAttributeTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
7751                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
7752
7753                    var entityAttributeTypes = entities.stream()
7754                            .map(EntityAttributeTypeObject::new)
7755                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
7756
7757                    data = new CountedObjects<>(objectLimiter, entityAttributeTypes);
7758                }
7759            }
7760        } catch (NamingException ex) {
7761            throw new RuntimeException(ex);
7762        }
7763
7764        return data;
7765    }
7766
7767    @GraphQLField
7768    @GraphQLName("componentVendorResults")
7769    static ComponentVendorResultsObject componentVendorResults(final DataFetchingEnvironment env,
7770            @GraphQLName("searchTypeName") @GraphQLNonNull final String searchTypeName) {
7771        ComponentVendorResultsObject componentVendorResultsObject = null;
7772
7773        try {
7774            var commandForm = SearchUtil.getHome().getGetComponentVendorResultsForm();
7775
7776            commandForm.setSearchTypeName(searchTypeName);
7777
7778            if(CDI.current().select(GetComponentVendorResultsCommand.class).get().canQueryByGraphQl(getUserVisitPK(env), commandForm)) {
7779                componentVendorResultsObject = new ComponentVendorResultsObject(commandForm);
7780            }
7781        } catch (NamingException ex) {
7782            throw new RuntimeException(ex);
7783        }
7784
7785        return componentVendorResultsObject;
7786    }
7787
7788    @GraphQLField
7789    @GraphQLName("entityTypeResults")
7790    static EntityTypeResultsObject entityTypeResults(final DataFetchingEnvironment env,
7791            @GraphQLName("searchTypeName") @GraphQLNonNull final String searchTypeName) {
7792        EntityTypeResultsObject entityTypeResultsObject = null;
7793
7794        try {
7795            var commandForm = SearchUtil.getHome().getGetEntityTypeResultsForm();
7796
7797            commandForm.setSearchTypeName(searchTypeName);
7798
7799            if(CDI.current().select(GetEntityTypeResultsCommand.class).get().canQueryByGraphQl(getUserVisitPK(env), commandForm)) {
7800                entityTypeResultsObject = new EntityTypeResultsObject(commandForm);
7801            }
7802        } catch (NamingException ex) {
7803            throw new RuntimeException(ex);
7804        }
7805
7806        return entityTypeResultsObject;
7807    }
7808
7809    @GraphQLField
7810    @GraphQLName("entityAliasTypeResults")
7811    static EntityAliasTypeResultsObject entityAliasTypeResults(final DataFetchingEnvironment env,
7812            @GraphQLName("searchTypeName") @GraphQLNonNull final String searchTypeName) {
7813        EntityAliasTypeResultsObject entityAliasTypeResultsObject = null;
7814
7815        try {
7816            var commandForm = SearchUtil.getHome().getGetEntityAliasTypeResultsForm();
7817
7818            commandForm.setSearchTypeName(searchTypeName);
7819
7820            if(CDI.current().select(GetEntityAliasTypeResultsCommand.class).get().canQueryByGraphQl(getUserVisitPK(env), commandForm)) {
7821                entityAliasTypeResultsObject = new EntityAliasTypeResultsObject(commandForm);
7822            }
7823        } catch (NamingException ex) {
7824            throw new RuntimeException(ex);
7825        }
7826
7827        return entityAliasTypeResultsObject;
7828    }
7829
7830    @GraphQLField
7831    @GraphQLName("entityAttributeGroupResults")
7832    static EntityAttributeGroupResultsObject entityAttributeGroupResults(final DataFetchingEnvironment env,
7833            @GraphQLName("searchTypeName") @GraphQLNonNull final String searchTypeName) {
7834        EntityAttributeGroupResultsObject entityAttributeGroupResultsObject = null;
7835
7836        try {
7837            var commandForm = SearchUtil.getHome().getGetEntityAttributeGroupResultsForm();
7838
7839            commandForm.setSearchTypeName(searchTypeName);
7840
7841            if(CDI.current().select(GetEntityAttributeGroupResultsCommand.class).get().canQueryByGraphQl(getUserVisitPK(env), commandForm)) {
7842                entityAttributeGroupResultsObject = new EntityAttributeGroupResultsObject(commandForm);
7843            }
7844        } catch (NamingException ex) {
7845            throw new RuntimeException(ex);
7846        }
7847
7848        return entityAttributeGroupResultsObject;
7849    }
7850
7851    @GraphQLField
7852    @GraphQLName("entityAttributeResults")
7853    static EntityAttributeResultsObject entityAttributeResults(final DataFetchingEnvironment env,
7854            @GraphQLName("searchTypeName") @GraphQLNonNull final String searchTypeName) {
7855        EntityAttributeResultsObject entityAttributeResultsObject = null;
7856
7857        try {
7858            var commandForm = SearchUtil.getHome().getGetEntityAttributeResultsForm();
7859
7860            commandForm.setSearchTypeName(searchTypeName);
7861
7862            if(CDI.current().select(GetEntityAttributeResultsCommand.class).get().canQueryByGraphQl(getUserVisitPK(env), commandForm)) {
7863                entityAttributeResultsObject = new EntityAttributeResultsObject(commandForm);
7864            }
7865        } catch (NamingException ex) {
7866            throw new RuntimeException(ex);
7867        }
7868
7869        return entityAttributeResultsObject;
7870    }
7871
7872    @GraphQLField
7873    @GraphQLName("entityListItemResults")
7874    static EntityListItemResultsObject entityListItemResults(final DataFetchingEnvironment env,
7875            @GraphQLName("searchTypeName") @GraphQLNonNull final String searchTypeName) {
7876        EntityListItemResultsObject entityListItemResultsObject = null;
7877
7878        try {
7879            var commandForm = SearchUtil.getHome().getGetEntityListItemResultsForm();
7880
7881            commandForm.setSearchTypeName(searchTypeName);
7882
7883            if(CDI.current().select(GetEntityListItemResultsCommand.class).get().canQueryByGraphQl(getUserVisitPK(env), commandForm)) {
7884                entityListItemResultsObject = new EntityListItemResultsObject(commandForm);
7885            }
7886        } catch (NamingException ex) {
7887            throw new RuntimeException(ex);
7888        }
7889
7890        return entityListItemResultsObject;
7891    }
7892
7893    @GraphQLField
7894    @GraphQLName("customerResults")
7895    static CustomerResultsObject customerResults(final DataFetchingEnvironment env,
7896            @GraphQLName("searchTypeName") @GraphQLNonNull final String searchTypeName) {
7897        CustomerResultsObject customerResultsObject = null;
7898
7899        try {
7900            var commandForm = SearchUtil.getHome().getGetCustomerResultsForm();
7901
7902            commandForm.setSearchTypeName(searchTypeName);
7903
7904            if(CDI.current().select(GetCustomerResultsCommand.class).get().canQueryByGraphQl(getUserVisitPK(env), commandForm)) {
7905                customerResultsObject = new CustomerResultsObject(commandForm);
7906            }
7907        } catch (NamingException ex) {
7908            throw new RuntimeException(ex);
7909        }
7910
7911        return customerResultsObject;
7912    }
7913
7914    @GraphQLField
7915    @GraphQLName("employeeResults")
7916    static EmployeeResultsObject employeeResults(final DataFetchingEnvironment env,
7917            @GraphQLName("searchTypeName") @GraphQLNonNull final String searchTypeName) {
7918        EmployeeResultsObject employeeResultsObject = null;
7919
7920        try {
7921            var commandForm = SearchUtil.getHome().getGetEmployeeResultsForm();
7922
7923            commandForm.setSearchTypeName(searchTypeName);
7924
7925            if(CDI.current().select(GetEmployeeResultsCommand.class).get().canQueryByGraphQl(getUserVisitPK(env), commandForm)) {
7926                employeeResultsObject = new EmployeeResultsObject(commandForm);
7927            }
7928        } catch (NamingException ex) {
7929            throw new RuntimeException(ex);
7930        }
7931
7932        return employeeResultsObject;
7933    }
7934
7935    @GraphQLField
7936    @GraphQLName("itemResults")
7937    static ItemResultsObject itemResults(final DataFetchingEnvironment env,
7938            @GraphQLName("searchTypeName") @GraphQLNonNull final String searchTypeName) {
7939        ItemResultsObject itemResultsObject = null;
7940
7941        try {
7942            var commandForm = SearchUtil.getHome().getGetItemResultsForm();
7943
7944            commandForm.setSearchTypeName(searchTypeName);
7945
7946            if(CDI.current().select(GetItemResultsCommand.class).get().canQueryByGraphQl(getUserVisitPK(env), commandForm)) {
7947                itemResultsObject = new ItemResultsObject(commandForm);
7948            }
7949        } catch (NamingException ex) {
7950            throw new RuntimeException(ex);
7951        }
7952
7953        return itemResultsObject;
7954    }
7955
7956    @GraphQLField
7957    @GraphQLName("checkItemSpelling")
7958    static CheckItemSpellingObject checkItemSpelling(final DataFetchingEnvironment env,
7959            @GraphQLName("languageIsoName") final String languageIsoName,
7960            @GraphQLName("searchDefaultOperatorName") final String searchDefaultOperatorName,
7961            @GraphQLName("searchTypeName") @GraphQLNonNull final String searchTypeName,
7962            @GraphQLName("q") final String q) {
7963        var checkItemSpellingObject = new CheckItemSpellingObject();
7964
7965        try {
7966            var commandForm = SearchUtil.getHome().getCheckItemSpellingForm();
7967
7968            commandForm.setLanguageIsoName(languageIsoName);
7969            commandForm.setSearchDefaultOperatorName(searchDefaultOperatorName);
7970            commandForm.setSearchTypeName(searchTypeName);
7971            commandForm.setQ(q);
7972
7973            var commandResult = SearchUtil.getHome().checkItemSpelling(getUserVisitPK(env), commandForm);
7974            checkItemSpellingObject.setCommandResult(commandResult);
7975            checkItemSpellingObject.setResult(commandResult.hasErrors() ? null : commandResult.getExecutionResult().getResult());
7976        } catch (NamingException ex) {
7977            throw new RuntimeException(ex);
7978        }
7979
7980        return checkItemSpellingObject;
7981    }
7982
7983    @GraphQLField
7984    @GraphQLName("vendorResults")
7985    static VendorResultsObject vendorResults(final DataFetchingEnvironment env,
7986            @GraphQLName("searchTypeName") @GraphQLNonNull final String searchTypeName) {
7987        VendorResultsObject vendorResultsObject = null;
7988
7989        try {
7990            var commandForm = SearchUtil.getHome().getGetVendorResultsForm();
7991
7992            commandForm.setSearchTypeName(searchTypeName);
7993
7994            if(CDI.current().select(GetVendorResultsCommand.class).get().canQueryByGraphQl(getUserVisitPK(env), commandForm)) {
7995                vendorResultsObject = new VendorResultsObject(commandForm);
7996            }
7997        } catch (NamingException ex) {
7998            throw new RuntimeException(ex);
7999        }
8000
8001        return vendorResultsObject;
8002    }
8003
8004    @GraphQLField
8005    @GraphQLName("shippingMethodResults")
8006    static ShippingMethodResultsObject shippingMethodResults(final DataFetchingEnvironment env,
8007            @GraphQLName("searchTypeName") @GraphQLNonNull final String searchTypeName) {
8008        ShippingMethodResultsObject shippingMethodResultsObject = null;
8009
8010        try {
8011            var commandForm = SearchUtil.getHome().getGetShippingMethodResultsForm();
8012
8013            commandForm.setSearchTypeName(searchTypeName);
8014
8015            if(CDI.current().select(GetShippingMethodResultsCommand.class).get().canQueryByGraphQl(getUserVisitPK(env), commandForm)) {
8016                shippingMethodResultsObject = new ShippingMethodResultsObject(commandForm);
8017            }
8018        } catch (NamingException ex) {
8019            throw new RuntimeException(ex);
8020        }
8021
8022        return shippingMethodResultsObject;
8023    }
8024
8025    @GraphQLField
8026    @GraphQLName("warehouseResults")
8027    static WarehouseResultsObject warehouseResults(final DataFetchingEnvironment env,
8028            @GraphQLName("searchTypeName") @GraphQLNonNull final String searchTypeName) {
8029        WarehouseResultsObject warehouseResultsObject = null;
8030
8031        try {
8032            var commandForm = SearchUtil.getHome().getGetWarehouseResultsForm();
8033
8034            commandForm.setSearchTypeName(searchTypeName);
8035
8036            if(CDI.current().select(GetWarehouseResultsCommand.class).get().canQueryByGraphQl(getUserVisitPK(env), commandForm)) {
8037                warehouseResultsObject = new WarehouseResultsObject(commandForm);
8038            }
8039        } catch (NamingException ex) {
8040            throw new RuntimeException(ex);
8041        }
8042
8043        return warehouseResultsObject;
8044    }
8045
8046    @GraphQLField
8047    @GraphQLName("contentCatalogResults")
8048    static ContentCatalogResultsObject contentCatalogResults(final DataFetchingEnvironment env,
8049            @GraphQLName("searchTypeName") @GraphQLNonNull final String searchTypeName) {
8050        ContentCatalogResultsObject contentCatalogResultsObject = null;
8051
8052        try {
8053            var commandForm = SearchUtil.getHome().getGetContentCatalogResultsForm();
8054
8055            commandForm.setSearchTypeName(searchTypeName);
8056
8057            if(CDI.current().select(GetContentCatalogResultsCommand.class).get().canQueryByGraphQl(getUserVisitPK(env), commandForm)) {
8058                contentCatalogResultsObject = new ContentCatalogResultsObject(commandForm);
8059            }
8060        } catch (NamingException ex) {
8061            throw new RuntimeException(ex);
8062        }
8063
8064        return contentCatalogResultsObject;
8065    }
8066
8067    @GraphQLField
8068    @GraphQLName("contentCatalogItemResults")
8069    static ContentCatalogItemResultsObject contentCatalogItemResults(final DataFetchingEnvironment env,
8070            @GraphQLName("searchTypeName") @GraphQLNonNull final String searchTypeName) {
8071        ContentCatalogItemResultsObject contentCatalogItemResultsObject = null;
8072
8073        try {
8074            var commandForm = SearchUtil.getHome().getGetContentCatalogItemResultsForm();
8075
8076            commandForm.setSearchTypeName(searchTypeName);
8077
8078            if(CDI.current().select(GetContentCatalogItemResultsCommand.class).get().canQueryByGraphQl(getUserVisitPK(env), commandForm)) {
8079                contentCatalogItemResultsObject = new ContentCatalogItemResultsObject(commandForm);
8080            }
8081        } catch (NamingException ex) {
8082            throw new RuntimeException(ex);
8083        }
8084
8085        return contentCatalogItemResultsObject;
8086    }
8087
8088    @GraphQLField
8089    @GraphQLName("contentCategoryResults")
8090    static ContentCategoryResultsObject contentCategoryResults(final DataFetchingEnvironment env,
8091            @GraphQLName("searchTypeName") @GraphQLNonNull final String searchTypeName) {
8092        ContentCategoryResultsObject contentCategoryResultsObject = null;
8093
8094        try {
8095            var commandForm = SearchUtil.getHome().getGetContentCategoryResultsForm();
8096
8097            commandForm.setSearchTypeName(searchTypeName);
8098
8099            if(CDI.current().select(GetContentCategoryResultsCommand.class).get().canQueryByGraphQl(getUserVisitPK(env), commandForm)) {
8100                contentCategoryResultsObject = new ContentCategoryResultsObject(commandForm);
8101            }
8102        } catch (NamingException ex) {
8103            throw new RuntimeException(ex);
8104        }
8105
8106        return contentCategoryResultsObject;
8107    }
8108
8109    @GraphQLField
8110    @GraphQLName("color")
8111    static ColorObject color(final DataFetchingEnvironment env,
8112            @GraphQLName("colorName") final String colorName,
8113            @GraphQLName("id") @GraphQLID final String id) {
8114        Color color;
8115
8116        try {
8117            var commandForm = CoreUtil.getHome().getGetColorForm();
8118
8119            commandForm.setColorName(colorName);
8120            commandForm.setUuid(id);
8121
8122            color = CDI.current().select(GetColorCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
8123        } catch (NamingException ex) {
8124            throw new RuntimeException(ex);
8125        }
8126
8127        return color == null ? null : new ColorObject(color);
8128    }
8129
8130    @GraphQLField
8131    @GraphQLName("colors")
8132    @GraphQLNonNull
8133    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
8134    static CountingPaginatedData<ColorObject> colors(final DataFetchingEnvironment env) {
8135        CountingPaginatedData<ColorObject> data;
8136
8137        try {
8138            var commandForm = CoreUtil.getHome().getGetColorsForm();
8139            var command = CDI.current().select(GetColorsCommand.class).get();
8140
8141            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8142            if(totalEntities == null) {
8143                data = Connections.emptyConnection();
8144            } else {
8145                try(var objectLimiter = new ObjectLimiter(env, ColorConstants.COMPONENT_VENDOR_NAME, ColorConstants.ENTITY_TYPE_NAME, totalEntities)) {
8146                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8147
8148                    var colors = entities.stream()
8149                            .map(ColorObject::new)
8150                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
8151
8152                    data = new CountedObjects<>(objectLimiter, colors);
8153                }
8154            }
8155        } catch (NamingException ex) {
8156            throw new RuntimeException(ex);
8157        }
8158
8159        return data;
8160    }
8161
8162    @GraphQLField
8163    @GraphQLName("fontStyle")
8164    static FontStyleObject fontStyle(final DataFetchingEnvironment env,
8165            @GraphQLName("fontStyleName") final String fontStyleName,
8166            @GraphQLName("id") @GraphQLID final String id) {
8167        FontStyle fontStyle;
8168
8169        try {
8170            var commandForm = CoreUtil.getHome().getGetFontStyleForm();
8171
8172            commandForm.setFontStyleName(fontStyleName);
8173            commandForm.setUuid(id);
8174
8175            fontStyle = CDI.current().select(GetFontStyleCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
8176        } catch (NamingException ex) {
8177            throw new RuntimeException(ex);
8178        }
8179
8180        return fontStyle == null ? null : new FontStyleObject(fontStyle);
8181    }
8182
8183    @GraphQLField
8184    @GraphQLName("fontStyles")
8185    @GraphQLNonNull
8186    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
8187    static CountingPaginatedData<FontStyleObject> fontStyles(final DataFetchingEnvironment env) {
8188        CountingPaginatedData<FontStyleObject> data;
8189
8190        try {
8191            var commandForm = CoreUtil.getHome().getGetFontStylesForm();
8192            var command = CDI.current().select(GetFontStylesCommand.class).get();
8193
8194            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8195            if(totalEntities == null) {
8196                data = Connections.emptyConnection();
8197            } else {
8198                try(var objectLimiter = new ObjectLimiter(env, FontStyleConstants.COMPONENT_VENDOR_NAME, FontStyleConstants.ENTITY_TYPE_NAME, totalEntities)) {
8199                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8200
8201                    var fontStyles = entities.stream()
8202                            .map(FontStyleObject::new)
8203                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
8204
8205                    data = new CountedObjects<>(objectLimiter, fontStyles);
8206                }
8207            }
8208        } catch (NamingException ex) {
8209            throw new RuntimeException(ex);
8210        }
8211
8212        return data;
8213    }
8214
8215    @GraphQLField
8216    @GraphQLName("fontWeight")
8217    static FontWeightObject fontWeight(final DataFetchingEnvironment env,
8218            @GraphQLName("fontWeightName") final String fontWeightName,
8219            @GraphQLName("id") @GraphQLID final String id) {
8220        FontWeight fontWeight;
8221
8222        try {
8223            var commandForm = CoreUtil.getHome().getGetFontWeightForm();
8224
8225            commandForm.setFontWeightName(fontWeightName);
8226            commandForm.setUuid(id);
8227
8228            fontWeight = CDI.current().select(GetFontWeightCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
8229        } catch (NamingException ex) {
8230            throw new RuntimeException(ex);
8231        }
8232
8233        return fontWeight == null ? null : new FontWeightObject(fontWeight);
8234    }
8235
8236    @GraphQLField
8237    @GraphQLName("fontWeights")
8238    @GraphQLNonNull
8239    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
8240    static CountingPaginatedData<FontWeightObject> fontWeights(final DataFetchingEnvironment env) {
8241        CountingPaginatedData<FontWeightObject> data;
8242
8243        try {
8244            var commandForm = CoreUtil.getHome().getGetFontWeightsForm();
8245            var command = CDI.current().select(GetFontWeightsCommand.class).get();
8246
8247            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8248            if(totalEntities == null) {
8249                data = Connections.emptyConnection();
8250            } else {
8251                try(var objectLimiter = new ObjectLimiter(env, FontWeightConstants.COMPONENT_VENDOR_NAME, FontWeightConstants.ENTITY_TYPE_NAME, totalEntities)) {
8252                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8253
8254                    var fontWeights = entities.stream()
8255                            .map(FontWeightObject::new)
8256                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
8257
8258                    data = new CountedObjects<>(objectLimiter, fontWeights);
8259                }
8260            }
8261        } catch (NamingException ex) {
8262            throw new RuntimeException(ex);
8263        }
8264
8265        return data;
8266    }
8267
8268    @GraphQLField
8269    @GraphQLName("textDecoration")
8270    static TextDecorationObject textDecoration(final DataFetchingEnvironment env,
8271            @GraphQLName("textDecorationName") final String textDecorationName,
8272            @GraphQLName("id") @GraphQLID final String id) {
8273        TextDecoration textDecoration;
8274
8275        try {
8276            var commandForm = CoreUtil.getHome().getGetTextDecorationForm();
8277
8278            commandForm.setTextDecorationName(textDecorationName);
8279            commandForm.setUuid(id);
8280
8281            textDecoration = CDI.current().select(GetTextDecorationCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
8282        } catch (NamingException ex) {
8283            throw new RuntimeException(ex);
8284        }
8285
8286        return textDecoration == null ? null : new TextDecorationObject(textDecoration);
8287    }
8288
8289    @GraphQLField
8290    @GraphQLName("textDecorations")
8291    @GraphQLNonNull
8292    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
8293    static CountingPaginatedData<TextDecorationObject> textDecorations(final DataFetchingEnvironment env) {
8294        CountingPaginatedData<TextDecorationObject> data;
8295
8296        try {
8297            var commandForm = CoreUtil.getHome().getGetTextDecorationsForm();
8298            var command = CDI.current().select(GetTextDecorationsCommand.class).get();
8299
8300            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8301            if(totalEntities == null) {
8302                data = Connections.emptyConnection();
8303            } else {
8304                try(var objectLimiter = new ObjectLimiter(env, TextDecorationConstants.COMPONENT_VENDOR_NAME, TextDecorationConstants.ENTITY_TYPE_NAME, totalEntities)) {
8305                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8306
8307                    var textDecorations = entities.stream()
8308                            .map(TextDecorationObject::new)
8309                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
8310
8311                    data = new CountedObjects<>(objectLimiter, textDecorations);
8312                }
8313            }
8314        } catch (NamingException ex) {
8315            throw new RuntimeException(ex);
8316        }
8317
8318        return data;
8319    }
8320
8321    @GraphQLField
8322    @GraphQLName("textTransformation")
8323    static TextTransformationObject textTransformation(final DataFetchingEnvironment env,
8324            @GraphQLName("textTransformationName") final String textTransformationName,
8325            @GraphQLName("id") @GraphQLID final String id) {
8326        TextTransformation textTransformation;
8327
8328        try {
8329            var commandForm = CoreUtil.getHome().getGetTextTransformationForm();
8330
8331            commandForm.setTextTransformationName(textTransformationName);
8332            commandForm.setUuid(id);
8333
8334            textTransformation = CDI.current().select(GetTextTransformationCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
8335        } catch (NamingException ex) {
8336            throw new RuntimeException(ex);
8337        }
8338
8339        return textTransformation == null ? null : new TextTransformationObject(textTransformation);
8340    }
8341
8342    @GraphQLField
8343    @GraphQLName("textTransformations")
8344    @GraphQLNonNull
8345    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
8346    static CountingPaginatedData<TextTransformationObject> textTransformations(final DataFetchingEnvironment env) {
8347        CountingPaginatedData<TextTransformationObject> data;
8348
8349        try {
8350            var commandForm = CoreUtil.getHome().getGetTextTransformationsForm();
8351            var command = CDI.current().select(GetTextTransformationsCommand.class).get();
8352
8353            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8354            if(totalEntities == null) {
8355                data = Connections.emptyConnection();
8356            } else {
8357                try(var objectLimiter = new ObjectLimiter(env, TextTransformationConstants.COMPONENT_VENDOR_NAME, TextTransformationConstants.ENTITY_TYPE_NAME, totalEntities)) {
8358                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8359
8360                    var textTransformations = entities.stream()
8361                            .map(TextTransformationObject::new)
8362                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
8363
8364                    data = new CountedObjects<>(objectLimiter, textTransformations);
8365                }
8366            }
8367        } catch (NamingException ex) {
8368            throw new RuntimeException(ex);
8369        }
8370
8371        return data;
8372    }
8373
8374    @GraphQLField
8375    @GraphQLName("userLogin")
8376    static UserLoginObject userLogin(final DataFetchingEnvironment env,
8377            @GraphQLName("username") final String username,
8378            @GraphQLName("id") @GraphQLID final String id) {
8379        UserLogin userLogin;
8380
8381        try {
8382            var commandForm = UserUtil.getHome().getGetUserLoginForm();
8383
8384            commandForm.setUsername(username);
8385            commandForm.setUuid(id);
8386
8387            var getUserLoginCommand = CDI.current().select(GetUserLoginCommand.class).get();
8388            userLogin = getUserLoginCommand.getEntityForGraphQl(getUserVisitPK(env), commandForm);
8389        } catch (NamingException ex) {
8390            throw new RuntimeException(ex);
8391        }
8392
8393        return userLogin == null ? null : new UserLoginObject(userLogin);
8394    }
8395
8396    @GraphQLField
8397    @GraphQLName("recoveryQuestion")
8398    static RecoveryQuestionObject recoveryQuestion(final DataFetchingEnvironment env,
8399            @GraphQLName("recoveryQuestionName") final String recoveryQuestionName,
8400            @GraphQLName("id") @GraphQLID final String id,
8401            @GraphQLName("username") final String username) {
8402        RecoveryQuestion recoveryQuestion;
8403
8404        try {
8405            var commandForm = UserUtil.getHome().getGetRecoveryQuestionForm();
8406
8407            commandForm.setRecoveryQuestionName(recoveryQuestionName);
8408            commandForm.setUuid(id);
8409            commandForm.setUsername(username);
8410
8411            recoveryQuestion = CDI.current().select(GetRecoveryQuestionCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
8412        } catch (NamingException ex) {
8413            throw new RuntimeException(ex);
8414        }
8415
8416        return recoveryQuestion == null ? null : new RecoveryQuestionObject(recoveryQuestion);
8417    }
8418
8419    @GraphQLField
8420    @GraphQLName("recoveryQuestions")
8421    @GraphQLNonNull
8422    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
8423    static CountingPaginatedData<RecoveryQuestionObject> recoveryQuestions(final DataFetchingEnvironment env) {
8424        CountingPaginatedData<RecoveryQuestionObject> data;
8425
8426        try {
8427            var commandForm = UserUtil.getHome().getGetRecoveryQuestionsForm();
8428            var command = CDI.current().select(GetRecoveryQuestionsCommand.class).get();
8429
8430            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8431            if(totalEntities == null) {
8432                data = Connections.emptyConnection();
8433            } else {
8434                try(var objectLimiter = new ObjectLimiter(env, RecoveryQuestionConstants.COMPONENT_VENDOR_NAME, RecoveryQuestionConstants.ENTITY_TYPE_NAME, totalEntities)) {
8435                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8436
8437                    var recoveryQuestions = entities.stream()
8438                            .map(RecoveryQuestionObject::new)
8439                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
8440
8441                    data = new CountedObjects<>(objectLimiter, recoveryQuestions);
8442                }
8443            }
8444        } catch (NamingException ex) {
8445            throw new RuntimeException(ex);
8446        }
8447
8448        return data;
8449    }
8450
8451    @GraphQLField
8452    @GraphQLName("userSession")
8453    static UserSessionObject userSession(final DataFetchingEnvironment env) {
8454        var userSession = BaseGraphQl.getUserSession(env);
8455
8456        return userSession == null ? null : new UserSessionObject(userSession);
8457    }
8458
8459    @GraphQLField
8460    @GraphQLName("userVisitGroup")
8461    static UserVisitGroupObject userVisitGroup(final DataFetchingEnvironment env,
8462            @GraphQLName("userVisitGroupName") final String userVisitGroupName,
8463            @GraphQLName("id") @GraphQLID final String id) {
8464        UserVisitGroup userVisitGroup;
8465
8466        try {
8467            var commandForm = UserUtil.getHome().getGetUserVisitGroupForm();
8468
8469            commandForm.setUserVisitGroupName(userVisitGroupName);
8470            commandForm.setUuid(id);
8471
8472            userVisitGroup = CDI.current().select(GetUserVisitGroupCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
8473        } catch (NamingException ex) {
8474            throw new RuntimeException(ex);
8475        }
8476
8477        return userVisitGroup == null ? null : new UserVisitGroupObject(userVisitGroup);
8478    }
8479
8480    @GraphQLField
8481    @GraphQLName("userVisitGroups")
8482    @GraphQLNonNull
8483    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
8484    static CountingPaginatedData<UserVisitGroupObject> userVisitGroups(final DataFetchingEnvironment env) {
8485        CountingPaginatedData<UserVisitGroupObject> data;
8486
8487        try {
8488            var commandForm = UserUtil.getHome().getGetUserVisitGroupsForm();
8489            var command = CDI.current().select(GetUserVisitGroupsCommand.class).get();
8490
8491            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8492            if(totalEntities == null) {
8493                data = Connections.emptyConnection();
8494            } else {
8495                try(var objectLimiter = new ObjectLimiter(env, UserVisitGroupConstants.COMPONENT_VENDOR_NAME, UserVisitGroupConstants.ENTITY_TYPE_NAME, totalEntities)) {
8496                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8497
8498                    var userVisitGroups = entities.stream()
8499                            .map(UserVisitGroupObject::new)
8500                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
8501
8502                    data = new CountedObjects<>(objectLimiter, userVisitGroups);
8503                }
8504            }
8505        } catch (NamingException ex) {
8506            throw new RuntimeException(ex);
8507        }
8508
8509        return data;
8510    }
8511
8512    @GraphQLField
8513    @GraphQLName("userVisit")
8514    static UserVisitObject userVisit(final DataFetchingEnvironment env) {
8515        var userVisit = BaseGraphQl.getUserVisit(env);
8516
8517        return userVisit == null ? null : new UserVisitObject(userVisit);
8518    }
8519
8520    @GraphQLField
8521    @GraphQLName("symbolPosition")
8522    static SymbolPositionObject symbolPosition(final DataFetchingEnvironment env,
8523            @GraphQLName("symbolPositionName") final String symbolPositionName,
8524            @GraphQLName("id") @GraphQLID final String id) {
8525        SymbolPosition symbolPosition;
8526
8527        try {
8528            var commandForm = AccountingUtil.getHome().getGetSymbolPositionForm();
8529
8530            commandForm.setSymbolPositionName(symbolPositionName);
8531            commandForm.setUuid(id);
8532
8533            symbolPosition = CDI.current().select(GetSymbolPositionCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
8534        } catch (NamingException ex) {
8535            throw new RuntimeException(ex);
8536        }
8537
8538        return symbolPosition == null ? null : new SymbolPositionObject(symbolPosition);
8539    }
8540
8541    @GraphQLField
8542    @GraphQLName("symbolPositions")
8543    @GraphQLNonNull
8544    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
8545    static CountingPaginatedData<SymbolPositionObject> symbolPositions(final DataFetchingEnvironment env) {
8546        CountingPaginatedData<SymbolPositionObject> data;
8547
8548        try {
8549            var commandForm = AccountingUtil.getHome().getGetSymbolPositionsForm();
8550            var command = CDI.current().select(GetSymbolPositionsCommand.class).get();
8551
8552            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8553            if(totalEntities == null) {
8554                data = Connections.emptyConnection();
8555            } else {
8556                try(var objectLimiter = new ObjectLimiter(env, SymbolPositionConstants.COMPONENT_VENDOR_NAME, SymbolPositionConstants.ENTITY_TYPE_NAME, totalEntities)) {
8557                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8558
8559                    var symbolPositions = entities.stream()
8560                            .map(SymbolPositionObject::new)
8561                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
8562
8563                    data = new CountedObjects<>(objectLimiter, symbolPositions);
8564                }
8565            }
8566        } catch (NamingException ex) {
8567            throw new RuntimeException(ex);
8568        }
8569
8570        return data;
8571    }
8572
8573    @GraphQLField
8574    @GraphQLName("currency")
8575    static CurrencyObject currency(final DataFetchingEnvironment env,
8576            @GraphQLName("currencyIsoName") final String currencyIsoName,
8577            @GraphQLName("id") @GraphQLID final String id) {
8578        Currency currency;
8579
8580        try {
8581            var commandForm = AccountingUtil.getHome().getGetCurrencyForm();
8582
8583            commandForm.setCurrencyIsoName(currencyIsoName);
8584            commandForm.setUuid(id);
8585
8586            currency = CDI.current().select(GetCurrencyCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
8587        } catch (NamingException ex) {
8588            throw new RuntimeException(ex);
8589        }
8590
8591        return currency == null ? null : new CurrencyObject(currency);
8592    }
8593
8594    @GraphQLField
8595    @GraphQLName("currencies")
8596    @GraphQLNonNull
8597    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
8598    static CountingPaginatedData<CurrencyObject> currencies(final DataFetchingEnvironment env) {
8599        CountingPaginatedData<CurrencyObject> data;
8600
8601        try {
8602            var commandForm = AccountingUtil.getHome().getGetCurrenciesForm();
8603            var command = CDI.current().select(GetCurrenciesCommand.class).get();
8604
8605            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8606            if(totalEntities == null) {
8607                data = Connections.emptyConnection();
8608            } else {
8609                try(var objectLimiter = new ObjectLimiter(env, CurrencyConstants.COMPONENT_VENDOR_NAME, CurrencyConstants.ENTITY_TYPE_NAME, totalEntities)) {
8610                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8611
8612                    var currencies = entities.stream()
8613                            .map(CurrencyObject::new)
8614                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
8615
8616                    data = new CountedObjects<>(objectLimiter, currencies);
8617                }
8618            }
8619        } catch (NamingException ex) {
8620            throw new RuntimeException(ex);
8621        }
8622
8623        return data;
8624    }
8625
8626    @GraphQLField
8627    @GraphQLName("language")
8628    static LanguageObject language(final DataFetchingEnvironment env,
8629            @GraphQLName("languageIsoName") final String languageIsoName,
8630            @GraphQLName("id") @GraphQLID final String id) {
8631        Language language;
8632
8633        try {
8634            var commandForm = PartyUtil.getHome().getGetLanguageForm();
8635
8636            commandForm.setLanguageIsoName(languageIsoName);
8637            commandForm.setUuid(id);
8638
8639            language = CDI.current().select(GetLanguageCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
8640        } catch (NamingException ex) {
8641            throw new RuntimeException(ex);
8642        }
8643
8644        return language == null ? null : new LanguageObject(language);
8645    }
8646
8647    @GraphQLField
8648    @GraphQLName("languages")
8649    @GraphQLNonNull
8650    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
8651    static CountingPaginatedData<LanguageObject> languages(final DataFetchingEnvironment env) {
8652        CountingPaginatedData<LanguageObject> data;
8653
8654        try {
8655            var commandForm = PartyUtil.getHome().getGetLanguagesForm();
8656            var command = CDI.current().select(GetLanguagesCommand.class).get();
8657
8658            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8659            if(totalEntities == null) {
8660                data = Connections.emptyConnection();
8661            } else {
8662                try(var objectLimiter = new ObjectLimiter(env, LanguageConstants.COMPONENT_VENDOR_NAME, LanguageConstants.ENTITY_TYPE_NAME, totalEntities)) {
8663                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8664
8665                    var languages = entities.stream()
8666                            .map(LanguageObject::new)
8667                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
8668
8669                    data = new CountedObjects<>(objectLimiter, languages);
8670                }
8671            }
8672        } catch (NamingException ex) {
8673            throw new RuntimeException(ex);
8674        }
8675
8676        return data;
8677    }
8678
8679    @GraphQLField
8680    @GraphQLName("dateTimeFormat")
8681    static DateTimeFormatObject dateTimeFormat(final DataFetchingEnvironment env,
8682            @GraphQLName("dateTimeFormatName") final String dateTimeFormatName,
8683            @GraphQLName("id") @GraphQLID final String id) {
8684        DateTimeFormat dateTimeFormat;
8685
8686        try {
8687            var commandForm = PartyUtil.getHome().getGetDateTimeFormatForm();
8688
8689            commandForm.setDateTimeFormatName(dateTimeFormatName);
8690            commandForm.setUuid(id);
8691
8692            dateTimeFormat = CDI.current().select(GetDateTimeFormatCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
8693        } catch (NamingException ex) {
8694            throw new RuntimeException(ex);
8695        }
8696
8697        return dateTimeFormat == null ? null : new DateTimeFormatObject(dateTimeFormat);
8698    }
8699
8700    @GraphQLField
8701    @GraphQLName("dateTimeFormats")
8702    @GraphQLNonNull
8703    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
8704    static CountingPaginatedData<DateTimeFormatObject> dateTimeFormats(final DataFetchingEnvironment env) {
8705        CountingPaginatedData<DateTimeFormatObject> data;
8706
8707        try {
8708            var commandForm = PartyUtil.getHome().getGetDateTimeFormatsForm();
8709            var command = CDI.current().select(GetDateTimeFormatsCommand.class).get();
8710
8711            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8712            if(totalEntities == null) {
8713                data = Connections.emptyConnection();
8714            } else {
8715                try(var objectLimiter = new ObjectLimiter(env, DateTimeFormatConstants.COMPONENT_VENDOR_NAME, DateTimeFormatConstants.ENTITY_TYPE_NAME, totalEntities)) {
8716                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8717
8718                    var dateTimeFormats = entities.stream()
8719                            .map(DateTimeFormatObject::new)
8720                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
8721
8722                    data = new CountedObjects<>(objectLimiter, dateTimeFormats);
8723                }
8724            }
8725        } catch (NamingException ex) {
8726            throw new RuntimeException(ex);
8727        }
8728
8729        return data;
8730    }
8731
8732    @GraphQLField
8733    @GraphQLName("timeZone")
8734    static TimeZoneObject timeZone(final DataFetchingEnvironment env,
8735            @GraphQLName("javaTimeZoneName") final String javaTimeZoneName,
8736            @GraphQLName("id") @GraphQLID final String id) {
8737        TimeZone timeZone;
8738
8739        try {
8740            var commandForm = PartyUtil.getHome().getGetTimeZoneForm();
8741
8742            commandForm.setJavaTimeZoneName(javaTimeZoneName);
8743            commandForm.setUuid(id);
8744
8745            timeZone = CDI.current().select(GetTimeZoneCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
8746        } catch (NamingException ex) {
8747            throw new RuntimeException(ex);
8748        }
8749
8750        return timeZone == null ? null : new TimeZoneObject(timeZone);
8751    }
8752
8753    @GraphQLField
8754    @GraphQLName("timeZones")
8755    @GraphQLNonNull
8756    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
8757    static CountingPaginatedData<TimeZoneObject> timeZones(final DataFetchingEnvironment env) {
8758        CountingPaginatedData<TimeZoneObject> data;
8759
8760        try {
8761            var commandForm = PartyUtil.getHome().getGetTimeZonesForm();
8762            var command = CDI.current().select(GetTimeZonesCommand.class).get();
8763
8764            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8765            if(totalEntities == null) {
8766                data = Connections.emptyConnection();
8767            } else {
8768                try(var objectLimiter = new ObjectLimiter(env, TimeZoneConstants.COMPONENT_VENDOR_NAME, TimeZoneConstants.ENTITY_TYPE_NAME, totalEntities)) {
8769                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8770
8771                    var timeZones = entities.stream()
8772                            .map(TimeZoneObject::new)
8773                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
8774
8775                    data = new CountedObjects<>(objectLimiter, timeZones);
8776                }
8777            }
8778        } catch (NamingException ex) {
8779            throw new RuntimeException(ex);
8780        }
8781
8782        return data;
8783    }
8784
8785    @GraphQLField
8786    @GraphQLName("customerType")
8787    static CustomerTypeObject customerType(final DataFetchingEnvironment env,
8788            @GraphQLName("customerTypeName") final String customerTypeName,
8789            @GraphQLName("id") @GraphQLID final String id) {
8790        CustomerType customerType;
8791
8792        try {
8793            var commandForm = CustomerUtil.getHome().getGetCustomerTypeForm();
8794
8795            commandForm.setCustomerTypeName(customerTypeName);
8796            commandForm.setUuid(id);
8797
8798            customerType = CDI.current().select(GetCustomerTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
8799        } catch (NamingException ex) {
8800            throw new RuntimeException(ex);
8801        }
8802
8803        return customerType == null ? null : new CustomerTypeObject(customerType);
8804    }
8805
8806    @GraphQLField
8807    @GraphQLName("customerTypes")
8808    @GraphQLNonNull
8809    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
8810    static CountingPaginatedData<CustomerTypeObject> customerTypes(final DataFetchingEnvironment env) {
8811        CountingPaginatedData<CustomerTypeObject> data;
8812
8813        try {
8814            var commandForm = CustomerUtil.getHome().getGetCustomerTypesForm();
8815            var command = CDI.current().select(GetCustomerTypesCommand.class).get();
8816
8817            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8818            if(totalEntities == null) {
8819                data = Connections.emptyConnection();
8820            } else {
8821                try(var objectLimiter = new ObjectLimiter(env, CustomerTypeConstants.COMPONENT_VENDOR_NAME, CustomerTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
8822                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8823
8824                    var customerTypes = entities.stream()
8825                            .map(CustomerTypeObject::new)
8826                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
8827
8828                    data = new CountedObjects<>(objectLimiter, customerTypes);
8829                }
8830            }
8831        } catch (NamingException ex) {
8832            throw new RuntimeException(ex);
8833        }
8834
8835        return data;
8836    }
8837
8838    @GraphQLField
8839    @GraphQLName("customerTypePaymentMethod")
8840    static CustomerTypePaymentMethodObject customerTypePaymentMethod(final DataFetchingEnvironment env,
8841            @GraphQLName("customerTypeName") @GraphQLNonNull final String customerTypeName,
8842            @GraphQLName("paymentMethodName") @GraphQLNonNull final String paymentMethodName) {
8843        CustomerTypePaymentMethod customerTypePaymentMethod;
8844
8845        try {
8846            var commandForm = CustomerUtil.getHome().getGetCustomerTypePaymentMethodForm();
8847
8848            commandForm.setCustomerTypeName(customerTypeName);
8849            commandForm.setPaymentMethodName(paymentMethodName);
8850
8851
8852            customerTypePaymentMethod = CDI.current().select(GetCustomerTypePaymentMethodCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
8853        } catch (NamingException ex) {
8854            throw new RuntimeException(ex);
8855        }
8856
8857        return customerTypePaymentMethod == null ? null : new CustomerTypePaymentMethodObject(customerTypePaymentMethod);
8858    }
8859
8860    @GraphQLField
8861    @GraphQLName("customerTypePaymentMethods")
8862    @GraphQLNonNull
8863    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
8864    static CountingPaginatedData<CustomerTypePaymentMethodObject> customerTypePaymentMethods(final DataFetchingEnvironment env,
8865            @GraphQLName("customerTypeName") @GraphQLNonNull final String customerTypeName) {
8866        CountingPaginatedData<CustomerTypePaymentMethodObject> data;
8867
8868        try {
8869            var commandForm = CustomerUtil.getHome().getGetCustomerTypePaymentMethodsForm();
8870            var command = CDI.current().select(GetCustomerTypePaymentMethodsCommand.class).get();
8871
8872            commandForm.setCustomerTypeName(customerTypeName);
8873
8874            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8875            if(totalEntities == null) {
8876                data = Connections.emptyConnection();
8877            } else {
8878                try(var objectLimiter = new ObjectLimiter(env, CustomerTypePaymentMethodConstants.COMPONENT_VENDOR_NAME, CustomerTypePaymentMethodConstants.ENTITY_TYPE_NAME, totalEntities)) {
8879                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8880
8881                    var customerTypePaymentMethods = entities.stream()
8882                            .map(CustomerTypePaymentMethodObject::new)
8883                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
8884
8885                    data = new CountedObjects<>(objectLimiter, customerTypePaymentMethods);
8886                }
8887            }
8888        } catch (NamingException ex) {
8889            throw new RuntimeException(ex);
8890        }
8891
8892        return data;
8893    }
8894
8895    @GraphQLField
8896    @GraphQLName("customerTypeShippingMethod")
8897    static CustomerTypeShippingMethodObject customerTypeShippingMethod(final DataFetchingEnvironment env,
8898            @GraphQLName("customerTypeName") @GraphQLNonNull final String customerTypeName,
8899            @GraphQLName("shippingMethodName") @GraphQLNonNull final String shippingMethodName) {
8900        CustomerTypeShippingMethod customerTypeShippingMethod;
8901
8902        try {
8903            var commandForm = CustomerUtil.getHome().getGetCustomerTypeShippingMethodForm();
8904
8905            commandForm.setCustomerTypeName(customerTypeName);
8906            commandForm.setShippingMethodName(shippingMethodName);
8907
8908
8909            customerTypeShippingMethod = CDI.current().select(GetCustomerTypeShippingMethodCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
8910        } catch (NamingException ex) {
8911            throw new RuntimeException(ex);
8912        }
8913
8914        return customerTypeShippingMethod == null ? null : new CustomerTypeShippingMethodObject(customerTypeShippingMethod);
8915    }
8916
8917    @GraphQLField
8918    @GraphQLName("customerTypeShippingMethods")
8919    @GraphQLNonNull
8920    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
8921    static CountingPaginatedData<CustomerTypeShippingMethodObject> customerTypeShippingMethods(final DataFetchingEnvironment env,
8922            @GraphQLName("customerTypeName") @GraphQLNonNull final String customerTypeName) {
8923        CountingPaginatedData<CustomerTypeShippingMethodObject> data;
8924
8925        try {
8926            var commandForm = CustomerUtil.getHome().getGetCustomerTypeShippingMethodsForm();
8927            var command = CDI.current().select(GetCustomerTypeShippingMethodsCommand.class).get();
8928
8929            commandForm.setCustomerTypeName(customerTypeName);
8930
8931            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8932            if(totalEntities == null) {
8933                data = Connections.emptyConnection();
8934            } else {
8935                try(var objectLimiter = new ObjectLimiter(env, CustomerTypeShippingMethodConstants.COMPONENT_VENDOR_NAME, CustomerTypeShippingMethodConstants.ENTITY_TYPE_NAME, totalEntities)) {
8936                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8937
8938                    var customerTypeShippingMethods = entities.stream()
8939                            .map(CustomerTypeShippingMethodObject::new)
8940                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
8941
8942                    data = new CountedObjects<>(objectLimiter, customerTypeShippingMethods);
8943                }
8944            }
8945        } catch (NamingException ex) {
8946            throw new RuntimeException(ex);
8947        }
8948
8949        return data;
8950    }
8951
8952    @GraphQLField
8953    @GraphQLName("customer")
8954    static CustomerObject customer(final DataFetchingEnvironment env,
8955            @GraphQLName("customerName") final String customerName,
8956            @GraphQLName("partyName") final String partyName,
8957            @GraphQLName("id") @GraphQLID final String id) {
8958        Customer customer;
8959
8960        try {
8961            var commandForm = CustomerUtil.getHome().getGetCustomerForm();
8962
8963            commandForm.setCustomerName(customerName);
8964            commandForm.setPartyName(partyName);
8965            commandForm.setUuid(id);
8966
8967            customer = CDI.current().select(GetCustomerCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
8968        } catch (NamingException ex) {
8969            throw new RuntimeException(ex);
8970        }
8971
8972        return customer == null ? null : new CustomerObject(customer);
8973    }
8974
8975    @GraphQLField
8976    @GraphQLName("customers")
8977    @GraphQLNonNull
8978    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
8979    static CountingPaginatedData<CustomerObject> customers(final DataFetchingEnvironment env) {
8980        CountingPaginatedData<CustomerObject> data;
8981
8982        try {
8983            var commandForm = CustomerUtil.getHome().getGetCustomersForm();
8984            var command = CDI.current().select(GetCustomersCommand.class).get();
8985
8986            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8987            if(totalEntities == null) {
8988                data = Connections.emptyConnection();
8989            } else {
8990                try(var objectLimiter = new ObjectLimiter(env, CustomerConstants.COMPONENT_VENDOR_NAME, CustomerConstants.ENTITY_TYPE_NAME, totalEntities)) {
8991                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
8992
8993                    var customers = entities.stream()
8994                            .map(CustomerObject::new)
8995                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
8996
8997                    data = new CountedObjects<>(objectLimiter, customers);
8998                }
8999            }
9000        } catch (NamingException ex) {
9001            throw new RuntimeException(ex);
9002        }
9003
9004        return data;
9005    }
9006
9007    @GraphQLField
9008    @GraphQLName("employee")
9009    static EmployeeObject employee(final DataFetchingEnvironment env,
9010            @GraphQLName("employeeName") final String employeeName,
9011            @GraphQLName("partyName") final String partyName,
9012            @GraphQLName("id") @GraphQLID final String id) {
9013        PartyEmployee partyEmployee;
9014
9015        try {
9016            var commandForm = EmployeeUtil.getHome().getGetEmployeeForm();
9017
9018            commandForm.setEmployeeName(employeeName);
9019            commandForm.setPartyName(partyName);
9020            commandForm.setUuid(id);
9021
9022            partyEmployee = CDI.current().select(GetEmployeeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
9023        } catch (NamingException ex) {
9024            throw new RuntimeException(ex);
9025        }
9026
9027        return partyEmployee == null ? null : new EmployeeObject(partyEmployee);
9028    }
9029
9030    @GraphQLField
9031    @GraphQLName("employees")
9032    @GraphQLNonNull
9033    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
9034    static CountingPaginatedData<EmployeeObject> employees(final DataFetchingEnvironment env) {
9035        CountingPaginatedData<EmployeeObject> data;
9036
9037        try {
9038            var commandForm = EmployeeUtil.getHome().getGetEmployeesForm();
9039            var command = CDI.current().select(GetEmployeesCommand.class).get();
9040
9041            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9042            if(totalEntities == null) {
9043                data = Connections.emptyConnection();
9044            } else {
9045                try(var objectLimiter = new ObjectLimiter(env, PartyEmployeeConstants.COMPONENT_VENDOR_NAME, PartyEmployeeConstants.ENTITY_TYPE_NAME, totalEntities)) {
9046                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9047
9048                    var employees = entities.stream()
9049                            .map(EmployeeObject::new)
9050                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
9051
9052                    data = new CountedObjects<>(objectLimiter, employees);
9053                }
9054            }
9055        } catch (NamingException ex) {
9056            throw new RuntimeException(ex);
9057        }
9058
9059        return data;
9060    }
9061
9062    @GraphQLField
9063    @GraphQLName("vendorType")
9064    static VendorTypeObject vendorType(final DataFetchingEnvironment env,
9065            @GraphQLName("vendorTypeName") final String vendorTypeName,
9066            @GraphQLName("id") @GraphQLID final String id) {
9067        VendorType vendorType;
9068
9069        try {
9070            var commandForm = VendorUtil.getHome().getGetVendorTypeForm();
9071
9072            commandForm.setVendorTypeName(vendorTypeName);
9073            commandForm.setUuid(id);
9074
9075            vendorType = CDI.current().select(GetVendorTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
9076        } catch (NamingException ex) {
9077            throw new RuntimeException(ex);
9078        }
9079
9080        return vendorType == null ? null : new VendorTypeObject(vendorType);
9081    }
9082
9083    @GraphQLField
9084    @GraphQLName("vendorTypes")
9085    @GraphQLNonNull
9086    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
9087    static CountingPaginatedData<VendorTypeObject> vendorTypes(final DataFetchingEnvironment env) {
9088        CountingPaginatedData<VendorTypeObject> data;
9089
9090        try {
9091            var commandForm = VendorUtil.getHome().getGetVendorTypesForm();
9092            var command = CDI.current().select(GetVendorTypesCommand.class).get();
9093
9094            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9095            if(totalEntities == null) {
9096                data = Connections.emptyConnection();
9097            } else {
9098                try(var objectLimiter = new ObjectLimiter(env, VendorTypeConstants.COMPONENT_VENDOR_NAME, VendorTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
9099                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9100
9101                    var vendorTypes = entities.stream()
9102                            .map(VendorTypeObject::new)
9103                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
9104
9105                    data = new CountedObjects<>(objectLimiter, vendorTypes);
9106                }
9107            }
9108        } catch (NamingException ex) {
9109            throw new RuntimeException(ex);
9110        }
9111
9112        return data;
9113    }
9114
9115    @GraphQLField
9116    @GraphQLName("vendor")
9117    static VendorObject vendor(final DataFetchingEnvironment env,
9118            @GraphQLName("vendorName") final String vendorName,
9119            @GraphQLName("partyName") final String partyName,
9120            @GraphQLName("id") @GraphQLID final String id) {
9121        Vendor vendor;
9122
9123        try {
9124            var commandForm = VendorUtil.getHome().getGetVendorForm();
9125
9126            commandForm.setVendorName(vendorName);
9127            commandForm.setPartyName(partyName);
9128            commandForm.setUuid(id);
9129
9130            vendor = CDI.current().select(GetVendorCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
9131        } catch (NamingException ex) {
9132            throw new RuntimeException(ex);
9133        }
9134
9135        return vendor == null ? null : new VendorObject(vendor);
9136    }
9137
9138    @GraphQLField
9139    @GraphQLName("vendors")
9140    @GraphQLNonNull
9141    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
9142    static CountingPaginatedData<VendorObject> vendors(final DataFetchingEnvironment env) {
9143        CountingPaginatedData<VendorObject> data;
9144
9145        try {
9146            var commandForm = VendorUtil.getHome().getGetVendorsForm();
9147            var command = CDI.current().select(GetVendorsCommand.class).get();
9148
9149            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9150            if(totalEntities == null) {
9151                data = Connections.emptyConnection();
9152            } else {
9153                try(var objectLimiter = new ObjectLimiter(env, VendorConstants.COMPONENT_VENDOR_NAME, VendorConstants.ENTITY_TYPE_NAME, totalEntities)) {
9154                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9155
9156                    var vendors = entities.stream()
9157                            .map(VendorObject::new)
9158                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
9159
9160                    data = new CountedObjects<>(objectLimiter, vendors);
9161                }
9162            }
9163        } catch (NamingException ex) {
9164            throw new RuntimeException(ex);
9165        }
9166
9167        return data;
9168    }
9169
9170    @GraphQLField
9171    @GraphQLName("vendorItem")
9172    static VendorItemObject vendorItem(final DataFetchingEnvironment env,
9173            @GraphQLName("vendorName") final String vendorName,
9174            @GraphQLName("partyName") final String partyName,
9175            @GraphQLName("vendorItemName") final String vendorItemName,
9176            @GraphQLName("id") @GraphQLID final String id) {
9177        VendorItem vendorItem;
9178
9179        try {
9180            var commandForm = VendorUtil.getHome().getGetVendorItemForm();
9181
9182            commandForm.setVendorName(vendorName);
9183            commandForm.setPartyName(partyName);
9184            commandForm.setVendorItemName(vendorItemName);
9185            commandForm.setUuid(id);
9186
9187            vendorItem = CDI.current().select(GetVendorItemCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
9188        } catch (NamingException ex) {
9189            throw new RuntimeException(ex);
9190        }
9191
9192        return vendorItem == null ? null : new VendorItemObject(vendorItem);
9193    }
9194
9195    @GraphQLField
9196    @GraphQLName("vendorItems")
9197    @GraphQLNonNull
9198    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
9199    static CountingPaginatedData<VendorItemObject> vendorItems(final DataFetchingEnvironment env,
9200            @GraphQLName("vendorName") final String vendorName,
9201            @GraphQLName("itemName") final String itemName) {
9202        CountingPaginatedData<VendorItemObject> data;
9203
9204        try {
9205            var commandForm = VendorUtil.getHome().getGetVendorItemsForm();
9206            var command = CDI.current().select(GetVendorItemsCommand.class).get();
9207
9208            commandForm.setVendorName(vendorName);
9209            commandForm.setItemName(itemName);
9210
9211            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9212            if(totalEntities == null) {
9213                data = Connections.emptyConnection();
9214            } else {
9215                try(var objectLimiter = new ObjectLimiter(env, VendorItemConstants.COMPONENT_VENDOR_NAME, VendorItemConstants.ENTITY_TYPE_NAME, totalEntities)) {
9216                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9217
9218                    var vendorItems = entities.stream()
9219                            .map(VendorItemObject::new)
9220                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
9221
9222                    data = new CountedObjects<>(objectLimiter, vendorItems);
9223                }
9224            }
9225        } catch (NamingException ex) {
9226            throw new RuntimeException(ex);
9227        }
9228
9229        return data;
9230    }
9231
9232    @GraphQLField
9233    @GraphQLName("vendorItemCost")
9234    static VendorItemCostObject vendorItemCost(final DataFetchingEnvironment env,
9235            @GraphQLName("vendorName") final String vendorName,
9236            @GraphQLName("partyName") final String partyName,
9237            @GraphQLName("vendorItemName") @GraphQLNonNull final String vendorItemName,
9238            @GraphQLName("inventoryConditionName") @GraphQLNonNull final String inventoryConditionName,
9239            @GraphQLName("unitOfMeasureTypeName") @GraphQLNonNull final String unitOfMeasureTypeName) {
9240        VendorItemCost vendorItemCost;
9241
9242        try {
9243            var commandForm = VendorUtil.getHome().getGetVendorItemCostForm();
9244
9245            commandForm.setVendorName(vendorName);
9246            commandForm.setPartyName(partyName);
9247            commandForm.setVendorItemName(vendorItemName);
9248            commandForm.setInventoryConditionName(inventoryConditionName);
9249            commandForm.setUnitOfMeasureTypeName(unitOfMeasureTypeName);
9250
9251            vendorItemCost = CDI.current().select(GetVendorItemCostCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
9252        } catch (NamingException ex) {
9253            throw new RuntimeException(ex);
9254        }
9255
9256        return vendorItemCost == null ? null : new VendorItemCostObject(vendorItemCost);
9257    }
9258
9259    @GraphQLField
9260    @GraphQLName("vendorItemCosts")
9261    @GraphQLNonNull
9262    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
9263    static CountingPaginatedData<VendorItemCostObject> vendorItemCosts(final DataFetchingEnvironment env,
9264            @GraphQLName("vendorName") @GraphQLNonNull final String vendorName,
9265            @GraphQLName("vendorItemName") @GraphQLNonNull final String vendorItemName) {
9266        CountingPaginatedData<VendorItemCostObject> data;
9267
9268        try {
9269            var commandForm = VendorUtil.getHome().getGetVendorItemCostsForm();
9270
9271            commandForm.setVendorName(vendorName);
9272            commandForm.setVendorItemName(vendorItemName);
9273
9274            var command = CDI.current().select(GetVendorItemCostsCommand.class).get();
9275
9276            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9277            if(totalEntities == null) {
9278                data = Connections.emptyConnection();
9279            } else {
9280                try(var objectLimiter = new ObjectLimiter(env, VendorItemCostConstants.COMPONENT_VENDOR_NAME, VendorItemCostConstants.ENTITY_TYPE_NAME, totalEntities)) {
9281                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9282
9283                    var vendorItemCosts = entities.stream()
9284                            .map(VendorItemCostObject::new)
9285                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
9286
9287                    data = new CountedObjects<>(objectLimiter, vendorItemCosts);
9288                }
9289            }
9290        } catch (NamingException ex) {
9291            throw new RuntimeException(ex);
9292        }
9293
9294        return data;
9295    }
9296
9297    @GraphQLField
9298    @GraphQLName("roleType")
9299    static RoleTypeObject roleType(final DataFetchingEnvironment env,
9300            @GraphQLName("roleTypeName") final String roleTypeName,
9301            @GraphQLName("id") @GraphQLID final String id) {
9302        RoleType roleType;
9303
9304        try {
9305            var commandForm = PartyUtil.getHome().getGetRoleTypeForm();
9306
9307            commandForm.setRoleTypeName(roleTypeName);
9308            commandForm.setUuid(id);
9309
9310            roleType = CDI.current().select(GetRoleTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
9311        } catch (NamingException ex) {
9312            throw new RuntimeException(ex);
9313        }
9314
9315        return roleType == null ? null : new RoleTypeObject(roleType);
9316    }
9317
9318    @GraphQLField
9319    @GraphQLName("roleTypes")
9320    @GraphQLNonNull
9321    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
9322    static CountingPaginatedData<RoleTypeObject> roleTypes(final DataFetchingEnvironment env) {
9323        CountingPaginatedData<RoleTypeObject> data;
9324
9325        try {
9326            var commandForm = PartyUtil.getHome().getGetRoleTypesForm();
9327            var command = CDI.current().select(GetRoleTypesCommand.class).get();
9328
9329            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9330            if(totalEntities == null) {
9331                data = Connections.emptyConnection();
9332            } else {
9333                try(var objectLimiter = new ObjectLimiter(env, RoleTypeConstants.COMPONENT_VENDOR_NAME, RoleTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
9334                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9335
9336                    var roleTypes = entities.stream()
9337                            .map(RoleTypeObject::new)
9338                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
9339
9340                    data = new CountedObjects<>(objectLimiter, roleTypes);
9341                }
9342            }
9343        } catch (NamingException ex) {
9344            throw new RuntimeException(ex);
9345        }
9346
9347        return data;
9348    }
9349
9350    @GraphQLField
9351    @GraphQLName("partyType")
9352    static PartyTypeObject partyType(final DataFetchingEnvironment env,
9353            @GraphQLName("partyTypeName") final String partyTypeName,
9354            @GraphQLName("id") @GraphQLID final String id) {
9355        PartyType partyType;
9356
9357        try {
9358            var commandForm = PartyUtil.getHome().getGetPartyTypeForm();
9359
9360            commandForm.setPartyTypeName(partyTypeName);
9361            commandForm.setUuid(id);
9362
9363            partyType = CDI.current().select(GetPartyTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
9364        } catch (NamingException ex) {
9365            throw new RuntimeException(ex);
9366        }
9367
9368        return partyType == null ? null : new PartyTypeObject(partyType);
9369    }
9370
9371    @GraphQLField
9372    @GraphQLName("partyTypes")
9373    @GraphQLNonNull
9374    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
9375    static CountingPaginatedData<PartyTypeObject> partyTypes(final DataFetchingEnvironment env) {
9376        CountingPaginatedData<PartyTypeObject> data;
9377
9378        try {
9379            var commandForm = PartyUtil.getHome().getGetPartyTypesForm();
9380            var command = CDI.current().select(GetPartyTypesCommand.class).get();
9381
9382            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9383            if(totalEntities == null) {
9384                data = Connections.emptyConnection();
9385            } else {
9386                try(var objectLimiter = new ObjectLimiter(env, PartyTypeConstants.COMPONENT_VENDOR_NAME, PartyTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
9387                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9388
9389                    var partyTypes = entities.stream()
9390                            .map(PartyTypeObject::new)
9391                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
9392
9393                    data = new CountedObjects<>(objectLimiter, partyTypes);
9394                }
9395            }
9396        } catch (NamingException ex) {
9397            throw new RuntimeException(ex);
9398        }
9399
9400        return data;
9401    }
9402
9403    @GraphQLField
9404    @GraphQLName("partyAliasType")
9405    static PartyAliasTypeObject partyAliasType(final DataFetchingEnvironment env,
9406            @GraphQLName("partyTypeName") final String partyTypeName,
9407            @GraphQLName("partyAliasTypeName") final String partyAliasTypeName,
9408            @GraphQLName("id") @GraphQLID final String id) {
9409        PartyAliasType partyAliasType;
9410
9411        try {
9412            var commandForm = PartyUtil.getHome().getGetPartyAliasTypeForm();
9413
9414            commandForm.setPartyTypeName(partyTypeName);
9415            commandForm.setPartyAliasTypeName(partyAliasTypeName);
9416            commandForm.setUuid(id);
9417
9418            partyAliasType = CDI.current().select(GetPartyAliasTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
9419        } catch (NamingException ex) {
9420            throw new RuntimeException(ex);
9421        }
9422
9423        return partyAliasType == null ? null : new PartyAliasTypeObject(partyAliasType);
9424    }
9425
9426    @GraphQLField
9427    @GraphQLName("partyAliasTypes")
9428    @GraphQLNonNull
9429    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
9430    static CountingPaginatedData<PartyAliasTypeObject> partyAliasTypes(final DataFetchingEnvironment env,
9431            @GraphQLName("partyTypeName") @GraphQLNonNull final String partyTypeName) {
9432        CountingPaginatedData<PartyAliasTypeObject> data;
9433
9434        try {
9435            var commandForm = PartyUtil.getHome().getGetPartyAliasTypesForm();
9436            var command = CDI.current().select(GetPartyAliasTypesCommand.class).get();
9437
9438            commandForm.setPartyTypeName(partyTypeName);
9439
9440            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9441            if(totalEntities == null) {
9442                data = Connections.emptyConnection();
9443            } else {
9444                try(var objectLimiter = new ObjectLimiter(env, PartyAliasTypeConstants.COMPONENT_VENDOR_NAME, PartyAliasTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
9445                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9446
9447                    var partyAliasTypes = entities.stream()
9448                            .map(PartyAliasTypeObject::new)
9449                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
9450
9451                    data = new CountedObjects<>(objectLimiter, partyAliasTypes);
9452                }
9453            }
9454        } catch (NamingException ex) {
9455            throw new RuntimeException(ex);
9456        }
9457
9458        return data;
9459    }
9460
9461    @GraphQLField
9462    @GraphQLName("partyAlias")
9463    static PartyAliasObject partyAlias(final DataFetchingEnvironment env,
9464            @GraphQLName("partyName") final String partyName,
9465            @GraphQLName("partyTypeName") final String partyTypeName,
9466            @GraphQLName("partyAliasTypeName") final String partyAliasTypeName,
9467            @GraphQLName("alias") final String alias) {
9468        PartyAlias partyAlias;
9469
9470        try {
9471            var commandForm = PartyUtil.getHome().getGetPartyAliasForm();
9472
9473            commandForm.setPartyName(partyName);
9474            commandForm.setPartyTypeName(partyTypeName);
9475            commandForm.setPartyAliasTypeName(partyAliasTypeName);
9476            commandForm.setAlias(alias);
9477
9478            partyAlias = CDI.current().select(GetPartyAliasCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
9479        } catch (NamingException ex) {
9480            throw new RuntimeException(ex);
9481        }
9482
9483        return partyAlias == null ? null : new PartyAliasObject(partyAlias);
9484    }
9485
9486    @GraphQLField
9487    @GraphQLName("partyAliases")
9488    static Collection<PartyAliasObject> partyAliases(final DataFetchingEnvironment env,
9489            @GraphQLName("partyName") final String partyName,
9490            @GraphQLName("partyTypeName") final String partyTypeName,
9491            @GraphQLName("partyAliasTypeName") final String partyAliasTypeName) {
9492        Collection<PartyAlias> partyAliases;
9493        Collection<PartyAliasObject> partyAliasObjects;
9494
9495        try {
9496            var commandForm = PartyUtil.getHome().getGetPartyAliasesForm();
9497
9498            commandForm.setPartyName(partyName);
9499            commandForm.setPartyTypeName(partyTypeName);
9500            commandForm.setPartyAliasTypeName(partyAliasTypeName);
9501
9502            partyAliases = CDI.current().select(GetPartyAliasesCommand.class).get().getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9503        } catch (NamingException ex) {
9504            throw new RuntimeException(ex);
9505        }
9506
9507        if(partyAliases == null) {
9508            partyAliasObjects = emptyList();
9509        } else {
9510            partyAliasObjects = new ArrayList<>(partyAliases.size());
9511
9512            partyAliases.stream()
9513                    .map(PartyAliasObject::new)
9514                    .forEachOrdered(partyAliasObjects::add);
9515        }
9516
9517        return partyAliasObjects;
9518    }
9519
9520    @GraphQLField
9521    @GraphQLName("party")
9522    static PartyObject party(final DataFetchingEnvironment env,
9523            @GraphQLName("partyName") final String partyName,
9524            @GraphQLName("id") @GraphQLID final String id) {
9525        Party party;
9526
9527        try {
9528            var commandForm = PartyUtil.getHome().getGetPartyForm();
9529
9530            commandForm.setPartyName(partyName);
9531            commandForm.setUuid(id);
9532
9533            party = CDI.current().select(GetPartyCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
9534        } catch (NamingException ex) {
9535            throw new RuntimeException(ex);
9536        }
9537
9538        return party == null ? null : new PartyObject(party);
9539    }
9540
9541    @GraphQLField
9542    @GraphQLName("parties")
9543    @GraphQLNonNull
9544    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
9545    static CountingPaginatedData<PartyObject> parties(final DataFetchingEnvironment env) {
9546        CountingPaginatedData<PartyObject> data;
9547
9548        try {
9549            var commandForm = PartyUtil.getHome().getGetPartiesForm();
9550            var command = CDI.current().select(GetPartiesCommand.class).get();
9551
9552            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9553            if(totalEntities == null) {
9554                data = Connections.emptyConnection();
9555            } else {
9556                try(var objectLimiter = new ObjectLimiter(env, PartyConstants.COMPONENT_VENDOR_NAME, PartyConstants.ENTITY_TYPE_NAME, totalEntities)) {
9557                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9558
9559                    var parties = entities.stream()
9560                            .map(PartyObject::new)
9561                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
9562
9563                    data = new CountedObjects<>(objectLimiter, parties);
9564                }
9565            }
9566        } catch (NamingException ex) {
9567            throw new RuntimeException(ex);
9568        }
9569
9570        return data;
9571    }
9572
9573    @GraphQLField
9574    @GraphQLName("company")
9575    static CompanyObject company(final DataFetchingEnvironment env,
9576            @GraphQLName("companyName") final String companyName,
9577            @GraphQLName("partyName") final String partyName,
9578            @GraphQLName("id") @GraphQLID final String id) {
9579        PartyCompany company;
9580
9581        try {
9582            var commandForm = PartyUtil.getHome().getGetCompanyForm();
9583
9584            commandForm.setCompanyName(companyName);
9585            commandForm.setPartyName(partyName);
9586            commandForm.setUuid(id);
9587
9588            company = CDI.current().select(GetCompanyCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
9589        } catch (NamingException ex) {
9590            throw new RuntimeException(ex);
9591        }
9592
9593        return company == null ? null : new CompanyObject(company);
9594    }
9595
9596    @GraphQLField
9597    @GraphQLName("companies")
9598    @GraphQLNonNull
9599    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
9600    static CountingPaginatedData<CompanyObject> companies(final DataFetchingEnvironment env) {
9601        CountingPaginatedData<CompanyObject> data;
9602
9603        try {
9604            var commandForm = PartyUtil.getHome().getGetCompaniesForm();
9605            var command = CDI.current().select(GetCompaniesCommand.class).get();
9606
9607            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9608            if(totalEntities == null) {
9609                data = Connections.emptyConnection();
9610            } else {
9611                try(var objectLimiter = new ObjectLimiter(env, PartyCompanyConstants.COMPONENT_VENDOR_NAME, PartyCompanyConstants.ENTITY_TYPE_NAME, totalEntities)) {
9612                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9613
9614                    var companies = entities.stream()
9615                            .map(CompanyObject::new)
9616                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
9617
9618                    data = new CountedObjects<>(objectLimiter, companies);
9619                }
9620            }
9621        } catch (NamingException ex) {
9622            throw new RuntimeException(ex);
9623        }
9624
9625        return data;
9626    }
9627
9628    @GraphQLField
9629    @GraphQLName("division")
9630    static DivisionObject division(final DataFetchingEnvironment env,
9631            @GraphQLName("companyName") final String companyName,
9632            @GraphQLName("divisionName") final String divisionName,
9633            @GraphQLName("partyName") final String partyName,
9634            @GraphQLName("id") @GraphQLID final String id) {
9635        PartyDivision division;
9636
9637        try {
9638            var commandForm = PartyUtil.getHome().getGetDivisionForm();
9639
9640            commandForm.setCompanyName(companyName);
9641            commandForm.setDivisionName(divisionName);
9642            commandForm.setPartyName(partyName);
9643            commandForm.setUuid(id);
9644
9645            division = CDI.current().select(GetDivisionCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
9646        } catch (NamingException ex) {
9647            throw new RuntimeException(ex);
9648        }
9649
9650        return division == null ? null : new DivisionObject(division);
9651    }
9652
9653    @GraphQLField
9654    @GraphQLName("divisions")
9655    @GraphQLNonNull
9656    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
9657    static CountingPaginatedData<DivisionObject> divisions(final DataFetchingEnvironment env,
9658            @GraphQLName("companyName") @GraphQLNonNull final String companyName) {
9659        CountingPaginatedData<DivisionObject> data;
9660
9661        try {
9662            var commandForm = PartyUtil.getHome().getGetDivisionsForm();
9663            var command = CDI.current().select(GetDivisionsCommand.class).get();
9664
9665            commandForm.setCompanyName(companyName);
9666
9667            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9668            if(totalEntities == null) {
9669                data = Connections.emptyConnection();
9670            } else {
9671                try(var objectLimiter = new ObjectLimiter(env, PartyDivisionConstants.COMPONENT_VENDOR_NAME, PartyDivisionConstants.ENTITY_TYPE_NAME, totalEntities)) {
9672                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9673
9674                    var divisions = entities.stream()
9675                            .map(DivisionObject::new)
9676                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
9677
9678                    data = new CountedObjects<>(objectLimiter, divisions);
9679                }
9680            }
9681        } catch (NamingException ex) {
9682            throw new RuntimeException(ex);
9683        }
9684
9685        return data;
9686    }
9687
9688    @GraphQLField
9689    @GraphQLName("department")
9690    static DepartmentObject department(final DataFetchingEnvironment env,
9691            @GraphQLName("companyName") final String companyName,
9692            @GraphQLName("divisionName") final String divisionName,
9693            @GraphQLName("departmentName") final String departmentName,
9694            @GraphQLName("partyName") final String partyName,
9695            @GraphQLName("id") @GraphQLID final String id) {
9696        PartyDepartment department;
9697
9698        try {
9699            var commandForm = PartyUtil.getHome().getGetDepartmentForm();
9700
9701            commandForm.setCompanyName(companyName);
9702            commandForm.setDivisionName(divisionName);
9703            commandForm.setDepartmentName(departmentName);
9704            commandForm.setPartyName(partyName);
9705            commandForm.setUuid(id);
9706
9707            department = CDI.current().select(GetDepartmentCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
9708        } catch (NamingException ex) {
9709            throw new RuntimeException(ex);
9710        }
9711
9712        return department == null ? null : new DepartmentObject(department);
9713    }
9714
9715    @GraphQLField
9716    @GraphQLName("departments")
9717    @GraphQLNonNull
9718    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
9719    static CountingPaginatedData<DepartmentObject> departments(final DataFetchingEnvironment env,
9720            @GraphQLName("companyName") @GraphQLNonNull final String companyName,
9721            @GraphQLName("divisionName") final String divisionName) {
9722        CountingPaginatedData<DepartmentObject> data;
9723
9724        try {
9725            var commandForm = PartyUtil.getHome().getGetDepartmentsForm();
9726            var command = CDI.current().select(GetDepartmentsCommand.class).get();
9727
9728            commandForm.setCompanyName(companyName);
9729            commandForm.setDivisionName(divisionName);
9730
9731            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9732            if(totalEntities == null) {
9733                data = Connections.emptyConnection();
9734            } else {
9735                try(var objectLimiter = new ObjectLimiter(env, PartyDepartmentConstants.COMPONENT_VENDOR_NAME, PartyDepartmentConstants.ENTITY_TYPE_NAME, totalEntities)) {
9736                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9737
9738                    var departments = entities.stream()
9739                            .map(DepartmentObject::new)
9740                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
9741
9742                    data = new CountedObjects<>(objectLimiter, departments);
9743                }
9744            }
9745        } catch (NamingException ex) {
9746            throw new RuntimeException(ex);
9747        }
9748
9749        return data;
9750    }
9751
9752    @GraphQLField
9753    @GraphQLName("warehouseType")
9754    static WarehouseTypeObject warehouseType(final DataFetchingEnvironment env,
9755            @GraphQLName("warehouseTypeName") final String warehouseTypeName,
9756            @GraphQLName("id") @GraphQLID final String id) {
9757        WarehouseType warehouseType;
9758
9759        try {
9760            var commandForm = WarehouseUtil.getHome().getGetWarehouseTypeForm();
9761
9762            commandForm.setWarehouseTypeName(warehouseTypeName);
9763            commandForm.setUuid(id);
9764
9765            warehouseType = CDI.current().select(GetWarehouseTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
9766        } catch (NamingException ex) {
9767            throw new RuntimeException(ex);
9768        }
9769
9770        return warehouseType == null ? null : new WarehouseTypeObject(warehouseType);
9771    }
9772
9773    @GraphQLField
9774    @GraphQLName("warehouseTypes")
9775    @GraphQLNonNull
9776    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
9777    static CountingPaginatedData<WarehouseTypeObject> warehouseTypes(final DataFetchingEnvironment env) {
9778        CountingPaginatedData<WarehouseTypeObject> data;
9779
9780        try {
9781            var commandForm = WarehouseUtil.getHome().getGetWarehouseTypesForm();
9782            var command = CDI.current().select(GetWarehouseTypesCommand.class).get();
9783
9784            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9785            if(totalEntities == null) {
9786                data = Connections.emptyConnection();
9787            } else {
9788                try(var objectLimiter = new ObjectLimiter(env, WarehouseTypeConstants.COMPONENT_VENDOR_NAME, WarehouseTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
9789                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9790
9791                    var warehouseTypes = entities.stream()
9792                            .map(WarehouseTypeObject::new)
9793                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
9794
9795                    data = new CountedObjects<>(objectLimiter, warehouseTypes);
9796                }
9797            }
9798        } catch (NamingException ex) {
9799            throw new RuntimeException(ex);
9800        }
9801
9802        return data;
9803    }
9804
9805    @GraphQLField
9806    @GraphQLName("warehouse")
9807    static WarehouseObject warehouse(final DataFetchingEnvironment env,
9808            @GraphQLName("warehouseName") final String warehouseName,
9809            @GraphQLName("partyName") final String partyName,
9810            @GraphQLName("id") @GraphQLID final String id) {
9811        Warehouse warehouse;
9812
9813        try {
9814            var commandForm = WarehouseUtil.getHome().getGetWarehouseForm();
9815
9816            commandForm.setWarehouseName(warehouseName);
9817            commandForm.setPartyName(partyName);
9818            commandForm.setUuid(id);
9819
9820            warehouse = CDI.current().select(GetWarehouseCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
9821        } catch (NamingException ex) {
9822            throw new RuntimeException(ex);
9823        }
9824
9825        return warehouse == null ? null : new WarehouseObject(warehouse);
9826    }
9827
9828    @GraphQLField
9829    @GraphQLName("warehouses")
9830    @GraphQLNonNull
9831    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
9832    static CountingPaginatedData<WarehouseObject> warehouses(final DataFetchingEnvironment env) {
9833        CountingPaginatedData<WarehouseObject> data;
9834
9835        try {
9836            var commandForm = WarehouseUtil.getHome().getGetWarehousesForm();
9837            var command = CDI.current().select(GetWarehousesCommand.class).get();
9838
9839            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9840            if(totalEntities == null) {
9841                data = Connections.emptyConnection();
9842            } else {
9843                try(var objectLimiter = new ObjectLimiter(env, WarehouseConstants.COMPONENT_VENDOR_NAME, WarehouseConstants.ENTITY_TYPE_NAME, totalEntities)) {
9844                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9845
9846                    var warehouses = entities.stream()
9847                            .map(WarehouseObject::new)
9848                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
9849
9850                    data = new CountedObjects<>(objectLimiter, warehouses);
9851                }
9852            }
9853        } catch (NamingException ex) {
9854            throw new RuntimeException(ex);
9855        }
9856
9857        return data;
9858    }
9859
9860    @GraphQLField
9861    @GraphQLName("locationUseType")
9862    static LocationUseTypeObject locationUseType(final DataFetchingEnvironment env,
9863            @GraphQLName("locationUseTypeName") final String locationUseTypeName,
9864            @GraphQLName("id") @GraphQLID final String id) {
9865        LocationUseType locationUseType;
9866
9867        try {
9868            var commandForm = WarehouseUtil.getHome().getGetLocationUseTypeForm();
9869
9870            commandForm.setLocationUseTypeName(locationUseTypeName);
9871            commandForm.setUuid(id);
9872
9873            locationUseType = CDI.current().select(GetLocationUseTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
9874        } catch (NamingException ex) {
9875            throw new RuntimeException(ex);
9876        }
9877
9878        return locationUseType == null ? null : new LocationUseTypeObject(locationUseType);
9879    }
9880
9881    @GraphQLField
9882    @GraphQLName("locationUseTypes")
9883    @GraphQLNonNull
9884    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
9885    static CountingPaginatedData<LocationUseTypeObject> locationUseTypes(final DataFetchingEnvironment env) {
9886        CountingPaginatedData<LocationUseTypeObject> data;
9887
9888        try {
9889            var commandForm = WarehouseUtil.getHome().getGetLocationUseTypesForm();
9890            var command = CDI.current().select(GetLocationUseTypesCommand.class).get();
9891
9892            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9893            if(totalEntities == null) {
9894                data = Connections.emptyConnection();
9895            } else {
9896                try(var objectLimiter = new ObjectLimiter(env, LocationUseTypeConstants.COMPONENT_VENDOR_NAME, LocationUseTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
9897                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9898
9899                    var locationUseTypes = entities.stream()
9900                            .map(LocationUseTypeObject::new)
9901                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
9902
9903                    data = new CountedObjects<>(objectLimiter, locationUseTypes);
9904                }
9905            }
9906        } catch (NamingException ex) {
9907            throw new RuntimeException(ex);
9908        }
9909
9910        return data;
9911    }
9912
9913    @GraphQLField
9914    @GraphQLName("inventoryLocation")
9915    static InventoryLocationObject inventoryLocation(final DataFetchingEnvironment env,
9916            @GraphQLName("partyName") final String partyName,
9917            @GraphQLName("warehouseName") final String warehouseName,
9918            @GraphQLName("locationName") @GraphQLNonNull final String locationName,
9919            @GraphQLName("itemName") @GraphQLNonNull final String itemName) {
9920        InventoryLocation inventoryLocation;
9921
9922        try {
9923            var commandForm = InventoryUtil.getHome().getGetInventoryLocationForm();
9924
9925            commandForm.setPartyName(partyName);
9926            commandForm.setWarehouseName(warehouseName);
9927            commandForm.setLocationName(locationName);
9928            commandForm.setItemName(itemName);
9929
9930            inventoryLocation = CDI.current().select(GetInventoryLocationCommand.class).get()
9931                    .getEntityForGraphQl(getUserVisitPK(env), commandForm);
9932        } catch (NamingException ex) {
9933            throw new RuntimeException(ex);
9934        }
9935
9936        return inventoryLocation == null ? null : new InventoryLocationObject(inventoryLocation);
9937    }
9938
9939    @GraphQLField
9940    @GraphQLName("inventoryLocations")
9941    @GraphQLNonNull
9942    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
9943    static CountingPaginatedData<InventoryLocationObject> inventoryLocations(final DataFetchingEnvironment env,
9944            @GraphQLName("partyName") final String partyName,
9945            @GraphQLName("warehouseName") final String warehouseName,
9946            @GraphQLName("locationName") final String locationName,
9947            @GraphQLName("ownerPartyName") final String ownerPartyName,
9948            @GraphQLName("itemName") final String itemName,
9949            @GraphQLName("unitOfMeasureKindName") final String unitOfMeasureKindName,
9950            @GraphQLName("unitOfMeasureTypeName") final String unitOfMeasureTypeName,
9951            @GraphQLName("inventoryConditionName") final String inventoryConditionName) {
9952        CountingPaginatedData<InventoryLocationObject> data;
9953
9954        try {
9955            var commandForm = InventoryUtil.getHome().getGetInventoryLocationsForm();
9956            var command = CDI.current().select(GetInventoryLocationsCommand.class).get();
9957
9958            commandForm.setPartyName(partyName);
9959            commandForm.setWarehouseName(warehouseName);
9960            commandForm.setLocationName(locationName);
9961            commandForm.setOwnerPartyName(ownerPartyName);
9962            commandForm.setItemName(itemName);
9963            commandForm.setUnitOfMeasureKindName(unitOfMeasureKindName);
9964            commandForm.setUnitOfMeasureTypeName(unitOfMeasureTypeName);
9965            commandForm.setInventoryConditionName(inventoryConditionName);
9966
9967            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9968            if(totalEntities == null) {
9969                data = Connections.emptyConnection();
9970            } else {
9971                try(var objectLimiter = new ObjectLimiter(env, InventoryLocationConstants.COMPONENT_VENDOR_NAME,
9972                        InventoryLocationConstants.ENTITY_TYPE_NAME, totalEntities)) {
9973                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
9974                    var inventoryLocations = entities.stream()
9975                            .map(InventoryLocationObject::new)
9976                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
9977
9978                    data = new CountedObjects<>(objectLimiter, inventoryLocations);
9979                }
9980            }
9981        } catch (NamingException ex) {
9982            throw new RuntimeException(ex);
9983        }
9984
9985        return data;
9986    }
9987
9988    @GraphQLField
9989    @GraphQLName("inventoryLayerBucket")
9990    static InventoryLayerBucketObject inventoryLayerBucket(final DataFetchingEnvironment env,
9991            @GraphQLName("partyName") final String partyName,
9992            @GraphQLName("companyName") final String companyName,
9993            @GraphQLName("inventoryConditionName") @GraphQLNonNull final String inventoryConditionName,
9994            @GraphQLName("inventoryLayerSequence") @GraphQLNonNull final String inventoryLayerSequence,
9995            @GraphQLName("itemName") @GraphQLNonNull final String itemName,
9996            @GraphQLName("inventoryBucketTypeName") @GraphQLNonNull final String inventoryBucketTypeName) {
9997        InventoryLayerBucket inventoryLayerBucket;
9998
9999        try {
10000            var commandForm = InventoryUtil.getHome().getGetInventoryLayerBucketForm();
10001
10002            commandForm.setPartyName(partyName);
10003            commandForm.setCompanyName(companyName);
10004            commandForm.setInventoryConditionName(inventoryConditionName);
10005            commandForm.setItemName(itemName);
10006            commandForm.setInventoryLayerSequence(inventoryLayerSequence);
10007            commandForm.setInventoryBucketTypeName(inventoryBucketTypeName);
10008
10009            inventoryLayerBucket = CDI.current().select(GetInventoryLayerBucketCommand.class).get()
10010                    .getEntityForGraphQl(getUserVisitPK(env), commandForm);
10011        } catch (NamingException ex) {
10012            throw new RuntimeException(ex);
10013        }
10014
10015        return inventoryLayerBucket == null ? null : new InventoryLayerBucketObject(inventoryLayerBucket);
10016    }
10017
10018    @GraphQLField
10019    @GraphQLName("inventoryLayerBuckets")
10020    @GraphQLNonNull
10021    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
10022    static CountingPaginatedData<InventoryLayerBucketObject> inventoryLayerBuckets(final DataFetchingEnvironment env,
10023            @GraphQLName("partyName") final String partyName,
10024            @GraphQLName("companyName") final String companyName,
10025            @GraphQLName("inventoryConditionName") final String inventoryConditionName,
10026            @GraphQLName("inventoryLayerSequence") final String inventoryLayerSequence,
10027            @GraphQLName("itemName") final String itemName,
10028            @GraphQLName("inventoryBucketTypeName") final String inventoryBucketTypeName) {
10029        CountingPaginatedData<InventoryLayerBucketObject> data;
10030
10031        try {
10032            var commandForm = InventoryUtil.getHome().getGetInventoryLayerBucketsForm();
10033            var command = CDI.current().select(GetInventoryLayerBucketsCommand.class).get();
10034
10035            commandForm.setPartyName(partyName);
10036            commandForm.setCompanyName(companyName);
10037            commandForm.setInventoryConditionName(inventoryConditionName);
10038            commandForm.setItemName(itemName);
10039            commandForm.setInventoryLayerSequence(inventoryLayerSequence);
10040            commandForm.setInventoryBucketTypeName(inventoryBucketTypeName);
10041
10042            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10043            if(totalEntities == null) {
10044                data = Connections.emptyConnection();
10045            } else {
10046                try(var objectLimiter = new ObjectLimiter(env, InventoryLayerBucketConstants.COMPONENT_VENDOR_NAME,
10047                        InventoryLayerBucketConstants.ENTITY_TYPE_NAME, totalEntities)) {
10048                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10049                    var inventoryLayerBuckets = entities.stream()
10050                            .map(InventoryLayerBucketObject::new)
10051                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
10052
10053                    data = new CountedObjects<>(objectLimiter, inventoryLayerBuckets);
10054                }
10055            }
10056        } catch (NamingException ex) {
10057            throw new RuntimeException(ex);
10058        }
10059
10060        return data;
10061    }
10062
10063    @GraphQLField
10064    @GraphQLName("inventoryLocationBucket")
10065    static InventoryLocationBucketObject inventoryLocationBucket(final DataFetchingEnvironment env,
10066            @GraphQLName("partyName") final String partyName,
10067            @GraphQLName("warehouseName") final String warehouseName,
10068            @GraphQLName("locationName") @GraphQLNonNull final String locationName,
10069            @GraphQLName("itemName") @GraphQLNonNull final String itemName,
10070            @GraphQLName("inventoryBucketTypeName") @GraphQLNonNull final String inventoryBucketTypeName) {
10071        InventoryLocationBucket inventoryLocationBucket;
10072
10073        try {
10074            var commandForm = InventoryUtil.getHome().getGetInventoryLocationBucketForm();
10075
10076            commandForm.setPartyName(partyName);
10077            commandForm.setWarehouseName(warehouseName);
10078            commandForm.setLocationName(locationName);
10079            commandForm.setItemName(itemName);
10080            commandForm.setInventoryBucketTypeName(inventoryBucketTypeName);
10081
10082            inventoryLocationBucket = CDI.current().select(GetInventoryLocationBucketCommand.class).get()
10083                    .getEntityForGraphQl(getUserVisitPK(env), commandForm);
10084        } catch (NamingException ex) {
10085            throw new RuntimeException(ex);
10086        }
10087
10088        return inventoryLocationBucket == null ? null : new InventoryLocationBucketObject(inventoryLocationBucket);
10089    }
10090
10091    @GraphQLField
10092    @GraphQLName("inventoryLocationBuckets")
10093    @GraphQLNonNull
10094    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
10095    static CountingPaginatedData<InventoryLocationBucketObject> inventoryLocationBuckets(final DataFetchingEnvironment env,
10096            @GraphQLName("partyName") final String partyName,
10097            @GraphQLName("warehouseName") final String warehouseName,
10098            @GraphQLName("locationName") final String locationName,
10099            @GraphQLName("itemName") final String itemName,
10100            @GraphQLName("inventoryBucketTypeName") final String inventoryBucketTypeName) {
10101        CountingPaginatedData<InventoryLocationBucketObject> data;
10102
10103        try {
10104            var commandForm = InventoryUtil.getHome().getGetInventoryLocationBucketsForm();
10105            var command = CDI.current().select(GetInventoryLocationBucketsCommand.class).get();
10106
10107            commandForm.setPartyName(partyName);
10108            commandForm.setWarehouseName(warehouseName);
10109            commandForm.setLocationName(locationName);
10110            commandForm.setItemName(itemName);
10111            commandForm.setInventoryBucketTypeName(inventoryBucketTypeName);
10112
10113            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10114            if(totalEntities == null) {
10115                data = Connections.emptyConnection();
10116            } else {
10117                try(var objectLimiter = new ObjectLimiter(env, InventoryLocationBucketConstants.COMPONENT_VENDOR_NAME,
10118                        InventoryLocationBucketConstants.ENTITY_TYPE_NAME, totalEntities)) {
10119                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10120                    var inventoryLocationBuckets = entities.stream()
10121                            .map(InventoryLocationBucketObject::new)
10122                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
10123
10124                    data = new CountedObjects<>(objectLimiter, inventoryLocationBuckets);
10125                }
10126            }
10127        } catch (NamingException ex) {
10128            throw new RuntimeException(ex);
10129        }
10130
10131        return data;
10132    }
10133
10134    @GraphQLField
10135    @GraphQLName("inventoryLocationGroup")
10136    static InventoryLocationGroupObject inventoryLocationGroup(final DataFetchingEnvironment env,
10137            @GraphQLName("warehouseName") final String warehouseName,
10138            @GraphQLName("inventoryLocationGroupName") final String inventoryLocationGroupName) {
10139        InventoryLocationGroup inventoryLocationGroup;
10140
10141        try {
10142            var commandForm = InventoryUtil.getHome().getGetInventoryLocationGroupForm();
10143
10144            commandForm.setWarehouseName(warehouseName);
10145            commandForm.setInventoryLocationGroupName(inventoryLocationGroupName);
10146
10147            inventoryLocationGroup = CDI.current().select(GetInventoryLocationGroupCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
10148        } catch (NamingException ex) {
10149            throw new RuntimeException(ex);
10150        }
10151
10152        return inventoryLocationGroup == null ? null : new InventoryLocationGroupObject(inventoryLocationGroup);
10153    }
10154
10155    @GraphQLField
10156    @GraphQLName("inventoryLocationGroups")
10157    @GraphQLNonNull
10158    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
10159    static CountingPaginatedData<InventoryLocationGroupObject> inventoryLocationGroups(final DataFetchingEnvironment env,
10160            @GraphQLName("warehouseName") final String warehouseName) {
10161        CountingPaginatedData<InventoryLocationGroupObject> data;
10162
10163        try {
10164            var commandForm = InventoryUtil.getHome().getGetInventoryLocationGroupsForm();
10165            var command = CDI.current().select(GetInventoryLocationGroupsCommand.class).get();
10166
10167            commandForm.setWarehouseName(warehouseName);
10168
10169            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10170            if(totalEntities == null) {
10171                data = Connections.emptyConnection();
10172            } else {
10173                try(var objectLimiter = new ObjectLimiter(env, InventoryLocationGroupConstants.COMPONENT_VENDOR_NAME, InventoryLocationGroupConstants.ENTITY_TYPE_NAME, totalEntities)) {
10174                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10175
10176                    var inventoryLocationGroups = entities.stream()
10177                            .map(InventoryLocationGroupObject::new)
10178                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
10179
10180                    data = new CountedObjects<>(objectLimiter, inventoryLocationGroups);
10181                }
10182            }
10183        } catch (NamingException ex) {
10184            throw new RuntimeException(ex);
10185        }
10186
10187        return data;
10188    }
10189
10190    @GraphQLField
10191    @GraphQLName("locationType")
10192    static LocationTypeObject locationType(final DataFetchingEnvironment env,
10193            @GraphQLName("warehouseName") final String warehouseName,
10194            @GraphQLName("locationTypeName") final String locationTypeName) {
10195        LocationType locationType;
10196
10197        try {
10198            var commandForm = WarehouseUtil.getHome().getGetLocationTypeForm();
10199
10200            commandForm.setWarehouseName(warehouseName);
10201            commandForm.setLocationTypeName(locationTypeName);
10202
10203            locationType = CDI.current().select(GetLocationTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
10204        } catch (NamingException ex) {
10205            throw new RuntimeException(ex);
10206        }
10207
10208        return locationType == null ? null : new LocationTypeObject(locationType);
10209    }
10210
10211    @GraphQLField
10212    @GraphQLName("locationTypes")
10213    @GraphQLNonNull
10214    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
10215    static CountingPaginatedData<LocationTypeObject> locationTypes(final DataFetchingEnvironment env,
10216            @GraphQLName("warehouseName") final String warehouseName) {
10217        CountingPaginatedData<LocationTypeObject> data;
10218
10219        try {
10220            var commandForm = WarehouseUtil.getHome().getGetLocationTypesForm();
10221            var command = CDI.current().select(GetLocationTypesCommand.class).get();
10222
10223            commandForm.setWarehouseName(warehouseName);
10224
10225            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10226            if(totalEntities == null) {
10227                data = Connections.emptyConnection();
10228            } else {
10229                try(var objectLimiter = new ObjectLimiter(env, LocationTypeConstants.COMPONENT_VENDOR_NAME, LocationTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
10230                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10231
10232                    var locationTypes = entities.stream()
10233                            .map(LocationTypeObject::new)
10234                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
10235
10236                    data = new CountedObjects<>(objectLimiter, locationTypes);
10237                }
10238            }
10239        } catch (NamingException ex) {
10240            throw new RuntimeException(ex);
10241        }
10242
10243        return data;
10244    }
10245
10246    @GraphQLField
10247    @GraphQLName("locationNameElement")
10248    static LocationNameElementObject locationNameElement(final DataFetchingEnvironment env,
10249            @GraphQLName("warehouseName") final String warehouseName,
10250            @GraphQLName("locationTypeName") final String locationTypeName,
10251            @GraphQLName("locationNameElementName") final String locationNameElementName) {
10252        LocationNameElement locationNameElement;
10253
10254        try {
10255            var commandForm = WarehouseUtil.getHome().getGetLocationNameElementForm();
10256
10257            commandForm.setWarehouseName(warehouseName);
10258            commandForm.setLocationTypeName(locationTypeName);
10259            commandForm.setLocationNameElementName(locationNameElementName);
10260
10261            locationNameElement = CDI.current().select(GetLocationNameElementCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
10262        } catch (NamingException ex) {
10263            throw new RuntimeException(ex);
10264        }
10265
10266        return locationNameElement == null ? null : new LocationNameElementObject(locationNameElement);
10267    }
10268
10269    @GraphQLField
10270    @GraphQLName("locationNameElements")
10271    @GraphQLNonNull
10272    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
10273    static CountingPaginatedData<LocationNameElementObject> locationNameElements(final DataFetchingEnvironment env,
10274            @GraphQLName("warehouseName") final String warehouseName,
10275            @GraphQLName("locationTypeName") final String locationTypeName) {
10276        CountingPaginatedData<LocationNameElementObject> data;
10277
10278        try {
10279            var commandForm = WarehouseUtil.getHome().getGetLocationNameElementsForm();
10280            var command = CDI.current().select(GetLocationNameElementsCommand.class).get();
10281
10282            commandForm.setWarehouseName(warehouseName);
10283            commandForm.setLocationTypeName(locationTypeName);
10284
10285            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10286            if(totalEntities == null) {
10287                data = Connections.emptyConnection();
10288            } else {
10289                try(var objectLimiter = new ObjectLimiter(env, LocationNameElementConstants.COMPONENT_VENDOR_NAME, LocationNameElementConstants.ENTITY_TYPE_NAME, totalEntities)) {
10290                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10291
10292                    var locationNameElements = entities.stream()
10293                            .map(LocationNameElementObject::new)
10294                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
10295
10296                    data = new CountedObjects<>(objectLimiter, locationNameElements);
10297                }
10298            }
10299        } catch (NamingException ex) {
10300            throw new RuntimeException(ex);
10301        }
10302
10303        return data;
10304    }
10305
10306    @GraphQLField
10307    @GraphQLName("location")
10308    static LocationObject location(final DataFetchingEnvironment env,
10309            @GraphQLName("warehouseName") final String warehouseName,
10310            @GraphQLName("locationName") final String locationName) {
10311        Location location;
10312
10313        try {
10314            var commandForm = WarehouseUtil.getHome().getGetLocationForm();
10315
10316            commandForm.setWarehouseName(warehouseName);
10317            commandForm.setLocationName(locationName);
10318
10319            location = CDI.current().select(GetLocationCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
10320        } catch (NamingException ex) {
10321            throw new RuntimeException(ex);
10322        }
10323
10324        return location == null ? null : new LocationObject(location);
10325    }
10326
10327    @GraphQLField
10328    @GraphQLName("locations")
10329    @GraphQLNonNull
10330    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
10331    static CountingPaginatedData<LocationObject> locations(final DataFetchingEnvironment env,
10332            @GraphQLName("warehouseName") final String warehouseName) {
10333        CountingPaginatedData<LocationObject> data;
10334
10335        try {
10336            var commandForm = WarehouseUtil.getHome().getGetLocationsForm();
10337            var command = CDI.current().select(GetLocationsCommand.class).get();
10338
10339            commandForm.setWarehouseName(warehouseName);
10340
10341            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10342            if(totalEntities == null) {
10343                data = Connections.emptyConnection();
10344            } else {
10345                try(var objectLimiter = new ObjectLimiter(env, LocationConstants.COMPONENT_VENDOR_NAME, LocationConstants.ENTITY_TYPE_NAME, totalEntities)) {
10346                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10347
10348                    var locations = entities.stream()
10349                            .map(LocationObject::new)
10350                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
10351
10352                    data = new CountedObjects<>(objectLimiter, locations);
10353                }
10354            }
10355        } catch (NamingException ex) {
10356            throw new RuntimeException(ex);
10357        }
10358
10359        return data;
10360    }
10361
10362    @GraphQLField
10363    @GraphQLName("cancellationKind")
10364    static CancellationKindObject cancellationKind(final DataFetchingEnvironment env,
10365            @GraphQLName("cancellationKindName") final String cancellationKindName,
10366            @GraphQLName("id") @GraphQLID final String id) {
10367        CancellationKind cancellationKind;
10368
10369        try {
10370            var commandForm = CancellationPolicyUtil.getHome().getGetCancellationKindForm();
10371
10372            commandForm.setCancellationKindName(cancellationKindName);
10373            commandForm.setUuid(id);
10374
10375            cancellationKind = CDI.current().select(GetCancellationKindCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
10376        } catch (NamingException ex) {
10377            throw new RuntimeException(ex);
10378        }
10379
10380        return cancellationKind == null ? null : new CancellationKindObject(cancellationKind);
10381    }
10382
10383    @GraphQLField
10384    @GraphQLName("cancellationKinds")
10385    @GraphQLNonNull
10386    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
10387    static CountingPaginatedData<CancellationKindObject> cancellationKinds(final DataFetchingEnvironment env) {
10388        CountingPaginatedData<CancellationKindObject> data;
10389
10390        try {
10391            var commandForm = CancellationPolicyUtil.getHome().getGetCancellationKindsForm();
10392            var command = CDI.current().select(GetCancellationKindsCommand.class).get();
10393
10394            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10395            if(totalEntities == null) {
10396                data = Connections.emptyConnection();
10397            } else {
10398                try(var objectLimiter = new ObjectLimiter(env, CancellationKindConstants.COMPONENT_VENDOR_NAME, CancellationKindConstants.ENTITY_TYPE_NAME, totalEntities)) {
10399                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10400
10401                    var cancellationKinds = entities.stream()
10402                            .map(CancellationKindObject::new)
10403                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
10404
10405                    data = new CountedObjects<>(objectLimiter, cancellationKinds);
10406                }
10407            }
10408        } catch (NamingException ex) {
10409            throw new RuntimeException(ex);
10410        }
10411
10412        return data;
10413    }
10414
10415    @GraphQLField
10416    @GraphQLName("cancellationPolicy")
10417    static CancellationPolicyObject cancellationPolicy(final DataFetchingEnvironment env,
10418            @GraphQLName("cancellationKindName") final String cancellationKindName,
10419            @GraphQLName("cancellationPolicyName") final String cancellationPolicyName,
10420            @GraphQLName("id") @GraphQLID final String id) {
10421        CancellationPolicy cancellationPolicy;
10422
10423        try {
10424            var commandForm = CancellationPolicyUtil.getHome().getGetCancellationPolicyForm();
10425
10426            commandForm.setCancellationKindName(cancellationKindName);
10427            commandForm.setCancellationPolicyName(cancellationPolicyName);
10428            commandForm.setUuid(id);
10429
10430            cancellationPolicy = CDI.current().select(GetCancellationPolicyCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
10431        } catch (NamingException ex) {
10432            throw new RuntimeException(ex);
10433        }
10434
10435        return cancellationPolicy == null ? null : new CancellationPolicyObject(cancellationPolicy);
10436    }
10437
10438    @GraphQLField
10439    @GraphQLName("cancellationPolicies")
10440    @GraphQLNonNull
10441    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
10442    static CountingPaginatedData<CancellationPolicyObject> cancellationPolicies(final DataFetchingEnvironment env,
10443            @GraphQLName("cancellationKindName") final String cancellationKindName) {
10444        CountingPaginatedData<CancellationPolicyObject> data;
10445
10446        try {
10447            var commandForm = CancellationPolicyUtil.getHome().getGetCancellationPoliciesForm();
10448            var command = CDI.current().select(GetCancellationPoliciesCommand.class).get();
10449
10450            commandForm.setCancellationKindName(cancellationKindName);
10451
10452            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10453            if(totalEntities == null) {
10454                data = Connections.emptyConnection();
10455            } else {
10456                try(var objectLimiter = new ObjectLimiter(env, CancellationPolicyConstants.COMPONENT_VENDOR_NAME, CancellationPolicyConstants.ENTITY_TYPE_NAME, totalEntities)) {
10457                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10458
10459                    var cancellationPolicies = entities.stream()
10460                            .map(CancellationPolicyObject::new)
10461                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
10462
10463                    data = new CountedObjects<>(objectLimiter, cancellationPolicies);
10464                }
10465            }
10466        } catch (NamingException ex) {
10467            throw new RuntimeException(ex);
10468        }
10469
10470        return data;
10471    }
10472
10473    @GraphQLField
10474    @GraphQLName("returnKind")
10475    static ReturnKindObject returnKind(final DataFetchingEnvironment env,
10476            @GraphQLName("returnKindName") final String returnKindName,
10477            @GraphQLName("id") @GraphQLID final String id) {
10478        ReturnKind returnKind;
10479
10480        try {
10481            var commandForm = ReturnPolicyUtil.getHome().getGetReturnKindForm();
10482
10483            commandForm.setReturnKindName(returnKindName);
10484            commandForm.setUuid(id);
10485
10486            returnKind = CDI.current().select(GetReturnKindCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
10487        } catch (NamingException ex) {
10488            throw new RuntimeException(ex);
10489        }
10490
10491        return returnKind == null ? null : new ReturnKindObject(returnKind);
10492    }
10493
10494    @GraphQLField
10495    @GraphQLName("returnKinds")
10496    @GraphQLNonNull
10497    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
10498    static CountingPaginatedData<ReturnKindObject> returnKinds(final DataFetchingEnvironment env) {
10499        CountingPaginatedData<ReturnKindObject> data;
10500
10501        try {
10502            var commandForm = ReturnPolicyUtil.getHome().getGetReturnKindsForm();
10503            var command = CDI.current().select(GetReturnKindsCommand.class).get();
10504
10505            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10506            if(totalEntities == null) {
10507                data = Connections.emptyConnection();
10508            } else {
10509                try(var objectLimiter = new ObjectLimiter(env, ReturnKindConstants.COMPONENT_VENDOR_NAME, ReturnKindConstants.ENTITY_TYPE_NAME, totalEntities)) {
10510                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10511
10512                    var returnKinds = entities.stream()
10513                            .map(ReturnKindObject::new)
10514                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
10515
10516                    data = new CountedObjects<>(objectLimiter, returnKinds);
10517                }
10518            }
10519        } catch (NamingException ex) {
10520            throw new RuntimeException(ex);
10521        }
10522
10523        return data;
10524    }
10525
10526    @GraphQLField
10527    @GraphQLName("returnPolicy")
10528    static ReturnPolicyObject returnPolicy(final DataFetchingEnvironment env,
10529            @GraphQLName("returnKindName") final String returnKindName,
10530            @GraphQLName("returnPolicyName") final String returnPolicyName,
10531            @GraphQLName("id") @GraphQLID final String id) {
10532        ReturnPolicy returnPolicy;
10533
10534        try {
10535            var commandForm = ReturnPolicyUtil.getHome().getGetReturnPolicyForm();
10536
10537            commandForm.setReturnKindName(returnKindName);
10538            commandForm.setReturnPolicyName(returnPolicyName);
10539            commandForm.setUuid(id);
10540
10541            returnPolicy = CDI.current().select(GetReturnPolicyCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
10542        } catch (NamingException ex) {
10543            throw new RuntimeException(ex);
10544        }
10545
10546        return returnPolicy == null ? null : new ReturnPolicyObject(returnPolicy);
10547    }
10548
10549    @GraphQLField
10550    @GraphQLName("returnPolicies")
10551    @GraphQLNonNull
10552    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
10553    static CountingPaginatedData<ReturnPolicyObject> returnPolicies(final DataFetchingEnvironment env,
10554            @GraphQLName("returnKindName") final String returnKindName) {
10555        CountingPaginatedData<ReturnPolicyObject> data;
10556
10557        try {
10558            var commandForm = ReturnPolicyUtil.getHome().getGetReturnPoliciesForm();
10559            var command = CDI.current().select(GetReturnPoliciesCommand.class).get();
10560
10561            commandForm.setReturnKindName(returnKindName);
10562
10563            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10564            if(totalEntities == null) {
10565                data = Connections.emptyConnection();
10566            } else {
10567                try(var objectLimiter = new ObjectLimiter(env, ReturnPolicyConstants.COMPONENT_VENDOR_NAME, ReturnPolicyConstants.ENTITY_TYPE_NAME, totalEntities)) {
10568                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10569
10570                    var returnPolicies = entities.stream()
10571                            .map(ReturnPolicyObject::new)
10572                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
10573
10574                    data = new CountedObjects<>(objectLimiter, returnPolicies);
10575                }
10576            }
10577        } catch(NamingException ex) {
10578            throw new RuntimeException(ex);
10579        }
10580
10581        return data;
10582    }
10583
10584    @GraphQLField
10585    @GraphQLName("item")
10586    static ItemObject item(final DataFetchingEnvironment env,
10587            @GraphQLName("itemName") final String itemName,
10588            @GraphQLName("itemNameOrAlias") final String itemNameOrAlias,
10589            @GraphQLName("id") @GraphQLID final String id) {
10590        Item item;
10591
10592        try {
10593            var commandForm = ItemUtil.getHome().getGetItemForm();
10594
10595            commandForm.setItemName(itemName);
10596            commandForm.setItemNameOrAlias(itemNameOrAlias);
10597            commandForm.setUuid(id);
10598
10599            item = CDI.current().select(GetItemCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
10600        } catch (NamingException ex) {
10601            throw new RuntimeException(ex);
10602        }
10603
10604        return item == null ? null : new ItemObject(item);
10605    }
10606
10607    @GraphQLField
10608    @GraphQLName("items")
10609    @GraphQLNonNull
10610    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
10611    static CountingPaginatedData<ItemObject> items(final DataFetchingEnvironment env) {
10612        CountingPaginatedData<ItemObject> data;
10613
10614        try {
10615            var commandForm = ItemUtil.getHome().getGetItemsForm();
10616            var command = CDI.current().select(GetItemsCommand.class).get();
10617
10618            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10619            if(totalEntities == null) {
10620                data = Connections.emptyConnection();
10621            } else {
10622                try(var objectLimiter = new ObjectLimiter(env, ItemConstants.COMPONENT_VENDOR_NAME, ItemConstants.ENTITY_TYPE_NAME, totalEntities)) {
10623                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10624
10625                    var items = entities.stream()
10626                            .map(ItemObject::new)
10627                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
10628
10629                    data = new CountedObjects<>(objectLimiter, items);
10630                }
10631            }
10632        } catch (NamingException ex) {
10633            throw new RuntimeException(ex);
10634        }
10635
10636        return data;
10637    }
10638
10639    @GraphQLField
10640    @GraphQLName("itemUnitOfMeasureType")
10641    static ItemUnitOfMeasureTypeObject itemUnitOfMeasureType(final DataFetchingEnvironment env,
10642            @GraphQLName("itemName") @GraphQLNonNull final String itemName,
10643            @GraphQLName("unitOfMeasureTypeName") @GraphQLNonNull final String unitOfMeasureTypeName) {
10644        ItemUnitOfMeasureType itemUnitOfMeasureType;
10645
10646        try {
10647            var commandForm = ItemUtil.getHome().getGetItemUnitOfMeasureTypeForm();
10648
10649            commandForm.setItemName(itemName);
10650            commandForm.setUnitOfMeasureTypeName(unitOfMeasureTypeName);
10651
10652            itemUnitOfMeasureType = CDI.current().select(GetItemUnitOfMeasureTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
10653        } catch (NamingException ex) {
10654            throw new RuntimeException(ex);
10655        }
10656
10657        return itemUnitOfMeasureType == null ? null : new ItemUnitOfMeasureTypeObject(itemUnitOfMeasureType);
10658    }
10659
10660    @GraphQLField
10661    @GraphQLName("itemUnitOfMeasureTypes")
10662    @GraphQLNonNull
10663    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
10664    static CountingPaginatedData<ItemUnitOfMeasureTypeObject> itemUnitOfMeasureTypes(final DataFetchingEnvironment env,
10665            @GraphQLName("itemName") @GraphQLNonNull final String itemName) {
10666        CountingPaginatedData<ItemUnitOfMeasureTypeObject> data;
10667
10668        try {
10669            var commandForm = ItemUtil.getHome().getGetItemUnitOfMeasureTypesForm();
10670            var command = CDI.current().select(GetItemUnitOfMeasureTypesCommand.class).get();
10671
10672            commandForm.setItemName(itemName);
10673
10674            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10675            if(totalEntities == null) {
10676                data = Connections.emptyConnection();
10677            } else {
10678                try(var objectLimiter = new ObjectLimiter(env, ItemUnitOfMeasureTypeConstants.COMPONENT_VENDOR_NAME, ItemUnitOfMeasureTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
10679                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10680
10681                    var itemUnitOfMeasureTypeObjects = entities.stream()
10682                            .map(ItemUnitOfMeasureTypeObject::new)
10683                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
10684
10685                    data = new CountedObjects<>(objectLimiter, itemUnitOfMeasureTypeObjects);
10686                }
10687            }
10688        } catch (NamingException ex) {
10689            throw new RuntimeException(ex);
10690        }
10691
10692        return data;
10693    }
10694
10695
10696    @GraphQLField
10697    @GraphQLName("itemDescription")
10698    static ItemDescriptionObject itemDescription(final DataFetchingEnvironment env,
10699            @GraphQLName("itemDescriptionTypeName") final String itemDescriptionTypeName,
10700            @GraphQLName("itemName") final String itemName,
10701            @GraphQLName("languageIsoName") final String languageIsoName,
10702            @GraphQLName("id") @GraphQLID final String id,
10703            @GraphQLName("referrer") final String referrer) {
10704        ItemDescription itemDescription;
10705
10706        try {
10707            var commandForm = ItemUtil.getHome().getGetItemDescriptionForm();
10708
10709            commandForm.setItemDescriptionTypeName(itemDescriptionTypeName);
10710            commandForm.setItemName(itemName);
10711            commandForm.setLanguageIsoName(languageIsoName);
10712            commandForm.setUuid(id);
10713            commandForm.setReferrer(referrer);
10714
10715            itemDescription = CDI.current().select(GetItemDescriptionCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
10716        } catch (NamingException ex) {
10717            throw new RuntimeException(ex);
10718        }
10719
10720        return itemDescription == null ? null : new ItemDescriptionObject(itemDescription);
10721    }
10722
10723    @GraphQLField
10724    @GraphQLName("itemDescriptions")
10725    @GraphQLNonNull
10726    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
10727    static CountingPaginatedData<ItemDescriptionObject> itemDescriptions(final DataFetchingEnvironment env,
10728            @GraphQLName("itemName") @GraphQLNonNull final String itemName,
10729            @GraphQLName("itemDescriptionTypeUseTypeName") final String itemDescriptionTypeUseTypeName,
10730            @GraphQLName("languageIsoName") final String languageIsoName) {
10731        CountingPaginatedData<ItemDescriptionObject> data;
10732
10733        try {
10734            var commandForm = ItemUtil.getHome().getGetItemDescriptionsForm();
10735            var command = CDI.current().select(GetItemDescriptionsCommand.class).get();
10736
10737            commandForm.setItemName(itemName);
10738            commandForm.setItemDescriptionTypeUseTypeName(itemDescriptionTypeUseTypeName);
10739            commandForm.setLanguageIsoName(languageIsoName);
10740
10741            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10742            if(totalEntities == null) {
10743                data = Connections.emptyConnection();
10744            } else {
10745                try(var objectLimiter = new ObjectLimiter(env, ItemDescriptionConstants.COMPONENT_VENDOR_NAME, ItemDescriptionConstants.ENTITY_TYPE_NAME, totalEntities)) {
10746                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10747                    var limitOffset = objectLimiter.getLimitOffset();
10748                    var limitCount = objectLimiter.getLimitCount();
10749
10750                    Collection<ItemDescription> limitedEntities;
10751                    if(itemDescriptionTypeUseTypeName != null) {
10752                        // A Limit must be manually applied.
10753                        limitedEntities = entities.stream()
10754                                .skip(limitOffset)
10755                                .limit(limitCount)
10756                                .toList();
10757                    } else {
10758                        // A Limit was applied in the SQL Query.
10759                        limitedEntities = entities;
10760                    }
10761
10762                    var itemDescriptions = limitedEntities.stream()
10763                            .skip(limitOffset)
10764                            .limit(limitCount)
10765                            .map(ItemDescriptionObject::new)
10766                            .collect(Collectors.toCollection(() -> new ArrayList<>(limitedEntities.size())));
10767
10768                    data = new CountedObjects<>(objectLimiter, itemDescriptions);
10769                }
10770            }
10771        } catch (NamingException ex) {
10772            throw new RuntimeException(ex);
10773        }
10774
10775        return data;
10776    }
10777
10778    @GraphQLField
10779    @GraphQLName("itemType")
10780    static ItemTypeObject itemType(final DataFetchingEnvironment env,
10781            @GraphQLName("itemTypeName") final String itemTypeName,
10782            @GraphQLName("id") @GraphQLID final String id) {
10783        ItemType itemType;
10784
10785        try {
10786            var commandForm = ItemUtil.getHome().getGetItemTypeForm();
10787
10788            commandForm.setItemTypeName(itemTypeName);
10789            commandForm.setUuid(id);
10790
10791            itemType = CDI.current().select(GetItemTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
10792        } catch (NamingException ex) {
10793            throw new RuntimeException(ex);
10794        }
10795
10796        return itemType == null ? null : new ItemTypeObject(itemType);
10797    }
10798
10799    @GraphQLField
10800    @GraphQLName("itemTypes")
10801    @GraphQLNonNull
10802    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
10803    static CountingPaginatedData<ItemTypeObject> itemTypes(final DataFetchingEnvironment env) {
10804        CountingPaginatedData<ItemTypeObject> data;
10805
10806        try {
10807            var commandForm = ItemUtil.getHome().getGetItemTypesForm();
10808            var command = CDI.current().select(GetItemTypesCommand.class).get();
10809
10810            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10811            if(totalEntities == null) {
10812                data = Connections.emptyConnection();
10813            } else {
10814                try(var objectLimiter = new ObjectLimiter(env, ItemTypeConstants.COMPONENT_VENDOR_NAME, ItemTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
10815                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10816
10817                    var itemTypes = entities.stream()
10818                            .map(ItemTypeObject::new)
10819                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
10820
10821                    data = new CountedObjects<>(objectLimiter, itemTypes);
10822                }
10823            }
10824        } catch (NamingException ex) {
10825            throw new RuntimeException(ex);
10826        }
10827
10828        return data;
10829    }
10830
10831    @GraphQLField
10832    @GraphQLName("itemUseType")
10833    static ItemUseTypeObject itemUseType(final DataFetchingEnvironment env,
10834            @GraphQLName("itemUseTypeName") final String itemUseTypeName,
10835            @GraphQLName("id") @GraphQLID final String id) {
10836        ItemUseType itemUseType;
10837
10838        try {
10839            var commandForm = ItemUtil.getHome().getGetItemUseTypeForm();
10840
10841            commandForm.setItemUseTypeName(itemUseTypeName);
10842            commandForm.setUuid(id);
10843
10844            itemUseType = CDI.current().select(GetItemUseTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
10845        } catch (NamingException ex) {
10846            throw new RuntimeException(ex);
10847        }
10848
10849        return itemUseType == null ? null : new ItemUseTypeObject(itemUseType);
10850    }
10851
10852    @GraphQLField
10853    @GraphQLName("itemUseTypes")
10854    @GraphQLNonNull
10855    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
10856    static CountingPaginatedData<ItemUseTypeObject> itemUseTypes(final DataFetchingEnvironment env) {
10857        CountingPaginatedData<ItemUseTypeObject> data;
10858
10859        try {
10860            var commandForm = ItemUtil.getHome().getGetItemUseTypesForm();
10861            var command = CDI.current().select(GetItemUseTypesCommand.class).get();
10862
10863            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10864            if(totalEntities == null) {
10865                data = Connections.emptyConnection();
10866            } else {
10867                try(var objectLimiter = new ObjectLimiter(env, ItemUseTypeConstants.COMPONENT_VENDOR_NAME, ItemUseTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
10868                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10869
10870                    var itemUseTypes = entities.stream()
10871                            .map(ItemUseTypeObject::new)
10872                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
10873
10874                    data = new CountedObjects<>(objectLimiter, itemUseTypes);
10875                }
10876            }
10877        } catch (NamingException ex) {
10878            throw new RuntimeException(ex);
10879        }
10880
10881        return data;
10882    }
10883
10884    @GraphQLField
10885    @GraphQLName("itemPriceType")
10886    static ItemPriceTypeObject itemPriceType(final DataFetchingEnvironment env,
10887            @GraphQLName("itemPriceTypeName") final String itemPriceTypeName,
10888            @GraphQLName("id") @GraphQLID final String id) {
10889        ItemPriceType itemPriceType;
10890
10891        try {
10892            var commandForm = ItemUtil.getHome().getGetItemPriceTypeForm();
10893
10894            commandForm.setItemPriceTypeName(itemPriceTypeName);
10895            commandForm.setUuid(id);
10896
10897            itemPriceType = CDI.current().select(GetItemPriceTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
10898        } catch (NamingException ex) {
10899            throw new RuntimeException(ex);
10900        }
10901
10902        return itemPriceType == null ? null : new ItemPriceTypeObject(itemPriceType);
10903    }
10904
10905    @GraphQLField
10906    @GraphQLName("itemPriceTypes")
10907    @GraphQLNonNull
10908    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
10909    static CountingPaginatedData<ItemPriceTypeObject> itemPriceTypes(final DataFetchingEnvironment env) {
10910        CountingPaginatedData<ItemPriceTypeObject> data;
10911
10912        try {
10913            var commandForm = ItemUtil.getHome().getGetItemPriceTypesForm();
10914            var command = CDI.current().select(GetItemPriceTypesCommand.class).get();
10915
10916            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10917            if(totalEntities == null) {
10918                data = Connections.emptyConnection();
10919            } else {
10920                try(var objectLimiter = new ObjectLimiter(env, ItemPriceTypeConstants.COMPONENT_VENDOR_NAME, ItemPriceTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
10921                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10922
10923                    var itemPriceTypes = entities.stream()
10924                            .map(ItemPriceTypeObject::new)
10925                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
10926
10927                    data = new CountedObjects<>(objectLimiter, itemPriceTypes);
10928                }
10929            }
10930        } catch (NamingException ex) {
10931            throw new RuntimeException(ex);
10932        }
10933
10934        return data;
10935    }
10936
10937    @GraphQLField
10938    @GraphQLName("itemDeliveryType")
10939    static ItemDeliveryTypeObject itemDeliveryType(final DataFetchingEnvironment env,
10940            @GraphQLName("itemDeliveryTypeName") final String itemDeliveryTypeName,
10941            @GraphQLName("id") @GraphQLID final String id) {
10942        ItemDeliveryType itemDeliveryType;
10943
10944        try {
10945            var commandForm = ItemUtil.getHome().getGetItemDeliveryTypeForm();
10946
10947            commandForm.setItemDeliveryTypeName(itemDeliveryTypeName);
10948            commandForm.setUuid(id);
10949
10950            itemDeliveryType = CDI.current().select(GetItemDeliveryTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
10951        } catch (NamingException ex) {
10952            throw new RuntimeException(ex);
10953        }
10954
10955        return itemDeliveryType == null ? null : new ItemDeliveryTypeObject(itemDeliveryType);
10956    }
10957
10958    @GraphQLField
10959    @GraphQLName("itemDeliveryTypes")
10960    @GraphQLNonNull
10961    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
10962    static CountingPaginatedData<ItemDeliveryTypeObject> itemDeliveryTypes(final DataFetchingEnvironment env) {
10963        CountingPaginatedData<ItemDeliveryTypeObject> data;
10964
10965        try {
10966            var commandForm = ItemUtil.getHome().getGetItemDeliveryTypesForm();
10967            var command = CDI.current().select(GetItemDeliveryTypesCommand.class).get();
10968
10969            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10970            if(totalEntities == null) {
10971                data = Connections.emptyConnection();
10972            } else {
10973                try(var objectLimiter = new ObjectLimiter(env, ItemDeliveryTypeConstants.COMPONENT_VENDOR_NAME, ItemDeliveryTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
10974                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
10975
10976                    var itemDeliveryTypes = entities.stream()
10977                            .map(ItemDeliveryTypeObject::new)
10978                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
10979
10980                    data = new CountedObjects<>(objectLimiter, itemDeliveryTypes);
10981                }
10982            }
10983        } catch (NamingException ex) {
10984            throw new RuntimeException(ex);
10985        }
10986
10987        return data;
10988    }
10989
10990    @GraphQLField
10991    @GraphQLName("itemInventoryType")
10992    static ItemInventoryTypeObject itemInventoryType(final DataFetchingEnvironment env,
10993            @GraphQLName("itemInventoryTypeName") final String itemInventoryTypeName,
10994            @GraphQLName("id") @GraphQLID final String id) {
10995        ItemInventoryType itemInventoryType;
10996
10997        try {
10998            var commandForm = ItemUtil.getHome().getGetItemInventoryTypeForm();
10999
11000            commandForm.setItemInventoryTypeName(itemInventoryTypeName);
11001            commandForm.setUuid(id);
11002
11003            itemInventoryType = CDI.current().select(GetItemInventoryTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11004        } catch (NamingException ex) {
11005            throw new RuntimeException(ex);
11006        }
11007
11008        return itemInventoryType == null ? null : new ItemInventoryTypeObject(itemInventoryType);
11009    }
11010
11011    @GraphQLField
11012    @GraphQLName("itemInventoryTypes")
11013    @GraphQLNonNull
11014    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11015    static CountingPaginatedData<ItemInventoryTypeObject> itemInventoryTypes(final DataFetchingEnvironment env) {
11016        CountingPaginatedData<ItemInventoryTypeObject> data;
11017
11018        try {
11019            var commandForm = ItemUtil.getHome().getGetItemInventoryTypesForm();
11020            var command = CDI.current().select(GetItemInventoryTypesCommand.class).get();
11021
11022            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11023            if(totalEntities == null) {
11024                data = Connections.emptyConnection();
11025            } else {
11026                try(var objectLimiter = new ObjectLimiter(env, ItemInventoryTypeConstants.COMPONENT_VENDOR_NAME, ItemInventoryTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
11027                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11028
11029                    var itemInventoryTypes = entities.stream()
11030                            .map(ItemInventoryTypeObject::new)
11031                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11032
11033                    data = new CountedObjects<>(objectLimiter, itemInventoryTypes);
11034                }
11035            }
11036        } catch (NamingException ex) {
11037            throw new RuntimeException(ex);
11038        }
11039
11040        return data;
11041    }
11042
11043    @GraphQLField
11044    @GraphQLName("itemPrice")
11045    static ItemPriceObject itemPrice(final DataFetchingEnvironment env,
11046            @GraphQLName("itemName") @GraphQLNonNull final String itemName,
11047            @GraphQLName("inventoryConditionName") @GraphQLNonNull final String inventoryConditionName,
11048            @GraphQLName("unitOfMeasureTypeName") @GraphQLNonNull final String unitOfMeasureTypeName,
11049            @GraphQLName("currencyIsoName") @GraphQLNonNull final String currencyIsoName) {
11050        ItemPrice itemPrice;
11051
11052        try {
11053            var commandForm = ItemUtil.getHome().getGetItemPriceForm();
11054
11055            commandForm.setItemName(itemName);
11056            commandForm.setInventoryConditionName(inventoryConditionName);
11057            commandForm.setUnitOfMeasureTypeName(unitOfMeasureTypeName);
11058            commandForm.setCurrencyIsoName(currencyIsoName);
11059
11060            itemPrice = CDI.current().select(GetItemPriceCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11061        } catch (NamingException ex) {
11062            throw new RuntimeException(ex);
11063        }
11064
11065        return itemPrice == null ? null : new ItemPriceObject(itemPrice);
11066    }
11067
11068    @GraphQLField
11069    @GraphQLName("itemPrices")
11070    @GraphQLNonNull
11071    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11072    static CountingPaginatedData<ItemPriceObject> itemPrices(final DataFetchingEnvironment env,
11073            @GraphQLName("itemName") @GraphQLNonNull final String itemName) {
11074        CountingPaginatedData<ItemPriceObject> data;
11075
11076        try {
11077            var commandForm = ItemUtil.getHome().getGetItemPricesForm();
11078            var command = CDI.current().select(GetItemPricesCommand.class).get();
11079
11080            commandForm.setItemName(itemName);
11081
11082            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11083            if(totalEntities == null) {
11084                data = Connections.emptyConnection();
11085            } else {
11086                try(var objectLimiter = new ObjectLimiter(env, ItemPriceConstants.COMPONENT_VENDOR_NAME, ItemPriceConstants.ENTITY_TYPE_NAME, totalEntities)) {
11087                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11088
11089                    var itemPriceObjects = entities.stream()
11090                            .map(ItemPriceObject::new)
11091                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11092
11093                    data = new CountedObjects<>(objectLimiter, itemPriceObjects);
11094                }
11095            }
11096        } catch (NamingException ex) {
11097            throw new RuntimeException(ex);
11098        }
11099
11100        return data;
11101    }
11102
11103    @GraphQLField
11104    @GraphQLName("itemAliasChecksumType")
11105    static ItemAliasChecksumTypeObject itemAliasChecksumType(final DataFetchingEnvironment env,
11106            @GraphQLName("itemAliasChecksumTypeName") final String itemAliasChecksumTypeName,
11107            @GraphQLName("id") @GraphQLID final String id) {
11108        ItemAliasChecksumType itemAliasChecksumType;
11109
11110        try {
11111            var commandForm = ItemUtil.getHome().getGetItemAliasChecksumTypeForm();
11112
11113            commandForm.setItemAliasChecksumTypeName(itemAliasChecksumTypeName);
11114            commandForm.setUuid(id);
11115
11116            itemAliasChecksumType = CDI.current().select(GetItemAliasChecksumTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11117        } catch (NamingException ex) {
11118            throw new RuntimeException(ex);
11119        }
11120
11121        return itemAliasChecksumType == null ? null : new ItemAliasChecksumTypeObject(itemAliasChecksumType);
11122    }
11123
11124    @GraphQLField
11125    @GraphQLName("itemAliasChecksumTypes")
11126    @GraphQLNonNull
11127    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11128    static CountingPaginatedData<ItemAliasChecksumTypeObject> itemAliasChecksumTypes(final DataFetchingEnvironment env) {
11129        CountingPaginatedData<ItemAliasChecksumTypeObject> data;
11130
11131        try {
11132            var commandForm = ItemUtil.getHome().getGetItemAliasChecksumTypesForm();
11133            var command = CDI.current().select(GetItemAliasChecksumTypesCommand.class).get();
11134
11135            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11136            if(totalEntities == null) {
11137                data = Connections.emptyConnection();
11138            } else {
11139                try(var objectLimiter = new ObjectLimiter(env, ItemAliasChecksumTypeConstants.COMPONENT_VENDOR_NAME, ItemAliasChecksumTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
11140                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11141
11142                    var itemAliasChecksumTypes = entities.stream()
11143                            .map(ItemAliasChecksumTypeObject::new)
11144                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11145
11146                    data = new CountedObjects<>(objectLimiter, itemAliasChecksumTypes);
11147                }
11148            }
11149        } catch (NamingException ex) {
11150            throw new RuntimeException(ex);
11151        }
11152
11153        return data;
11154    }
11155
11156    @GraphQLField
11157    @GraphQLName("itemAlias")
11158    static ItemAliasObject itemAlias(final DataFetchingEnvironment env,
11159            @GraphQLName("alias") @GraphQLNonNull final String alias) {
11160        ItemAlias itemAlias;
11161
11162        try {
11163            var commandForm = ItemUtil.getHome().getGetItemAliasForm();
11164
11165            commandForm.setAlias(alias);
11166
11167            itemAlias = CDI.current().select(GetItemAliasCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11168        } catch (NamingException ex) {
11169            throw new RuntimeException(ex);
11170        }
11171
11172        return itemAlias == null ? null : new ItemAliasObject(itemAlias);
11173    }
11174
11175    @GraphQLField
11176    @GraphQLName("itemAliases")
11177    @GraphQLNonNull
11178    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11179    static CountingPaginatedData<ItemAliasObject> itemAliases(final DataFetchingEnvironment env,
11180            @GraphQLName("itemName") @GraphQLNonNull final String itemName) {
11181        CountingPaginatedData<ItemAliasObject> data;
11182
11183        try {
11184            var commandForm = ItemUtil.getHome().getGetItemAliasesForm();
11185            var command = CDI.current().select(GetItemAliasesCommand.class).get();
11186
11187            commandForm.setItemName(itemName);
11188
11189            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11190            if(totalEntities == null) {
11191                data = Connections.emptyConnection();
11192            } else {
11193                try(var objectLimiter = new ObjectLimiter(env, ItemAliasConstants.COMPONENT_VENDOR_NAME, ItemAliasConstants.ENTITY_TYPE_NAME, totalEntities)) {
11194                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11195
11196                    var itemAliasObjects = entities.stream()
11197                            .map(ItemAliasObject::new)
11198                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11199
11200                    data = new CountedObjects<>(objectLimiter, itemAliasObjects);
11201                }
11202            }
11203        } catch (NamingException ex) {
11204            throw new RuntimeException(ex);
11205        }
11206
11207        return data;
11208    }
11209
11210    @GraphQLField
11211    @GraphQLName("itemCategory")
11212    static ItemCategoryObject itemCategory(final DataFetchingEnvironment env,
11213            @GraphQLName("itemCategoryName") final String itemCategoryName,
11214            @GraphQLName("id") @GraphQLID final String id) {
11215        ItemCategory itemCategory;
11216
11217        try {
11218            var commandForm = ItemUtil.getHome().getGetItemCategoryForm();
11219
11220            commandForm.setItemCategoryName(itemCategoryName);
11221            commandForm.setUuid(id);
11222
11223            itemCategory = CDI.current().select(GetItemCategoryCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11224        } catch (NamingException ex) {
11225            throw new RuntimeException(ex);
11226        }
11227
11228        return itemCategory == null ? null : new ItemCategoryObject(itemCategory);
11229    }
11230
11231    @GraphQLField
11232    @GraphQLName("itemCategories")
11233    @GraphQLNonNull
11234    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11235    static CountingPaginatedData<ItemCategoryObject> itemCategories(final DataFetchingEnvironment env,
11236            @GraphQLName("parentItemCategoryName") final String parentItemCategoryName) {
11237        CountingPaginatedData<ItemCategoryObject> data;
11238
11239        try {
11240            var commandForm = ItemUtil.getHome().getGetItemCategoriesForm();
11241            var command = CDI.current().select(GetItemCategoriesCommand.class).get();
11242
11243            commandForm.setParentItemCategoryName(parentItemCategoryName);
11244
11245            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11246            if(totalEntities == null) {
11247                data = Connections.emptyConnection();
11248            } else {
11249                try(var objectLimiter = new ObjectLimiter(env, ItemCategoryConstants.COMPONENT_VENDOR_NAME, ItemCategoryConstants.ENTITY_TYPE_NAME, totalEntities)) {
11250                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11251
11252                    var itemCategories = entities.stream()
11253                            .map(ItemCategoryObject::new)
11254                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11255
11256                    data = new CountedObjects<>(objectLimiter, itemCategories);
11257                }
11258            }
11259        } catch (NamingException ex) {
11260            throw new RuntimeException(ex);
11261        }
11262
11263        return data;
11264    }
11265
11266    @GraphQLField
11267    @GraphQLName("itemAccountingCategory")
11268    static ItemAccountingCategoryObject itemAccountingCategory(final DataFetchingEnvironment env,
11269            @GraphQLName("itemAccountingCategoryName") final String itemAccountingCategoryName,
11270            @GraphQLName("id") @GraphQLID final String id) {
11271        ItemAccountingCategory itemAccountingCategory;
11272
11273        try {
11274            var commandForm = AccountingUtil.getHome().getGetItemAccountingCategoryForm();
11275
11276            commandForm.setItemAccountingCategoryName(itemAccountingCategoryName);
11277            commandForm.setUuid(id);
11278
11279            itemAccountingCategory = CDI.current().select(GetItemAccountingCategoryCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11280        } catch (NamingException ex) {
11281            throw new RuntimeException(ex);
11282        }
11283
11284        return itemAccountingCategory == null ? null : new ItemAccountingCategoryObject(itemAccountingCategory);
11285    }
11286
11287    @GraphQLField
11288    @GraphQLName("itemAccountingCategories")
11289    @GraphQLNonNull
11290    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11291    static CountingPaginatedData<ItemAccountingCategoryObject> itemAccountingCategories(final DataFetchingEnvironment env) {
11292        CountingPaginatedData<ItemAccountingCategoryObject> data;
11293
11294        try {
11295            var commandForm = AccountingUtil.getHome().getGetItemAccountingCategoriesForm();
11296            var command = CDI.current().select(GetItemAccountingCategoriesCommand.class).get();
11297
11298            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11299            if(totalEntities == null) {
11300                data = Connections.emptyConnection();
11301            } else {
11302                try(var objectLimiter = new ObjectLimiter(env, ItemAccountingCategoryConstants.COMPONENT_VENDOR_NAME, ItemAccountingCategoryConstants.ENTITY_TYPE_NAME, totalEntities)) {
11303                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11304
11305                    var itemAccountingCategories = entities.stream()
11306                            .map(ItemAccountingCategoryObject::new)
11307                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11308
11309                    data = new CountedObjects<>(objectLimiter, itemAccountingCategories);
11310                }
11311            }
11312        } catch (NamingException ex) {
11313            throw new RuntimeException(ex);
11314        }
11315
11316        return data;
11317    }
11318
11319    @GraphQLField
11320    @GraphQLName("glAccount")
11321    static GlAccountObject glAccount(final DataFetchingEnvironment env,
11322            @GraphQLName("glAccountName") final String glAccountName,
11323            @GraphQLName("id") @GraphQLID final String id) {
11324        GlAccount glAccount;
11325
11326        try {
11327            var commandForm = AccountingUtil.getHome().getGetGlAccountForm();
11328
11329            commandForm.setGlAccountName(glAccountName);
11330            commandForm.setUuid(id);
11331
11332            glAccount = CDI.current().select(GetGlAccountCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11333        } catch (NamingException ex) {
11334            throw new RuntimeException(ex);
11335        }
11336
11337        return glAccount == null ? null : new GlAccountObject(glAccount);
11338    }
11339
11340    @GraphQLField
11341    @GraphQLName("glAccounts")
11342    @GraphQLNonNull
11343    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11344    static CountingPaginatedData<GlAccountObject> glAccounts(final DataFetchingEnvironment env,
11345            @GraphQLName("glAccountCategoryName") final String glAccountCategoryName) {
11346        CountingPaginatedData<GlAccountObject> data;
11347
11348        try {
11349            var commandForm = AccountingUtil.getHome().getGetGlAccountsForm();
11350            var command = CDI.current().select(GetGlAccountsCommand.class).get();
11351
11352            commandForm.setGlAccountCategoryName(glAccountCategoryName);
11353
11354            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11355            if(totalEntities == null) {
11356                data = Connections.emptyConnection();
11357            } else {
11358                try(var objectLimiter = new ObjectLimiter(env, GlAccountConstants.COMPONENT_VENDOR_NAME, GlAccountConstants.ENTITY_TYPE_NAME, totalEntities)) {
11359                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11360
11361                    var glAccounts = entities.stream()
11362                            .map(GlAccountObject::new)
11363                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11364
11365                    data = new CountedObjects<>(objectLimiter, glAccounts);
11366                }
11367            }
11368        } catch (NamingException ex) {
11369            throw new RuntimeException(ex);
11370        }
11371
11372        return data;
11373    }
11374
11375    @GraphQLField
11376    @GraphQLName("glAccountType")
11377    static GlAccountTypeObject glAccountType(final DataFetchingEnvironment env,
11378            @GraphQLName("glAccountTypeName") final String glAccountTypeName,
11379            @GraphQLName("id") @GraphQLID final String id) {
11380        GlAccountType glAccountType;
11381
11382        try {
11383            var commandForm = AccountingUtil.getHome().getGetGlAccountTypeForm();
11384
11385            commandForm.setGlAccountTypeName(glAccountTypeName);
11386            commandForm.setUuid(id);
11387
11388            glAccountType = CDI.current().select(GetGlAccountTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11389        } catch (NamingException ex) {
11390            throw new RuntimeException(ex);
11391        }
11392
11393        return glAccountType == null ? null : new GlAccountTypeObject(glAccountType);
11394    }
11395
11396    @GraphQLField
11397    @GraphQLName("glAccountTypes")
11398    @GraphQLNonNull
11399    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11400    static CountingPaginatedData<GlAccountTypeObject> glAccountTypes(final DataFetchingEnvironment env) {
11401        CountingPaginatedData<GlAccountTypeObject> data;
11402
11403        try {
11404            var commandForm = AccountingUtil.getHome().getGetGlAccountTypesForm();
11405            var command = CDI.current().select(GetGlAccountTypesCommand.class).get();
11406
11407            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11408            if(totalEntities == null) {
11409                data = Connections.emptyConnection();
11410            } else {
11411                try(var objectLimiter = new ObjectLimiter(env, GlAccountTypeConstants.COMPONENT_VENDOR_NAME, GlAccountTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
11412                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11413
11414                    var glAccountTypes = entities.stream()
11415                            .map(GlAccountTypeObject::new)
11416                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11417
11418                    data = new CountedObjects<>(objectLimiter, glAccountTypes);
11419                }
11420            }
11421        } catch (NamingException ex) {
11422            throw new RuntimeException(ex);
11423        }
11424
11425        return data;
11426    }
11427
11428    @GraphQLField
11429    @GraphQLName("glAccountClass")
11430    static GlAccountClassObject glAccountClass(final DataFetchingEnvironment env,
11431            @GraphQLName("glAccountClassName") final String glAccountClassName,
11432            @GraphQLName("id") @GraphQLID final String id) {
11433        GlAccountClass glAccountClass;
11434
11435        try {
11436            var commandForm = AccountingUtil.getHome().getGetGlAccountClassForm();
11437
11438            commandForm.setGlAccountClassName(glAccountClassName);
11439            commandForm.setUuid(id);
11440
11441            glAccountClass = CDI.current().select(GetGlAccountClassCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11442        } catch (NamingException ex) {
11443            throw new RuntimeException(ex);
11444        }
11445
11446        return glAccountClass == null ? null : new GlAccountClassObject(glAccountClass);
11447    }
11448
11449    @GraphQLField
11450    @GraphQLName("glAccountClasses")
11451    @GraphQLNonNull
11452    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11453    static CountingPaginatedData<GlAccountClassObject> glAccountClasses(final DataFetchingEnvironment env) {
11454        CountingPaginatedData<GlAccountClassObject> data;
11455
11456        try {
11457            var commandForm = AccountingUtil.getHome().getGetGlAccountClassesForm();
11458            var command = CDI.current().select(GetGlAccountClassesCommand.class).get();
11459
11460            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11461            if(totalEntities == null) {
11462                data = Connections.emptyConnection();
11463            } else {
11464                try(var objectLimiter = new ObjectLimiter(env, GlAccountClassConstants.COMPONENT_VENDOR_NAME, GlAccountClassConstants.ENTITY_TYPE_NAME, totalEntities)) {
11465                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11466
11467                    var glAccountClasses = entities.stream()
11468                            .map(GlAccountClassObject::new)
11469                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11470
11471                    data = new CountedObjects<>(objectLimiter, glAccountClasses);
11472                }
11473            }
11474        } catch (NamingException ex) {
11475            throw new RuntimeException(ex);
11476        }
11477
11478        return data;
11479    }
11480
11481    @GraphQLField
11482    @GraphQLName("glAccountCategory")
11483    static GlAccountCategoryObject glAccountCategory(final DataFetchingEnvironment env,
11484            @GraphQLName("glAccountCategoryName") final String glAccountCategoryName,
11485            @GraphQLName("id") @GraphQLID final String id) {
11486        GlAccountCategory glAccountCategory;
11487
11488        try {
11489            var commandForm = AccountingUtil.getHome().getGetGlAccountCategoryForm();
11490
11491            commandForm.setGlAccountCategoryName(glAccountCategoryName);
11492            commandForm.setUuid(id);
11493
11494            glAccountCategory = CDI.current().select(GetGlAccountCategoryCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11495        } catch (NamingException ex) {
11496            throw new RuntimeException(ex);
11497        }
11498
11499        return glAccountCategory == null ? null : new GlAccountCategoryObject(glAccountCategory);
11500    }
11501
11502    @GraphQLField
11503    @GraphQLName("glAccountCategories")
11504    @GraphQLNonNull
11505    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11506    static CountingPaginatedData<GlAccountCategoryObject> glAccountCategories(final DataFetchingEnvironment env) {
11507        CountingPaginatedData<GlAccountCategoryObject> data;
11508
11509        try {
11510            var commandForm = AccountingUtil.getHome().getGetGlAccountCategoriesForm();
11511            var command = CDI.current().select(GetGlAccountCategoriesCommand.class).get();
11512
11513            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11514            if(totalEntities == null) {
11515                data = Connections.emptyConnection();
11516            } else {
11517                try(var objectLimiter = new ObjectLimiter(env, GlAccountCategoryConstants.COMPONENT_VENDOR_NAME, GlAccountCategoryConstants.ENTITY_TYPE_NAME, totalEntities)) {
11518                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11519
11520                    var glAccountCategories = entities.stream()
11521                            .map(GlAccountCategoryObject::new)
11522                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11523
11524                    data = new CountedObjects<>(objectLimiter, glAccountCategories);
11525                }
11526            }
11527        } catch (NamingException ex) {
11528            throw new RuntimeException(ex);
11529        }
11530
11531        return data;
11532    }
11533
11534    @GraphQLField
11535    @GraphQLName("glResourceType")
11536    static GlResourceTypeObject glResourceType(final DataFetchingEnvironment env,
11537            @GraphQLName("glResourceTypeName") final String glResourceTypeName,
11538            @GraphQLName("id") @GraphQLID final String id) {
11539        GlResourceType glResourceType;
11540
11541        try {
11542            var commandForm = AccountingUtil.getHome().getGetGlResourceTypeForm();
11543
11544            commandForm.setGlResourceTypeName(glResourceTypeName);
11545            commandForm.setUuid(id);
11546
11547            glResourceType = CDI.current().select(GetGlResourceTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11548        } catch (NamingException ex) {
11549            throw new RuntimeException(ex);
11550        }
11551
11552        return glResourceType == null ? null : new GlResourceTypeObject(glResourceType);
11553    }
11554
11555    @GraphQLField
11556    @GraphQLName("glResourceTypes")
11557    @GraphQLNonNull
11558    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11559    static CountingPaginatedData<GlResourceTypeObject> glResourceTypes(final DataFetchingEnvironment env) {
11560        CountingPaginatedData<GlResourceTypeObject> data;
11561
11562        try {
11563            var commandForm = AccountingUtil.getHome().getGetGlResourceTypesForm();
11564            var command = CDI.current().select(GetGlResourceTypesCommand.class).get();
11565
11566            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11567            if(totalEntities == null) {
11568                data = Connections.emptyConnection();
11569            } else {
11570                try(var objectLimiter = new ObjectLimiter(env, GlResourceTypeConstants.COMPONENT_VENDOR_NAME, GlResourceTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
11571                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11572
11573                    var glResourceTypes = entities.stream()
11574                            .map(GlResourceTypeObject::new)
11575                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11576
11577                    data = new CountedObjects<>(objectLimiter, glResourceTypes);
11578                }
11579            }
11580        } catch (NamingException ex) {
11581            throw new RuntimeException(ex);
11582        }
11583
11584        return data;
11585    }
11586
11587    @GraphQLField
11588    @GraphQLName("itemPurchasingCategory")
11589    static ItemPurchasingCategoryObject itemPurchasingCategory(final DataFetchingEnvironment env,
11590            @GraphQLName("itemPurchasingCategoryName") final String itemPurchasingCategoryName,
11591            @GraphQLName("id") @GraphQLID final String id) {
11592        ItemPurchasingCategory itemPurchasingCategory;
11593
11594        try {
11595            var commandForm = VendorUtil.getHome().getGetItemPurchasingCategoryForm();
11596
11597            commandForm.setItemPurchasingCategoryName(itemPurchasingCategoryName);
11598            commandForm.setUuid(id);
11599
11600            itemPurchasingCategory = CDI.current().select(GetItemPurchasingCategoryCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11601        } catch (NamingException ex) {
11602            throw new RuntimeException(ex);
11603        }
11604
11605        return itemPurchasingCategory == null ? null : new ItemPurchasingCategoryObject(itemPurchasingCategory);
11606    }
11607
11608    @GraphQLField
11609    @GraphQLName("itemPurchasingCategories")
11610    @GraphQLNonNull
11611    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11612    static CountingPaginatedData<ItemPurchasingCategoryObject> itemPurchasingCategories(final DataFetchingEnvironment env) {
11613        CountingPaginatedData<ItemPurchasingCategoryObject> data;
11614
11615        try {
11616            var commandForm = VendorUtil.getHome().getGetItemPurchasingCategoriesForm();
11617            var command = CDI.current().select(GetItemPurchasingCategoriesCommand.class).get();
11618
11619            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11620            if(totalEntities == null) {
11621                data = Connections.emptyConnection();
11622            } else {
11623                try(var objectLimiter = new ObjectLimiter(env, ItemPurchasingCategoryConstants.COMPONENT_VENDOR_NAME, ItemPurchasingCategoryConstants.ENTITY_TYPE_NAME, totalEntities)) {
11624                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11625
11626                    var itemPurchasingCategories = entities.stream()
11627                            .map(ItemPurchasingCategoryObject::new)
11628                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11629
11630                    data = new CountedObjects<>(objectLimiter, itemPurchasingCategories);
11631                }
11632            }
11633        } catch (NamingException ex) {
11634            throw new RuntimeException(ex);
11635        }
11636
11637        return data;
11638    }
11639
11640    @GraphQLField
11641    @GraphQLName("itemDescriptionType")
11642    static ItemDescriptionTypeObject itemDescriptionType(final DataFetchingEnvironment env,
11643            @GraphQLName("itemDescriptionTypeName") final String itemDescriptionTypeName,
11644            @GraphQLName("id") @GraphQLID final String id) {
11645        ItemDescriptionType itemDescriptionType;
11646
11647        try {
11648            var commandForm = ItemUtil.getHome().getGetItemDescriptionTypeForm();
11649
11650            commandForm.setItemDescriptionTypeName(itemDescriptionTypeName);
11651            commandForm.setUuid(id);
11652
11653            itemDescriptionType = CDI.current().select(GetItemDescriptionTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11654        } catch (NamingException ex) {
11655            throw new RuntimeException(ex);
11656        }
11657
11658        return itemDescriptionType == null ? null : new ItemDescriptionTypeObject(itemDescriptionType);
11659    }
11660
11661    @GraphQLField
11662    @GraphQLName("itemDescriptionTypes")
11663    @GraphQLNonNull
11664    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11665    static CountingPaginatedData<ItemDescriptionTypeObject> itemDescriptionTypes(final DataFetchingEnvironment env,
11666            @GraphQLName("parentItemDescriptionTypeName") final String parentItemDescriptionTypeName) {
11667        CountingPaginatedData<ItemDescriptionTypeObject> data;
11668
11669        try {
11670            var commandForm = ItemUtil.getHome().getGetItemDescriptionTypesForm();
11671            var command = CDI.current().select(GetItemDescriptionTypesCommand.class).get();
11672
11673            commandForm.setParentItemDescriptionTypeName(parentItemDescriptionTypeName);
11674
11675            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11676            if(totalEntities == null) {
11677                data = Connections.emptyConnection();
11678            } else {
11679                try(var objectLimiter = new ObjectLimiter(env, ItemDescriptionTypeConstants.COMPONENT_VENDOR_NAME, ItemDescriptionTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
11680                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11681
11682                    var itemDescriptionTypes = entities.stream()
11683                            .map(ItemDescriptionTypeObject::new)
11684                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11685
11686                    data = new CountedObjects<>(objectLimiter, itemDescriptionTypes);
11687                }
11688            }
11689        } catch (NamingException ex) {
11690            throw new RuntimeException(ex);
11691        }
11692
11693        return data;
11694    }
11695
11696    @GraphQLField
11697    @GraphQLName("itemImageType")
11698    static ItemImageTypeObject itemImageType(final DataFetchingEnvironment env,
11699            @GraphQLName("itemImageTypeName") final String itemImageTypeName,
11700            @GraphQLName("id") @GraphQLID final String id) {
11701        ItemImageType itemImageType;
11702
11703        try {
11704            var commandForm = ItemUtil.getHome().getGetItemImageTypeForm();
11705
11706            commandForm.setItemImageTypeName(itemImageTypeName);
11707            commandForm.setUuid(id);
11708
11709            itemImageType = CDI.current().select(GetItemImageTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11710        } catch (NamingException ex) {
11711            throw new RuntimeException(ex);
11712        }
11713
11714        return itemImageType == null ? null : new ItemImageTypeObject(itemImageType);
11715    }
11716
11717    @GraphQLField
11718    @GraphQLName("itemImageTypes")
11719    @GraphQLNonNull
11720    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11721    static CountingPaginatedData<ItemImageTypeObject> itemImageTypes(final DataFetchingEnvironment env) {
11722        CountingPaginatedData<ItemImageTypeObject> data;
11723
11724        try {
11725            var commandForm = ItemUtil.getHome().getGetItemImageTypesForm();
11726            var command = CDI.current().select(GetItemImageTypesCommand.class).get();
11727
11728            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11729            if(totalEntities == null) {
11730                data = Connections.emptyConnection();
11731            } else {
11732                try(var objectLimiter = new ObjectLimiter(env, ItemImageTypeConstants.COMPONENT_VENDOR_NAME, ItemImageTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
11733                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11734
11735                    var itemImageTypes = entities.stream()
11736                            .map(ItemImageTypeObject::new)
11737                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11738
11739                    data = new CountedObjects<>(objectLimiter, itemImageTypes);
11740                }
11741            }
11742        } catch (NamingException ex) {
11743            throw new RuntimeException(ex);
11744        }
11745
11746        return data;
11747    }
11748
11749    @GraphQLField
11750    @GraphQLName("itemDescriptionTypeUseType")
11751    static ItemDescriptionTypeUseTypeObject itemDescriptionTypeUseType(final DataFetchingEnvironment env,
11752            @GraphQLName("itemDescriptionTypeUseTypeName") final String itemDescriptionTypeUseTypeName,
11753            @GraphQLName("id") @GraphQLID final String id) {
11754        ItemDescriptionTypeUseType itemDescriptionTypeUseType;
11755
11756        try {
11757            var commandForm = ItemUtil.getHome().getGetItemDescriptionTypeUseTypeForm();
11758
11759            commandForm.setItemDescriptionTypeUseTypeName(itemDescriptionTypeUseTypeName);
11760            commandForm.setUuid(id);
11761
11762            itemDescriptionTypeUseType = CDI.current().select(GetItemDescriptionTypeUseTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11763        } catch (NamingException ex) {
11764            throw new RuntimeException(ex);
11765        }
11766
11767        return itemDescriptionTypeUseType == null ? null : new ItemDescriptionTypeUseTypeObject(itemDescriptionTypeUseType);
11768    }
11769
11770    @GraphQLField
11771    @GraphQLName("itemDescriptionTypeUseTypes")
11772    @GraphQLNonNull
11773    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11774    static CountingPaginatedData<ItemDescriptionTypeUseTypeObject> itemDescriptionTypeUseTypes(final DataFetchingEnvironment env) {
11775        CountingPaginatedData<ItemDescriptionTypeUseTypeObject> data;
11776
11777        try {
11778            var commandForm = ItemUtil.getHome().getGetItemDescriptionTypeUseTypesForm();
11779            var command = CDI.current().select(GetItemDescriptionTypeUseTypesCommand.class).get();
11780
11781            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11782            if(totalEntities == null) {
11783                data = Connections.emptyConnection();
11784            } else {
11785                try(var objectLimiter = new ObjectLimiter(env, ItemDescriptionTypeUseTypeConstants.COMPONENT_VENDOR_NAME, ItemDescriptionTypeUseTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
11786                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11787
11788                    var itemDescriptionTypeUseTypes = entities.stream()
11789                            .map(ItemDescriptionTypeUseTypeObject::new)
11790                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11791
11792                    data = new CountedObjects<>(objectLimiter, itemDescriptionTypeUseTypes);
11793                }
11794            }
11795        } catch (NamingException ex) {
11796            throw new RuntimeException(ex);
11797        }
11798
11799        return data;
11800    }
11801
11802    @GraphQLField
11803    @GraphQLName("itemDescriptionTypeUse")
11804    static ItemDescriptionTypeUseObject itemDescriptionTypeUse(final DataFetchingEnvironment env,
11805            @GraphQLName("itemDescriptionTypeUseTypeName") @GraphQLNonNull final String itemDescriptionTypeUseTypeName,
11806            @GraphQLName("itemDescriptionTypeName") @GraphQLNonNull final String itemDescriptionTypeName) {
11807        ItemDescriptionTypeUse itemDescriptionTypeUse;
11808
11809        try {
11810            var commandForm = ItemUtil.getHome().getGetItemDescriptionTypeUseForm();
11811
11812            commandForm.setItemDescriptionTypeUseTypeName(itemDescriptionTypeUseTypeName);
11813            commandForm.setItemDescriptionTypeName(itemDescriptionTypeName);
11814
11815            itemDescriptionTypeUse = CDI.current().select(GetItemDescriptionTypeUseCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11816        } catch (NamingException ex) {
11817            throw new RuntimeException(ex);
11818        }
11819
11820        return itemDescriptionTypeUse == null ? null : new ItemDescriptionTypeUseObject(itemDescriptionTypeUse);
11821    }
11822
11823    @GraphQLField
11824    @GraphQLName("itemDescriptionTypeUses")
11825    @GraphQLNonNull
11826    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11827    static CountingPaginatedData<ItemDescriptionTypeUseObject> itemDescriptionTypeUses(final DataFetchingEnvironment env,
11828            @GraphQLName("itemDescriptionTypeUseTypeName") final String itemDescriptionTypeUseTypeName,
11829            @GraphQLName("itemDescriptionTypeName") final String itemDescriptionTypeName) {
11830        CountingPaginatedData<ItemDescriptionTypeUseObject> data;
11831
11832        try {
11833            var commandForm = ItemUtil.getHome().getGetItemDescriptionTypeUsesForm();
11834            var command = CDI.current().select(GetItemDescriptionTypeUsesCommand.class).get();
11835
11836            commandForm.setItemDescriptionTypeUseTypeName(itemDescriptionTypeUseTypeName);
11837            commandForm.setItemDescriptionTypeName(itemDescriptionTypeName);
11838
11839            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11840            if(totalEntities == null) {
11841                data = Connections.emptyConnection();
11842            } else {
11843                try(var objectLimiter = new ObjectLimiter(env, com.echothree.model.data.item.common.ItemDescriptionTypeUseConstants.COMPONENT_VENDOR_NAME, com.echothree.model.data.item.common.ItemDescriptionTypeUseConstants.ENTITY_TYPE_NAME, totalEntities)) {
11844                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11845
11846                    var objects = entities.stream()
11847                            .map(ItemDescriptionTypeUseObject::new)
11848                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11849
11850                    data = new CountedObjects<>(objectLimiter, objects);
11851                }
11852            }
11853        } catch (NamingException ex) {
11854            throw new RuntimeException(ex);
11855        }
11856
11857        return data;
11858    }
11859
11860    @GraphQLField
11861    @GraphQLName("itemAliasType")
11862    static ItemAliasTypeObject itemAliasType(final DataFetchingEnvironment env,
11863            @GraphQLName("itemAliasTypeName") final String itemAliasTypeName,
11864            @GraphQLName("id") @GraphQLID final String id) {
11865        ItemAliasType itemAliasType;
11866
11867        try {
11868            var commandForm = ItemUtil.getHome().getGetItemAliasTypeForm();
11869
11870            commandForm.setItemAliasTypeName(itemAliasTypeName);
11871            commandForm.setUuid(id);
11872
11873            itemAliasType = CDI.current().select(GetItemAliasTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11874        } catch (NamingException ex) {
11875            throw new RuntimeException(ex);
11876        }
11877
11878        return itemAliasType == null ? null : new ItemAliasTypeObject(itemAliasType);
11879    }
11880
11881    @GraphQLField
11882    @GraphQLName("itemAliasTypes")
11883    @GraphQLNonNull
11884    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11885    static CountingPaginatedData<ItemAliasTypeObject> itemAliasTypes(final DataFetchingEnvironment env) {
11886        CountingPaginatedData<ItemAliasTypeObject> data;
11887
11888        try {
11889            var commandForm = ItemUtil.getHome().getGetItemAliasTypesForm();
11890            var command = CDI.current().select(GetItemAliasTypesCommand.class).get();
11891
11892            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11893            if(totalEntities == null) {
11894                data = Connections.emptyConnection();
11895            } else {
11896                try(var objectLimiter = new ObjectLimiter(env, ItemAliasTypeConstants.COMPONENT_VENDOR_NAME, ItemAliasTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
11897                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11898
11899                    var itemAliasTypes = entities.stream()
11900                            .map(ItemAliasTypeObject::new)
11901                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11902
11903                    data = new CountedObjects<>(objectLimiter, itemAliasTypes);
11904                }
11905            }
11906        } catch (NamingException ex) {
11907            throw new RuntimeException(ex);
11908        }
11909
11910        return data;
11911    }
11912
11913    @GraphQLField
11914    @GraphQLName("itemWeightType")
11915    static ItemWeightTypeObject itemWeightType(final DataFetchingEnvironment env,
11916            @GraphQLName("itemWeightTypeName") final String itemWeightTypeName,
11917            @GraphQLName("id") @GraphQLID final String id) {
11918        ItemWeightType itemWeightType;
11919
11920        try {
11921            var commandForm = ItemUtil.getHome().getGetItemWeightTypeForm();
11922
11923            commandForm.setItemWeightTypeName(itemWeightTypeName);
11924            commandForm.setUuid(id);
11925
11926            itemWeightType = CDI.current().select(GetItemWeightTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11927        } catch (NamingException ex) {
11928            throw new RuntimeException(ex);
11929        }
11930
11931        return itemWeightType == null ? null : new ItemWeightTypeObject(itemWeightType);
11932    }
11933
11934    @GraphQLField
11935    @GraphQLName("itemWeightTypes")
11936    @GraphQLNonNull
11937    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11938    static CountingPaginatedData<ItemWeightTypeObject> itemWeightTypes(final DataFetchingEnvironment env) {
11939        CountingPaginatedData<ItemWeightTypeObject> data;
11940
11941        try {
11942            var commandForm = ItemUtil.getHome().getGetItemWeightTypesForm();
11943            var command = CDI.current().select(GetItemWeightTypesCommand.class).get();
11944
11945            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11946            if(totalEntities == null) {
11947                data = Connections.emptyConnection();
11948            } else {
11949                try(var objectLimiter = new ObjectLimiter(env, ItemWeightTypeConstants.COMPONENT_VENDOR_NAME, ItemWeightTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
11950                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11951
11952                    var itemWeightTypes = entities.stream()
11953                            .map(ItemWeightTypeObject::new)
11954                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
11955
11956                    data = new CountedObjects<>(objectLimiter, itemWeightTypes);
11957                }
11958            }
11959        } catch (NamingException ex) {
11960            throw new RuntimeException(ex);
11961        }
11962
11963        return data;
11964    }
11965
11966    @GraphQLField
11967    @GraphQLName("itemVolumeType")
11968    static ItemVolumeTypeObject itemVolumeType(final DataFetchingEnvironment env,
11969            @GraphQLName("itemVolumeTypeName") final String itemVolumeTypeName,
11970            @GraphQLName("id") @GraphQLID final String id) {
11971        ItemVolumeType itemVolumeType;
11972
11973        try {
11974            var commandForm = ItemUtil.getHome().getGetItemVolumeTypeForm();
11975
11976            commandForm.setItemVolumeTypeName(itemVolumeTypeName);
11977            commandForm.setUuid(id);
11978
11979            itemVolumeType = CDI.current().select(GetItemVolumeTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
11980        } catch (NamingException ex) {
11981            throw new RuntimeException(ex);
11982        }
11983
11984        return itemVolumeType == null ? null : new ItemVolumeTypeObject(itemVolumeType);
11985    }
11986
11987    @GraphQLField
11988    @GraphQLName("itemVolumeTypes")
11989    @GraphQLNonNull
11990    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
11991    static CountingPaginatedData<ItemVolumeTypeObject> itemVolumeTypes(final DataFetchingEnvironment env) {
11992        CountingPaginatedData<ItemVolumeTypeObject> data;
11993
11994        try {
11995            var commandForm = ItemUtil.getHome().getGetItemVolumeTypesForm();
11996            var command = CDI.current().select(GetItemVolumeTypesCommand.class).get();
11997
11998            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
11999            if(totalEntities == null) {
12000                data = Connections.emptyConnection();
12001            } else {
12002                try(var objectLimiter = new ObjectLimiter(env, ItemVolumeTypeConstants.COMPONENT_VENDOR_NAME, ItemVolumeTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
12003                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12004
12005                    var itemVolumeTypes = entities.stream()
12006                            .map(ItemVolumeTypeObject::new)
12007                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12008
12009                    data = new CountedObjects<>(objectLimiter, itemVolumeTypes);
12010                }
12011            }
12012        } catch (NamingException ex) {
12013            throw new RuntimeException(ex);
12014        }
12015
12016        return data;
12017    }
12018
12019    @GraphQLField
12020    @GraphQLName("relatedItemType")
12021    static RelatedItemTypeObject relatedItemType(final DataFetchingEnvironment env,
12022            @GraphQLName("relatedItemTypeName") final String relatedItemTypeName,
12023            @GraphQLName("id") @GraphQLID final String id) {
12024        RelatedItemType relatedItemType;
12025
12026        try {
12027            var commandForm = ItemUtil.getHome().getGetRelatedItemTypeForm();
12028
12029            commandForm.setRelatedItemTypeName(relatedItemTypeName);
12030            commandForm.setUuid(id);
12031
12032            relatedItemType = CDI.current().select(GetRelatedItemTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
12033        } catch (NamingException ex) {
12034            throw new RuntimeException(ex);
12035        }
12036
12037        return relatedItemType == null ? null : new RelatedItemTypeObject(relatedItemType, null);
12038    }
12039
12040    @GraphQLField
12041    @GraphQLName("relatedItemTypes")
12042    @GraphQLNonNull
12043    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12044    static CountingPaginatedData<RelatedItemTypeObject> relatedItemTypes(final DataFetchingEnvironment env) {
12045        CountingPaginatedData<RelatedItemTypeObject> data;
12046
12047        try {
12048            var commandForm = ItemUtil.getHome().getGetRelatedItemTypesForm();
12049            var command = CDI.current().select(GetRelatedItemTypesCommand.class).get();
12050
12051            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12052            if(totalEntities == null) {
12053                data = Connections.emptyConnection();
12054            } else {
12055                try(var objectLimiter = new ObjectLimiter(env, RelatedItemTypeConstants.COMPONENT_VENDOR_NAME, RelatedItemTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
12056                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12057
12058                    var relatedItemTypes = entities.stream()
12059                            .map((RelatedItemType relatedItemType) -> new RelatedItemTypeObject(relatedItemType, null))
12060                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12061
12062                    data = new CountedObjects<>(objectLimiter, relatedItemTypes);
12063                }
12064            }
12065        } catch (NamingException ex) {
12066            throw new RuntimeException(ex);
12067        }
12068
12069        return data;
12070    }
12071
12072    @GraphQLField
12073    @GraphQLName("relatedItem")
12074    static RelatedItemObject relatedItem(final DataFetchingEnvironment env,
12075            @GraphQLName("relatedItemTypeName") @GraphQLNonNull final String relatedItemTypeName,
12076            @GraphQLName("fromItemName") @GraphQLNonNull final String fromItemName,
12077            @GraphQLName("toItemName") @GraphQLNonNull final String toItemName) {
12078        RelatedItem relatedItem;
12079
12080        try {
12081            var commandForm = ItemUtil.getHome().getGetRelatedItemForm();
12082
12083            commandForm.setRelatedItemTypeName(relatedItemTypeName);
12084            commandForm.setFromItemName(fromItemName);
12085            commandForm.setToItemName(toItemName);
12086
12087            relatedItem = CDI.current().select(GetRelatedItemCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
12088        } catch (NamingException ex) {
12089            throw new RuntimeException(ex);
12090        }
12091
12092        return relatedItem == null ? null : new RelatedItemObject(relatedItem);
12093    }
12094
12095    @GraphQLField
12096    @GraphQLName("relatedItems")
12097    @GraphQLNonNull
12098    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12099    static CountingPaginatedData<RelatedItemObject> relatedItems(final DataFetchingEnvironment env,
12100            @GraphQLName("relatedItemTypeName") final String relatedItemTypeName,
12101            @GraphQLName("fromItemName") final String fromItemName,
12102            @GraphQLName("toItemName") final String toItemName) {
12103        CountingPaginatedData<RelatedItemObject> data;
12104
12105        try {
12106            var commandForm = ItemUtil.getHome().getGetRelatedItemsForm();
12107            var command = CDI.current().select(GetRelatedItemsCommand.class).get();
12108
12109            commandForm.setRelatedItemTypeName(relatedItemTypeName);
12110            commandForm.setFromItemName(fromItemName);
12111            commandForm.setToItemName(toItemName);
12112
12113            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12114            if(totalEntities == null) {
12115                data = Connections.emptyConnection();
12116            } else {
12117                try(var objectLimiter = new ObjectLimiter(env, RelatedItemConstants.COMPONENT_VENDOR_NAME, RelatedItemConstants.ENTITY_TYPE_NAME, totalEntities)) {
12118                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12119
12120                    var relatedItemObjects = entities.stream()
12121                            .map(RelatedItemObject::new)
12122                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12123
12124                    data = new CountedObjects<>(objectLimiter, relatedItemObjects);
12125                }
12126            }
12127        } catch (NamingException ex) {
12128            throw new RuntimeException(ex);
12129        }
12130
12131        return data;
12132    }
12133
12134    @GraphQLField
12135    @GraphQLName("orderType")
12136    static OrderTypeObject orderType(final DataFetchingEnvironment env,
12137            @GraphQLName("orderTypeName") final String orderTypeName,
12138            @GraphQLName("id") @GraphQLID final String id) {
12139        OrderType orderType;
12140
12141        try {
12142            var commandForm = OrderUtil.getHome().getGetOrderTypeForm();
12143
12144            commandForm.setOrderTypeName(orderTypeName);
12145            commandForm.setUuid(id);
12146
12147            orderType = CDI.current().select(GetOrderTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
12148        } catch (NamingException ex) {
12149            throw new RuntimeException(ex);
12150        }
12151
12152        return orderType == null ? null : new OrderTypeObject(orderType);
12153    }
12154
12155    @GraphQLField
12156    @GraphQLName("orderTypes")
12157    @GraphQLNonNull
12158    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12159    static CountingPaginatedData<OrderTypeObject> orderTypes(final DataFetchingEnvironment env) {
12160        CountingPaginatedData<OrderTypeObject> data;
12161
12162        try {
12163            var commandForm = OrderUtil.getHome().getGetOrderTypesForm();
12164            var command = CDI.current().select(GetOrderTypesCommand.class).get();
12165
12166            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12167            if(totalEntities == null) {
12168                data = Connections.emptyConnection();
12169            } else {
12170                try(var objectLimiter = new ObjectLimiter(env, OrderTypeConstants.COMPONENT_VENDOR_NAME, OrderTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
12171                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12172
12173                    var orderTypes = entities.stream()
12174                            .map(OrderTypeObject::new)
12175                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12176
12177                    data = new CountedObjects<>(objectLimiter, orderTypes);
12178                }
12179            }
12180        } catch (NamingException ex) {
12181            throw new RuntimeException(ex);
12182        }
12183
12184        return data;
12185    }
12186
12187    @GraphQLField
12188    @GraphQLName("orderPriority")
12189    static OrderPriorityObject orderPriority(final DataFetchingEnvironment env,
12190            @GraphQLName("orderTypeName") final String orderTypeName,
12191            @GraphQLName("orderPriorityName") final String orderPriorityName,
12192            @GraphQLName("id") @GraphQLID final String id) {
12193        OrderPriority orderPriority;
12194
12195        try {
12196            var commandForm = OrderUtil.getHome().getGetOrderPriorityForm();
12197
12198            commandForm.setOrderTypeName(orderTypeName);
12199            commandForm.setOrderPriorityName(orderPriorityName);
12200            commandForm.setUuid(id);
12201
12202            orderPriority = CDI.current().select(GetOrderPriorityCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
12203        } catch (NamingException ex) {
12204            throw new RuntimeException(ex);
12205        }
12206
12207        return orderPriority == null ? null : new OrderPriorityObject(orderPriority);
12208    }
12209
12210    @GraphQLField
12211    @GraphQLName("orderPriorities")
12212    @GraphQLNonNull
12213    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12214    static CountingPaginatedData<OrderPriorityObject> orderPriorities(final DataFetchingEnvironment env,
12215            @GraphQLName("orderTypeName") final String orderTypeName) {
12216        CountingPaginatedData<OrderPriorityObject> data;
12217
12218        try {
12219            var commandForm = OrderUtil.getHome().getGetOrderPrioritiesForm();
12220            var command = CDI.current().select(GetOrderPrioritiesCommand.class).get();
12221
12222            commandForm.setOrderTypeName(orderTypeName);
12223
12224            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12225            if(totalEntities == null) {
12226                data = Connections.emptyConnection();
12227            } else {
12228                try(var objectLimiter = new ObjectLimiter(env, OrderPriorityConstants.COMPONENT_VENDOR_NAME, OrderPriorityConstants.ENTITY_TYPE_NAME, totalEntities)) {
12229                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12230
12231                    var orderPriorities = entities.stream()
12232                            .map(OrderPriorityObject::new)
12233                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12234
12235                    data = new CountedObjects<>(objectLimiter, orderPriorities);
12236                }
12237            }
12238        } catch (NamingException ex) {
12239            throw new RuntimeException(ex);
12240        }
12241
12242        return data;
12243    }
12244
12245    @GraphQLField
12246    @GraphQLName("orderTimeType")
12247    static OrderTimeTypeObject orderTimeType(final DataFetchingEnvironment env,
12248            @GraphQLName("orderTypeName") final String orderTypeName,
12249            @GraphQLName("orderTimeTypeName") final String orderTimeTypeName,
12250            @GraphQLName("id") @GraphQLID final String id) {
12251        OrderTimeType orderTimeType;
12252
12253        try {
12254            var commandForm = OrderUtil.getHome().getGetOrderTimeTypeForm();
12255
12256            commandForm.setOrderTypeName(orderTypeName);
12257            commandForm.setOrderTimeTypeName(orderTimeTypeName);
12258            commandForm.setUuid(id);
12259
12260            orderTimeType = CDI.current().select(GetOrderTimeTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
12261        } catch (NamingException ex) {
12262            throw new RuntimeException(ex);
12263        }
12264
12265        return orderTimeType == null ? null : new OrderTimeTypeObject(orderTimeType);
12266    }
12267
12268    @GraphQLField
12269    @GraphQLName("orderTimeTypes")
12270    @GraphQLNonNull
12271    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12272    static CountingPaginatedData<OrderTimeTypeObject> orderTimeTypes(final DataFetchingEnvironment env,
12273            @GraphQLName("orderTypeName") final String orderTypeName) {
12274        CountingPaginatedData<OrderTimeTypeObject> data;
12275
12276        try {
12277            var commandForm = OrderUtil.getHome().getGetOrderTimeTypesForm();
12278            var command = CDI.current().select(GetOrderTimeTypesCommand.class).get();
12279
12280            commandForm.setOrderTypeName(orderTypeName);
12281
12282            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12283            if(totalEntities == null) {
12284                data = Connections.emptyConnection();
12285            } else {
12286                try(var objectLimiter = new ObjectLimiter(env, OrderTimeTypeConstants.COMPONENT_VENDOR_NAME, OrderTimeTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
12287                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12288
12289                    var orderTimeTypes = entities.stream()
12290                            .map(OrderTimeTypeObject::new)
12291                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12292
12293                    data = new CountedObjects<>(objectLimiter, orderTimeTypes);
12294                }
12295            }
12296        } catch (NamingException ex) {
12297            throw new RuntimeException(ex);
12298        }
12299
12300        return data;
12301    }
12302
12303    @GraphQLField
12304    @GraphQLName("wishlistType")
12305    static WishlistTypeObject wishlistType(final DataFetchingEnvironment env,
12306            @GraphQLName("wishlistTypeName") final String wishlistTypeName,
12307            @GraphQLName("id") @GraphQLID final String id) {
12308        WishlistType wishlistType;
12309
12310        try {
12311            var commandForm = WishlistUtil.getHome().getGetWishlistTypeForm();
12312
12313            commandForm.setWishlistTypeName(wishlistTypeName);
12314            commandForm.setUuid(id);
12315
12316            wishlistType = CDI.current().select(GetWishlistTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
12317        } catch (NamingException ex) {
12318            throw new RuntimeException(ex);
12319        }
12320
12321        return wishlistType == null ? null : new WishlistTypeObject(wishlistType);
12322    }
12323
12324    @GraphQLField
12325    @GraphQLName("wishlistTypes")
12326    @GraphQLNonNull
12327    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12328    static CountingPaginatedData<WishlistTypeObject> wishlistTypes(final DataFetchingEnvironment env) {
12329        CountingPaginatedData<WishlistTypeObject> data;
12330
12331        try {
12332            var commandForm = WishlistUtil.getHome().getGetWishlistTypesForm();
12333            var command = CDI.current().select(GetWishlistTypesCommand.class).get();
12334
12335            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12336            if(totalEntities == null) {
12337                data = Connections.emptyConnection();
12338            } else {
12339                try(var objectLimiter = new ObjectLimiter(env, WishlistTypeConstants.COMPONENT_VENDOR_NAME, WishlistTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
12340                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12341
12342                    var wishlistTypes = entities.stream()
12343                            .map(WishlistTypeObject::new)
12344                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12345
12346                    data = new CountedObjects<>(objectLimiter, wishlistTypes);
12347                }
12348            }
12349        } catch (NamingException ex) {
12350            throw new RuntimeException(ex);
12351        }
12352
12353        return data;
12354    }
12355
12356    @GraphQLField
12357    @GraphQLName("wishlistPriority")
12358    static WishlistPriorityObject wishlistPriority(final DataFetchingEnvironment env,
12359            @GraphQLName("wishlistTypeName") final String wishlistTypeName,
12360            @GraphQLName("wishlistPriorityName") final String wishlistPriorityName,
12361            @GraphQLName("id") @GraphQLID final String id) {
12362        WishlistPriority wishlistPriority;
12363
12364        try {
12365            var commandForm = WishlistUtil.getHome().getGetWishlistPriorityForm();
12366
12367            commandForm.setWishlistTypeName(wishlistTypeName);
12368            commandForm.setWishlistPriorityName(wishlistPriorityName);
12369            commandForm.setUuid(id);
12370
12371            wishlistPriority = CDI.current().select(GetWishlistPriorityCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
12372        } catch (NamingException ex) {
12373            throw new RuntimeException(ex);
12374        }
12375
12376        return wishlistPriority == null ? null : new WishlistPriorityObject(wishlistPriority);
12377    }
12378
12379    @GraphQLField
12380    @GraphQLName("wishlistPriorities")
12381    @GraphQLNonNull
12382    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12383    static CountingPaginatedData<WishlistPriorityObject> wishlistPriorities(final DataFetchingEnvironment env,
12384            @GraphQLName("wishlistTypeName") @GraphQLNonNull final String wishlistTypeName) {
12385        CountingPaginatedData<WishlistPriorityObject> data;
12386
12387        try {
12388            var commandForm = WishlistUtil.getHome().getGetWishlistPrioritiesForm();
12389            var command = CDI.current().select(GetWishlistPrioritiesCommand.class).get();
12390
12391            commandForm.setWishlistTypeName(wishlistTypeName);
12392
12393            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12394            if(totalEntities == null) {
12395                data = Connections.emptyConnection();
12396            } else {
12397                try(var objectLimiter = new ObjectLimiter(env, WishlistPriorityConstants.COMPONENT_VENDOR_NAME, WishlistPriorityConstants.ENTITY_TYPE_NAME, totalEntities)) {
12398                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12399
12400                    var wishlistPriorities = entities.stream()
12401                            .map(WishlistPriorityObject::new)
12402                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12403
12404                    data = new CountedObjects<>(objectLimiter, wishlistPriorities);
12405                }
12406            }
12407        } catch (NamingException ex) {
12408            throw new RuntimeException(ex);
12409        }
12410
12411        return data;
12412    }
12413
12414    @GraphQLField
12415    @GraphQLName("termType")
12416    static TermTypeObject termType(final DataFetchingEnvironment env,
12417            @GraphQLName("termTypeName") final String termTypeName,
12418            @GraphQLName("id") @GraphQLID final String id) {
12419        TermType termType;
12420
12421        try {
12422            var commandForm = TermUtil.getHome().getGetTermTypeForm();
12423
12424            commandForm.setTermTypeName(termTypeName);
12425            commandForm.setUuid(id);
12426
12427            termType = CDI.current().select(GetTermTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
12428        } catch (NamingException ex) {
12429            throw new RuntimeException(ex);
12430        }
12431
12432        return termType == null ? null : new TermTypeObject(termType);
12433    }
12434
12435    @GraphQLField
12436    @GraphQLName("termTypes")
12437    @GraphQLNonNull
12438    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12439    static CountingPaginatedData<TermTypeObject> termTypes(final DataFetchingEnvironment env) {
12440        CountingPaginatedData<TermTypeObject> data;
12441
12442        try {
12443            var commandForm = TermUtil.getHome().getGetTermTypesForm();
12444            var command = CDI.current().select(GetTermTypesCommand.class).get();
12445
12446            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12447            if(totalEntities == null) {
12448                data = Connections.emptyConnection();
12449            } else {
12450                try(var objectLimiter = new ObjectLimiter(env, TermTypeConstants.COMPONENT_VENDOR_NAME, TermTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
12451                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12452
12453                    var termTypes = entities.stream()
12454                            .map(TermTypeObject::new)
12455                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12456
12457                    data = new CountedObjects<>(objectLimiter, termTypes);
12458                }
12459            }
12460        } catch (NamingException ex) {
12461            throw new RuntimeException(ex);
12462        }
12463
12464        return data;
12465    }
12466
12467    @GraphQLField
12468    @GraphQLName("term")
12469    static TermObject term(final DataFetchingEnvironment env,
12470            @GraphQLName("termName") final String termName,
12471            @GraphQLName("id") @GraphQLID final String id) {
12472        Term term;
12473
12474        try {
12475            var commandForm = TermUtil.getHome().getGetTermForm();
12476
12477            commandForm.setTermName(termName);
12478            commandForm.setUuid(id);
12479
12480            term = CDI.current().select(GetTermCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
12481        } catch (NamingException ex) {
12482            throw new RuntimeException(ex);
12483        }
12484
12485        return term == null ? null : new TermObject(term);
12486    }
12487
12488    @GraphQLField
12489    @GraphQLName("terms")
12490    @GraphQLNonNull
12491    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12492    static CountingPaginatedData<TermObject> terms(final DataFetchingEnvironment env) {
12493        CountingPaginatedData<TermObject> data;
12494
12495        try {
12496            var commandForm = TermUtil.getHome().getGetTermsForm();
12497            var command = CDI.current().select(GetTermsCommand.class).get();
12498
12499            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12500            if(totalEntities == null) {
12501                data = Connections.emptyConnection();
12502            } else {
12503                try(var objectLimiter = new ObjectLimiter(env, TermConstants.COMPONENT_VENDOR_NAME, TermConstants.ENTITY_TYPE_NAME, totalEntities)) {
12504                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12505
12506                    var terms = entities.stream()
12507                            .map(TermObject::new)
12508                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12509
12510                    data = new CountedObjects<>(objectLimiter, terms);
12511                }
12512            }
12513        } catch (NamingException ex) {
12514            throw new RuntimeException(ex);
12515        }
12516
12517        return data;
12518    }
12519
12520    @GraphQLField
12521    @GraphQLName("securityRoleGroup")
12522    static SecurityRoleGroupObject securityRoleGroup(final DataFetchingEnvironment env,
12523            @GraphQLName("securityRoleGroupName") final String securityRoleGroupName,
12524            @GraphQLName("id") @GraphQLID final String id) {
12525        SecurityRoleGroup securityRoleGroup;
12526
12527        try {
12528            var commandForm = SecurityUtil.getHome().getGetSecurityRoleGroupForm();
12529
12530            commandForm.setSecurityRoleGroupName(securityRoleGroupName);
12531            commandForm.setUuid(id);
12532
12533            securityRoleGroup = CDI.current().select(GetSecurityRoleGroupCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
12534        } catch (NamingException ex) {
12535            throw new RuntimeException(ex);
12536        }
12537
12538        return securityRoleGroup == null ? null : new SecurityRoleGroupObject(securityRoleGroup);
12539    }
12540
12541    @GraphQLField
12542    @GraphQLName("securityRoleGroups")
12543    @GraphQLNonNull
12544    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12545    static CountingPaginatedData<SecurityRoleGroupObject> securityRoleGroups(final DataFetchingEnvironment env,
12546            @GraphQLName("parentSecurityRoleGroupName") final String parentSecurityRoleGroupName) {
12547        CountingPaginatedData<SecurityRoleGroupObject> data;
12548
12549        try {
12550            var commandForm = SecurityUtil.getHome().getGetSecurityRoleGroupsForm();
12551            var command = CDI.current().select(GetSecurityRoleGroupsCommand.class).get();
12552
12553            commandForm.setParentSecurityRoleGroupName(parentSecurityRoleGroupName);
12554
12555            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12556            if(totalEntities == null) {
12557                data = Connections.emptyConnection();
12558            } else {
12559                try(var objectLimiter = new ObjectLimiter(env, SecurityRoleGroupConstants.COMPONENT_VENDOR_NAME, SecurityRoleGroupConstants.ENTITY_TYPE_NAME, totalEntities)) {
12560                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12561
12562                    var securityRoleGroups = entities.stream()
12563                            .map(SecurityRoleGroupObject::new)
12564                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12565
12566                    data = new CountedObjects<>(objectLimiter, securityRoleGroups);
12567                }
12568            }
12569        } catch (NamingException ex) {
12570            throw new RuntimeException(ex);
12571        }
12572
12573        return data;
12574    }
12575
12576    @GraphQLField
12577    @GraphQLName("securityRole")
12578    static SecurityRoleObject securityRole(final DataFetchingEnvironment env,
12579            @GraphQLName("securityRoleGroupName") final String securityRoleGroupName,
12580            @GraphQLName("securityRoleName") final String securityRoleName,
12581            @GraphQLName("id") @GraphQLID final String id) {
12582        SecurityRole securityRole;
12583
12584        try {
12585            var commandForm = SecurityUtil.getHome().getGetSecurityRoleForm();
12586
12587            commandForm.setSecurityRoleGroupName(securityRoleGroupName);
12588            commandForm.setSecurityRoleName(securityRoleName);
12589            commandForm.setUuid(id);
12590
12591            securityRole = CDI.current().select(GetSecurityRoleCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
12592        } catch (NamingException ex) {
12593            throw new RuntimeException(ex);
12594        }
12595
12596        return securityRole == null ? null : new SecurityRoleObject(securityRole);
12597    }
12598
12599    @GraphQLField
12600    @GraphQLName("securityRoles")
12601    @GraphQLNonNull
12602    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12603    static CountingPaginatedData<SecurityRoleObject> securityRoles(final DataFetchingEnvironment env,
12604            @GraphQLName("securityRoleGroupName") @GraphQLNonNull final String securityRoleGroupName) {
12605        CountingPaginatedData<SecurityRoleObject> data;
12606
12607        try {
12608            var commandForm = SecurityUtil.getHome().getGetSecurityRolesForm();
12609            var command = CDI.current().select(GetSecurityRolesCommand.class).get();
12610
12611            commandForm.setSecurityRoleGroupName(securityRoleGroupName);
12612
12613            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12614            if(totalEntities == null) {
12615                data = Connections.emptyConnection();
12616            } else {
12617                try(var objectLimiter = new ObjectLimiter(env, SecurityRoleConstants.COMPONENT_VENDOR_NAME, SecurityRoleConstants.ENTITY_TYPE_NAME, totalEntities)) {
12618                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12619
12620                    var securityRoles = entities.stream()
12621                            .map(SecurityRoleObject::new)
12622                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12623
12624                    data = new CountedObjects<>(objectLimiter, securityRoles);
12625                }
12626            }
12627        } catch (NamingException ex) {
12628            throw new RuntimeException(ex);
12629        }
12630
12631        return data;
12632    }
12633
12634    @GraphQLField
12635    @GraphQLName("personalTitles")
12636    @GraphQLNonNull
12637    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12638    static CountingPaginatedData<PersonalTitleObject> personalTitles(final DataFetchingEnvironment env) {
12639        CountingPaginatedData<PersonalTitleObject> data;
12640
12641        try {
12642            var commandForm = PartyUtil.getHome().getGetPersonalTitlesForm();
12643            var command = CDI.current().select(GetPersonalTitlesCommand.class).get();
12644
12645            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12646            if(totalEntities == null) {
12647                data = Connections.emptyConnection();
12648            } else {
12649                try(var objectLimiter = new ObjectLimiter(env, PersonalTitleConstants.COMPONENT_VENDOR_NAME, PersonalTitleConstants.ENTITY_TYPE_NAME, totalEntities)) {
12650                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12651
12652                    var personalTitles = entities.stream()
12653                            .map(PersonalTitleObject::new)
12654                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12655
12656                    data = new CountedObjects<>(objectLimiter, personalTitles);
12657                }
12658            }
12659        } catch (NamingException ex) {
12660            throw new RuntimeException(ex);
12661        }
12662
12663        return data;
12664    }
12665
12666    @GraphQLField
12667    @GraphQLName("nameSuffixes")
12668    @GraphQLNonNull
12669    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12670    static CountingPaginatedData<NameSuffixObject> nameSuffixes(final DataFetchingEnvironment env) {
12671        CountingPaginatedData<NameSuffixObject> data;
12672
12673        try {
12674            var commandForm = PartyUtil.getHome().getGetNameSuffixesForm();
12675            var command = CDI.current().select(GetNameSuffixesCommand.class).get();
12676
12677            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12678            if(totalEntities == null) {
12679                data = Connections.emptyConnection();
12680            } else {
12681                try(var objectLimiter = new ObjectLimiter(env, NameSuffixConstants.COMPONENT_VENDOR_NAME, NameSuffixConstants.ENTITY_TYPE_NAME, totalEntities)) {
12682                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12683
12684                    var nameSuffixes = entities.stream()
12685                            .map(NameSuffixObject::new)
12686                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12687
12688                    data = new CountedObjects<>(objectLimiter, nameSuffixes);
12689                }
12690            }
12691        } catch (NamingException ex) {
12692            throw new RuntimeException(ex);
12693        }
12694
12695        return data;
12696    }
12697
12698    @GraphQLField
12699    @GraphQLName("tagScope")
12700    static TagScopeObject tagScope(final DataFetchingEnvironment env,
12701            @GraphQLName("tagScopeName") final String tagScopeName,
12702            @GraphQLName("id") @GraphQLID final String id) {
12703        TagScope tagScope;
12704
12705        try {
12706            var commandForm = TagUtil.getHome().getGetTagScopeForm();
12707
12708            commandForm.setTagScopeName(tagScopeName);
12709            commandForm.setUuid(id);
12710
12711            tagScope = CDI.current().select(GetTagScopeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
12712        } catch (NamingException ex) {
12713            throw new RuntimeException(ex);
12714        }
12715
12716        return tagScope == null ? null : new TagScopeObject(tagScope, null);
12717    }
12718
12719    @GraphQLField
12720    @GraphQLName("tagScopes")
12721    @GraphQLNonNull
12722    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12723    static CountingPaginatedData<TagScopeObject> tagScopes(final DataFetchingEnvironment env) {
12724        CountingPaginatedData<TagScopeObject> data;
12725
12726        try {
12727            var commandForm = TagUtil.getHome().getGetTagScopesForm();
12728            var command = CDI.current().select(GetTagScopesCommand.class).get();
12729
12730            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12731            if(totalEntities == null) {
12732                data = Connections.emptyConnection();
12733            } else {
12734                try(var objectLimiter = new ObjectLimiter(env, TagScopeConstants.COMPONENT_VENDOR_NAME, TagScopeConstants.ENTITY_TYPE_NAME, totalEntities)) {
12735                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12736
12737                    var tagScopes = entities.stream()
12738                            .map(TagScopeObject::new)
12739                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12740
12741                    data = new CountedObjects<>(objectLimiter, tagScopes);
12742                }
12743            }
12744        } catch (NamingException ex) {
12745            throw new RuntimeException(ex);
12746        }
12747
12748        return data;
12749    }
12750
12751    @GraphQLField
12752    @GraphQLName("tagScopeEntityType")
12753    static TagScopeEntityTypeObject tagScopeEntityType(final DataFetchingEnvironment env,
12754            @GraphQLName("tagScopeName") @GraphQLNonNull final String tagScopeName,
12755            @GraphQLName("componentVendorName") @GraphQLNonNull final String componentVendorName,
12756            @GraphQLName("entityTypeName") @GraphQLNonNull final String entityTypeName) {
12757        TagScopeEntityType tagScopeEntityType;
12758
12759        try {
12760            var commandForm = TagUtil.getHome().getGetTagScopeEntityTypeForm();
12761
12762            commandForm.setTagScopeName(tagScopeName);
12763            commandForm.setComponentVendorName(componentVendorName);
12764            commandForm.setEntityTypeName(entityTypeName);
12765
12766            tagScopeEntityType = CDI.current().select(GetTagScopeEntityTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
12767        } catch (NamingException ex) {
12768            throw new RuntimeException(ex);
12769        }
12770
12771        return tagScopeEntityType == null ? null : new TagScopeEntityTypeObject(tagScopeEntityType);
12772    }
12773
12774    @GraphQLField
12775    @GraphQLName("tagScopeEntityTypes")
12776    @GraphQLNonNull
12777    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12778    static CountingPaginatedData<TagScopeEntityTypeObject> tagScopeEntityTypes(final DataFetchingEnvironment env,
12779            @GraphQLName("tagScopeName") final String tagScopeName,
12780            @GraphQLName("componentVendorName") final String componentVendorName,
12781            @GraphQLName("entityTypeName") final String entityTypeName) {
12782        try {
12783            var commandForm = TagUtil.getHome().getGetTagScopeEntityTypesForm();
12784            var command = CDI.current().select(GetTagScopeEntityTypesCommand.class).get();
12785
12786            commandForm.setTagScopeName(tagScopeName);
12787            commandForm.setComponentVendorName(componentVendorName);
12788            commandForm.setEntityTypeName(entityTypeName);
12789
12790            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12791            if(totalEntities == null) {
12792                return Connections.emptyConnection();
12793            } else {
12794                try(var objectLimiter = new ObjectLimiter(env, TagScopeEntityTypeConstants.COMPONENT_VENDOR_NAME, TagScopeEntityTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
12795                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12796
12797                    return new CountedObjects<>(objectLimiter, entities.stream().map(TagScopeEntityTypeObject::new).collect(Collectors.toCollection(() -> new ArrayList<>(entities.size()))));
12798                }
12799            }
12800        } catch (NamingException ex) {
12801            throw new RuntimeException(ex);
12802        }
12803    }
12804
12805    @GraphQLField
12806    @GraphQLName("tag")
12807    static TagObject tag(final DataFetchingEnvironment env,
12808            @GraphQLName("tagScopeName") final String tagScopeName,
12809            @GraphQLName("tagName") final String tagName,
12810            @GraphQLName("id") @GraphQLID final String id) {
12811        Tag tag;
12812
12813        try {
12814            var commandForm = TagUtil.getHome().getGetTagForm();
12815
12816            commandForm.setTagScopeName(tagScopeName);
12817            commandForm.setTagName(tagName);
12818            commandForm.setUuid(id);
12819
12820            tag = CDI.current().select(GetTagCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
12821        } catch (NamingException ex) {
12822            throw new RuntimeException(ex);
12823        }
12824
12825        return tag == null ? null : new TagObject(tag);
12826    }
12827
12828    @GraphQLField
12829    @GraphQLName("tags")
12830    @GraphQLNonNull
12831    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12832    static CountingPaginatedData<TagObject> tags(final DataFetchingEnvironment env,
12833            @GraphQLName("tagScopeName") @GraphQLNonNull final String tagScopeName) {
12834        CountingPaginatedData<TagObject> data;
12835
12836        try {
12837            var commandForm = TagUtil.getHome().getGetTagsForm();
12838            var command = CDI.current().select(GetTagsCommand.class).get();
12839
12840            commandForm.setTagScopeName(tagScopeName);
12841
12842            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12843            if(totalEntities == null) {
12844                data = Connections.emptyConnection();
12845            } else {
12846                try(var objectLimiter = new ObjectLimiter(env, TagConstants.COMPONENT_VENDOR_NAME, TagConstants.ENTITY_TYPE_NAME, totalEntities)) {
12847                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12848
12849                    var tagObjects = entities.stream()
12850                            .map(TagObject::new)
12851                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12852
12853                    data = new CountedObjects<>(objectLimiter, tagObjects);
12854                }
12855            }
12856        } catch (NamingException ex) {
12857            throw new RuntimeException(ex);
12858        }
12859
12860        return data;
12861    }
12862
12863    @GraphQLField
12864    @GraphQLName("entityTag")
12865    static EntityTagObject entityTag(final DataFetchingEnvironment env,
12866            @GraphQLName("id") @GraphQLNonNull final String id,
12867            @GraphQLName("tagScopeName") @GraphQLNonNull final String tagScopeName,
12868            @GraphQLName("tagName") @GraphQLNonNull final String tagName) {
12869        EntityTag entityTag;
12870
12871        try {
12872            var commandForm = TagUtil.getHome().getGetEntityTagForm();
12873
12874            commandForm.setUuid(id);
12875            commandForm.setTagScopeName(tagScopeName);
12876            commandForm.setTagName(tagName);
12877
12878            entityTag = CDI.current().select(GetEntityTagCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
12879        } catch (NamingException ex) {
12880            throw new RuntimeException(ex);
12881        }
12882
12883        return entityTag == null ? null : new EntityTagObject(entityTag);
12884    }
12885
12886    @GraphQLField
12887    @GraphQLName("entityTags")
12888    @GraphQLNonNull
12889    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12890    static CountingPaginatedData<EntityTagObject> entityTags(final DataFetchingEnvironment env,
12891            @GraphQLName("id") final String id,
12892            @GraphQLName("tagScopeName") final String tagScopeName,
12893            @GraphQLName("tagName") final String tagName) {
12894        CountingPaginatedData<EntityTagObject> data;
12895
12896        try {
12897            var commandForm = TagUtil.getHome().getGetEntityTagsForm();
12898            var command = CDI.current().select(GetEntityTagsCommand.class).get();
12899
12900            commandForm.setUuid(id);
12901            commandForm.setTagScopeName(tagScopeName);
12902            commandForm.setTagName(tagName);
12903
12904            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12905            if(totalEntities == null) {
12906                data = Connections.emptyConnection();
12907            } else {
12908                try(var objectLimiter = new ObjectLimiter(env, EntityTagConstants.COMPONENT_VENDOR_NAME, EntityTagConstants.ENTITY_TYPE_NAME, totalEntities)) {
12909                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12910
12911                    var entityTags = entities.stream()
12912                            .map(EntityTagObject::new)
12913                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12914
12915                    data = new CountedObjects<>(objectLimiter, entityTags);
12916                }
12917            }
12918        } catch (NamingException ex) {
12919            throw new RuntimeException(ex);
12920        }
12921
12922        return data;
12923    }
12924
12925    @GraphQLField
12926    @GraphQLName("geoCodeType")
12927    static GeoCodeTypeObject geoCodeType(final DataFetchingEnvironment env,
12928            @GraphQLName("geoCodeTypeName") final String geoCodeTypeName,
12929            @GraphQLName("id") @GraphQLID final String id) {
12930        GeoCodeType geoCodeType;
12931
12932        try {
12933            var commandForm = GeoUtil.getHome().getGetGeoCodeTypeForm();
12934
12935            commandForm.setGeoCodeTypeName(geoCodeTypeName);
12936            commandForm.setUuid(id);
12937
12938            geoCodeType = CDI.current().select(GetGeoCodeTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
12939        } catch (NamingException ex) {
12940            throw new RuntimeException(ex);
12941        }
12942
12943        return geoCodeType == null ? null : new GeoCodeTypeObject(geoCodeType);
12944    }
12945
12946    @GraphQLField
12947    @GraphQLName("geoCodeTypes")
12948    @GraphQLNonNull
12949    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
12950    static CountingPaginatedData<GeoCodeTypeObject> geoCodeTypes(final DataFetchingEnvironment env) {
12951        CountingPaginatedData<GeoCodeTypeObject> data;
12952
12953        try {
12954            var commandForm = GeoUtil.getHome().getGetGeoCodeTypesForm();
12955            var command = CDI.current().select(GetGeoCodeTypesCommand.class).get();
12956
12957            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12958            if(totalEntities == null) {
12959                data = Connections.emptyConnection();
12960            } else {
12961                try(var objectLimiter = new ObjectLimiter(env, GeoCodeTypeConstants.COMPONENT_VENDOR_NAME, GeoCodeTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
12962                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
12963
12964                    var geoCodeTypes = entities.stream()
12965                            .map(GeoCodeTypeObject::new)
12966                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
12967
12968                    data = new CountedObjects<>(objectLimiter, geoCodeTypes);
12969                }
12970            }
12971        } catch (NamingException ex) {
12972            throw new RuntimeException(ex);
12973        }
12974
12975        return data;
12976    }
12977
12978    @GraphQLField
12979    @GraphQLName("geoCodeAliasType")
12980    static GeoCodeAliasTypeObject geoCodeAliasType(final DataFetchingEnvironment env,
12981            @GraphQLName("geoCodeTypeName") @GraphQLNonNull final String geoCodeTypeName,
12982            @GraphQLName("geoCodeAliasTypeName") @GraphQLNonNull final String geoCodeAliasTypeName) {
12983        GeoCodeAliasType geoCodeAliasType;
12984
12985        try {
12986            var commandForm = GeoUtil.getHome().getGetGeoCodeAliasTypeForm();
12987
12988            commandForm.setGeoCodeTypeName(geoCodeTypeName);
12989            commandForm.setGeoCodeAliasTypeName(geoCodeAliasTypeName);
12990
12991            geoCodeAliasType = CDI.current().select(GetGeoCodeAliasTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
12992        } catch (NamingException ex) {
12993            throw new RuntimeException(ex);
12994        }
12995
12996        return geoCodeAliasType == null ? null : new GeoCodeAliasTypeObject(geoCodeAliasType);
12997    }
12998
12999    @GraphQLField
13000    @GraphQLName("geoCodeAliasTypes")
13001    @GraphQLNonNull
13002    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13003    static CountingPaginatedData<GeoCodeAliasTypeObject> geoCodeAliasTypes(final DataFetchingEnvironment env,
13004            @GraphQLName("geoCodeTypeName") @GraphQLNonNull final String geoCodeTypeName) {
13005        CountingPaginatedData<GeoCodeAliasTypeObject> data;
13006
13007        try {
13008            var commandForm = GeoUtil.getHome().getGetGeoCodeAliasTypesForm();
13009            var command = CDI.current().select(GetGeoCodeAliasTypesCommand.class).get();
13010
13011            commandForm.setGeoCodeTypeName(geoCodeTypeName);
13012
13013            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13014            if(totalEntities == null) {
13015                data = Connections.emptyConnection();
13016            } else {
13017                try(var objectLimiter = new ObjectLimiter(env, GeoCodeAliasTypeConstants.COMPONENT_VENDOR_NAME, GeoCodeAliasTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
13018                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13019
13020                    var geoCodeAliasTypes = entities.stream()
13021                            .map(GeoCodeAliasTypeObject::new)
13022                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
13023
13024                    data = new CountedObjects<>(objectLimiter, geoCodeAliasTypes);
13025                }
13026            }
13027        } catch (NamingException ex) {
13028            throw new RuntimeException(ex);
13029        }
13030
13031        return data;
13032    }
13033
13034    @GraphQLField
13035    @GraphQLName("geoCodeScope")
13036    static GeoCodeScopeObject geoCodeScope(final DataFetchingEnvironment env,
13037            @GraphQLName("geoCodeScopeName") final String geoCodeScopeName,
13038            @GraphQLName("id") @GraphQLID final String id) {
13039        GeoCodeScope geoCodeScope;
13040
13041        try {
13042            var commandForm = GeoUtil.getHome().getGetGeoCodeScopeForm();
13043
13044            commandForm.setGeoCodeScopeName(geoCodeScopeName);
13045            commandForm.setUuid(id);
13046
13047            geoCodeScope = CDI.current().select(GetGeoCodeScopeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13048        } catch (NamingException ex) {
13049            throw new RuntimeException(ex);
13050        }
13051
13052        return geoCodeScope == null ? null : new GeoCodeScopeObject(geoCodeScope);
13053    }
13054
13055    @GraphQLField
13056    @GraphQLName("geoCodeScopes")
13057    @GraphQLNonNull
13058    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13059    static CountingPaginatedData<GeoCodeScopeObject> geoCodeScopes(final DataFetchingEnvironment env) {
13060        CountingPaginatedData<GeoCodeScopeObject> data;
13061
13062        try {
13063            var commandForm = GeoUtil.getHome().getGetGeoCodeScopesForm();
13064            var command = CDI.current().select(GetGeoCodeScopesCommand.class).get();
13065
13066            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13067            if(totalEntities == null) {
13068                data = Connections.emptyConnection();
13069            } else {
13070                try(var objectLimiter = new ObjectLimiter(env, GeoCodeScopeConstants.COMPONENT_VENDOR_NAME, GeoCodeScopeConstants.ENTITY_TYPE_NAME, totalEntities)) {
13071                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13072
13073                    var geoCodeScopes = entities.stream()
13074                            .map(GeoCodeScopeObject::new)
13075                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
13076
13077                    data = new CountedObjects<>(objectLimiter, geoCodeScopes);
13078                }
13079            }
13080        } catch (NamingException ex) {
13081            throw new RuntimeException(ex);
13082        }
13083
13084        return data;
13085    }
13086
13087    @GraphQLField
13088    @GraphQLName("geoCode")
13089    static GeoCodeObject geoCode(final DataFetchingEnvironment env,
13090            @GraphQLName("geoCodeName") final String geoCodeName,
13091            @GraphQLName("id") @GraphQLID final String id) {
13092        GeoCode geoCode;
13093
13094        try {
13095            var commandForm = GeoUtil.getHome().getGetGeoCodeForm();
13096
13097            commandForm.setGeoCodeName(geoCodeName);
13098            commandForm.setUuid(id);
13099
13100            geoCode = CDI.current().select(GetGeoCodeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13101        } catch (NamingException ex) {
13102            throw new RuntimeException(ex);
13103        }
13104
13105        return geoCode == null ? null : new GeoCodeObject(geoCode);
13106    }
13107
13108    @GraphQLField
13109    @GraphQLName("geoCodeAlias")
13110    static GeoCodeAliasObject geoCodeAlias(final DataFetchingEnvironment env,
13111            @GraphQLName("geoCodeName") @GraphQLNonNull final String geoCodeName,
13112            @GraphQLName("geoCodeAliasTypeName") @GraphQLNonNull final String geoCodeAliasTypeName) {
13113        GeoCodeAlias geoCodeAlias;
13114
13115        try {
13116            var commandForm = GeoUtil.getHome().getGetGeoCodeAliasForm();
13117
13118            commandForm.setGeoCodeName(geoCodeName);
13119            commandForm.setGeoCodeAliasTypeName(geoCodeAliasTypeName);
13120
13121            geoCodeAlias = CDI.current().select(GetGeoCodeAliasCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13122        } catch (NamingException ex) {
13123            throw new RuntimeException(ex);
13124        }
13125
13126        return geoCodeAlias == null ? null : new GeoCodeAliasObject(geoCodeAlias);
13127    }
13128
13129    @GraphQLField
13130    @GraphQLName("geoCodeAliases")
13131    @GraphQLNonNull
13132    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13133    static CountingPaginatedData<GeoCodeAliasObject> geoCodeAliases(final DataFetchingEnvironment env,
13134            @GraphQLName("geoCodeName") @GraphQLNonNull final String geoCodeName) {
13135        CountingPaginatedData<GeoCodeAliasObject> data;
13136
13137        try {
13138            var commandForm = GeoUtil.getHome().getGetGeoCodeAliasesForm();
13139            var command = CDI.current().select(GetGeoCodeAliasesCommand.class).get();
13140
13141            commandForm.setGeoCodeName(geoCodeName);
13142
13143            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13144            if(totalEntities == null) {
13145                data = Connections.emptyConnection();
13146            } else {
13147                try(var objectLimiter = new ObjectLimiter(env, GeoCodeAliasConstants.COMPONENT_VENDOR_NAME, GeoCodeAliasConstants.ENTITY_TYPE_NAME, totalEntities)) {
13148                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13149
13150                    var geoCodeAliass = entities.stream()
13151                            .map(GeoCodeAliasObject::new)
13152                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
13153
13154                    data = new CountedObjects<>(objectLimiter, geoCodeAliass);
13155                }
13156            }
13157        } catch (NamingException ex) {
13158            throw new RuntimeException(ex);
13159        }
13160
13161        return data;
13162    }
13163
13164    @GraphQLField
13165    @GraphQLName("geoCodeLanguage")
13166    static GeoCodeLanguageObject geoCodeLanguage(final DataFetchingEnvironment env,
13167            @GraphQLName("geoCodeName") @GraphQLNonNull final String geoCodeName,
13168            @GraphQLName("languageIsoName") @GraphQLNonNull final String languageIsoName) {
13169        GeoCodeLanguage geoCodeLanguage;
13170
13171        try {
13172            var commandForm = GeoUtil.getHome().getGetGeoCodeLanguageForm();
13173
13174            commandForm.setGeoCodeName(geoCodeName);
13175            commandForm.setLanguageIsoName(languageIsoName);
13176
13177            geoCodeLanguage = CDI.current().select(GetGeoCodeLanguageCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13178        } catch (NamingException ex) {
13179            throw new RuntimeException(ex);
13180        }
13181
13182        return geoCodeLanguage == null ? null : new GeoCodeLanguageObject(geoCodeLanguage);
13183    }
13184
13185    @GraphQLField
13186    @GraphQLName("geoCodeLanguages")
13187    @GraphQLNonNull
13188    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13189    static CountingPaginatedData<GeoCodeLanguageObject> geoCodeLanguages(final DataFetchingEnvironment env,
13190            @GraphQLName("geoCodeName") final String geoCodeName,
13191            @GraphQLName("languageIsoName") final String languageIsoName) {
13192        CountingPaginatedData<GeoCodeLanguageObject> data;
13193
13194        try {
13195            var commandForm = GeoUtil.getHome().getGetGeoCodeLanguagesForm();
13196            var command = CDI.current().select(GetGeoCodeLanguagesCommand.class).get();
13197
13198            commandForm.setGeoCodeName(geoCodeName);
13199            commandForm.setLanguageIsoName(languageIsoName);
13200
13201            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13202            if(totalEntities == null) {
13203                data = Connections.emptyConnection();
13204            } else {
13205                try(var objectLimiter = new ObjectLimiter(env, GeoCodeLanguageConstants.COMPONENT_VENDOR_NAME, GeoCodeLanguageConstants.ENTITY_TYPE_NAME, totalEntities)) {
13206                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13207
13208                    var transactionTypes = entities.stream()
13209                            .map(GeoCodeLanguageObject::new)
13210                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
13211
13212                    data = new CountedObjects<>(objectLimiter, transactionTypes);
13213                }
13214            }
13215        } catch (NamingException ex) {
13216            throw new RuntimeException(ex);
13217        }
13218
13219        return data;
13220    }
13221
13222    @GraphQLField
13223    @GraphQLName("geoCodeCurrency")
13224    static GeoCodeCurrencyObject geoCodeCurrency(final DataFetchingEnvironment env,
13225            @GraphQLName("geoCodeName") @GraphQLNonNull final String geoCodeName,
13226            @GraphQLName("currencyIsoName") @GraphQLNonNull final String currencyIsoName) {
13227        GeoCodeCurrency geoCodeCurrency;
13228
13229        try {
13230            var commandForm = GeoUtil.getHome().getGetGeoCodeCurrencyForm();
13231
13232            commandForm.setGeoCodeName(geoCodeName);
13233            commandForm.setCurrencyIsoName(currencyIsoName);
13234
13235            geoCodeCurrency = CDI.current().select(GetGeoCodeCurrencyCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13236        } catch (NamingException ex) {
13237            throw new RuntimeException(ex);
13238        }
13239
13240        return geoCodeCurrency == null ? null : new GeoCodeCurrencyObject(geoCodeCurrency);
13241    }
13242
13243    @GraphQLField
13244    @GraphQLName("geoCodeCurrencies")
13245    @GraphQLNonNull
13246    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13247    static CountingPaginatedData<GeoCodeCurrencyObject> geoCodeCurrencies(final DataFetchingEnvironment env,
13248            @GraphQLName("geoCodeName") final String geoCodeName,
13249            @GraphQLName("currencyIsoName") final String currencyIsoName) {
13250        CountingPaginatedData<GeoCodeCurrencyObject> data;
13251
13252        try {
13253            var commandForm = GeoUtil.getHome().getGetGeoCodeCurrenciesForm();
13254            var command = CDI.current().select(GetGeoCodeCurrenciesCommand.class).get();
13255
13256            commandForm.setGeoCodeName(geoCodeName);
13257            commandForm.setCurrencyIsoName(currencyIsoName);
13258
13259            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13260            if(totalEntities == null) {
13261                data = Connections.emptyConnection();
13262            } else {
13263                try(var objectLimiter = new ObjectLimiter(env, GeoCodeCurrencyConstants.COMPONENT_VENDOR_NAME, GeoCodeCurrencyConstants.ENTITY_TYPE_NAME, totalEntities)) {
13264                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13265
13266                    var transactionTypes = entities.stream()
13267                            .map(GeoCodeCurrencyObject::new)
13268                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
13269
13270                    data = new CountedObjects<>(objectLimiter, transactionTypes);
13271                }
13272            }
13273        } catch (NamingException ex) {
13274            throw new RuntimeException(ex);
13275        }
13276
13277        return data;
13278    }
13279
13280    @GraphQLField
13281    @GraphQLName("geoCodeTimeZone")
13282    static GeoCodeTimeZoneObject geoCodeTimeZone(final DataFetchingEnvironment env,
13283            @GraphQLName("geoCodeName") @GraphQLNonNull final String geoCodeName,
13284            @GraphQLName("javaTimeZoneName") @GraphQLNonNull final String javaTimeZoneName) {
13285        GeoCodeTimeZone geoCodeTimeZone;
13286
13287        try {
13288            var commandForm = GeoUtil.getHome().getGetGeoCodeTimeZoneForm();
13289
13290            commandForm.setGeoCodeName(geoCodeName);
13291            commandForm.setJavaTimeZoneName(javaTimeZoneName);
13292
13293            geoCodeTimeZone = CDI.current().select(GetGeoCodeTimeZoneCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13294        } catch (NamingException ex) {
13295            throw new RuntimeException(ex);
13296        }
13297
13298        return geoCodeTimeZone == null ? null : new GeoCodeTimeZoneObject(geoCodeTimeZone);
13299    }
13300
13301    @GraphQLField
13302    @GraphQLName("geoCodeTimeZones")
13303    @GraphQLNonNull
13304    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13305    static CountingPaginatedData<GeoCodeTimeZoneObject> geoCodeTimeZones(final DataFetchingEnvironment env,
13306            @GraphQLName("geoCodeName") final String geoCodeName,
13307            @GraphQLName("javaTimeZoneName") final String javaTimeZoneName) {
13308        CountingPaginatedData<GeoCodeTimeZoneObject> data;
13309
13310        try {
13311            var commandForm = GeoUtil.getHome().getGetGeoCodeTimeZonesForm();
13312            var command = CDI.current().select(GetGeoCodeTimeZonesCommand.class).get();
13313
13314            commandForm.setGeoCodeName(geoCodeName);
13315            commandForm.setJavaTimeZoneName(javaTimeZoneName);
13316
13317            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13318            if(totalEntities == null) {
13319                data = Connections.emptyConnection();
13320            } else {
13321                try(var objectLimiter = new ObjectLimiter(env, GeoCodeTimeZoneConstants.COMPONENT_VENDOR_NAME, GeoCodeTimeZoneConstants.ENTITY_TYPE_NAME, totalEntities)) {
13322                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13323
13324                    var transactionTypes = entities.stream()
13325                            .map(GeoCodeTimeZoneObject::new)
13326                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
13327
13328                    data = new CountedObjects<>(objectLimiter, transactionTypes);
13329                }
13330            }
13331        } catch (NamingException ex) {
13332            throw new RuntimeException(ex);
13333        }
13334
13335        return data;
13336    }
13337
13338    @GraphQLField
13339    @GraphQLName("geoCodeDateTimeFormat")
13340    static GeoCodeDateTimeFormatObject geoCodeDateTimeFormat(final DataFetchingEnvironment env,
13341            @GraphQLName("geoCodeName") @GraphQLNonNull final String geoCodeName,
13342            @GraphQLName("dateTimeFormatName") @GraphQLNonNull final String dateTimeFormatName) {
13343        GeoCodeDateTimeFormat geoCodeDateTimeFormat;
13344
13345        try {
13346            var commandForm = GeoUtil.getHome().getGetGeoCodeDateTimeFormatForm();
13347
13348            commandForm.setGeoCodeName(geoCodeName);
13349            commandForm.setDateTimeFormatName(dateTimeFormatName);
13350
13351            geoCodeDateTimeFormat = CDI.current().select(GetGeoCodeDateTimeFormatCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13352        } catch (NamingException ex) {
13353            throw new RuntimeException(ex);
13354        }
13355
13356        return geoCodeDateTimeFormat == null ? null : new GeoCodeDateTimeFormatObject(geoCodeDateTimeFormat);
13357    }
13358
13359    @GraphQLField
13360    @GraphQLName("geoCodeDateTimeFormats")
13361    @GraphQLNonNull
13362    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13363    static CountingPaginatedData<GeoCodeDateTimeFormatObject> geoCodeDateTimeFormats(final DataFetchingEnvironment env,
13364            @GraphQLName("geoCodeName") final String geoCodeName,
13365            @GraphQLName("dateTimeFormatName") final String dateTimeFormatName) {
13366        CountingPaginatedData<GeoCodeDateTimeFormatObject> data;
13367
13368        try {
13369            var commandForm = GeoUtil.getHome().getGetGeoCodeDateTimeFormatsForm();
13370            var command = CDI.current().select(GetGeoCodeDateTimeFormatsCommand.class).get();
13371
13372            commandForm.setGeoCodeName(geoCodeName);
13373            commandForm.setDateTimeFormatName(dateTimeFormatName);
13374
13375            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13376            if(totalEntities == null) {
13377                data = Connections.emptyConnection();
13378            } else {
13379                try(var objectLimiter = new ObjectLimiter(env, GeoCodeDateTimeFormatConstants.COMPONENT_VENDOR_NAME, GeoCodeDateTimeFormatConstants.ENTITY_TYPE_NAME, totalEntities)) {
13380                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13381
13382                    var transactionTypes = entities.stream()
13383                            .map(GeoCodeDateTimeFormatObject::new)
13384                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
13385
13386                    data = new CountedObjects<>(objectLimiter, transactionTypes);
13387                }
13388            }
13389        } catch (NamingException ex) {
13390            throw new RuntimeException(ex);
13391        }
13392
13393        return data;
13394    }
13395
13396    @GraphQLField
13397    @GraphQLName("country")
13398    static GeoCodeObject country(final DataFetchingEnvironment env,
13399            @GraphQLName("geoCodeName") final String geoCodeName,
13400            @GraphQLName("countryName") final String countryName,
13401            @GraphQLName("iso3Number") final String iso3Number,
13402            @GraphQLName("iso3Letter") final String iso3Letter,
13403            @GraphQLName("iso2Letter") final String iso2Letter,
13404            @GraphQLName("alias") final String alias) {
13405        GeoCode geoCode;
13406
13407        try {
13408            var commandForm = GeoUtil.getHome().getGetCountryForm();
13409
13410            commandForm.setGeoCodeName(geoCodeName);
13411            commandForm.setCountryName(countryName);
13412            commandForm.setIso3Number(iso3Number);
13413            commandForm.setIso3Letter(iso3Letter);
13414            commandForm.setIso2Letter(iso2Letter);
13415            commandForm.setAlias(alias);
13416
13417            geoCode = CDI.current().select(GetCountryCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13418        } catch (NamingException ex) {
13419            throw new RuntimeException(ex);
13420        }
13421
13422        return geoCode == null ? null : new GeoCodeObject(geoCode);
13423    }
13424
13425    @GraphQLField
13426    @GraphQLName("countries")
13427    @GraphQLNonNull
13428    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13429    static CountingPaginatedData<GeoCodeObject> countries(final DataFetchingEnvironment env) {
13430        CountingPaginatedData<GeoCodeObject> data;
13431
13432        try {
13433            var commandForm = GeoUtil.getHome().getGetCountriesForm();
13434            var command = CDI.current().select(GetCountriesCommand.class).get();
13435
13436            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13437            if(totalEntities == null) {
13438                data = Connections.emptyConnection();
13439            } else {
13440                try(var objectLimiter = new ObjectLimiter(env, GeoCodeConstants.COMPONENT_VENDOR_NAME, GeoCodeConstants.ENTITY_TYPE_NAME, totalEntities)) {
13441                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13442
13443                    var geoCodeAliasTypes = entities.stream()
13444                            .map(GeoCodeObject::new)
13445                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
13446
13447                    data = new CountedObjects<>(objectLimiter, geoCodeAliasTypes);
13448                }
13449            }
13450        } catch (NamingException ex) {
13451            throw new RuntimeException(ex);
13452        }
13453
13454        return data;
13455    }
13456
13457    @GraphQLField
13458    @GraphQLName("zipCode")
13459    static GeoCodeObject zipCode(final DataFetchingEnvironment env,
13460            @GraphQLName("countryGeoCodeName") @GraphQLNonNull final String countryGeoCodeName,
13461            @GraphQLName("zipCodeName") @GraphQLNonNull final String zipCodeName) {
13462        GeoCode geoCode;
13463
13464        try {
13465            var commandForm = GeoUtil.getHome().getGetZipCodeForm();
13466
13467            commandForm.setCountryGeoCodeName(countryGeoCodeName);
13468            commandForm.setZipCodeName(zipCodeName);
13469
13470            geoCode = CDI.current().select(GetZipCodeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13471        } catch (NamingException ex) {
13472            throw new RuntimeException(ex);
13473        }
13474
13475        return geoCode == null ? null : new GeoCodeObject(geoCode);
13476    }
13477
13478    @GraphQLField
13479    @GraphQLName("zipCodes")
13480    @GraphQLNonNull
13481    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13482    static CountingPaginatedData<GeoCodeObject> zipCodes(final DataFetchingEnvironment env,
13483            @GraphQLName("countryName") @GraphQLNonNull final String countryName) {
13484        CountingPaginatedData<GeoCodeObject> data;
13485
13486        try {
13487            var commandForm = GeoUtil.getHome().getGetZipCodesForm();
13488            var command = CDI.current().select(GetZipCodesCommand.class).get();
13489
13490            commandForm.setCountryName(countryName);
13491
13492            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13493            if(totalEntities == null) {
13494                data = Connections.emptyConnection();
13495            } else {
13496                try(var objectLimiter = new ObjectLimiter(env, GeoCodeConstants.COMPONENT_VENDOR_NAME, GeoCodeConstants.ENTITY_TYPE_NAME, totalEntities)) {
13497                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13498
13499                    var geoCodeAliasTypes = entities.stream()
13500                            .map(GeoCodeObject::new)
13501                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
13502
13503                    data = new CountedObjects<>(objectLimiter, geoCodeAliasTypes);
13504                }
13505            }
13506        } catch (NamingException ex) {
13507            throw new RuntimeException(ex);
13508        }
13509
13510        return data;
13511    }
13512
13513    @GraphQLField
13514    @GraphQLName("state")
13515    static GeoCodeObject state(final DataFetchingEnvironment env,
13516            @GraphQLName("countryGeoCodeName") @GraphQLNonNull final String countryGeoCodeName,
13517            @GraphQLName("stateName") final String stateName,
13518            @GraphQLName("postal2Letter") final String postal2Letter) {
13519        GeoCode geoCode;
13520
13521        try {
13522            var commandForm = GeoUtil.getHome().getGetStateForm();
13523
13524            commandForm.setCountryGeoCodeName(countryGeoCodeName);
13525            commandForm.setStateName(stateName);
13526            commandForm.setPostal2Letter(postal2Letter);
13527
13528            geoCode = CDI.current().select(GetStateCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13529        } catch (NamingException ex) {
13530            throw new RuntimeException(ex);
13531        }
13532
13533        return geoCode == null ? null : new GeoCodeObject(geoCode);
13534    }
13535
13536    @GraphQLField
13537    @GraphQLName("states")
13538    @GraphQLNonNull
13539    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13540    static CountingPaginatedData<GeoCodeObject> states(final DataFetchingEnvironment env,
13541            @GraphQLName("countryName") @GraphQLNonNull final String countryName) {
13542        CountingPaginatedData<GeoCodeObject> data;
13543
13544        try {
13545            var commandForm = GeoUtil.getHome().getGetStatesForm();
13546            var command = CDI.current().select(GetStatesCommand.class).get();
13547
13548            commandForm.setCountryName(countryName);
13549
13550            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13551            if(totalEntities == null) {
13552                data = Connections.emptyConnection();
13553            } else {
13554                try(var objectLimiter = new ObjectLimiter(env, GeoCodeConstants.COMPONENT_VENDOR_NAME, GeoCodeConstants.ENTITY_TYPE_NAME, totalEntities)) {
13555                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13556
13557                    var geoCodeAliasTypes = entities.stream()
13558                            .map(GeoCodeObject::new)
13559                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
13560
13561                    data = new CountedObjects<>(objectLimiter, geoCodeAliasTypes);
13562                }
13563            }
13564        } catch (NamingException ex) {
13565            throw new RuntimeException(ex);
13566        }
13567
13568        return data;
13569    }
13570
13571    @GraphQLField
13572    @GraphQLName("county")
13573    static GeoCodeObject county(final DataFetchingEnvironment env,
13574            @GraphQLName("stateGeoCodeName") @GraphQLNonNull final String stateGeoCodeName,
13575            @GraphQLName("countyName") final String countyName,
13576            @GraphQLName("countyNumber") final String countyNumber) {
13577        GeoCode geoCode;
13578
13579        try {
13580            var commandForm = GeoUtil.getHome().getGetCountyForm();
13581
13582            commandForm.setStateGeoCodeName(stateGeoCodeName);
13583            commandForm.setCountyName(countyName);
13584            commandForm.setCountyNumber(countyNumber);
13585
13586            geoCode = CDI.current().select(GetCountyCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13587        } catch (NamingException ex) {
13588            throw new RuntimeException(ex);
13589        }
13590
13591        return geoCode == null ? null : new GeoCodeObject(geoCode);
13592    }
13593
13594    @GraphQLField
13595    @GraphQLName("counties")
13596    @GraphQLNonNull
13597    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13598    static CountingPaginatedData<GeoCodeObject> counties(final DataFetchingEnvironment env,
13599            @GraphQLName("countryName") @GraphQLNonNull final String countryName,
13600            @GraphQLName("stateName") @GraphQLNonNull final String stateName) {
13601        CountingPaginatedData<GeoCodeObject> data;
13602
13603        try {
13604            var commandForm = GeoUtil.getHome().getGetCountiesForm();
13605            var command = CDI.current().select(GetCountiesCommand.class).get();
13606
13607            commandForm.setCountryName(countryName);
13608            commandForm.setStateName(stateName);
13609
13610            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13611            if(totalEntities == null) {
13612                data = Connections.emptyConnection();
13613            } else {
13614                try(var objectLimiter = new ObjectLimiter(env, GeoCodeConstants.COMPONENT_VENDOR_NAME, GeoCodeConstants.ENTITY_TYPE_NAME, totalEntities)) {
13615                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13616
13617                    var geoCodeAliasTypes = entities.stream()
13618                            .map(GeoCodeObject::new)
13619                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
13620
13621                    data = new CountedObjects<>(objectLimiter, geoCodeAliasTypes);
13622                }
13623            }
13624        } catch (NamingException ex) {
13625            throw new RuntimeException(ex);
13626        }
13627
13628        return data;
13629    }
13630
13631    @GraphQLField
13632    @GraphQLName("city")
13633    static GeoCodeObject city(final DataFetchingEnvironment env,
13634            @GraphQLName("stateGeoCodeName") @GraphQLNonNull final String stateGeoCodeName,
13635            @GraphQLName("cityName") @GraphQLNonNull final String cityName) {
13636        GeoCode geoCode;
13637
13638        try {
13639            var commandForm = GeoUtil.getHome().getGetCityForm();
13640
13641            commandForm.setStateGeoCodeName(stateGeoCodeName);
13642            commandForm.setCityName(cityName);
13643
13644            geoCode = CDI.current().select(GetCityCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13645        } catch (NamingException ex) {
13646            throw new RuntimeException(ex);
13647        }
13648
13649        return geoCode == null ? null : new GeoCodeObject(geoCode);
13650    }
13651
13652    @GraphQLField
13653    @GraphQLName("cities")
13654    @GraphQLNonNull
13655    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13656    static CountingPaginatedData<GeoCodeObject> cities(final DataFetchingEnvironment env,
13657            @GraphQLName("countryName") @GraphQLNonNull final String countryName,
13658            @GraphQLName("stateName") @GraphQLNonNull final String stateName) {
13659        CountingPaginatedData<GeoCodeObject> data;
13660
13661        try {
13662            var commandForm = GeoUtil.getHome().getGetCitiesForm();
13663            var command = CDI.current().select(GetCitiesCommand.class).get();
13664
13665            commandForm.setCountryName(countryName);
13666            commandForm.setStateName(stateName);
13667
13668            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13669            if(totalEntities == null) {
13670                data = Connections.emptyConnection();
13671            } else {
13672                try(var objectLimiter = new ObjectLimiter(env, GeoCodeConstants.COMPONENT_VENDOR_NAME, GeoCodeConstants.ENTITY_TYPE_NAME, totalEntities)) {
13673                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13674
13675                    var geoCodeAliasTypes = entities.stream()
13676                            .map(GeoCodeObject::new)
13677                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
13678
13679                    data = new CountedObjects<>(objectLimiter, geoCodeAliasTypes);
13680                }
13681            }
13682        } catch (NamingException ex) {
13683            throw new RuntimeException(ex);
13684        }
13685
13686        return data;
13687    }
13688
13689    @GraphQLField
13690    @GraphQLName("shippingMethod")
13691    static ShippingMethodObject shippingMethod(final DataFetchingEnvironment env,
13692            @GraphQLName("shippingMethodName") final String shippingMethodName,
13693            @GraphQLName("id") @GraphQLID final String id) {
13694        ShippingMethod shippingMethod;
13695
13696        try {
13697            var commandForm = ShippingUtil.getHome().getGetShippingMethodForm();
13698
13699            commandForm.setShippingMethodName(shippingMethodName);
13700            commandForm.setUuid(id);
13701
13702            shippingMethod = CDI.current().select(GetShippingMethodCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13703        } catch (NamingException ex) {
13704            throw new RuntimeException(ex);
13705        }
13706
13707        return shippingMethod == null ? null : new ShippingMethodObject(shippingMethod);
13708    }
13709
13710    @GraphQLField
13711    @GraphQLName("shippingMethods")
13712    @GraphQLNonNull
13713    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13714    static CountingPaginatedData<ShippingMethodObject> shippingMethods(final DataFetchingEnvironment env) {
13715        CountingPaginatedData<ShippingMethodObject> data;
13716
13717        try {
13718            var shippingControl = Session.getModelController(ShippingControl.class);
13719            var totalCount = shippingControl.countShippingMethods();
13720
13721            try(var objectLimiter = new ObjectLimiter(env, ShippingMethodConstants.COMPONENT_VENDOR_NAME, ShippingMethodConstants.ENTITY_TYPE_NAME, totalCount)) {
13722                var commandForm = ShippingUtil.getHome().getGetShippingMethodsForm();
13723                var entities = CDI.current().select(GetShippingMethodsCommand.class).get().getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13724
13725                if(entities == null) {
13726                    data = Connections.emptyConnection();
13727                } else {
13728                    var shippingMethods = entities.stream().map(ShippingMethodObject::new).collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
13729
13730                    data = new CountedObjects<>(objectLimiter, shippingMethods);
13731                }
13732            }
13733        } catch (NamingException ex) {
13734            throw new RuntimeException(ex);
13735        }
13736
13737        return data;
13738    }
13739
13740    @GraphQLField
13741    @GraphQLName("transactionTimeType")
13742    static TransactionTimeTypeObject transactionTimeType(final DataFetchingEnvironment env,
13743            @GraphQLName("transactionTimeTypeName") final String transactionTimeTypeName,
13744            @GraphQLName("id") @GraphQLID final String id) {
13745        TransactionTimeType transactionTimeType;
13746
13747        try {
13748            var commandForm = AccountingUtil.getHome().getGetTransactionTimeTypeForm();
13749
13750            commandForm.setTransactionTimeTypeName(transactionTimeTypeName);
13751            commandForm.setUuid(id);
13752
13753            transactionTimeType = CDI.current().select(GetTransactionTimeTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13754        } catch (NamingException ex) {
13755            throw new RuntimeException(ex);
13756        }
13757
13758        return transactionTimeType == null ? null : new TransactionTimeTypeObject(transactionTimeType);
13759    }
13760
13761    @GraphQLField
13762    @GraphQLName("transactionTimeTypes")
13763    @GraphQLNonNull
13764    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13765    static CountingPaginatedData<TransactionTimeTypeObject> transactionTimeTypes(final DataFetchingEnvironment env) {
13766        CountingPaginatedData<TransactionTimeTypeObject> data;
13767
13768        try {
13769            var commandForm = AccountingUtil.getHome().getGetTransactionTimeTypesForm();
13770            var command = CDI.current().select(GetTransactionTimeTypesCommand.class).get();
13771
13772            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13773            if(totalEntities == null) {
13774                data = Connections.emptyConnection();
13775            } else {
13776                try(var objectLimiter = new ObjectLimiter(env, TransactionTimeTypeConstants.COMPONENT_VENDOR_NAME, TransactionTimeTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
13777                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13778
13779                    var transactionTimeTypes = entities.stream()
13780                            .map(TransactionTimeTypeObject::new)
13781                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
13782
13783                    data = new CountedObjects<>(objectLimiter, transactionTimeTypes);
13784                }
13785            }
13786        } catch (NamingException ex) {
13787            throw new RuntimeException(ex);
13788        }
13789
13790        return data;
13791    }
13792
13793    @GraphQLField
13794    @GraphQLName("transactionType")
13795    static TransactionTypeObject transactionType(final DataFetchingEnvironment env,
13796            @GraphQLName("transactionTypeName") final String transactionTypeName,
13797            @GraphQLName("id") @GraphQLID final String id) {
13798        TransactionType transactionType;
13799
13800        try {
13801            var commandForm = AccountingUtil.getHome().getGetTransactionTypeForm();
13802
13803            commandForm.setTransactionTypeName(transactionTypeName);
13804            commandForm.setUuid(id);
13805
13806            transactionType = CDI.current().select(GetTransactionTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13807        } catch (NamingException ex) {
13808            throw new RuntimeException(ex);
13809        }
13810
13811        return transactionType == null ? null : new TransactionTypeObject(transactionType);
13812    }
13813
13814    @GraphQLField
13815    @GraphQLName("transactionTypes")
13816    @GraphQLNonNull
13817    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13818    static CountingPaginatedData<TransactionTypeObject> transactionTypes(final DataFetchingEnvironment env) {
13819        CountingPaginatedData<TransactionTypeObject> data;
13820
13821        try {
13822            var commandForm = AccountingUtil.getHome().getGetTransactionTypesForm();
13823            var command = CDI.current().select(GetTransactionTypesCommand.class).get();
13824
13825            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13826            if(totalEntities == null) {
13827                data = Connections.emptyConnection();
13828            } else {
13829                try(var objectLimiter = new ObjectLimiter(env, TransactionTypeConstants.COMPONENT_VENDOR_NAME, TransactionTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
13830                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13831
13832                    var transactionTypes = entities.stream()
13833                            .map(TransactionTypeObject::new)
13834                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
13835
13836                    data = new CountedObjects<>(objectLimiter, transactionTypes);
13837                }
13838            }
13839        } catch (NamingException ex) {
13840            throw new RuntimeException(ex);
13841        }
13842
13843        return data;
13844    }
13845
13846    @GraphQLField
13847    @GraphQLName("transactionGlAccountCategory")
13848    static TransactionGlAccountCategoryObject transactionGlAccountCategory(final DataFetchingEnvironment env,
13849            @GraphQLName("transactionTypeName") final String transactionTypeName,
13850            @GraphQLName("transactionGlAccountCategoryName") final String transactionGlAccountCategoryName,
13851            @GraphQLName("id") @GraphQLID final String id) {
13852        TransactionGlAccountCategory transactionGlAccountCategory;
13853
13854        try {
13855            var commandForm = AccountingUtil.getHome().getGetTransactionGlAccountCategoryForm();
13856
13857            commandForm.setTransactionTypeName(transactionTypeName);
13858            commandForm.setTransactionGlAccountCategoryName(transactionGlAccountCategoryName);
13859            commandForm.setUuid(id);
13860
13861            transactionGlAccountCategory = CDI.current().select(GetTransactionGlAccountCategoryCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13862        } catch (NamingException ex) {
13863            throw new RuntimeException(ex);
13864        }
13865
13866        return transactionGlAccountCategory == null ? null : new TransactionGlAccountCategoryObject(transactionGlAccountCategory);
13867    }
13868
13869    @GraphQLField
13870    @GraphQLName("transactionGlAccountCategories")
13871    @GraphQLNonNull
13872    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13873    static CountingPaginatedData<TransactionGlAccountCategoryObject> transactionGlAccountCategories(final DataFetchingEnvironment env,
13874            @GraphQLName("transactionTypeName") final String transactionTypeName) {
13875        CountingPaginatedData<TransactionGlAccountCategoryObject> data;
13876
13877        try {
13878            var commandForm = AccountingUtil.getHome().getGetTransactionGlAccountCategoriesForm();
13879            var command = CDI.current().select(GetTransactionGlAccountCategoriesCommand.class).get();
13880
13881            commandForm.setTransactionTypeName(transactionTypeName);
13882
13883            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13884            if(totalEntities == null) {
13885                data = Connections.emptyConnection();
13886            } else {
13887                try(var objectLimiter = new ObjectLimiter(env, TransactionGlAccountCategoryConstants.COMPONENT_VENDOR_NAME, TransactionGlAccountCategoryConstants.ENTITY_TYPE_NAME, totalEntities)) {
13888                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13889
13890                    var transactionGlAccountCategories = entities.stream()
13891                            .map(TransactionGlAccountCategoryObject::new)
13892                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
13893
13894                    data = new CountedObjects<>(objectLimiter, transactionGlAccountCategories);
13895                }
13896            }
13897        } catch (NamingException ex) {
13898            throw new RuntimeException(ex);
13899        }
13900
13901        return data;
13902    }
13903
13904    @GraphQLField
13905    @GraphQLName("transactionEntityRoleType")
13906    static TransactionEntityRoleTypeObject transactionEntityRoleType(final DataFetchingEnvironment env,
13907            @GraphQLName("transactionTypeName") final String transactionTypeName,
13908            @GraphQLName("transactionEntityRoleTypeName") final String transactionEntityRoleTypeName,
13909            @GraphQLName("id") @GraphQLID final String id) {
13910        TransactionEntityRoleType transactionEntityRoleType;
13911
13912        try {
13913            var commandForm = AccountingUtil.getHome().getGetTransactionEntityRoleTypeForm();
13914
13915            commandForm.setTransactionTypeName(transactionTypeName);
13916            commandForm.setTransactionEntityRoleTypeName(transactionEntityRoleTypeName);
13917            commandForm.setUuid(id);
13918
13919            transactionEntityRoleType = CDI.current().select(GetTransactionEntityRoleTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13920        } catch (NamingException ex) {
13921            throw new RuntimeException(ex);
13922        }
13923
13924        return transactionEntityRoleType == null ? null : new TransactionEntityRoleTypeObject(transactionEntityRoleType);
13925    }
13926
13927    @GraphQLField
13928    @GraphQLName("transactionEntityRoleTypes")
13929    @GraphQLNonNull
13930    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13931    static CountingPaginatedData<TransactionEntityRoleTypeObject> transactionEntityRoleTypes(final DataFetchingEnvironment env,
13932            @GraphQLName("transactionTypeName") final String transactionTypeName) {
13933        CountingPaginatedData<TransactionEntityRoleTypeObject> data;
13934
13935        try {
13936            var commandForm = AccountingUtil.getHome().getGetTransactionEntityRoleTypesForm();
13937            var command = CDI.current().select(GetTransactionEntityRoleTypesCommand.class).get();
13938
13939            commandForm.setTransactionTypeName(transactionTypeName);
13940
13941            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13942            if(totalEntities == null) {
13943                data = Connections.emptyConnection();
13944            } else {
13945                try(var objectLimiter = new ObjectLimiter(env, TransactionEntityRoleTypeConstants.COMPONENT_VENDOR_NAME, TransactionEntityRoleTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
13946                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13947
13948                    var transactionEntityRoleTypes = entities.stream()
13949                            .map(TransactionEntityRoleTypeObject::new)
13950                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
13951
13952                    data = new CountedObjects<>(objectLimiter, transactionEntityRoleTypes);
13953                }
13954            }
13955        } catch (NamingException ex) {
13956            throw new RuntimeException(ex);
13957        }
13958
13959        return data;
13960    }
13961
13962    @GraphQLField
13963    @GraphQLName("transactionGroup")
13964    static TransactionGroupObject transactionGroup(final DataFetchingEnvironment env,
13965            @GraphQLName("transactionGroupName") final String transactionGroupName,
13966            @GraphQLName("id") @GraphQLID final String id) {
13967        TransactionGroup transactionGroup;
13968
13969        try {
13970            var commandForm = AccountingUtil.getHome().getGetTransactionGroupForm();
13971
13972            commandForm.setTransactionGroupName(transactionGroupName);
13973            commandForm.setUuid(id);
13974
13975            transactionGroup = CDI.current().select(GetTransactionGroupCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
13976        } catch (NamingException ex) {
13977            throw new RuntimeException(ex);
13978        }
13979
13980        return transactionGroup == null ? null : new TransactionGroupObject(transactionGroup);
13981    }
13982
13983    @GraphQLField
13984    @GraphQLName("transactionGroups")
13985    @GraphQLNonNull
13986    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
13987    static CountingPaginatedData<TransactionGroupObject> transactionGroups(final DataFetchingEnvironment env) {
13988        CountingPaginatedData<TransactionGroupObject> data;
13989
13990        try {
13991            var commandForm = AccountingUtil.getHome().getGetTransactionGroupsForm();
13992            var command = CDI.current().select(GetTransactionGroupsCommand.class).get();
13993
13994            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
13995            if(totalEntities == null) {
13996                data = Connections.emptyConnection();
13997            } else {
13998                try(var objectLimiter = new ObjectLimiter(env, TransactionGroupConstants.COMPONENT_VENDOR_NAME, TransactionGroupConstants.ENTITY_TYPE_NAME, totalEntities)) {
13999                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14000
14001                    var transactionGroups = entities.stream()
14002                            .map(TransactionGroupObject::new)
14003                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14004
14005                    data = new CountedObjects<>(objectLimiter, transactionGroups);
14006                }
14007            }
14008        } catch (NamingException ex) {
14009            throw new RuntimeException(ex);
14010        }
14011
14012        return data;
14013    }
14014
14015    @GraphQLField
14016    @GraphQLName("transaction")
14017    static TransactionObject transaction(final DataFetchingEnvironment env,
14018            @GraphQLName("transactionName") final String transactionName,
14019            @GraphQLName("id") @GraphQLID final String id) {
14020        Transaction transaction;
14021
14022        try {
14023            var commandForm = AccountingUtil.getHome().getGetTransactionForm();
14024
14025            commandForm.setTransactionName(transactionName);
14026            commandForm.setUuid(id);
14027
14028            transaction = CDI.current().select(GetTransactionCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
14029        } catch (NamingException ex) {
14030            throw new RuntimeException(ex);
14031        }
14032
14033        return transaction == null ? null : new TransactionObject(transaction);
14034    }
14035
14036    @GraphQLField
14037    @GraphQLName("transactions")
14038    @GraphQLNonNull
14039    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
14040    static CountingPaginatedData<TransactionObject> transactions(final DataFetchingEnvironment env,
14041            @GraphQLName("transactionGroupName") final String transactionGroupName) {
14042        CountingPaginatedData<TransactionObject> data;
14043
14044        try {
14045            var commandForm = AccountingUtil.getHome().getGetTransactionsForm();
14046            var command = CDI.current().select(GetTransactionsCommand.class).get();
14047
14048            commandForm.setTransactionGroupName(transactionGroupName);
14049
14050            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14051            if(totalEntities == null) {
14052                data = Connections.emptyConnection();
14053            } else {
14054                try(var objectLimiter = new ObjectLimiter(env, TransactionConstants.COMPONENT_VENDOR_NAME, TransactionConstants.ENTITY_TYPE_NAME, totalEntities)) {
14055                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14056
14057                    var transactions = entities.stream()
14058                            .map(TransactionObject::new)
14059                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14060
14061                    data = new CountedObjects<>(objectLimiter, transactions);
14062                }
14063            }
14064        } catch (NamingException ex) {
14065            throw new RuntimeException(ex);
14066        }
14067
14068        return data;
14069    }
14070
14071    @GraphQLField
14072    @GraphQLName("campaign")
14073    static CampaignObject campaign(final DataFetchingEnvironment env,
14074            @GraphQLName("campaignName") final String campaignName,
14075            @GraphQLName("id") @GraphQLID final String id) {
14076        Campaign campaign;
14077
14078        try {
14079            var commandForm = CampaignUtil.getHome().getGetCampaignForm();
14080
14081            commandForm.setCampaignName(campaignName);
14082            commandForm.setUuid(id);
14083
14084            campaign = CDI.current().select(GetCampaignCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
14085        } catch (NamingException ex) {
14086            throw new RuntimeException(ex);
14087        }
14088
14089        return campaign == null ? null : new CampaignObject(campaign);
14090    }
14091
14092    @GraphQLField
14093    @GraphQLName("campaigns")
14094    @GraphQLNonNull
14095    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
14096    static CountingPaginatedData<CampaignObject> campaigns(final DataFetchingEnvironment env) {
14097        CountingPaginatedData<CampaignObject> data;
14098
14099        try {
14100            var commandForm = CampaignUtil.getHome().getGetCampaignsForm();
14101            var command = CDI.current().select(GetCampaignsCommand.class).get();
14102
14103            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14104            if(totalEntities == null) {
14105                data = Connections.emptyConnection();
14106            } else {
14107                try(var objectLimiter = new ObjectLimiter(env, CampaignConstants.COMPONENT_VENDOR_NAME, CampaignConstants.ENTITY_TYPE_NAME, totalEntities)) {
14108                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14109
14110                    var campaigns = entities.stream()
14111                            .map(CampaignObject::new)
14112                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14113
14114                    data = new CountedObjects<>(objectLimiter, campaigns);
14115                }
14116            }
14117        } catch (NamingException ex) {
14118            throw new RuntimeException(ex);
14119        }
14120
14121        return data;
14122    }
14123
14124    @GraphQLField
14125    @GraphQLName("campaignContent")
14126    static CampaignContentObject campaignContent(final DataFetchingEnvironment env,
14127            @GraphQLName("campaignContentName") final String campaignContentName,
14128            @GraphQLName("id") @GraphQLID final String id) {
14129        CampaignContent campaignContent;
14130
14131        try {
14132            var commandForm = CampaignUtil.getHome().getGetCampaignContentForm();
14133
14134            commandForm.setCampaignContentName(campaignContentName);
14135            commandForm.setUuid(id);
14136
14137            campaignContent = CDI.current().select(GetCampaignContentCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
14138        } catch (NamingException ex) {
14139            throw new RuntimeException(ex);
14140        }
14141
14142        return campaignContent == null ? null : new CampaignContentObject(campaignContent);
14143    }
14144
14145    @GraphQLField
14146    @GraphQLName("campaignContents")
14147    @GraphQLNonNull
14148    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
14149    static CountingPaginatedData<CampaignContentObject> campaignContents(final DataFetchingEnvironment env) {
14150        CountingPaginatedData<CampaignContentObject> data;
14151
14152        try {
14153            var commandForm = CampaignUtil.getHome().getGetCampaignContentsForm();
14154            var command = CDI.current().select(GetCampaignContentsCommand.class).get();
14155
14156            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14157            if(totalEntities == null) {
14158                data = Connections.emptyConnection();
14159            } else {
14160                try(var objectLimiter = new ObjectLimiter(env, CampaignContentConstants.COMPONENT_VENDOR_NAME, CampaignContentConstants.ENTITY_TYPE_NAME, totalEntities)) {
14161                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14162
14163                    var campaignContents = entities.stream()
14164                            .map(CampaignContentObject::new)
14165                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14166
14167                    data = new CountedObjects<>(objectLimiter, campaignContents);
14168                }
14169            }
14170        } catch (NamingException ex) {
14171            throw new RuntimeException(ex);
14172        }
14173
14174        return data;
14175    }
14176
14177    @GraphQLField
14178    @GraphQLName("campaignMedium")
14179    static CampaignMediumObject campaignMedium(final DataFetchingEnvironment env,
14180            @GraphQLName("campaignMediumName") final String campaignMediumName,
14181            @GraphQLName("id") @GraphQLID final String id) {
14182        CampaignMedium campaignMedium;
14183
14184        try {
14185            var commandForm = CampaignUtil.getHome().getGetCampaignMediumForm();
14186
14187            commandForm.setCampaignMediumName(campaignMediumName);
14188            commandForm.setUuid(id);
14189
14190            campaignMedium = CDI.current().select(GetCampaignMediumCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
14191        } catch (NamingException ex) {
14192            throw new RuntimeException(ex);
14193        }
14194
14195        return campaignMedium == null ? null : new CampaignMediumObject(campaignMedium);
14196    }
14197
14198    @GraphQLField
14199    @GraphQLName("campaignMediums")
14200    @GraphQLNonNull
14201    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
14202    static CountingPaginatedData<CampaignMediumObject> campaignMediums(final DataFetchingEnvironment env) {
14203        CountingPaginatedData<CampaignMediumObject> data;
14204
14205        try {
14206            var commandForm = CampaignUtil.getHome().getGetCampaignMediumsForm();
14207            var command = CDI.current().select(GetCampaignMediumsCommand.class).get();
14208
14209            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14210            if(totalEntities == null) {
14211                data = Connections.emptyConnection();
14212            } else {
14213                try(var objectLimiter = new ObjectLimiter(env, CampaignMediumConstants.COMPONENT_VENDOR_NAME, CampaignMediumConstants.ENTITY_TYPE_NAME, totalEntities)) {
14214                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14215
14216                    var campaignMediums = entities.stream()
14217                            .map(CampaignMediumObject::new)
14218                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14219
14220                    data = new CountedObjects<>(objectLimiter, campaignMediums);
14221                }
14222            }
14223        } catch (NamingException ex) {
14224            throw new RuntimeException(ex);
14225        }
14226
14227        return data;
14228    }
14229
14230    @GraphQLField
14231    @GraphQLName("campaignTerm")
14232    static CampaignTermObject campaignTerm(final DataFetchingEnvironment env,
14233            @GraphQLName("campaignTermName") final String campaignTermName,
14234            @GraphQLName("id") @GraphQLID final String id) {
14235        CampaignTerm campaignTerm;
14236
14237        try {
14238            var commandForm = CampaignUtil.getHome().getGetCampaignTermForm();
14239
14240            commandForm.setCampaignTermName(campaignTermName);
14241            commandForm.setUuid(id);
14242
14243            campaignTerm = CDI.current().select(GetCampaignTermCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
14244        } catch (NamingException ex) {
14245            throw new RuntimeException(ex);
14246        }
14247
14248        return campaignTerm == null ? null : new CampaignTermObject(campaignTerm);
14249    }
14250
14251    @GraphQLField
14252    @GraphQLName("campaignTerms")
14253    @GraphQLNonNull
14254    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
14255    static CountingPaginatedData<CampaignTermObject> campaignTerms(final DataFetchingEnvironment env) {
14256        CountingPaginatedData<CampaignTermObject> data;
14257
14258        try {
14259            var commandForm = CampaignUtil.getHome().getGetCampaignTermsForm();
14260            var command = CDI.current().select(GetCampaignTermsCommand.class).get();
14261
14262            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14263            if(totalEntities == null) {
14264                data = Connections.emptyConnection();
14265            } else {
14266                try(var objectLimiter = new ObjectLimiter(env, CampaignTermConstants.COMPONENT_VENDOR_NAME, CampaignTermConstants.ENTITY_TYPE_NAME, totalEntities)) {
14267                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14268
14269                    var campaignTerms = entities.stream()
14270                            .map(CampaignTermObject::new)
14271                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14272
14273                    data = new CountedObjects<>(objectLimiter, campaignTerms);
14274                }
14275            }
14276        } catch (NamingException ex) {
14277            throw new RuntimeException(ex);
14278        }
14279
14280        return data;
14281    }
14282
14283    @GraphQLField
14284    @GraphQLName("campaignSource")
14285    static CampaignSourceObject campaignSource(final DataFetchingEnvironment env,
14286            @GraphQLName("campaignSourceName") final String campaignSourceName,
14287            @GraphQLName("id") @GraphQLID final String id) {
14288        CampaignSource campaignSource;
14289
14290        try {
14291            var commandForm = CampaignUtil.getHome().getGetCampaignSourceForm();
14292
14293            commandForm.setCampaignSourceName(campaignSourceName);
14294            commandForm.setUuid(id);
14295
14296            campaignSource = CDI.current().select(GetCampaignSourceCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
14297        } catch (NamingException ex) {
14298            throw new RuntimeException(ex);
14299        }
14300
14301        return campaignSource == null ? null : new CampaignSourceObject(campaignSource);
14302    }
14303
14304    @GraphQLField
14305    @GraphQLName("campaignSources")
14306    @GraphQLNonNull
14307    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
14308    static CountingPaginatedData<CampaignSourceObject> campaignSources(final DataFetchingEnvironment env) {
14309        CountingPaginatedData<CampaignSourceObject> data;
14310
14311        try {
14312            var commandForm = CampaignUtil.getHome().getGetCampaignSourcesForm();
14313            var command = CDI.current().select(GetCampaignSourcesCommand.class).get();
14314
14315            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14316            if(totalEntities == null) {
14317                data = Connections.emptyConnection();
14318            } else {
14319                try(var objectLimiter = new ObjectLimiter(env, CampaignSourceConstants.COMPONENT_VENDOR_NAME, CampaignSourceConstants.ENTITY_TYPE_NAME, totalEntities)) {
14320                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14321
14322                    var campaignSources = entities.stream()
14323                            .map(CampaignSourceObject::new)
14324                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14325
14326                    data = new CountedObjects<>(objectLimiter, campaignSources);
14327                }
14328            }
14329        } catch (NamingException ex) {
14330            throw new RuntimeException(ex);
14331        }
14332
14333        return data;
14334    }
14335
14336    @GraphQLField
14337    @GraphQLName("subscriptionKind")
14338    static SubscriptionKindObject subscriptionKind(final DataFetchingEnvironment env,
14339            @GraphQLName("subscriptionKindName") final String subscriptionKindName,
14340            @GraphQLName("id") @GraphQLID final String id) {
14341        SubscriptionKind subscriptionKind;
14342
14343        try {
14344            var commandForm = SubscriptionUtil.getHome().getGetSubscriptionKindForm();
14345
14346            commandForm.setSubscriptionKindName(subscriptionKindName);
14347            commandForm.setUuid(id);
14348
14349            subscriptionKind = CDI.current().select(GetSubscriptionKindCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
14350        } catch (NamingException ex) {
14351            throw new RuntimeException(ex);
14352        }
14353
14354        return subscriptionKind == null ? null : new SubscriptionKindObject(subscriptionKind);
14355    }
14356
14357    @GraphQLField
14358    @GraphQLName("subscriptionKinds")
14359    @GraphQLNonNull
14360    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
14361    static CountingPaginatedData<SubscriptionKindObject> subscriptionKinds(final DataFetchingEnvironment env) {
14362        CountingPaginatedData<SubscriptionKindObject> data;
14363
14364        try {
14365            var commandForm = SubscriptionUtil.getHome().getGetSubscriptionKindsForm();
14366            var command = CDI.current().select(GetSubscriptionKindsCommand.class).get();
14367
14368            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14369            if(totalEntities == null) {
14370                data = Connections.emptyConnection();
14371            } else {
14372                try(var objectLimiter = new ObjectLimiter(env, SubscriptionKindConstants.COMPONENT_VENDOR_NAME, SubscriptionKindConstants.ENTITY_TYPE_NAME, totalEntities)) {
14373                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14374
14375                    var subscriptionKinds = entities.stream()
14376                            .map(SubscriptionKindObject::new)
14377                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14378
14379                    data = new CountedObjects<>(objectLimiter, subscriptionKinds);
14380                }
14381            }
14382        } catch (NamingException ex) {
14383            throw new RuntimeException(ex);
14384        }
14385
14386        return data;
14387    }
14388
14389    @GraphQLField
14390    @GraphQLName("subscriptionType")
14391    static SubscriptionTypeObject subscriptionType(final DataFetchingEnvironment env,
14392            @GraphQLName("subscriptionKindName") final String subscriptionKindName,
14393            @GraphQLName("subscriptionTypeName") final String subscriptionTypeName,
14394            @GraphQLName("id") @GraphQLID final String id) {
14395        SubscriptionType subscriptionType;
14396
14397        try {
14398            var commandForm = SubscriptionUtil.getHome().getGetSubscriptionTypeForm();
14399
14400            commandForm.setSubscriptionKindName(subscriptionKindName);
14401            commandForm.setSubscriptionTypeName(subscriptionTypeName);
14402            commandForm.setUuid(id);
14403
14404            subscriptionType = CDI.current().select(GetSubscriptionTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
14405        } catch (NamingException ex) {
14406            throw new RuntimeException(ex);
14407        }
14408
14409        return subscriptionType == null ? null : new SubscriptionTypeObject(subscriptionType);
14410    }
14411
14412    @GraphQLField
14413    @GraphQLName("subscriptionTypes")
14414    @GraphQLNonNull
14415    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
14416    static CountingPaginatedData<SubscriptionTypeObject> subscriptionTypes(final DataFetchingEnvironment env,
14417            @GraphQLName("subscriptionKindName") @GraphQLNonNull final String subscriptionKindName) {
14418        CountingPaginatedData<SubscriptionTypeObject> data;
14419
14420        try {
14421            var commandForm = SubscriptionUtil.getHome().getGetSubscriptionTypesForm();
14422            var command = CDI.current().select(GetSubscriptionTypesCommand.class).get();
14423
14424            commandForm.setSubscriptionKindName(subscriptionKindName);
14425
14426            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14427            if(totalEntities == null) {
14428                data = Connections.emptyConnection();
14429            } else {
14430                try(var objectLimiter = new ObjectLimiter(env, SubscriptionTypeConstants.COMPONENT_VENDOR_NAME, SubscriptionTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
14431                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14432
14433                    var subscriptionTypes = entities.stream()
14434                            .map(SubscriptionTypeObject::new)
14435                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14436
14437                    data = new CountedObjects<>(objectLimiter, subscriptionTypes);
14438                }
14439            }
14440        } catch (NamingException ex) {
14441            throw new RuntimeException(ex);
14442        }
14443
14444        return data;
14445    }
14446
14447    @GraphQLField
14448    @GraphQLName("subscription")
14449    static SubscriptionObject subscription(final DataFetchingEnvironment env,
14450            @GraphQLName("subscriptionName") final String subscriptionName,
14451            @GraphQLName("id") @GraphQLID final String id) {
14452        Subscription subscription;
14453
14454        try {
14455            var commandForm = SubscriptionUtil.getHome().getGetSubscriptionForm();
14456
14457            commandForm.setSubscriptionName(subscriptionName);
14458            commandForm.setUuid(id);
14459
14460            subscription = CDI.current().select(GetSubscriptionCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
14461        } catch (NamingException ex) {
14462            throw new RuntimeException(ex);
14463        }
14464
14465        return subscription == null ? null : new SubscriptionObject(subscription);
14466    }
14467
14468    @GraphQLField
14469    @GraphQLName("subscriptions")
14470    @GraphQLNonNull
14471    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
14472    static CountingPaginatedData<SubscriptionObject> subscriptions(final DataFetchingEnvironment env,
14473            @GraphQLName("subscriptionKindName") @GraphQLNonNull final String subscriptionKindName,
14474            @GraphQLName("subscriptionTypeName") @GraphQLNonNull final String subscriptionTypeName) {
14475        CountingPaginatedData<SubscriptionObject> data;
14476
14477        try {
14478            var commandForm = SubscriptionUtil.getHome().getGetSubscriptionsForm();
14479            var command = CDI.current().select(GetSubscriptionsCommand.class).get();
14480
14481            commandForm.setSubscriptionKindName(subscriptionKindName);
14482            commandForm.setSubscriptionTypeName(subscriptionTypeName);
14483
14484            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14485            if(totalEntities == null) {
14486                data = Connections.emptyConnection();
14487            } else {
14488                try(var objectLimiter = new ObjectLimiter(env, SubscriptionConstants.COMPONENT_VENDOR_NAME, SubscriptionConstants.ENTITY_TYPE_NAME, totalEntities)) {
14489                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14490
14491                    var subscriptions = entities.stream()
14492                            .map(SubscriptionObject::new)
14493                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14494
14495                    data = new CountedObjects<>(objectLimiter, subscriptions);
14496                }
14497            }
14498        } catch (NamingException ex) {
14499            throw new RuntimeException(ex);
14500        }
14501
14502        return data;
14503    }
14504
14505    @GraphQLField
14506    @GraphQLName("chainKind")
14507    static ChainKindObject chainKind(final DataFetchingEnvironment env,
14508            @GraphQLName("chainKindName") final String chainKindName,
14509            @GraphQLName("id") @GraphQLID final String id) {
14510        ChainKind chainKind;
14511
14512        try {
14513            var commandForm = ChainUtil.getHome().getGetChainKindForm();
14514
14515            commandForm.setChainKindName(chainKindName);
14516            commandForm.setUuid(id);
14517
14518            chainKind = CDI.current().select(GetChainKindCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
14519        } catch (NamingException ex) {
14520            throw new RuntimeException(ex);
14521        }
14522
14523        return chainKind == null ? null : new ChainKindObject(chainKind);
14524    }
14525
14526    @GraphQLField
14527    @GraphQLName("chainKinds")
14528    @GraphQLNonNull
14529    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
14530    static CountingPaginatedData<ChainKindObject> chainKinds(final DataFetchingEnvironment env) {
14531        CountingPaginatedData<ChainKindObject> data;
14532
14533        try {
14534            var commandForm = ChainUtil.getHome().getGetChainKindsForm();
14535            var command = CDI.current().select(GetChainKindsCommand.class).get();
14536
14537            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14538            if(totalEntities == null) {
14539                data = Connections.emptyConnection();
14540            } else {
14541                try(var objectLimiter = new ObjectLimiter(env, ChainKindConstants.COMPONENT_VENDOR_NAME, ChainKindConstants.ENTITY_TYPE_NAME, totalEntities)) {
14542                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14543
14544                    var chainKinds = entities.stream()
14545                            .map(ChainKindObject::new)
14546                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14547
14548                    data = new CountedObjects<>(objectLimiter, chainKinds);
14549                }
14550            }
14551        } catch (NamingException ex) {
14552            throw new RuntimeException(ex);
14553        }
14554
14555        return data;
14556    }
14557
14558    @GraphQLField
14559    @GraphQLName("chainType")
14560    static ChainTypeObject chainType(final DataFetchingEnvironment env,
14561            @GraphQLName("chainKindName") final String chainKindName,
14562            @GraphQLName("chainTypeName") final String chainTypeName,
14563            @GraphQLName("id") @GraphQLID final String id) {
14564        ChainType chainType;
14565
14566        try {
14567            var commandForm = ChainUtil.getHome().getGetChainTypeForm();
14568
14569            commandForm.setChainKindName(chainKindName);
14570            commandForm.setChainTypeName(chainTypeName);
14571            commandForm.setUuid(id);
14572
14573            chainType = CDI.current().select(GetChainTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
14574        } catch (NamingException ex) {
14575            throw new RuntimeException(ex);
14576        }
14577
14578        return chainType == null ? null : new ChainTypeObject(chainType);
14579    }
14580
14581    @GraphQLField
14582    @GraphQLName("chainTypes")
14583    @GraphQLNonNull
14584    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
14585    static CountingPaginatedData<ChainTypeObject> chainTypes(final DataFetchingEnvironment env,
14586            @GraphQLName("chainKindName") @GraphQLNonNull final String chainKindName) {
14587        CountingPaginatedData<ChainTypeObject> data;
14588
14589        try {
14590            var commandForm = ChainUtil.getHome().getGetChainTypesForm();
14591            var command = CDI.current().select(GetChainTypesCommand.class).get();
14592
14593            commandForm.setChainKindName(chainKindName);
14594
14595            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14596            if(totalEntities == null) {
14597                data = Connections.emptyConnection();
14598            } else {
14599                try(var objectLimiter = new ObjectLimiter(env, ChainTypeConstants.COMPONENT_VENDOR_NAME, ChainTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
14600                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14601
14602                    var chainTypes = entities.stream()
14603                            .map(ChainTypeObject::new)
14604                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14605
14606                    data = new CountedObjects<>(objectLimiter, chainTypes);
14607                }
14608            }
14609        } catch (NamingException ex) {
14610            throw new RuntimeException(ex);
14611        }
14612
14613        return data;
14614    }
14615
14616    @GraphQLField
14617    @GraphQLName("chain")
14618    static ChainObject chain(final DataFetchingEnvironment env,
14619            @GraphQLName("chainKindName") final String chainKindName,
14620            @GraphQLName("chainTypeName") final String chainTypeName,
14621            @GraphQLName("chainName") final String chainName,
14622            @GraphQLName("id") @GraphQLID final String id) {
14623        Chain chain;
14624
14625        try {
14626            var commandForm = ChainUtil.getHome().getGetChainForm();
14627
14628            commandForm.setChainKindName(chainKindName);
14629            commandForm.setChainTypeName(chainTypeName);
14630            commandForm.setChainName(chainName);
14631            commandForm.setUuid(id);
14632
14633            chain = CDI.current().select(GetChainCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
14634        } catch (NamingException ex) {
14635            throw new RuntimeException(ex);
14636        }
14637
14638        return chain == null ? null : new ChainObject(chain);
14639    }
14640
14641    @GraphQLField
14642    @GraphQLName("chains")
14643    @GraphQLNonNull
14644    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
14645    static CountingPaginatedData<ChainObject> chains(final DataFetchingEnvironment env,
14646            @GraphQLName("chainKindName") @GraphQLNonNull final String chainKindName,
14647            @GraphQLName("chainTypeName") @GraphQLNonNull final String chainTypeName) {
14648        CountingPaginatedData<ChainObject> data;
14649
14650        try {
14651            var commandForm = ChainUtil.getHome().getGetChainsForm();
14652            var command = CDI.current().select(GetChainsCommand.class).get();
14653
14654            commandForm.setChainKindName(chainKindName);
14655            commandForm.setChainTypeName(chainTypeName);
14656
14657            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14658            if(totalEntities == null) {
14659                data = Connections.emptyConnection();
14660            } else {
14661                try(var objectLimiter = new ObjectLimiter(env, ChainConstants.COMPONENT_VENDOR_NAME, ChainConstants.ENTITY_TYPE_NAME, totalEntities)) {
14662                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14663
14664                    var chains = entities.stream()
14665                            .map(ChainObject::new)
14666                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14667
14668                    data = new CountedObjects<>(objectLimiter, chains);
14669                }
14670            }
14671        } catch (NamingException ex) {
14672            throw new RuntimeException(ex);
14673        }
14674
14675        return data;
14676    }
14677
14678    @GraphQLField
14679    @GraphQLName("chainActionSet")
14680    static ChainActionSetObject chainActionSet(final DataFetchingEnvironment env,
14681            @GraphQLName("chainKindName") final String chainKindName,
14682            @GraphQLName("chainTypeName") final String chainTypeName,
14683            @GraphQLName("chainName") final String chainName,
14684            @GraphQLName("chainActionSetName") final String chainActionSetName,
14685            @GraphQLName("id") @GraphQLID final String id) {
14686        ChainActionSet chainActionSet;
14687
14688        try {
14689            var commandForm = ChainUtil.getHome().getGetChainActionSetForm();
14690
14691            commandForm.setChainKindName(chainKindName);
14692            commandForm.setChainTypeName(chainTypeName);
14693            commandForm.setChainName(chainName);
14694            commandForm.setChainActionSetName(chainActionSetName);
14695            commandForm.setUuid(id);
14696
14697            chainActionSet = CDI.current().select(GetChainActionSetCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
14698        } catch (NamingException ex) {
14699            throw new RuntimeException(ex);
14700        }
14701
14702        return chainActionSet == null ? null : new ChainActionSetObject(chainActionSet);
14703    }
14704
14705    @GraphQLField
14706    @GraphQLName("chainActionSets")
14707    @GraphQLNonNull
14708    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
14709    static CountingPaginatedData<ChainActionSetObject> chainActionSets(final DataFetchingEnvironment env,
14710            @GraphQLName("chainKindName") @GraphQLNonNull final String chainKindName,
14711            @GraphQLName("chainTypeName") @GraphQLNonNull final String chainTypeName,
14712            @GraphQLName("chainName") @GraphQLNonNull final String chainName) {
14713        CountingPaginatedData<ChainActionSetObject> data;
14714
14715        try {
14716            var commandForm = ChainUtil.getHome().getGetChainActionSetsForm();
14717            var command = CDI.current().select(GetChainActionSetsCommand.class).get();
14718
14719            commandForm.setChainKindName(chainKindName);
14720            commandForm.setChainTypeName(chainTypeName);
14721            commandForm.setChainName(chainName);
14722
14723            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14724            if(totalEntities == null) {
14725                data = Connections.emptyConnection();
14726            } else {
14727                try(var objectLimiter = new ObjectLimiter(env, ChainActionSetConstants.COMPONENT_VENDOR_NAME, ChainActionSetConstants.ENTITY_TYPE_NAME, totalEntities)) {
14728                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14729
14730                    var chainActionSets = entities.stream()
14731                            .map(ChainActionSetObject::new)
14732                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14733
14734                    data = new CountedObjects<>(objectLimiter, chainActionSets);
14735                }
14736            }
14737        } catch (NamingException ex) {
14738            throw new RuntimeException(ex);
14739        }
14740
14741        return data;
14742    }
14743
14744    @GraphQLField
14745    @GraphQLName("chainActionType")
14746    static ChainActionTypeObject chainActionType(final DataFetchingEnvironment env,
14747            @GraphQLName("chainActionTypeName") final String chainActionTypeName,
14748            @GraphQLName("id") @GraphQLID final String id) {
14749        ChainActionType chainActionType;
14750
14751        try {
14752            var commandForm = ChainUtil.getHome().getGetChainActionTypeForm();
14753
14754            commandForm.setChainActionTypeName(chainActionTypeName);
14755            commandForm.setUuid(id);
14756
14757            chainActionType = CDI.current().select(GetChainActionTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
14758        } catch (NamingException ex) {
14759            throw new RuntimeException(ex);
14760        }
14761
14762        return chainActionType == null ? null : new ChainActionTypeObject(chainActionType);
14763    }
14764
14765    @GraphQLField
14766    @GraphQLName("chainActionTypes")
14767    @GraphQLNonNull
14768    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
14769    static CountingPaginatedData<ChainActionTypeObject> chainActionTypes(final DataFetchingEnvironment env) {
14770        CountingPaginatedData<ChainActionTypeObject> data;
14771
14772        try {
14773            var commandForm = ChainUtil.getHome().getGetChainActionTypesForm();
14774            var command = CDI.current().select(GetChainActionTypesCommand.class).get();
14775
14776            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14777            if(totalEntities == null) {
14778                data = Connections.emptyConnection();
14779            } else {
14780                try(var objectLimiter = new ObjectLimiter(env, ChainActionTypeConstants.COMPONENT_VENDOR_NAME, ChainActionTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
14781                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14782
14783                    var chainActionTypes = entities.stream()
14784                            .map(ChainActionTypeObject::new)
14785                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14786
14787                    data = new CountedObjects<>(objectLimiter, chainActionTypes);
14788                }
14789            }
14790        } catch (NamingException ex) {
14791            throw new RuntimeException(ex);
14792        }
14793
14794        return data;
14795    }
14796
14797    @GraphQLField
14798    @GraphQLName("chainEntityTypeRole")
14799    static ChainEntityRoleTypeObject chainEntityTypeRole(final DataFetchingEnvironment env,
14800            @GraphQLName("chainKindName") final String chainKindName,
14801            @GraphQLName("chainTypeName") final String chainTypeName,
14802            @GraphQLName("chainEntityRoleTypeName") final String chainEntityRoleTypeName,
14803            @GraphQLName("id") @GraphQLID final String id) {
14804        ChainEntityRoleType chainEntityRoleType;
14805
14806        try {
14807            var commandForm = ChainUtil.getHome().getGetChainEntityRoleTypeForm();
14808
14809            commandForm.setChainKindName(chainKindName);
14810            commandForm.setChainTypeName(chainTypeName);
14811            commandForm.setChainEntityRoleTypeName(chainEntityRoleTypeName);
14812            commandForm.setUuid(id);
14813
14814            chainEntityRoleType = CDI.current().select(GetChainEntityRoleTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
14815        } catch (NamingException ex) {
14816            throw new RuntimeException(ex);
14817        }
14818
14819        return chainEntityRoleType == null ? null : new ChainEntityRoleTypeObject(chainEntityRoleType);
14820    }
14821
14822    @GraphQLField
14823    @GraphQLName("chainEntityTypeRoles")
14824    @GraphQLNonNull
14825    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
14826    static CountingPaginatedData<ChainEntityRoleTypeObject> chainEntityTypeRoles(final DataFetchingEnvironment env,
14827            @GraphQLName("chainKindName") @GraphQLNonNull final String chainKindName,
14828            @GraphQLName("chainTypeName") @GraphQLNonNull final String chainTypeName) {
14829        CountingPaginatedData<ChainEntityRoleTypeObject> data;
14830
14831        try {
14832            var commandForm = ChainUtil.getHome().getGetChainEntityRoleTypesForm();
14833            var command = CDI.current().select(GetChainEntityRoleTypesCommand.class).get();
14834
14835            commandForm.setChainKindName(chainKindName);
14836            commandForm.setChainTypeName(chainTypeName);
14837
14838            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14839            if(totalEntities == null) {
14840                data = Connections.emptyConnection();
14841            } else {
14842                try(var objectLimiter = new ObjectLimiter(env, ChainEntityRoleTypeConstants.COMPONENT_VENDOR_NAME, ChainEntityRoleTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
14843                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14844
14845                    var chainEntityTypeRoles = entities.stream()
14846                            .map(ChainEntityRoleTypeObject::new)
14847                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14848
14849                    data = new CountedObjects<>(objectLimiter, chainEntityTypeRoles);
14850                }
14851            }
14852        } catch (NamingException ex) {
14853            throw new RuntimeException(ex);
14854        }
14855
14856        return data;
14857    }
14858
14859    @GraphQLField
14860    @GraphQLName("chainAction")
14861    static ChainActionObject chainAction(final DataFetchingEnvironment env,
14862            @GraphQLName("chainKindName") final String chainKindName,
14863            @GraphQLName("chainTypeName") final String chainTypeName,
14864            @GraphQLName("chainName") final String chainName,
14865            @GraphQLName("chainActionSetName") final String chainActionSetName,
14866            @GraphQLName("chainActionName") final String chainActionName,
14867            @GraphQLName("id") @GraphQLID final String id) {
14868        ChainAction chainAction;
14869
14870        try {
14871            var commandForm = ChainUtil.getHome().getGetChainActionForm();
14872
14873            commandForm.setChainKindName(chainKindName);
14874            commandForm.setChainTypeName(chainTypeName);
14875            commandForm.setChainName(chainName);
14876            commandForm.setChainActionSetName(chainActionSetName);
14877            commandForm.setChainActionName(chainActionName);
14878            commandForm.setUuid(id);
14879
14880            chainAction = CDI.current().select(GetChainActionCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
14881        } catch (NamingException ex) {
14882            throw new RuntimeException(ex);
14883        }
14884
14885        return chainAction == null ? null : new ChainActionObject(chainAction);
14886    }
14887
14888    @GraphQLField
14889    @GraphQLName("chainActions")
14890    @GraphQLNonNull
14891    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
14892    static CountingPaginatedData<ChainActionObject> chainActions(final DataFetchingEnvironment env,
14893            @GraphQLName("chainKindName") @GraphQLNonNull final String chainKindName,
14894            @GraphQLName("chainTypeName") @GraphQLNonNull final String chainTypeName,
14895            @GraphQLName("chainName") @GraphQLNonNull final String chainName,
14896            @GraphQLName("chainActionSetName") @GraphQLNonNull final String chainActionSetName) {
14897        CountingPaginatedData<ChainActionObject> data;
14898
14899        try {
14900            var commandForm = ChainUtil.getHome().getGetChainActionsForm();
14901            var command = CDI.current().select(GetChainActionsCommand.class).get();
14902
14903            commandForm.setChainKindName(chainKindName);
14904            commandForm.setChainTypeName(chainTypeName);
14905            commandForm.setChainName(chainName);
14906            commandForm.setChainActionSetName(chainActionSetName);
14907
14908            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14909            if(totalEntities == null) {
14910                data = Connections.emptyConnection();
14911            } else {
14912                try(var objectLimiter = new ObjectLimiter(env, ChainActionConstants.COMPONENT_VENDOR_NAME, ChainActionConstants.ENTITY_TYPE_NAME, totalEntities)) {
14913                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14914
14915                    var chainActions = entities.stream()
14916                            .map(ChainActionObject::new)
14917                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14918
14919                    data = new CountedObjects<>(objectLimiter, chainActions);
14920                }
14921            }
14922        } catch (NamingException ex) {
14923            throw new RuntimeException(ex);
14924        }
14925
14926        return data;
14927    }
14928
14929    @GraphQLField
14930    @GraphQLName("chainInstance")
14931    static ChainInstanceObject chainInstance(final DataFetchingEnvironment env,
14932            @GraphQLName("chainInstanceName") final String chainInstanceName,
14933            @GraphQLName("id") @GraphQLID final String id) {
14934        ChainInstance chainInstance;
14935
14936        try {
14937            var commandForm = ChainUtil.getHome().getGetChainInstanceForm();
14938
14939            commandForm.setChainInstanceName(chainInstanceName);
14940            commandForm.setUuid(id);
14941
14942            chainInstance = CDI.current().select(GetChainInstanceCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
14943        } catch (NamingException ex) {
14944            throw new RuntimeException(ex);
14945        }
14946
14947        return chainInstance == null ? null : new ChainInstanceObject(chainInstance);
14948    }
14949
14950    @GraphQLField
14951    @GraphQLName("chainInstances")
14952    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
14953    static CountingPaginatedData<ChainInstanceObject> chainInstances(final DataFetchingEnvironment env,
14954            @GraphQLName("chainKindName") final String chainKindName,
14955            @GraphQLName("chainTypeName") final String chainTypeName,
14956            @GraphQLName("chainName") final String chainName) {
14957        CountingPaginatedData<ChainInstanceObject> data;
14958
14959        try {
14960            var commandForm = ChainUtil.getHome().getGetChainInstancesForm();
14961            var command = CDI.current().select(GetChainInstancesCommand.class).get();
14962
14963            commandForm.setChainKindName(chainKindName);
14964            commandForm.setChainTypeName(chainTypeName);
14965            commandForm.setChainName(chainName);
14966
14967            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14968            if(totalEntities == null) {
14969                data = Connections.emptyConnection();
14970            } else {
14971                try(var objectLimiter = new ObjectLimiter(env, ChainInstanceConstants.COMPONENT_VENDOR_NAME, ChainInstanceConstants.ENTITY_TYPE_NAME, totalEntities)) {
14972                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
14973
14974                    var chainInstances = entities.stream()
14975                            .map(ChainInstanceObject::new)
14976                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
14977
14978                    data = new CountedObjects<>(objectLimiter, chainInstances);
14979                }
14980            }
14981        } catch (NamingException ex) {
14982            throw new RuntimeException(ex);
14983        }
14984
14985        return data;
14986    }
14987
14988
14989    @GraphQLField
14990    @GraphQLName("contactListFrequency")
14991    static ContactListFrequencyObject contactListFrequency(final DataFetchingEnvironment env,
14992            @GraphQLName("contactListFrequencyName") final String contactListFrequencyName,
14993            @GraphQLName("id") @GraphQLID final String id) {
14994        ContactListFrequency contactListFrequency;
14995
14996        try {
14997            var commandForm = ContactListUtil.getHome().getGetContactListFrequencyForm();
14998
14999            commandForm.setContactListFrequencyName(contactListFrequencyName);
15000            commandForm.setUuid(id);
15001
15002            contactListFrequency = CDI.current().select(GetContactListFrequencyCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
15003        } catch (NamingException ex) {
15004            throw new RuntimeException(ex);
15005        }
15006
15007        return contactListFrequency == null ? null : new ContactListFrequencyObject(contactListFrequency);
15008    }
15009
15010    @GraphQLField
15011    @GraphQLName("contactListFrequencies")
15012    @GraphQLNonNull
15013    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15014    static CountingPaginatedData<ContactListFrequencyObject> contactListFrequencies(final DataFetchingEnvironment env) {
15015        CountingPaginatedData<ContactListFrequencyObject> data;
15016
15017        try {
15018            var commandForm = ContactListUtil.getHome().getGetContactListFrequenciesForm();
15019            var command = CDI.current().select(GetContactListFrequenciesCommand.class).get();
15020
15021            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15022            if(totalEntities == null) {
15023                data = Connections.emptyConnection();
15024            } else {
15025                try(var objectLimiter = new ObjectLimiter(env, ContactListFrequencyConstants.COMPONENT_VENDOR_NAME, ContactListFrequencyConstants.ENTITY_TYPE_NAME, totalEntities)) {
15026                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15027
15028                    var contactListFrequencies = entities.stream()
15029                            .map(ContactListFrequencyObject::new)
15030                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15031
15032                    data = new CountedObjects<>(objectLimiter, contactListFrequencies);
15033                }
15034            }
15035        } catch (NamingException ex) {
15036            throw new RuntimeException(ex);
15037        }
15038
15039        return data;
15040    }
15041
15042    @GraphQLField
15043    @GraphQLName("contactMechanismPurpose")
15044    static ContactMechanismPurposeObject contactMechanismPurpose(final DataFetchingEnvironment env,
15045            @GraphQLName("contactMechanismPurposeName") final String contactMechanismPurposeName,
15046            @GraphQLName("id") @GraphQLID final String id) {
15047        ContactMechanismPurpose contactMechanismPurpose;
15048
15049        try {
15050            var commandForm = ContactUtil.getHome().getGetContactMechanismPurposeForm();
15051
15052            commandForm.setContactMechanismPurposeName(contactMechanismPurposeName);
15053            commandForm.setUuid(id);
15054
15055            contactMechanismPurpose = CDI.current().select(GetContactMechanismPurposeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
15056        } catch (NamingException ex) {
15057            throw new RuntimeException(ex);
15058        }
15059
15060        return contactMechanismPurpose == null ? null : new ContactMechanismPurposeObject(contactMechanismPurpose);
15061    }
15062
15063    @GraphQLField
15064    @GraphQLName("contactMechanismPurposes")
15065    @GraphQLNonNull
15066    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15067    static CountingPaginatedData<ContactMechanismPurposeObject> contactMechanismPurposes(final DataFetchingEnvironment env) {
15068        CountingPaginatedData<ContactMechanismPurposeObject> data;
15069
15070        try {
15071            var commandForm = ContactUtil.getHome().getGetContactMechanismPurposesForm();
15072            var command = CDI.current().select(GetContactMechanismPurposesCommand.class).get();
15073
15074            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15075            if(totalEntities == null) {
15076                data = Connections.emptyConnection();
15077            } else {
15078                try(var objectLimiter = new ObjectLimiter(env, ContactMechanismPurposeConstants.COMPONENT_VENDOR_NAME, ContactMechanismPurposeConstants.ENTITY_TYPE_NAME, totalEntities)) {
15079                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15080
15081                    var contactMechanismPurposes = entities.stream()
15082                            .map(ContactMechanismPurposeObject::new)
15083                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15084
15085                    data = new CountedObjects<>(objectLimiter, contactMechanismPurposes);
15086                }
15087            }
15088        } catch (NamingException ex) {
15089            throw new RuntimeException(ex);
15090        }
15091
15092        return data;
15093    }
15094
15095    @GraphQLField
15096    @GraphQLName("contactListGroup")
15097    static ContactListGroupObject contactListGroup(final DataFetchingEnvironment env,
15098            @GraphQLName("contactListGroupName") final String contactListGroupName,
15099            @GraphQLName("id") @GraphQLID final String id) {
15100        ContactListGroup contactListGroup;
15101
15102        try {
15103            var commandForm = ContactListUtil.getHome().getGetContactListGroupForm();
15104
15105            commandForm.setContactListGroupName(contactListGroupName);
15106            commandForm.setUuid(id);
15107
15108            contactListGroup = CDI.current().select(GetContactListGroupCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
15109        } catch (NamingException ex) {
15110            throw new RuntimeException(ex);
15111        }
15112
15113        return contactListGroup == null ? null : new ContactListGroupObject(contactListGroup);
15114    }
15115
15116    @GraphQLField
15117    @GraphQLName("contactListGroups")
15118    @GraphQLNonNull
15119    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15120    static CountingPaginatedData<ContactListGroupObject> contactListGroups(final DataFetchingEnvironment env) {
15121        CountingPaginatedData<ContactListGroupObject> data;
15122
15123        try {
15124            var commandForm = ContactListUtil.getHome().getGetContactListGroupsForm();
15125            var command = CDI.current().select(GetContactListGroupsCommand.class).get();
15126
15127            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15128            if(totalEntities == null) {
15129                data = Connections.emptyConnection();
15130            } else {
15131                try(var objectLimiter = new ObjectLimiter(env, ContactListGroupConstants.COMPONENT_VENDOR_NAME, ContactListGroupConstants.ENTITY_TYPE_NAME, totalEntities)) {
15132                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15133
15134                    var contactListGroups = entities.stream()
15135                            .map(ContactListGroupObject::new)
15136                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15137
15138                    data = new CountedObjects<>(objectLimiter, contactListGroups);
15139                }
15140            }
15141        } catch (NamingException ex) {
15142            throw new RuntimeException(ex);
15143        }
15144
15145        return data;
15146    }
15147
15148    @GraphQLField
15149    @GraphQLName("customerTypeContactListGroup")
15150    static CustomerTypeContactListGroupObject customerTypeContactListGroup(final DataFetchingEnvironment env,
15151            @GraphQLName("customerTypeName") @GraphQLNonNull final String customerTypeName,
15152            @GraphQLName("contactListGroupName") @GraphQLNonNull final String contactListGroupName) {
15153        CustomerTypeContactListGroup customerTypeContactListGroup;
15154
15155        try {
15156            var commandForm = ContactListUtil.getHome().getGetCustomerTypeContactListGroupForm();
15157
15158            commandForm.setCustomerTypeName(customerTypeName);
15159            commandForm.setContactListGroupName(contactListGroupName);
15160
15161            customerTypeContactListGroup = CDI.current().select(GetCustomerTypeContactListGroupCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
15162        } catch (NamingException ex) {
15163            throw new RuntimeException(ex);
15164        }
15165
15166        return customerTypeContactListGroup == null ? null : new CustomerTypeContactListGroupObject(customerTypeContactListGroup);
15167    }
15168
15169    @GraphQLField
15170    @GraphQLName("customerTypeContactListGroups")
15171    @GraphQLNonNull
15172    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15173    static CountingPaginatedData<CustomerTypeContactListGroupObject> customerTypeContactListGroups(final DataFetchingEnvironment env,
15174            @GraphQLName("customerTypeName") final String customerTypeName,
15175            @GraphQLName("contactListGroupName") final String contactListGroupName) {
15176        CountingPaginatedData<CustomerTypeContactListGroupObject> data;
15177
15178        try {
15179            var commandForm = ContactListUtil.getHome().getGetCustomerTypeContactListGroupsForm();
15180            var command = CDI.current().select(GetCustomerTypeContactListGroupsCommand.class).get();
15181
15182            commandForm.setCustomerTypeName(customerTypeName);
15183            commandForm.setContactListGroupName(contactListGroupName);
15184
15185            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15186            if(totalEntities == null) {
15187                data = Connections.emptyConnection();
15188            } else {
15189                try(var objectLimiter = new ObjectLimiter(env, CustomerTypeContactListGroupConstants.COMPONENT_VENDOR_NAME, CustomerTypeContactListGroupConstants.ENTITY_TYPE_NAME, totalEntities)) {
15190                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15191
15192                    var customerTypeContactListGroups = entities.stream()
15193                            .map(CustomerTypeContactListGroupObject::new)
15194                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15195
15196                    data = new CountedObjects<>(objectLimiter, customerTypeContactListGroups);
15197                }
15198            }
15199        } catch (NamingException ex) {
15200            throw new RuntimeException(ex);
15201        }
15202
15203        return data;
15204    }
15205
15206    @GraphQLField
15207    @GraphQLName("partyTypeContactListGroup")
15208    static PartyTypeContactListGroupObject partyTypeContactListGroup(final DataFetchingEnvironment env,
15209            @GraphQLName("partyTypeName") @GraphQLNonNull final String partyTypeName,
15210            @GraphQLName("contactListGroupName") @GraphQLNonNull final String contactListGroupName) {
15211        PartyTypeContactListGroup partyTypeContactListGroup;
15212
15213        try {
15214            var commandForm = ContactListUtil.getHome().getGetPartyTypeContactListGroupForm();
15215
15216            commandForm.setPartyTypeName(partyTypeName);
15217            commandForm.setContactListGroupName(contactListGroupName);
15218
15219            partyTypeContactListGroup = CDI.current().select(GetPartyTypeContactListGroupCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
15220        } catch (NamingException ex) {
15221            throw new RuntimeException(ex);
15222        }
15223
15224        return partyTypeContactListGroup == null ? null : new PartyTypeContactListGroupObject(partyTypeContactListGroup);
15225    }
15226
15227    @GraphQLField
15228    @GraphQLName("partyTypeContactListGroups")
15229    @GraphQLNonNull
15230    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15231    static CountingPaginatedData<PartyTypeContactListGroupObject> partyTypeContactListGroups(final DataFetchingEnvironment env,
15232            @GraphQLName("partyTypeName") final String partyTypeName,
15233            @GraphQLName("contactListGroupName") final String contactListGroupName) {
15234        CountingPaginatedData<PartyTypeContactListGroupObject> data;
15235
15236        try {
15237            var commandForm = ContactListUtil.getHome().getGetPartyTypeContactListGroupsForm();
15238            var command = CDI.current().select(GetPartyTypeContactListGroupsCommand.class).get();
15239
15240            commandForm.setPartyTypeName(partyTypeName);
15241            commandForm.setContactListGroupName(contactListGroupName);
15242
15243            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15244            if(totalEntities == null) {
15245                data = Connections.emptyConnection();
15246            } else {
15247                try(var objectLimiter = new ObjectLimiter(env, PartyTypeContactListGroupConstants.COMPONENT_VENDOR_NAME, PartyTypeContactListGroupConstants.ENTITY_TYPE_NAME, totalEntities)) {
15248                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15249
15250                    var partyTypeContactListGroups = entities.stream()
15251                            .map(PartyTypeContactListGroupObject::new)
15252                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15253
15254                    data = new CountedObjects<>(objectLimiter, partyTypeContactListGroups);
15255                }
15256            }
15257        } catch (NamingException ex) {
15258            throw new RuntimeException(ex);
15259        }
15260
15261        return data;
15262    }
15263
15264    @GraphQLField
15265    @GraphQLName("contactListType")
15266    static ContactListTypeObject contactListType(final DataFetchingEnvironment env,
15267            @GraphQLName("contactListTypeName") final String contactListTypeName,
15268            @GraphQLName("id") @GraphQLID final String id) {
15269        ContactListType contactListType;
15270
15271        try {
15272            var commandForm = ContactListUtil.getHome().getGetContactListTypeForm();
15273
15274            commandForm.setContactListTypeName(contactListTypeName);
15275            commandForm.setUuid(id);
15276
15277            contactListType = CDI.current().select(GetContactListTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
15278        } catch (NamingException ex) {
15279            throw new RuntimeException(ex);
15280        }
15281
15282        return contactListType == null ? null : new ContactListTypeObject(contactListType);
15283    }
15284
15285    @GraphQLField
15286    @GraphQLName("contactListTypes")
15287    @GraphQLNonNull
15288    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15289    static CountingPaginatedData<ContactListTypeObject> contactListTypes(final DataFetchingEnvironment env) {
15290        CountingPaginatedData<ContactListTypeObject> data;
15291
15292        try {
15293            var commandForm = ContactListUtil.getHome().getGetContactListTypesForm();
15294            var command = CDI.current().select(GetContactListTypesCommand.class).get();
15295
15296            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15297            if(totalEntities == null) {
15298                data = Connections.emptyConnection();
15299            } else {
15300                try(var objectLimiter = new ObjectLimiter(env, ContactListTypeConstants.COMPONENT_VENDOR_NAME, ContactListTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
15301                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15302
15303                    var contactListTypes = entities.stream()
15304                            .map(ContactListTypeObject::new)
15305                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15306
15307                    data = new CountedObjects<>(objectLimiter, contactListTypes);
15308                }
15309            }
15310        } catch (NamingException ex) {
15311            throw new RuntimeException(ex);
15312        }
15313
15314        return data;
15315    }
15316
15317    @GraphQLField
15318    @GraphQLName("contactList")
15319    static ContactListObject contactList(final DataFetchingEnvironment env,
15320            @GraphQLName("contactListName") final String contactListName,
15321            @GraphQLName("id") @GraphQLID final String id) {
15322        ContactList contactList;
15323
15324        try {
15325            var commandForm = ContactListUtil.getHome().getGetContactListForm();
15326
15327            commandForm.setContactListName(contactListName);
15328            commandForm.setUuid(id);
15329
15330            contactList = CDI.current().select(GetContactListCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
15331        } catch (NamingException ex) {
15332            throw new RuntimeException(ex);
15333        }
15334
15335        return contactList == null ? null : new ContactListObject(contactList);
15336    }
15337
15338    @GraphQLField
15339    @GraphQLName("contactLists")
15340    @GraphQLNonNull
15341    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15342    static CountingPaginatedData<ContactListObject> contactLists(final DataFetchingEnvironment env) {
15343        CountingPaginatedData<ContactListObject> data;
15344
15345        try {
15346            var commandForm = ContactListUtil.getHome().getGetContactListsForm();
15347            var command = CDI.current().select(GetContactListsCommand.class).get();
15348
15349            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15350            if(totalEntities == null) {
15351                data = Connections.emptyConnection();
15352            } else {
15353                try(var objectLimiter = new ObjectLimiter(env, ContactListConstants.COMPONENT_VENDOR_NAME, ContactListConstants.ENTITY_TYPE_NAME, totalEntities)) {
15354                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15355
15356                    var contactLists = entities.stream()
15357                            .map(ContactListObject::new)
15358                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15359
15360                    data = new CountedObjects<>(objectLimiter, contactLists);
15361                }
15362            }
15363        } catch (NamingException ex) {
15364            throw new RuntimeException(ex);
15365        }
15366
15367        return data;
15368    }
15369
15370    @GraphQLField
15371    @GraphQLName("customerTypeContactList")
15372    static CustomerTypeContactListObject customerTypeContactList(final DataFetchingEnvironment env,
15373            @GraphQLName("customerTypeName") @GraphQLNonNull final String customerTypeName,
15374            @GraphQLName("contactListName") @GraphQLNonNull final String contactListName) {
15375        CustomerTypeContactList customerTypeContactList;
15376
15377        try {
15378            var commandForm = ContactListUtil.getHome().getGetCustomerTypeContactListForm();
15379
15380            commandForm.setCustomerTypeName(customerTypeName);
15381            commandForm.setContactListName(contactListName);
15382
15383            customerTypeContactList = CDI.current().select(GetCustomerTypeContactListCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
15384        } catch (NamingException ex) {
15385            throw new RuntimeException(ex);
15386        }
15387
15388        return customerTypeContactList == null ? null : new CustomerTypeContactListObject(customerTypeContactList);
15389    }
15390
15391    @GraphQLField
15392    @GraphQLName("customerTypeContactLists")
15393    @GraphQLNonNull
15394    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15395    static CountingPaginatedData<CustomerTypeContactListObject> customerTypeContactLists(final DataFetchingEnvironment env,
15396            @GraphQLName("customerTypeName") final String customerTypeName,
15397            @GraphQLName("contactListName") final String contactListName) {
15398        CountingPaginatedData<CustomerTypeContactListObject> data;
15399
15400        try {
15401            var commandForm = ContactListUtil.getHome().getGetCustomerTypeContactListsForm();
15402            var command = CDI.current().select(GetCustomerTypeContactListsCommand.class).get();
15403
15404            commandForm.setCustomerTypeName(customerTypeName);
15405            commandForm.setContactListName(contactListName);
15406
15407            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15408            if(totalEntities == null) {
15409                data = Connections.emptyConnection();
15410            } else {
15411                try(var objectLimiter = new ObjectLimiter(env, CustomerTypeContactListConstants.COMPONENT_VENDOR_NAME, CustomerTypeContactListConstants.ENTITY_TYPE_NAME, totalEntities)) {
15412                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15413
15414                    var customerTypeContactLists = entities.stream()
15415                            .map(CustomerTypeContactListObject::new)
15416                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15417
15418                    data = new CountedObjects<>(objectLimiter, customerTypeContactLists);
15419                }
15420            }
15421        } catch (NamingException ex) {
15422            throw new RuntimeException(ex);
15423        }
15424
15425        return data;
15426    }
15427
15428    @GraphQLField
15429    @GraphQLName("partyTypeContactList")
15430    static PartyTypeContactListObject partyTypeContactList(final DataFetchingEnvironment env,
15431            @GraphQLName("partyTypeName") @GraphQLNonNull final String partyTypeName,
15432            @GraphQLName("contactListName") @GraphQLNonNull final String contactListName) {
15433        PartyTypeContactList partyTypeContactList;
15434
15435        try {
15436            var commandForm = ContactListUtil.getHome().getGetPartyTypeContactListForm();
15437
15438            commandForm.setPartyTypeName(partyTypeName);
15439            commandForm.setContactListName(contactListName);
15440
15441            partyTypeContactList = CDI.current().select(GetPartyTypeContactListCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
15442        } catch (NamingException ex) {
15443            throw new RuntimeException(ex);
15444        }
15445
15446        return partyTypeContactList == null ? null : new PartyTypeContactListObject(partyTypeContactList);
15447    }
15448
15449    @GraphQLField
15450    @GraphQLName("partyTypeContactLists")
15451    @GraphQLNonNull
15452    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15453    static CountingPaginatedData<PartyTypeContactListObject> partyTypeContactLists(final DataFetchingEnvironment env,
15454            @GraphQLName("partyTypeName") final String partyTypeName,
15455            @GraphQLName("contactListName") final String contactListName) {
15456        CountingPaginatedData<PartyTypeContactListObject> data;
15457
15458        try {
15459            var commandForm = ContactListUtil.getHome().getGetPartyTypeContactListsForm();
15460            var command = CDI.current().select(GetPartyTypeContactListsCommand.class).get();
15461
15462            commandForm.setPartyTypeName(partyTypeName);
15463            commandForm.setContactListName(contactListName);
15464
15465            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15466            if(totalEntities == null) {
15467                data = Connections.emptyConnection();
15468            } else {
15469                try(var objectLimiter = new ObjectLimiter(env, PartyTypeContactListConstants.COMPONENT_VENDOR_NAME, PartyTypeContactListConstants.ENTITY_TYPE_NAME, totalEntities)) {
15470                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15471
15472                    var partyTypeContactLists = entities.stream()
15473                            .map(PartyTypeContactListObject::new)
15474                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15475
15476                    data = new CountedObjects<>(objectLimiter, partyTypeContactLists);
15477                }
15478            }
15479        } catch (NamingException ex) {
15480            throw new RuntimeException(ex);
15481        }
15482
15483        return data;
15484    }
15485
15486    @GraphQLField
15487    @GraphQLName("partyContactList")
15488    static PartyContactListObject partyContactList(final DataFetchingEnvironment env,
15489            @GraphQLName("partyName") final String partyName,
15490            @GraphQLName("contactListName") final String contactListName,
15491            @GraphQLName("id") @GraphQLID final String id) {
15492        PartyContactList partyContactList;
15493
15494        try {
15495            var commandForm = ContactListUtil.getHome().getGetPartyContactListForm();
15496
15497            commandForm.setPartyName(partyName);
15498            commandForm.setContactListName(contactListName);
15499            commandForm.setUuid(id);
15500
15501            partyContactList = CDI.current().select(GetPartyContactListCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
15502        } catch (NamingException ex) {
15503            throw new RuntimeException(ex);
15504        }
15505
15506        return partyContactList == null ? null : new PartyContactListObject(partyContactList);
15507    }
15508
15509    @GraphQLField
15510    @GraphQLName("partyContactLists")
15511    @GraphQLNonNull
15512    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15513    static CountingPaginatedData<PartyContactListObject> partyContactLists(final DataFetchingEnvironment env,
15514            @GraphQLName("partyName") final String partyName,
15515            @GraphQLName("contactListName") final String contactListName) {
15516        CountingPaginatedData<PartyContactListObject> data;
15517
15518        try {
15519            var commandForm = ContactListUtil.getHome().getGetPartyContactListsForm();
15520            var command = CDI.current().select(GetPartyContactListsCommand.class).get();
15521
15522            commandForm.setPartyName(partyName);
15523            commandForm.setContactListName(contactListName);
15524
15525            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15526            if(totalEntities == null) {
15527                data = Connections.emptyConnection();
15528            } else {
15529                try(var objectLimiter = new ObjectLimiter(env, PartyContactListConstants.COMPONENT_VENDOR_NAME, PartyContactListConstants.ENTITY_TYPE_NAME, totalEntities)) {
15530                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15531
15532                    var partyContactLists = entities.stream()
15533                            .map(PartyContactListObject::new)
15534                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15535
15536                    data = new CountedObjects<>(objectLimiter, partyContactLists);
15537                }
15538            }
15539        } catch (NamingException ex) {
15540            throw new RuntimeException(ex);
15541        }
15542
15543        return data;
15544    }
15545
15546    @GraphQLField
15547    @GraphQLName("contactListContactMechanismPurpose")
15548    static ContactListContactMechanismPurposeObject contactListContactMechanismPurpose(final DataFetchingEnvironment env,
15549            @GraphQLName("contactListName") final String contactListName,
15550            @GraphQLName("contactMechanismPurposeName") final String contactMechanismPurposeName) {
15551        ContactListContactMechanismPurpose contactListContactMechanismPurpose = null;
15552
15553        try {
15554            var commandForm = ContactListUtil.getHome().getGetContactListContactMechanismPurposeForm();
15555
15556            commandForm.setContactListName(contactListName);
15557            commandForm.setContactMechanismPurposeName(contactMechanismPurposeName);
15558
15559            contactListContactMechanismPurpose = CDI.current().select(GetContactListContactMechanismPurposeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
15560        } catch (NamingException ex) {
15561            throw new RuntimeException(ex);
15562        }
15563
15564        return contactListContactMechanismPurpose == null ? null : new ContactListContactMechanismPurposeObject(contactListContactMechanismPurpose);
15565    }
15566
15567    @GraphQLField
15568    @GraphQLName("contactListContactMechanismPurposes")
15569    @GraphQLNonNull
15570    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15571    static CountingPaginatedData<ContactListContactMechanismPurposeObject> contactListContactMechanismPurposes(final DataFetchingEnvironment env,
15572            @GraphQLName("contactListName") final String contactListName) {
15573        CountingPaginatedData<ContactListContactMechanismPurposeObject> data;
15574
15575        try {
15576            var commandForm = ContactListUtil.getHome().getGetContactListContactMechanismPurposesForm();
15577            var command = CDI.current().select(GetContactListContactMechanismPurposesCommand.class).get();
15578
15579            commandForm.setContactListName(contactListName);
15580
15581            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15582            if(totalEntities == null) {
15583                data = Connections.emptyConnection();
15584            } else {
15585                try(var objectLimiter = new ObjectLimiter(env, ContactListContactMechanismPurposeConstants.COMPONENT_VENDOR_NAME, ContactListContactMechanismPurposeConstants.ENTITY_TYPE_NAME, totalEntities)) {
15586                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15587
15588                    var contactListContactMechanismPurposes = entities.stream()
15589                            .map(ContactListContactMechanismPurposeObject::new)
15590                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15591
15592                    data = new CountedObjects<>(objectLimiter, contactListContactMechanismPurposes);
15593                }
15594            }
15595        } catch (NamingException ex) {
15596            throw new RuntimeException(ex);
15597        }
15598
15599        return data;
15600    }
15601
15602    @GraphQLField
15603    @GraphQLName("periodKind")
15604    static PeriodKindObject periodKind(final DataFetchingEnvironment env,
15605            @GraphQLName("periodKindName") final String periodKindName,
15606            @GraphQLName("id") @GraphQLID final String id) {
15607        PeriodKind periodKind;
15608
15609        try {
15610            var commandForm = PeriodUtil.getHome().getGetPeriodKindForm();
15611
15612            commandForm.setPeriodKindName(periodKindName);
15613            commandForm.setUuid(id);
15614
15615            periodKind = CDI.current().select(GetPeriodKindCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
15616        } catch (NamingException ex) {
15617            throw new RuntimeException(ex);
15618        }
15619
15620        return periodKind == null ? null : new PeriodKindObject(periodKind);
15621    }
15622
15623    @GraphQLField
15624    @GraphQLName("periodKinds")
15625    @GraphQLNonNull
15626    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15627    static CountingPaginatedData<PeriodKindObject> periodKinds(final DataFetchingEnvironment env) {
15628        CountingPaginatedData<PeriodKindObject> data;
15629
15630        try {
15631            var commandForm = PeriodUtil.getHome().getGetPeriodKindsForm();
15632            var command = CDI.current().select(GetPeriodKindsCommand.class).get();
15633
15634            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15635            if(totalEntities == null) {
15636                data = Connections.emptyConnection();
15637            } else {
15638                try(var objectLimiter = new ObjectLimiter(env, PeriodKindConstants.COMPONENT_VENDOR_NAME, PeriodKindConstants.ENTITY_TYPE_NAME, totalEntities)) {
15639                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15640
15641                    var periodKinds = entities.stream()
15642                            .map(PeriodKindObject::new)
15643                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15644
15645                    data = new CountedObjects<>(objectLimiter, periodKinds);
15646                }
15647            }
15648        } catch (NamingException ex) {
15649            throw new RuntimeException(ex);
15650        }
15651
15652        return data;
15653    }
15654
15655    @GraphQLField
15656    @GraphQLName("periodType")
15657    static PeriodTypeObject periodType(final DataFetchingEnvironment env,
15658            @GraphQLName("periodKindName") final String periodKindName,
15659            @GraphQLName("periodTypeName") final String periodTypeName,
15660            @GraphQLName("id") @GraphQLID final String id) {
15661        PeriodType periodType;
15662
15663        try {
15664            var commandForm = PeriodUtil.getHome().getGetPeriodTypeForm();
15665
15666            commandForm.setPeriodKindName(periodKindName);
15667            commandForm.setPeriodTypeName(periodTypeName);
15668            commandForm.setUuid(id);
15669
15670            periodType = CDI.current().select(GetPeriodTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
15671        } catch (NamingException ex) {
15672            throw new RuntimeException(ex);
15673        }
15674
15675        return periodType == null ? null : new PeriodTypeObject(periodType);
15676    }
15677
15678    @GraphQLField
15679    @GraphQLName("periodTypes")
15680    @GraphQLNonNull
15681    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15682    static CountingPaginatedData<PeriodTypeObject> periodTypes(final DataFetchingEnvironment env,
15683            @GraphQLName("periodKindName") @GraphQLNonNull final String periodKindName) {
15684        CountingPaginatedData<PeriodTypeObject> data;
15685
15686        try {
15687            var commandForm = PeriodUtil.getHome().getGetPeriodTypesForm();
15688            var command = CDI.current().select(GetPeriodTypesCommand.class).get();
15689
15690            commandForm.setPeriodKindName(periodKindName);
15691
15692            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15693            if(totalEntities == null) {
15694                data = Connections.emptyConnection();
15695            } else {
15696                try(var objectLimiter = new ObjectLimiter(env, PeriodTypeConstants.COMPONENT_VENDOR_NAME, PeriodTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
15697                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15698
15699                    var periodTypes = entities.stream()
15700                            .map(PeriodTypeObject::new)
15701                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15702
15703                    data = new CountedObjects<>(objectLimiter, periodTypes);
15704                }
15705            }
15706        } catch (NamingException ex) {
15707            throw new RuntimeException(ex);
15708        }
15709
15710        return data;
15711    }
15712
15713    @GraphQLField
15714    @GraphQLName("fiscalPeriod")
15715    static FiscalPeriodObject fiscalPeriod(final DataFetchingEnvironment env,
15716            @GraphQLName("periodName") final String periodName,
15717            @GraphQLName("id") @GraphQLID final String id) {
15718        try {
15719            var form = PeriodUtil.getHome().getGetFiscalPeriodForm();
15720
15721            form.setPeriodName(periodName);
15722            form.setUuid(id);
15723
15724            var period = CDI.current().select(GetFiscalPeriodCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), form);
15725
15726            return period == null ? null : new FiscalPeriodObject(period);
15727        } catch(NamingException ex) {
15728            throw new RuntimeException(ex);
15729        }
15730    }
15731
15732    @GraphQLField
15733    @GraphQLName("fiscalPeriods")
15734    @GraphQLNonNull
15735    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15736    static CountingPaginatedData<FiscalPeriodObject> fiscalPeriods(final DataFetchingEnvironment env,
15737            @GraphQLName("parentPeriodName") final String parentPeriodName,
15738            @GraphQLName("periodTypeName") final String periodTypeName) {
15739        CountingPaginatedData<FiscalPeriodObject> data = null;
15740
15741        try {
15742            var form = PeriodUtil.getHome().getGetFiscalPeriodsForm();
15743            var command = CDI.current().select(GetFiscalPeriodsCommand.class).get();
15744
15745            form.setParentPeriodName(parentPeriodName);
15746            form.setPeriodTypeName(periodTypeName);
15747
15748            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), form);
15749            if(totalEntities == null) {
15750                data = Connections.emptyConnection();
15751            } else {
15752                try(var objectLimiter = new ObjectLimiter(env, PeriodConstants.COMPONENT_VENDOR_NAME,
15753                        PeriodConstants.ENTITY_TYPE_NAME, totalEntities)) {
15754                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), form);
15755
15756                    var fiscalPeriodObjects = entities.stream().map(FiscalPeriodObject::new)
15757                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15758
15759                    return new CountedObjects<>(objectLimiter, fiscalPeriodObjects);
15760                }
15761            }
15762        } catch(NamingException ex) {
15763            throw new RuntimeException(ex);
15764        }
15765
15766        return data;
15767    }
15768
15769
15770    @GraphQLField
15771    @GraphQLName("linkCardinality")
15772    static LinkCardinalityObject linkCardinality(final DataFetchingEnvironment env,
15773            @GraphQLName("linkCardinalityName") final String linkCardinalityName,
15774            @GraphQLName("id") @GraphQLID final String id) {
15775        LinkCardinality linkCardinality;
15776
15777        try {
15778            var commandForm = CoreUtil.getHome().getGetLinkCardinalityForm();
15779
15780            commandForm.setLinkCardinalityName(linkCardinalityName);
15781            commandForm.setUuid(id);
15782
15783            linkCardinality = CDI.current().select(GetLinkCardinalityCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
15784        } catch (NamingException ex) {
15785            throw new RuntimeException(ex);
15786        }
15787
15788        return linkCardinality == null ? null : new LinkCardinalityObject(linkCardinality);
15789    }
15790
15791    @GraphQLField
15792    @GraphQLName("linkCardinalities")
15793    @GraphQLNonNull
15794    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15795    static CountingPaginatedData<LinkCardinalityObject> linkCardinalities(final DataFetchingEnvironment env) {
15796        CountingPaginatedData<LinkCardinalityObject> data;
15797
15798        try {
15799            var commandForm = CoreUtil.getHome().getGetLinkCardinalitiesForm();
15800            var command = CDI.current().select(GetLinkCardinalitiesCommand.class).get();
15801
15802            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15803            if(totalEntities == null) {
15804                data = Connections.emptyConnection();
15805            } else {
15806                try(var objectLimiter = new ObjectLimiter(env, LinkCardinalityConstants.COMPONENT_VENDOR_NAME, LinkCardinalityConstants.ENTITY_TYPE_NAME, totalEntities)) {
15807                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15808
15809                    var linkCardinalities = entities.stream()
15810                            .map(LinkCardinalityObject::new)
15811                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15812
15813                    data = new CountedObjects<>(objectLimiter, linkCardinalities);
15814                }
15815            }
15816        } catch (NamingException ex) {
15817            throw new RuntimeException(ex);
15818        }
15819
15820        return data;
15821    }
15822
15823    @GraphQLField
15824    @GraphQLName("linkDirectionality")
15825    static LinkDirectionalityObject linkDirectionality(final DataFetchingEnvironment env,
15826            @GraphQLName("linkDirectionalityName") final String linkDirectionalityName,
15827            @GraphQLName("id") @GraphQLID final String id) {
15828        LinkDirectionality linkDirectionality;
15829
15830        try {
15831            var commandForm = CoreUtil.getHome().getGetLinkDirectionalityForm();
15832
15833            commandForm.setLinkDirectionalityName(linkDirectionalityName);
15834            commandForm.setUuid(id);
15835
15836            linkDirectionality = CDI.current().select(GetLinkDirectionalityCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
15837        } catch (NamingException ex) {
15838            throw new RuntimeException(ex);
15839        }
15840
15841        return linkDirectionality == null ? null : new LinkDirectionalityObject(linkDirectionality);
15842    }
15843
15844    @GraphQLField
15845    @GraphQLName("linkDirectionalities")
15846    @GraphQLNonNull
15847    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15848    static CountingPaginatedData<LinkDirectionalityObject> linkDirectionalities(final DataFetchingEnvironment env) {
15849        CountingPaginatedData<LinkDirectionalityObject> data;
15850
15851        try {
15852            var commandForm = CoreUtil.getHome().getGetLinkDirectionalitiesForm();
15853            var command = CDI.current().select(GetLinkDirectionalitiesCommand.class).get();
15854
15855            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15856            if(totalEntities == null) {
15857                data = Connections.emptyConnection();
15858            } else {
15859                try(var objectLimiter = new ObjectLimiter(env, LinkDirectionalityConstants.COMPONENT_VENDOR_NAME, LinkDirectionalityConstants.ENTITY_TYPE_NAME, totalEntities)) {
15860                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15861
15862                    var linkDirectionalities = entities.stream()
15863                            .map(LinkDirectionalityObject::new)
15864                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15865
15866                    data = new CountedObjects<>(objectLimiter, linkDirectionalities);
15867                }
15868            }
15869        } catch (NamingException ex) {
15870            throw new RuntimeException(ex);
15871        }
15872
15873        return data;
15874    }
15875
15876    @GraphQLField
15877    @GraphQLName("link")
15878    static LinkObject link(final DataFetchingEnvironment env,
15879            @GraphQLName("linkTypeName") @GraphQLNonNull final String linkTypeName,
15880            @GraphQLName("sourceId") @GraphQLNonNull @GraphQLID final String sourceId,
15881            @GraphQLName("targetId") @GraphQLNonNull @GraphQLID final String targetId) {
15882        Link link;
15883
15884        try {
15885            var commandForm = CoreUtil.getHome().getGetLinkForm();
15886
15887            commandForm.setLinkTypeName(linkTypeName);
15888            commandForm.setSourceUuid(sourceId);
15889            commandForm.setTargetUuid(targetId);
15890
15891            link = CDI.current().select(GetLinkCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
15892        } catch (NamingException ex) {
15893            throw new RuntimeException(ex);
15894        }
15895
15896        return link == null ? null : new LinkObject(link);
15897    }
15898
15899    @GraphQLField
15900    @GraphQLName("links")
15901    @GraphQLNonNull
15902    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15903    static CountingPaginatedData<LinkObject> links(final DataFetchingEnvironment env,
15904            @GraphQLName("linkTypeName") final String linkTypeName,
15905            @GraphQLName("sourceId") @GraphQLID final String sourceId,
15906            @GraphQLName("targetId") @GraphQLID final String targetId) {
15907        CountingPaginatedData<LinkObject> data;
15908
15909        try {
15910            var commandForm = CoreUtil.getHome().getGetLinksForm();
15911            var command = CDI.current().select(GetLinksCommand.class).get();
15912
15913            commandForm.setLinkTypeName(linkTypeName);
15914            commandForm.setSourceUuid(sourceId);
15915            commandForm.setTargetUuid(targetId);
15916
15917            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15918            if(totalEntities == null) {
15919                data = Connections.emptyConnection();
15920            } else {
15921                try(var objectLimiter = new ObjectLimiter(env, LinkConstants.COMPONENT_VENDOR_NAME, LinkConstants.ENTITY_TYPE_NAME, totalEntities)) {
15922                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15923                    var links = entities.stream()
15924                            .map(LinkObject::new)
15925                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15926
15927                    data = new CountedObjects<>(objectLimiter, links);
15928                }
15929            }
15930        } catch (NamingException ex) {
15931            throw new RuntimeException(ex);
15932        }
15933
15934        return data;
15935    }
15936
15937    @GraphQLField
15938    @GraphQLName("linkType")
15939    static LinkTypeObject linkType(final DataFetchingEnvironment env,
15940            @GraphQLName("linkTypeName") final String linkTypeName,
15941            @GraphQLName("id") @GraphQLID final String id) {
15942        LinkType linkType;
15943
15944        try {
15945            var commandForm = CoreUtil.getHome().getGetLinkTypeForm();
15946
15947            commandForm.setLinkTypeName(linkTypeName);
15948            commandForm.setUuid(id);
15949
15950            linkType = CDI.current().select(GetLinkTypeCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
15951        } catch (NamingException ex) {
15952            throw new RuntimeException(ex);
15953        }
15954
15955        return linkType == null ? null : new LinkTypeObject(linkType);
15956    }
15957
15958    @GraphQLField
15959    @GraphQLName("linkTypes")
15960    @GraphQLNonNull
15961    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
15962    static CountingPaginatedData<LinkTypeObject> linkTypes(final DataFetchingEnvironment env,
15963            @GraphQLName("parentLinkTypeName") final String parentLinkTypeName,
15964            @GraphQLName("sourceComponentVendorName") final String sourceComponentVendorName,
15965            @GraphQLName("sourceEntityTypeName") final String sourceEntityTypeName,
15966            @GraphQLName("targetComponentVendorName") final String targetComponentVendorName,
15967            @GraphQLName("targetEntityTypeName") final String targetEntityTypeName,
15968            @GraphQLName("linkCardinalityName") final String linkCardinalityName,
15969            @GraphQLName("linkDirectionalityName") final String linkDirectionalityName,
15970            @GraphQLName("inverseLinkTypeName") final String inverseLinkTypeName) {
15971        CountingPaginatedData<LinkTypeObject> data;
15972
15973        try {
15974            var commandForm = CoreUtil.getHome().getGetLinkTypesForm();
15975            var command = CDI.current().select(GetLinkTypesCommand.class).get();
15976
15977            commandForm.setParentLinkTypeName(parentLinkTypeName);
15978            commandForm.setSourceComponentVendorName(sourceComponentVendorName);
15979            commandForm.setSourceEntityTypeName(sourceEntityTypeName);
15980            commandForm.setTargetComponentVendorName(targetComponentVendorName);
15981            commandForm.setTargetEntityTypeName(targetEntityTypeName);
15982            commandForm.setLinkCardinalityName(linkCardinalityName);
15983            commandForm.setLinkDirectionalityName(linkDirectionalityName);
15984            commandForm.setInverseLinkTypeName(inverseLinkTypeName);
15985
15986            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15987            if(totalEntities == null) {
15988                data = Connections.emptyConnection();
15989            } else {
15990                try(var objectLimiter = new ObjectLimiter(env, LinkTypeConstants.COMPONENT_VENDOR_NAME, LinkTypeConstants.ENTITY_TYPE_NAME, totalEntities)) {
15991                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
15992
15993                    var linkTypes = entities.stream()
15994                            .map(LinkTypeObject::new)
15995                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
15996
15997                    data = new CountedObjects<>(objectLimiter, linkTypes);
15998                }
15999            }
16000        } catch (NamingException ex) {
16001            throw new RuntimeException(ex);
16002        }
16003
16004        return data;
16005    }
16006
16007    @GraphQLField
16008    @GraphQLName("linkTypeTranslation")
16009    static LinkTypeTranslationObject linkTypeTranslation(final DataFetchingEnvironment env,
16010            @GraphQLName("linkTypeName") @GraphQLNonNull final String linkTypeName,
16011            @GraphQLName("languageIsoName") @GraphQLNonNull final String languageIsoName) {
16012        LinkTypeTranslation linkTypeTranslation;
16013
16014        try {
16015            var commandForm = CoreUtil.getHome().getGetLinkTypeTranslationForm();
16016
16017            commandForm.setLinkTypeName(linkTypeName);
16018            commandForm.setLanguageIsoName(languageIsoName);
16019
16020            linkTypeTranslation = CDI.current().select(GetLinkTypeTranslationCommand.class).get().getEntityForGraphQl(getUserVisitPK(env), commandForm);
16021        } catch (NamingException ex) {
16022            throw new RuntimeException(ex);
16023        }
16024
16025        return linkTypeTranslation == null ? null : new LinkTypeTranslationObject(linkTypeTranslation);
16026    }
16027
16028    @GraphQLField
16029    @GraphQLName("linkTypeTranslations")
16030    @GraphQLNonNull
16031    @GraphQLConnection(connectionFetcher = CountingDataConnectionFetcher.class)
16032    static CountingPaginatedData<LinkTypeTranslationObject> linkTypeTranslations(final DataFetchingEnvironment env,
16033            @GraphQLName("linkTypeName") @GraphQLNonNull final String linkTypeName) {
16034        CountingPaginatedData<LinkTypeTranslationObject> data;
16035
16036        try {
16037            var commandForm = CoreUtil.getHome().getGetLinkTypeTranslationsForm();
16038            var command = CDI.current().select(GetLinkTypeTranslationsCommand.class).get();
16039
16040            commandForm.setLinkTypeName(linkTypeName);
16041
16042            var totalEntities = command.getTotalEntitiesForGraphQl(getUserVisitPK(env), commandForm);
16043            if(totalEntities == null) {
16044                data = Connections.emptyConnection();
16045            } else {
16046                try(var objectLimiter = new ObjectLimiter(env, LinkTypeTranslationConstants.COMPONENT_VENDOR_NAME, LinkTypeTranslationConstants.ENTITY_TYPE_NAME, totalEntities)) {
16047                    var entities = command.getEntitiesForGraphQl(getUserVisitPK(env), commandForm);
16048
16049                    var linkTypeTranslations = entities.stream()
16050                            .map(LinkTypeTranslationObject::new)
16051                            .collect(Collectors.toCollection(() -> new ArrayList<>(entities.size())));
16052
16053                    data = new CountedObjects<>(objectLimiter, linkTypeTranslations);
16054                }
16055            }
16056        } catch (NamingException ex) {
16057            throw new RuntimeException(ex);
16058        }
16059
16060        return data;
16061    }
16062
16063}