protected static long getFixedCacheDelay() { if ( fixedCacheDelay == null ) { fixedCacheDelay = new Long( LibLoaderBoot.getInstance().getExtendedConfig().getIntProperty ( "org.pentaho.reporting.libraries.resourceloader.config.url.FixedCacheDelay", 5000 ) ); } return fixedCacheDelay.longValue(); }
protected boolean isProgressDialogEnabled( final MasterReport report, final String configKey ) { return getConfig().getBoolProperty( configKey ); }
public String getRole() { return getConfig().getConfigProperty( getConfigurationPrefix() + "role" ); //$NON-NLS-1$ }
extendedConfig.getIntProperty( "org.pentaho.reporting.engine.classic.core.layout.defaults.FontSize", 12 ); setNumericFeatureValue( OutputProcessorFeature.DEFAULT_FONT_SIZE, defaultFontSize ); extendedConfig.getIntProperty( "org.pentaho.reporting.engine.classic.core.layout.defaults.FontSmoothThreshold", 8 ); setNumericFeatureValue( OutputProcessorFeature.FONT_SMOOTH_THRESHOLD, fontSmoothThreshold ); if ( extendedConfig.getBoolProperty( "org.pentaho.reporting.engine.classic.core.layout.fontrenderer.UseMaxCharBounds", true ) == false ) { addFeature( OutputProcessorFeature.LEGACY_LINEHEIGHT_CALC ); if ( extendedConfig.getBoolProperty( "org.pentaho.reporting.engine.classic.core.layout.AlwaysPrintFirstLineOfText", true ) ) { addFeature( OutputProcessorFeature.ALWAYS_PRINT_FIRST_LINE_OF_TEXT ); if ( extendedConfig.getBoolProperty( ClassicEngineCoreModule.COMPLEX_TEXT_CONFIG_OVERRIDE_KEY, false ) == true ) { addFeature( OutputProcessorFeature.COMPLEX_TEXT ); if ( extendedConfig.getBoolProperty( "org.pentaho.reporting.engine.classic.core.FixImageResolutionMapping", true ) ) { addFeature( OutputProcessorFeature.IMAGE_RESOLUTION_MAPPING ); if ( extendedConfig.getBoolProperty( "org.pentaho.reporting.engine.classic.core.UseNativeScaling", true ) ) { addFeature( OutputProcessorFeature.PREFER_NATIVE_SCALING ); if ( extendedConfig.getBoolProperty( "org.pentaho.reporting.engine.classic.core.DetectExtraContent", true ) ) { addFeature( OutputProcessorFeature.DETECT_EXTRA_CONTENT ); if ( extendedConfig.getBoolProperty( "org.pentaho.reporting.engine.classic.core.legacy.StrictCompatibility", false ) ) { addFeature( OutputProcessorFeature.STRICT_COMPATIBILITY );
public InMemoryDataCache() { this( ClassicEngineBoot.getInstance().getExtendedConfig().getIntProperty( "org.pentaho.reporting.engine.classic.core.cache.InMemoryCache.MaxEntries" ), ClassicEngineBoot.getInstance() .getExtendedConfig().getIntProperty( "org.pentaho.reporting.engine.classic.core.cache.InMemoryCache.CachableRowLimit" ) ); }
protected static boolean isFixBrokenWebServiceDateHeader() { if ( fixBrokenWebServiceDateHeader == null ) { fixBrokenWebServiceDateHeader = Boolean.valueOf( LibLoaderBoot.getInstance().getExtendedConfig().getBoolProperty ( "org.pentaho.reporting.libraries.resourceloader.config.url.FixBrokenWebServiceDateHeader", false ) ); } return fixBrokenWebServiceDateHeader.booleanValue(); }
/** * A sort key used to enforce a certain order within the actions. * * @return */ public int getMenuOrder() { return getConfig().getIntProperty( getConfigurationPrefix() + "menu-order", 0 ); //$NON-NLS-1$ }
public BaseFontSupport( final ITextFontRegistry registry, final String defaultEncoding ) { this.baseFonts = new HashMap(); this.registry = registry; this.defaultEncoding = defaultEncoding; final ExtendedConfiguration extendedConfig = LibFontBoot.getInstance().getExtendedConfig(); this.useGlobalCache = extendedConfig.getBoolProperty( "org.pentaho.reporting.libraries.fonts.itext.UseGlobalFontCache" ); }
public EhCacheDataCache() { this( ClassicEngineBoot.getInstance().getExtendedConfig().getIntProperty( "org.pentaho.reporting.engine.classic.core.cache.EhCacheDataCache.CachableRowLimit" ) ); }
/** * Returns true if the action is separated, and false otherwise. A separated action starts a new action group and will * be sepearated from previous actions on the menu and toolbar. * * @return true, if the action should be separated from previous actions, false otherwise. */ public boolean isSeparated() { return getConfig().getBoolProperty( getConfigurationPrefix() + "separated" ); //$NON-NLS-1$ }
public int getRolePreference() { return getConfig().getIntProperty( getConfigurationPrefix() + "role-preference", 0 ); //$NON-NLS-1$ } }
/** * Returns true if the action should be added to the toolbar, and false otherwise. * * @return true, if the plugin should be added to the toolbar, false otherwise. */ public boolean isAddToToolbar() { return getConfig().getBoolProperty( getConfigurationPrefix() + "add-to-toolbar" ); //$NON-NLS-1$ }
public int getToolbarOrder() { return getConfig().getIntProperty( getConfigurationPrefix() + "toolbar-order", 0 ); //$NON-NLS-1$ }
/** * Returns true if the action should be added to the menu, and false otherwise. * * @return A boolean. */ public boolean isAddToMenu() { final String name = getConfigurationPrefix() + "add-to-menu"; //$NON-NLS-1$ return getConfig().getBoolProperty( name ); }
extendedConfig.getIntProperty( "org.pentaho.reporting.libraries.css.defaults.FontSize", 12 ); extendedConfig.getIntProperty( "org.pentaho.reporting.libraries.css.defaults.FontSmoothThreshold", 8 ); setNumericFeatureValue( OutputProcessorFeature.FONT_SMOOTH_THRESHOLD, fontSmoothThreshold ); extendedConfig.getIntProperty( "org.pentaho.reporting.libraries.css.defaults.DeviceResolution", 72 ); if ( deviceResolution > 0 ) { setNumericFeatureValue( OutputProcessorFeature.DEVICE_RESOLUTION, deviceResolution );
/** * Initializes the module. Use this method to perform all initial setup operations. This method is called only once in * a modules lifetime. If the initializing cannot be completed, throw a ModuleInitializeException to indicate the * error,. The module will not be available to the system. * * @param subSystem * the subSystem. * @throws ModuleInitializeException * if an error ocurred while initializing the module. */ public void initialize( final SubSystem subSystem ) throws ModuleInitializeException { if ( subSystem.getExtendedConfig().getBoolProperty( "org.pentaho.reporting.engine.classic.core.modules.gui.base.SwingDialogTranslation" ) ) { //$NON-NLS-1$ final ResourceBundle resources = ResourceBundle.getBundle( SwingCommonModule.BUNDLE_NAME ); final UIDefaults defaults = UIManager.getDefaults(); final Enumeration en = resources.getKeys(); while ( en.hasMoreElements() ) { try { final String keyName = (String) en.nextElement(); defaults.put( keyName, resources.getObject( keyName ) ); } catch ( Exception e ) { // Ignored; if it happens, we would not care that much .. } } } } }
public void initialize( final Configuration configuration ) { super.initialize( configuration ); addFeature( OutputProcessorFeature.FAST_FONTRENDERING ); addFeature( OutputProcessorFeature.BACKGROUND_IMAGE ); addFeature( OutputProcessorFeature.PAGE_SECTIONS ); addFeature( OutputProcessorFeature.SPACING_SUPPORTED ); if ( "true" .equals( configuration .getConfigProperty( "org.pentaho.reporting.engine.classic.core.modules.output.pageable.graphics.WatermarkPrinted" ) ) ) { addFeature( OutputProcessorFeature.WATERMARK_SECTION ); } final ExtendedConfiguration extendedConfig = new ExtendedConfigurationWrapper( configuration ); final double deviceResolution = extendedConfig.getIntProperty( "org.pentaho.reporting.engine.classic.core.modules.output.pageable.graphics.DeviceResolution", 0 ); if ( deviceResolution > 0 ) { setNumericFeatureValue( OutputProcessorFeature.DEVICE_RESOLUTION, deviceResolution ); } if ( "true" .equals( configuration .getConfigProperty( "org.pentaho.reporting.engine.classic.core.modules.output.pageable.graphics.AssumeOverflowX" ) ) ) { addFeature( OutputProcessorFeature.ASSUME_OVERFLOW_X ); } if ( "true" .equals( configuration .getConfigProperty( "org.pentaho.reporting.engine.classic.core.modules.output.pageable.graphics.AssumeOverflowY" ) ) ) { addFeature( OutputProcessorFeature.ASSUME_OVERFLOW_Y ); } }
int byteindex = 0; boolean useMasterSelect = ClassicEngineBoot.getInstance().getExtendedConfig().getBoolProperty( "org.pentaho.reporting.engine.classic.core.modules.output.pageable.plaintext.UseEpsonMasterSelect" ); if ( charactersPerInch == PrinterDriverCommands.CPI_10 ) {
protected void runAllGoldReports() throws Exception { if ( "true".equals( ClassicEngineBoot.getInstance().getGlobalConfig().getConfigProperty( ClassicEngineCoreModule.COMPLEX_TEXT_CONFIG_OVERRIDE_KEY ) ) ) { Assert.fail( "Dont run GoldenSample tests with the new layout system. These tests are not platform independent." ); } final int numThreads = Math.max( 1, ClassicEngineBoot.getInstance().getExtendedConfig().getIntProperty( "org.pentaho.reporting.engine.classic.core.testsupport.gold.MaxWorkerThreads", Math.max( 1, Runtime.getRuntime().availableProcessors() - 1 ) ) ); StopWatch w = new StopWatch(); w.start(); try { if ( numThreads == 1 ) { runAllGoldReportsSerial(); } else { runAllGoldReportsInParallel( numThreads ); } } finally { System.out.println( w.toString() ); } }
public StyleResolvingEvaluator() { statisticsHit = new DoubleKeyedCounter<String, Long>(); statisticsMiss = new DoubleKeyedCounter<String, Long>(); ExtendedConfiguration config = ClassicEngineBoot.getInstance().getExtendedConfig(); collectDetailedStatistics = config.getBoolProperty( DETAILED_STATISTICS_CONFIG ); }