Examples of SimpleTupleMetadata


Examples of uk.org.ogsadai.tuple.SimpleTupleMetadata

        final int TUPLE_COUNT = 20000;
        List<ColumnMetadata> cdlist = new ArrayList<ColumnMetadata>();
        cdlist.add(new SimpleColumnMetadata("A", TupleTypes._INT, 0, 0, 11));
        cdlist.add(new SimpleColumnMetadata("B", TupleTypes._INT, 0, 0, 11));
        cdlist.add(new SimpleColumnMetadata("C", TupleTypes._INT, 0, 0, 11));
        TupleMetadata metadata = new SimpleTupleMetadata(cdlist);
        TestBlockReader input = new TestBlockReader(TUPLE_COUNT);
        input.setTupleFactory(new SimpleTupleFactory());
        input.setTupleMetadata(metadata);
        SortActivity activity = new SortActivity();
        activity.addInput("data", input);
View Full Code Here

Examples of uk.org.ogsadai.tuple.SimpleTupleMetadata

        for (int i=0; i<columnCount; i++)
        {
            ColumnMetadata col = new SimpleColumnMetadata("", TupleTypes._DOUBLE, 0,0,0);
            columns.add(col);
        }
        TupleMetadata metadata = new SimpleTupleMetadata(columns);
        return new MetadataWrapper(metadata);
      
    }
View Full Code Here

Examples of uk.org.ogsadai.tuple.SimpleTupleMetadata

          columns.add(column);
          column = new SimpleColumnMetadata("humidity", TupleTypes._INT, 0, 0, 0);
          columns.add(column);
          column = new SimpleColumnMetadata("play", TupleTypes._STRING, 0, 0, 0);
          columns.add(column);
          TupleMetadata metadata = new SimpleTupleMetadata(columns);
       
          List<Object> result = new ArrayList<Object>();
       
          result.add(ControlBlock.LIST_BEGIN);
          result.add(new MetadataWrapper(metadata));
View Full Code Here

Examples of uk.org.ogsadai.tuple.SimpleTupleMetadata

    }
   
    public void testSimple() throws Exception
    {
        ColumnMetadata col = new SimpleColumnMetadata("class", TupleTypes._STRING, 0,0,0);
        TupleMetadata metadata = new SimpleTupleMetadata(Collections.singletonList(col));
        MockInputPipe inputExpected = new MockInputPipe(new Object[] {
            ControlBlock.LIST_BEGIN,
            new MetadataWrapper(metadata),
            new SimpleTuple(Arrays.asList("yes")),
            new SimpleTuple(Arrays.asList("no")),
View Full Code Here

Examples of uk.org.ogsadai.tuple.SimpleTupleMetadata

    }

    public void testUnmatched() throws Exception
    {
        ColumnMetadata col = new SimpleColumnMetadata("class", TupleTypes._STRING, 0,0,0);
        TupleMetadata metadata = new SimpleTupleMetadata(Collections.singletonList(col));
        MockInputPipe inputExpected = new MockInputPipe(new Object[] {
            ControlBlock.LIST_BEGIN,
            new MetadataWrapper(metadata),
            new SimpleTuple(Arrays.asList("yes")),
            new SimpleTuple(Arrays.asList("no")),
View Full Code Here

Examples of uk.org.ogsadai.tuple.SimpleTupleMetadata

    public void testSimple() throws Exception
    {
        List<ColumnMetadata> cdlist = new ArrayList<ColumnMetadata>();
        cdlist.add(new SimpleColumnMetadata("ID", TupleTypes._INT, 0, 0, 11));
        cdlist.add(new SimpleColumnMetadata("ITEMS", TupleTypes._OBJECT, 0, 0, 11));
        SimpleTupleMetadata metadata = new SimpleTupleMetadata(cdlist);
       
        Vector v1 = new Vector();
        v1.add("30");
        v1.add("90");
        Vector v2 = new Vector();
View Full Code Here

Examples of uk.org.ogsadai.tuple.SimpleTupleMetadata

    {
        GroupByActivity activity = new GroupByActivity();
        List<ColumnMetadata> cdlist = new ArrayList<ColumnMetadata>();
        cdlist.add(new SimpleColumnMetadata("A", TupleTypes._INT, 0, 0, 11));
        cdlist.add(new SimpleColumnMetadata("B", TupleTypes._INT, 0, 0, 11));
        TupleMetadata metadata = new SimpleTupleMetadata(cdlist);
        TestBlockReader dataInput = new TestBlockReader(10000);
        dataInput.setTupleFactory(new GroupTupleFactory());
        dataInput.setTupleMetadata(metadata);
        activity.addInput(GroupByActivity.INPUT_DATA, dataInput);
        MockInputPipe columnsInput = new MockInputPipe(new Object[] {
View Full Code Here

Examples of uk.org.ogsadai.tuple.SimpleTupleMetadata

        columns.add(col);
        col = new SimpleColumnMetadata("D", TupleTypes._DOUBLE, 0,0,0);
        columns.add(col);
        col = new SimpleColumnMetadata("E", TupleTypes._DOUBLE, 0,0,0);
        columns.add(col);
        TupleMetadata metadata = new SimpleTupleMetadata(columns);
        return metadata;
    }
View Full Code Here

Examples of uk.org.ogsadai.tuple.SimpleTupleMetadata

                listColumnMetadata.add(new SimpleColumnMetadata(var,
                        TupleTypes._STRING, 100, ColumnMetadata.COLUMN_NULLABLE,
                        10000));
            }

            output.write(new MetadataWrapper(new SimpleTupleMetadata(
                    listColumnMetadata)));

            for (; rs.hasNext();)
            {
                QuerySolution qs = rs.next();
View Full Code Here

Examples of uk.org.ogsadai.tuple.SimpleTupleMetadata

                    10,
                    ColumnMetadata.COLUMN_NULLABLE,
                    10));
        }
       
        return new SimpleTupleMetadata(elements);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.