|
-
November 18th, 2009, 04:06 PM
#1
Empty Constructors
Is anyone else bothered by this as much as I am? I hate them, they look like such a waste. When you have a base class that your inheriting from and it requires some arguments via its constructor but your derived class does not require anything upon construction, your required to use the derived classes constructor as a middle-man who's sole purpose in life is to just pass the arguments to the base class constructor, leaving you with an empty derived class constructor body.
This to me is a tragedy:
Code:
public class Manager : Employee
{
public Manager(string name)
: base(name) { }
}
They drive me insane sometimes to the point where Ill think of something, anything, to pass to the derived constructor to assign to a field, or call a function, or something just to make it do something other than act as a middle-man. Anyone else have this "disorder"? haha
R.I.P. 3.5" Floppy Drives
"I know not with what weapons World War III will be fought, but World War IV will be fought with sticks and stones." - Albert Einstein
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|