Liferay 6.0.5

com.liferay.portal.service
Interface OrganizationLocalService

All Known Implementing Classes:
OrganizationLocalServiceBaseImpl, OrganizationLocalServiceImpl, OrganizationLocalServiceWrapper

@Transactional(isolation=PORTAL,
               rollbackFor={PortalException.class,SystemException.class})
public interface OrganizationLocalService

The interface for the organization local service.

Never modify or reference this interface directly. Always use OrganizationLocalServiceUtil to access the organization local service. Add custom service methods to OrganizationLocalServiceImpl and rerun ServiceBuilder to automatically copy the method declarations to this interface.

This is a local service. Methods of this service will not have security checks based on the propagated JAAS credentials because this service can only be accessed from within the same VM.

See Also:
OrganizationLocalServiceUtil, OrganizationLocalServiceBaseImpl, OrganizationLocalServiceImpl
ServiceBuilder generated this class. Modifications in this class will be overwritten the next time is generated.

Method Summary
 void addGroupOrganizations(long groupId, long[] organizationIds)
           
 Organization addOrganization(long userId, long parentOrganizationId, String name, String type, boolean recursable, long regionId, long countryId, int statusId, String comments, ServiceContext serviceContext)
           
 Organization addOrganization(Organization organization)
          Adds the organization to the database.
 void addOrganizationResources(long userId, Organization organization)
           
 void addPasswordPolicyOrganizations(long passwordPolicyId, long[] organizationIds)
           
 Organization createOrganization(long organizationId)
          Creates a new organization with the primary key.
 void deleteLogo(long organizationId)
           
 void deleteOrganization(long organizationId)
          Deletes the organization with the primary key from the database.
 void deleteOrganization(Organization organization)
          Deletes the organization from the database.
 List dynamicQuery(DynamicQuery dynamicQuery)
          Performs a dynamic query on the database and returns the matching rows.
 List dynamicQuery(DynamicQuery dynamicQuery, int start, int end)
          Performs a dynamic query on the database and returns a range of the matching rows.
 List dynamicQuery(DynamicQuery dynamicQuery, int start, int end, OrderByComparator orderByComparator)
          Performs a dynamic query on the database and returns an ordered range of the matching rows.
 long dynamicQueryCount(DynamicQuery dynamicQuery)
          Counts the number of rows that match the dynamic query.
 List<Organization> getGroupOrganizations(long groupId)
           
 Organization getOrganization(long organizationId)
          Gets the organization with the primary key.
 Organization getOrganization(long companyId, String name)
           
 long getOrganizationId(long companyId, String name)
           
 List<Organization> getOrganizations(int start, int end)
          Gets a range of all the organizations.
 List<Organization> getOrganizations(long[] organizationIds)
           
 int getOrganizationsCount()
          Gets the number of organizations.
 List<Organization> getParentOrganizations(long organizationId)
           
 List<Organization> getSuborganizations(List<Organization> organizations)
           
 List<Organization> getSubsetOrganizations(List<Organization> allOrganizations, List<Organization> availableOrganizations)
           
 List<Organization> getUserOrganizations(long userId)
           
 List<Organization> getUserOrganizations(long userId, boolean inheritUserGroups)
           
 List<Organization> getUserOrganizations(long userId, boolean inheritUserGroups, int start, int end)
           
 List<Organization> getUserOrganizations(long userId, int start, int end)
           
 int getUserOrganizationsCount(long userId)
           
 boolean hasGroupOrganization(long groupId, long organizationId)
           
 boolean hasPasswordPolicyOrganization(long passwordPolicyId, long organizationId)
           
 boolean hasUserOrganization(long userId, long organizationId)
           
 boolean hasUserOrganization(long userId, long organizationId, boolean inheritSuborganizations, boolean inheritUserGroups, boolean includeSpecifiedOrganization)
           
 void rebuildTree(long companyId, boolean force)
           
 Hits search(long companyId, long parentOrganizationId, String keywords, LinkedHashMap<String,Object> params, int start, int end, Sort sort)
           
 List<Organization> search(long companyId, long parentOrganizationId, String keywords, String type, Long regionId, Long countryId, LinkedHashMap<String,Object> params, int start, int end)
           
 List<Organization> search(long companyId, long parentOrganizationId, String keywords, String type, Long regionId, Long countryId, LinkedHashMap<String,Object> params, int start, int end, OrderByComparator obc)
           
 List<Organization> search(long companyId, long parentOrganizationId, String name, String type, String street, String city, String zip, Long regionId, Long countryId, LinkedHashMap<String,Object> params, boolean andOperator, int start, int end)
           
 List<Organization> search(long companyId, long parentOrganizationId, String name, String type, String street, String city, String zip, Long regionId, Long countryId, LinkedHashMap<String,Object> params, boolean andOperator, int start, int end, OrderByComparator obc)
           
 Hits search(long companyId, long parentOrganizationId, String name, String type, String street, String city, String zip, String region, String country, LinkedHashMap<String,Object> params, boolean andSearch, int start, int end, Sort sort)
           
 int searchCount(long companyId, long parentOrganizationId, String keywords, String type, Long regionId, Long countryId, LinkedHashMap<String,Object> params)
           
 int searchCount(long companyId, long parentOrganizationId, String name, String type, String street, String city, String zip, Long regionId, Long countryId, LinkedHashMap<String,Object> params, boolean andOperator)
           
 void setGroupOrganizations(long groupId, long[] organizationIds)
           
 void unsetGroupOrganizations(long groupId, long[] organizationIds)
           
 void unsetPasswordPolicyOrganizations(long passwordPolicyId, long[] organizationIds)
           
 void updateAsset(long userId, Organization organization, long[] assetCategoryIds, String[] assetTagNames)
           
 Organization updateOrganization(long companyId, long organizationId, long parentOrganizationId, String name, String type, boolean recursable, long regionId, long countryId, int statusId, String comments, ServiceContext serviceContext)
           
 Organization updateOrganization(Organization organization)
          Updates the organization in the database.
 Organization updateOrganization(Organization organization, boolean merge)
          Updates the organization in the database.
 

