Avocadorm is an object-relational mapper (ORM), used to link database tables to Dart objects. Its main focus is to be quick and easy to use. This is achieved by coding all database-related information in the entity classes.

##Creating the avocadorm In order to create the avocadorm, you need to tell it about your database by means of a database handler, then feed it with your entities.

avocadorm = new Avocadorm(databaseHandler)

##Usage With a valid Avocadorm in your hands, CRUD operations (and a few others) can be performed. See the documentation for more information about these methods.

With the avocadorm, you can

  • Create a new entity
  • Count entities
  • Retrieve entities
  • Update an entity
  • Delete an entity

##Usage example

var newEmployee = new Employee()
  ..name = 'Zyrthofar'
  ..companyId = 42;

avocadorm.create(newEmployee).then((pkValue) {
  print('New employee\'s id is ${pkValue}.');

See the examples page or the ready-to-use GitHub's /example project for more examples.

##Dependencies In order to use the Avocadorm, add the dependency in your pubspec.yaml, along with your database handler of choice. For example:

  magnetfruit_avocadorm: ">=0.1.0 <0.2.0"
  magnetfruit_mysql_database_handler: ">=0.1.0 <0.2.0"



ORM to perform CRUD operations on entities.