@Override
  public void write(DataOutput out) throws IOException {

    WritableUtils.writeString(out, first_key);
    WritableUtils.writeString(out, second_key);
    WritableUtils.writeString(out, third_key);
  }
 /**
  * Write a Map<String, String>
  *
  * @param out DataOutput
  * @param map Map to write
  * @throws IOException I/O errors
  */
 public static void writeStrStrMap(DataOutput out, Map<String, String> map) throws IOException {
   out.writeInt(map.size());
   for (Map.Entry<String, String> entry : map.entrySet()) {
     WritableUtils.writeString(out, entry.getKey());
     WritableUtils.writeString(out, entry.getValue());
   }
 }
 @Override
 public void write(DataOutput out) throws IOException {
   PyString pyString;
   try {
     pyString = cPickle.dumps(getPyObject());
   } catch (PyException e) {
     LOG.fatal("Could not serialize wrapped Jython value: " + getPyObject().__str__());
     throw e;
   }
   WritableUtils.writeString(out, pyString.getString());
 }
Beispiel #4
0
 /*
  * Write a String array as a Nework Int N, followed by Int N Byte Array Strings.
  * Could be generalised using introspection.
  *
  */
 public static void writeStringArray(DataOutput out, String[] s) throws IOException {
   out.writeInt(s.length);
   for (int i = 0; i < s.length; i++) {
     writeString(out, s[i]);
   }
 }
 @Override
 public void write(DataOutput out) throws IOException {
   WritableUtils.writeString(out, realSplit.getClass().getName());
   ((Writable) realSplit).write(out);
 }
 @Override
 public void write(DataOutput out) throws IOException {
   out.writeUTF(containerState.toString());
   out.writeFloat(progress);
   WritableUtils.writeString(out, statusMessage);
 }
 @Override
 public void write(DataOutput dataOutput) throws IOException {
   WritableUtils.writeString(dataOutput, _id);
   WritableUtils.writeString(dataOutput, _name);
 }
 public void write(DataOutput out) throws IOException {
   out.writeInt(layoutVersion);
   out.writeInt(namespaceID);
   WritableUtils.writeString(out, clusterID);
   out.writeLong(cTime);
 }
 /**
  * Write class name
  *
  * @param out DataOutput
  * @param klass Class
  * @throws IOException I/O errors
  */
 public static void writeClassName(DataOutput out, Class<?> klass) throws IOException {
   WritableUtils.writeString(out, klass.getName());
 }
 /**
  * Write a Hive FieldSchema to output
  *
  * @param out DataOutput
  * @param fs FieldSchema
  * @throws IOException I/O errors
  */
 public static void writeFieldSchema(DataOutput out, FieldSchema fs) throws IOException {
   WritableUtils.writeString(out, fs.getName());
   WritableUtils.writeString(out, fs.getType());
 }
 /**
  * Write a List<String>
  *
  * @param out DataOutput
  * @param data list of strings
  * @throws IOException I/O errors
  */
 public static void writeStringList(DataOutput out, List<String> data) throws IOException {
   out.writeInt(data.size());
   for (String s : data) {
     WritableUtils.writeString(out, s);
   }
 }
 @Override
 public void write(DataOutput out) throws IOException {
   WritableUtils.writeVLong(out, key);
   WritableUtils.writeString(out, keyValue);
 }
Beispiel #13
0
 @Override
 public void write(DataOutput output) throws IOException {
   super.write(output);
   WritableUtils.writeString(output, formatString);
   WritableUtils.writeEnum(output, type);
 }
Beispiel #14
0
 @Override
 public void write(DataOutput out) throws IOException {
   // TODO Auto-generated method stub
   WritableUtils.writeString(out, empName);
   WritableUtils.writeVLong(out, empID);
 }
 @Override
 public void write(@Nonnull DataOutput out) throws IOException {
   super.write(out);
   WritableUtils.writeString(out, compressedPath.toUri().toString());
 }
 public void write(DataOutput out) throws IOException {
   WritableUtils.writeString(out, file.toString());
   WritableUtils.writeVLong(out, len);
 }