Method Detail

addOrganization

Organization addOrganization(Organization organization)
                             throws SystemException
Adds the organization to the database. Also notifies the appropriate model listeners.

Parameters:
organization - the organization to add
Returns:
the organization that was added
Throws:
SystemException - if a system exception occurred

createOrganization

Organization createOrganization(long organizationId)
Creates a new organization with the primary key. Does not add the organization to the database.

Parameters:
organizationId - the primary key for the new organization
Returns:
the new organization

deleteOrganization

void deleteOrganization(long organizationId)
                        throws PortalException,
                               SystemException
Deletes the organization with the primary key from the database. Also notifies the appropriate model listeners.

Parameters:
organizationId - the primary key of the organization to delete
Throws:
PortalException - if a organization with the primary key could not be found
SystemException - if a system exception occurred

deleteOrganization

void deleteOrganization(Organization organization)
                        throws SystemException
Deletes the organization from the database. Also notifies the appropriate model listeners.

Parameters:
organization - the organization to delete
Throws:
SystemException - if a system exception occurred

dynamicQuery

List dynamicQuery(DynamicQuery dynamicQuery)
                  throws SystemException
Performs a dynamic query on the database and returns the matching rows.

Parameters:
dynamicQuery - the dynamic query to search with
Returns:
the matching rows
Throws:
SystemException - if a system exception occurred

dynamicQuery

List dynamicQuery(DynamicQuery dynamicQuery,
                  int start,
                  int end)
                  throws SystemException
