net.wotonomy.foundation
Class NSNotification

java.lang.Object
  extended by net.wotonomy.foundation.NSNotification

public class NSNotification
extends java.lang.Object

An NSNotification is a generic message that can be dispatched by the NSNotificationCenter.

Version:
$Revision: 893 $
Author:
michael@mpowers.net, $Author: cgruber $

Field Summary
protected  java.lang.String name
           
protected  java.lang.Object object
           
static boolean showStack
           
protected  java.util.Map userInfo
           
 
Constructor Summary
NSNotification()
          Default constructor creates a new notification with no name, object, or info dictionary.
NSNotification(java.lang.String aName, java.lang.Object anObject)
          Constructor specifying name and object.
NSNotification(java.lang.String aName, java.lang.Object anObject, java.util.Map aUserInfo)
          Constructor specifying name, object, and a Map containing application specific information.
 
Method Summary
 java.lang.String name()
          Returns the name of this notification.
 java.lang.Object object()
          Returns the object of this notification.
 java.lang.Throwable stackTrace()
          Returns the stack trace when this notification was generated, or null if showStack is false, which is the default.
 java.lang.String toString()
          Returns a human-readable string representation.
 NSDictionary userInfo()
          Returns an NSDictionary that is a copy of the map containing application specific information relating to this notification, or null if no such data exists.
 java.util.Map userInfoMap()
          Returns a Map containing application specific information relating to this notification, or null if no such data exists.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

showStack

public static boolean showStack

name

protected java.lang.String name

object

protected java.lang.Object object

userInfo

protected java.util.Map userInfo
Constructor Detail

NSNotification

public NSNotification()
Default constructor creates a new notification with no name, object, or info dictionary.


NSNotification

public NSNotification(java.lang.String aName,
                      java.lang.Object anObject)
Constructor specifying name and object.


NSNotification

public NSNotification(java.lang.String aName,
                      java.lang.Object anObject,
                      java.util.Map aUserInfo)
Constructor specifying name, object, and a Map containing application specific information.

Method Detail

name

public java.lang.String name()
Returns the name of this notification.


object

public java.lang.Object object()
Returns the object of this notification.


userInfo

public NSDictionary userInfo()
Returns an NSDictionary that is a copy of the map containing application specific information relating to this notification, or null if no such data exists.


userInfoMap

public java.util.Map userInfoMap()
Returns a Map containing application specific information relating to this notification, or null if no such data exists. Note: this method is not in the spec.


stackTrace

public java.lang.Throwable stackTrace()
Returns the stack trace when this notification was generated, or null if showStack is false, which is the default. NOTE: This method is not part of the specification.


toString

public java.lang.String toString()
Returns a human-readable string representation.

Overrides:
toString in class java.lang.Object


Copyright © 2006 null. All Rights Reserved.