This project has moved. For the latest updates, please go here.
Project Description
Dynamic Entities ORM

Entity Hidroxide (EntityOH)

Basically this library is an ORM tool for .net framework applications
The chemical name was invented to express that the library act as an Alkali that can balance your application very fast and let you finish your project without messing with your code or refactoring it again.
The usage of the library is very straight forward .. moreover you only have to reference one dll.
The syntax is very easy to remember specially for the CRUD operations.
the mapping can be done automatically between class name == table name .. automatic public properties with field names.

and also you don't have to declare all fields on the class itself. the library is driven by the class public properties itself to get its data.

Why OH postfix?

Because this library can be glued to your application without any hassle. and produce rapid results whenever you want.

Strength points

  • Dynamic Mapping for POCO Classes with the name of the class and the public properties.
  • Compatible with .NET 3.5 (you can get the source and compile it into .NET 4.0)
  • Supporting Sql Server, Sql Server Compact, and OLE Databases.

Simple Usage

  • First Add your connection key in the application configuration file {make sure you are writing the provider name for different connections}
    • <add name="MaddyCompact" providerName="System.Data.SqlServerCe" connectionString="Data Source = ..\..\Maddy.sdf" />
  • Define your POCO Class
using EntityOH.Attributes;
class Person
    {
        [EntityField(Primary = true, Identity=true)]
        public int ID { get; set; }

        public string FirstName { get; set; }
        public string LastName { get; set; }

        public string Email { get; set; }

        public string Phone { get; set; }
    }
  • Get DbProbe object and do your
using (DbProbe db = DbProbe.Db("MaddyCompact")  // connection key
{


db.CreateTable<Person>(); // this command create the table in the database.
db.Select<Person>();  // this command retrieve the data from the database.
db.Insert<Person>(new Person{FirstName="",LastName=""});
db.Delete<Person>(ref Person person);
db.Update<Person>(ref Person person);
db.Count<Person>(); // for counting number of tables
db.SelectPage<Person>(int pageIndex, int pageItemsCount);  // for selecting portion of data based on page information

// to get a datatable use indexer
var dt = db["Person"];
}

  • Mapping of the data fields and properties of created is very very fast.
If any one has a large set of data to be compared against the library please let me know to measure it

at last I hope you like the library and use it as I am using it today.

Last edited Sep 2 at 11:06 AM by IBlueSun, version 5