Package org.pentaho.reporting.libraries.resourceloader

Examples of org.pentaho.reporting.libraries.resourceloader.FactoryParameterKey


      throw new NullPointerException();
    }

    final ResourceKey bundleKey = getBundleMainKey().getParent();
    final ResourceBundleLoader o = (ResourceBundleLoader)
        bundleKey.getFactoryParameters().get(new FactoryParameterKey("repository-loader"));
    if (o == null)
    {
      throw new ResourceKeyCreationException("Unable to create a inner-bundle key, no loader available.");
    }
    return o.deriveKey(getBundleMainKey(), entryName, factoryParameters);
View Full Code Here


    }

    this.repository = repository;

    final HashMap<FactoryParameterKey, Object> map = new HashMap<FactoryParameterKey, Object>();
    map.put(new FactoryParameterKey("repository"), repository);
    map.put(new FactoryParameterKey("repository-loader"), this);

    this.bundleKey = new ResourceKey(outsideContextKey, SCHEMA, new Object(), map);
    final String bundleType = BundleUtilities.getBundleType(repository);
    final String bundleMapping = BundleUtilities.getBundleMapping(bundleType);
    if (bundleMapping == null)
View Full Code Here

    if (isSupportedKey(key) == false)
    {
      return null;
    }
    final RepositoryResourceBundleLoader o = (RepositoryResourceBundleLoader)
        key.getFactoryParameters().get(new FactoryParameterKey("repository-loader"));
    return o.loadBundle(resourceManager, key);
  }
View Full Code Here

    if (isSupportedKey(parent) == false)
    {
      throw new ResourceKeyCreationException();
    }
    final RepositoryResourceBundleLoader o = (RepositoryResourceBundleLoader)
        parent.getFactoryParameters().get(new FactoryParameterKey("repository-loader"));

    if ("true".equals(LibDocBundleBoot.getInstance().getGlobalConfig().getConfigProperty
        ("org.pentaho.reporting.libraries.docbundle.bundleloader.memory.StrictKeyCheck", "true")))
    {
      try
      {
        final Repository repository = (Repository) parent.getFactoryParameters().get(new FactoryParameterKey("repository"));
        if (RepositoryUtilities.isExistsEntity(repository, RepositoryUtilities.split(path, "/")) == false)
        {
          throw new ResourceKeyCreationException("The key does not exist: " + path);
        }
      }
View Full Code Here

  private boolean parseDataDefinition(final String parameterFile) throws ParseException
  {
    try
    {
      final Map parameters = deriveParseParameters();
      parameters.put(new FactoryParameterKey(ReportParserUtil.HELPER_OBJ_REPORT_NAME), null);
      final SubReportDataDefinition dataDefinition = (SubReportDataDefinition)
          performExternalParsing(parameterFile, SubReportDataDefinition.class, parameters);
      report.setDataFactory(dataDefinition.getDataFactory());
      report.setQuery(dataDefinition.getQuery());
      report.setQueryLimit(dataDefinition.getQueryLimit());
View Full Code Here

  private boolean parseLayout(final String layout) throws ParseException
  {
    try
    {
      final Map parameters = deriveParseParameters();
      parameters.put(new FactoryParameterKey(ReportParserUtil.HELPER_OBJ_REPORT_NAME), report);
      parameters.put(new FactoryParameterKey(ReportParserUtil.INCLUDE_PARSING_KEY),
          ReportParserUtil.INCLUDE_PARSING_VALUE);
      final MasterReport report = (MasterReport) performExternalParsing(layout, MasterReport.class, parameters);
      return report == this.report;
    }
    catch (ResourceLoadingException e)
View Full Code Here

  private boolean parseStyles(final String stylefile) throws ParseException
  {
    try
    {
      final Map parameters = deriveParseParameters();
      parameters.put(new FactoryParameterKey(ReportParserUtil.HELPER_OBJ_REPORT_NAME), report);
      parameters.put(new FactoryParameterKey(ReportParserUtil.INCLUDE_PARSING_KEY),
          ReportParserUtil.INCLUDE_PARSING_VALUE);
      final MasterReport report = (MasterReport) performExternalParsing(stylefile, MasterReport.class, parameters);
      return report == this.report;
    }
    catch (ResourceLoadingException e)
View Full Code Here

  private boolean parseDataDefinition(final String parameterFile) throws ParseException
  {
    try
    {
      final Map parameters = deriveParseParameters();
      parameters.put(new FactoryParameterKey(ReportParserUtil.HELPER_OBJ_REPORT_NAME), null);
      final DataDefinition dataDefinition = (DataDefinition)
          performExternalParsing(parameterFile, DataDefinition.class, parameters);

      report.setQuery(dataDefinition.getQuery());
      report.setQueryLimit(dataDefinition.getQueryLimit());
View Full Code Here

  private boolean parseSettings(final String settingsFile) throws ParseException
  {
    try
    {
      final Map parameters = deriveParseParameters();
      parameters.put(new FactoryParameterKey(ReportParserUtil.HELPER_OBJ_REPORT_NAME), null);
      final BundleSettings settings = (BundleSettings)
          performExternalParsing(settingsFile, BundleSettings.class, parameters);
      // todo: Apply settings
      final Configuration configuration = settings.getConfiguration();
      final Enumeration configProperties = configuration.getConfigProperties();
View Full Code Here

  private boolean parseDataSchema() throws ParseException
  {
    try
    {
      final Map parameters = deriveParseParameters();
      parameters.put(new FactoryParameterKey(ReportParserUtil.HELPER_OBJ_REPORT_NAME), null);
      final DataSchemaDefinition metaData = (DataSchemaDefinition)
          performExternalParsing("dataschema.xml", DataSchemaDefinition.class, parameters);
      report.setDataSchemaDefinition(metaData);
      return true;
    }
View Full Code Here

TOP

Related Classes of org.pentaho.reporting.libraries.resourceloader.FactoryParameterKey

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.