Object objects

Object objects

Every multimedia_text, textual_content and file_descriptor are descendants of object. For those of you who aren't familiar with Object-oriented Programming, this is probably going to sound mysterious. Now, think of it in terms of you and I. We are both humans, right? Well, it's the same here. Jack is Jack and Jill and Jill, you can surely tell who is who, yet, they both are human, so you know they have a heart, lungs etc.

When we say that everything is an object, we make a similar assumption. Whatever we can say about object will apply to its descendants as well. Although this is a bit too general (and there are actually exceptions) this is as much programming you need to understand this documentation. So, what is this whatever we can say about object? At first sight, this object thing seems to do very little, and in fact it is a very general being.

bdnaIt is what we can call a low-level DNA: it contains a set of flags that tell the descendant how to behave. You don't know what a flag is in Information Technology? Well, it's simply a good old switch. It can be true or false, i.e., it can be on or off. You used switches for most of your life, so there's no secret about them.

Currently our DNA is fairly simple, as it's got just three switches:

  1. copyrightable
  2. networked
  3. mediated

The first switch says whether the descendant object can be licensed as the concept of 'drink' cannot be copyrighted, but a drink's name can (if used as a trademark). Copyright-able objects need licence information to be usable, so this switch tells the descendant object (no matter what it is) that it should carry a licence before being accepted by the system. Obviously the licence can be public domain, which is by all means a licence.

If the networked switch is on, it means that the descendant object will be broadcast on the distributed repository. Not all individual objects in the system need broadcasting, as many are generated from rules. To remain on legal grounds, a copyright-able object assumes the licence of the region (we shall see what a region is later on) to which it belongs, unless it states an exception. In both cases the need for a licence is satisfied, but only exceptions to regional rules need being broadcast individually.

Last we have a flag called mediated. When mediated is set TRUE, it means that the content is language dependent, and in order to be meaningful for a user it must be put into the most appropriate linguistic phase. I can see a lot of eyebrows moving. What sort of content can be language independent? Well, you can easily find out in what language is expressed the word wine, and in what is expressed вино, but what's the language of the drink itself?

As we said, object is not only included into multimedia_text and specialized container objects. Other entities that descend from it always carry language independent information (i.e. not the name of the drink in a given language, but the drink itself, before language). The border between language dependent and language independent entities is fixed, as an object's flags can be set only on creation, and never be modified afterwards.

A further service given by object is that it can be classified. We shall see in detail how classification works later on, at this stage it is important to understand that you can attribute semantic qualities to any object, and since everything is built on top of an object... you can give semantic classification to any element in the system.

There is a final service performed by object: it is our main catalog of everything that is in the system. Networked objects carry uuids (if you don't understand what they are think of the bar-code that identifies a product in a large network of supermarkets) that identify them all over the distributed repository, but the larger set of local objects has only numeric identifiers, that are supplied by object. Since all tables that contain data of the descendant entities cascade on this numeric id, if you delete an object you are actually automatically deleting whatever entity had been derived from it. 

The next step introduces us to our before language container, the profile object.