#125 MESSAGE: access to target and arguments

Next_Release
closed
David Ashley
Classes (154)
5
2012-08-14
2007-03-17
No

In notification patterns it may become important to be able to learn about the object and/or arguments the notification message is set up with.

Hence the request for an enhancement to the message class that allows access to target and argument.

---rony

Discussion

  • Rick McGuire
    Rick McGuire
    2007-03-17

    Logged In: YES
    user_id=1125291
    Originator: NO

    I'm not sure I understand what you're asking for with this RFE or the one about SEND and START. Can you give some usage scenario examples?

     
  • Rick McGuire
    Rick McGuire
    2007-03-17

    Logged In: YES
    user_id=1125291
    Originator: NO

    Ok, 3 methods have been added to the message class:

    target()

    Returns the message target object. This is either the target object specified on the NEW() method or an override object that was specified with SEND() or START().

    messagename()

    Returns the name of the message used by the message object.

    arguments()

    Returns a array of arguments that are passed to the method. If no arguments were specified, an empty array is returned.

    David, I'm assigning this to you because the docs also need updating.

     
  • Logged In: YES
    user_id=662126
    Originator: YES

    First of all: thank you very much for target(), messagename() and arguments()!

    Ad an example scenario where adding arguments to a notification message would be important: in a socket application the accepting of clients may be done asynchroneously for multiple clients; whenever a client gets accepted not only that fact is important (for which one would send/start off the received notification message objects), but also supplying the received client as an argument with those notifications messages, such that the receivers can get access to such freshly accepted clients.

     


Anonymous


Cancel   Add attachments