Packages

c

com.electronwill.niol.io

ChannelOutput

final class ChannelOutput extends NiolOutput with Closeable

A NiolOutput based on a ByteChannel. The channel must be in blocking mode for the ChannelOutput to work correctly.

Linear Supertypes
Closeable, AutoCloseable, NiolOutput, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. ChannelOutput
  2. Closeable
  3. AutoCloseable
  4. NiolOutput
  5. AnyRef
  6. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new ChannelOutput(path: Path, prov: StorageProvider)
  2. new ChannelOutput(path: Path, storage: BytesStorage)
  3. new ChannelOutput(fc: FileChannel, prov: StorageProvider)
  4. new ChannelOutput(channel: GatheringByteChannel, storage: BytesStorage)

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def _write(from: ByteBuffer, len: Int): Unit

    Implements write without necessarily checking for available space.

    Implements write without necessarily checking for available space.

    Attributes
    protected[niol]
    Definition Classes
    ChannelOutputNiolOutput
  5. def _write(from: Array[Byte], off: Int, len: Int): Unit

    Implements write without necessarily checking for available space.

    Implements write without necessarily checking for available space.

    Attributes
    protected[niol]
    Definition Classes
    ChannelOutputNiolOutput
  6. def _write(b: Byte): Unit

    Implements write without necessarily checking for available space.

    Implements write without necessarily checking for available space.

    Attributes
    protected[niol]
    Definition Classes
    ChannelOutputNiolOutput
  7. final def _write(b: Long): Unit

    Implements write without necessarily checking for available space.

    Implements write without necessarily checking for available space.

    Attributes
    protected[niol]
    Definition Classes
    NiolOutput
  8. final def _write(b: Int): Unit

    Implements write without necessarily checking for available space.

    Implements write without necessarily checking for available space.

    Attributes
    protected[niol]
    Definition Classes
    NiolOutput
  9. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  10. val channel: GatheringByteChannel
  11. def check(nValues: Int, n: Int): Unit

    Checks if at least n bytes can be written

    Checks if at least n bytes can be written

    Attributes
    protected[niol]
    Definition Classes
    NiolOutput
  12. def checkWritable(n: Int): Unit

    Checks if at least n bytes can be written

    Checks if at least n bytes can be written

    Attributes
    protected[niol]
    Definition Classes
    NiolOutput
  13. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  14. def close(): Unit
    Definition Classes
    ChannelOutput → Closeable → AutoCloseable
    Annotations
    @throws( ... )
  15. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  16. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  17. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  18. def flush(): Unit
  19. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  20. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  21. def isEnded: Boolean

    True if this output is closed or has definitively reached its end.

    True if this output is closed or has definitively reached its end. If isEnded == true then isWriteable == false and writableBytes == 0.

    returns

    true if it's closed or has definitively reached its end, false otherwise

    Definition Classes
    ChannelOutputNiolOutput
  22. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  23. def isWritable: Boolean

    * True if a byte can be written to this NiolOutput.

    * True if a byte can be written to this NiolOutput.

    returns

    true if at least one byte can be written, false otherwise

    Definition Classes
    ChannelOutputNiolOutput
  24. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  25. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  26. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  27. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  28. def toString(): String
    Definition Classes
    AnyRef → Any
  29. def tryWrite(b: Byte): Boolean

    Attempts to write a byte.

    Attempts to write a byte. Returns false if the output is full.

    b

    the byte to write

    returns

    true if the byte has been write, false if the output is full

    Definition Classes
    NiolOutput
  30. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  31. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  32. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  33. def writableBytes: Int

    The number of bytes that can be written to this NiolOutput.

    The number of bytes that can be written to this NiolOutput. This number is always >= 0. It may be underestimated except when it's zero, that is, if writableBytes == 0 then no byte can be written and isWritable == false.

    returns

    n > 0 if can write n bytes, 0 if closed output or full buffer

    Definition Classes
    ChannelOutputNiolOutput
  34. def write(src: NiolBuffer): Unit

    Writes all of the given NiolBuffer.

    Writes all of the given NiolBuffer. Throws an exception if there isn't enough space for the data.

    src

    the buffer to write

    Definition Classes
    ChannelOutputNiolOutput
  35. def write(src: Array[Byte], offset: Int, length: Int): Unit

    Writes the content of src, starting at index offset and ending at index offset+length-1.

    Writes the content of src, starting at index offset and ending at index offset+length-1. Throws an exception if there isn't enough space for the data or if the array index goes out of bounds.

    src

    the array to write

    offset

    the first index to use

    length

    the number of bytes to write

    Definition Classes
    NiolOutput
  36. def write(src: Array[Byte]): Unit

    Writes all the bytes of src.

    Writes all the bytes of src. Throws an exception if there isn't enough space for the data.

    src

    the array to write

    Definition Classes
    NiolOutput
  37. def write(src: ByteBuffer): Unit

    Writes all of the given ByteBuffer.

    Writes all of the given ByteBuffer. Throws an exception if there isn't enough space for the data.

    src

    the buffer to write

    Definition Classes
    NiolOutput
  38. def write(b: Byte): Unit

    Writes a byte.

    Writes a byte.

    b

    the byte to write

    Definition Classes
    NiolOutput
  39. def writeBool(bool: Boolean, trueValue: Byte, falseValue: Byte): Unit

    Writes a boolean.

    Writes a boolean. If it's true, writes trueValue. If it's false, writes falseValue.

    bool

    the boolean to write

    trueValue

    the byte to write if the boolean is true

    falseValue

    the byte to write if the boolean is false

    Definition Classes
    NiolOutput
  40. def writeBool(bool: Boolean): Unit

    Writes a boolean.

    Writes a boolean. The default behavior is as follow: If it's true, writes the byte 1. If it's false, writes the byte 0.

    bool

    the boolean to write

    Definition Classes
    NiolOutput
  41. def writeBoolean(boolean: Boolean): Unit

    Writes a boolean.

    Writes a boolean. The default behavior is as follow: If the value is true, writes the byte 1. If it's false, writes the byte 0.

    boolean

    the boolean to write

    Definition Classes
    NiolOutput
  42. def writeBooleans(src: Array[Boolean], offset: Int, length: Int): Unit

    Writes the content of src, starting at index offset and ending at index offset+length-1.

    Writes the content of src, starting at index offset and ending at index offset+length-1. Throws an exception if there isn't enough space for the data or if the array index goes out of bounds.

    src

    the array to write

    offset

    the first index to use

    length

    the number of booleans to write

    Definition Classes
    NiolOutput
  43. def writeBooleans(src: Array[Boolean]): Unit

    Writes all the booleans of src.

    Writes all the booleans of src. Throws an exception if there isn't enough space for the data.

    src

    the array to write

    Definition Classes
    NiolOutput
  44. final def writeByte(l: Long): Unit

    Writes the least significant byte of a long.

    Writes the least significant byte of a long.

    l

    the value to write

    Definition Classes
    NiolOutput
  45. final def writeByte(i: Int): Unit

    Writes the least significant byte of an int.

    Writes the least significant byte of an int.

    i

    the value to write

    Definition Classes
    NiolOutput
  46. final def writeByte(b: Byte): Unit

    Writes a byte.

    Writes a byte.

    b

    the byte to write

    Definition Classes
    NiolOutput
  47. final def writeChar(c: Char): Unit

    Writes a big-endian char.

    Writes a big-endian char.

    c

    the value to write

    Definition Classes
    NiolOutput
  48. final def writeCharLE(c: Char): Unit

    Writes a little-endian char.

    Writes a little-endian char.

    c

    the value to write

    Definition Classes
    NiolOutput
  49. final def writeCharSequence(csq: CharSequence, charset: Charset = UTF_8): Unit

    Writes a CharSequence with the given charset.

    Writes a CharSequence with the given charset. The written data isn't prefixed by its length.

    csq

    the value to write

    charset

    the charset to encode the CharSequence with

    Definition Classes
    NiolOutput
  50. def writeDouble(d: Double): Unit

    Writes a big-endian 8-bytes double.

    Writes a big-endian 8-bytes double.

    d

    the value to write

    Definition Classes
    ChannelOutputNiolOutput
  51. def writeDoubleLE(d: Double): Unit

    Writes a little-endian 8-bytes double.

    Writes a little-endian 8-bytes double.

    d

    the value to write

    Definition Classes
    NiolOutput
  52. def writeDoubles(src: Array[Double], offset: Int, length: Int): Unit

    Writes the content of src, starting at index offset and ending at index offset+length-1.

    Writes the content of src, starting at index offset and ending at index offset+length-1. Uses big-endian for each value. Throws an exception if there isn't enough space for the data or if the array index goes out of bounds.

    src

    the array to write

    offset

    the first index to use

    length

    the number of doubles to write

    Definition Classes
    NiolOutput
  53. def writeDoubles(src: Array[Double]): Unit

    Writes all the doubles of src.

    Writes all the doubles of src. Uses big-endian for each value. Throws an exception if there isn't enough space for the data.

    src

    the array to write

    Definition Classes
    NiolOutput
  54. def writeDoublesLE(src: Array[Double], offset: Int, length: Int): Unit

    Writes the content of src, starting at index offset and ending at index offset+length-1.

    Writes the content of src, starting at index offset and ending at index offset+length-1. Uses little-endian for each value. Throws an exception if there isn't enough space for the data or if the array index goes out of bounds.

    src

    the array to write

    offset

    the first index to use

    length

    the number of doubles to write

    Definition Classes
    NiolOutput
  55. def writeDoublesLE(src: Array[Double]): Unit

    Writes all the doubles of src.

    Writes all the doubles of src. Uses little-endian for each value. Throws an exception if there isn't enough space for the data.

    src

    the array to write

    Definition Classes
    NiolOutput
  56. def writeFloat(f: Float): Unit

    Writes a big-endian 4-bytes float.

    Writes a big-endian 4-bytes float.

    f

    the value to write

    Definition Classes
    ChannelOutputNiolOutput
  57. final def writeFloat(f: Double): Unit

    Writes a big-endian 4-bytes float.

    Writes a big-endian 4-bytes float.

    f

    the value to write

    Definition Classes
    NiolOutput
  58. final def writeFloatLE(f: Double): Unit

    Writes a little-endian 4-bytes float.

    Writes a little-endian 4-bytes float.

    f

    the value to write

    Definition Classes
    NiolOutput
  59. def writeFloatLE(f: Float): Unit

    Writes a little-endian 4-bytes float.

    Writes a little-endian 4-bytes float.

    f

    the value to write

    Definition Classes
    NiolOutput
  60. def writeFloats(src: Array[Float], offset: Int, length: Int): Unit

    Writes the content of src, starting at index offset and ending at index offset+length-1.

    Writes the content of src, starting at index offset and ending at index offset+length-1. Uses big-endian for each value. Throws an exception if there isn't enough space for the data or if the array index goes out of bounds.

    src

    the array to write

    offset

    the first index to use

    length

    the number of floats to write

    Definition Classes
    NiolOutput
  61. def writeFloats(src: Array[Float]): Unit

    Writes all the floats of src.

    Writes all the floats of src. Uses big-endian for each value. Throws an exception if there isn't enough space for the data.

    src

    the array to write

    Definition Classes
    NiolOutput
  62. def writeFloatsLE(src: Array[Float], offset: Int, length: Int): Unit

    Writes the content of src, starting at index offset and ending at index offset+length-1.

    Writes the content of src, starting at index offset and ending at index offset+length-1. Uses little-endian for each value. Throws an exception if there isn't enough space for the data or if the array index goes out of bounds.

    src

    the array to write

    offset

    the first index to use

    length

    the number of floats to write

    Definition Classes
    NiolOutput
  63. def writeFloatsLE(src: Array[Float]): Unit

    Writes all the floats of src.

    Writes all the floats of src. Uses little-endian for each value. Throws an exception if there isn't enough space for the data.

    src

    the array to write

    Definition Classes
    NiolOutput
  64. def writeInt(i: Int): Unit

    Writes a big-endian 4-bytes integer.

    Writes a big-endian 4-bytes integer.

    i

    the value to write

    Definition Classes
    ChannelOutputNiolOutput
  65. def writeIntLE(i: Int): Unit

    Writes a little-endian 4-bytes integer.

    Writes a little-endian 4-bytes integer.

    i

    the value to write

    Definition Classes
    NiolOutput
  66. def writeInts(src: Array[Int], offset: Int, length: Int): Unit

    Writes the content of src, starting at index offset and ending at index offset+length-1.

    Writes the content of src, starting at index offset and ending at index offset+length-1. Uses big-endian for each value. Throws an exception if there isn't enough space for the data or if the array index goes out of bounds.

    src

    the array to write

    offset

    the first index to use

    length

    the number of ints to write

    Definition Classes
    NiolOutput
  67. def writeInts(src: Array[Int]): Unit

    Writes all the ints of src.

    Writes all the ints of src. Uses big-endian for each value. Throws an exception if there isn't enough space for the data.

    src

    the array to write

    Definition Classes
    NiolOutput
  68. def writeIntsLE(src: Array[Int], offset: Int, length: Int): Unit

    Writes the content of src, starting at index offset and ending at index offset+length-1.

    Writes the content of src, starting at index offset and ending at index offset+length-1. Uses little-endian for each value. Throws an exception if there isn't enough space for the data or if the array index goes out of bounds.

    src

    the array to write

    offset

    the first index to use

    length

    the number of ints to write

    Definition Classes
    NiolOutput
  69. def writeIntsLE(src: Array[Int]): Unit

    Writes all the ints of src.

    Writes all the ints of src. Uses little-endian for each value. Throws an exception if there isn't enough space for the data.

    src

    the array to write

    Definition Classes
    NiolOutput
  70. def writeLong(l: Long): Unit

    Writes a big-endian 8-bytes integer.

    Writes a big-endian 8-bytes integer.

    l

    the value to write

    Definition Classes
    ChannelOutputNiolOutput
  71. def writeLongLE(l: Long): Unit

    Writes a little-endian 8-bytes integer.

    Writes a little-endian 8-bytes integer.

    l

    the value to write

    Definition Classes
    NiolOutput
  72. def writeLongs(src: Array[Long], offset: Int, length: Int): Unit

    Writes the content of src, starting at index offset and ending at index offset+length-1.

    Writes the content of src, starting at index offset and ending at index offset+length-1. Uses big-endian for each value. Throws an exception if there isn't enough space for the data or if the array index goes out of bounds.

    src

    the array to write

    offset

    the first index to use

    length

    the number of longs to write

    Definition Classes
    NiolOutput
  73. def writeLongs(src: Array[Long]): Unit

    Writes all the longs of src.

    Writes all the longs of src. Uses big-endian for each value. Throws an exception if there isn't enough space for the data.

    src

    the array to write

    Definition Classes
    NiolOutput
  74. def writeLongsLE(src: Array[Long], offset: Int, length: Int): Unit

    Writes the content of src, starting at index offset and ending at index offset+length-1.

    Writes the content of src, starting at index offset and ending at index offset+length-1. Uses little-endian for each value. Throws an exception if there isn't enough space for the data or if the array index goes out of bounds.

    src

    the array to write

    offset

    the first index to use

    length

    the number of longs to write

    Definition Classes
    NiolOutput
  75. def writeLongsLE(src: Array[Long]): Unit

    Writes all the longs of src.

    Writes all the longs of src. Uses little-endian for each value. Throws an exception if there isn't enough space for the data.

    src

    the array to write

    Definition Classes
    NiolOutput
  76. def writeMedium(m: Int): Unit

    Writes a big-endian 3-bytes integer.

    Writes a big-endian 3-bytes integer.

    m

    the value to write

    Definition Classes
    NiolOutput
  77. def writeMediumLE(m: Int): Unit

    Writes a little-endian 3-bytes integer.

    Writes a little-endian 3-bytes integer.

    m

    the value to write

    Definition Classes
    NiolOutput
  78. final def writeSVarIntZigZag(n: Int): Unit

    Writes a variable-length int using the signed/zig-zag encoding.

    Writes a variable-length int using the signed/zig-zag encoding.

    n

    the value to write

    Definition Classes
    NiolOutput
  79. final def writeSVarLongZigZag(n: Long): Unit

    Writes a variable-length long using the signed/zig-zag encoding.

    Writes a variable-length long using the signed/zig-zag encoding.

    n

    the value to write

    Definition Classes
    NiolOutput
  80. def writeShort(s: Int): Unit

    Writes a big-endian short.

    Writes a big-endian short.

    Definition Classes
    ChannelOutputNiolOutput
  81. final def writeShort(s: Short): Unit

    Writes a big-endian short.

    Writes a big-endian short.

    s

    the value to write

    Definition Classes
    NiolOutput
  82. def writeShortLE(i: Int): Unit

    Writes a little-endian short.

    Writes a little-endian short.

    i

    the value to write

    Definition Classes
    NiolOutput
  83. final def writeShortLE(s: Short): Unit

    Writes a little-endian short.

    Writes a little-endian short.

    s

    the value to write

    Definition Classes
    NiolOutput
  84. final def writeShortString(csq: CharSequence, charset: Charset = UTF_8): Unit

    Writes a CharSequence with the given charset, prefixed by its length written as a big-endian 2-bytes unsigned integer.

    Writes a CharSequence with the given charset, prefixed by its length written as a big-endian 2-bytes unsigned integer.

    csq

    the value to write

    charset

    the charset to encode the CharSequence with

    Definition Classes
    NiolOutput
  85. final def writeShortStringLE(csq: CharSequence, charset: Charset = UTF_8): Unit

    Writes a CharSequence with the given charset, prefixed by its length written as a little-endian 2-bytes unsigned integer.

    Writes a CharSequence with the given charset, prefixed by its length written as a little-endian 2-bytes unsigned integer.

    csq

    the value to write

    charset

    the charset to encode the CharSequence with

    Definition Classes
    NiolOutput
  86. def writeShorts(src: Array[Short], offset: Int, length: Int): Unit

    Writes the content of src, starting at index offset and ending at index offset+length-1.

    Writes the content of src, starting at index offset and ending at index offset+length-1. Uses big-endian for each value. Throws an exception if there isn't enough space for the data or if the array index goes out of bounds.

    src

    the array to write

    offset

    the first index to use

    length

    the number of shorts to write

    Definition Classes
    NiolOutput
  87. def writeShorts(src: Array[Short]): Unit

    Writes all the shorts of src.

    Writes all the shorts of src. Uses big-endian for each value. Throws an exception if there isn't enough space for the data.

    src

    the array to write

    Definition Classes
    NiolOutput
  88. def writeShortsLE(src: Array[Short], offset: Int, length: Int): Unit

    Writes the content of src, starting at index offset and ending at index offset+length-1.

    Writes the content of src, starting at index offset and ending at index offset+length-1. Uses little-endian for each value. Throws an exception if there isn't enough space for the data or if the array index goes out of bounds.

    src

    the array to write

    offset

    the first index to use

    length

    the number of shorts to write

    Definition Classes
    NiolOutput
  89. def writeShortsLE(src: Array[Short]): Unit

    Writes all the shorts of src.

    Writes all the shorts of src. Uses little-endian for each value. Throws an exception if there isn't enough space for the data.

    src

    the array to write

    Definition Classes
    NiolOutput
  90. def writeSome(src: NiolBuffer): Int

    Writes at most src.readableBytes bytes from src into this output.

    Writes at most src.readableBytes bytes from src into this output. The buffer's read position will be advanced by the number of bytes written to this NiolOutput.

    src

    the buffer to write

    Definition Classes
    ChannelOutputNiolOutput
  91. def writeSome(src: Array[Byte], offset: Int, length: Int): Int

    Writes at most length bytes of src, starting at index offset.

    Writes at most length bytes of src, starting at index offset. Returns the actual number of bytes written, possibly zero.

    src

    the array to write

    offset

    the first index to use

    length

    the number of bytes to write

    returns

    the number of bytes written

    Definition Classes
    NiolOutput
  92. def writeSome(src: Array[Byte]): Int

    Writes at most src.length bytes of src.

    Writes at most src.length bytes of src. Returns the actual number of bytes written, possibly zero.

    src

    the array to write

    returns

    the number of bytes written

    Definition Classes
    NiolOutput
  93. def writeSome(src: ByteBuffer): Int

    Writes at most src.remaining() bytes from src into this output.

    Writes at most src.remaining() bytes from src into this output. The buffer's position will be advanced by the number of bytes written to this NiolOutput.

    src

    the buffer to write

    Definition Classes
    NiolOutput
  94. def writeSomeBooleans(src: Array[Boolean], offset: Int, length: Int): Int

    Writes at most length booleans of src, starting at index offset.

    Writes at most length booleans of src, starting at index offset. Returns the actual number of booleans written, possibly zero.

    src

    the array to write

    offset

    the first index to use

    length

    the number of booleans to write

    returns

    the number of booleans written

    Definition Classes
    NiolOutput
  95. def writeSomeBooleans(src: Array[Boolean]): Int

    Writes at most src.length booleans of src.

    Writes at most src.length booleans of src. Returns the actual number of booleans written, possibly zero.

    src

    the array to write

    returns

    the number of booleans written

    Definition Classes
    NiolOutput
  96. def writeSomeDoubles(src: Array[Double], offset: Int, length: Int): Int

    Writes at most length doubles of src, starting at index offset.

    Writes at most length doubles of src, starting at index offset. Uses big-endian for each value. Returns the actual number of doubles written, possibly zero.

    src

    the array to write

    offset

    the first index to use

    length

    the number of doubles to write

    returns

    the number of doubles written

    Definition Classes
    NiolOutput
  97. def writeSomeDoubles(src: Array[Double]): Int

    Writes at most src.length doubles of src.

    Writes at most src.length doubles of src. Uses big-endian for each value. Returns the actual number of doubles written, possibly zero.

    src

    the array to write

    returns

    the number of doubles written

    Definition Classes
    NiolOutput
  98. def writeSomeDoublesLE(src: Array[Double], offset: Int, length: Int): Int

    Writes at most length doubles of src, starting at index offset.

    Writes at most length doubles of src, starting at index offset. Uses little-endian for each value. Returns the actual number of doubles written, possibly zero.

    src

    the array to write

    offset

    the first index to use

    length

    the number of doubles to write

    returns

    the number of doubles written

    Definition Classes
    NiolOutput
  99. def writeSomeDoublesLE(src: Array[Double]): Int

    Writes at most src.length doubles of src for each value.

    Writes at most src.length doubles of src for each value. Uses little-endian for each value. Returns the actual number of doubles written, possibly zero.

    src

    the array to write

    returns

    the number of doubles written

    Definition Classes
    NiolOutput
  100. def writeSomeFloats(src: Array[Float], offset: Int, length: Int): Int

    Writes at most length floats of src, starting at index offset.

    Writes at most length floats of src, starting at index offset. Uses big-endian for each value. Returns the actual number of floats written, possibly zero.

    src

    the array to write

    offset

    the first index to use

    length

    the number of floats to write

    returns

    the number of floats written

    Definition Classes
    NiolOutput
  101. def writeSomeFloats(src: Array[Float]): Int

    Writes at most src.length floats of src.

    Writes at most src.length floats of src. Uses big-endian for each value. Returns the actual number of floats written, possibly zero.

    src

    the array to write

    returns

    the number of floats written

    Definition Classes
    NiolOutput
  102. def writeSomeFloatsLE(src: Array[Float], offset: Int, length: Int): Int

    Writes at most length floats of src, starting at index offset.

    Writes at most length floats of src, starting at index offset. Uses little-endian for each value. Returns the actual number of floats written, possibly zero.

    src

    the array to write

    offset

    the first index to use

    length

    the number of floats to write

    returns

    the number of floats written

    Definition Classes
    NiolOutput
  103. def writeSomeFloatsLE(src: Array[Float]): Int

    Writes at most src.length floats of src for each value.

    Writes at most src.length floats of src for each value. Uses little-endian for each value. Returns the actual number of floats written, possibly zero.

    src

    the array to write

    returns

    the number of floats written

    Definition Classes
    NiolOutput
  104. def writeSomeInts(src: Array[Int], offset: Int, length: Int): Int

    Writes at most length ints of src, starting at index offset.

    Writes at most length ints of src, starting at index offset. Uses big-endian for each value. Returns the actual number of ints written, possibly zero.

    src

    the array to write

    offset

    the first index to use

    length

    the number of ints to write

    returns

    the number of ints written

    Definition Classes
    NiolOutput
  105. def writeSomeInts(src: Array[Int]): Int

    Writes at most src.length ints of src.

    Writes at most src.length ints of src. Uses big-endian for each value. Returns the actual number of ints written, possibly zero.

    src

    the array to write

    returns

    the number of ints written

    Definition Classes
    NiolOutput
  106. def writeSomeIntsLE(src: Array[Int], offset: Int, length: Int): Int

    Writes at most length ints of src, starting at index offset.

    Writes at most length ints of src, starting at index offset. Uses little-endian for each value. Returns the actual number of ints written, possibly zero.

    src

    the array to write

    offset

    the first index to use

    length

    the number of ints to write

    returns

    the number of ints written

    Definition Classes
    NiolOutput
  107. def writeSomeIntsLE(src: Array[Int]): Int

    Writes at most src.length ints of src for each value.

    Writes at most src.length ints of src for each value. Uses little-endian for each value. Returns the actual number of ints written, possibly zero.

    src

    the array to write

    returns

    the number of ints written

    Definition Classes
    NiolOutput
  108. def writeSomeLongs(src: Array[Long], offset: Int, length: Int): Int

    Writes at most length longs of src, starting at index offset.

    Writes at most length longs of src, starting at index offset. Uses big-endian for each value. Returns the actual number of longs written, possibly zero.

    src

    the array to write

    offset

    the first index to use

    length

    the number of longs to write

    returns

    the number of longs written

    Definition Classes
    NiolOutput
  109. def writeSomeLongs(src: Array[Long]): Int

    Writes at most src.length longs of src.

    Writes at most src.length longs of src. Uses big-endian for each value. Returns the actual number of longs written, possibly zero.

    src

    the array to write

    returns

    the number of longs written

    Definition Classes
    NiolOutput
  110. def writeSomeLongsLE(src: Array[Long], offset: Int, length: Int): Int

    Writes at most length longs of src, starting at index offset.

    Writes at most length longs of src, starting at index offset. Uses little-endian for each value. Returns the actual number of longs written, possibly zero.

    src

    the array to write

    offset

    the first index to use

    length

    the number of longs to write

    returns

    the number of longs written

    Definition Classes
    NiolOutput
  111. def writeSomeLongsLE(src: Array[Long]): Int

    Writes at most src.length longs of src for each value.

    Writes at most src.length longs of src for each value. Uses little-endian for each value. Returns the actual number of longs written, possibly zero.

    src

    the array to write

    returns

    the number of longs written

    Definition Classes
    NiolOutput
  112. def writeSomeShorts(src: Array[Short], offset: Int, length: Int): Int

    Writes at most length shorts of src, starting at index offset.

    Writes at most length shorts of src, starting at index offset. Uses big-endian for each value. Returns the actual number of shorts written, possibly zero.

    src

    the array to write

    offset

    the first index to use

    length

    the number of shorts to write

    returns

    the number of shorts written

    Definition Classes
    NiolOutput
  113. def writeSomeShorts(src: Array[Short]): Int

    Writes at most src.length shorts of src.

    Writes at most src.length shorts of src. Uses big-endian for each value. Returns the actual number of shorts written, possibly zero.

    src

    the array to write

    returns

    the number of shorts written

    Definition Classes
    NiolOutput
  114. def writeSomeShortsLE(src: Array[Short], offset: Int, length: Int): Int

    Writes at most length shorts of src, starting at index offset.

    Writes at most length shorts of src, starting at index offset. Uses little-endian for each value. Returns the actual number of shorts written, possibly zero.

    src

    the array to write

    offset

    the first index to use

    length

    the number of shorts to write

    returns

    the number of shorts written

    Definition Classes
    NiolOutput
  115. def writeSomeShortsLE(src: Array[Short]): Int

    Writes at most src.length shorts of src for each value.

    Writes at most src.length shorts of src for each value. Uses little-endian for each value. Returns the actual number of shorts written, possibly zero.

    src

    the array to write

    returns

    the number of shorts written

    Definition Classes
    NiolOutput
  116. final def writeString(str: String, charset: Charset = UTF_8): Unit

    Writes a String with the given charset.

    Writes a String with the given charset. The written data isn't prefixed by its length.

    str

    the value to write

    charset

    the charset to encode the String with

    Definition Classes
    NiolOutput
  117. final def writeUUID(uuid: UUID): Unit

    Writes a UUID as two 8-bytes big-endian integers, most significant bits first.

    Writes a UUID as two 8-bytes big-endian integers, most significant bits first.

    uuid

    the value to write

    Definition Classes
    NiolOutput
  118. def writeVarInt(i: Int): Unit

    Writes a variable-length int using the normal/unsigned encoding.

    Writes a variable-length int using the normal/unsigned encoding.

    i

    the value to write

    Definition Classes
    NiolOutput
  119. def writeVarLong(l: Long): Unit

    Writes a variable-length long using the normal/unsigned encoding.

    Writes a variable-length long using the normal/unsigned encoding.

    l

    the value to write

    Definition Classes
    NiolOutput
  120. final def writeVarString(csq: CharSequence, charset: Charset = UTF_8): Unit

    Writes a CharSequence with the given charset, preceded by its length written as a normal VarInt.

    Writes a CharSequence with the given charset, preceded by its length written as a normal VarInt.

    csq

    the value to write

    charset

    the charset to CharSequence the String with

    Definition Classes
    NiolOutput

Inherited from Closeable

Inherited from AutoCloseable

Inherited from NiolOutput

Inherited from AnyRef

Inherited from Any

Ungrouped