コード例 #1
0
        public Nfs3WriteResult Write(Nfs3FileHandle handle, long position, byte[] buffer, int bufferOffset, int count)
        {
            MemoryStream  ms     = new MemoryStream();
            XdrDataWriter writer = StartCallMessage(ms, _client.Credentials, 7);

            handle.Write(writer);
            writer.Write(position);
            writer.Write(count);
            writer.Write((int)0); // UNSTABLE
            writer.WriteBuffer(buffer, bufferOffset, count);

            RpcReply reply = DoSend(ms);

            if (reply.Header.IsSuccess)
            {
                return(new Nfs3WriteResult(reply.BodyReader));
            }
            else
            {
                throw new RpcException(reply.Header.ReplyHeader);
            }
        }
コード例 #2
0
ファイル: Nfs3FileHandle.cs プロジェクト: ibeae/ThinkAway.net
 internal void Write(XdrDataWriter writer)
 {
     writer.WriteBuffer(Value);
 }
コード例 #3
0
 public void Write(XdrDataWriter writer)
 {
     writer.Write((int)_flavour);
     writer.WriteBuffer(_body);
 }
コード例 #4
0
 public void Write(XdrDataWriter writer)
 {
     writer.Write((int)_flavour);
     writer.WriteBuffer(_body);
 }