Package org.cyclos.impl.system
Class ConfigurationEntityLogHandlerImpl
- java.lang.Object
-
- org.cyclos.impl.AbstractServerComponent
-
- org.cyclos.impl.AbstractNetworkedServerComponent
-
- org.cyclos.impl.BaseNetworkedHandlerImpl
-
- org.cyclos.impl.system.BaseEntityLogHandlerImpl<Configuration,ConfigurationDTO>
-
- org.cyclos.impl.system.ConfigurationEntityLogHandlerImpl
-
- All Implemented Interfaces:
EntityLogHandler<Configuration,ConfigurationDTO>
@Component public class ConfigurationEntityLogHandlerImpl extends BaseEntityLogHandlerImpl<Configuration,ConfigurationDTO>
Handler for Configuration entity logs.
-
-
Field Summary
-
Fields inherited from class org.cyclos.impl.system.BaseEntityLogHandlerImpl
$, el, MASKED_VALUE
-
Fields inherited from class org.cyclos.impl.AbstractNetworkedServerComponent
authHandler, conversionHandler, customFieldValueHandler, entityManagerHandler, groupsHandler, productsHandler, restBeanPropertyMapping, userLocatorHandler
-
Fields inherited from class org.cyclos.impl.AbstractServerComponent
accountHandler, configurationHandler, dataTranslationHandler, notificationHandler, profileFieldHandler, transactionHandler, translationHandler
-
-
Constructor Summary
Constructors Constructor Description ConfigurationEntityLogHandlerImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanareEquals(Configuration oldEntity, Configuration newEntity, PropertyAccess access, Object oldValue, Object newValue)In case of Configuration for a property to be considered having the same value in old and new instances it must have the same value or both null, have the same definition and also the same lock mode.protected List<EntityPropertyLog>doOnBeforeLog(Configuration oldEntity, Configuration newEntity, List<EntityPropertyLog> result, EntityLogEvent event)Class<Configuration>getEntityClass()The entity class related to this handlerprotected ConfigurationgetEntityToViewLog(long entityId)Returns the entity with the given id ONLY if the logged user can view its logs.EntityLogTypegetType()The log type this handler manages.EntityLogDescriptor<ConfigurationDTO>resolveLogDescriptor(Configuration configuration)Return the descriptor with the mappings for each DTO property.-
Methods inherited from class org.cyclos.impl.system.BaseEntityLogHandlerImpl
applyLogFilters, canViewEntityLog, createEntityPropertyLog, customLogForCreation, doApplyLogFilters, getEntityLogName, getRelatedUser, getValues, isLogEnabled, onBeforeLog
-
Methods inherited from class org.cyclos.impl.AbstractNetworkedServerComponent
canManage, checkManagesUser, checkPermission, checkRelatesToUser, checkValue, clearAlreadyValidated, getBaseEntityManagerHandler, getConfiguration, getLoggedBasicUser, getLoggedUser, getProducts, getTranslatedName, getTranslatedValue, hasPermission, hasValue, inSameNetwork, inSameNetworkOrGlobal, isAdmin, isAlreadyValidated, isBroker, isGlobalAdmin, isGlobalAdminInNetwork, isGuest, isLoggedIn, isMember, isMemberOnly, isNetworkAdmin, isOperator, isRelatedToUser, isSystem, isUserManager, isUserManagerOf, message, message, permission, permission, permissionOptionalValue, permissionOptionalValue, toDate, toDateTime, validate
-
Methods inherited from class org.cyclos.impl.AbstractServerComponent
dataTranslationProxy, delete, detach, find, flush, from, getApplicationContext, getFormatter, getFormatter, getFormatter, getLogger, getRemoteAddress, getSessionData, mailContentBuilder, message, message, persist, processBatch, processBatch, refresh, remove, selectFrom, subQuery, update
-
-
-
-
Method Detail
-
areEquals
public boolean areEquals(Configuration oldEntity, Configuration newEntity, PropertyAccess access, Object oldValue, Object newValue)
In case of Configuration for a property to be considered having the same value in old and new instances it must have the same value or both null, have the same definition and also the same lock mode.- Specified by:
areEqualsin interfaceEntityLogHandler<Configuration,ConfigurationDTO>- Overrides:
areEqualsin classBaseEntityLogHandlerImpl<Configuration,ConfigurationDTO>
-
getEntityClass
public Class<Configuration> getEntityClass()
Description copied from interface:EntityLogHandlerThe entity class related to this handler
-
getType
public EntityLogType getType()
Description copied from interface:EntityLogHandlerThe log type this handler manages.
-
resolveLogDescriptor
public EntityLogDescriptor<ConfigurationDTO> resolveLogDescriptor(Configuration configuration)
Description copied from interface:EntityLogHandlerReturn the descriptor with the mappings for each DTO property.
-
doOnBeforeLog
protected List<EntityPropertyLog> doOnBeforeLog(Configuration oldEntity, Configuration newEntity, List<EntityPropertyLog> result, EntityLogEvent event)
- Overrides:
doOnBeforeLogin classBaseEntityLogHandlerImpl<Configuration,ConfigurationDTO>
-
getEntityToViewLog
protected Configuration getEntityToViewLog(long entityId)
Description copied from class:BaseEntityLogHandlerImplReturns the entity with the given id ONLY if the logged user can view its logs. Otherwise it MUST return null.- Specified by:
getEntityToViewLogin classBaseEntityLogHandlerImpl<Configuration,ConfigurationDTO>
-
-