/**
   * Every report should have a context map telling UCSD what its parent is. In this case, map it
   * back to the Spark account overview page.
   */
  @Override
  public ContextMapRule[] getMapRules() {
    DynReportContext context =
        ReportContextRegistry.getInstance().getContextByName(SparkConstants.INFRA_ACCOUNT_TYPE);
    ContextMapRule rule = new ContextMapRule();
    rule.setContextName(context.getId());
    rule.setContextType(context.getType());

    ContextMapRule[] rules = new ContextMapRule[1];
    rules[0] = rule;

    return rules;
  }
  @Override
  public ContextMapRule[] getMapRules() {
    DynReportContext context =
        ReportContextRegistry.getInstance().getContextByName(PureConstants.PURE_ACCOUNT_TYPE);
    ContextMapRule rule = new ContextMapRule();
    logger.info("ContextMapRule: context Id:" + context.getId());
    logger.info("ContextMapRule: ContextType:" + context.getType());
    rule.setContextName(context.getId());
    rule.setContextType(context.getType());

    ContextMapRule[] rules = new ContextMapRule[1];
    rules[0] = rule;

    return rules;
  }
  /**
   * Defines the report context map rule
   *
   * @return returns map rule
   */
  @Override
  public ContextMapRule[] getMapRules() {
    // i'm using an autogenerated report context (which I registered in FooModule), as mentioned in
    // documentation
    // the type may vary depending on deployments, so the safest way to retrieve the auto generated
    // type value
    // is to use the getContextByName api!
    DynReportContext dummyContextOneType =
        ReportContextRegistry.getInstance().getContextByName(SlimceaConstants.INFRA_ACCOUNT_TYPE);
    ContextMapRule rule = new ContextMapRule();
    rule.setContextName(dummyContextOneType.getId());
    rule.setContextType(dummyContextOneType.getType());

    ContextMapRule[] rules = new ContextMapRule[1];
    rules[0] = rule;

    return rules;
  }