Examples of createKey()


Examples of org.pentaho.reporting.libraries.resourceloader.ResourceManager.createKey()

    final ResourceManager manager = new ResourceManager();
    manager.registerDefaults();

    factoryParams.put(new FactoryParameterKey("this"), "that");
    factoryParams.put(new FactoryParameterKey("null"), null);
    final ResourceKey originalKey = manager.createKey(URL1, factoryParams);

    final String serializedVersion = resourceLoader.serialize(null, originalKey);
    final ResourceKey duplicateKey = resourceLoader.deserialize(null, serializedVersion);
    assertNotNull(duplicateKey);
    assertTrue(originalKey.equals(duplicateKey));
View Full Code Here

Examples of org.pentaho.reporting.libraries.resourceloader.ResourceManager.createKey()

    parameters.put(ClassicEngineFactoryParameters.ORIGINAL_VALUE, "c:\\invalid dir\\test.png");
    parameters.put(ClassicEngineFactoryParameters.MIME_TYPE, mimeType);
    parameters.put(ClassicEngineFactoryParameters.PATTERN, pattern);
    parameters.put(ClassicEngineFactoryParameters.EMBED, "true"); // NON-NLS
    // create an embedded key in here.
    return resMgr.createKey(bout.toByteArray(), parameters);
  }
}

// need parser fix: On PRD load, the resource-keys loaded must be made embedded-as-edited, and thus must
// be byte-arrays on the key with the bundle-key as parent.
View Full Code Here

Examples of org.pentaho.reporting.libraries.resourceloader.ResourceManager.createKey()

      {
        final FontSource fr = (FontSource) fofam.getFontRecord(false, false);
        final ResourceManager resourceManager = new ResourceManager();
        resourceManager.registerDefaults();

        final ResourceKey fontSource = resourceManager.createKey(new File(fr.getFontSource()));
        final FontDataInputSource fs =
            new ResourceFontDataInputSource(resourceManager, fontSource);
        final TrueTypeFont ttf = new TrueTypeFont(fs);
        final NameTable nt = (NameTable) ttf.getTable(NameTable.TABLE_ID);
        //PostscriptInformationTable pst = ttf.getTable(PostscriptInformationTable.TABLE_ID);
View Full Code Here

Examples of org.pentaho.reporting.libraries.resourceloader.ResourceManager.createKey()

  private ResourceKey createImageKey()
      throws IOException, ResourceKeyCreationException
  {
    final ResourceManager resMgr = new ResourceManager();
    resMgr.registerDefaults();
    return resMgr.createKey(new URL("http://127.0.0.1:65535/image.jpg"));
  }
}
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.