Package uk.org.ogsadai.metadata

Examples of uk.org.ogsadai.metadata.MetadataWrapper


       
        int count=0;
       
//        Random rand = new Random();
       
        MetadataWrapper metadataWrapper = tuples.getMetadataWrapper();
       
        TupleMetadata metadata =
            (TupleMetadata)metadataWrapper.getMetadata();
       
        Tuple[] sampleTuples = new Tuple[sampleSize];
        boolean filled = false;

        try
View Full Code Here


            ColumnMetadata col = new SimpleColumnMetadata("groupID", TupleTypes._STRING, 0, 0, 0);
            columns.add(col);
            col = new SimpleColumnMetadata("groupID", TupleTypes._DOUBLE, 0, 0, 0);
            columns.add(col);
            TupleMetadata metadata = new SimpleTupleMetadata(columns);
            MetadataWrapper wrapper = new MetadataWrapper(metadata);
           
            mOutput.write(ControlBlock.LIST_BEGIN);
            mOutput.write(wrapper);

            Tuple tuple;
View Full Code Here

                columns.add(md);
               
              }
             // columns.addAll(Arrays.asList(((AssociationRulesProducer)tupleAssociator.getAssociator()).getAssociationRules().getRules().get(0).getMetricNamesForRule()));
              TupleMetadata rulesMetadata = new SimpleTupleMetadata(columns);
              mOutputRules.write(new MetadataWrapper(rulesMetadata));
              for(AssociationRule rule:((AssociationRulesProducer)tupleAssociator.getAssociator()).getAssociationRules().getRules()) {
                List<Object> elements = new ArrayList<Object>();
                elements.add(rule.toString());
                for(int i=1; i<columns.size();i++) {
                  elements.add(rule.getMetricValuesForRule()[i - 1]);
View Full Code Here

            ColumnMetadata col0 = new SimpleColumnMetadata("groupID", TupleTypes._STRING, 0, 0, 0);
            columns.add(col0);
            ColumnMetadata col1 = new SimpleColumnMetadata("groupID", TupleTypes._OBJECT, 0, 0, 0);
            columns.add(col1);
            TupleMetadata metadata = new SimpleTupleMetadata(columns);
            MetadataWrapper wrapper = new MetadataWrapper(metadata);
            mOutput.write(wrapper);
            while ((tuple = Next(tuples)) != null)
            {
                mOutput.write(tuple);
            }
View Full Code Here

        {
            List columns = new ArrayList();
            ColumnMetadata col = new SimpleColumnMetadata("groupID", TupleTypes._STRING, 0, 0, 0);
            columns.add(col);
            TupleMetadata metadata = new SimpleTupleMetadata(columns);
            MetadataWrapper wrapper = new MetadataWrapper(metadata);
           
            mOutput.write(ControlBlock.LIST_BEGIN);
            mOutput.write(wrapper);
            Open(tuples);
            while ((tuple = Next()) != null)
View Full Code Here

               ActivityTerminatedException,
               ActivityUserException
    {
        int linearIndex = ((Number)iterationInputs[0]).intValue();
        TupleListIterator tuples = (TupleListIterator)iterationInputs[1];
        MetadataWrapper wrapper = tuples.getMetadataWrapper();
        TupleMetadata metadata = (TupleMetadata)wrapper.getMetadata();
        validateLinearIndex(linearIndex, metadata);
        List<UpdateableTuple> data = getTuples(tuples);
        filter(linearIndex, data);
        writeOutput(wrapper, data);
    }
View Full Code Here

        TupleListIterator tuples = (TupleListIterator)iterationData[1];
       
        try
        {
            mOutput.write(ControlBlock.LIST_BEGIN);
            MetadataWrapper wrapper = tuples.getMetadataWrapper();
            Filter filter =
                new Filter(condition, (TupleMetadata)wrapper.getMetadata());
            mOutput.write(wrapper);
            Tuple tuple;
            while ((tuple = (Tuple)tuples.nextValue()) != null)
            {
                if (filter.isValid(tuple))
View Full Code Here

        ColumnMetadata col0 = new SimpleColumnMetadata("ID", TupleTypes._STRING, 0, 0, 0);
        columns.add(col0);
        ColumnMetadata col1 = new SimpleColumnMetadata("ITEMS", TupleTypes._STRING, 0, 0, 0);
        columns.add(col1);
        TupleMetadata metadata = new SimpleTupleMetadata(columns);
        MetadataWrapper wrapper = new MetadataWrapper(metadata);
        mOutput.write(wrapper);
        while ((tuple = Next(tuples)) != null)
        {
            mOutput.write(tuple);
        }
View Full Code Here

       
        try
        {
            mOutputTrue.write(ControlBlock.LIST_BEGIN);
            mOutputFalse.write(ControlBlock.LIST_BEGIN);
            MetadataWrapper wrapper = tuples.getMetadataWrapper();
            Filter filter =
                new Filter(condition, (TupleMetadata)wrapper.getMetadata());
            mOutputTrue.write(wrapper);
            mOutputFalse.write(wrapper);
            Tuple tuple;
            while ((tuple = (Tuple)tuples.nextValue()) != null)
            {
View Full Code Here

    {
        ListIterator iterator = (ListIterator)iterationData[1];
        Object block;
        long count = 1;
        long listSize = ((Number)iterationData[0]).longValue();
        MetadataWrapper metadata = null;
        while ((block = iterator.nextValue()) != null)
        {
            if (block instanceof MetadataWrapper)
            {
                metadata = (MetadataWrapper)block;
View Full Code Here

TOP

Related Classes of uk.org.ogsadai.metadata.MetadataWrapper

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.