Package org.pentaho.platform.plugin.action.jfreereport.helper

Examples of org.pentaho.platform.plugin.action.jfreereport.helper.PentahoTableModel


      if ( !isDefinedInput( AbstractJFreeReportComponent.REPORTGENERATEDEFN_REPORTTEMP_PERFQRY )
          || "true".equals( getInputParameter( AbstractJFreeReportComponent.REPORTGENERATEDEFN_REPORTTEMP_PERFQRY ) ) ) { //$NON-NLS-1$
        IPentahoResultSet pentahoResultSet = getResultSet( getReportSpec() );
        factory = new PentahoTableDataFactory();
        pentahoResultSet.beforeFirst();
        factory.addTable( AbstractJFreeReportComponent.DATACOMPONENT_DEFAULTINPUT, new PentahoTableModel(
              pentahoResultSet ) );

      } else {
        factory = super.getDataFactory();
      }
View Full Code Here


        if ( ( dataComponent.validate() == IRuntimeContext.RUNTIME_CONTEXT_VALIDATE_OK ) && dataComponent.init()
            && ( dataComponent.execute() == IRuntimeContext.RUNTIME_STATUS_SUCCESS ) ) {
          final IPentahoResultSet resultset = dataComponent.getResultSet();
          factory =
              new PentahoTableDataFactory( AbstractJFreeReportComponent.DATACOMPONENT_DEFAULTINPUT,
                  new PentahoTableModel( resultset ) );
        } else {
          throw new IllegalArgumentException( Messages.getInstance().getErrorString(
              "JFreeReport.ERROR_0021_DATA_COMPONENT_FAILED" ) ); //$NON-NLS-1$
        }
      } catch ( ClassNotFoundException e ) {
View Full Code Here

          debug( "ResultSet is not scrollable. Copying into memory" ); //$NON-NLS-1$
          IPentahoResultSet memSet = resultset.memoryCopy();
          resultset.close();
          resultset = memSet;
        }
        factory.addTable( AbstractJFreeReportComponent.DATACOMPONENT_DEFAULTINPUT, new PentahoTableModel( resultset ) );
      } else if ( dataObject instanceof TableModel ) {
        factory.addTable( AbstractJFreeReportComponent.DATACOMPONENT_DEFAULTINPUT, (TableModel) dataObject );
      }

      IActionInput[] subreportQueries = jFreeReportAction.getSubreportQueryParams();
      for ( IActionInput element : subreportQueries ) {
        dataObject = element.getValue();
        if ( dataObject instanceof IPreparedComponent ) {
          factory.addPreparedComponent( element.getName(), (IPreparedComponent) dataObject );
        } else if ( dataObject instanceof IPentahoResultSet ) {
          final IPentahoResultSet resultset = (IPentahoResultSet) dataObject;
          resultset.beforeFirst();
          factory.addTable( element.getName(), new PentahoTableModel( resultset ) );
        } else if ( dataObject instanceof TableModel ) {
          factory.addTable( element.getName(), (TableModel) dataObject );
        }
      }
    }
View Full Code Here

          if ( ( dataComponent.validate() == IRuntimeContext.RUNTIME_CONTEXT_VALIDATE_OK ) && dataComponent.init()
              && ( dataComponent.execute() == IRuntimeContext.RUNTIME_STATUS_SUCCESS ) ) {
            final IPentahoResultSet resultset = dataComponent.getResultSet();
            factory =
                new PentahoTableDataFactory( AbstractJFreeReportComponent.DATACOMPONENT_DEFAULTINPUT,
                    new PentahoTableModel( resultset ) );
          } else {
            throw new IllegalArgumentException( Messages.getInstance().getErrorString(
                "JFreeReport.ERROR_0021_DATA_COMPONENT_FAILED" ) ); //$NON-NLS-1$
          }
        } catch ( ClassNotFoundException e ) {
View Full Code Here

          final IPreparedComponent comp = (IPreparedComponent) dataObject;
          factory.addPreparedComponent( name, comp );
        } else if ( dataObject instanceof IPentahoResultSet ) {
          final IPentahoResultSet resultset = (IPentahoResultSet) dataObject;
          resultset.beforeFirst();
          factory.addTable( name, new PentahoTableModel( resultset ) );
        } else if ( dataObject instanceof TableModel ) {
          final TableModel model = (TableModel) dataObject;
          factory.addTable( name, model );
        }
      }
View Full Code Here

TOP

Related Classes of org.pentaho.platform.plugin.action.jfreereport.helper.PentahoTableModel

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.