Packages

  • package root
    Definition Classes
    root
  • package strawman
    Definition Classes
    root
  • package collection

    A strawman architecture for new collections.

    A strawman architecture for new collections. It contains some example collection classes and methods with the intent to expose some key issues. It would be good to compare this to odether implementations of the same functionality, to get an idea of the strengths and weaknesses of different collection architectures.

    For a test file, see tests/run/CollectionTests.scala.

    Strawman6 is like strawman5, and adds lazy lists (i.e. lazie streams), arrays and some utilitity methods (take, tail, mkString, toArray). Also, systematically uses builders for all strict collections.

    Types covered in this strawman:

    1. Collection base types:

    IterableOnce, Iterable, Seq, LinearSeq, View, IndexedView

    2. Collection creator base types:

    FromIterable, IterableFactory, Buildable, Builder

    3. Types that bundle operations:

    IterableOps, IterableMonoTransforms, IterablePolyTransforms, IterableLike SeqMonoTransforms, SeqLike

    4. Concrete collection types:

    List, LazyList, ListBuffer, ArrayBuffer, ArrayBufferView, StringView, ArrayView

    5. Decorators for existing types

    StringOps, ArrayOps

    6. Related non collection types:

    Iterator, StringBuilder

    Operations covered in this strawman:

    1. Abstract operations, or expected to be overridden:

    For iterables:

    iterator, fromIterable, fromIterableWithSameElemType, knownLength, className

    For sequences:

    apply, length

    For buildables:

    newBuilder

    For builders:

    +=, result

    2. Utility methods, might be overridden for performance:

    Operations returning not necessarily a collection:

    foreach, foldLeft, foldRight, indexWhere, isEmpty, head, size, mkString

    Operations returning a collection of a fixed type constructor:

    view, to, toArray, copyToArray

    Type-preserving generic transforms:

    filter, partition, take, drop, tail, reverse

    Generic transforms returning collections of different element types:

    map, flatMap, ++, zip

    Definition Classes
    strawman
  • package mutable
    Definition Classes
    collection
  • ArrayBuffer
  • ArrayBufferView
  • BitSet
  • Buildable
  • Builder
  • Growable
  • GrowableSeq
  • HashMap
  • HashSet
  • IndexedOptimizedGrowableSeq
  • IndexedOptimizedSeq
  • Iterable
  • ListBuffer
  • Map
  • MapLike
  • RefArrayUtils
  • Seq
  • Set
  • SetLike
  • SetMonoTransforms
  • SortedSet
  • SortedSetLike
  • StringBuilder

class StringBuilder extends Builder[Char, String]

Linear Supertypes
Builder[Char, String], Growable[Char], AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. StringBuilder
  2. Builder
  3. Growable
  4. AnyRef
  5. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new StringBuilder()

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. def ++=(s: String): StringBuilder

    Overloaded version of ++= that takes a string

  4. def ++=(xs: IterableOnce[Char]): StringBuilder.this.type

    ${Add}s all elements produced by a TraversableOnce to this $coll.

    ${Add}s all elements produced by a TraversableOnce to this $coll.

    xs

    the TraversableOnce producing the elements to $add.

    returns

    the $coll itself.

    Definition Classes
    Growable
  5. def +=(x: Char): StringBuilder.this.type

    Append an element

    Append an element

    returns

    the $coll itself

    Definition Classes
    StringBuilderBuilderGrowable
  6. def +=(elem1: Char, elem2: Char, elems: Char*): StringBuilder.this.type

    ${Add}s two or more elements to this $coll.

    ${Add}s two or more elements to this $coll.

    elem1

    the first element to $add.

    elem2

    the second element to $add.

    elems

    the remaining elements to $add.

    returns

    the $coll itself

    Definition Classes
    Growable
  7. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  8. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  9. def clear(): Unit

    Clears the contents of this builder.

    Clears the contents of this builder. After execution of this method the builder will contain no elements.

    Definition Classes
    StringBuilderBuilderGrowable
  10. def clone(): AnyRef
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  11. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  12. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  13. def finalize(): Unit
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  14. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
  15. def hashCode(): Int
    Definition Classes
    AnyRef → Any
  16. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  17. def mapResult[NewTo](f: (String) ⇒ NewTo): Builder[Char, NewTo]

    A builder resulting from this builder my mapping the result using f.

    A builder resulting from this builder my mapping the result using f.

    Definition Classes
    Builder
  18. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  19. final def notify(): Unit
    Definition Classes
    AnyRef
  20. final def notifyAll(): Unit
    Definition Classes
    AnyRef
  21. def result: String

    Result collection consisting of all elements appended so far.

    Result collection consisting of all elements appended so far.

    Definition Classes
    StringBuilderBuilder
  22. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  23. def toString(): String
    Definition Classes
    StringBuilder → AnyRef → Any
  24. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  25. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  26. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from Builder[Char, String]

Inherited from Growable[Char]

Inherited from AnyRef

Inherited from Any

Ungrouped