public class BMECatCatalogStep extends GeneratedBMECatCatalogStep
BMECatImportStep.DefaultBMECatObjectProcessorGenericItem.GenericItemImplLocalizableItem.LocalizableItemImplExtensibleItem.ExtensibleItemImplItem.AttributeFilter, Item.AttributeMode, Item.CachedGetter, Item.CachedSetter, Item.ItemAttributeMap, Item.ItemConstraint, Item.ItemImpl, Item.JaloCachedComputationExceptionADDRESSATTRIBUTEMAPPING, ADDRESSTYPE, AGREEMENTATTRIBUTEMAPPING, AGREEMENTTYPE, BUYERATTRIBUTEMAPPING, BUYERTYPE, CATALOGATTRIBUTEMAPPING, CATALOGTYPE, CATALOGVERSIONATTRIBUTEMAPPING, CATALOGVERSIONTYPE, DEFAULT_INITIAL_ATTRIBUTES, SUPPLIERATTRIBUTEMAPPING, SUPPLIERTYPEXML_MIME_TYPE, ZIP_MIME_TYPEBATCHJOB, CODE, CRONJOBPENDINGSTEPSRELATION_MARKMODIFIED, CRONJOBPENDINGSTEPSRELATION_SRC_ORDERED, CRONJOBPENDINGSTEPSRELATION_TGT_ORDERED, CRONJOBPROCESSEDSTEPSRELATION_MARKMODIFIED, CRONJOBPROCESSEDSTEPSRELATION_SRC_ORDERED, CRONJOBPROCESSEDSTEPSRELATION_TGT_ORDERED, ERRORMODE, PENDINGCRONJOBS, PROCESSEDCRONJOBS, SEQUENCENUMBER, SYNCHRONOUSLANGUAGE_FALLBACK_ENABLED_CREATION_TIME_INTERNAL, _MODIFIED_TIME_INTERNAL, accessorLog, CREATION_TIME, DISABLE_ATTRIBUTE_CHECK, DISABLE_ITEMCHECK_BEFORE_REMOVABLE, EVEN, FEATURE_ACCESSMAP_QUALIFIER, INITIAL_CREATION_FLAG, isJaloOnly, MODIFIED_TIME, NEGATIVE, NOT_FOUND, OWNER, PK, POSITIVE, SAVE_FROM_SERVICE_LAYER, staticTransientObjects, TYPEimpl, tenant| Constructor and Description |
|---|
BMECatCatalogStep() |
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
canUndo(CronJob forSchedule)
Declares that this step can be undone.
|
void |
checkConstraints(Catalog catalogValueObject,
BMECatImportCronJob cronJob)
Checks which catalog objects exists and which information has already been set to the CronJob by the infoStep (if
exists).
|
Agreement |
createAgreement(BMECatImportCronJob cronJob,
Item.ItemAttributeMap values)
Creates agreement
|
protected Catalog |
createCatalog(BMECatImportCronJob cronJob,
Item.ItemAttributeMap values)
Creates catalog
|
protected CatalogVersion |
createCatalogVersion(BMECatImportCronJob cronJob,
Item.ItemAttributeMap values)
Creates catalog version
|
protected Map |
createDefaultAddressMapping(ComposedType addressType) |
protected Map |
createDefaultAgreementMapping(ComposedType agreementType) |
protected Map |
createDefaultCatalogMapping(ComposedType catalogType) |
protected Map |
createDefaultCatalogVersionMapping(ComposedType catalogVersionType) |
protected Map |
createDefaultCompanyMapping(ComposedType companyType) |
protected Item.ItemAttributeMap |
getAddressValues(BMECatImportCronJob cronJob,
Company owner,
Address addressValueObject,
boolean create)
|
protected Item.ItemAttributeMap |
getAgreementValues(BMECatImportCronJob cronJob,
Agreement agreementValueObject)
|
protected Item.ItemAttributeMap |
getCatalogValues(BMECatImportCronJob cronJob,
Catalog catalogValueObject,
Catalog catalog)
|
protected Item.ItemAttributeMap |
getCatalogVersionValues(BMECatImportCronJob cronJob,
Catalog catalogValueObject)
Returns an
ItemAttributeMap containing all extracted values of the provided catalog value object. |
protected Item.ItemAttributeMap |
getCatalogVersionValues(BMECatImportCronJob cronJob,
Catalog catalogValueObject,
CatalogVersion catalogVersion)
Translates attributes of value object
Catalog into attributes of the item
CatalogVersion |
protected Item.ItemAttributeMap |
getCompanyValues(BMECatImportCronJob cronJob,
Company company,
Map mapping,
Company companyValueObject)
|
protected Collection |
getOrCreateAddresses(BMECatImportCronJob cronJob,
Company owner,
Address addressValueObject)
gets or create an address for parameters contained in addressValueObject
|
protected Collection |
getOrCreateAgreements(BMECatImportCronJob cronJob,
Catalog catalogValueObject)
Get or creates the provided aggrements provided in the specified catalog value object.
|
protected Company |
getOrCreateBuyer(BMECatImportCronJob cronJob,
Company companyValueObject) |
protected Company |
getOrCreateCompany(BMECatImportCronJob cronJob,
ComposedType companyType,
Map mapping,
Company companyValueObject)
Gets an existing company by company name or creates a new with the given parameters (mapping)
|
protected Region |
getOrCreateRegion(CronJob cronJob,
Country jaloCountry,
String state)
Gets existing region by parameter "state" or creates new
|
protected Company |
getOrCreateSupplier(BMECatImportCronJob cronJob,
Company companyValueObject) |
protected Item.ItemAttributeMap |
getPartOfCompanyValues(BMECatImportCronJob cronJob,
Company company,
Map mapping,
Company companyValueObject)
|
protected Region |
getRegion(CronJob cronJob,
Country jaloCountry,
String state)
Gets existing region by parameter "state"
|
protected void |
importBMECatObject(Catalog catalog,
AbstractValueObject object,
BMECatImportCronJob cronJob)
Throws a
ParseAbortException in case of an (test-)abort otherwise does nothing. |
protected void |
importCatalog(BMECatImportCronJob cronJob,
Catalog catalogValueObject)
Imports catalog and catalog version
|
protected void |
initializeAttributeEnumValues()
Creates enumeration values which represent BMECat elements or attributes.
|
protected void |
initializeBMECatImport(Catalog cat,
BMECatImportCronJob cronJob)
Checks start constraints and creates the new catalog.
|
void |
remove(SessionContext ctx)
Removes this item.
|
void |
setNonInitialAttributes(SessionContext ctx,
Item item,
Item.ItemAttributeMap nonInitialAttributes)
Implements default setting of category type and the attribute mapping if these attributes are not specified during
step creation.
|
protected void |
undoStep(CronJob forSchedule)
Removes created catalog version and catalog.
|
protected void |
updateCatalog(BMECatImportCronJob cronJob,
Catalog catalog,
Catalog catalogValueObject) |
protected void |
updateCatalogVersion(BMECatImportCronJob cronJob,
CatalogVersion catalogVersion,
Catalog catalogValueObject) |
getAddressType, getAddressType, getAgreementType, getAgreementType, getAllAddressAttributeMapping, getAllAddressAttributeMapping, getAllAgreementAttributeMapping, getAllAgreementAttributeMapping, getAllBuyerAttributeMapping, getAllBuyerAttributeMapping, getAllCatalogAttributeMapping, getAllCatalogAttributeMapping, getAllCatalogVersionAttributeMapping, getAllCatalogVersionAttributeMapping, getAllSupplierAttributeMapping, getAllSupplierAttributeMapping, getBuyerType, getBuyerType, getCatalogType, getCatalogType, getCatalogVersionType, getCatalogVersionType, getDefaultAttributeModes, getSupplierType, getSupplierType, setAddressType, setAddressType, setAgreementType, setAgreementType, setAllAddressAttributeMapping, setAllAddressAttributeMapping, setAllAgreementAttributeMapping, setAllAgreementAttributeMapping, setAllBuyerAttributeMapping, setAllBuyerAttributeMapping, setAllCatalogAttributeMapping, setAllCatalogAttributeMapping, setAllCatalogVersionAttributeMapping, setAllCatalogVersionAttributeMapping, setAllSupplierAttributeMapping, setAllSupplierAttributeMapping, setBuyerType, setBuyerType, setCatalogType, setCatalogType, setCatalogVersionType, setCatalogVersionType, setSupplierType, setSupplierTypecanPerform, createKeyword, createProcessor, customizeImport, finalizeStep, getBMECatManager, getCatalogManager, getCompletedCount, getCompletionStatus, getData, getOrCreateKeywords, getProduct, getTotalToComplete, isAbortable, performStep, writeToFileaddChange, createItem, debug, error, fatal, getChanges, getChanges, getChanges, getChanges, getFailErrorMode, getIgnoreErrorMode, getMostRecentChange, getNonInitialAttributes, getPauseErrorMode, hasChanges, info, isDebugEnabled, isErrorEnabled, isInfoEnabled, isWarnEnabled, log, toString, warngetBatchJob, getBatchJob, getCode, getCode, getErrorMode, getErrorMode, getSequenceNumber, getSequenceNumber, getSequenceNumberAsPrimitive, getSequenceNumberAsPrimitive, isSynchronous, isSynchronous, isSynchronousAsPrimitive, isSynchronousAsPrimitive, setBatchJob, setBatchJob, setCode, setCode, setErrorMode, setErrorMode, setSequenceNumber, setSequenceNumber, setSequenceNumber, setSequenceNumber, setSynchronous, setSynchronous, setSynchronous, setSynchronousgetInitialPropertiesgetAllLocalizedProperties, getAllLocalizedProperties, getAllLocalizedProperties, getAllLocalizedProperties, getAllValuesSessionContext, getLocalizedProperty, getLocalizedProperty, getLocalizedPropertyInternal, getLocalizedPropertyNames, getLocalizedPropertyNames, hasLanguage, isEmptyValue, isFallbackEnabled, removeLocalizedProperty, removeLocalizedProperty, setAllLocalizedProperties, setAllLocalizedProperties, setLocalizedProperty, setLocalizedPropertycreateNonClassAccessor, getAllProperties, getAllProperties, getProperty, getProperty, getPropertyNames, getPropertyNames, removeProperty, removeProperty, setAllProperties, setAllProperties, setProperty, setPropertyaddLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addNegativePermission, addPermission, addPositivePermission, assureExtensionsLoaded, changeTypeAfterCreation, checkConstraint, checkItemPermission, checkMandatoryAttribute, checkMandatoryAttribute, checkPermission, checkPermission, checkRemovable, clearPermission, compareTo, ctx, doAfterRemove, doBeforeRemove, equals, getAccessorFor, getAllAttributes, getAllAttributes, getAllAttributes, getAllAttributes, getAllAttributesInternal, getAllLinkedItems, getAndCheckCacheBoundItem, getAttribute, getAttribute, getCacheBoundItem, getComposedType, getComposedTypePK, getCreationTime, getCurrentlyRemovingCount, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItemsCount, getLinkedItemsCount, getLinkedItemsCount, getModificationTime, getNegativePermissions, getOwner, getPermissionMap, getPermissions, getPersistenceVersion, getPK, getPositivePermissions, getRestrictedPrincipals, getSession, getSyncObject, getTenant, getTransientObject, getTransientObjectMap, hashCode, hasRegisteredClassAccessorFor, internal_registerClassAccessorFor, internal_registerNonClassAccessorFor, invalidateLocalCaches, isAlive, isCacheBound, isCurrentlyRemoving, isCurrentlyRemoving, isEmptyRelationValue, isInCreate, isInstanceOf, isItemCheckBeforeRemoveableDisabled, isRelationLocalizationFallbackEnabled, newInstance, notifyExtensionsAfterItemCreation, notifyExtensionsBeforeItemCreation, notifyItemRemoval, readResolve, refreshRemote, registerAccessFor, registerAccessFor, registerJaloInvalidationListeners, remove, removeItemCollection, removeItemCollection, removeLinkedItems, removeLinkedItems, removeLinkedItems, removeLinkedItems, removeLinks, removePartOfItems, removePartOfItems, setAllAttributes, setAllAttributes, setAllAttributesInternal, setAllLinkedItems, setAllLinkedItems, setAllLinkedItems, setAllLinkedItems, setAttribute, setAttribute, setAttributeFromString, setAttributeFromString, setCacheBound, setComposedType, setCreationTime, setImplementation, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setModificationTime, setOwner, setPermissionsByMap, setTransientObject, setUseTA, useTA, writeReplacegetImplementation, setTenantprotected EnumerationValue CATALOG_ID
protected EnumerationValue CATALOG_NAME
protected EnumerationValue CATALOG_SUPPLIER
protected EnumerationValue CATALOGVERSION_AGREEMENT
protected EnumerationValue CATALOG_BUYER
protected EnumerationValue CATALOGVERSION_DEFAULTCURRENCY
protected EnumerationValue CATALOGVERSION_GENERATIONDATE
protected EnumerationValue CATALOGVERSION_GENERATORINFO
protected EnumerationValue CATALOGVERSION_INCLASSURANCE
protected EnumerationValue CATALOGVERSION_INCLDUTY
protected EnumerationValue CATALOGVERSION_INCLFREIGHT
protected EnumerationValue CATALOGVERSION_INCLPACKING
protected EnumerationValue CATALOGVERSION_LANGUAGE
protected EnumerationValue CATALOGVERSION_MIMEROOTDIRECTORY
protected EnumerationValue CATALOGVERSION_TERRITORIES
protected EnumerationValue CATALOGVERSION_FEATURESYSTEM
protected EnumerationValue CATALOGVERSION_VERSION
protected EnumerationValue CATALOGVERSION_CATALOG
protected EnumerationValue COMPANY_NAME
protected EnumerationValue COMPANY_ID
protected EnumerationValue COMPANY_BUYERSPECIFICID
protected EnumerationValue COMPANY_SUPPLIERSPECIFICID
protected EnumerationValue COMPANY_ILNID
protected EnumerationValue COMPANY_DUNSID
protected EnumerationValue COMPANY_ADDRESS
protected EnumerationValue ADDRESS_NAME
protected EnumerationValue ADDRESS_NAME2
protected EnumerationValue ADDRESS_NAME3
protected EnumerationValue ADDRESS_CONTACT
protected EnumerationValue ADDRESS_STREET
protected EnumerationValue ADDRESS_ZIP
protected EnumerationValue ADDRESS_BOXNO
protected EnumerationValue ADDRESS_ZIPBOX
protected EnumerationValue ADDRESS_CITY
protected EnumerationValue ADDRESS_STATE
protected EnumerationValue ADDRESS_COUNTRY
protected EnumerationValue ADDRESS_PHONE
protected EnumerationValue ADDRESS_FAX
protected EnumerationValue ADDRESS_EMAIL
protected EnumerationValue ADDRESS_PUBLICKEY
protected EnumerationValue ADDRESS_URL
protected EnumerationValue ADDRESS_REMARKS
protected EnumerationValue AGREEMENT_ID
protected EnumerationValue AGREEMENT_STARTDATE
protected EnumerationValue AGREEMENT_ENDDATE
protected EnumerationValue AGREEMENT_CATALOGVERSION
public void remove(SessionContext ctx) throws ConsistencyCheckException
Item
This method is using the following attributes of the given SessionContext:
| CacheUsage | Language | StagingMethod | ||
|---|---|---|---|---|
| n/a (this is a setter method) | no, language doesn't matter for removal | yes if called on a StageableItem, no otherwise |
remove in class BMECatImportStepctx - A SessionContext objectConsistencyCheckException - if this item could not be removed for some reasonItem.remove(SessionContext)public void setNonInitialAttributes(SessionContext ctx, Item item, Item.ItemAttributeMap nonInitialAttributes) throws JaloBusinessException
setNonInitialAttributes in class Stepctx - item - nonInitialAttributes - JaloBusinessExceptionprotected boolean canUndo(CronJob forSchedule)
canUndo in class StepforSchedule - the CronJob which is used for executionStep.canUndo(de.hybris.platform.cronjob.jalo.CronJob)protected void undoStep(CronJob forSchedule)
undoStep in class BMECatImportStepforSchedule - context of step executionStep.undoStep(de.hybris.platform.cronjob.jalo.CronJob)protected void initializeBMECatImport(Catalog cat, BMECatImportCronJob cronJob) throws ParseAbortException
initializeBMECatImport in class BMECatImportStepcat - cronJob - ParseAbortExceptionBMECatImportStep.initializeBMECatImport(de.hybris.platform.bmecat.parser.Catalog, BMECatImportCronJob)protected void importBMECatObject(Catalog catalog, AbstractValueObject object, BMECatImportCronJob cronJob) throws ParseAbortException
ParseAbortException in case of an (test-)abort otherwise does nothing.importBMECatObject in class BMECatImportStepcatalog - object - cronJob - ParseAbortExceptionBMECatImportStep.importBMECatObject(de.hybris.platform.bmecat.parser.Catalog, AbstractValueObject,
BMECatImportCronJob)public void checkConstraints(Catalog catalogValueObject, BMECatImportCronJob cronJob)
catalogValueObject - value object for catalog tagcronJob - context in which the step runsprotected void importCatalog(BMECatImportCronJob cronJob, Catalog catalogValueObject) throws ParseAbortException
cronJob - catalogValueObject - ParseAbortExceptionprotected void updateCatalogVersion(BMECatImportCronJob cronJob, CatalogVersion catalogVersion, Catalog catalogValueObject)
cronJob - catalogVersion - catalogValueObject - protected void updateCatalog(BMECatImportCronJob cronJob, Catalog catalog, Catalog catalogValueObject)
cronJob - catalog - catalogValueObject - protected Item.ItemAttributeMap getCatalogVersionValues(BMECatImportCronJob cronJob, Catalog catalogValueObject)
ItemAttributeMap containing all extracted values of the provided catalog value object. The
keys of the map are the attribute qualifiers which are determined using the configured attribute mapping, the
values are the actual attribute values.cronJob - the currenct cronJobcatalogValueObject - the catalog value object, the values will be extracted fromItemAttributeMap containing all extracted values of the provided catalog value objectprotected Collection getOrCreateAgreements(BMECatImportCronJob cronJob, Catalog catalogValueObject)
cronJob - The current import cronJob.catalogValueObject - The catalog value object containing the actual data.Agreements according to the values of the catalog
value object.public Agreement createAgreement(BMECatImportCronJob cronJob, Item.ItemAttributeMap values)
values - paramter for agreement creation Agreementprotected Catalog createCatalog(BMECatImportCronJob cronJob, Item.ItemAttributeMap values)
values - parameter for catalog creation Catalogprotected CatalogVersion createCatalogVersion(BMECatImportCronJob cronJob, Item.ItemAttributeMap values)
values - parameter for catalog creationprotected Company getOrCreateCompany(BMECatImportCronJob cronJob, ComposedType companyType, Map mapping, Company companyValueObject)
cronJob - context of this stepcompanyType - type of company to be createdmapping - Maps company tags/attributes to company item attributescompanyValueObject - value object containing information about parsed <BUYER> <SUPPLIER> tagprotected Region getOrCreateRegion(CronJob cronJob, Country jaloCountry, String state)
jaloCountry - state - protected Region getRegion(CronJob cronJob, Country jaloCountry, String state)
jaloCountry - state - protected Collection getOrCreateAddresses(BMECatImportCronJob cronJob, Company owner, Address addressValueObject)
cronJob - owner - addressValueObject - protected Item.ItemAttributeMap getAddressValues(BMECatImportCronJob cronJob, Company owner, Address addressValueObject, boolean create)
cronJob - owner - addressValueObject - create - Address attribute qualifiers to values extracted from the given BMECat value
objectprotected Item.ItemAttributeMap getAgreementValues(BMECatImportCronJob cronJob, Agreement agreementValueObject)
cronJob - agreementValueObject - Agreement attribute qualifiers to values extracted from the given BMECat value
objectprotected Item.ItemAttributeMap getCompanyValues(BMECatImportCronJob cronJob, Company company, Map mapping, Company companyValueObject)
cronJob - companyValueObject - Company attribute qualifiers to values extracted from the given BMECat value
objectprotected Item.ItemAttributeMap getPartOfCompanyValues(BMECatImportCronJob cronJob, Company company, Map mapping, Company companyValueObject)
cronJob - company - mapping - companyValueObject - Company attribute qualifiers to values extracted from the given BMECat value
objectprotected Item.ItemAttributeMap getCatalogValues(BMECatImportCronJob cronJob, Catalog catalogValueObject, Catalog catalog) throws ParseAbortException
cronJob - catalogValueObject - Catalog attribute qualifiers to values extracted from the given BMECat value
objectParseAbortExceptionprotected Item.ItemAttributeMap getCatalogVersionValues(BMECatImportCronJob cronJob, Catalog catalogValueObject, CatalogVersion catalogVersion)
Catalog into attributes of the item
CatalogVersioncronJob - catalogValueObject - catalogVersion - CatalogVersion attribute qualifiers to values extracted from the given BMECat
value objectprotected Map createDefaultAddressMapping(ComposedType addressType)
protected Map createDefaultAgreementMapping(ComposedType agreementType)
protected Map createDefaultCatalogMapping(ComposedType catalogType)
protected Map createDefaultCatalogVersionMapping(ComposedType catalogVersionType)
protected Map createDefaultCompanyMapping(ComposedType companyType)
protected void initializeAttributeEnumValues()
protected Company getOrCreateBuyer(BMECatImportCronJob cronJob, Company companyValueObject)
protected Company getOrCreateSupplier(BMECatImportCronJob cronJob, Company companyValueObject)
Copyright © 2017 SAP SE. All Rights Reserved.