it.sistematica.isharedoc.service
Interface OrganizationService

All Known Implementing Classes:
OrganizationServiceImpl

public interface OrganizationService

The Interface OrganizationService.


Method Summary
 OrganizationUser addOrganizationUser(Organization organization, it.neverworks.security.User user)
          Adds the organization user.
 boolean canChangeFileConfidentialityLevel(CloudFile file)
          Can change file confidentiality level.
 boolean canChangeInstanceConfidentialityLevel(ItemInstance instance)
          Can change instance confidentiality level.
 void cloneOrganizationVersion(OrganizationVersion sourceVersion, OrganizationVersion targetVersion)
          Clone organization version.
 void copyUserProfile(it.neverworks.security.User source, it.neverworks.security.User target, Partition targetPartition, boolean cleanTarget, boolean copyProfileMbox, boolean copyProfileOrg, boolean copyProfileTeam, boolean copyProfileWf, boolean copyProfileSubscr, boolean copyProfileUsr)
          Copy user profile.
 it.neverworks.security.User findUserById(java.lang.String id)
          Find user by id.
 java.util.List<Organization> getActiveOrganizations()
          Gets the active organizations.
 OrganizationVersion getActiveOrganizationVersion()
          Gets the active organization version.
 java.util.List<Team> getActiveTeams()
          Gets the active teams.
 java.util.List<Organization> getAllOrganizations()
          Gets the all organizations.
 java.util.List<ConfidentialityLevel> getConfidentialityLevels()
          Gets the confidentiality levels.
 java.util.List<Organization> getMyActiveOrganizations()
          Gets the my active organizations.
 Organization getOrganizationBy(java.lang.String fieldName, java.lang.Object byValue)
          Gets the organization by.
 OrganizationUser getOrganizationUser(Organization organization, it.neverworks.security.User user)
          Gets the organization user.
 java.util.List<Organization> getUserActiveOrganizations(it.neverworks.security.User user)
          Gets the user active organizations.
 it.neverworks.security.User getUserByName(java.lang.String name)
          Gets the user by name.
 Organization getUserFirstOrganization(it.neverworks.security.User user)
          Gets the user first organization.
 void removeOrganization(Organization organization, Organization movePendingToOrganization, it.neverworks.security.User movePendingTasksToUser)
          Removes the organization.
 void removeOrganizationUser(OrganizationUser organizationUser, OrganizationUser movePendingToOrganizationUser)
          Removes the organization user.
 it.neverworks.security.User resolveAssigneeAssignment(ItemInstance instance, java.lang.String taskDefinitionKey)
          Resolve assignee assignment.
 it.neverworks.security.User resolveAssigneeAssignment(ItemInstance instance, java.lang.String taskDefinitionKey, Organization organization)
          Resolve assignee assignment.
 it.neverworks.security.User resolveAssigneeAssignmentInLane(ItemInstance instance, java.lang.String taskDefinitionKey, java.lang.String laneId)
          Resolve assignee assignment in lane.
 Organization resolveOrganizationId(java.lang.String organizationId)
          Resolve organization id.
 OrganizationUser resolveOrganizationUserId(java.lang.String organizationUserId)
          Resolve organization user id.
 Organization resolveOwnerAssignment(ItemInstance instance, java.lang.String taskDefinitionKey)
          Resolve owner assignment.
 Organization resolveOwnerAssignmentFirst(ItemInstance instance, java.lang.String taskDefinitionKey)
          Resolve owner assignment first.
 Organization resolveOwnerAssignmentInLane(ItemInstance instance, java.lang.String taskDefinitionKey, java.lang.String laneId)
          Resolve owner assignment in lane.
 java.util.List<OrganizationUser> resolveUsersWithFunction(Organization organization, java.lang.String function)
          Resolve users with function.
 void save(Organization organization)
          Save.
 

Method Detail

save

void save(Organization organization)
Save.

Parameters:
organization - the organization

cloneOrganizationVersion

void cloneOrganizationVersion(OrganizationVersion sourceVersion,
                              OrganizationVersion targetVersion)
Clone organization version.

Parameters:
sourceVersion - the source version
targetVersion - the target version

removeOrganization

void removeOrganization(Organization organization,
                        Organization movePendingToOrganization,
                        it.neverworks.security.User movePendingTasksToUser)
Removes the organization.

Parameters:
organization - the organization
movePendingToOrganization - the move pending to organization
movePendingTasksToUser - the move pending tasks to user

addOrganizationUser

OrganizationUser addOrganizationUser(Organization organization,
                                     it.neverworks.security.User user)
Adds the organization user.

Parameters:
organization - the organization
user - the user
Returns:
the organization user

removeOrganizationUser

void removeOrganizationUser(OrganizationUser organizationUser,
                            OrganizationUser movePendingToOrganizationUser)
Removes the organization user.

Parameters:
organizationUser - the organization user
movePendingToOrganizationUser - the move pending to organization user

findUserById

it.neverworks.security.User findUserById(java.lang.String id)
Find user by id.

Parameters:
id - the id
Returns:
the user

getUserByName

it.neverworks.security.User getUserByName(java.lang.String name)
Gets the user by name.

Parameters:
name - the name
Returns:
the user by name

getActiveOrganizationVersion

OrganizationVersion getActiveOrganizationVersion()
Gets the active organization version.

