Package uk.org.ogsadai.activity.io

Examples of uk.org.ogsadai.activity.io.BlockReader


            throws InvalidActivityInputsException
    {
        List<ActivityInput> inputs = new ArrayList<ActivityInput>();
       
        // set up block reader for data input
        BlockReader data = getInput(INPUT_DATA);
        if (data == null)
        {
            throw new InvalidActivityInputsException(1, INPUT_DATA);
        }  
        ActivityInput dataInput = new TupleListActivityInput(INPUT_DATA);
        dataInput.setBlockReader(data);
        inputs.add(dataInput);

        // set up block reader for options input
        BlockReader options = getInput(INPUT_OPTIONS);

        TypedOptionalActivityInput optionsInput =
            new TypedOptionalActivityInput(INPUT_OPTIONS, Object.class, DEFAULT_OPTIONS);
        optionsInput.setBlockReader(options);
        inputs.add(optionsInput);
       
        // set up block reader for options input
        BlockReader algorithm = getInput(INPUT_ALGORITHM_CLASS);
       
        TypedOptionalActivityInput algorithmInput =
            new TypedOptionalActivityInput(INPUT_ALGORITHM_CLASS, Object.class, DEFAULT_ALGORITHM);
        algorithmInput.setBlockReader(algorithm);
        inputs.add(algorithmInput);
       
        // set up block reader for indexes of nominal values columns
        BlockReader indexes = getInput(INPUT_COLUMN_INDICES);
        TypedOptionalListActivityInput nomValIndexesInput = new TypedOptionalListActivityInput(INPUT_COLUMN_INDICES, Number.class);
        if(nomValIndexesInput != null && indexes != null)
          nomValIndexesInput.setBlockReader(indexes);
        inputs.add(nomValIndexesInput);
       
View Full Code Here


        throws ActivityUserException,
               ActivityProcessingException,
               ActivityTerminatedException
    {
        TypedActivityInput input = new TypedActivityInput(INPUT_LANGUAGE, String.class);
        BlockReader blockReader = mInputs.get(INPUT_LANGUAGE);
        if (blockReader == null)
        {
            throw new InvalidActivityInputsException(1, INPUT_LANGUAGE);
        }
        input.setBlockReader(blockReader);
View Full Code Here

    private String readScript()
        throws ActivityUserException,
               ActivityProcessingException,
               ActivityTerminatedException
    {
        BlockReader blockReader = mInputs.get(INPUT_SCRIPT);
        if (blockReader == null)
        {
            throw new InvalidActivityInputsException(1, INPUT_SCRIPT);
        }
        TypedActivityInput input = new TypedActivityInput(INPUT_SCRIPT, String.class);
View Full Code Here

TOP

Related Classes of uk.org.ogsadai.activity.io.BlockReader

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.