fr.paris.lutece.plugins.directory.service.record
Class RecordService

java.lang.Object
  extended by fr.paris.lutece.plugins.directory.service.record.RecordService
All Implemented Interfaces:
IRecordService

public class RecordService
extends java.lang.Object
implements IRecordService

RecordService


Field Summary
static java.lang.String BEAN_SERVICE
           
 
Constructor Summary
RecordService()
           
 
Method Summary
 int copy(Record record, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Copy an instance of record
 int create(Record record, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Creation of an instance of record
 java.lang.Boolean directoryRecordListHasWorkflow(int nIdDirectory, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Test if the given directory record list has a worflow
 Record findByPrimaryKey(int nKey, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Returns an instance of a recordwhose identifier is specified in parameter
 int getCountRecord(RecordFieldFilter filter, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Count record who verify the filter
 java.lang.Integer getDirectoryIdByRecordId(java.lang.Integer nRecordId, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Get directory id by by record id
 java.util.List<Record> getListRecord(RecordFieldFilter filter, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Load the data of all the record who verify the filter and returns them in a list
 java.util.List<java.lang.Integer> getListRecordId(RecordFieldFilter filter, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Load the data of all the record who verify the filter and returns them in a list
 java.util.List<Record> loadListByListId(java.util.List<java.lang.Integer> lIdList, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Load a list of record
 void remove(int nIdRecord, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Remove the record whose identifier is specified in parameter
 void update(Record record, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Update of the record
 void updateWidthRecordField(Record record, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Update of the record which is specified in parameter
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

BEAN_SERVICE

public static final java.lang.String BEAN_SERVICE
See Also:
Constant Field Values
Constructor Detail

RecordService

public RecordService()
Method Detail

copy

@Transactional(value="directory.transactionManager")
public int copy(Record record,
                              fr.paris.lutece.portal.service.plugin.Plugin plugin)
Copy an instance of record

Specified by:
copy in interface IRecordService
Parameters:
record - The instance of the record who must copy
plugin - the Plugin
Returns:
the id of the record

create

@Transactional(value="directory.transactionManager")
public int create(Record record,
                                fr.paris.lutece.portal.service.plugin.Plugin plugin)
Creation of an instance of record

Specified by:
create in interface IRecordService
Parameters:
record - The instance of the record which contains the informations to store
plugin - the Plugin
Returns:
the id of the new record

remove

@Transactional(value="directory.transactionManager")
public void remove(int nIdRecord,
                                 fr.paris.lutece.portal.service.plugin.Plugin plugin)
Remove the record whose identifier is specified in parameter

Specified by:
remove in interface IRecordService
Parameters:
nIdRecord - The recordId
plugin - the Plugin

update

@Transactional(value="directory.transactionManager")
public void update(Record record,
                                 fr.paris.lutece.portal.service.plugin.Plugin plugin)
Update of the record

Specified by:
update in interface IRecordService
Parameters:
record - The instance of the record which contains the informations to update
plugin - the Plugin

updateWidthRecordField

@Transactional(value="directory.transactionManager")
public void updateWidthRecordField(Record record,
                                                 fr.paris.lutece.portal.service.plugin.Plugin plugin)
Update of the record which is specified in parameter

Specified by:
updateWidthRecordField in interface IRecordService
Parameters:
record - The instance of the record which contains the informations to update
plugin - the Plugin

directoryRecordListHasWorkflow

public java.lang.Boolean directoryRecordListHasWorkflow(int nIdDirectory,
                                                        fr.paris.lutece.portal.service.plugin.Plugin plugin)
Test if the given directory record list has a worflow

Specified by:
directoryRecordListHasWorkflow in interface IRecordService
Parameters:
nIdDirectory - directory Id
plugin - the plugin
Returns:
true if has at least one

findByPrimaryKey

public Record findByPrimaryKey(int nKey,
                               fr.paris.lutece.portal.service.plugin.Plugin plugin)
Returns an instance of a recordwhose identifier is specified in parameter

Specified by:
findByPrimaryKey in interface IRecordService
Parameters:
nKey - The formResponse primary key
plugin - the Plugin
Returns:
an instance of FormResponse

getCountRecord

public int getCountRecord(RecordFieldFilter filter,
                          fr.paris.lutece.portal.service.plugin.Plugin plugin)
Count record who verify the filter

Specified by:
getCountRecord in interface IRecordService
Parameters:
filter - the filter
plugin - the plugin
Returns:
the number of record

getDirectoryIdByRecordId

public java.lang.Integer getDirectoryIdByRecordId(java.lang.Integer nRecordId,
                                                  fr.paris.lutece.portal.service.plugin.Plugin plugin)
Get directory id by by record id

Specified by:
getDirectoryIdByRecordId in interface IRecordService
Parameters:
nRecordId - the record id
plugin - the plugin
Returns:
the directory id

getListRecord

public java.util.List<Record> getListRecord(RecordFieldFilter filter,
                                            fr.paris.lutece.portal.service.plugin.Plugin plugin)
Load the data of all the record who verify the filter and returns them in a list

Specified by:
getListRecord in interface IRecordService
Parameters:
filter - the filter
plugin - the plugin
Returns:
the list of record

getListRecordId

public java.util.List<java.lang.Integer> getListRecordId(RecordFieldFilter filter,
                                                         fr.paris.lutece.portal.service.plugin.Plugin plugin)
Load the data of all the record who verify the filter and returns them in a list

Specified by:
getListRecordId in interface IRecordService
Parameters:
filter - the filter
plugin - the plugin
Returns:
the list of record

loadListByListId

public java.util.List<Record> loadListByListId(java.util.List<java.lang.Integer> lIdList,
                                               fr.paris.lutece.portal.service.plugin.Plugin plugin)
Load a list of record

Specified by:
loadListByListId in interface IRecordService
plugin - the plugin
Returns:
list of Record


Copyright © 2012 Mairie de Paris. All Rights Reserved.