fr.paris.lutece.plugins.form.service
Class ResponseService

java.lang.Object
  extended by fr.paris.lutece.plugins.form.service.ResponseService
All Implemented Interfaces:
IResponseService

public class ResponseService
extends Object
implements IResponseService

ResponseService


Constructor Summary
ResponseService()
           
 
Method Summary
 void anonymizeEntries(List<Integer> listIdEntries, Timestamp dateCleanTo)
          Anonymize entries of responses
 void create(FormSubmit formSubmit)
          Create a form submit
 void create(fr.paris.lutece.plugins.genericattributes.business.Response response, int nIdFormSubmit)
          Creation of an instance of response
 fr.paris.lutece.plugins.genericattributes.business.Response findByPrimaryKey(int nKey, boolean bGetFileData)
          Returns an instance of a Response whose identifier is specified in parameter
 fr.paris.lutece.plugins.genericattributes.service.file.FileService getFileService()
          Get the file service
 List<fr.paris.lutece.plugins.genericattributes.business.Response> getResponseList(fr.paris.lutece.plugins.genericattributes.business.ResponseFilter filter, boolean bGetFileData)
          Load the data of all the response who verify the filter and returns them in a list
 List<fr.paris.lutece.plugins.genericattributes.business.StatisticEntrySubmit> getStatisticByIdEntry(int nIdEntry)
          Return a list of statistic on the entry
 void removeFromFormSubmit(int nIdFormSubmit)
          Remove responses associated with a given form submit
 void update(fr.paris.lutece.plugins.genericattributes.business.Response response)
          Update of the response which is specified in parameter
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ResponseService

public ResponseService()
Method Detail

getFileService

public fr.paris.lutece.plugins.genericattributes.service.file.FileService getFileService()
Get the file service

Specified by:
getFileService in interface IResponseService
Returns:
the file service

create

@Transactional(value="form.transactionManager")
public void create(FormSubmit formSubmit)
Create a form submit

Specified by:
create in interface IResponseService
Parameters:
formSubmit - The form submit to create

create

public void create(fr.paris.lutece.plugins.genericattributes.business.Response response,
                   int nIdFormSubmit)
Creation of an instance of response

Specified by:
create in interface IResponseService
Parameters:
response - The instance of the response which contains the informations to store
nIdFormSubmit - The id of the form submit associated with this response

update

public void update(fr.paris.lutece.plugins.genericattributes.business.Response response)
Update of the response which is specified in parameter

Specified by:
update in interface IResponseService
Parameters:
response - The instance of the Response which contains the informations to update

findByPrimaryKey

public fr.paris.lutece.plugins.genericattributes.business.Response findByPrimaryKey(int nKey,
                                                                                    boolean bGetFileData)
Returns an instance of a Response whose identifier is specified in parameter

Specified by:
findByPrimaryKey in interface IResponseService
Parameters:
nKey - The entry primary key
bGetFileData - get file data
Returns:
an instance of Response

getResponseList

public List<fr.paris.lutece.plugins.genericattributes.business.Response> getResponseList(fr.paris.lutece.plugins.genericattributes.business.ResponseFilter filter,
                                                                                         boolean bGetFileData)
Load the data of all the response who verify the filter and returns them in a list

Specified by:
getResponseList in interface IResponseService
Parameters:
filter - the filter
bGetFileData - get file data
Returns:
the list of response

getStatisticByIdEntry

public List<fr.paris.lutece.plugins.genericattributes.business.StatisticEntrySubmit> getStatisticByIdEntry(int nIdEntry)
Return a list of statistic on the entry

Specified by:
getStatisticByIdEntry in interface IResponseService
Parameters:
nIdEntry - the id of the entry
Returns:
return a list of statistic on the entry

anonymizeEntries

public void anonymizeEntries(List<Integer> listIdEntries,
                             Timestamp dateCleanTo)
Anonymize entries of responses

Specified by:
anonymizeEntries in interface IResponseService
Parameters:
listIdEntries - The list of id of responses to anonymize responses of
dateCleanTo - Anonymize responses posted before this date

removeFromFormSubmit

public void removeFromFormSubmit(int nIdFormSubmit)
Remove responses associated with a given form submit

Specified by:
removeFromFormSubmit in interface IResponseService
Parameters:
nIdFormSubmit - The id of the form submit


Copyright © 2014 Mairie de Paris. All Rights Reserved.