Foundations Apex API Developer Reference

fferpcore.MappingDescriber

global abstract class MappingDescriber

Base class that is extended to define a mapping describer.
Required if using the FDN Mappings component.
You must reference the name of the concrete class in the Small Data field of a Foundations configuration item record.
The Process field on the record must contain the following value: Foundations Mapping Process.

Methods

getSourceContext

global abstract fferpcore.Context getSourceContext()

Specify the type of source objects that the mappings will read.
Concrete implementations exist for typical usage.

Return Value

An instance of a concrete Context.

Sample Data

new fferpcore.Context.SObjectContext(Account.SObjectType)

getTargetContext

global abstract fferpcore.Context getTargetContext()

Specify the type of target object that the mappings will write to.
Concrete implementations exist for typical usage.

Return Value

An instance of a concrete Context.

Sample Data

new fferpcore.Context.SObjectContext(Account.SObjectType)

getManagedMappings

global virtual List<fferpcore.TransformMapping> getManagedMappings()

Specify any managed mappings that are fixed and therefore not configurable by the user.
Returns an empty list by default if not overridden.

Return Value

A list of TransformMapping instances, each corresponding to a single managed mapping.

getCustomMappings

global virtual List<fferpcore.MappingService.CustomMapping> getCustomMappings(String process)

Specify any custom mappings for the mapping process.
Required only if the mapping process does not store custom mappings as Foundations mapping records.

Input Parameters

Name Type Description
process String The process name using this MappingDescriber.

Return Value

A list of MappingService.CustomMapping instances, each corresponding to a single custom mapping.

saveCustomMappings

global virtual void saveCustomMappings(String process, List<fferpcore.MappingService.CustomMapping> customMappings)

Specify how any custom mappings should be saved.
Required only if the mapping process does not store custom mappings as Foundations mapping records.

Input Parameters

Name Type Description
process String The process name using this MappingDescriber.
customMappings List<fferpcore.MappingService.CustomMapping> The list of custom mappings to be saved. The save is not incremental so this list will always include every custom mapping for the process.

supportsCustomMappings

global virtual Boolean supportsCustomMappings()

Return Value

Whether this mapping process supports custom mappings. True if not overridden.

© Copyright 2009–2021 FinancialForce.com, inc. All rights reserved. Various trademarks held by their respective owners.