fr.paris.lutece.plugins.directory.service
Class DirectoryService

java.lang.Object
  extended by fr.paris.lutece.plugins.directory.service.DirectoryService

public class DirectoryService
extends java.lang.Object

FormService


Constructor Summary
DirectoryService()
           
 
Method Summary
 java.util.List<Field> getFieldsListFromIdEntry(int nIdEntry)
          Get the list of fields from a given id entry
static DirectoryService getInstance()
          Returns the instance of the singleton
 java.util.Map<java.lang.String,java.lang.Object> getManageAdvancedParameters(fr.paris.lutece.portal.business.user.AdminUser user)
          Build the advanced parameters management
 int getMaxNumber(IEntry entry)
          Get the max number
 java.util.Map<java.lang.String,java.lang.String> getModelForEntryForXml(IEntry entry)
          Get the model for entry for xml
 int getNumber(IEntry entry, java.lang.String strNumber)
          Get the number to insert to the entry type numbering.
 int getRecordsCount(Directory directory, fr.paris.lutece.portal.business.user.AdminUser user)
          Get the records count
 fr.paris.lutece.portal.service.security.LuteceUser getUserFromIdDirectoryRecord(int nIdDirectoryRecord)
          Get the user from the id directory record
 fr.paris.lutece.util.ReferenceList getUserInfo(fr.paris.lutece.portal.service.security.LuteceUser user)
          Get the user info
 java.lang.String getWSRestUrl(IEntry entry, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Get the WS rest url from a given entry
 void init()
          Initialize the Form service
 void removeAsynchronousFile(RecordField recordField, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Remove asynchronous file
 boolean showXY(IEntry entry)
          Check if the entry must show the X and Y or not
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DirectoryService

public DirectoryService()
Method Detail

init

public void init()
Initialize the Form service


getInstance

public static DirectoryService getInstance()
Returns the instance of the singleton

Returns:
The instance of the singleton

getManageAdvancedParameters

public java.util.Map<java.lang.String,java.lang.Object> getManageAdvancedParameters(fr.paris.lutece.portal.business.user.AdminUser user)
Build the advanced parameters management

Parameters:
user - the current user
Returns:
The model for the advanced parameters

getRecordsCount

public int getRecordsCount(Directory directory,
                           fr.paris.lutece.portal.business.user.AdminUser user)
Get the records count

Parameters:
directory - the Directory
user - the AdminUser
Returns:
the record count

getUserFromIdDirectoryRecord

public fr.paris.lutece.portal.service.security.LuteceUser getUserFromIdDirectoryRecord(int nIdDirectoryRecord)
Get the user from the id directory record

Parameters:
nIdDirectoryRecord - the id directory record
Returns:
a LuteceUser, null if the directory record is not a MyLutece entry

getUserInfo

public fr.paris.lutece.util.ReferenceList getUserInfo(fr.paris.lutece.portal.service.security.LuteceUser user)
Get the user info

Parameters:
user - LuteceUser
Returns:
a list of info of the user

getMaxNumber

public int getMaxNumber(IEntry entry)
Get the max number

Parameters:
nIdEntryTypeNumbering - the id entry type numbering
nIdDirectory - the id directory
Returns:
the max number

getNumber

public int getNumber(IEntry entry,
                     java.lang.String strNumber)
              throws DirectoryErrorException
Get the number to insert to the entry type numbering.

Parameters:
entry - the entry type numbering
strNumber - the number to insert
Returns:
the number
Throws:
DirectoryErrorException - exception if the number already exists on an another record field

getFieldsListFromIdEntry

public java.util.List<Field> getFieldsListFromIdEntry(int nIdEntry)
Get the list of fields from a given id entry

Parameters:
nIdEntry - the id entry
Returns:
a list of fields

getModelForEntryForXml

public java.util.Map<java.lang.String,java.lang.String> getModelForEntryForXml(IEntry entry)
Get the model for entry for xml

Parameters:
entry - the entry
Returns:
the model

showXY

public boolean showXY(IEntry entry)
Check if the entry must show the X and Y or not

Returns:
true if it must show, false otherwise

removeAsynchronousFile

public void removeAsynchronousFile(RecordField recordField,
                                   fr.paris.lutece.portal.service.plugin.Plugin plugin)
Remove asynchronous file

Parameters:
recordField - the record field
plugin - the plugin

getWSRestUrl

public java.lang.String getWSRestUrl(IEntry entry,
                                     fr.paris.lutece.portal.service.plugin.Plugin plugin)
Get the WS rest url from a given entry

Parameters:
entry - the entry
plugin - the plugin
Returns:
the ws rest url


Copyright © 2011 Mairie de Paris. All Rights Reserved.