EasyMango 1.1.3

dotnet add package EasyMango --version 1.1.3
                    
NuGet\Install-Package EasyMango -Version 1.1.3
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="EasyMango" Version="1.1.3" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="EasyMango" Version="1.1.3" />
                    
Directory.Packages.props
<PackageReference Include="EasyMango" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add EasyMango --version 1.1.3
                    
#r "nuget: EasyMango, 1.1.3"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package EasyMango@1.1.3
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=EasyMango&version=1.1.3
                    
Install as a Cake Addin
#tool nuget:?package=EasyMango&version=1.1.3
                    
Install as a Cake Tool

EasyMango

EasyMango is a simple library that makes working with MongoDB easy

https://www.nuget.org/packages/EasyMango

setting up

instanciate an EasyMango object with the following parameters :
  • connectionString : connection string to MongoDb
  • databaseName : name of your MongoDB batabase
  • collectionName : name of your MongoDB collection

usage

all the following methods return true if they were sucessful and false if a problem occured

- get a single entry from the database

to get a single entry from the database, use the getSingleDatabaseEntry method with the following parameters :
  • field (string) : the field used to search the entry in the database
  • value (any type) : the value of said field
  • out result (BsonDocument) : the result of the search as a BsonDocument
if you wish to get the first result from a sorted array of the search result, you can use the following parameters :
  • field (string) : the field used to search the entry in the database
  • value (any type) : the value of said field
  • sortingOrder (SortingOrder) : the order to sort with, the available orders are : SortingOrder.Default, SortingOrder.Ascending, SortingOrder.Descending
  • sortingField (string) : the field used to sort the results
  • out result (BsonDocument) : the result of the search as a BsonDocument

- get multiple entries from the database

to get multiple entries from the database, use the GetMultipleDatabaseEntries method with the same parameters as the getSingleDatabaseEntry method, but change the last parameter from :

out result (BsonDocument)

to :

out result (List<BsonDocument>)

you can also sort the resulting list, with the same parameters as the getSingleDatabaseEntry method

- replace a single entry in the database

to replace a single entry in the database, use the ReplaceSingleDatabaseEntry method with the following parameters :
  • field (string) : the field used to search the entry in the database
  • value (any type) : the value of said field
  • entry (BsonDocument) : the new entry to replace the retrieved Entry with

- replace mutiple entries in the database

to replace multiple entries in the database, use the ReplaceMultipleDatabaseEntries method with the with the same parameters as the ReplaceSingleDatabaseEntry method. all the entries that have a field equal to the value, will be replaced by the entry

- add a single entry to the database

to add a single entry to the database, use the AddSingleDatabaseEntry method with the following parameter :
  • entry (BsonDocument) : the entry to add to the database

- add multiple entries to the database

to add multiple entries to the database, use the AddSingleDatabaseEntry method with the following parameter :
  • entries (List<BsonDocument>) : the entries to add to the database

- remove a single entry from the datatbase

to remove a single entry from the database, use the RemoveSingleDatabaseEntry method with the following parameters :
  • field (string) : the field used to search the entry in the database
  • value (any type) : the value of said field
to remove multiple entries from the database, use the RemoveMultiplesDatabaseEntries method with the with the same parameters as the RemoveSingleDatabaseEntry method. all the entries that have a field equal to the value, will be removed from the database
Product Compatible and additional computed target framework versions.
.NET net5.0 is compatible.  net5.0-windows was computed.  net6.0 was computed.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

This package has no dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.1.3 581 5/22/2022
1.1.2 523 4/26/2022
1.1.1 494 3/24/2022
1.1.0 494 3/8/2022
1.0.1 501 3/7/2022
1.0.0 488 3/6/2022

updated dependencies