InterviewSolution
Saved Bookmarks
| 1. |
Solve : Simple question :)? |
|
Answer» Hello all , could anybody help me understanding this "The Law of Demeter for functions requires that a method M of an object O may only invoke the methods of the following kinds of objects: 1. O itself 2. M's parameters 3. any objects created/instantiated within M 4. O's direct component objects simple example for each case ( case 1 , 2, 3 and 4 ) would do thank you this paragraph follows the above : "The basic idea is to avoid invoking methods of a member object that is returned by another method. When you do this, you make structural assumptions about the container object that may be likely to change. The container may later need to be modified to contain a different number of the CONTAINED objects, or it may end up being changed to contain another object which contains the original component object. If the "returned" object isn't a subpart of the object whose method was invoked, nor of some other object, then it typically is not a violation of LoD to invoke a method of the returned object (particularly if the object was created by the invoking method)." could you please help me understand this too... your help is highly appreciated WE don't do people's Comp Sci homework for them. IM a math major gradute, doing my master in computer science, this is NOT a homwork..im doing a reseach on the SoC ( seperation of concerns ) and came across LoD (law of demeter ) ..if you dont want to help..thats ok..just dont give me excuses LIKE "we dont do homework' ! plus .think about it! what kind of a silly homework would my question be ! This is not a masters level tutorial site. Read some of the other posts to get an idea of what type of question stands a good chance of being answered. And leave the attitude at the door. David Bock's "paper boy example" SEEMS to be the sort of thing you are looking for however. lol...the question i asked it NOT even A MASTER LEVEL DEAR... i dont wana LEAVE MY ATTITUDE AT THE DOOR...I WANA TAKE IT WITH ME WHEREVER I GO :p DO ME A FAVOR AND "KICK ME" OUT OF THIS FORUM ! IT SUCKS LOL..CANT EVEN ANSWER A SIMPLE QUESTION ! YOU GUYS ARE STUPID... GUESS THIS WILL BE MY LAST MESSAGE HERE..SO LET ME SAY "YOU SUCKKKKK,,:p" NO HARD FEELINGS...EIHHH ?:p///CIAOO...:pWith that attitude, you won't get any help. Quote GUESS THIS WILL BE MY LAST MESSAGE HEREFair enough. I'm sure someone like you can Google. Topic Closed. If the OP or anyone has any inquiries REGARDING this, please PM me or one of the moderators.Being the simple question that it is, I'm sure you'll have no trouble finding the answer yourself. |
|