io.netty.buffer.ByteBuf.getIntLE()方法的使用及代码示例

x33g5p2x  于2022-01-16 转载在 其他  
字(4.3k)|赞(0)|评价(0)|浏览(397)

本文整理了Java中io.netty.buffer.ByteBuf.getIntLE()方法的一些代码示例,展示了ByteBuf.getIntLE()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ByteBuf.getIntLE()方法的具体详情如下:
包路径:io.netty.buffer.ByteBuf
类名称:ByteBuf
方法名:getIntLE

ByteBuf.getIntLE介绍

[英]Gets a 32-bit integer at the specified absolute index in this buffer with Little Endian Byte Order. This method does not modify readerIndex or writerIndex of this buffer.
[中]获取此缓冲区中指定绝对索引处的32位整数,其字节顺序为小尾数。此方法不修改此缓冲区的readerIndex或writerIndex。

代码示例

代码示例来源:origin: netty/netty

@Override
public int getIntLE(int index) {
  return buf.getIntLE(index);
}

代码示例来源:origin: redisson/redisson

@Override
public int getIntLE(int index) {
  return buf.getIntLE(index);
}

代码示例来源:origin: netty/netty

/**
 * Gets a 32-bit floating point number at the specified absolute
 * {@code index} in this buffer in Little Endian Byte Order.
 * This method does not modify {@code readerIndex} or
 * {@code writerIndex} of this buffer.
 *
 * @throws IndexOutOfBoundsException
 *         if the specified {@code index} is less than {@code 0} or
 *         {@code index + 4} is greater than {@code this.capacity}
 */
public float getFloatLE(int index) {
  return Float.intBitsToFloat(getIntLE(index));
}

代码示例来源:origin: redisson/redisson

/**
 * Gets a 32-bit floating point number at the specified absolute
 * {@code index} in this buffer in Little Endian Byte Order.
 * This method does not modify {@code readerIndex} or
 * {@code writerIndex} of this buffer.
 *
 * @throws IndexOutOfBoundsException
 *         if the specified {@code index} is less than {@code 0} or
 *         {@code index + 4} is greater than {@code this.capacity}
 */
public float getFloatLE(int index) {
  return Float.intBitsToFloat(getIntLE(index));
}

代码示例来源:origin: netty/netty

@Override
public int getIntLE(int index) {
  checkIndex(index, 4);
  return buffer.getIntLE(index);
}

代码示例来源:origin: netty/netty

@Override
public int getIntLE(int index) {
  return unwrap().getIntLE(index);
}

代码示例来源:origin: netty/netty

@Override
protected int _getIntLE(int index) {
  return unwrap().getIntLE(index);
}

代码示例来源:origin: netty/netty

@Override
public int getIntLE(int index) {
  return unwrap().getIntLE(index);
}

代码示例来源:origin: netty/netty

@Override
protected int _getIntLE(int index) {
  return unwrap().getIntLE(index);
}

代码示例来源:origin: redisson/redisson

@Override
public int getIntLE(int index) {
  checkIndex(index, 4);
  return buffer.getIntLE(index);
}

代码示例来源:origin: redisson/redisson

@Override
public int getIntLE(int index) {
  return unwrap().getIntLE(index);
}

代码示例来源:origin: redisson/redisson

@Override
public int getIntLE(int index) {
  return unwrap().getIntLE(index);
}

代码示例来源:origin: redisson/redisson

@Override
protected int _getIntLE(int index) {
  return unwrap().getIntLE(index);
}

代码示例来源:origin: netty/netty

@Override
protected int _getIntLE(int index) {
  return unwrap().getIntLE(idx(index));
}

代码示例来源:origin: netty/netty

@Override
public int getIntLE(int index) {
  checkIndex0(index, 4);
  return unwrap().getIntLE(idx(index));
}

代码示例来源:origin: redisson/redisson

@Override
public int getIntLE(int index) {
  checkIndex0(index, 4);
  return unwrap().getIntLE(idx(index));
}

代码示例来源:origin: netty/netty

@Override
protected int _getIntLE(int index) {
  Component c = findComponent(index);
  if (index + 4 <= c.endOffset) {
    return c.buf.getIntLE(index - c.offset);
  } else if (order() == ByteOrder.BIG_ENDIAN) {
    return _getShortLE(index) & 0xFFFF | (_getShortLE(index + 2) & 0xFFFF) << 16;
  } else {
    return (_getShortLE(index) & 0xffff) << 16 | _getShortLE(index + 2) & 0xffff;
  }
}

代码示例来源:origin: netty/netty

@Override
protected int _getIntLE(int index) {
  Component c = findComponent0(index);
  if (index + 4 <= c.endOffset) {
    return c.buf.getIntLE(c.idx(index));
  } else if (order() == ByteOrder.BIG_ENDIAN) {
    return _getShortLE(index) & 0xffff | (_getShortLE(index + 2) & 0xffff) << 16;
  } else {
    return (_getShortLE(index) & 0xffff) << 16 | _getShortLE(index + 2) & 0xffff;
  }
}

代码示例来源:origin: redisson/redisson

@Override
protected int _getIntLE(int index) {
  Component c = findComponent(index);
  if (index + 4 <= c.endOffset) {
    return c.buf.getIntLE(index - c.offset);
  } else if (order() == ByteOrder.BIG_ENDIAN) {
    return _getShortLE(index) & 0xFFFF | (_getShortLE(index + 2) & 0xFFFF) << 16;
  } else {
    return (_getShortLE(index) & 0xffff) << 16 | _getShortLE(index + 2) & 0xffff;
  }
}

代码示例来源:origin: redisson/redisson

@Override
protected int _getIntLE(int index) {
  Component c = findComponent0(index);
  if (index + 4 <= c.endOffset) {
    return c.buf.getIntLE(c.idx(index));
  } else if (order() == ByteOrder.BIG_ENDIAN) {
    return _getShortLE(index) & 0xffff | (_getShortLE(index + 2) & 0xffff) << 16;
  } else {
    return (_getShortLE(index) & 0xffff) << 16 | _getShortLE(index + 2) & 0xffff;
  }
}

相关文章

ByteBuf类方法