Introduction Advanced data models and emerging trends (Ch. 11, 3 rd ed. – Ch. 20, 4 th ed.)

Slides:



Advertisements
Similar presentations
Object Oriented Programming
Advertisements

Final and Abstract Classes
Understand and appreciate Object Oriented Programming (OOP) Objects are self-contained modules or subroutines that contain data as well as the functions.
Construction process lasts until coding and testing is completed consists of design and implementation reasons for this phase –analysis model is not sufficiently.
OO databases 1 Object Oriented databases. OO databases 2 Developing OODBMS - motivation motivation more and more application areas require systems that.
Chapter 10: Designing Databases
Object Oriented Database Group 4 Mathieu Metz Palani Kumaresan Napa Gavinlertvatana Kristine Pei Keow Lee Prabhu Ramachandran.
Object-Oriented Programming. 2 An object, similar to a real-world object, is an entity with certain properties, and with the ability to react in certain.
Jane Reid, BSc/IT DB, QMUL, 25/2/02 1 Object-oriented DBMS Background to ODBMS ODBMS requirements Object components ODB conceptual design –Graphical ODB.
the Entity-Relationship (ER) Model
Relational Database Design Via ER Modelling
Distributed DBMS©M. T. Özsu & P. Valduriez Ch.15/1 Outline Introduction Background Distributed Database Design Database Integration Semantic Data Control.
Copyright © 2007 Ramez Elmasri and Shamkant B. Navathe Slide
George Blank University Lecturer.
Object Databases Baochuan Lu. outline Concepts for Object Databases Object Database Standards, Languages, and Design Object-Relational and Extended-Relational.
Databases CIS 422. Lifetime of Data Transient results to the evaluations of expression Variables involved in procedure activation Global variables Dynamically.
ODMG Standard: Object Model1 OBJECT-ORIENTED DATABASE SYSTEMS ODMG Standard: Object Model Susan D. Urban and Suzanne W. Dietrich Department of Computer.
Object-Oriented Databases v OO systems associated with – graphical user interface (GUI) – powerful modeling techniques – advanced data management capabilities.
Chapter Object-Oriented Practices. Agenda Object-Oriented Concepts Terminology Object-Oriented Modeling Tips Object-Oriented Data Models and DBMSs.
OBJECTS Object Oriented ???????. OBJECTS Object-Oriented n OO convenient label for a collection of interconnected ideas n OO approach views computer.
©Silberschatz, Korth and Sudarshan8.1Database System Concepts Chapter 8: Object-Oriented Databases Need for Complex Data Types The Object-Oriented Data.
7M701 1 Class Diagram advanced concepts. 7M701 2 Characteristics of Object Oriented Design (OOD) objectData and operations (functions) are combined 
Object-Oriented Databases
Chapter 20 Concepts for Object-Oriented Databases Copyright © 2004 Pearson Education, Inc.
Fundamentals, Design, and Implementation, 9/e Chapter 16 Object-Oriented Database Processing.
Object Oriented Databases - Overview
July 13, 2015ADBS: OODB1 Concepts for Object-Oriented Databases Chapter 20.
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 11 Object and Object- Relational Databases.
EER vs. UML Terminology EER Diagram Entity Type Entity Attribute
OOP Languages: Java vs C++
Advanced Database CS-426 Week 2 – Logic Query Languages, Object Model.
Comparison of OO Programming Languages © Jason Voegele, 2003.
Programming Languages and Paradigms Object-Oriented Programming.
Chapter 24 Introduction to Object DBMSs Prepared by Kai Huang CS157B Prof Sin-Min Lee.
Introduction to the Other Databases
DBMS Lecture 9  Object Database Management Group –12 Rules for an OODBMS –Components of the ODMG standard  OODBMS Object Model Schema  OO Data Model.
11 1 Object oriented DB (not in book) Database Systems: Design, Implementation, & Management, 6 th Edition, Rob & Coronel Learning objectives: What.
CISC6795: Spring Object-Oriented Programming: Polymorphism.
1 Announcements Research Paper due Friday November 19 For Wednesday read
Chapter 20 Concepts for Object-Oriented Databases Copyright © 2004 Pearson Education, Inc.
11 Chapter 11 Object-Oriented Databases Database Systems: Design, Implementation, and Management 4th Edition Peter Rob & Carlos Coronel.
11 1 Chapter 11 Object Oriented Databases Database Systems: Design, Implementation, and Management, Sixth Edition, Rob and Coronel.
Guided Notes Ch. 9 ADT and Modules Ch. 10 Object-Oriented Programming PHP support for OOP and Assignment 4 Term project proposal C++ and Java Designer.
FEN NOEA/IT - Databases/ODB1 ODB – Object DataBases Object-Oriented – Fundamental Concepts UML and EE/R OO and Relational Databases Introduction.
1 CS457 Object-Oriented Databases Chapters as reference.
ITEC 3220A Using and Designing Database Systems Instructor: Prof Z. Yang Course Website: 3220a.htm
ITEC 3220A Using and Designing Database Systems Instructor: Gordon Turpin Course Website: Office: CSEB3020.
Object Oriented Database By Ashish Kaul References from Professor Lee’s presentations and the Web.
Object Relational Features
11-1 CHAPTER 11 Concepts for Object-Oriented Databases.
Object-Oriented Programming Chapter Chapter
ISBN Object-Oriented Programming Chapter Chapter
Copyright © 2007 Ramez Elmasri and Shamkant B. Navathe Chapter 7 Object-Oriented Database.
The ODMG Standard for Object Databases
Inheritance and Class Hierarchies Chapter 3. Chapter 3: Inheritance and Class Hierarchies2 Chapter Objectives To understand inheritance and how it facilitates.
Chapter 18 Object Database Management Systems. Outline Motivation for object database management Object-oriented principles Architectures for object database.
Lecture 2: Review of Object Orientation. © Lethbridge/La ganière 2005 Chapter 2: Review of Object Orientation What is Object Orientation? Procedural.
The Object-Oriented Database System Manifesto Malcolm Atkinson, François Bancilhon, David deWitt, Klaus Dittrich, David Maier, Stanley Zdonik DOOD'89,
Chapter 20 Concepts for Object-Oriented Databases Copyright © 2004 Pearson Education, Inc.
Copyright © 2016 Ramez Elmasri and Shamkant B. Navathe Chapter 12 Outline Overview of Object Database Concepts Object-Relational Features Object Database.
IST 210 Object Oriented Database. IST 210 Object-Oriented Concepts  Abstract Data Types  Class definition, provides extension to complex attribute types.
Faeez, Franz & Syamim.   Database – collection of persistent data  Database Management System (DBMS) – software system that supports creation, population,
OODBMS and ORDBMS. Background Object-oriented software, based on the principles of user-defined datatypes, along with inheritance and polymorphism, is.
Concepts for Object Databases
Object – Oriented Databases
Types of Programming Languages
Chapter 12 Outline Overview of Object Database Concepts
ISC321 Database Systems I Chapter 10: Object and Object-Relational Databases: Concepts, Models, Languages, and Standards Spring 2015 Dr. Abdullah Almutairi.
ITEC 3220A Using and Designing Database Systems
4/27/2019.
Presentation transcript:

