Object Definition Language ODL
Object Definition Language ODL
Language ODL
Presented By:
Sagar S Talagatti – 2GI23SCS08
3. Conclusions
4. References
1. Key concepts of Object Model of ODMG
a. Characteristics of objects:
i. Object Identifier(Object_id) – Unique, system-wide identifier
ii. Name – Some objects may optionally be given a unique name
iii. Lifetime – Specifies whether an object is persistent or transient
iv. Structure – Specifies whether an object is atomic or not
v. Creation – Typically accomplished via an operation new for a special Object_Factory interface
b. Literals:
Literal is a value that does not have an object identifier, can be of 3 types:
i. Atomic – Examples are long, short(integers), float, double, boolean, ENUM, etc…
ii. Structured – Created using the STRUCT keyword in ODL
iii. Collection – Collection of objects or values, and can be of type set, bag, list, array, dictionary
1. Key concepts of Object Model of ODMG
(ctd…)
c. Object interface:
interface Object {
...
boolean same_as(in object other_object);
object copy();
void delete();
};
• Its main use is to create object specifications—that is, classes and interfaces.
• A user can specify a database schema in ODL independently of any programming language, and then use the
specific language bindings to specify how ODL constructs can be mapped to constructs in specific
programming languages, such as C++, Smalltalk, and Java.
2. Object Definition Language(ODL) (ctd…)
a. EER diagram of University DB
2. Object Definition Language(ODL) (ctd…)
b. Graphical notations
2. Object Definition Language(ODL) (ctd…)
c. Example schemas
i. University DB
2. Object Definition Language(ODL) (ctd…)
c. Example schemas
ii. Graphical objects
2. Object Definition Language(ODL) (ctd…)
d. ODL schema code for University DB
2. Object Definition Language(ODL) (ctd…)
2. Object Definition Language(ODL) (ctd…)
2. Object Definition Language(ODL) (ctd…)
2. Object Definition Language(ODL) (ctd…)
e. ODL schema code for Geometric Shapes
3. Conclusions
i. An object consists of attributes and operations.
iii. User can specify the db schema using ODL, independent of programming language.
iv. Multiple inheritance of interfaces by a class is allowed, but with the extends (class)
inheritance, multiple inheritance is not permitted.
v. Language specific bindings can be used to map ODL constructs to language specific
constructs.
4. References
• Elmasri and Navathe: Fundamentals of Database Systems, 6 th Edition, Pearson Education
THANK YOU