Package jdbm.helper

Examples of jdbm.helper.OpenByteArrayInputStream


      if(bufferInUse){
        //current reusable buffer is in use, have to create new instances
        byte[] buffer = new byte[1024];
        OpenByteArrayOutputStream bao = new OpenByteArrayOutputStream(buffer);
        SerializerOutput out = new SerializerOutput(bao);
        OpenByteArrayInputStream bai = new OpenByteArrayInputStream(buffer);
        SerializerInput in = new SerializerInput(bai);
        return fetch2(recid,serializer,buffer,bao,out, bai,in);
      }
        try{
          bufferInUse = true;
View Full Code Here


        return (K[]) ret;
      }

     
      Serializer ser = _btree.keySerializer!=null? _btree.keySerializer : DefaultSerializer.INSTANCE;
      OpenByteArrayInputStream in1 = null;
      SerializerInput in2 = null;
      byte[] previous = null;
      for(int i = firstUse;i<_btree._pageSize;i++){
        byte[] b = LeadingValueCompressionProvider.readByteArray(ois, previous, 0);
        if(b == null ) continue;
        if(in1 == null){
          in1 = new OpenByteArrayInputStream(b);
          in2 = new SerializerInput(in1);
        }
        in1.reset(b, b.length);
        ret[i] = ser.deserialize(in2);
        previous = b;
      }
      return (K[]) ret;     
View Full Code Here

TOP

Related Classes of jdbm.helper.OpenByteArrayInputStream

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.