Skip to main content

Posts

Showing posts from October, 2007

Easy Freeware Downloads - My New Blog

Q. What is this? A. This is the screenshot of my new blog Easy Freeware Downloads . Q. What was it about? A. It is pretty much a freeware (software) archive. It is a blog hence new freeware are added with brief description and feature list. Q. Why is it named so? A. For each freeware we list, a direct download link makes downloading easy with just ONE CLICK, hence the name. Q. Is it worth visiting now? A. I guess so, because I am announcing it after having working on it for more than a month. It has 60+ freeware listed (as of 28-Oct-07). Click Easy Freeware Downloads to visit.

Overloading the Parenthesis () Operator

First, I want to apologize to my readers for not being able to post lately, partly due to me being very busy these days;-) As we all know, there are certain ways by which we can pass data to objects (of class). We can pass values during the time of construction as below: class-name ob-name(values); Or we may define a member function to accept data which can be called as below: class-name ob-name; ob-name.set(values); Where set is the member function of the class. But actually there is one more way to do so, yeah you guessed it right!, by overloading the parenthesis () operator. Parenthesis () operator like other operators is overloaded with the following prototype: ret-type operator ()(arg1, arg2,...); It is a unary operator hence the only argument passed to this function (implicitly) is this pointer. The argument list may contain any number of arguments as you wish to pass. The following example program illustrates the overloading of parenthesi