// Get the dimensions. Cast the Product dimension as an MdmStandardDimension
// so that it has a createCustomMember method.
MdmStandardDimension mdmProdStdDim = (MdmStandardDimension)
getMdmPrimaryDimension("PRODUCT_AW");
MdmPrimaryDimension mdmTimeDim = getMdmPrimaryDimension("TIME_AW");
MdmPrimaryDimension mdmChanDim = getMdmPrimaryDimension("CHANNEL_AW");
MdmPrimaryDimension mdmCustDim = getMdmPrimaryDimension("CUSTOMER_AW");
// Get the Source for the product dimension.
Source prodStdDim = mdmProdStdDim.getSource();
// Get the marketing manager attribute and the Source for it.
MdmAttribute mdmMktMngrAttr = getContext().getAttributeByName(mdmProdStdDim,
"MARKETING_MANAGER_AW");
Source mktMngrAttr = mdmMktMngrAttr.getSource();
// Get the default hierarchies of the dimensions and the Source objects
// for them.
MdmLevelHierarchy mdmCalendar = (MdmLevelHierarchy)
mdmTimeDim.getDefaultHierarchy();
MdmLevelHierarchy mdmProdHier = (MdmLevelHierarchy)
mdmProdStdDim.getDefaultHierarchy();
MdmLevelHierarchy mdmChanHier = (MdmLevelHierarchy)
mdmChanDim.getDefaultHierarchy();
MdmLevelHierarchy mdmShipHier = (MdmLevelHierarchy)
mdmCustDim.getDefaultHierarchy();
StringSource calendar = (StringSource) mdmCalendar.getSource();
StringSource prodHier = (StringSource) mdmProdHier.getSource();
StringSource chanHier = (StringSource) mdmChanHier.getSource();
StringSource shipHier = (StringSource) mdmShipHier.getSource();