Browse Prior Art Database

Dynamic Data Conversion for Software Release Compatibility by Object Oriented Programming

IP.com Disclosure Number: IPCOM000111082D
Original Publication Date: 1994-Feb-01
Included in the Prior Art Database: 2005-Mar-26
Document File: 4 page(s) / 161K

Publishing Venue

IBM

Related People

Poon, R: AUTHOR

Abstract

An object-oriented method for data conversion between software releases dynamically and implicitly during run-time is disclosed. With this invention only the class owner who modifies the class need to be concerned with the data conversion and no ripple, caused by the change of the data structure, will spread to the applications. This invention provides a new keyword in the object- oriented languages as a mean for the class owner to manage the data conversion.

This text was extracted from an ASCII text file.
This is the abbreviated version, containing approximately 27% of the total text.

Dynamic Data Conversion for Software Release Compatibility by Object
Oriented Programming

        An object-oriented method for data conversion between
software releases dynamically and implicitly during run-time is
disclosed.  With this invention only the class owner who modifies the
class need to be concerned with the data conversion and no ripple,
caused by the change of the data structure, will spread to the
applications.  This invention provides a new keyword in the object-
oriented languages as a mean for the class owner to manage the data
conversion.

      The core of this invention is a new feature introduced into
object-oriented programming.  Before this new feature will be
discussed, two unique characteristics of object-oriented programming,
class inheritance and polymorphism, will be summarized.  Class
inheritance is the technique used to build new class from old ones.
A subclass has to inherit all the class attributes from the
superclass(es), not part of them.  If a "member function" is only
defined in the subclass, the superclass(es) can't use it.

      Polymorphism in object-oriented programming is the ability for
each individual subclass to have its own custom version of the common
function and, at run time, the object is bound to the function
provided by the class the object belongs to.  Therefore, there is no
need for a series of IF statements or CASE statements to test the
object type in order to invoke the correct custom function.

      The current implementation of the polymorphism builds a table
containing the name of the subclass and the entry point of the custom
function during the compile time.  At run time, when an object of
superclass issues a message to the common function, the machine will
search (or harsh for performance) the table to obtain the entry point
for the subclass and invoke the proper custom function for that
subclass object.  The following example will illustrate the
polymorphism.

IN CLASS LIBRARY:

       class figures {
            public:
              virtual void draw();
        };
        class triangle : derived figures {
            int side1, side2, side3;
            public:
            triangle(int a, int b, int c)
              { side1=a; side2=b; side3=c;}
            void draw() { ......}
        };

       class square : derived figures {
            int side;
            public:
            square(int a)
              { side=a;}
            void draw() { ......}
        };
       (......)

IN APPLICATION:

       main()
        { figures *f1[2];                /* declare a two element
array
                                            of class figures      */
          disk_device d1;       ...