|
Re: some questions regarding oops
Applications of OOPS -
You can virtually design anything you want as an object. Let me take a concrete example of this page itself.
If have to design this page which you are reading now using OOPS, simply you can assume this "page" itself as an object which inherits all properties from another object called "template". You can "override" any of those default properties from template in "Page" like colors, size, styles and so on. You want to go deeper in to this cycle, you can think page instantiates another object "post" which contains a single post of a thread and this cycle goes on. You can even model each button, field as an object.
Memory management in OOPS -
OOPS is a programing style. Not a methodology to do any activity. So every (OOPS) programing language inherits this style in its own way with its own implementation. OOPS doesn't have such standards in memory management. Every programming language has its own way of doing it.
OOPS in internet -
I couldn't get what you are looking for exactly. If you are talking about internet programming languages, Yes. We have OOPS there too.
Exception handling -
There are two types of exception.
1. Compile time exceptions and
2. Run time exceptions
Compiler takes care of compile time exceptions generally and we are expected to take care of runtime exception.
A simple example is, reading input from user. If you are expecting a number in quantity field of a shopping cart, but user can input an alphabet at run time. This has to handled programmatically using exceptions or other means (like series of validations on fields).
Thanks,
Krishna
__________________
Give 1 cup rice to a hungry Indian just by a mouse click. No money, no form filling, no hassle... Click here for the donation.
|