[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: Item vs. Instance XRI element name
XDI TC Members: This email is background for an agenda item on today's TC call regarding the name for a particular XRI subelement. In extensive discussions since the last call about the v2 universal schema and the five-layer logical data model with Andy Dale and Steve Churchill of ooTao and XDI.ORG (Steve is joining the TC today), we concluded that "Instance" does in fact seem to be a more intuitive name than "Item" for the fourth element in the hierarchy: Physical Logical Type Instance Version Andy pointed out one reason that I found fascinating. From a distributed database perspective, what the XDI logical data model represents is the following set of abstractions: Physical --> Database Logical --> Table Type --> Column Instance --> Row Version --> ("z" axis not usually managed by databases) This actually fits well with the following observation about mapping objects into databases from the Wikipedia entry for "database" at http://en.wikipedia.org/wiki/Database. See especially the last sentence after "the Two Great Blunders...". "In recent years, the object-oriented paradigm has been applied to databases as well, creating a new programming model known as object databases. These databases attempt to overcome some of the difficulties of using objects with the SQL DBMSs. An object-oriented program allows objects of the same type to have different implementations and behave differently, so long as they have the same interface (polymorphism). This doesn't fit well with a SQL database where user-defined types are difficult to define and use, and where the Two Great Blunders prevail: the identification of classes with tables (the correct identification is of classes with types, and of objects with values), and the usage of pointers." According to this analysis, the conventional object notion of a "class", when adapted to a database, indeed corresponds to a Type, which in database table architecture is typically represented as a Column. It seems to follow naturally that if a Column equates to a Type, then a Row equates to an Instance. From a pure OO standpoint, a Field or Cell (the intersection of a Column and a Row) can in fact be considered a very simple object (with only one value), but it is indeed an instance of the Type defined by its Column. The following definitions from the Java Tutorial at http://java.sun.com/docs/books/tutorial/java/concepts/class.html also seem to be consistent with this: ****BEGIN EXCERPT**** What Is a Class? In the real world, you often have many objects of the same kind. For example, your bicycle is just one of many bicycles in the world. Using object-oriented terminology, we say that your bicycle object is an instance of the class of objects known as bicycles. Bicycles have some state (current gear, current cadence, two wheels) and behavior (change gears, brake) in common. However, each bicycle's state is independent of and can be different from that of other bicycles. Type A class or interface. Instance An object of a particular class. In programs written in the Java(TM) programming language, an instance of a class is created using the new operator followed by the class name. ****END EXCERPT**** Conclusion: Andy, Steve, and I recommend we use the tag name "Instance" for the third level in the hierarchy. We'll discuss further on the call today. =Drummond
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]