/** * Creates a new PDF export task. */ public ReportExportTask( final MasterReport report, final SwingGuiContext swingGuiContext, String targetPath, Boolean createParentFolder ) { if ( report == null ) { throw new NullPointerException( "ReportExportTask(..): Report parameter cannot be null" ); } this.report = report; this.statusListener = swingGuiContext.getStatusListener(); // Check if the current Locale is supported: // If not, use the default (US) locale. Locale locale = swingGuiContext.getLocale(); try { ResourceBundle.getBundle( BASE_RESOURCE_CLASS, swingGuiContext.getLocale() ); } catch ( MissingResourceException e ) { locale = Locale.US; } this.messages = new Messages( locale, BASE_RESOURCE_CLASS, ObjectUtilities.getClassLoader( ReportExportTask.class ) ); this.targetPath = targetPath; this.createParentFolder = createParentFolder; }
/** * Creates a new instance. */ public Messages( final Locale locale ) { super( locale, "org.pentaho.reporting.libraries.formula.messages", // NON-NLS ObjectUtilities.getClassLoader( Messages.class ) ); } }
/** * Creates a new instance based on locale. */ private Messages( Locale locale ) { super( locale, "org.pentaho.reporting.engine.classic.core.parameters.messages", ObjectUtilities .getClassLoader( Messages.class ) ); } }
/** * Creates a new Messages-collection. The locale and baseName will be used to create the resource-bundle that backs up * this implementation. */ private EditorMessages() { super( Locale.getDefault(), "org.pentaho.reporting.designer.core.util.messages", // NON-NLS ObjectUtilities.getClassLoader( EditorMessages.class ) ); } }
public static boolean isJpegEncodingAvailable() { try { final ClassLoader loader = ObjectUtilities.getClassLoader( JpegImageEncoder.class ); final Class aClass = Class.forName( ENCODER_CLASS, false, loader ); return aClass != null; } catch ( Throwable t ) { // ignore the throwable .. return false; } } }
/** * Creates a new instance. */ private Messages() { super( Locale.getDefault(), "org.pentaho.reporting.engine.classic.core.modules.misc.connections.messages", ObjectUtilities.getClassLoader( Messages.class ) ); } }
/** * DefaultConstructor. */ public HtmlZipExportPlugin() { resources = new ResourceBundleSupport( Locale.getDefault(), HtmlExportGUIModule.BASE_RESOURCE_CLASS, ObjectUtilities .getClassLoader( HtmlExportGUIModule.class ) ); }
public Class getParameterType( final int position ) { try { final String string = getBundle( Locale.getDefault() ).getString( "parameter." + position + ".type" ); return Class.forName( string, false, ObjectUtilities.getClassLoader( AbstractSequenceDescription.class ) ); } catch ( Exception e ) { throw new IllegalStateException( e ); } }
/** * DefaultConstructor. */ public ExcelExportPlugin() { resources = new ResourceBundleSupport( Locale.getDefault(), ExcelExportPlugin.BASE_RESOURCE_CLASS, ObjectUtilities .getClassLoader( ExcelExportPlugin.class ) ); }
/** * DefaultConstructor. */ public HtmlStreamExportPlugin() { resources = new ResourceBundleSupport( Locale.getDefault(), HtmlExportGUIModule.BASE_RESOURCE_CLASS, ObjectUtilities .getClassLoader( HtmlExportGUIModule.class ) ); }
/** * DefaultConstructor. */ public CSVDataExportPlugin() { resources = new ResourceBundleSupport( Locale.getDefault(), CSVDataExportPlugin.BASE_RESOURCE_CLASS, ObjectUtilities .getClassLoader( CSVDataExportPlugin.class ) ); }
/** * DefaultConstructor. */ public HtmlDirExportPlugin() { resources = new ResourceBundleSupport( Locale.getDefault(), HtmlExportGUIModule.BASE_RESOURCE_CLASS, ObjectUtilities .getClassLoader( HtmlExportGUIModule.class ) ); }
/** * DefaultConstructor. */ public XSSFExcelExportPlugin() { resources = new ResourceBundleSupport( Locale.getDefault(), XSSFExcelExportPlugin.BASE_RESOURCE_CLASS, ObjectUtilities .getClassLoader( XSSFExcelExportPlugin.class ) ); }
public Messages getBundle( final Locale locale ) { if ( locale == null ) { throw new NullPointerException(); } if ( lastMessages == null || ObjectUtilities.equal( locale, lastLocale ) == false ) { lastMessages = new Messages( locale, bundleLocation, ObjectUtilities.getClassLoader( AbstractMetaData.class ) ); lastLocale = locale; } return lastMessages; }
/** * Default Constructor. */ public PageSetupPlugin() { resources = new ResourceBundleSupport( Locale.getDefault(), PrintingPlugin.BASE_RESOURCE_CLASS, ObjectUtilities .getClassLoader( PrintingPlugin.class ) ); reportJobListener = new ReportJobListener(); }
public PrintExportTask( final MasterReport job, final ReportProgressDialog progressListener, final SwingGuiContext swingGuiContext ) { this.job = job; this.progressListener = progressListener; if ( swingGuiContext != null ) { this.statusListener = swingGuiContext.getStatusListener(); this.messages = new Messages( swingGuiContext.getLocale(), PrintingPlugin.BASE_RESOURCE_CLASS, ObjectUtilities .getClassLoader( PrintingPlugin.class ) ); } }
public boolean initialize( final SwingGuiContext context ) { super.initialize( context ); resources = new ResourceBundleSupport( context.getLocale(), SwingPreviewModule.BUNDLE_NAME, ObjectUtilities .getClassLoader( SwingPreviewModule.class ) ); return true; }
public boolean initialize( final SwingGuiContext context ) { super.initialize( context ); resources = new ResourceBundleSupport( context.getLocale(), SwingPreviewModule.BUNDLE_NAME, ObjectUtilities .getClassLoader( SwingPreviewModule.class ) ); context.getEventSource().addPropertyChangeListener( updateListener ); setEnabled( context.getEventSource().isPaginated() ); return true; }
public boolean initialize( final SwingGuiContext context ) { super.initialize( context ); resources = new ResourceBundleSupport( context.getLocale(), SwingPreviewModule.BUNDLE_NAME, ObjectUtilities .getClassLoader( SwingPreviewModule.class ) ); context.getEventSource().addPropertyChangeListener( updateListener ); setEnabled( context.getEventSource().isPaginated() ); return true; }
public boolean initialize( final SwingGuiContext context ) { super.initialize( context ); resources = new ResourceBundleSupport( context.getLocale(), SwingPreviewModule.BUNDLE_NAME, ObjectUtilities .getClassLoader( SwingPreviewModule.class ) ); context.getEventSource().addPropertyChangeListener( updateListener ); setEnabled( context.getEventSource().isPaginated() ); return true; }