pipeFrom() abstract private method

abstract private pipeFrom ( Stream src, long len ) : long
src Stream
len long
return long
Example #1
0
            public override Long readBuf(Buf other, long n)
            {
                if (p.m_pos >= p.m_size)
                {
                    return(null);
                }
                int len = Math.Min(p.m_size - p.m_pos, (int)n);

                other.pipeFrom(p.m_buf, p.m_pos, len);
                p.m_pos += len;
                return(Long.valueOf(len));
            }
Example #2
0
 public override Long readBuf(Buf buf, long n)
 {
     try
     {
         long read = buf.pipeFrom(inStream, n);
         if (read <= 0)
         {
             return(null);
         }
         return(Long.valueOf(read));
     }
     catch (IOException e)
     {
         throw IOErr.make(e).val;
     }
 }
Example #3
0
 public override Long readBuf(Buf other, long n)
 {
     try
     {
         long read = other.pipeFrom(p.m_stream, n);
         if (read < 0)
         {
             return(null);
         }
         return(Long.valueOf(read));
     }
     catch (IOException e)
     {
         throw IOErr.make(e).val;
     }
 }
Example #4
0
 public override Long readBuf(Buf buf, long n)
 {
     try
       {
     long read = buf.pipeFrom(inStream, n);
     if (read <= 0) return null;
     return Long.valueOf(read);
       }
       catch (IOException e)
       {
     throw IOErr.make(e).val;
       }
 }
Example #5
0
 public override Long readBuf(Buf other, long n)
 {
     if (p.m_pos >= p.m_size) return null;
     int len = Math.Min(p.m_size-p.m_pos, (int)n);
     other.pipeFrom(p.m_buf, p.m_pos, len);
     p.m_pos += len;
     return Long.valueOf(len);
 }
Example #6
0
 public override Long readBuf(Buf other, long n)
 {
     try
     {
       long read = other.pipeFrom(p.m_stream, n);
       if (read < 0) return null;
       return Long.valueOf(read);
     }
     catch (IOException e)
     {
       throw IOErr.make(e).val;
     }
 }