public interface SchemeManager
Modifier and Type | Field and Description |
---|---|
static String |
PROJECT_ASSOCIATION
The one and only "association type".
|
Modifier and Type | Method and Description |
---|---|
void |
addDefaultSchemeToProject(org.ofbiz.core.entity.GenericValue project)
Deprecated.
Use
addDefaultSchemeToProject(com.atlassian.jira.project.Project) instead. Since v5.0. |
void |
addDefaultSchemeToProject(Project project)
Adds the default scheme to a particular project
|
void |
addSchemeToProject(org.ofbiz.core.entity.GenericValue project,
org.ofbiz.core.entity.GenericValue scheme)
Deprecated.
Use
addSchemeToProject(com.atlassian.jira.project.Project, Scheme) instead. Since v5.0. |
void |
addSchemeToProject(Project project,
Scheme scheme)
Adds a scheme to a particular project
|
org.ofbiz.core.entity.GenericValue |
copyScheme(org.ofbiz.core.entity.GenericValue scheme)
Deprecated.
Use
copyScheme(Scheme) instead. Since v5.0. |
Scheme |
copyScheme(Scheme scheme)
Copys a scheme, giving the new scheme the same entities as the original one
|
org.ofbiz.core.entity.GenericValue |
createDefaultScheme()
Creates a default scheme, with an id of 0
|
org.ofbiz.core.entity.GenericValue |
createScheme(String name,
String description)
Deprecated.
Use
createSchemeObject(String, String) instead. Since v5.0. |
Scheme |
createSchemeAndEntities(Scheme scheme) |
org.ofbiz.core.entity.GenericValue |
createSchemeEntity(org.ofbiz.core.entity.GenericValue scheme,
SchemeEntity entity) |
Scheme |
createSchemeObject(String name,
String description)
Creates a new scheme
|
void |
deleteEntities(Iterable<Long> ids)
Deletes a collection of entities from the database.
|
void |
deleteEntity(Long id)
Deletes an entity with the given id from the database.
|
void |
deleteScheme(Long id)
Deletes a scheme from the database
|
List<Scheme> |
getAssociatedSchemes(boolean withEntitiesComparable)
Gets all schemes of this type in the database taht are associated with at least one project.
|
org.ofbiz.core.entity.GenericValue |
getDefaultScheme()
Deprecated.
Use
getDefaultSchemeObject() instead. Since v5.0. |
Scheme |
getDefaultSchemeObject()
Gets the default scheme.
|
List<org.ofbiz.core.entity.GenericValue> |
getEntities(org.ofbiz.core.entity.GenericValue scheme)
Get all Scheme entity records for a particular scheme
|
List<org.ofbiz.core.entity.GenericValue> |
getEntities(org.ofbiz.core.entity.GenericValue scheme,
Long entityTypeId) |
List<org.ofbiz.core.entity.GenericValue> |
getEntities(org.ofbiz.core.entity.GenericValue scheme,
Long entityTypeId,
String parameter) |
List<org.ofbiz.core.entity.GenericValue> |
getEntities(org.ofbiz.core.entity.GenericValue scheme,
String entityTypeId) |
List<org.ofbiz.core.entity.GenericValue> |
getEntities(org.ofbiz.core.entity.GenericValue scheme,
String type,
Long entityTypeId) |
List<org.ofbiz.core.entity.GenericValue> |
getEntities(String type,
String parameter)
Get all entity records with a particular parameter
|
List<org.ofbiz.core.entity.GenericValue> |
getEntitiesByIds(List<Long> ids)
Get all entity records for a list of ids
|
org.ofbiz.core.entity.GenericValue |
getEntity(Long id)
Gets a scheme entity based on the id of the entity
|
Collection<com.atlassian.crowd.embedded.api.Group> |
getGroups(Long permissionId,
org.ofbiz.core.entity.GenericValue project)
Deprecated.
Use
getGroups(Long, com.atlassian.jira.project.Project) instead. Since v5.0. |
Collection<com.atlassian.crowd.embedded.api.Group> |
getGroups(Long permissionId,
Project project) |
List<Project> |
getProjects(Scheme scheme)
Gets all projects that are associated with that scheme
|
org.ofbiz.core.entity.GenericValue |
getScheme(Long id)
Deprecated.
Use
getSchemeObject(Long) instead. Since v5.0. |
org.ofbiz.core.entity.GenericValue |
getScheme(String name)
Deprecated.
use
getSchemeObject(String) instead. Since 2010. |
Scheme |
getSchemeFor(Project project)
Get the scheme of this type attached to the given project.
|
Long |
getSchemeIdFor(Project project)
Get the scheme of this type attached to the given project.
|
Scheme |
getSchemeObject(Long id)
Gets a scheme by id from the database.
|
Scheme |
getSchemeObject(String name)
Gets a scheme by name from the database.
|
List<Scheme> |
getSchemeObjects()
Gets all scheme objects in the database.
|
List<org.ofbiz.core.entity.GenericValue> |
getSchemes()
Deprecated.
use
getSchemeObjects() . Since 2010. |
List<org.ofbiz.core.entity.GenericValue> |
getSchemes(org.ofbiz.core.entity.GenericValue project)
Deprecated.
Use
getSchemeFor(com.atlassian.jira.project.Project) instead. Since v5.0. |
List<Scheme> |
getUnassociatedSchemes()
Will return all @link Scheme objects that are not currently associated with any projects.
|
Collection<ApplicationUser> |
getUsers(Long permissionId,
org.ofbiz.core.entity.GenericValue issueOrProject)
Deprecated.
Use
getUsers(Long, com.atlassian.jira.permission.PermissionContext) instead. Since 2006. |
Collection<ApplicationUser> |
getUsers(Long permissionId,
Issue issue) |
Collection<ApplicationUser> |
getUsers(Long permissionId,
PermissionContext ctx) |
Collection<ApplicationUser> |
getUsers(Long permissionId,
Project project) |
boolean |
removeEntities(org.ofbiz.core.entity.GenericValue scheme,
Long entityTypeId)
Deprecated.
Use
getEntities(org.ofbiz.core.entity.GenericValue, Long) and deleteEntity(Long) instead. Since v5.0. |
boolean |
removeEntities(String type,
String parameter)
Removes all scheme entities with this parameter and type
|
void |
removeSchemesFromProject(org.ofbiz.core.entity.GenericValue project)
Deprecated.
Use
removeSchemesFromProject(com.atlassian.jira.project.Project) instead. Since v4.4. |
void |
removeSchemesFromProject(Project project)
Removes all schemes from a project
|
boolean |
schemeExists(String name)
Determine if the given scheme name exists.
|
void |
swapParameterForEntitiesOfType(String type,
String parameter,
String resultingParameter)
Swaps all parameters of entities with the given type scheme to the given resulting parameter
|
void |
updateScheme(org.ofbiz.core.entity.GenericValue entity)
Deprecated.
Use
updateScheme(Scheme) instead. Since v5.0. |
void |
updateScheme(Scheme scheme)
Updates any changes to the scheme object.
|
static final String PROJECT_ASSOCIATION
org.ofbiz.core.entity.GenericValue getScheme(Long id) throws org.ofbiz.core.entity.GenericEntityException
getSchemeObject(Long)
instead. Since v5.0.id
- Id of the schemeorg.ofbiz.core.entity.GenericEntityException
- DB ErrorScheme getSchemeObject(Long id) throws DataAccessException
id
- the id of the scheme to get.DataAccessException
- if there is trouble retrieving from the database.List<org.ofbiz.core.entity.GenericValue> getSchemes() throws org.ofbiz.core.entity.GenericEntityException
getSchemeObjects()
. Since 2010.org.ofbiz.core.entity.GenericEntityException
- DB ErrorList<Scheme> getSchemeObjects() throws DataAccessException
DataAccessException
- if the database is down or equivalent.List<Scheme> getAssociatedSchemes(boolean withEntitiesComparable)
withEntitiesComparable
- if true then the scheme entites will be logically comparable (they will not include
database specific information such as the pk id). Otherwise the object will be a full representation of the row
stored in the database.org.ofbiz.core.entity.GenericValue getScheme(String name) throws org.ofbiz.core.entity.GenericEntityException
getSchemeObject(String)
instead. Since 2010.name
- the name of the scheme to get.org.ofbiz.core.entity.GenericEntityException
- DB errorScheme getSchemeObject(String name) throws DataAccessException
name
- the name of the scheme to get.DataAccessException
- if there is trouble retrieving from the database.List<org.ofbiz.core.entity.GenericValue> getSchemes(org.ofbiz.core.entity.GenericValue project) throws org.ofbiz.core.entity.GenericEntityException
getSchemeFor(com.atlassian.jira.project.Project)
instead. Since v5.0.project
- The project that the schemes are attached toorg.ofbiz.core.entity.GenericEntityException
- If a DB error occurs@Nullable Scheme getSchemeFor(Project project)
project
- The projectgetSchemeIdFor(Project)
@Nullable Long getSchemeIdFor(Project project)
project
- The projectgetSchemeFor(Project)
boolean schemeExists(String name) throws org.ofbiz.core.entity.GenericEntityException
name
- The name of the schemeorg.ofbiz.core.entity.GenericEntityException
- If a DB error occurs@Deprecated org.ofbiz.core.entity.GenericValue createScheme(String name, String description) throws org.ofbiz.core.entity.GenericEntityException
createSchemeObject(String, String)
instead. Since v5.0.name
- The name of the new schemedescription
- The description of the new schemeorg.ofbiz.core.entity.GenericEntityException
- If a DB error occursScheme createSchemeObject(String name, String description)
name
- The name of the new schemedescription
- The description of the new schemeScheme createSchemeAndEntities(Scheme scheme) throws DataAccessException
DataAccessException
org.ofbiz.core.entity.GenericValue getEntity(Long id) throws org.ofbiz.core.entity.GenericEntityException
id
- The id of the entityorg.ofbiz.core.entity.GenericEntityException
- If a DB error occursList<org.ofbiz.core.entity.GenericValue> getEntities(org.ofbiz.core.entity.GenericValue scheme) throws org.ofbiz.core.entity.GenericEntityException
scheme
- The scheme that the entities belong toorg.ofbiz.core.entity.GenericEntityException
- If a DB error occursList<org.ofbiz.core.entity.GenericValue> getEntities(org.ofbiz.core.entity.GenericValue scheme, Long entityTypeId) throws org.ofbiz.core.entity.GenericEntityException
org.ofbiz.core.entity.GenericEntityException
List<org.ofbiz.core.entity.GenericValue> getEntities(org.ofbiz.core.entity.GenericValue scheme, String entityTypeId) throws org.ofbiz.core.entity.GenericEntityException
org.ofbiz.core.entity.GenericEntityException
List<org.ofbiz.core.entity.GenericValue> getEntities(org.ofbiz.core.entity.GenericValue scheme, Long entityTypeId, String parameter) throws org.ofbiz.core.entity.GenericEntityException
org.ofbiz.core.entity.GenericEntityException
List<org.ofbiz.core.entity.GenericValue> getEntities(org.ofbiz.core.entity.GenericValue scheme, String type, Long entityTypeId) throws org.ofbiz.core.entity.GenericEntityException
org.ofbiz.core.entity.GenericEntityException
void updateScheme(org.ofbiz.core.entity.GenericValue entity) throws org.ofbiz.core.entity.GenericEntityException
updateScheme(Scheme)
instead. Since v5.0.entity
- The modified schemeorg.ofbiz.core.entity.GenericEntityException
- If a DB error occursvoid updateScheme(Scheme scheme)
scheme
- The modified scheme objectvoid deleteScheme(Long id) throws org.ofbiz.core.entity.GenericEntityException
id
- Id of the scheme to be deletedorg.ofbiz.core.entity.GenericEntityException
- If a DB error occursvoid addSchemeToProject(org.ofbiz.core.entity.GenericValue project, org.ofbiz.core.entity.GenericValue scheme) throws org.ofbiz.core.entity.GenericEntityException
addSchemeToProject(com.atlassian.jira.project.Project, Scheme)
instead. Since v5.0.project
- The project that the scheme is to be added toscheme
- The scheme to be addedorg.ofbiz.core.entity.GenericEntityException
- If a DB error occursvoid addSchemeToProject(Project project, Scheme scheme)
project
- The project that the scheme is to be added toscheme
- The scheme to be addedvoid removeSchemesFromProject(org.ofbiz.core.entity.GenericValue project) throws org.ofbiz.core.entity.GenericEntityException
removeSchemesFromProject(com.atlassian.jira.project.Project)
instead. Since v4.4.project
- The project that all schemes are to be deleted fromorg.ofbiz.core.entity.GenericEntityException
- If a DB error occursvoid removeSchemesFromProject(Project project)
project
- The project that all schemes are to be deleted fromorg.ofbiz.core.entity.GenericValue createSchemeEntity(org.ofbiz.core.entity.GenericValue scheme, SchemeEntity entity) throws org.ofbiz.core.entity.GenericEntityException
org.ofbiz.core.entity.GenericEntityException
void deleteEntity(Long id) throws org.ofbiz.core.entity.GenericEntityException
id
- The id of the entity to be deletedorg.ofbiz.core.entity.GenericEntityException
- If a DB error occursvoid deleteEntities(Iterable<Long> ids)
ids
- a collection entity ids to be deleted.org.ofbiz.core.entity.GenericEntityException
List<Project> getProjects(Scheme scheme)
scheme
- The scheme used to get all projectsProject
'sorg.ofbiz.core.entity.GenericValue createDefaultScheme() throws org.ofbiz.core.entity.GenericEntityException
org.ofbiz.core.entity.GenericEntityException
- If a DB error occursorg.ofbiz.core.entity.GenericValue getDefaultScheme() throws org.ofbiz.core.entity.GenericEntityException
getDefaultSchemeObject()
instead. Since v5.0.This does not work for the Default Notification scheme as it does not have an id of 0.
org.ofbiz.core.entity.GenericEntityException
- If a DB error occursScheme getDefaultSchemeObject()
This does not work for the Default Notification scheme as it does not have an id of 0.
void addDefaultSchemeToProject(org.ofbiz.core.entity.GenericValue project) throws org.ofbiz.core.entity.GenericEntityException
addDefaultSchemeToProject(com.atlassian.jira.project.Project)
instead. Since v5.0.project
- The project that the scheme is to be added toorg.ofbiz.core.entity.GenericEntityException
- If a DB error occursvoid addDefaultSchemeToProject(Project project)
project
- The project that the scheme is to be added toorg.ofbiz.core.entity.GenericValue copyScheme(org.ofbiz.core.entity.GenericValue scheme) throws org.ofbiz.core.entity.GenericEntityException
copyScheme(Scheme)
instead. Since v5.0.scheme
- The permission scheme to be copiedorg.ofbiz.core.entity.GenericEntityException
- If a DB error occursScheme copyScheme(Scheme scheme)
scheme
- The permission scheme to be copiedboolean removeEntities(org.ofbiz.core.entity.GenericValue scheme, Long entityTypeId) throws RemoveException
getEntities(org.ofbiz.core.entity.GenericValue, Long)
and deleteEntity(Long)
instead. Since v5.0.scheme
- to remove entites from must NOT be nullentityTypeId
- to removeRemoveException
- if the delete fails (DB error)List<org.ofbiz.core.entity.GenericValue> getEntities(String type, String parameter) throws org.ofbiz.core.entity.GenericEntityException
type
- The type of entity you wish to retrieve, eg 'user', 'group', 'projectrole'parameter
- The parameter in the entityorg.ofbiz.core.entity.GenericEntityException
- If a DB error occursboolean removeEntities(String type, String parameter) throws RemoveException
type
- the 'type' of entity you are deleting, eg 'group', 'user', 'projectrole'parameter
- must NOT be nullRemoveException
- if the delete fails (DB error)void swapParameterForEntitiesOfType(String type, String parameter, String resultingParameter)
type
- the 'type' of entity you are swapping, eg 'group', 'user', 'projectrole'parameter
- must NOT be nullRemoveException
- if the swap fails (DB error)Collection<com.atlassian.crowd.embedded.api.Group> getGroups(Long permissionId, org.ofbiz.core.entity.GenericValue project)
getGroups(Long, com.atlassian.jira.project.Project)
instead. Since v5.0.Collection<com.atlassian.crowd.embedded.api.Group> getGroups(Long permissionId, Project project)
Collection<ApplicationUser> getUsers(Long permissionId, Project project)
Collection<ApplicationUser> getUsers(Long permissionId, Issue issue)
@Deprecated Collection<ApplicationUser> getUsers(Long permissionId, org.ofbiz.core.entity.GenericValue issueOrProject)
getUsers(Long, com.atlassian.jira.permission.PermissionContext)
instead. Since 2006.Collection<ApplicationUser> getUsers(Long permissionId, PermissionContext ctx)
List<Scheme> getUnassociatedSchemes() throws DataAccessException
DataAccessException
- if the database is down or equivalent.List<org.ofbiz.core.entity.GenericValue> getEntitiesByIds(List<Long> ids)
ids
- a collection of entity ids that should be retrievedCopyright © 2002-2017 Atlassian. All Rights Reserved.