mongodb/ methods duplication removal

This commit is contained in:
Hinell
2017-01-08 03:09:50 +03:00
parent 03e2e599c5
commit 1e18f44d5c
-18
View File
@@ -1172,8 +1172,6 @@ export interface Cursor extends Readable {
// http://mongodb.github.io/node-mongodb-native/2.1/api/Cursor.html#next
next(): Promise<CursorResult>;
next(callback: MongoCallback<CursorResult>): void;
//http://mongodb.github.io/node-mongodb-native/2.1/api/Cursor.html#pipe
pipe(destination: Writable, options?: Object): this;
//http://mongodb.github.io/node-mongodb-native/2.1/api/Cursor.html#project
project(value: Object): Cursor;
//http://mongodb.github.io/node-mongodb-native/2.1/api/Cursor.html#read
@@ -1184,8 +1182,6 @@ export interface Cursor extends Readable {
rewind(): void;
// http://mongodb.github.io/node-mongodb-native/2.1/api/Cursor.html#setCursorOption
setCursorOption(field: string, value: Object): Cursor;
//http://mongodb.github.io/node-mongodb-native/2.1/api/Cursor.html#setEncoding
setEncoding(encoding: string): this;
// http://mongodb.github.io/node-mongodb-native/2.1/api/Cursor.html#setReadPreference
setReadPreference(readPreference: string | ReadPreference): Cursor;
// http://mongodb.github.io/node-mongodb-native/2.1/api/Cursor.html#showRecordId
@@ -1201,8 +1197,6 @@ export interface Cursor extends Readable {
// http://mongodb.github.io/node-mongodb-native/2.1/api/Cursor.html#toArray
toArray(): Promise<any[]>;
toArray(callback: MongoCallback<any[]>): void;
//http://mongodb.github.io/node-mongodb-native/2.1/api/Cursor.html#unpipe
unpipe(destination?: Writable): this;
//http://mongodb.github.io/node-mongodb-native/2.1/api/Cursor.html#unshift
unshift(stream: Buffer | string): void;
}
@@ -1260,8 +1254,6 @@ export interface AggregationCursor extends Readable {
next(callback: MongoCallback<AggregationCursorResult>): void;
// http://mongodb.github.io/node-mongodb-native/2.1/api/AggregationCursor.html#out
out(destination: string): AggregationCursor;
//http://mongodb.github.io/node-mongodb-native/2.1/api/AggregationCursor.html#pipe
pipe(destination: Writable, options?: Object): this;
//http://mongodb.github.io/node-mongodb-native/2.1/api/AggregationCursor.html#project
project(document: Object): AggregationCursor;
//http://mongodb.github.io/node-mongodb-native/2.1/api/AggregationCursor.html#read
@@ -1271,16 +1263,12 @@ export interface AggregationCursor extends Readable {
//http://mongodb.github.io/node-mongodb-native/2.1/api/AggregationCursor.html#rewind
rewind(): AggregationCursor;
//http://mongodb.github.io/node-mongodb-native/2.1/api/AggregationCursor.html#setEncoding
setEncoding(encoding: string): this;
// http://mongodb.github.io/node-mongodb-native/2.1/api/AggregationCursor.html#skip
skip(value: number): AggregationCursor;
// http://mongodb.github.io/node-mongodb-native/2.1/api/AggregationCursor.html#sort
sort(document: Object): AggregationCursor;
// http://mongodb.github.io/node-mongodb-native/2.1/api/AggregationCursor.html#toArray
toArray(): Promise<any[]>;
toArray(callback: MongoCallback<any[]>): void;
//http://mongodb.github.io/node-mongodb-native/2.1/api/AggregationCursor.html#unpipe
unpipe(destination?: Writable): this;
//http://mongodb.github.io/node-mongodb-native/2.1/api/AggregationCursor.html#unshift
unshift(stream: Buffer | string): void;
//http://mongodb.github.io/node-mongodb-native/2.1/api/AggregationCursor.html#unwind
@@ -1305,21 +1293,15 @@ export interface CommandCursor extends Readable {
// http://mongodb.github.io/node-mongodb-native/2.1/api/CommandCursor.html#next
next(): Promise<AggregationCursorResult>;
next(callback: MongoCallback<AggregationCursorResult>): void;
//http://mongodb.github.io/node-mongodb-native/2.1/api/CommandCursor.html#pipe
pipe(destination: Writable, options?: Object): this;
//http://mongodb.github.io/node-mongodb-native/2.1/api/CommandCursor.html#read
read(size: number): string | Buffer | void;
//http://mongodb.github.io/node-mongodb-native/2.1/api/CommandCursor.html#rewind
rewind(): CommandCursor;
//http://mongodb.github.io/node-mongodb-native/2.1/api/CommandCursor.html#setEncoding
setEncoding(encoding: string): this;
// http://mongodb.github.io/node-mongodb-native/2.1/api/CommandCursor.html#setReadPreference
setReadPreference(readPreference: string | ReadPreference): CommandCursor;
// http://mongodb.github.io/node-mongodb-native/2.1/api/CommandCursor.html#toArray
toArray(): Promise<any[]>;
toArray(callback: MongoCallback<any[]>): void;
//http://mongodb.github.io/node-mongodb-native/2.1/api/CommandCursor.html#unpipe
unpipe(destination?: Writable): this;
//http://mongodb.github.io/node-mongodb-native/2.1/api/CommandCursor.html#unshift
unshift(stream: Buffer | string): void;
}