org.nuiton.topia.history
Interface TopiaHistoryService

All Superinterfaces:
TopiaService
All Known Implementing Classes:
TopiaHistoryServiceImpl

public interface TopiaHistoryService
extends TopiaService

Author:
poussin

Field Summary
static String SERVICE_NAME
           
 
Method Summary
 void clear(Date toDate)
          Supprime tout l'historique jusqu'a la date passé en parametre
 List<String> findLastAction(int limit, String user, String type, Integer... action)
          Search TopiaId targeted by action and user.
 void keep(int number)
          Ne garde dans l'historique que les number dernier elements
 void store(Date toDate, Writer out)
          Permet de stocker l'historique dans un writer (par exemple un fichier)
 
Methods inherited from interface org.nuiton.topia.framework.TopiaService
getPersistenceClasses, getServiceName, postInit, preInit
 

Field Detail

SERVICE_NAME

static final String SERVICE_NAME
See Also:
Constant Field Values
Method Detail

clear

void clear(Date toDate)
           throws Exception
Supprime tout l'historique jusqu'a la date passé en parametre

Parameters:
toDate - la derniere date effacé inclue
Throws:
Exception - if any pb

keep

void keep(int number)
          throws Exception
Ne garde dans l'historique que les number dernier elements

Parameters:
number - le nombre d'element a conserver dans l'historique
Throws:
Exception - if any pb

store

void store(Date toDate,
           Writer out)
           throws Exception
Permet de stocker l'historique dans un writer (par exemple un fichier)

Parameters:
toDate - l'historique est sauve jusqu'a cette date incluse
out - le flux sur lequel il faut ecrire l'historique
Throws:
Exception - if any pb

findLastAction

List<String> findLastAction(int limit,
                            String user,
                            String type,
                            Integer... action)
                            throws Exception
Search TopiaId targeted by action and user. Results are ordered by date last is oldest

Parameters:
limit - maximum number of result, -1 for all
user - TopiaId of user, can be null for all user
type - type of target search (fqn class) can be null for all object
action - action as int that we want to search, can be an sum of action wanted LOAD + UPDATE + DELETE + CREATE for all action
Returns:
TopiaId of target object
Throws:
Exception - if any pb


Copyright © 2004-2010 CodeLutin. All Rights Reserved.