public static final class ByteString.ByteStrings extends ByteString implements scala.Serializable
ByteString.ByteString1, ByteString.ByteString1$, ByteString.ByteString1C, ByteString.ByteString1C$, ByteString.ByteStrings, ByteString.ByteStrings$, ByteString.Companion, ByteString.Companion$scala.collection.immutable.IndexedSeq.Impl<A>scala.PartialFunction.AndThen<A,B,C>, scala.PartialFunction.Lifted<A,B>, scala.PartialFunction.OrElse<A,B>, scala.PartialFunction.Unlifted<A,B>scala.collection.IndexedSeqLike.Elementsscala.collection.SeqLike.CombinationsItr, scala.collection.SeqLike.PermutationsItrscala.collection.TraversableLike.WithFilterscala.collection.TraversableOnce.BufferedCanBuildFrom<A,CC extends scala.collection.TraversableOnce<java.lang.Object>>, scala.collection.TraversableOnce.FlattenOps<A>, scala.collection.TraversableOnce.ForceImplicitAmbiguity, scala.collection.TraversableOnce.MonadOps<A>, scala.collection.TraversableOnce.OnceCanBuildFrom<A>| Modifier and Type | Method and Description |
|---|---|
byte |
apply(int idx) |
java.nio.ByteBuffer |
asByteBuffer()
Returns a read-only ByteBuffer that directly wraps this ByteString
if it is not fragmented.
|
scala.collection.immutable.Iterable<java.nio.ByteBuffer> |
asByteBuffers()
Scala API: Returns an immutable Iterable of read-only ByteBuffers that directly wraps this ByteStrings
all fragments.
|
ByteString.ByteStrings$ |
byteStringCompanion() |
scala.collection.immutable.Vector<ByteString.ByteString1> |
bytestrings() |
CompactByteString |
compact()
Create a new ByteString with all contents compacted into a single,
full byte array.
|
int |
copyToBuffer(java.nio.ByteBuffer buffer)
Copy as many bytes as possible to a ByteBuffer, starting from it's
current position.
|
java.lang.String |
decodeString(java.nio.charset.Charset charset)
Decodes this ByteString using a charset to produce a String.
|
java.lang.String |
decodeString(java.lang.String charset)
Decodes this ByteString using a charset to produce a String.
|
ByteString |
drop(int n) |
ByteString |
dropRight(int n) |
<B> int |
indexOf(B elem) |
<B> int |
indexOf(B elem,
int from) |
boolean |
isCompact()
Check whether this ByteString is compact in memory.
|
ByteIterator.MultiByteArrayIterator |
iterator()
Avoid `iterator` in performance sensitive code, call ops directly on ByteString instead
|
int |
length() |
ByteString |
slice(int from,
int until) |
ByteString |
take(int n) |
ByteString |
take0(int n) |
protected java.lang.Object |
writeReplace() |
void |
writeToOutputStream(java.io.ObjectOutputStream os) |
$colon$bslash, $colon$plus, $div$colon, $plus$colon, $plus$plus, $plus$plus$colon, $plus$plus$colon, addString, addString, addString, aggregate, andThen, apply$mcDD$sp, apply$mcDF$sp, apply$mcDI$sp, apply$mcDJ$sp, apply$mcFD$sp, apply$mcFF$sp, apply$mcFI$sp, apply$mcFJ$sp, apply$mcID$sp, apply$mcIF$sp, apply$mcII$sp, apply$mcIJ$sp, apply$mcJD$sp, apply$mcJF$sp, apply$mcJI$sp, apply$mcJJ$sp, apply$mcVD$sp, apply$mcVF$sp, apply$mcVI$sp, apply$mcVJ$sp, apply$mcZD$sp, apply$mcZF$sp, apply$mcZI$sp, apply$mcZJ$sp, applyOrElse, canBuildFrom, canEqual, collect, collectFirst, combinations, companion, compose, concat, contains, containsSlice, copyToArray, corresponds, count, createBuilder, diff, distinct, dropWhile, empty, endsWith, equals, exists, filter, filterImpl, filterNot, find, flatMap, flatten, fold, foldLeft, foldRight, forall, foreach, fromArray, fromArray, fromByteBuffer, fromInts, fromInts, fromString, fromString, genericBuilder, getByteBuffers, groupBy, grouped, hasDefiniteSize, hashCode, head, headOption, indexOfSlice, indexOfSlice, indexWhere, indices, init, inits, intersect, isDefinedAt, isEmpty, isTraversableAgain, last, lastIndexOf, lastIndexOf, lastIndexOfSlice, lastIndexOfSlice, lastIndexWhere, lastIndexWhere, lastOption, lengthCompare, lift, map, mapI, max, maxBy, min, minBy, mkString, mkString, mkString, newBuilder, nonEmpty, orElse, padTo, par, parCombiner, partition, patch, permutations, prefixLength, product, reduce, reduceLeft, reduceLeftOption, reduceOption, reduceRight, reduceRightOption, repr, reverse, reversed, reverseIterator, reverseMap, runWith, sameElements, scan, scanLeft, scanRight, segmentLength, seq, size, sizeHintIfCheap, sliceWithKnownBound, sliceWithKnownDelta, sliding, sliding, sortBy, sorted, sortWith, span, splitAt, startsWith, startsWith, stringPrefix, sum, tail, tails, takeRight, takeWhile, thisCollection, to, toArray, toArray, toBuffer, toByteBuffer, toCollection, toIndexedSeq, toIterable, toIterator, toList, toMap, toSeq, toSet, toStream, toString, toTraversable, toVector, transpose, union, unzip, unzip3, updated, UTF_8, utf8String, view, view, withFilter, zip, zipAll, zipWithIndexclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait$init$, companion, concat, fill, fill, fill, fill, fill, iterate, range, range, ReusableCBF, seq, tabulate, tabulate, tabulate, tabulate, tabulate, toIndexedSeq, unapplySeq$init$, andThen, applyOrElse, cond, condOpt, isDefinedAt, lift, orElse, runWith$init$, apply, apply$mcDD$sp, apply$mcDF$sp, apply$mcDI$sp, apply$mcDJ$sp, apply$mcFD$sp, apply$mcFF$sp, apply$mcFI$sp, apply$mcFJ$sp, apply$mcID$sp, apply$mcIF$sp, apply$mcII$sp, apply$mcIJ$sp, apply$mcJD$sp, apply$mcJF$sp, apply$mcJI$sp, apply$mcJJ$sp, apply$mcVD$sp, apply$mcVF$sp, apply$mcVI$sp, apply$mcVJ$sp, apply$mcZD$sp, apply$mcZF$sp, apply$mcZI$sp, apply$mcZJ$sp, compose$init$, apply, concat, fill, fill, fill, fill, fill, iterate, range, range, tabulate, tabulate, tabulate, tabulate, tabulate$init$, flatten, genericBuilder, isEmpty, transpose, unzip, unzip3$init$, hashCode, sizeHintIfCheap, thisCollection, toBuffer, toCollection$colon$plus, $init$, $plus$colon, combinations, contains, containsSlice, corresponds, diff, distinct, endsWith, indexOfSlice, indexOfSlice, indexWhere, indices, intersect, isEmpty, lastIndexOfSlice, lastIndexOfSlice, lastIndexWhere, lengthCompare, padTo, patch, permutations, reverse, reverseIterator, reverseMap, segmentLength, size, sortBy, sorted, sortWith, startsWith, union, updated, view, view$init$, canEqual, exists, find, foldRight, forall, grouped, reduceRight, sameElements, sliding, sliding, toIterable, toIterator, toStream, zip, zipAll, zipWithIndex$init$, $plus$plus, $plus$plus$colon, $plus$plus$colon, collect, filter, filterImpl, filterNot, flatMap, groupBy, hasDefiniteSize, headOption, inits, isTraversableAgain, lastOption, map, partition, repr, scan, scanLeft, scanRight, sliceWithKnownBound, sliceWithKnownDelta, tails, to, toTraversable, withFilter$colon$bslash, $div$colon, $init$, addString, addString, addString, aggregate, alternateImplicit, collectFirst, copyToArray, copyToArray, copyToBuffer, count, flattenTraversableOnce, fold, foldLeft, max, maxBy, min, minBy, mkString, mkString, mkString, MonadOps, nonEmpty, OnceCanBuildFrom, product, reduce, reduceLeft, reduceLeftOption, reduceOption, reduceRightOption, reversed, sum, toList, toMap, toSet, toVectorpublic scala.collection.immutable.Vector<ByteString.ByteString1> bytestrings()
public int length()
length in interface scala.collection.GenSeqLike<java.lang.Object,ByteString>length in interface scala.collection.SeqLike<java.lang.Object,ByteString>length in class ByteStringpublic byte apply(int idx)
apply in interface scala.collection.GenSeqLike<java.lang.Object,ByteString>apply in interface scala.collection.SeqLike<java.lang.Object,ByteString>apply in class ByteStringpublic ByteIterator.MultiByteArrayIterator iterator()
iterator in interface scala.collection.GenIterableLike<java.lang.Object,ByteString>iterator in interface scala.collection.IndexedSeqLike<java.lang.Object,ByteString>iterator in interface scala.collection.IterableLike<java.lang.Object,ByteString>iterator in class ByteStringpublic ByteString.ByteStrings$ byteStringCompanion()
byteStringCompanion in class ByteStringpublic boolean isCompact()
ByteStringisCompact in class ByteStringpublic int copyToBuffer(java.nio.ByteBuffer buffer)
ByteStringcopyToBuffer in class ByteStringbuffer - a ByteBuffer to copy bytes topublic CompactByteString compact()
ByteStringcompact in class ByteStringpublic java.nio.ByteBuffer asByteBuffer()
ByteStringasByteBuffer in class ByteStringpublic scala.collection.immutable.Iterable<java.nio.ByteBuffer> asByteBuffers()
ByteStringasByteBuffers in class ByteStringpublic java.lang.String decodeString(java.lang.String charset)
ByteStringCharset instance available, use decodeString(charset: java.nio.charset.Charset instead.decodeString in class ByteStringcharset - (undocumented)public java.lang.String decodeString(java.nio.charset.Charset charset)
ByteStringdecodeString(charset: String).decodeString in class ByteStringcharset - (undocumented)public void writeToOutputStream(java.io.ObjectOutputStream os)
writeToOutputStream in class ByteStringpublic ByteString take(int n)
take in interface scala.collection.GenTraversableLike<java.lang.Object,ByteString>take in interface scala.collection.IndexedSeqOptimized<java.lang.Object,ByteString>take in interface scala.collection.IterableLike<java.lang.Object,ByteString>take in interface scala.collection.TraversableLike<java.lang.Object,ByteString>take in class ByteStringpublic ByteString take0(int n)
public ByteString dropRight(int n)
dropRight in interface scala.collection.IndexedSeqOptimized<java.lang.Object,ByteString>dropRight in interface scala.collection.IterableLike<java.lang.Object,ByteString>dropRight in class ByteStringpublic ByteString slice(int from, int until)
slice in interface scala.collection.GenTraversableLike<java.lang.Object,ByteString>slice in interface scala.collection.IndexedSeqOptimized<java.lang.Object,ByteString>slice in interface scala.collection.IterableLike<java.lang.Object,ByteString>slice in interface scala.collection.TraversableLike<java.lang.Object,ByteString>slice in class ByteStringpublic ByteString drop(int n)
drop in interface scala.collection.GenTraversableLike<java.lang.Object,ByteString>drop in interface scala.collection.IndexedSeqOptimized<java.lang.Object,ByteString>drop in interface scala.collection.IterableLike<java.lang.Object,ByteString>drop in interface scala.collection.TraversableLike<java.lang.Object,ByteString>drop in class ByteStringpublic <B> int indexOf(B elem)
indexOf in interface scala.collection.GenSeqLike<java.lang.Object,ByteString>indexOf in class ByteStringpublic <B> int indexOf(B elem,
int from)
indexOf in interface scala.collection.GenSeqLike<java.lang.Object,ByteString>protected java.lang.Object writeReplace()