Examples of BinaryData


Examples of org.persvr.data.BinaryData

    case HEADER_BINARY:
    case HEADER_BIG_STRING:
      long fileId = readVarLong(input);
      BinaryData.InputStreamSource inputSource = readFile(fileId);
      if (header == HEADER_BINARY)
        return new BinaryData(inputSource);
      return IOUtils.toString(inputSource.getStream(), "UTF-8");
    case HEADER_UNDEFINED:
      return Undefined.instance;
    case HEADER_END:
      return END_OF_LIST;
View Full Code Here

Examples of org.persvr.data.BinaryData

        fileTarget.set("content", IOUtils.toString(new InputStreamReader((InputStream) data, charSet == null ? "UTF-8" : charSet)));
      else
        fileTarget.set("content", new String((byte[]) data, charSet == null ? "UTF-8" : charSet));
    } else {
      if (data instanceof InputStream)
        fileTarget.set("content", new BinaryData((InputStream) data));
      else
        fileTarget.set("content", new BinaryData((byte[]) data));
    }
    return fileTarget;
  }
View Full Code Here

Examples of org.persvr.data.BinaryData

          throw new RuntimeException(e);
        }
          }
          if (value.startsWith(BINARY_HEADER)) {
            value = value.substring(BINARY_HEADER.length());
        return new BinaryData(Base64.decodeBase64(value.getBytes()));
          }
          if (value.equals(UNDEFINED)) {
              return Undefined.instance;
          }
          if (BOOLEAN_FALSE.equals(value))
View Full Code Here

Examples of uk.org.ogsadai.data.BinaryData

        bytesToTuple.createInput(ByteArraysToTuple.DATA_INPUT);
        bytesToTuple.createOutput(ByteArraysToTuple.RESULT_OUTPUT);
        bytesToTuple.addInput(ByteArraysToTuple.DATA_INPUT, ListBegin.VALUE);
        bytesToTuple.addInput(
                ByteArraysToTuple.DATA_INPUT,
                new BinaryData(bytes.toByteArray()));
        bytesToTuple.addInput(ByteArraysToTuple.DATA_INPUT, ListEnd.VALUE);
        return bytesToTuple;
    }
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.