ServerJS/Binary/B: Difference between revisions

Jump to navigation Jump to search
→‎Instance methods (in prototype): There is no "default charset". And there should be none.
(Added link to tests)
(→‎Instance methods (in prototype): There is no "default charset". And there should be none.)
Line 140: Line 140:
; toString()
; toString()
: A string debug representation like "[ByteArray 10]". Alternative debug representations are valid too, as long as (1) this method will never fail, (2) the length is included.
: A string debug representation like "[ByteArray 10]". Alternative debug representations are valid too, as long as (1) this method will never fail, (2) the length is included.
; decodeToString()
; decodeToString(charset)
; decodeToString(charset)
: returns a String from its decoded bytes in a given charset.  If no charset is provided, or if the charset is "undefined", assumes the default system encoding.
: returns a String from its decoded bytes in a given charset.
; toByteArray()
; toByteArray()
: just a copy
: just a copy
62

edits

Navigation menu