com.atlassian.jira.issue.subscription
Interface SubscriptionManager

All Known Implementing Classes:
DefaultSubscriptionManager

public interface SubscriptionManager


Method Summary
 org.ofbiz.core.entity.GenericValue createSubscription(com.atlassian.crowd.embedded.api.User user, Long filterId, String groupName, Long period, Boolean emailOnEmpty)
           
 org.ofbiz.core.entity.GenericValue createSubscription(com.atlassian.crowd.embedded.api.User user, Long filterId, String groupName, org.quartz.Trigger trigger, Boolean emailOnEmpty)
          Creates a new subscription based on the passed in filter id and fired in accordance with the passed in trigger
 void deleteSubscription(Long subId)
           
 void deleteSubscriptionsForGroup(com.atlassian.crowd.embedded.api.Group group)
           
 void deleteSubscriptionsForUser(com.atlassian.crowd.embedded.api.User user)
           
 List<org.ofbiz.core.entity.GenericValue> getAllSubscriptions()
           
 List<org.ofbiz.core.entity.GenericValue> getAllSubscriptions(Long filterId)
           
 org.ofbiz.core.entity.GenericValue getSubscription(com.atlassian.crowd.embedded.api.User user, Long subId)
           
 org.ofbiz.core.entity.GenericValue getSubscriptionFromTriggerName(String triggerName)
           
 List<org.ofbiz.core.entity.GenericValue> getSubscriptions(com.atlassian.crowd.embedded.api.User user, Long filterId)
           
 org.quartz.Trigger getTriggerFromSubscription(org.ofbiz.core.entity.GenericValue subscription)
           
 boolean hasSubscription(com.atlassian.crowd.embedded.api.User user, Long filterId)
           
 void runSubscription(org.ofbiz.core.entity.GenericValue subId)
           
 void runSubscription(com.atlassian.crowd.embedded.api.User u, Long subId)
           
 void updateSubscription(com.atlassian.crowd.embedded.api.User user, Long subscriptionId, String groupName, org.quartz.Trigger trigger, Boolean emailOnEmpty)
           
 

Method Detail

hasSubscription

boolean hasSubscription(com.atlassian.crowd.embedded.api.User user,
                        Long filterId)
                        throws org.ofbiz.core.entity.GenericEntityException
Throws:
org.ofbiz.core.entity.GenericEntityException

getSubscription

org.ofbiz.core.entity.GenericValue getSubscription(com.atlassian.crowd.embedded.api.User user,
                                                   Long subId)
                                                   throws org.ofbiz.core.entity.GenericEntityException
Throws:
org.ofbiz.core.entity.GenericEntityException

getSubscriptions

List<org.ofbiz.core.entity.GenericValue> getSubscriptions(com.atlassian.crowd.embedded.api.User user,
                                                          Long filterId)
                                                          throws org.ofbiz.core.entity.GenericEntityException
Throws:
org.ofbiz.core.entity.GenericEntityException

createSubscription

org.ofbiz.core.entity.GenericValue createSubscription(com.atlassian.crowd.embedded.api.User user,
                                                      Long filterId,
                                                      String groupName,
                                                      Long period,
                                                      Boolean emailOnEmpty)

createSubscription

org.ofbiz.core.entity.GenericValue createSubscription(com.atlassian.crowd.embedded.api.User user,
                                                      Long filterId,
                                                      String groupName,
                                                      org.quartz.Trigger trigger,
                                                      Boolean emailOnEmpty)
Creates a new subscription based on the passed in filter id and fired in accordance with the passed in trigger

Parameters:
user - the current user performing this operation
filterId - Id of the filter subscribing to
groupName - Sent ot group
trigger - The trigger to store
emailOnEmpty - send email if filter returns no results
Returns:
GenericValue representing new subscription

deleteSubscription

void deleteSubscription(Long subId)
                        throws Exception
Throws:
Exception

runSubscription

void runSubscription(org.ofbiz.core.entity.GenericValue subId)
                     throws Exception
Throws:
Exception

runSubscription

void runSubscription(com.atlassian.crowd.embedded.api.User u,
                     Long subId)
                     throws Exception
Throws:
Exception

getSubscriptionFromTriggerName

org.ofbiz.core.entity.GenericValue getSubscriptionFromTriggerName(String triggerName)
                                                                  throws org.ofbiz.core.entity.GenericEntityException
Throws:
org.ofbiz.core.entity.GenericEntityException

getTriggerFromSubscription

org.quartz.Trigger getTriggerFromSubscription(org.ofbiz.core.entity.GenericValue subscription)
                                              throws org.quartz.SchedulerException
Throws:
org.quartz.SchedulerException

updateSubscription

void updateSubscription(com.atlassian.crowd.embedded.api.User user,
                        Long subscriptionId,
                        String groupName,
                        org.quartz.Trigger trigger,
                        Boolean emailOnEmpty)
                        throws DataAccessException
Parameters:
user - the current user performing this operation
subscriptionId - identifies the subscription to update
groupName - (optional) the name of the group to receive the email
trigger - The trigger to update the subscription with
Throws:
DataAccessException - if there is a problem persisting the data.

getAllSubscriptions

List<org.ofbiz.core.entity.GenericValue> getAllSubscriptions(Long filterId)

getAllSubscriptions

List<org.ofbiz.core.entity.GenericValue> getAllSubscriptions()

deleteSubscriptionsForUser

void deleteSubscriptionsForUser(com.atlassian.crowd.embedded.api.User user)
                                throws Exception
Throws:
Exception

deleteSubscriptionsForGroup

void deleteSubscriptionsForGroup(com.atlassian.crowd.embedded.api.Group group)
                                 throws Exception
Throws:
Exception


Copyright © 2002-2012 Atlassian. All Rights Reserved.