org.opennms.web.notification.bobject
Class GroupTarget

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

public class GroupTarget
extends NotificationTarget

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

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
GroupTarget()
          Default Constructor
 
Method Summary
 void addUserTarget(UserTarget target)
          Adds a user target to this group target
 String getCommandName()
          Returns the command name for this target
 String getGroupName()
          Returns the userId for this target
 int getType()
          Returns the type of the target
 List<UserTarget> getUserTargets()
          Returns the list of UserTargets in this group target
 void setCommandName(String commandName)
          Sets the command name for this target
 void setGroupName(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

GroupTarget

public GroupTarget()
Default Constructor

Method Detail

setGroupName

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

Parameters:
name - the group name.

getGroupName

public String getGroupName()
Returns the userId for this target

Returns:
the group name.

setCommandName

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

Parameters:
commandName - the command name.

getCommandName

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

Returns:
the command name.

addUserTarget

public void addUserTarget(UserTarget target)
Adds a user target to this group target

Parameters:
target - a user target to be added.

getUserTargets

public List<UserTarget> getUserTargets()
Returns the list of UserTargets in this group target

Returns:
the list of user targets.

getType

public int getType()
Returns the type of the target

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


Copyright © 2009. All Rights Reserved.