0% found this document useful (0 votes)
44 views

Adms Smalltalk Binding

The document discusses the Object Data Management Group (ODMG) standards for object databases and its Smalltalk binding specifications. It provides details on: 1) The ODMG standards include an object model, object definition language, object query language, and bindings for C++ and Smalltalk. 2) The Smalltalk binding specifies how ODMG concepts like the object model, object definition language, and object query language are mapped to Smalltalk programming constructs and types. 3) The Smalltalk binding respects Smalltalk principles by mapping ODMG concepts in a natural way and supporting interoperability through a unified type system shared with ODL.

Uploaded by

Priyu Sakhare
Copyright
© © All Rights Reserved
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
44 views

Adms Smalltalk Binding

The document discusses the Object Data Management Group (ODMG) standards for object databases and its Smalltalk binding specifications. It provides details on: 1) The ODMG standards include an object model, object definition language, object query language, and bindings for C++ and Smalltalk. 2) The Smalltalk binding specifies how ODMG concepts like the object model, object definition language, and object query language are mapped to Smalltalk programming constructs and types. 3) The Smalltalk binding respects Smalltalk principles by mapping ODMG concepts in a natural way and supporting interoperability through a unified type system shared with ODL.

Uploaded by

Priyu Sakhare
Copyright
© © All Rights Reserved
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 5

2.

1// Object Data Management Group is a sub-group of the OMG (Object Management
Group).
2//The OMG is a consortium of hundreds of object vendors whose purpose is setting
standards for object technology.so,Basically it is the
standards setting group for object database technology that is made up of an
agreement or combination of object-oriented DBMS vendors.
3//The primary goal of the ODMG is to put forward a set of specifications that
allowed a developer to write portable applications
for object database and also for the object-relational mapping products. so, In
order to do this, the data schema,
programming language bindings, data manipulation and query languages needed to be
portable.

3. 1// in first when odmg was resealed that was in 1993 it was published as ODMG-
93.
2//The ODMG-93 standard includes a common architecture and definition for an
OODBMS like definitions for an object model,
an object definition language (ODL), an object query language (OQL), and for
bindings to C++ and Smalltalk.
3//The need of OODBMS is that if there is increase in emphasis on process
integration it is a drives force for the adoption
of object-oriented database systems.
so, For example if we take the Computer Integrated Manufacturing (CIM) area,it
is focusing heavily on using object-oriented database
technology as the process integration framework.
another example is, Advanced office automation systems where it uses object-
oriented database systems to handle hypermedia data.
or of we take Hospital patient care tracking systems where it also uses object-
oriented database technologies for maintaining the patient records.
All of these applications are characterized by having to manage complex, highly
interrelated information, which is a strength of
object-oriented database management systems.

4. // The major components of ODMG are -


Object Model.

Object Definition Language (ODL)

Object Query Language (OQL)

Language bindings
- again the language binding is further classified as

C++ Binding

Smalltalk Binding

Java Binding

so, here we are going to discuss about the smalltalk binding in detail.

5. 1//The smalltalk binding is a a language binding that specifies how ODL/OML


constructs are mapped to programming
language constructs.so The languages supported by ODMG are Smalltalk,C++ and Java
as well.
2// This is the binding of ODMG implementations to Smalltalk.
It defines the binding in terms of the mapping between ODL and Smalltalk, which is
based on the OMG Smalltalk binding for IDL
i.e Interface Definition Language and Smalltalk binding also includes a process to
invoke OQL
and procedures for operations on databases and transactions.

6.//ODMG Smalltalk binding is based upon two principles-


1st is that It should bind to Smalltalk in a natural way that is consistent with
the principles of the language, and
2nd is that it should support language interoperability consistent with ODL
specification and semantics.

//but These principles have several implications that are evident in the design of
the binding with respect to ODL.
1. There is a unified type system that is shared by Smalltalk and the ODMS.
so,This type system is ODL as mapped into Smalltalk by the Smalltalk binding.
2. The binding respects the Smalltalk syntax,means that the Smalltalk language
will not have to be modified to accommodate this binding. ODL concepts
will be represented using normal Smalltalk coding conventions only.
3. The binding respects the fact that Smalltalk is dynamically typed. that is
Arbitrary
Smalltalk objects may be stored persistently, including ODL-specified
objects that will obey the ODL typing semantics.
4. the last one is The binding respects the dynamic memory management semantics
of Smalltalk.
here the Objects will become persistent when they are referenced by other
persistent objects in the database and
will be removed when they are no longer reachable in this manner.

7.// now here we will see the mapping of ODMG OBJECT MODEL INTO SMALLTALK. Although
Smalltalk provides a powerful data model, it remains necessary to precisely
describe how the concepts of the ODMG
Object Model map into concrete Smalltalk constructions.
//1.so , 1st is - Object and Literal- here An ODMG object type maps into a
Smalltalk class. Since Smalltalk has no distinct
literal objects, both ODMG objects and ODMG literals may be implemented by the same
Smalltalk classes.
//2. Relationship- This concept is not directly supported by Smalltalk and is
implemented by
Smalltalk methods that support a standard protocol.
//3. Name-here , Objects in Smalltalk have a unique identity, and references to
objects may appear in a variety of naming contexts.
//4.Extents-Extents are not supported by this binding. Instead, users may use the
database naming
protocol to explicitly register and access named Collections.
//5.Keys- Key declarations are also not supported by this binding.users may use
the database
naming protocol to explicitly register and access named Dictionaries.
//6.Implementation-Everything in Smalltalk is implemented as an object.
//7.Collections-Smalltalk provides a rich set of Collection subclasses,
including Set, Bag, List, Dictionary, and Array classes.
//8. Database Administration Databases are represented by instances of Database
objects in this binding, and a
protocol is defined for creating databases and for connecting to them.

