net.fehmicansaglam.tepkin

MongoCollection

Related Doc: package tepkin

class MongoCollection extends AnyRef

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. MongoCollection
  2. AnyRef
  3. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new MongoCollection(databaseName: String, collectionName: String, pool: ActorRef)

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 aggregate(pipeline: List[BsonDocument], explain: Option[Boolean] = None, allowDiskUse: Option[Boolean] = None, cursor: Option[BsonDocument] = None, batchMultiplier: Int = 1000)(implicit ec: ExecutionContext, timeout: Timeout): Future[Source[List[BsonDocument], ActorRef]]

    Calculates aggregate values for the data in this collection.

    Calculates aggregate values for the data in this collection.

    pipeline

    A sequence of data aggregation operations or stages.

    explain

    Specifies to return the information on the processing of the pipeline.

    allowDiskUse

    Enables writing to temporary files. When set to true, aggregation operations can write data to the _tmp subdirectory in the dbPath directory.

    cursor

    Specifies the initial batch size for the cursor. The value of the cursor field is a document with the field batchSize.

  5. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  6. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  7. def count(query: Option[BsonDocument] = None, limit: Option[Int] = None, skip: Option[Int] = None)(implicit ec: ExecutionContext, timeout: Timeout): Future[CountResult]

    Counts the number of documents in this collection.

    Counts the number of documents in this collection.

    query

    A query that selects which documents to count in a collection.

    limit

    The maximum number of matching documents to return.

    skip

    The number of matching documents to skip before returning results.

  8. def createIndexes(indexes: Index*)(implicit ec: ExecutionContext, timeout: Timeout): Future[CreateIndexesResult]

    Creates indexes on this collection.

  9. def delete(query: BsonDocument, justOne: Boolean = false, writeConcern: Option[WriteConcern] = None)(implicit ec: ExecutionContext, timeout: Timeout): Future[DeleteResult]

    Removes documents from a collection.

    Removes documents from a collection.

    query

    Specifies deletion criteria using query operators. To delete all documents in a collection, pass an empty document ({}).

    justOne

    To limit the deletion to just one document, set to true. Omit to use the default value of false and delete all documents matching the deletion criteria.

    writeConcern

    A document expressing the write concern. Omit to use the default write concern.

    returns

    A WriteResult object that contains the status of the operation.

  10. def distinct(field: String, query: Option[BsonDocument] = None)(implicit ec: ExecutionContext, timeout: Timeout): Future[DistinctResult]

    Finds the distinct values for a specified field across a single collection and returns the results in an array.

    Finds the distinct values for a specified field across a single collection and returns the results in an array.

    field

    The field for which to return distinct values.

    query

    A query that specifies the documents from which to retrieve the distinct values.

  11. def drop()(implicit ec: ExecutionContext, timeout: Timeout): Future[Reply]

    Drops this collection

  12. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  13. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  14. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  15. def find(query: BsonDocument, fields: Option[BsonDocument] = None, skip: Int = 0, batchMultiplier: Int = 1000)(implicit ec: ExecutionContext, timeout: Timeout): Future[Source[List[BsonDocument], ActorRef]]

    Selects documents in this collection.

    Selects documents in this collection.

    query

    Specifies selection criteria using query operators. To return all documents in a collection, pass an empty document ({}).

    fields

    Specifies the fields to return using projection operators. To return all fields in the matching document, omit this parameter.

  16. def findAndRemove(query: Option[BsonDocument] = None, sort: Option[BsonDocument] = None, fields: Option[Seq[String]] = None)(implicit ec: ExecutionContext, timeout: Timeout): Future[Option[BsonDocument]]

    Removes and returns a single document.

    Removes and returns a single document.

    query

    The selection criteria for the remove.

    sort

    Determines which model the operation removes if the query selects multiple models. findAndRemove() removes the first model in the sort order specified by this argument.

    fields

    A subset of fields to return.

  17. def findAndUpdate(query: Option[BsonDocument] = None, sort: Option[BsonDocument] = None, update: BsonDocument, returnNew: Boolean = false, fields: Option[Seq[String]] = None, upsert: Boolean = false)(implicit ec: ExecutionContext, timeout: Timeout): Future[Option[BsonDocument]]

    Updates and returns a single document.

    Updates and returns a single document. It returns the old document by default.

    query

    The selection criteria for the update.

    sort

    Determines which model the operation updates if the query selects multiple models. findAndUpdate() updates the first model in the sort order specified by this argument.

    update

    Performs an update of the selected model.

    returnNew

    When true, returns the updated model rather than the original.

    fields

    A subset of fields to return.

    upsert

    When true, findAndUpdate() creates a new model if no model matches the query.

  18. def findOne(query: BsonDocument = BsonDocument.empty, skip: Int = 0)(implicit ec: ExecutionContext, timeout: Timeout): Future[Option[BsonDocument]]

    Retrieves at most one document matching the given selector.

  19. def findRandom(query: Option[BsonDocument] = None)(implicit ec: ExecutionContext, timeout: Timeout): Future[Option[BsonDocument]]

    Retrieves a random document matching the given selector.

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

    Definition Classes
    AnyRef → Any
  21. def getIndexes()(implicit ec: ExecutionContext, timeout: Timeout): Future[List[Index]]

    Returns a list of documents that identify and describe the existing indexes on this collection.

  22. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  23. def insert(documents: Seq[BsonDocument], ordered: Option[Boolean] = None, writeConcern: Option[WriteConcern] = None)(implicit ec: ExecutionContext, timeout: Timeout): Future[InsertResult]

    Inserts documents into a collection.

    Inserts documents into a collection.

    documents

    A sequence of documents to insert into the collection.

    ordered

    If true, perform an ordered insert of the documents in the array, and if an error occurs with one of documents, MongoDB will return without processing the remaining documents in the array. If false, perform an unordered insert, and if an error occurs with one of documents, continue processing the remaining documents in the array.

    writeConcern

    A document expressing the write concern.

  24. def insert(document: BsonDocument, writeConcern: WriteConcern)(implicit ec: ExecutionContext, timeout: Timeout): Future[InsertResult]

    Inserts document into this collection.

    Inserts document into this collection.

    document

    document to insert into the collection.

  25. def insert(document: BsonDocument)(implicit ec: ExecutionContext, timeout: Timeout): Future[InsertResult]

    Inserts document into this collection.

    Inserts document into this collection.

    document

    document to insert into the collection.

  26. def insertFromSource[M](source: Source[List[BsonDocument], M], ordered: Option[Boolean] = None, writeConcern: Option[WriteConcern] = None)(implicit ec: ExecutionContext, timeout: Timeout): Source[InsertResult, M]

    Inserts documents into a collection.

    Inserts documents into a collection.

    source

    A source of documents to insert into the collection.

    ordered

    If true, perform an ordered insert of the documents in the array, and if an error occurs with one of documents, MongoDB will return without processing the remaining documents in the array. If false, perform an unordered insert, and if an error occurs with one of documents, continue processing the remaining documents in the array.

    writeConcern

    A document expressing the write concern.

  27. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  28. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  29. final def notify(): Unit

    Definition Classes
    AnyRef
  30. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  31. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  32. def toString(): String

    Definition Classes
    AnyRef → Any
  33. def update(query: BsonDocument, update: BsonDocument, upsert: Option[Boolean] = None, multi: Option[Boolean] = None, writeConcern: Option[WriteConcern] = None)(implicit ec: ExecutionContext, timeout: Timeout): Future[UpdateResult]

    Modifies an existing document or documents in a collection.

    Modifies an existing document or documents in a collection. The method can modify specific fields of an existing document or documents or replace an existing document entirely, depending on the update parameter.

    query

    The selection criteria for the update. Use the same query selectors as used in the find() method.

    update

    The modifications to apply.

    upsert

    If set to true, creates a new document when no document matches the query criteria. The default value is false, which does not insert a new document when no match is found.

    multi

    If set to true, updates multiple documents that meet the query criteria. If set to false, updates one document. The default value is false.

    writeConcern

    A document expressing the write concern.

  34. def validate(full: Option[Boolean] = None, scandata: Option[Boolean] = None)(implicit ec: ExecutionContext, timeout: Timeout): Future[BsonDocument]

    Validates a collection.

    Validates a collection. The method scans a collection’s data structures for correctness and returns a single document that describes the relationship between the logical collection and the physical representation of the data.

    full

    Specify true to enable a full validation and to return full statistics. MongoDB disables full validation by default because it is a potentially resource-intensive operation.

    scandata

    if false skips the scan of the base collection without skipping the scan of the index.

  35. final def wait(): Unit

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

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

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from AnyRef

Inherited from Any

Ungrouped