Examples of Tuple3


Examples of ch.epfl.labos.iu.orm.Tuple3

         switch(subreaders.length)
         {
            case 2:
               return (U)new Pair(data[0], data[1]);
            case 3:
               return (U)new Tuple3(data[0], data[1], data[2]);
            case 4:
               return (U)new Tuple4(data[0], data[1], data[2], data[3]);
            case 5:
               return (U)new Tuple5(data[0], data[1], data[2], data[3], data[4]);
            case 8:
View Full Code Here

Examples of eu.stratosphere.api.java.tuple.Tuple3

        .setDBUrl("jdbc:derby:memory:ebookshop")
        .setQuery("insert into books (id, title, author, price, qty) values (?,?,?,?,?)")
        .finish();
    jdbcOutputFormat.open(0, 1);

    Tuple3 tuple3 = new Tuple3();
    tuple3.setField(4, 0);
    tuple3.setField("hi", 1);
    tuple3.setField(4.4, 2);

    jdbcOutputFormat.writeRecord(tuple3);
    jdbcOutputFormat.close();
  }
View Full Code Here

Examples of org.apache.crunch.Tuple3

  }

  @Test
  @SuppressWarnings("rawtypes")
  public void testTriples() throws Exception {
    Tuple3 j = Tuple3.of("a", "b", "c");
    Text[] t = new Text[] { new Text("a"), new Text("b"), new Text("c"), };
    BytesWritable[] b = new BytesWritable[t.length];
    for (int i = 0; i < t.length; i++) {
      b[i] = new BytesWritable(WritableUtils.toByteArray(t[i]));
    }
View Full Code Here

Examples of org.apache.crunch.Tuple3

  }

  @Test
  @SuppressWarnings("rawtypes")
  public void testTriples() throws Exception {
    Tuple3 j = Tuple3.of("a", "b", "c");
    Text[] t = new Text[] { new Text("a"), new Text("b"), new Text("c"), };
    TupleWritable w = new TupleWritable(t);
    WritableType<?, ?> wt = Writables.triples(Writables.strings(), Writables.strings(), Writables.strings());
    testInputOutputFn(wt, j, w);
  }
View Full Code Here

Examples of org.apache.crunch.Tuple3

  @Test
  @SuppressWarnings("rawtypes")
  public void testTriples() throws Exception {
    AvroType at = Avros.triples(Avros.strings(), Avros.strings(), Avros.strings());
    Tuple3 j = Tuple3.of("a", "b", "c");
    GenericData.Record w = new GenericData.Record(at.getSchema());
    w.put(0, new Utf8("a"));
    w.put(1, new Utf8("b"));
    w.put(2, new Utf8("c"));
    testInputOutputFn(at, j, w);
View Full Code Here

Examples of org.apache.crunch.Tuple3

  @Test
  @SuppressWarnings("rawtypes")
  public void testTriples() throws Exception {
    AvroType at = Avros.triples(Avros.strings(), Avros.strings(), Avros.strings());
    Tuple3 j = Tuple3.of("a", "b", "c");
    GenericData.Record w = new GenericData.Record(at.getSchema());
    w.put(0, new Utf8("a"));
    w.put(1, new Utf8("b"));
    w.put(2, new Utf8("c"));
    testInputOutputFn(at, j, w);
View Full Code Here

Examples of org.apache.crunch.Tuple3

  }

  @Test
  @SuppressWarnings("rawtypes")
  public void testTriples() throws Exception {
    Tuple3 j = Tuple3.of("a", "b", "c");
    Text[] t = new Text[] { new Text("a"), new Text("b"), new Text("c"), };
    TupleWritable w = new TupleWritable(t);
    WritableType<?, ?> wt = Writables.triples(Writables.strings(), Writables.strings(), Writables.strings());
    testInputOutputFn(wt, j, w);
  }
View Full Code Here

Examples of org.apache.crunch.Tuple3

  @Test
  @SuppressWarnings("rawtypes")
  public void testTriples() throws Exception {
    AvroType at = Avros.triples(Avros.strings(), Avros.strings(), Avros.strings());
    Tuple3 j = Tuple3.of("a", "b", "c");
    GenericData.Record w = new GenericData.Record(at.getSchema());
    w.put(0, new Utf8("a"));
    w.put(1, new Utf8("b"));
    w.put(2, new Utf8("c"));
    testInputOutputFn(at, j, w);
View Full Code Here

Examples of org.apache.crunch.Tuple3

  }

  @Test
  @SuppressWarnings("rawtypes")
  public void testTriples() throws Exception {
    Tuple3 j = Tuple3.of("a", "b", "c");
    TupleWritable w = new TupleWritable(new Text[] { new Text("a"), new Text("b"), new Text("c"), });
    w.setWritten(0);
    w.setWritten(1);
    w.setWritten(2);
    WritableType<?, ?> wt = Writables.triples(Writables.strings(), Writables.strings(), Writables.strings());
View Full Code Here

Examples of org.apache.crunch.Tuple3

  @Test
  @SuppressWarnings("rawtypes")
  public void testTriples() throws Exception {
    AvroType at = Avros.triples(Avros.strings(), Avros.strings(), Avros.strings());
    Tuple3 j = Tuple3.of("a", "b", "c");
    GenericData.Record w = new GenericData.Record(at.getSchema());
    w.put(0, new Utf8("a"));
    w.put(1, new Utf8("b"));
    w.put(2, new Utf8("c"));
    testInputOutputFn(at, j, w);
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.