BlackHole.Core.ORM 6.0.0

There is a newer version of this package available.
See the version list below for details.
dotnet add package BlackHole.Core.ORM --version 6.0.0
NuGet\Install-Package BlackHole.Core.ORM -Version 6.0.0
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="BlackHole.Core.ORM" Version="6.0.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add BlackHole.Core.ORM --version 6.0.0
#r "nuget: BlackHole.Core.ORM, 6.0.0"
#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.
// Install BlackHole.Core.ORM as a Cake Addin
#addin nuget:?package=BlackHole.Core.ORM&version=6.0.0

// Install BlackHole.Core.ORM as a Cake Tool
#tool nuget:?package=BlackHole.Core.ORM&version=6.0.0

BlackHole-Core-ORM

A fully automated, very easy to use and setup, with many new features, Object Relational Mapping Library, for .Net Core 6 and 7. Using Custom Data Providers that are 3x times faster than EF Core and Dapper. Many interfaces for easy Reading and Writing Data. Extention Methods for Joining any tables. It Supports SQL SERVER, MYSQL, POSTGRESQL, ORACLE and SQLITE.

6.0.0 is released.

Changes:

  • Replaced Dapper with Custom Mappers that are 3 times faster

  • Added more Methods to the BHDataProvider

  • Added IBHConnection Interface for custom commands.

  • Improved Configuration made it simpler with more options

  • Added Logs Cleaner to automatically clean up the logs that are aged more than x days.

  • Added Support for Oracle Database

  • Added developer mode that allows dropping columns and constraints on entity changes. But when it's set to false, protects the production database from data loss, by disabling columns dropping. And instead it makes them nullable, if the property of the entity has been deleted.

  • Added BHParameters for custom queries and commands.

  • Improved transaction adding RoleBack option and performing automatic Rollback if the transaction fails.

  • Added configuration option to load Entities and Services from selected Namespaces or Other Assemblies. This way you can make your Apps transform into different App, depending on the configuration.

  • Code clean up and redesign. Organized namespaces better for more efficiency. The user now has all the configuration Items into 'BlackHole.Configuration' namespace. All the Functionalities into 'BlackHole.Core' namespace. And all the Attributes for the entities into the 'BlackHole.Entities' namespace.

*note BlackHole can Not install oracle database to your system. You need to have an instance installed and BlackHole can only create or drop tables in this type of database.

Example: -Find an Example Project here ⇒ BlackHole Example

Quick Start:

  • In Your project install Black.Hole.ORM from nuget

  • In your Program.cs add 'using BlackHole.Configuration' Add the following line into your IServiceCollection ⇒ services.SuperNova(settings ⇒ settings.IsDeveloperMode(devmode == "dev").AddDatabase(connection ⇒ connection.UseOracle(connectionString)))

  • Create some Entities in any folder that Inherit from the class 'BlackHoleEntity<int>' for Entities that are using Integer as Id, or 'BlackHoleEntity<Guid>' for Entities that are using Guid as Id or 'BlackHoleEntity<string>' for Entities that are using SHA1 hash as Id. (using BlackHole.Entities)

  • Add properties on your Entities except the Id property that already exists in the BlackHoleEntity class.

  • Add Attributes to the properties of your Entities' '[ForeignKey(typeof(Entity), nullability)]' , '[NotNullable]' and '[VarCharSize(int)]'

    • You can also use '[UseActivator]' attribute on your Entity, to take advantage of the 'IsActive' column in case you need to keep the data after delete.
  • Make your services Inherit from 'BlackHoleScoped' or 'BlackHoleSingleton' or 'BlackHoleTransient' so they will be automatically registered on the Startup without needing services.Add(<>). (using BlackHole.Services)

  • Last step , go to your services or your controllers and add the Interfaces for the DataProviders ⇒ private readonly IBHDataProvider<Entity,IdType> _entityService; Example: IBHDataProvider<Customer,Guid> _customerService; (using BlackHole.Core)

  • For custom queries and commands, use the IBHConnection Interface that is already Injected with Dependency Injection.

  • Done! You are ready to use all the functionality of the Data Providers in your services.

  • there are descriptions on the methods of what they do

  • The Ids are created automatically on Insert and they get returned.

  • The cascade on Foreign keys is automatic and it depends on the Nullability of the column

I will soon upload here a more detailed guide of all the functionalities of this ORM, such as Stored Views and Joins and automatic mapping on DTOs or Updating Specific Columns.

Product Compatible and additional computed target framework versions.
.NET net6.0 is compatible.  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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

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
8.1.0-rc.2 183 10/31/2023
8.1.0-rc 45 9/26/2023
7.1.2 465 10/31/2023
7.1.1 328 9/26/2023
6.1.2 322 10/31/2023
6.1.1 322 9/26/2023
6.0.3 377 7/16/2023
6.0.2 382 7/8/2023
6.0.1 339 6/29/2023
6.0.0 391 4/20/2023

-Replaced Dapper with Custom Mappers that are 3 times faster
-Added more Methods to the BHDataProvider
-Added IBHConnection Interface for custom commands.
-Improved Configuration made it simpler with more options
-Added Logs Cleaner to automatically clean up the logs that are aged more than x days.
-Added Support for Oracle Database
-Added developer mode that allows dropping columns and constraints on entity changes. But when it's set to false, protects the production database from data loss, by disabling columns dropping. And instead it makes them nullable, if the property of the entity has been deleted.
-Added BHParameters for custom queries and commands.
-Improved transaction adding RoleBack option and performing automatic Rollback if the transaction fails.
-Added configuration option to load Entities and Services from selected Namespaces or Other Assemblies. This way you can make your Apps transform into different App, depending on the configuration.
-Code clean up and redesign. Organized namespaces better for more efficiency. The user now has all the configuration Items into 'BlackHole.Configuration' namespace. All the Functionalities into 'BlackHole.Core' namespace. And all the Attributes for the entities into the 'BlackHole.Entities' namespace.