Click or drag to resize

MongoGridFS Class

Represents a GridFS file system.
Inheritance Hierarchy
SystemObject
  MongoDB.Driver.GridFSMongoGridFS

Namespace:  MongoDB.Driver.GridFS
Assembly:  MongoDB.Driver.Legacy (in MongoDB.Driver.Legacy.dll) Version: 2.16.0+eeafbea0921243a5868b81984e1083a07c1f75bc
Syntax
public class MongoGridFS

The MongoGridFS type exposes the following members.

Constructors
  NameDescription
Public methodMongoGridFS(MongoDatabase) Obsolete.
Initializes a new instance of the MongoGridFS class.
Public methodMongoGridFS(MongoDatabase, MongoGridFSSettings) Obsolete.
Initializes a new instance of the MongoGridFS class.
Public methodMongoGridFS(MongoServer, String, MongoGridFSSettings)
Initializes a new instance of the MongoGridFS class.
Top
Properties
  NameDescription
Public propertyChunks
Gets the chunks collection.
Public propertyDatabase
Gets the database containing the GridFS collections.
Public propertyDatabaseName
Gets the database containing the GridFS collections.
Public propertyFiles
Gets the files collection.
Public propertyServer
Gets the server containing the GridFS collections.
Public propertySettings
Gets the GridFS settings.
Top
Methods
  NameDescription
Public methodAppendText
Appends UTF-8 encoded text to an existing GridFS file.
Public methodCopyTo(String, String)
Copies a GridFS file.
Public methodCopyTo(String, String, MongoGridFSCreateOptions)
Copies a GridFS file.
Public methodCreate(String)
Creates or overwrites a GridFS file.
Public methodCreate(String, MongoGridFSCreateOptions)
Creates or overwrites a GridFS file.
Public methodCreateText(String)
Creates or opens a GridFS file for writing UTF-8 encoded text.
Public methodCreateText(String, MongoGridFSCreateOptions)
Creates or opens a GridFS file for writing UTF-8 encoded text.
Public methodDelete(IMongoQuery)
Deletes GridFS files.
Public methodDelete(String)
Deletes all versions of a GridFS file.
Public methodDeleteById
Deletes a GridFS file.
Public methodDownload(String)
Downloads the most recent version of a GridFS file.
Public methodDownload(Stream, MongoGridFSFileInfo)
Downloads a GridFS file.
Public methodDownload(Stream, IMongoQuery)
Downloads the most recent version of a GridFS file.
Public methodDownload(Stream, String)
Downloads the most recent version of a GridFS file.
Public methodDownload(String, MongoGridFSFileInfo)
Downloads a GridFS file.
Public methodDownload(String, IMongoQuery)
Downloads the most recent version of a GridFS file.
Public methodDownload(String, Int32)
Downloads a specific version of a GridFS file.
Public methodDownload(String, String)
Downloads the most recent version of a GridFS file.
Public methodDownload(Stream, IMongoQuery, Int32)
Downloads a specific version of a GridFS file.
Public methodDownload(Stream, String, Int32)
Downloads a specific version of a GridFS file.
Public methodDownload(String, IMongoQuery, Int32)
Downloads a specific version of a GridFS file.
Public methodDownload(String, String, Int32)
Downloads a specific version of a GridFS file.
Public methodEnsureIndexes
Ensures that the proper indexes for GridFS exist (only creates the new indexes if there are fewer than 1000 GridFS files).
Public methodEnsureIndexes(Int32)
Ensures that the proper indexes for GridFS exist.
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Public methodExists(IMongoQuery)
Tests whether a GridFS file exists.
Public methodExists(String)
Tests whether a GridFS file exists.
Public methodExistsById
Tests whether a GridFS file exists.
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodFind(IMongoQuery)
Finds matching GridFS files.
Public methodFind(String)
Finds matching GridFS files.
Public methodFindAll
Finds all GridFS files.
Public methodFindOne(IMongoQuery)
Finds the most recent version of a GridFS file.
Public methodFindOne(String)
Finds the most recent version of a GridFS file.
Public methodFindOne(IMongoQuery, Int32)
Finds a specific version of a GridFS file.
Public methodFindOne(String, Int32)
Finds a specific version of a GridFS file.
Public methodFindOneById
Finds a GridFS file.
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodMoveTo
Moves the most recent version of a GridFS file.
Public methodOpen(String, FileMode)
Opens a GridFS file with the specified mode.
Public methodOpen(String, FileMode, FileAccess)
Opens a GridFS file with the specified mode and access.
Public methodOpen(String, FileMode, FileAccess, MongoGridFSCreateOptions)
Opens a GridFS file with the specified mode, access and create options.
Public methodOpenRead
Opens an existing GridFS file for reading.
Public methodOpenText
Opens an existing UTF-8 encoded text GridFS file for reading.
Public methodOpenWrite(String)
Opens an existing GridFS file for writing.
Public methodOpenWrite(String, MongoGridFSCreateOptions)
Opens an existing GridFS file for writing.
Public methodSetAliases
Sets the aliases for an existing GridFS file.
Public methodSetContentType
Sets the content type for an existing GridFS file.
Public methodSetMetadata
Sets the metadata for an existing GridFS file.
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Public methodUpload(String)
Uploads a GridFS file.
Public methodUpload(Stream, String)
Uploads a GridFS file.
Public methodUpload(String, String)
Uploads a GridFS file.
Public methodUpload(Stream, String, MongoGridFSCreateOptions)
Uploads a GridFS file.
Top
Extension Methods
  NameDescription
Public Extension MethodToBson
Serializes an object to a BSON byte array.
(Defined by BsonExtensionMethods.)
Public Extension MethodToBsonDocument
Serializes an object to a BsonDocument.
(Defined by BsonExtensionMethods.)
Public Extension MethodToJson
Serializes an object to a JSON string.
(Defined by BsonExtensionMethods.)
Top
See Also