Package org.pentaho.platform.engine.services.runtime

Examples of org.pentaho.platform.engine.services.runtime.SimpleRuntimeElement


    srr.setSession( session );
    IRuntimeElement ele1 = srr.loadElementById( "instanceid", null ); //$NON-NLS-1$
    IRuntimeElement ele2 = srr.newRuntimeElement( "parent", "parentType", true ); //$NON-NLS-1$ //$NON-NLS-2$
    IRuntimeElement ele3 = srr.newRuntimeElement( "parentid", "parentType", "solutionId", true ); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$

    SimpleRuntimeElement sre = (SimpleRuntimeElement) srr.loadElementById( "instanceid", null ); //$NON-NLS-1$
    List list = sre.getMessages();
    if ( list != null ) {
      for ( int i = 0; i < list.size(); i++ ) {
        System.out.println( "Message " + ( i + 1 ) + list.get( i ) ); //$NON-NLS-1$
      }

      sre.setParentId( "parentid1" ); //$NON-NLS-1$
      sre.setParentType( "parentidType1" ); //$NON-NLS-1$
      sre.setSolutionId( "solutionId1" ); //$NON-NLS-1$
      sre.setReadOnly( true );
      boolean isReadOnly = sre.getReadOnly();
      String parentId = sre.getParentId();
      String parentIdType = sre.getParentType();
      String solutionId = sre.getSolutionId();
      assertEquals( isReadOnly, true );
      assertEquals( parentId, "parentid1" ); //$NON-NLS-1$
      assertEquals( parentIdType, "parentidType1" ); //$NON-NLS-1$
      assertEquals( solutionId, "solutionId1" ); //$NON-NLS-1$
    }
    int revision = sre.getRevision();
    System.out.println( "Revision Value is" + revision ); //$NON-NLS-1$
    sre.setStringProperty( "parentId", "value" ); //$NON-NLS-1$ //$NON-NLS-2$
    BigDecimal tstBD = new BigDecimal( "2.4" ); //$NON-NLS-1$
    ele2.setBigDecimalProperty( "junkBD", tstBD ); //$NON-NLS-1$
    BigDecimal bd = ele2.getBigDecimalProperty( "junkBD" ); //$NON-NLS-1$
    assertEquals( bd, tstBD );
    Date tstDT = new Date();
View Full Code Here


    }

    IRuntimeElement runtimeData;
    if ( runtimeRepository == null ) {
      String id = UUIDUtil.getUUIDAsString();
      runtimeData = new SimpleRuntimeElement( id, session.getId(), IParameterProvider.SCOPE_SESSION );
    } else {
      runtimeRepository.setLoggingLevel( loggingLevel );
      if ( newInstance ) {
        // we need to create runtime data for this execution
        try {
View Full Code Here

  public IRuntimeElement loadElementById( final String instanceId, final Collection allowableReadAttributeNames )
    throws RepositoryException {
    if ( SimpleRuntimeRepository.debug ) {
      debug( Messages.getInstance().getString( "RTREPO.DEBUG_CREATE_INSTANCE", instanceId ) ); //$NON-NLS-1$
    }
    SimpleRuntimeElement re = new SimpleRuntimeElement( instanceId );
    return re;
  }
View Full Code Here

    }
    String instanceId = UUIDUtil.getUUIDAsString();
    if ( SimpleRuntimeRepository.debug ) {
      debug( Messages.getInstance().getString( "RTREPO.DEBUG_CREATE_INSTANCE", instanceId ) ); //$NON-NLS-1$
    }
    SimpleRuntimeElement re = new SimpleRuntimeElement( instanceId, parId, parType );
    return re;
  }
View Full Code Here

    }
    String instanceId = UUIDUtil.getUUIDAsString();
    if ( SimpleRuntimeRepository.debug ) {
      debug( Messages.getInstance().getString( "RTREPO.DEBUG_CREATE_INSTANCE", instanceId ) ); //$NON-NLS-1$
    }
    SimpleRuntimeElement re = new SimpleRuntimeElement( instanceId, parId, parType, solnId );
    return re;
  }
View Full Code Here

TOP

Related Classes of org.pentaho.platform.engine.services.runtime.SimpleRuntimeElement

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.