Returns:
the active organization version

resolveOrganizationId

Organization resolveOrganizationId(java.lang.String organizationId)
Resolve organization id.

Parameters:
organizationId - the organization id
Returns:
the organization

getOrganizationBy

Organization getOrganizationBy(java.lang.String fieldName,
                               java.lang.Object byValue)
Gets the organization by.

Parameters:
fieldName - the field name
byValue - the by value
Returns:
the organization by

getMyActiveOrganizations

java.util.List<Organization> getMyActiveOrganizations()
Gets the my active organizations.

Returns:
the my active organizations

getUserActiveOrganizations

java.util.List<Organization> getUserActiveOrganizations(it.neverworks.security.User user)
Gets the user active organizations.

Parameters:
user - the user
Returns:
the user active organizations

getUserFirstOrganization

Organization getUserFirstOrganization(it.neverworks.security.User user)
Gets the user first organization.

Parameters:
user - the user
Returns:
the user first organization

getActiveOrganizations

java.util.List<Organization> getActiveOrganizations()
Gets the active organizations.

Returns:
the active organizations

getAllOrganizations

java.util.List<Organization> getAllOrganizations()
Gets the all organizations.

Returns:
the all organizations

getActiveTeams

java.util.List<Team> getActiveTeams()
Gets the active teams.

Returns:
the active teams

resolveAssigneeAssignment

it.neverworks.security.User resolveAssigneeAssignment(ItemInstance instance,
                                                      java.lang.String taskDefinitionKey)
Resolve assignee assignment.

Parameters:
instance - the instance
taskDefinitionKey - the task definition key
Returns:
the user

resolveAssigneeAssignment

it.neverworks.security.User resolveAssigneeAssignment(ItemInstance instance,
                                                      java.lang.String taskDefinitionKey,
                                                      Organization organization)
Resolve assignee assignment.

Parameters:
instance - the instance
taskDefinitionKey - the task definition key
organization - the organization
Returns:
the user

resolveAssigneeAssignmentInLane

it.neverworks.security.User resolveAssigneeAssignmentInLane(ItemInstance instance,
                                                            java.lang.String taskDefinitionKey,
                                                            java.lang.String laneId)
Resolve assignee assignment in lane.

Parameters:
instance - the instance
taskDefinitionKey - the task definition key
laneId - the lane id
Returns:
the user

resolveOwnerAssignment

Organization resolveOwnerAssignment(ItemInstance instance,
                                    java.lang.String taskDefinitionKey)
Resolve owner assignment.

Parameters:
instance - the instance
taskDefinitionKey - the task definition key
Returns:
the organization

resolveOwnerAssignmentFirst

Organization resolveOwnerAssignmentFirst(ItemInstance instance,
                                         java.lang.String taskDefinitionKey)
Resolve owner assignment first.

Parameters:
instance - the instance
taskDefinitionKey - the task definition key
Returns:
the organization

resolveOwnerAssignmentInLane

Organization resolveOwnerAssignmentInLane(ItemInstance instance,
                                          java.lang.String taskDefinitionKey,
                                          java.lang.String laneId)
Resolve owner assignment in lane.

Parameters:
instance - the instance
taskDefinitionKey - the task definition key
laneId - the lane id
Returns:
the organization

resolveOrganizationUserId

OrganizationUser resolveOrganizationUserId(java.lang.String organizationUserId)
Resolve organization user id.

Parameters:
organizationUserId - the organization user id
Returns:
the organization user

getOrganizationUser

OrganizationUser getOrganizationUser(Organization organization,
                                     it.neverworks.security.User user)
Gets the organization user.

Parameters:
organization - the organization
user - the user
Returns:
the organization user

getConfidentialityLevels

java.util.List<ConfidentialityLevel> getConfidentialityLevels()
Gets the confidentiality levels.

Returns:
the confidentiality levels

canChangeInstanceConfidentialityLevel

boolean canChangeInstanceConfidentialityLevel(ItemInstance instance)
Can change instance confidentiality level.

Parameters:
instance - the instance
Returns:
true, if successful

canChangeFileConfidentialityLevel

boolean canChangeFileConfidentialityLevel(CloudFile file)
Can change file confidentiality level.

Parameters:
file - the file
Returns:
true, if successful

resolveUsersWithFunction

java.util.List<OrganizationUser> resolveUsersWithFunction(Organization organization,
                                                          java.lang.String function)
Resolve users with function.

Parameters:
organization - the organization
function - the function
Returns:
the list

copyUserProfile

void copyUserProfile(it.neverworks.security.User source,
                     it.neverworks.security.User target,
                     Partition targetPartition,
                     boolean cleanTarget,
                     boolean copyProfileMbox,
                     boolean copyProfileOrg,
                     boolean copyProfileTeam,
                     boolean copyProfileWf,
                     boolean copyProfileSubscr,
                     boolean copyProfileUsr)
Copy user profile.

Parameters:
source - the source
target - the target
targetPartition - the target partition
cleanTarget - the clean target
copyProfileMbox - the copy profile mbox
copyProfileOrg - the copy profile org
copyProfileTeam - the copy profile team
copyProfileWf - the copy profile wf
copyProfileSubscr - the copy profile subscr
copyProfileUsr - the copy profile usr