Java ByteBuffer to Byte Array getBytes(MappedByteBuffer buffer, int pos, byte[] target)

Here you can find the source of getBytes(MappedByteBuffer buffer, int pos, byte[] target)

Description

get Bytes

License

Apache License

Declaration

public static void getBytes(MappedByteBuffer buffer, int pos, byte[] target) 

Method Source Code

//package com.java2s;
// Licensed under the Apache License, Version 2.0 (the "License");

import java.nio.MappedByteBuffer;

public class Main {
    public static void getBytes(MappedByteBuffer buffer, int pos, byte[] target) {
        for (int i = 0; i < target.length; ++i) {
            target[i] = buffer.get(pos + i);
        }/*from w  ww  .ja va  2  s.  c  o m*/
    }
}

Related

  1. getBytes(ByteBuffer buffer, int len)
  2. getBytes(ByteBuffer byteBuffer, int length)
  3. getBytes(ByteBuffer bytes)
  4. getBytes(ByteBuffer floatCalculator, float number)
  5. getBytes(ByteBuffer in)
  6. getBytesAtOffset(ByteBuffer buffer, int offset, int length)
  7. getBytesFromBuffer(ByteBuffer buffer, int len)
  8. getBytesFromByteBuffer(ByteBuffer byteBuffer)
  9. getBytesFromByteBuffer(Object obj)