Examples of toStream()


Examples of com.orientechnologies.orient.core.serialization.OSerializableStream.toStream()

                throw new OSerializationException("Can't serialize the object since it's not implements the OSerializableStream interface");

      OSerializableStream stream = (OSerializableStream) iValue;
      iOutput.append(iValue.getClass().getName());
      iOutput.append(OStreamSerializerHelper.SEPARATOR);
      iOutput.append(OBinaryProtocol.bytes2string(stream.toStream()));
    }
    return iOutput;
  }

  public String getName() {
View Full Code Here

Examples of com.orientechnologies.orient.core.serialization.serializer.record.ORecordSerializer.toStream()

    assertEquals(doc.fieldType("integer"), OType.INTEGER);
    assertEquals(doc.fieldType("link"), OType.LINK);
    assertEquals(doc.fieldType("string"), OType.STRING);
    assertEquals(doc.fieldType("binary"), OType.BINARY);
    ORecordSerializer ser = ODatabaseDocumentTx.getDefaultSerializer();
    byte[] bytes = ser.toStream(doc, false);
    doc = new ODocument();
    ser.fromStream(bytes, doc, null);
    assertEquals(doc.fieldType("integer"), OType.INTEGER);
    assertEquals(doc.fieldType("string"), OType.STRING);
    assertEquals(doc.fieldType("binary"), OType.BINARY);
View Full Code Here

Examples of com.orientechnologies.orient.core.serialization.serializer.stream.OStreamSerializer.toStream()

    final OMemoryStream outStream = new OMemoryStream(outBuffer);
    try {
      outStream.jump(offset);

      for (int i = 0; i < oldSize; ++i)
        outStream.set(valueSerializer.toStream(oldValues[i]));

      return outStream.toByteArray();

    } finally {
      outStream.close();
View Full Code Here

Examples of com.orientechnologies.orient.core.serialization.serializer.string.OStringBuilderSerializable.toStream()

          iRecord.field(iName, coll);
      } else
        // LAZY SET
        coll = (OStringBuilderSerializable) iValue;

      coll.toStream(iOutput);

      PROFILER.stopChrono(PROFILER.getProcessMetric("serializer.record.string.linkSet2string"), "Serialize linkset to string",
          timer);
      break;
    }
View Full Code Here

Examples of com.sun.mail.util.SharedByteArrayOutputStream.toStream()

      } catch (IOException cex) { }
      throw iioex;
  }
  if (b < 0)
      throw new EOFException("EOF on socket");
  return buf.toStream();
    }

    /**
     * Temporarily turn off protocol tracing, e.g., to prevent
     * tracing the authentication sequence, including the password.
View Full Code Here

Examples of edu.byu.ece.rapidSmith.bitstreamTools.bitstream.Bitstream.toStream()

      System.out.println(bitstream.toXMLString());
      System.exit(1);     
    }
    // Print full bitstream
    PrintWriter pw = new PrintWriter(System.out);
    bitstream.toStream(true, true, pw);
    pw.flush();
    pw.close();       
    }

 
View Full Code Here

Examples of org.fcrepo.server.storage.types.TupleArrayTripleIterator.toStream()

            TupleArrayTripleIterator iter =
                    new TupleArrayTripleIterator(new ArrayList<RelationshipTuple>(Arrays
                            .asList(tuples)));
            ByteArrayOutputStream os = new ByteArrayOutputStream();
            try {
                iter.toStream(os, RDFFormat.NOTATION_3, false);
            } catch (TrippiException e) {
                e.printStackTrace();
            }
            term = new String(os.toByteArray());
        } else if (javaType != null && javaType.equals("java.lang.String")) {
View Full Code Here

Examples of org.fcrepo.server.utilities.FilteredTripleIterator.toStream()

            map.put(RDF.prefix, RDF.uri);

            try {
                TripleIterator triples =
                        new FilteredTripleIterator(map, toAdd, true);
                triples.toStream(out, RDFFormat.RDF_XML, false);
            } catch (TrippiException e) {
                throw new GeneralException(e.getMessage(), e);
            }

            dsxml = new XMLDatastreamProcessor(dsId);
View Full Code Here

Examples of org.trippi.TripleIterator.toStream()

            map.put(RDF.prefix, RDF.uri);

            try {
                TripleIterator triples =
                        new FilteredTripleIterator(map, toAdd, true);
                triples.toStream(out, RDFFormat.RDF_XML, false);
            } catch (TrippiException e) {
                throw new GeneralException(e.getMessage(), e);
            }

            dsxml = new XMLDatastreamProcessor(dsId);
View Full Code Here

Examples of storm.trident.fluent.GroupedStream.toStream()

        List<Fields> fullGroupFields = new ArrayList<Fields>();
        for(int i=0; i<groupedStreams.size(); i++) {
            GroupedStream gs = groupedStreams.get(i);
            Fields groupFields = gs.getGroupFields();
            fullGroupFields.add(groupFields);
            streams.add(gs.toStream().partitionBy(groupFields));
            fullInputFields.add(TridentUtils.fieldsUnion(groupFields, inputFields.get(i)));
           
        }
        return multiReduce(fullInputFields, streams, new GroupedMultiReducerExecutor(function, fullGroupFields, inputFields), outputFields);
    }
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.