Package org.pentaho.platform.engine.services.actionsequence

Examples of org.pentaho.platform.engine.services.actionsequence.ActionParameterSource


      Iterator destinationsIterator = destinationsList.iterator();
      if ( destinationsList.size() > 1 ) {
        contentItem = new MultiContentItem();
      }
      while ( destinationsIterator.hasNext() ) {
        ActionParameterSource destination = (ActionParameterSource) destinationsIterator.next();

        String objectName = destination.getSourceName();
        String contentName = destination.getValue();
        contentName = TemplateUtil.applyTemplate( contentName, this );
        outputHandler.setSession( session );
        IContentItem tmpContentItem =
            outputHandler.getOutputContentItem( objectName, contentName, instanceId, mimeType );
        if ( contentItem instanceof MultiContentItem ) {
View Full Code Here


    Set inputNames = getInputNames();
    Iterator inputNamesIterator = inputNames.iterator();
    IActionParameter actionParameter;
    List variables;
    Iterator variablesIterator;
    ActionParameterSource variable;
    String sourceName;
    String sourceValue;
    Object variableValue = null;
    IParameterProvider parameterProvider;
    while ( inputNamesIterator.hasNext() ) {
      variableValue = null;

      String inputName = (String) inputNamesIterator.next();
      actionParameter = paramManager.getCurrentInput( inputName );
      if ( actionParameter == null ) {
        throw new UnresolvedParameterException( Messages.getInstance().getErrorString(
            "RuntimeContext.ERROR_0031_INPUT_NOT_FOUND", inputName ), //$NON-NLS-1$
            session.getName(), instanceId, getActionSequence().getSequenceName(), null );
      }

      variables = actionParameter.getVariables();
      variablesIterator = variables.iterator();
      while ( variablesIterator.hasNext() ) {
        variable = (ActionParameterSource) variablesIterator.next();
        sourceName = variable.getSourceName();
        sourceValue = variable.getValue();
        variableValue = null;
        // TODO support accessing the ancestors of the current instance,
        // e.g. runtme.parent
        if ( "runtime".equals( sourceName ) ) { //$NON-NLS-1$
          // first check the standard variables
View Full Code Here

      IActionParameter inputParam = (IActionParameter) allParams.get( outputName );
      if ( inputParam == null ) {
        returnMap.put( outputParam.getName(), null );
      } else {
        for ( Iterator varIt = outputParam.getVariables().iterator(); varIt.hasNext(); ) {
          ActionParameterSource src = (ActionParameterSource) varIt.next();
          returnMap.put( outputParam.getName(), new ReturnParameter( src.getSourceName(), src.getValue(), inputParam
              .getValue() ) );
        }
      }
    }
    return ( returnMap );
View Full Code Here

    IActionParameter actionParameter = getCurrentInput( fieldName );
    if ( actionParameter != null ) {
      List vars = actionParameter.getVariables();

      for ( int i = 0; i < vars.size(); i++ ) {
        ActionParameterSource source = (ActionParameterSource) ( vars.get( i ) );
        if ( source.getSourceName().equals( IParameterProvider.SCOPE_REQUEST ) ) {
          return source.getValue();
        }
      }
    }
    return fieldName;
  }
View Full Code Here

TOP

Related Classes of org.pentaho.platform.engine.services.actionsequence.ActionParameterSource

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.