fr.paris.lutece.plugins.workflow.modules.automaticassignment.service
Interface IAutomaticAssignmentService

All Known Implementing Classes:
AutomaticAssignmentService

public interface IAutomaticAssignmentService

IAutomaticAssignmentService


Method Summary
 boolean checkExist(AutomaticAssignment assign, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Check if an assignment already exist
 void create(AutomaticAssignment assign, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Creation of an instance of assign
 java.util.List<java.lang.Integer> findAllIdEntriesByTask(int nIdTask, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Return a list of id from entries with the same task
 java.util.List<AutomaticAssignment> findByTask(int nIdTask, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Return a list of assignment with the same task
 java.util.List<AutomaticAssignment> findByTaskByEntry(int nIdTask, int nIdEntry, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Return a list of assignment with the same task and entry
 java.util.List<fr.paris.lutece.util.mail.FileAttachment> getFilesAttachment(TaskAutomaticAssignmentConfig config, int nIdRecord, int nIdDirectory)
          the files Attachments to insert in the mail
 java.util.List<fr.paris.lutece.plugins.directory.business.IEntry> getListEntries(int nIdTask)
          Get the list of entries from a given id task
 java.util.List<fr.paris.lutece.plugins.directory.business.IEntry> getListEntriesFile(int nIdTask, java.util.Locale locale)
          Get the list of entries that have the accepted type for file
 boolean isEntryTypeFileAccepted(int nIdEntryType)
          Check if the given entry type id is accepted for file
 void notify(TaskAutomaticAssignmentConfig config, java.util.List<java.lang.String> listWorkgroup, fr.paris.lutece.plugins.workflowcore.business.resource.ResourceHistory resourceHistory, javax.servlet.http.HttpServletRequest request, java.util.Locale locale, fr.paris.lutece.plugins.workflowcore.service.task.ITask task)
          Notify the mailing list associated to the list of workgroups
 void remove(AutomaticAssignment assign, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Remove assign which is specified in parameter
 void removeByTask(int nIdTask, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Remove all assign linked to the task
 

Method Detail

create

@Transactional(value="workflow-automaticassignment.transactionManager")
void create(AutomaticAssignment assign,
                          fr.paris.lutece.portal.service.plugin.Plugin plugin)
Creation of an instance of assign

Parameters:
assign - The instance of AutomaticAssignment
plugin - the plugin

remove

@Transactional(value="workflow-automaticassignment.transactionManager")
void remove(AutomaticAssignment assign,
                          fr.paris.lutece.portal.service.plugin.Plugin plugin)
Remove assign which is specified in parameter

Parameters:
assign - The AutomaticAssignment
plugin - the plugin

removeByTask

@Transactional(value="workflow-automaticassignment.transactionManager")
void removeByTask(int nIdTask,
                                fr.paris.lutece.portal.service.plugin.Plugin plugin)
Remove all assign linked to the task

Parameters:
nIdTask - The id of the task
plugin - the plugin

checkExist

boolean checkExist(AutomaticAssignment assign,
                   fr.paris.lutece.portal.service.plugin.Plugin plugin)
Check if an assignment already exist

Parameters:
assign - the assignment to check
plugin - the plugin
Returns:
true if exists

isEntryTypeFileAccepted

boolean isEntryTypeFileAccepted(int nIdEntryType)
Check if the given entry type id is accepted for file

Parameters:
nIdEntryType - the id entry type
Returns:
true if it is accepted, false otherwise

findByTaskByEntry

java.util.List<AutomaticAssignment> findByTaskByEntry(int nIdTask,
                                                      int nIdEntry,
                                                      fr.paris.lutece.portal.service.plugin.Plugin plugin)
Return a list of assignment with the same task and entry

Parameters:
nIdTask - the task id
nIdEntry - the entry id
plugin - the plugin
Returns:
assignmentList the list of automatic assignment

findByTask

java.util.List<AutomaticAssignment> findByTask(int nIdTask,
                                               fr.paris.lutece.portal.service.plugin.Plugin plugin)
Return a list of assignment with the same task

Parameters:
nIdTask - the task id
plugin - the plugin
Returns:
assignmentList the list of automatic assignment

findAllIdEntriesByTask

java.util.List<java.lang.Integer> findAllIdEntriesByTask(int nIdTask,
                                                         fr.paris.lutece.portal.service.plugin.Plugin plugin)
Return a list of id from entries with the same task

Parameters:
nIdTask - the task id
plugin - the plugin
Returns:
idEntriesList the list of entries id

getListEntries

java.util.List<fr.paris.lutece.plugins.directory.business.IEntry> getListEntries(int nIdTask)
Get the list of entries from a given id task

Parameters:
nIdTask - the id task
Returns:
a list of IEntry

getListEntriesFile

java.util.List<fr.paris.lutece.plugins.directory.business.IEntry> getListEntriesFile(int nIdTask,
                                                                                     java.util.Locale locale)
Get the list of entries that have the accepted type for file

Parameters:
nIdTask - the id task
locale - the Locale
Returns:
a List of entries

getFilesAttachment

java.util.List<fr.paris.lutece.util.mail.FileAttachment> getFilesAttachment(TaskAutomaticAssignmentConfig config,
                                                                            int nIdRecord,
                                                                            int nIdDirectory)
the files Attachments to insert in the mail

Parameters:
config - the configuration
nIdRecord - the record id
nIdDirectory - the directory id
Returns:
the files Attachments to insert in the mail

notify

void notify(TaskAutomaticAssignmentConfig config,
            java.util.List<java.lang.String> listWorkgroup,
            fr.paris.lutece.plugins.workflowcore.business.resource.ResourceHistory resourceHistory,
            javax.servlet.http.HttpServletRequest request,
            java.util.Locale locale,
            fr.paris.lutece.plugins.workflowcore.service.task.ITask task)
Notify the mailing list associated to the list of workgroups

Parameters:
config - the config
listWorkgroup - the list of workgroups
resourceHistory - the resource history
request - the HTTP request
locale - the Locale
task - the task


Copyright © 2012 Mairie de Paris. All Rights Reserved.