Thursday, November 22, 2007

Object Oriented and Incarnation of God

This incident dates back a decade when Ramayana was telecasted in Doordarshan (DD). Not sure how many of you watched Ramayana in DD.

Obviously anyone who knows Ramayana will also know that both Ram and Parasuram met during Sita's syamwar.

The immediate question that stuck my mind after this scene was how come Vishnu take avatar of Ram and also take avatar of Parasuram at the same time? (I was not matured enough to understand the philosophy behind it).

Though I was able to understand that God can take avatars but not two avatars at the same time. How he be in two different forms in the same place? That sounded strange and never have I heard any similar stories.

The question was in my mind unanswered till the time I learned Object Oriented Programming for Java.

During my early days of learning java it was really tough to under the Object Oriented Concepts. But as the time passed, i was able to see everything in the form of Object well of course everything was actually in Objects but its only then I realised it.

In Object Oriented Programming there are concepts like Inheritance, Abstraction, Polymorphism, Class, Objects etc.

Inheritance: In object-oriented programming, inheritance is a way to form new classes (instances of which are called objects) using classes that have already been defined. The new classes, known as derived classes, take over (or inherit) attributes and behaviour of the pre-existing classes, which are referred to as base classes (or ancestor classes). It is intended to help reuse of existing code with little or no modification.
Refer http://en.wikipedia.org/wiki/Inheritance_(computer_science)

Abstract Class: An abstract class, or abstract base class (ABC), is one that is designed only as a parent class and from which child classes may be derived, and which is not itself suitable for instantiation. Abstract classes are often used to represent abstract concepts or entities. The incomplete features of the abstract class are then shared by a group of sibling sub-classes which add different variations of the missing pieces.
Refer http://en.wikipedia.org/wiki/Abstract_class#Abstract_and_concrete_classes

As per this, I concluded that Lord Vishn can be considered as an Abstract Class while both Ram and Parasuram can be considered as inherited concrete classes with their own properties but still a concrete manifestation of the Lord Vishnu.

How wonderful to know that even God’s are Object Oriented?

2 comments:

Unknown said...

Jagan,
LOL .. interesting write up! What a perspective! Thinking of re-incarnation of God as 'objects' and God himself as a 'Class'. And the words literally convey the meaning as well! That is the icing on the cake ...

But you reminded me of Java. I am getting nostalgic now ... that was one stuff I loved, but never got to work on. Ended up as a poor mainframer :(

Smiles,
Vinayak

Sukumar said...

This is a good analogy and giving a different dimension.