8.// there are 3 Smalltalk binding with respect to ODL,OQL and OML.so,here is the
smalltalk ODL which has the OMG IDL binding and
Smalltalk ODL Binding extension.
1.now , Since the Smalltalk/ODL binding is based upon the OMG Smalltalk/IDL
binding, we
include here some descriptions of the important aspects of the IDL binding that are
needed in order to better understand the ODL binding.OMG IDL smalltalk binding has
few descriptors in it,they are
-Identifiers-here,IDL allows the use of underscore characters in its identifiers.
Since underscore char#acters are not allowed in
all Smalltalk implementations, the Smalltalk/IDL binding provides a conversion
algorithm.
-next is Interfaces-now,Interfaces defines sets of operations, that an instance
supporting that interface must
possess. for now, interfaces correspond to Smalltalk protocols that is,Implementors
are free
to map interfaces to classes as required to specify the operations, that are
supported by
a Smalltalk object.
-than comes the Objects- here,Any Smalltalk object that has an associated IDL
definition
(by its CORBAName method which is the Naming Service specification) may be a CORBA
object.
-next is Operations- so, Unlike Smalltalk, IDL operations also allow out and inout
parameters to be
defined, which allow more than a single result to be communicated back to the
caller
of the method.
-then are constants- so,any Constants or Exceptions that are defined in IDL, are
made available to the
Smalltalk programmer in a global dictionary, which is indexed by the fully
qualified scoped name of the IDL entity.
-next is type - Since, in Smalltalk, everything is an object, there is no
separation of objects and
datatypes as exist in other hybrid languages such as C++.
-and the last is exceptions-IDL exceptions are defined within modules and
interfaces, and therfore are referenced by the
operation signatures that raise them.
2.now, after OMG Smalltalk/IDL binding,comes the Smalltalk ODL Binding
extension.This section describes the binding of
ODMG ODL to Smalltalk. ODL provides a description of the database schema as a set
of interfaces, including their attributes,
relationships, and operations. so, the Smalltalk implementations consist of a set
of object classes
and their instances. This includes -
-Interfaces and classes-In ODL, interfaces are used to represent the abstract
behavior of an object, and classes
are used to model the abstract state of objects. Both types may be implemented by
Smalltalk classes.
-then attributes declarations-Attribute declarations are used to define pairs of
accessor operations that get and set
attribute values.
-next is Relationship declaration-The Smalltalk binding for relationships results
in public methods to form and
drop members from the relationship, plus public methods on the relationship target
classes to provide access and private methods to manage the required referential
integrity constraints.
-then comes collection-The Smalltalk method selector that this binding defines
for each of the
Collection interfaces.
-last is structured literals- it is used to represent Date, Time, Timestamp, and
Interval
values that must be supported by each language binding.

9.//next is smalltalk OML.So, The guiding principle for Smalltalk OML is that the
syntax used to create,
delete, identify, reference, get/set property values, and invoke operations on a
persistent object
should not be different from that used for objects of shorter time.
//The Smalltalk OML follows 3 protocols-Object Protocol,Database
Protocol,Transaction Protocol.

10. 1.//1st is object protocol-Since all Smalltalk objects inherit from class
Object, it is natural to implement some of
the ODMG language binding mechanisms as methods on this class.
//Object protocol includes Object Persistence which is not limited to any
particular
subset of the class hierarchy, nor is it deter#mined at object creation time.
//then Object Deletion is that An object is removed from the database during
garbage collection if that
object is not referenced by any other persistent object.
//then Object Locking where Objects that are activated into memory, acquire the
default lock for the active concurrency
control policy.
//and Object Modification-here the Modified persistent Smalltalk objects will
have their updated values reflected in the
ODMS at transaction commit.
2.//2nd protocol is database protocol-A Smalltalk application must open a
Database before any objects in that database are
accessible.
//Database protocol comprises of opening database,closing of database and
database name where Each Database manages a
persistent name space that maps string names to objects or collections of objects,
which are contained in the database.
3.//3rd one is the Transaction protocol-this is implemented in Smalltalk using
methods that are defined on the class
Transaction.
//Transaction protocols includes simple transactions like
begin,commit,join,ccurrent,abort.
//2nd one is blocked scoped transaction -here,A transaction can also be
scoped to a Block to allow
for greater convenience and integrity.so,If the transaction commits, the
commitBlock will be evaluated after
the commit has completed or If the transaction aborts, the abortBlock will be
evaluated
after the rollback has completed.
//last one is transaction exception-here, Several exceptions that may be
raised during the execution of a transaction like
noTransactionSignal is raised ,or inactiveSignal or when a
transactionCommitFailedSignal is raised.

11.//last one is smalltalk OQL.This section describes how OQL is


mapped to the Smalltalk language. so, The current Smalltalk OQL binding is a
loosely
coupled binding modeled after the OMG Object Query Service.
//smalltalk OQL includes Query class which has 4 attributes-queryResult,
queryStatus, queryString,
and queryParameters.
where QueryResult holds the object that was the result of executing
the OQL query.
QueryStatus holds the status of query execution.
QueryString is the OQL query text to be executed.
and QueryParameters contains variable-value pairs to be bound to the OQL query
at execution.

You might also like