Introduction Advanced data models and emerging trends (Ch. 11, 3 rd ed. – Ch. 20, 4 th ed.)

Introduction Outline -Object-identifier, object structure -Encapsulation -Type and class hierarchy -Structured and unstructured objects -Polymorphism and operator overloading -Multiple inheritance

Introduction OO has roots in Programming languages SIMULA (simulation language) has the concept of classes - late 60s SMALL TALK is the first pure OO language Hybrid languages incorporate OO concepts into an already exisiting programming language –Example: C++

Introduction Programming objects only exist during the program execution Database objects need to exist permanently (persistent objects) Concepts such as encapsulation, inheritance, identity and evolving relationships must be applied in the context of OODBMS OODBMS must also support transactions, concurrency, recovery

Object Identity FEach object in the DB has a unique identity (OID) Feven though the value of an object changes, its identity must not change (the OID is immutable) F if an object is deleted its OID must not be assigned to any other object FThese two properties imply that an object identifier must not depend on an attribute FSome systems use the physical address of the object in storage as an OID FRelational database tables have a primary key Fvalue can change Fcould have same object - two tables - different primary keys

Object Structure In OODB, the value of a complex object can be constructed from other objects Each object can be viewed as a triple –( i, c, v) –where i is the unique object identifier (OID) –c is the constructor or an indication of how the object value is constructed (operator) –v is the value of the object (state) Basic constructors are atom, tuple, set –Others: list, array

Object Structure The value v can be interpreted on the basis of the constructor c Example: –if c = atom then v = atomic value o 1 = (i 1, atom, Houston) o 2 = (i 2, atom, Bellaire) o 3 = (i 3, atom, Sugarland) o 4 = (i 4, atom, 5) o 5 = (i 5, atom, Research) o 6 = (i 6, atom, 22-May-78) The value Houston

Object Structure Example: –if c = tuple then v = o 8 = (i 8, tuple, ) o 9 = (i 9, tuple, ) A department tuple

Object Structure Example: –if c = set then v = {i 1,i 2,i 3 } o 7 = (i 7, set, { i 1, i 2, i 3 } ) o 10 = (i 10, set, { i 12, i 13, i 14 } ) o 11 = (i 11, set, { i 15, i 16, i 17 } ) A set of employees

Type Constructors Define type department tuple( dnamestring dnumberinteger mgrtuple (manageremployee startdate:date) locationsset (string) employeesset (employee ) projectsset (project ) ) Define type employee tuple( namestring ssnstring birthdatedate work_indepartment ) We will have references to other objects

Type Constructors O8O8 tuple Dname dnumber mgr locations employees projects i5i5 Research atom i4i4 5 i9i9 tuple Manager managerstartdate tuple i 12 i 10 set tuple i 13 tuple i 14 i6i6 atom 22-May-78

