Class UserAssociationStoreImpl

java.lang.Object
com.atlassian.jira.association.UserAssociationStoreImpl
All Implemented Interfaces:
UserAssociationStore

public class UserAssociationStoreImpl extends Object implements UserAssociationStore
Since:
v4.3
  • Constructor Details

  • Method Details

    • createAssociation

      public void createAssociation(String associationType, ApplicationUser user, org.ofbiz.core.entity.GenericValue sink)
      Description copied from interface: UserAssociationStore
      Creates an association between a user and a sink node.
      Specified by:
      createAssociation in interface UserAssociationStore
      Parameters:
      associationType - the Association type
      user - the user to associate with the sink node.
      sink - the sink node
    • createAssociation

      public void createAssociation(String associationType, ApplicationUser user, Issue sink)
      Description copied from interface: UserAssociationStore
      Creates an association between a user and a sink node.
      Specified by:
      createAssociation in interface UserAssociationStore
      Parameters:
      associationType - the Association type
      user - the user to associate with the sink node.
      sink - the sink node
    • createAssociation

      public void createAssociation(String associationType, String userName, String sinkNodeEntity, Long sinkNodeId)
      Description copied from interface: UserAssociationStore
      Creates an association between a user and a sink node.
      Specified by:
      createAssociation in interface UserAssociationStore
      Parameters:
      associationType - the Association type
      userName - the user name to associate with the sink node.
      sinkNodeEntity - the entity name of the sink node
      sinkNodeId - the id of the sink node entity
    • removeAssociation

      public void removeAssociation(String associationType, String userkey, String sinkNodeEntity, Long sinkNodeId)
      Description copied from interface: UserAssociationStore
      Removes an association between a user and a sink node.
      Specified by:
      removeAssociation in interface UserAssociationStore
      Parameters:
      associationType - the Association type
      userkey - the user to associate with the sink node.
      sinkNodeEntity - the entity name of the sink node
      sinkNodeId - the id of the sink node entity
    • removeAssociation

      public void removeAssociation(String associationType, ApplicationUser user, Issue sink)
      Description copied from interface: UserAssociationStore
      Removes an association between a user and a sink node.
      Specified by:
      removeAssociation in interface UserAssociationStore
      Parameters:
      associationType - the Association type
      user - the user to associate with the sink node.
      sink - the sink node
    • removeUserAssociationsFromUser

      public void removeUserAssociationsFromUser(String associationType, ApplicationUser user, String sinkNodeEntity)
      Description copied from interface: UserAssociationStore
      Removes all User Associations for this User of the given associationType
      Specified by:
      removeUserAssociationsFromUser in interface UserAssociationStore
      Parameters:
      associationType - the Association type
      user - the User
      sinkNodeEntity - The entity name of the sink node (eg "Issue").
    • removeUserAssociationsFromSink

      public void removeUserAssociationsFromSink(String sinkNodeEntity, Long sinkNodeId)
      Description copied from interface: UserAssociationStore
      Removes all User Associations for this Sink
      Specified by:
      removeUserAssociationsFromSink in interface UserAssociationStore
      Parameters:
      sinkNodeEntity - The entity name of the sink node (eg "Issue").
      sinkNodeId - the id of the sink node entity
    • associationExists

      public boolean associationExists(String associationType, ApplicationUser user, String sinkNodeEntity, Long sinkNodeId)
      Description copied from interface: UserAssociationStore
      Tests if the given association exists.
      Specified by:
      associationExists in interface UserAssociationStore
      Parameters:
      associationType - the Association type
      user - the User
      sinkNodeEntity - The entity name of the sink node (eg "Issue").
      sinkNodeId - The id of the sink node.
      Returns:
      true if the given association exists.
    • getUsersFromSink

      public List<ApplicationUser> getUsersFromSink(String associationType, org.ofbiz.core.entity.GenericValue sink)
      Description copied from interface: UserAssociationStore
      Finds and returns a list of Users associated with a given sink.
      Specified by:
      getUsersFromSink in interface UserAssociationStore
      Parameters:
      associationType - the Association type
      sink - the sink node
      Returns:
      a list of associated Users (never null)
    • getUsernamesFromSink

      public List<String> getUsernamesFromSink(String associationType, org.ofbiz.core.entity.GenericValue sink)
      Description copied from interface: UserAssociationStore
      Finds and returns a list of usernames associated with a given sink.
      Specified by:
      getUsernamesFromSink in interface UserAssociationStore
      Parameters:
      associationType - the Association type
      sink - the sink node
      Returns:
      a list of associated usernames (never null)
    • getUserkeysFromSink

      public Collection<String> getUserkeysFromSink(String associationType, String sinkNodeEntity, Long sinkNodeId)
      Description copied from interface: UserAssociationStore
      Finds and returns a list of userkeys associated with a given sink.
      Specified by:
      getUserkeysFromSink in interface UserAssociationStore
      Parameters:
      associationType - the Association type
      sinkNodeEntity - The entity name of the sink node (eg "Issue").
      sinkNodeId - The id of the sink node.
      Returns:
      a list of associated usernames (never null)
    • getUserkeysFromIssue

      public Collection<String> getUserkeysFromIssue(String associationType, Long issueId)
      Specified by:
      getUserkeysFromIssue in interface UserAssociationStore
    • getSinksFromUser

      public List<org.ofbiz.core.entity.GenericValue> getSinksFromUser(String associationType, ApplicationUser user, String sinkNodeEntity)
      Description copied from interface: UserAssociationStore
      Returns all the sinks that are associated with the given User.
      Specified by:
      getSinksFromUser in interface UserAssociationStore
      Parameters:
      associationType - the Association type
      user - the User
      sinkNodeEntity - The entity name of the sink node (eg "Issue").
      Returns:
      all the sinks that are associated with the given User.