org.opennms.web.notification.bobject
Class UserTarget

java.lang.Object
  extended by org.opennms.web.notification.bobject.NotificationTarget
      extended by org.opennms.web.notification.bobject.UserTarget

public class UserTarget
extends NotificationTarget

A NotificationTarget representing a user target parsed from the notifications xml file.

Version:
1.1.1.1
Author:
Jason Johns , OpenNMS

Field Summary
 
Fields inherited from class org.opennms.web.notification.bobject.NotificationTarget
TARGET_TYPE_GROUP, TARGET_TYPE_NOTIF, TARGET_TYPE_USER
 
Constructor Summary
UserTarget()
          Default Constructor
 
Method Summary
 Command getCommand()
          Returns the Command object for this target
 String getCommandName()
          Returns the command name for this target
 int getType()
          Returns the type of the target
 User getUser()
          Returns the User object for this target
 String getUserName()
          Returns the userId for this target
 void setCommand(Command command)
          Sets the Command object for this target
 void setCommandName(String commandName)
          Sets the command name for this target
 void setUser(User user)
          Sets the User object for this target
 void setUserName(String name)
          Sets the userId for this target
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UserTarget

public UserTarget()
Default Constructor

Method Detail

setUserName

public void setUserName(String name)
Sets the userId for this target

Parameters:
name - the username to be set.

getUserName

public String getUserName()
Returns the userId for this target

Returns:
the username.

setUser

public void setUser(User user)
Sets the User object for this target

Parameters:
user - the user object to be set.

getUser

public User getUser()
Returns the User object for this target

Returns:
the user object.

setCommandName

public void setCommandName(String commandName)
Sets the command name for this target

Parameters:
commandName - the command name to be set.

getCommandName

public String getCommandName()
Returns the command name for this target

Returns:
the command name.

setCommand

public void setCommand(Command command)
Sets the Command object for this target

Parameters:
command - the command to be set.

getCommand

public Command getCommand()
Returns the Command object for this target

Returns:
the command.

getType

public int getType()
Returns the type of the target

Specified by:
getType in class NotificationTarget
Returns:
the type, compare to NotificationTask.TARGET_TYPE_USER.


Copyright © 2009. All Rights Reserved.