Since two decades author and leadership consultant Frank Kanu helps top managers and executives to improve success ratios and productivity.
 About Frank Kanu  |  Testimonials  |  Order Books  |  Free Articles  |  Press  |  Excellence in Leadership  |  Genius One

Genius One Inc., Smart Solutions for Growth

Frank Uncovers Excellence in Leadership

Posts

Delegation

© Copyright Frank D. Kanu 2000-2008

Delegation:
Passing a message from one object to another; the first object delegates the responsibility to the second object

For every event there will be a listener to which the event will be passed; thus the name Delegation Model/Pattern. Originally the name Command-Model was used, but it was thought that is does not match to closely the functionality of it.

Delegation
Delegate pattern are a big part of OS, like NeXTSATEP, OPENSTEP and Mac OS X

A delegate can implement methods, but that is not a must. Does an event arrives and the object knows a delegate, which does have the method implemented then it does call a method directly or better sends a message to the delegate. The Delegate pattern has many similarities with the Goal or Reducer pattern.

Another example which matches the delegation pattern is the collection. Collections in JDK 1.2 are not thread safe. To avoid the need of synchronizing all manipulations to the collection there are some methods to make an un-sychronized collection synchronized:


    static Collection synchronizedCollection(Collection c)
    static List synchronizedList(List list)
    static Map synchronizedMap(Map m)
    static Set synchronizedSet(Set s)
    static SortedMap synchronizedSortedMap(SortedMap m)
    static SortedSet synchronizedSortedSet(SortedSet s)



In the OO programming world there are two different ways of re-using code: inheritance and delegation. This becomes a design pattern when an object delegates work which should have done by itself. In that case it makes the most sense to force delegation and use the delegate pattern. A perfect example are classes with identical functionality in them, but the classes do not belong to the same family, eg classes from the swing toolkit.

class diagram

Literature:
Fowler, Martin Refactoring - Improving the Design of Existing Code
Blair, G.S.; Gallagher, J.J.; Malik, J.: Genericity vs. Inheritance vs. Delegation vs. Conformance vs …. In: Journal of Object-Oriented Programming. Sep./Oct., 1989, S. xx-xx
Booch, G.: Object-Oriented Analysis and Design with Applications. 2. Aufl., Redwood City 1994
Frank, U.: MEMO: A Tool Supported Methodology for Analyzing and (Re-) Designing Business Information Systems. In: Ege, R.; Singh, M.; Meyer, B. (Ed.): Technology of Object-Oriented Languages and Systems. Englewood Cliffs 1994, S. 367-380
Gamma, E.; Helm, R.; Johnson, R.; Vlissides, J.: Design Patterns. Elements of Reusable Object-Oriented Software. Reading/Mass. etc.: Addison-Wesley 1995
Jacobson, I.; Christerson, M.; Jonsson, P.; Overgaard, G.: Object-Oriented Engineering. A Use Case Driven Approach. Reading/Mass. 1992
Johnson, R.E.; Zweig, J.: Delegation in C++. In: Journal of Object-Oriented Programming. Vol. 4, No. 11, S. 22-35
Kathuria, R. and Subramaniam, V.: Assimilation: A New and Necessary Concept for an Object Model. REPORT ON OBJECT ANALYSIS & DESIGN, Vol. 2, No. 5, 1996, S. 36-39
Lieberman, H.: Using prototypical objects to implement shared behavior in object-oriented systems. In: OOPSLA, 1986, S. 214-223
Kim, W.; Lochovsky, F. (Hg.) Object-Oriented Concepts, Applications, and Databases. New York 1989
Rumbaugh, J. et al.: Object Oriented Modeling and Design. Englewood Cliffs, NJ 1993
Sciore E.: Object specialization. In: ACM Transactions on Office Information Systems, Vol. xx, No. xx, 1989, S.
Smith, R.B.; Ungar, D.: Programming as an Experience. The Inspiration for Self. In: Proceedings of the ECOOP 95
Stein, L.A.: Delegation is Inheritance; oopsla, 1987

