Popularity
1.1
Stable
Activity
0.0
Stable
6
4
1

Description

The DatabaseObjects library is .NET object relational mapping tool that contains a large set of powerful classes that interface to the underlying database system. Classes and properties in the business layer / model are marked with attributes (or functions overridden) in order to indicate the table and field mappings to the database. The library is simple, powerful and easy to learn. There are no external files to setup - everything is setup using standard object-oriented techniques. It is light-weight, flexible and provides facilities for ensuring maximum performance. It is also under active development and requests for changes are always welcome.

Code Quality Rank: L2
Programming language: C#
License: Copyright 2015
Tags: ORM     Database     SQL     SqlServer     DAL     Utility    

DatabaseObjects alternatives and similar packages

Based on the "ORM" category.
Alternatively, view DatabaseObjects alternatives based on common mentions on social networks and blogs.

Do you think we are missing an alternative of DatabaseObjects or a related project?

Add another 'ORM' Package

README

DatabaseObjects

Database Support

  • SQL Server
  • MySQL
  • SQLite
  • HyperSQL
  • Microsoft Access
  • Pervasive

Environment Support

  • Windows
  • iOS via MonoTouch
  • Android via MonoDroid
  • OSX / Linux via Mono

Overview

The DatabaseObjects library is .NET object relational mapping tool that contains a large set of powerful classes that interface to the underlying database system. Classes and properties in the business layer / model are marked with attributes (or functions overridden) in order to indicate the table and field mappings to the database. The library is simple, powerful and easy to learn. There are no external files to setup - everything is setup using standard object-oriented techniques. It is light-weight, flexible and provides facilities for ensuring maximum performance. It is also under active development and requests for changes are always welcome.

License

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

SQL Support

The library also supports other database commands for creating / altering tables, indexes, views and specifying table joins, arithmetic expressions, aggregates, grouping, ordering, unions and support for all common data types and more. All commands are database agnostic.

Videos

A series of tutorial videos are available [here].(http://www.youtube.com/user/80twix/)

Documentation

All documentation and other information is available on the website www.hisystems.com.au/databaseobjects

Example

Below is a really simple example of what the library can do. This is really just a taste, see the demo project or the unit test project for more advanced examples.

namespace Northwind.Model
{
    public class Northwind
    {
        public Suppliers Suppliers { get; private set; }

        public Northwind()
        {
            var database = new DatabaseObjects.MicrosoftSQLServerDatabase("localhost", "Northwind");
            this.Suppliers = new Suppliers(database);
        }
    }

    [DatabaseObjects.Table("Suppliers")]
    [DatabaseObjects.DistinctField("SupplierID", eAutomaticAssignment: DatabaseObjects.SQL.FieldValueAutoAssignmentType.AutoIncrement)]
    [DatabaseObjects.OrderByField("CompanyName")]
    public class Suppliers : DatabaseObjects.Generic.DatabaseObjectsEnumerable<Supplier>
    {
        internal Suppliers(DatabaseObjects.Database database)
            : base(database)
        {
        }
    }

    public class Supplier : DatabaseObjects.DatabaseObject
    {
        [DatabaseObjects.FieldMapping("CompanyName")]
        public string Name { get; set; }

        [DatabaseObjects.FieldMapping("ContactName")]
        public string ContactName { get; set; }

        internal Supplier(Suppliers suppliers)
            : base(suppliers)
        {
        }
    }
}

namespace Northwind.Executable
{
    using Model;

    public class Program
    {
        public static void Main(string[] args)
        {
            var model = new Northwind();

            foreach (Supplier supplier in model.Suppliers)
                System.Console.WriteLine(supplier.Name);
        }
    }
}

Demo Project

The demonstration project is available in a separate repository on Github here. It includes a number of examples on how to utilise the library. To run the demo project in conjunction with the library it must be located in same directory as the library.

For example:

/DatabaseObjects /DatabaseObjects.Demo

Unit Test Project

The unit test project is available in a separate repository on Github here. It is also a good resource for examples on how to utilise the library. To run the unit tests project in conjunction with the library it must be located in the same directory as the library.

For example:

/DatabaseObjects /DatabaseObjects.UnitTests


*Note that all licence references and agreements mentioned in the DatabaseObjects README section above are relevant to that project's source code only.