Class/Object

reactivemongo.bson

BSONArray

Related Docs: object BSONArray | package bson

Permalink

case class BSONArray(stream: Stream[Try[BSONValue]]) extends BSONValue with BSONElementSet with Product with Serializable

A BSONArray structure (BSON type 0x04).

A BSONArray is a straightforward BSONDocument where keys are a sequence of positive integers.

A BSONArray is basically a stream of tuples (String, BSONValue) where the first member is a string representation of an index. It is completely lazy. The stream it wraps is a Stream[Try[(String, BSONValue)]] since we cannot be sure that a not yet deserialized value will be processed without error.

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. BSONArray
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. BSONElementSet
  7. ElementProducer
  8. Producer
  9. BSONValue
  10. AnyRef
  11. Any
Implicitly
  1. by ExtendedBSONValue
  2. by valueProducer
  3. by any2stringadd
  4. by StringFormat
  5. by Ensuring
  6. by ArrowAssoc
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new BSONArray(stream: Stream[Try[BSONValue]])

    Permalink

Type Members

  1. type SetType = BSONArray

    Permalink
    Definition Classes
    BSONArrayBSONElementSet

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. def +(other: String): String

    Permalink
    Implicit information
    This member is added by an implicit conversion from BSONArray to any2stringadd[BSONArray] performed by method any2stringadd in scala.Predef.
    Definition Classes
    any2stringadd
  4. def ++(values: Producer[BSONValue]*): BSONArray

    Permalink

    Alias for add

  5. def ++(array: BSONArray): BSONArray

    Permalink

    Alias for the corresponding merge

    Alias for the corresponding merge

    Annotations
    @inline()
  6. def +:(value: Producer[BSONValue]): BSONArray

    Permalink

    Alias for BSONArray.prepend

  7. def ->[B](y: B): (BSONArray, B)

    Permalink
    Implicit information
    This member is added by an implicit conversion from BSONArray to ArrowAssoc[BSONArray] performed by method ArrowAssoc in scala.Predef.
    Definition Classes
    ArrowAssoc
    Annotations
    @inline()
  8. def :~(elements: Producer[BSONElement]*): BSONArray

    Permalink

    The name of the produced elements are ignored, instead the indexes are used.

    The name of the produced elements are ignored, instead the indexes are used.

    Definition Classes
    BSONArrayBSONElementSet
  9. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  10. def add(values: Producer[BSONValue]*): BSONArray

    Permalink

    Alias for merge.

  11. def as[T](implicit reader: BSONReader[BSONArray, T]): T

    Permalink
    Implicit information
    This member is added by an implicit conversion from BSONArray to ExtendedBSONValue[BSONArray] performed by method ExtendedBSONValue in reactivemongo.bson.BSONValue.
    Definition Classes
    ExtendedBSONValue
  12. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  13. def asOpt[T](implicit reader: BSONReader[BSONArray, T]): Option[T]

    Permalink
    Implicit information
    This member is added by an implicit conversion from BSONArray to ExtendedBSONValue[BSONArray] performed by method ExtendedBSONValue in reactivemongo.bson.BSONValue.
    Definition Classes
    ExtendedBSONValue
  14. def asTry[T](implicit reader: BSONReader[BSONArray, T]): Try[T]

    Permalink
    Implicit information
    This member is added by an implicit conversion from BSONArray to ExtendedBSONValue[BSONArray] performed by method ExtendedBSONValue in reactivemongo.bson.BSONValue.
    Definition Classes
    ExtendedBSONValue
  15. val bson: BSONArray

    Permalink
    Implicit information
    This member is added by an implicit conversion from BSONArray to ExtendedBSONValue[BSONArray] performed by method ExtendedBSONValue in reactivemongo.bson.BSONValue.
    Definition Classes
    ExtendedBSONValue
  16. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  17. val code: Byte

    Permalink

    The code indicating the BSON type for this value

    The code indicating the BSON type for this value

    Definition Classes
    BSONArrayBSONValue
  18. def contains(name: String): Boolean

    Permalink

    Returns true if the given name corresponds to a valid index.

    Returns true if the given name corresponds to a valid index.

    returns

    true if the key is found

    Definition Classes
    BSONArrayBSONElementSet
  19. def elements: List[BSONElement]

    Permalink

    Returns a list for the values as BSONElements, with their indexes as names (e.g.

    Returns a list for the values as BSONElements, with their indexes as names (e.g. "0" for the first).

    Definition Classes
    BSONArrayBSONElementSet
  20. def ensuring(cond: (BSONArray) ⇒ Boolean, msg: ⇒ Any): BSONArray

    Permalink
    Implicit information
    This member is added by an implicit conversion from BSONArray to Ensuring[BSONArray] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  21. def ensuring(cond: (BSONArray) ⇒ Boolean): BSONArray

    Permalink
    Implicit information
    This member is added by an implicit conversion from BSONArray to Ensuring[BSONArray] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  22. def ensuring(cond: Boolean, msg: ⇒ Any): BSONArray

    Permalink
    Implicit information
    This member is added by an implicit conversion from BSONArray to Ensuring[BSONArray] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  23. def ensuring(cond: Boolean): BSONArray

    Permalink
    Implicit information
    This member is added by an implicit conversion from BSONArray to Ensuring[BSONArray] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  24. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  25. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  26. def formatted(fmtstr: String): String

    Permalink
    Implicit information
    This member is added by an implicit conversion from BSONArray to StringFormat[BSONArray] performed by method StringFormat in scala.Predef.
    Definition Classes
    StringFormat
    Annotations
    @inline()
  27. def get(name: String): Option[BSONValue]

    Permalink

    Returns the BSONValue matching the given name, provided it is a valid string representation of a valid index.

    Returns the BSONValue matching the given name, provided it is a valid string representation of a valid index.

    Definition Classes
    BSONArrayBSONElementSet
  28. def get(index: Int): Option[BSONValue]

    Permalink

    Returns the BSONValue at the given index.

    Returns the BSONValue at the given index.

    If there is no such index or the matching value cannot be deserialized, returns None.

  29. def getAs[T](index: Int)(implicit reader: BSONReader[_ <: BSONValue, T]): Option[T]

    Permalink

    Gets the BSONValue at the given index, and converts it with the given implicit BSONReader.

    Gets the BSONValue at the given index, and converts it with the given implicit BSONReader.

    If there is no matching value, or the value could not be deserialized or converted, returns a None.

  30. def getAsTry[T](index: Int)(implicit reader: BSONReader[_ <: BSONValue, T]): Try[T]

    Permalink

    Gets the BSONValue at the given index, and converts it with the given implicit BSONReader.

    Gets the BSONValue at the given index, and converts it with the given implicit BSONReader.

    If there is no matching value, or the value could not be deserialized or converted, returns a Failure. The Failure holds a exceptions.DocumentKeyNotFound if the key could not be found.

  31. def getAsUnflattenedTry[T](index: Int)(implicit reader: BSONReader[_ <: BSONValue, T]): Try[Option[T]]

    Permalink

    Gets the BSONValue at the given index, and converts it with the given implicit BSONReader.

    Gets the BSONValue at the given index, and converts it with the given implicit BSONReader.

    If there is no matching value, returns a Success holding None. If the value could not be deserialized or converted, returns a Failure.

  32. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  33. def getTry(index: Int): Try[BSONValue]

    Permalink

    Returns the BSONValue at the given index.

    Returns the BSONValue at the given index.

    If there is no such index or the matching value cannot be deserialized, returns a Failure. The Failure holds a exceptions.DocumentKeyNotFound if the key could not be found.

  34. def getUnflattenedTry(index: Int): Try[Option[BSONValue]]

    Permalink

    Returns the BSONValue at the given index.

    Returns the BSONValue at the given index.

    If there is no such index, the resulting option will be None. If the matching value could not be deserialized, returns a Failure.

  35. def headOption: Option[BSONElement]

    Permalink

    The first/mandatory nested element, if any

    The first/mandatory nested element, if any

    Definition Classes
    BSONArrayBSONElementSet
  36. def isEmpty: Boolean

    Permalink

    Indicates whether this element set is empty

    Indicates whether this element set is empty

    Definition Classes
    BSONArrayBSONElementSet
    Annotations
    @inline()
  37. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  38. def merge(values: Producer[BSONValue]*): BSONArray

    Permalink

    Creates a new BSONArray containing all the elements of this one and the given elements.

  39. def merge(doc: BSONArray): BSONArray

    Permalink

    Creates a new BSONArray containing all the elements of this one and the elements of the given document.

  40. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  41. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  42. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  43. def prepend(value: Producer[BSONValue]): BSONArray

    Permalink

    Returns a BSONArray with the given value prepended to its elements.

  44. def seeAsOpt[T](implicit reader: BSONReader[_ <: BSONValue, T]): Option[T]

    Permalink
    Implicit information
    This member is added by an implicit conversion from BSONArray to ExtendedBSONValue[BSONArray] performed by method ExtendedBSONValue in reactivemongo.bson.BSONValue.
    Definition Classes
    ExtendedBSONValue
  45. def seeAsTry[T](implicit reader: BSONReader[_ <: BSONValue, T]): Try[T]

    Permalink
    Implicit information
    This member is added by an implicit conversion from BSONArray to ExtendedBSONValue[BSONArray] performed by method ExtendedBSONValue in reactivemongo.bson.BSONValue.
    Definition Classes
    ExtendedBSONValue
  46. def size: Int

    Permalink

    The number of elements

    The number of elements

    Definition Classes
    BSONArrayBSONElementSet
    Annotations
    @inline()
  47. val stream: Stream[Try[BSONValue]]

    Permalink
  48. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  49. def toMap: Map[String, BSONValue]

    Permalink

    Returns a Map representation for this element set.

    Returns a Map representation for this element set.

    Definition Classes
    BSONElementSet
  50. def toString(): String

    Permalink
    Definition Classes
    BSONArray → AnyRef → Any
  51. def values: Stream[BSONValue]

    Permalink

    Returns the values for the nested elements.

    Returns the values for the nested elements.

    Definition Classes
    BSONArrayBSONElementSet
  52. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  53. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  54. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  55. def ~:(elements: Producer[BSONElement]): BSONArray

    Permalink

    Merge the produced elements at the beginning of this set

    Merge the produced elements at the beginning of this set

    Definition Classes
    BSONArrayBSONElementSet
  56. def [B](y: B): (BSONArray, B)

    Permalink
    Implicit information
    This member is added by an implicit conversion from BSONArray to ArrowAssoc[BSONArray] performed by method ArrowAssoc in scala.Predef.
    Definition Classes
    ArrowAssoc

Deprecated Value Members

  1. def add(doc: BSONArray): BSONArray

    Permalink

    Alias for merge.

    Alias for merge.

    Annotations
    @deprecated
    Deprecated

    (Since version 0.12.0) Use the corresponding merge

  2. def iterator: Iterator[Try[(String, BSONValue)]]

    Permalink

    Returns an iterator for the values as elements, with their indexes as names (e.g.

    Returns an iterator for the values as elements, with their indexes as names (e.g. "0" for the first).

    Annotations
    @deprecated
    Deprecated

    (Since version 0.12.0) Use elements

  3. def length: Int

    Permalink
    Annotations
    @deprecated
    Deprecated

    (Since version 0.12.0) Use size

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from BSONElementSet

Inherited from ElementProducer

Inherited from Producer[BSONElement]

Inherited from BSONValue

Inherited from AnyRef

Inherited from Any

Inherited by implicit conversion ExtendedBSONValue from BSONArray to ExtendedBSONValue[BSONArray]

Inherited by implicit conversion valueProducer from BSONArray to Producer[BSONValue]

Inherited by implicit conversion any2stringadd from BSONArray to any2stringadd[BSONArray]

Inherited by implicit conversion StringFormat from BSONArray to StringFormat[BSONArray]

Inherited by implicit conversion Ensuring from BSONArray to Ensuring[BSONArray]

Inherited by implicit conversion ArrowAssoc from BSONArray to ArrowAssoc[BSONArray]

Ungrouped