trait AggregationCursor[T] extends Object with Readable
Aggregation Cursor
- Annotations
- @RawJSType() @native()
- Alphabetic
- By Inheritance
- AggregationCursor
- Readable
- IEventEmitter
- Object
- Any
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
_read(size: Int): Unit
- Definition Classes
- Readable
-
def
_readableState: ReadableState
- Definition Classes
- Readable
-
def
addListener(eventName: String, listener: Function): AggregationCursor.this.type
- Definition Classes
- IEventEmitter
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
batchSize(size: Int): AggregationCursor.this.type
Sets the batch size parameter of this cursor to the given value.
Sets the batch size parameter of this cursor to the given value.
- size
the new batch size.
batchSize(batchSize[, callback])
Example: -
def
clone(): AggregationCursor.this.type
Clone the cursor
Clone the cursor
- Definition Classes
- AggregationCursor → AnyRef
-
def
close(callback: MongoCallback1[AggregationCursor.this.type] = js.native): Promise[AggregationCursor.this.type]
Close the cursor, sending a AggregationCursor command and emitting close.
Close the cursor, sending a AggregationCursor command and emitting close.
- callback
this optional callbak will be called after executing this method. The first parameter will always contain null while; The second parameter will contain a reference to this cursor.
-
val
domain: String
- Definition Classes
- IEventEmitter
-
def
each(callback: MongoCallback1[T]): Unit
Iterates over all the documents for this cursor.
Iterates over all the documents for this cursor. As with {cursor.toArray}, not all of the elements will be iterated if this cursor had been previouly accessed. In that case, {cursor.rewind} can be used to reset the cursor. However, unlike {cursor.toArray}, the cursor will only hold a maximum of batch size elements at any given time if batch size is specified. Otherwise, the caller is responsible for making sure that the entire result can fit the memory.
- callback
this will be called for while iterating every document of the query result. The first parameter will contain the Error object if an error occurred, or null otherwise. While the second parameter will contain the document.
-
def
emit(name: String, args: Any*): Any
- Definition Classes
- IEventEmitter
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
explain(callback: MongoCallback1[Any]): Unit
Gets a detailed information about how the query is performed on this cursor and how long it took the database to process it.
Gets a detailed information about how the query is performed on this cursor and how long it took the database to process it.
- callback
this will be called after executing this method. The first parameter will always be null while the second parameter will be an object containing the details.
explain(callback)
Example: -
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
-
def
getMaxListeners(): Int
- Definition Classes
- IEventEmitter
-
def
hasOwnProperty(v: String): Boolean
- Definition Classes
- Object
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
-
def
isClosed(): Boolean
Check if the cursor is closed or open.
Check if the cursor is closed or open.
- returns
the state of the cursor.
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
def
isPaused(): Boolean
- Definition Classes
- Readable
-
def
isPrototypeOf(v: Object): Boolean
- Definition Classes
- Object
-
def
listenerCount(eventName: String): Int
- Definition Classes
- IEventEmitter
-
def
listeners(eventName: String): Array[Function]
- Definition Classes
- IEventEmitter
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
-
def
on(eventName: String, listener: Function): AggregationCursor.this.type
- Definition Classes
- IEventEmitter
-
def
once(eventName: String, listener: Function): AggregationCursor.this.type
- Definition Classes
- IEventEmitter
-
def
pause(): AggregationCursor.this.type
- Definition Classes
- Readable
-
def
pipe(destination: Writable, options: |[ReadablePipeOptions, RawOptions]): AggregationCursor.this.type
- Definition Classes
- Readable
-
def
propertyIsEnumerable(v: String): Boolean
- Definition Classes
- Object
-
def
push(chunk: Buffer): Boolean
- Definition Classes
- Readable
-
def
push(chunk: String, encoding: String): Boolean
- Definition Classes
- Readable
-
def
read[T](size: Int): T
- Definition Classes
- Readable
-
def
removeAllListeners(): AggregationCursor.this.type
- Definition Classes
- IEventEmitter
-
def
removeAllListeners(eventName: String): AggregationCursor.this.type
- Definition Classes
- IEventEmitter
-
def
removeListener(eventName: String, listener: Function): AggregationCursor.this.type
- Definition Classes
- IEventEmitter
-
def
resume(): AggregationCursor.this.type
- Definition Classes
- Readable
-
def
setEncoding(encoding: String): AggregationCursor.this.type
- Definition Classes
- Readable
-
def
setMaxListeners(n: Int): AggregationCursor.this.type
- Definition Classes
- IEventEmitter
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toArray(callback: MongoCallback1[Array[T]] = js.native): Promise[Array[T]]
Returns an array of documents.
Returns an array of documents. The caller is responsible for making sure that there is enough memory to store the results. Note that the array only contain partial results when this cursor had been previouly accessed. In that case, cursor.rewind() can be used to reset the cursor.
- callback
This will be called after executing this method successfully. The first parameter will contain the Error object if an error occurred, or null otherwise. The second parameter will contain an array of BSON deserialized objects as a result of the query.
- returns
a promise of the results
-
def
toLocaleString(): String
- Definition Classes
- Object
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
def
unpipe(destination: Writable): Unit
- Definition Classes
- Readable
-
def
unshift(chunk: Any): Unit
- Definition Classes
- Readable
-
val
usingDomains: Boolean
- Definition Classes
- IEventEmitter
-
def
valueOf(): Any
- Definition Classes
- Object
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
def
wrap(stream: Any): Unit
- Definition Classes
- Readable