com.atlassian.jira.issue.search
Class SearchRequestFactory

java.lang.Object
  |
  +--com.atlassian.jira.issue.search.SearchRequestFactory

public class SearchRequestFactory
extends java.lang.Object


Constructor Summary
SearchRequestFactory()
           
 
Method Summary
static SearchRequest getRequest(com.opensymphony.module.user.User searcher, java.lang.Long aLong)
          Find a search request given the searcher and the search request ID.
static SearchRequest getRequest(com.opensymphony.module.user.User author, java.lang.String name, com.opensymphony.module.user.User searcher)
          Find a search request given the author and the request name.
static java.util.List getRequests()
          Retrieves all the SearchRequest GenericValues
static java.util.List getRequests(com.opensymphony.module.user.User author)
          Retrieves all the SearchRequest GenericValues from a particular user
static SearchRequest loadByMap(java.util.Map fields, com.opensymphony.module.user.User searcher)
           
static void remove(com.opensymphony.module.user.User author, java.lang.Long id)
          Removes the SearchRequest GenericValue from the database based on its id and User
static org.ofbiz.core.entity.GenericValue save(SearchRequest request)
          Takes a searchrequest, user, name of search request and description and persists the XML representation of the SearchRequest object to the database along with the rest of the details
static org.ofbiz.core.entity.GenericValue update(SearchRequest request)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SearchRequestFactory

public SearchRequestFactory()
Method Detail

save

public static org.ofbiz.core.entity.GenericValue save(SearchRequest request)
                                               throws org.ofbiz.core.entity.GenericEntityException
Takes a searchrequest, user, name of search request and description and persists the XML representation of the SearchRequest object to the database along with the rest of the details

Parameters:
request - SearchResult that should be persisted
Returns:
GenericValue object that was persisted to the database
Throws:
org.ofbiz.core.entity.GenericEntityException

update

public static org.ofbiz.core.entity.GenericValue update(SearchRequest request)
                                                 throws org.ofbiz.core.entity.GenericEntityException
org.ofbiz.core.entity.GenericEntityException

remove

public static void remove(com.opensymphony.module.user.User author,
                          java.lang.Long id)
                   throws SearchException
Removes the SearchRequest GenericValue from the database based on its id and User

Parameters:
author - of the SearchRequest
id - of the search request to be removed from storage
Throws:
SearchException

getRequests

public static java.util.List getRequests()
                                  throws org.ofbiz.core.entity.GenericEntityException
Retrieves all the SearchRequest GenericValues

Returns:
Returns a list of searchRequest GenericValues
Throws:
org.ofbiz.core.entity.GenericEntityException

getRequests

public static java.util.List getRequests(com.opensymphony.module.user.User author)
                                  throws org.ofbiz.core.entity.GenericEntityException
Retrieves all the SearchRequest GenericValues from a particular user

Parameters:
author - to retrieve all the SearchRequests for
Returns:
Returns a list of searchRequest GenericValues
Throws:
org.ofbiz.core.entity.GenericEntityException

getRequest

public static SearchRequest getRequest(com.opensymphony.module.user.User author,
                                       java.lang.String name,
                                       com.opensymphony.module.user.User searcher)
                                throws org.ofbiz.core.entity.GenericEntityException
Find a search request given the author and the request name.

Returns:
The SearchRequest, or null if there is no matching request
Throws:
org.ofbiz.core.entity.GenericEntityException - If any exceptions occur finding the request

getRequest

public static SearchRequest getRequest(com.opensymphony.module.user.User searcher,
                                       java.lang.Long aLong)
                                throws org.ofbiz.core.entity.GenericEntityException
Find a search request given the searcher and the search request ID.

Returns:
The SearchRequest, or null if there is no matching request for this searcher.
Throws:
org.ofbiz.core.entity.GenericEntityException - If any exceptions occur finding the request

loadByMap

public static SearchRequest loadByMap(java.util.Map fields,
                                      com.opensymphony.module.user.User searcher)
                               throws org.ofbiz.core.entity.GenericEntityException
Parameters:
fields -
Returns:
Throws:
org.ofbiz.core.entity.GenericEntityException


Copyright © 2002-2003 Atlassian. All Rights Reserved.