Performs a dynamic query on the database and returns a range of the matching rows.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Parameters:
dynamicQuery - the dynamic query to search with
start - the lower bound of the range of model instances to return
end - the upper bound of the range of model instances to return (not inclusive)
Returns:
the range of matching rows
Throws:
SystemException - if a system exception occurred

dynamicQuery

List dynamicQuery(DynamicQuery dynamicQuery,
                  int start,
                  int end,
                  OrderByComparator orderByComparator)
                  throws SystemException
Performs a dynamic query on the database and returns an ordered range of the matching rows.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Parameters:
dynamicQuery - the dynamic query to search with
start - the lower bound of the range of model instances to return
end - the upper bound of the range of model instances to return (not inclusive)
orderByComparator - the comparator to order the results by
Returns:
the ordered range of matching rows
Throws:
SystemException - if a system exception occurred

dynamicQueryCount

long dynamicQueryCount(DynamicQuery dynamicQuery)
                       throws SystemException
Counts the number of rows that match the dynamic query.

Parameters:
dynamicQuery - the dynamic query to search with
Returns:
the number of rows that match the dynamic query
Throws:
SystemException - if a system exception occurred

getOrganization

@Transactional(propagation=SUPPORTS,
               readOnly=true)
Organization getOrganization(long organizationId)
                             throws PortalException,
                                    SystemException
Gets the organization with the primary key.

Parameters:
organizationId - the primary key of the organization to get
Returns:
the organization
Throws:
PortalException - if a organization with the primary key could not be found
SystemException - if a system exception occurred

getOrganizations

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<Organization> getOrganizations(int start,
                                                                             int end)
                                    throws SystemException
Gets a range of all the organizations.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Parameters:
start - the lower bound of the range of organizations to return
end - the upper bound of the range of organizations to return (not inclusive)
Returns:
the range of organizations
Throws:
SystemException - if a system exception occurred

getOrganizationsCount

@Transactional(propagation=SUPPORTS,
               readOnly=true)
int getOrganizationsCount()
                          throws SystemException
Gets the number of organizations.

Returns:
the number of organizations
Throws:
SystemException - if a system exception occurred

updateOrganization

Organization updateOrganization(Organization organization)
                                throws SystemException
Updates the organization in the database. Also notifies the appropriate model listeners.

Parameters:
organization - the organization to update
Returns:
the organization that was updated
Throws:
SystemException - if a system exception occurred

updateOrganization

Organization updateOrganization(Organization organization,
                                boolean merge)
                                throws SystemException
Updates the organization in the database. Also notifies the appropriate model listeners.

Parameters:
organization - the organization to update
merge - whether to merge the organization with the current session. See BatchSession.update(com.liferay.portal.kernel.dao.orm.Session, com.liferay.portal.model.BaseModel, boolean) for an explanation.
Returns:
the organization that was updated
Throws:
SystemException - if a system exception occurred

addGroupOrganizations

void addGroupOrganizations(long groupId,
                           long[] organizationIds)
                           throws PortalException,
                                  SystemException
Throws:
PortalException
SystemException

addOrganization

Organization addOrganization(long userId,
                             long parentOrganizationId,
                             String name,
                             String type,
                             boolean recursable,
                             long regionId,
                             long countryId,
                             int statusId,
                             String comments,
                             ServiceContext serviceContext)
                             throws PortalException,
                                    SystemException
Throws:
PortalException
SystemException

addOrganizationResources

void addOrganizationResources(long userId,
                              Organization organization)
                              throws PortalException,
                                     SystemException
Throws:
PortalException
SystemException

addPasswordPolicyOrganizations

void addPasswordPolicyOrganizations(long passwordPolicyId,
                                    long[] organizationIds)
                                    throws SystemException
Throws:
SystemException

deleteLogo

void deleteLogo(long organizationId)
                throws PortalException,
                       SystemException
Throws:
PortalException
SystemException

getGroupOrganizations

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<Organization> getGroupOrganizations(long groupId)
                                         throws SystemException
Throws:
SystemException

getOrganization