Encapsulation Encapsulation - Structure of an object is not visible to the external world –all operations on an object are predefined –some operations may be used to create, destroy, modify the values or retrieve the values of an object –External users only have access to the interface of the object (signature) which defines the names and types of all parameters to each operation –Methods specify the implementation of operations –A method is invoked (call) by sending a message

Encapsulation In a RDBMS, the structure of an object is visible to all users –That is, a relation and attributes are visible –All database operations (selection, insertion, deletion..) are applicable to any relation (all object types) In an OODBMS, one can divide a structure into visible and hidden parts –The hidden attributes are completely encapsulated and accessed only through pre-defined operations

Encapsulation/Persistence It is customary for an OODBMS to be closely coupled with an OO programming language An OO programming language is used to specify the method implementations –O2 uses O2C … O2C is C adapted for objects –ObjectStore uses C++ In an OODBMS, not all objects are persistent; some are transient In an EER or relational model, all objects are persistent

Type and Class Hierarchies FTypes are different from classes even though they lead to the same structures FA type has a name, a set of attributes (instance variables) and operations (methods) FA new type can be defined based on other predefined types leading to a Type hierarchy FAn object can belong to a type FType definitions do not generate objects of their own FExample: Person: Name, Address, Birthdate, Age FEmployee subtype of Person: Salary, HireDate

Class Hierarchies FClass is a collection of objects meaningful to some application FIn most OODBs, a class is a collection of objects belonging to the same type FA class is defined by its name and the collection of objects included in the class FWe can also define subclasses and superclasses creating a class hierarchy FIn OODBs the concept of a type and class are the same. Hence, the hierarchies are the same. FEach class then has a particular type and holds a collection of persistent objects of that type

Complex Objects FMotivation for the development of OO systems is to represent complex objects FTwo types of complex objects: FUnstructured FStructured

Complex Objects FUnstructured Complex Object –The structure of these objects is not known to the DBMS –Only the application programs can interpret the objects –Ex: Bitmap images - BLOB (Binary large objects) –These objects require a large amount of storage and not a part of the standard type definitions

FUnstructured Complex Object –DBMS may retrieve only a portion of the object –DBMS may use caching and buffering to prefetch portions of the object –The DBMS does not have the capability to directly process selection conditions based on values of these objects unless the application programs provide the code –In OODBMS, this is done by defining an Abstract data type with operations for selection, comparison, etc –These feature allows the OODBM to have an extensible type system That is, new types can be created and hence libraries of new types Complex Objects

FStructured Complex Object –The object structure is defined and known to the DBMS –Object Structure is defined using type constructors (set, atom, tuple) –Two types of reference semantics exist between a complex object and its component: F Ownership F Reference Complex Objects

FOwnership Semantics –Subobjects are encapsulated within a complex object are considered a part of the complex object FReference Semantics –Components of a complex object are themselves independent objects, but at the same time may be considered a part of the complex object

O8O8 tuple Dname dnumber mgr locations employees projects Research 5 i9i9 tuple Manager managerstartdate tuple i 12 i 10 set tuple i 13 tuple i 14 i6i6 atom 22-May-78

FThe ownership semantics leads to an is-part-of or is-component-of relationship Fare employees part of the department? FThe is-part-of relationship (or ownership semantics) means that the encapsulated objects can be accessed by the methods of that object and deleted if the object is deleted Complex Objects

FThe reference semantics leads to an is-associated-with relationship Fare the employees associated with the department? FAn OODBMS should provide the storage options for clustering the component objects together in order to increase efficiency FThe mechanism of building objects from complex object structures is called object assembly Complex Objects

Other OO concepts FPolymorphism –An operator can be applied to different types of objects –When an operator has distinct implementations then we have operator overloading –Example: + when applied to integers implies integer addition –+ when applied to sets implies set union

Other OO concepts FPolymorphism FExample: Geometry_Object: Shape, Area, CenterPoint Rectangle subtype_of Geometry_Object(Shape=rectangle): Width, height Triangle subtype_of Geometry_Object(Shape=triangle): side1, side2, angle Circle subtype_of Geometry_Object(Shape=circle): Radius Area is a method that would be different for each sub-Type

FStrongly Typed systems: Method selection is done at compile time (early binding) FWeakly Typed systems: Method selection is done at run time (late binding). Lisp and Small Talk are examples late-binding Other OO concepts

FMultiple Inheritance: Fallowed in O2 Fleads to a lattice –One problem: if a subtype inherits two distinct methods with the same name from two different supertypes –A solution: check for ambiguity when the subtype is created and let the user choose the function –Another solution: use some system default –A third solution: disallow multiple inheritance if ambiguity occurs Other OO concepts

FSelective Inheritance: –When a subtype inherits only a few methods –This mechanism is not usually provided by OODBMS Other OO concepts

FVersions: –Ability to maintain several versions of an object –Commonly found in many software engineering and concurrent engineering environments –Merging and reconciliation of various versions is left to the application program –Some systems maintain a version graph FConfiguration: –A configuration is a collection compatible versions of modules of a software system (a version per module) Other OO concepts