Package org.apache.avro.io

Examples of org.apache.avro.io.EncoderFactory


    }

    @Override
    public void open(OutputStream out) throws IOException {
      this.out = out;
      this.encoder = new EncoderFactory().configureBlockSize(512).binaryEncoder(out, null);
    }
View Full Code Here


    ReflectDatumWriter<Object> writer = new ReflectDatumWriter<Object>(schema);
    ByteArrayOutputStream out = new ByteArrayOutputStream();
    if (!blocking) {
      writer.write(datum, EncoderFactory.get().directBinaryEncoder(out, null));
    } else {
      writer.write(datum, new EncoderFactory().configureBlockSize(64)
          .blockingBinaryEncoder(out, null));
    }
    writer.write(datum, EncoderFactory.get().directBinaryEncoder(out, null));
    byte[] data = out.toByteArray();
View Full Code Here

      this.writer = writer;
    }

    public void open(OutputStream out) {
      this.out = out;
      this.encoder = new EncoderFactory().configureBlockSize(512).binaryEncoder(out, null);
    }
View Full Code Here

      this.writer = writer;
    }

    public void open(OutputStream out) {
      this.out = out;
      this.encoder = new EncoderFactory().configureBlockSize(512)
          .binaryEncoder(out, null);
    }
View Full Code Here

    }
   
    @Override
    public void open(OutputStream out) throws IOException {
      this.out = out;
      this.encoder = new EncoderFactory().configureBlockSize(512)
          .binaryEncoder(out, null);
    }
View Full Code Here

TOP

Related Classes of org.apache.avro.io.EncoderFactory

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.