@Transactional(propagation=SUPPORTS,
               readOnly=true)
Organization getOrganization(long companyId,
                                                                      String name)
                             throws PortalException,
                                    SystemException
Throws:
PortalException
SystemException

getOrganizationId

@Transactional(propagation=SUPPORTS,
               readOnly=true)
long getOrganizationId(long companyId,
                                                                String name)
                       throws SystemException
Throws:
SystemException

getOrganizations

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<Organization> getOrganizations(long[] organizationIds)
                                    throws PortalException,
                                           SystemException
Throws:
PortalException
SystemException

getParentOrganizations

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<Organization> getParentOrganizations(long organizationId)
                                          throws PortalException,
                                                 SystemException
Throws:
PortalException
SystemException

getSuborganizations

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<Organization> getSuborganizations(List<Organization> organizations)
                                       throws SystemException
Throws:
SystemException

getSubsetOrganizations

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<Organization> getSubsetOrganizations(List<Organization> allOrganizations,
                                                                                   List<Organization> availableOrganizations)

getUserOrganizations

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<Organization> getUserOrganizations(long userId)
                                        throws PortalException,
                                               SystemException
Throws:
PortalException
SystemException

getUserOrganizations

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<Organization> getUserOrganizations(long userId,
                                                                                 boolean inheritUserGroups)
                                        throws PortalException,
                                               SystemException
Throws:
PortalException
SystemException

getUserOrganizations

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<Organization> getUserOrganizations(long userId,
                                                                                 boolean inheritUserGroups,
                                                                                 int start,
                                                                                 int end)
                                        throws PortalException,
                                               SystemException
Throws:
PortalException
SystemException

getUserOrganizations

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<Organization> getUserOrganizations(long userId,
                                                                                 int start,
                                                                                 int end)
                                        throws PortalException,
                                               SystemException
Throws:
PortalException
SystemException

getUserOrganizationsCount

@Transactional(propagation=SUPPORTS,
               readOnly=true)
int getUserOrganizationsCount(long userId)
                              throws SystemException
Throws:
SystemException

hasGroupOrganization

@Transactional(propagation=SUPPORTS,
               readOnly=true)
boolean hasGroupOrganization(long groupId,
                                                                      long organizationId)
                             throws SystemException
Throws:
SystemException

hasPasswordPolicyOrganization

@Transactional(propagation=SUPPORTS,
               readOnly=true)
boolean hasPasswordPolicyOrganization(long passwordPolicyId,
                                                                               long organizationId)
                                      throws SystemException
Throws:
SystemException

hasUserOrganization

@Transactional(propagation=SUPPORTS,
               readOnly=true)
boolean hasUserOrganization(long userId,
                                                                     long organizationId)
                            throws SystemException
Throws:
SystemException

hasUserOrganization

@Transactional(propagation=SUPPORTS,
               readOnly=true)
boolean hasUserOrganization(long userId,
                                                                     long organizationId,
                                                                     boolean inheritSuborganizations,
                                                                     boolean inheritUserGroups,
                                                                     boolean includeSpecifiedOrganization)
                            throws PortalException,
                                   SystemException
Throws:
PortalException
SystemException

rebuildTree

void rebuildTree(long companyId,
                 boolean force)
                 throws SystemException
Throws:
SystemException

search

@Transactional(propagation=SUPPORTS,
               readOnly=true)
Hits search(long companyId,
                                                     long parentOrganizationId,
                                                     String keywords,
                                                     LinkedHashMap<String,Object> params,
                                                     int start,
                                                     int end,
                                                     Sort sort)
            throws SystemException
Throws:
SystemException

search

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<Organization> search(long companyId,
                                                                   long parentOrganizationId,
                                                                   String keywords,
                                                                   String type,
                                                                   Long regionId,
                                                                   Long countryId,
                                                                   LinkedHashMap<String,Object> params,
                                                                   int start,
                                                                   int end)
                          throws SystemException