Tags:
assimilation  business information systems  c static  code inheritance  collection c  delegate  delegates  delegation  delegation model  design  design pattern  design patterns  driven approach  ege  martin fowler  functionality  jdk  listener  match  method implemented  model report  object model  object oriented analysis  object oriented languages  object oriented programming  object oriented software  oo programming  programming world  reading mass  refactoring  reusable object oriented software  static collection  swing toolkit  synchronized  synchronizing  two different ways
 Technorati (All Links are external): assimilation  business information systems  c static  code inheritance  collection c  delegate  delegates  delegation  delegation model  design  design pattern  design patterns  driven approach  ege  martin fowler  functionality  jdk  listener  match  method implemented  model report  object model  object oriented analysis  object oriented languages  object oriented programming  object oriented software  oo programming  programming world  reading mass  refactoring  reusable object oriented software  static collection  swing toolkit  synchronized  synchronizing  two different ways  it
 
Digg  del.icio.us  StumbleUpon  Technorati  Reddit This blog-entry is protected by a digital fingerprint:785273ed81985582c8a1be62f78c9459
 
  • Frank Kanu on Thursday, September 2nd, 2004 @ 10:00
  • Filed under IT


You can follow responses to this entry through the RSS 2.0 feed.

Readers, who enjoyed reading this posting, also read:
  • What is delegation?
  • Delegation Is Good Management
  • Management by Decision Rules
  • Management by Delegation
  • The Harzburger Model

Because I value your thoughtful opinions, I encourage you to add them.

Please leave your Response right here:




XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>



Please do not be offended if I edit your response for clarity or to keep out questionable matters, however, and I may even delete off-topic responses.

Archives and Links




« Normal forms     quotes from Friedrich Nietzche »


  • Tags
    • blog
      confucius
      decisions
      e book
      education
      failure
      few days
      followers
      job
      kanu
      leader
      leaders
      leadership skills
      love
      mail
      manager
      managers
      mistakes
      money
      president bush
      programmers
      questions
      start leading
      stop telling
      success

    • Tags sorted alphabetically
    • Tags sorted numerically
  • Categories
    • Business
      • Case Studies
      • Negotiations
    • Cooking
    • Definitions
    • Ethics
    • Events
    • Frank Kanu
    • General
      • Daily Question
      • Quote of the Day
      • Weekly Poll
    • IT
      • Code review
    • Leadership
    • Management
      • Teams
    • Motivation
    • Politics
    • Something funny
    • Stop Telling… Start Leading!
  • Random Posts
    • - Be Aware of Others—Show That You Care
    • - CIOs on the Board
    • - A stupid Tax?

    • blogmap
    • More about Frank
  • Links
    • Frank Kanu's Books
    • - Andy Coote
    • - Andy Wibbels
    • - Billy McDermott*s Blog
    • - Blogcritics
    • - dandrea projetos
    • - David Intersimone “David I”
    • - Derek Jones
    • - Develop Your Vision
    • - enhance your leadership skills
    • - Forbes.com
    • - Frank Kanu
    • - Frank Kanu’s article archive
    • - Genius One
    • - Handelsblatt
    • - Karel’s Legal Blog
    • - Managing Leadership
    • - New York Nitty-Gritty
    • - News for nerds, stuff that matters
    • - Philip Greenspun’s Weblog
    • - Practical Developmental Ideas
    • - Practical Solutions to Business Puzzles
    • - Recipes
    • - Rick Cooper, The PDA Pro
    • - Roberta Pili
    • - Sacred Cow Dung
    • - Savvy Intrapreneur
    • - Scrapbooker for hire
    • - Scrapbooking 4 others
    • - seth godin’s blog
    • - stop telling… start leading!
    • - The Art of Managing People by Asking Questions
    • - The Washington Post
    • - TomPeters!
  • RSS Feed
    • Syndicate using RSS
    • The latest comments to all posts in RSS
  • Archives/Calendar
    • yearly archives
    • monthly archives
    • weekly archives
    • daily archives
    November 2008
    M T W T F S S
    « Oct    
     12
    3456789
    10111213141516
    17181920212223
    24252627282930
  • Blog Of The Day Awards Winner

If not otherwise stated - all postings © Frank D. Kanu. All rights reserved.

This blog is designed to provide accurate and authoritative information in regard to the subject matter covered.
If legal advice or other expert assistance is required, the services of a competent professional should be sought.



Genius One Inc. · USA
Fax: (509) 463-0129 · E-mail:
info@GeniusOne.com

 


Privacy Statement   Sitemap

 
Copyright © 2000-2008 Genius One Inc.
All rights reserved.
Reproduction or use in whole or part in any form or medium without written permission of Genius One Inc. is prohibited.
If parts or any part of these WebPages is judicially determined to be invalid, that invalidity will not affect the remaining part of these Pages.