com.elasticpath.domain.dataimport
Interface ImportDataType

All Superinterfaces:
EpDomain, java.io.Serializable, Transient
All Known Implementing Classes:
AbstractImportDataTypeImpl, ImportDataTypeCategoryImpl, ImportDataTypeCustomerAddressImpl, ImportDataTypeCustomerImpl, ImportDataTypeProductAssociationImpl, ImportDataTypeProductCategoryAssociationImpl, ImportDataTypeProductImpl, ImportDataTypeProductPriceImpl, ImportDataTypeProductSkuImpl, ImportDataTypeProductSkuPriceImpl

public interface ImportDataType
extends Transient

Represents an import data type.


Field Summary
static java.lang.String SEPARATOR
          Separtor used in import data type name.
 
Method Summary
 void clearValueObjects(Entity entity)
          Clear the value objects of the given entity.
 ValueObject createValueObject()
          Create and return a new value object.
 java.lang.String getGuidFieldName()
          Return the field name for guid.
 ImportField getImportField(java.lang.String importFieldName)
          Return an import field with the given name.
 java.util.Map getImportFields()
          Return all import fields as a Map The name of an import field will be used as key, and the import field itself will be put as a value.
 java.lang.String getImportJobRunnerBeanName()
          Returns the import job runner bean name.
 java.lang.Object getMetaObject()
          Returns the meta object used to intialize the import data type.
 java.lang.String getName()
          Returns import data type name.
 java.util.List getOptionalImportFields()
          Return all optional import fields.
 java.util.List getRequiredImportFields()
          Return all required import fields.
 void init(java.lang.Object baseObject)
          Initialize the import data type based on the given base object.
 boolean isEntityImport()
          Returns true if this import data type imports entity.
 boolean isValueObjectImport()
          Returns true if this import data type imports value object.
 void saveOrUpdate(Entity entity, ValueObject object)
          Add or update the given value object to the given entity.
 
Methods inherited from interface com.elasticpath.domain.EpDomain
getElasticPath, setElasticPath
 

Field Detail

SEPARATOR

static final java.lang.String SEPARATOR
Separtor used in import data type name.

See Also:
Constant Field Values
Method Detail

clearValueObjects

void clearValueObjects(Entity entity)
Clear the value objects of the given entity.

Parameters:
entity - the entity

createValueObject

ValueObject createValueObject()
Create and return a new value object.

Returns:
a new value object

getGuidFieldName

java.lang.String getGuidFieldName()
Return the field name for guid. If it doesn't exist, return null.

Returns:
the field name for guid

getImportField

ImportField getImportField(java.lang.String importFieldName)
Return an import field with the given name.

Parameters:
importFieldName - the import field name.
Returns:
an import field with the given name

getImportFields

java.util.Map getImportFields()
Return all import fields as a Map The name of an import field will be used as key, and the import field itself will be put as a value.

Returns:
all import fields as a Map

getImportJobRunnerBeanName

java.lang.String getImportJobRunnerBeanName()
Returns the import job runner bean name.

Returns:
the import job runner bean name.

getMetaObject

java.lang.Object getMetaObject()
Returns the meta object used to intialize the import data type.

Returns:
the meta object used to intialize the import data type

getName

java.lang.String getName()
Returns import data type name.

Returns:
import data type name.

getOptionalImportFields

java.util.List getOptionalImportFields()
Return all optional import fields.

Returns:
all optional import fields.

getRequiredImportFields

java.util.List getRequiredImportFields()
Return all required import fields.

Returns:
all required import fields.

init

void init(java.lang.Object baseObject)
Initialize the import data type based on the given base object.

Parameters:
baseObject - the base object used to initialize the import data type.

isEntityImport

boolean isEntityImport()
Returns true if this import data type imports entity.

Returns:
true if this import data type imports entity

isValueObjectImport

boolean isValueObjectImport()
Returns true if this import data type imports value object.

Returns:
true if this import data type imports value object

saveOrUpdate

void saveOrUpdate(Entity entity,
                  ValueObject object)
Add or update the given value object to the given entity.

Parameters:
entity - the entity
object - the value object