Exemplo n.º 1
0
        public IByteBuffer WithOrder(ByteOrder order)
        {
            if (order == this.Order)
            {
                return(this);
            }
            SwappedByteBuffer swappedBuf = this.swappedByteBuffer;

            if (swappedBuf == null)
            {
                this.swappedByteBuffer = swappedBuf = this.NewSwappedByteBuffer();
            }
            return(swappedBuf);
        }
Exemplo n.º 2
0
        public override IByteBuffer WithOrder(ByteOrder endianness)
        {
            if (this.Order == endianness)
            {
                return(this);
            }

            SwappedByteBuffer buffer = this.swappedBuffer;

            if (buffer != null)
            {
                return(this.swappedBuffer);
            }

            buffer             = new SwappedByteBuffer(this);
            this.swappedBuffer = buffer;

            return(this.swappedBuffer);
        }
Exemplo n.º 3
0
 public IByteBuffer WithOrder(ByteOrder order)
 {
     if (order == this.Order)
     {
         return this;
     }
     SwappedByteBuffer swappedBuf = this.swappedByteBuffer;
     if (swappedBuf == null)
     {
         this.swappedByteBuffer = swappedBuf = this.NewSwappedByteBuffer();
     }
     return swappedBuf;
 }