All Data Structures Functions Variables Pages
Static Public Member Functions
MappingRuleFormAndElementTypeUtil Class Reference

Static Public Member Functions

static makeCollectionByAttributeImportRules ($attributeImportRules, $attributeIndexOrDerivedType, $columnType)
 
static makeFormsAndElementTypesByMappingDataAndImportRulesType ($mappingData, $importRulesType)
 
static makeForm ($importRulesType, $attributeIndexOrDerivedType, $mappingRuleFormClassName)
 
static validateMappingRuleForms ($mappingDataMappingRuleFormsData)
 

Detailed Description

Helper class for working with MappingRuleForms and Element types that are used with those forms.

Definition at line 40 of file MappingRuleFormAndElementTypeUtil.php.

Member Function Documentation

static makeCollectionByAttributeImportRules (   $attributeImportRules,
  $attributeIndexOrDerivedType,
  $columnType 
)
static

Given an array of AttributeImportRules an attribute index or derived type, make a MappingRuleForm

Parameters
$attributeImportRules
$attributeIndexOrDerivedType
$columnType
Returns
array
Exceptions
NotSupportedException

Definition at line 50 of file MappingRuleFormAndElementTypeUtil.php.

static makeFormsAndElementTypesByMappingDataAndImportRulesType (   $mappingData,
  $importRulesType 
)
static

Given an array of mapping data and an import rules type, make an array of mapping rule forms and element types. This is indexed by the column name from the mapping data. If the type of column is 'extraColumn', then the mapping rules forms will be set with the scenario 'extraColumn'.

Parameters
array$mappingData
string$importRulesType

Definition at line 90 of file MappingRuleFormAndElementTypeUtil.php.

static makeForm (   $importRulesType,
  $attributeIndexOrDerivedType,
  $mappingRuleFormClassName 
)
static

Make a mapping rule form object.

Parameters
string$importRulesType
string$attributeIndexOrDerivedType
string$mappingRuleFormClassName

Definition at line 134 of file MappingRuleFormAndElementTypeUtil.php.

static validateMappingRuleForms (   $mappingDataMappingRuleFormsData)
static

Given an array of mappingDataMappingRuleForms data, validate each form. If any form does not validate, then return false. The mappingDataMappingRuleForms array is organized by columnNames, then by the mapping rules for each column.

Parameters
array$mappingDataMappingRuleFormsAndElementTypes
Returns
true/false validation results.

Definition at line 157 of file MappingRuleFormAndElementTypeUtil.php.


The documentation for this class was generated from the following file:
Generated on Fri Feb 28 2020 07:10:53