Throws:
SystemException

search

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<Organization> search(long companyId,
                                                                   long parentOrganizationId,
                                                                   String keywords,
                                                                   String type,
                                                                   Long regionId,
                                                                   Long countryId,
                                                                   LinkedHashMap<String,Object> params,
                                                                   int start,
                                                                   int end,
                                                                   OrderByComparator obc)
                          throws SystemException
Throws:
SystemException

search

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<Organization> search(long companyId,
                                                                   long parentOrganizationId,
                                                                   String name,
                                                                   String type,
                                                                   String street,
                                                                   String city,
                                                                   String zip,
                                                                   Long regionId,
                                                                   Long countryId,
                                                                   LinkedHashMap<String,Object> params,
                                                                   boolean andOperator,
                                                                   int start,
                                                                   int end)
                          throws SystemException
Throws:
SystemException

search

@Transactional(propagation=SUPPORTS,
               readOnly=true)
List<Organization> search(long companyId,
                                                                   long parentOrganizationId,
                                                                   String name,
                                                                   String type,
                                                                   String street,
                                                                   String city,
                                                                   String zip,
                                                                   Long regionId,
                                                                   Long countryId,
                                                                   LinkedHashMap<String,Object> params,
                                                                   boolean andOperator,
                                                                   int start,
                                                                   int end,
                                                                   OrderByComparator obc)
                          throws SystemException
Throws:
SystemException

search

@Transactional(propagation=SUPPORTS,
               readOnly=true)
Hits search(long companyId,
                                                     long parentOrganizationId,
                                                     String name,
                                                     String type,
                                                     String street,
                                                     String city,
                                                     String zip,
                                                     String region,
                                                     String country,
                                                     LinkedHashMap<String,Object> params,
                                                     boolean andSearch,
                                                     int start,
                                                     int end,
                                                     Sort sort)
            throws SystemException
Throws:
SystemException

searchCount

@Transactional(propagation=SUPPORTS,
               readOnly=true)
int searchCount(long companyId,
                                                         long parentOrganizationId,
                                                         String keywords,
                                                         String type,
                                                         Long regionId,
                                                         Long countryId,
                                                         LinkedHashMap<String,Object> params)
                throws SystemException
Throws:
SystemException

searchCount

@Transactional(propagation=SUPPORTS,
               readOnly=true)
int searchCount(long companyId,
                                                         long parentOrganizationId,
                                                         String name,
                                                         String type,
                                                         String street,
                                                         String city,
                                                         String zip,
                                                         Long regionId,
                                                         Long countryId,
                                                         LinkedHashMap<String,Object> params,
                                                         boolean andOperator)
                throws SystemException
Throws:
SystemException

setGroupOrganizations

void setGroupOrganizations(long groupId,
                           long[] organizationIds)
                           throws PortalException,
                                  SystemException
Throws:
PortalException
SystemException

unsetGroupOrganizations

void unsetGroupOrganizations(long groupId,
                             long[] organizationIds)
                             throws PortalException,
                                    SystemException
Throws:
PortalException
SystemException

unsetPasswordPolicyOrganizations

void unsetPasswordPolicyOrganizations(long passwordPolicyId,
                                      long[] organizationIds)
                                      throws SystemException
Throws:
SystemException

updateAsset

void updateAsset(long userId,
                 Organization organization,
                 long[] assetCategoryIds,
                 String[] assetTagNames)
                 throws PortalException,
                        SystemException
Throws:
PortalException
SystemException

updateOrganization

Organization updateOrganization(long companyId,
                                long organizationId,
                                long parentOrganizationId,
                                String name,
                                String type,
                                boolean recursable,
                                long regionId,
                                long countryId,
                                int statusId,
                                String comments,
                                ServiceContext serviceContext)
                                throws PortalException,
                                       SystemException
Throws:
PortalException
SystemException

Liferay 6.0.5