Future Directions

By Stephan Meyn

Saturday, June 05, 2004

Joins & Select Support

What is irritating with OODBMS and Bamboo is that you always have to get the complete object. SQL databases do have a very nifty feature where you can join two tables and select only the fields you want to access/display.

Consider you have two objects: Person and Location. The latter has a telephone number and the Person object has an association to Location named office.  Assume you need to update a phone list for a selected number of people.

In Bamboo Builder you get the Person objects first. Then you have to get the associated Address object for each Person object and extract the phone number (from Address) and the Person Surname and Firstname and put them into a  manually constructed object which you can then supply to a datagrid or similar.

The Join&Select support allows you to define a ViewObject. This object is identified to be a join between the two classes. The fields in the viewobject are a selected subset of the fields from the two classes.

In this example the view object only has three fields:

Once defined Bamboo Builder can then generate the class and add a method to the rootobject that will return such a precreated object.

Automated Getters for Foreign Keys

Based upon the discussion on Loosely Coupled Relationships, one of the next items is to design methods that allow entity objects to retrieve related objects in a transparent way. This implies they can call  the bamboo engine to retrieve related objects. As relations are two ways, it is possible to build it in two phases:

  1. From the object with the foreign key to the one with the primary key (many to one direction)
  2. The reverse, one to many relations

Indexing

The basic Bamboo engine is very fast and simple . Hence primary keys do not really require indexing. But searching for secondary fields, esp. text fields can benefit from indexing. Bamboo Prevalence has basic support for indexing across text fields. This needs to be researched further.

VB Support

Currently Bamboo Builder only generates C# code. The CodeDom is intended to generate either, C# or VB. However coding in CodeDom is not easy and leads to bulky and hard to maintain code. So in a good number of cases there are short cuts which made the implementation easier but as a side effect it breaks the CodeDom model making it impossible to generate proper VB code. So introducing VB Support means reworking the code. Hence this is low priority.