import { DataHierarchyProvider } from '../../libappsop/datahierarchy'; 
 | 
export enum DataMetalBaseSalesSegmentName { 
 | 
  AllOrganics = 'All Organics', 
 | 
  AllSalesSegments = 'All Sales Segments', 
 | 
  AudiA8 = 'Audi A8', 
 | 
  Automotive = 'Automotive', 
 | 
  BMWi3 = 'BMW i3', 
 | 
  Cans = 'Cans', 
 | 
  CanManChina = 'CanMan China', 
 | 
  SpecialCan = 'Special Can', 
 | 
  Volkswagen = 'Volkswagen', 
 | 
} 
 | 
  
 | 
const dataSalesSegment = { 
 | 
  BMW: {Name: {Name: 'BMW'}, Parents: [{Name: DataMetalBaseSalesSegmentName.AllSalesSegments}, {Name: DataMetalBaseSalesSegmentName.Automotive}]}, 
 | 
}; 
 | 
  
 | 
/** 
 | 
 * Define the row name and its immediate parent (no need define all ancestors for easier maintenance and readability). 
 | 
 * Create a DataHierarchyProvider object to store and query row ancestors to use in spec file. 
 | 
 */ 
 | 
export const dataFoodSalesSegment = { 
 | 
  Carrefour: { Name: 'Carrefour', NameKey: 'Carrefour', ParentKey: ''}, 
 | 
  Target: { Name: 'Target', NameKey: 'Target', ParentKey: ''}, 
 | 
  
 | 
}; 
 | 
  
 | 
export const dataMetalsSalesSegment = { 
 | 
  AllSalesSegments: { Name: 'All Sales Segments', NameKey: 'AllSalesSegments', ParentKey: ''}, 
 | 
  Cans: { Name: 'Cans', NameKey: 'Cans', ParentKey: 'AllSalesSegments'}, 
 | 
  AsiaSegment: { Name: 'Asia Segment', NameKey: 'AsiaSegment', ParentKey: 'Cans'}, 
 | 
  SpecialCan: { Name: 'Special Can', NameKey: 'SpecialCan', ParentKey: 'AsiaSegment'}, 
 | 
  
 | 
}; 
 | 
  
 | 
export { dataSalesSegment as DataSalesSegment }; 
 | 
export const dataFoodSalesSegmentProvider: DataHierarchyProvider = new DataHierarchyProvider(dataFoodSalesSegment); 
 | 
export const dataMetalsSalesSegmentProvider: DataHierarchyProvider = new DataHierarchyProvider(dataMetalsSalesSegment); 
 |