Interface LogbookParameters
-
- All Superinterfaces:
VitamParameter<LogbookParameterName>
- All Known Implementing Classes:
LogbookLifeCycleObjectGroupParameters,LogbookLifeCycleParameters,LogbookLifeCycleUnitParameters,LogbookOperationParameters
public interface LogbookParameters extends VitamParameter<LogbookParameterName>
Logbook parameters
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.time.LocalDateTimegetEventDateTime()The EventDateTime is set by the Logbook methods during creation or appendjava.lang.StringgetParameterValue(LogbookParameterName parameterName)Get the parameter according to the parameterNameStatusCodegetStatus()Get the outcome statusLogbookTypeProcessgetTypeProcess()Get the process typeLogbookParametersputParameterValue(LogbookParameterName parameterName, java.lang.String parameterValue)Put parameterValue on mapParamaters with parameterName key
If parameterKey already exists, the override it (no check)LogbookParameterssetBeginningLog(java.lang.String handlerId, java.lang.String subTaskId, java.lang.String additionalMessage, java.lang.String... params)Update the current LogbookParameters with status and messageLogbookParameterssetFinalStatus(java.lang.String handlerId, java.lang.String subTaskId, StatusCode code, java.lang.String additionalMessage, java.lang.String... params)Update the current LogbookParameters with status and messageLogbookParameterssetFromParameters(LogbookParameters parameters)Set from another LogbookParametersLogbookParameterssetMap(java.util.Map<java.lang.String,java.lang.String> map)Set from map using String as KeyLogbookParameterssetStatus(StatusCode outcome)Set the outcome statusLogbookParameterssetTypeProcess(LogbookTypeProcess process)Set the process type-
Methods inherited from interface fr.gouv.vitam.common.parameter.VitamParameter
getMandatoriesParameters, getMapParameters
-
-
-
-
Method Detail
-
getEventDateTime
java.time.LocalDateTime getEventDateTime()
The EventDateTime is set by the Logbook methods during creation or append- Returns:
- the associated EventDateTime if set (or null if not set yet)
-
setStatus
LogbookParameters setStatus(StatusCode outcome)
Set the outcome status- Parameters:
outcome-- Returns:
- this
-
getStatus
StatusCode getStatus()
Get the outcome status- Returns:
- the status (or null if not set yet)
- Throws:
java.lang.IllegalArgumentException- if the status is with incorrect value
-
setTypeProcess
LogbookParameters setTypeProcess(LogbookTypeProcess process)
Set the process type- Parameters:
process- process type- Returns:
- this
-
getTypeProcess
LogbookTypeProcess getTypeProcess()
Get the process type- Returns:
- the process type (or null if not set yet)
- Throws:
java.lang.IllegalArgumentException- if the process type is with incorrect value
-
putParameterValue
LogbookParameters putParameterValue(LogbookParameterName parameterName, java.lang.String parameterValue)
Put parameterValue on mapParamaters with parameterName key
If parameterKey already exists, the override it (no check)- Parameters:
parameterName- the key of the parameter to put on the parameter mapparameterValue- the value to put on the parameter map- Returns:
- actual instance of LogbookParameters (fluent like)
- Throws:
java.lang.IllegalArgumentException- if the parameterName is null or if the parameterValue cannot be null or empty
-
getParameterValue
java.lang.String getParameterValue(LogbookParameterName parameterName)
Get the parameter according to the parameterName- Parameters:
parameterName-- Returns:
- the value or null if not found
- Throws:
java.lang.IllegalArgumentException- if the parameterName is null
-
setMap
LogbookParameters setMap(java.util.Map<java.lang.String,java.lang.String> map)
Set from map using String as Key- Parameters:
map-- Returns:
- this
-
setFromParameters
LogbookParameters setFromParameters(LogbookParameters parameters)
Set from another LogbookParameters- Parameters:
parameters-- Returns:
- this
-
setFinalStatus
LogbookParameters setFinalStatus(java.lang.String handlerId, java.lang.String subTaskId, StatusCode code, java.lang.String additionalMessage, java.lang.String... params)
Update the current LogbookParameters with status and message- Parameters:
handlerId- the Handler IdsubTaskId- the subTask Id if any (may be null)code- the Status CodeAdminManagementClientRestTestadditionalMessage- the additional message (as " Details= ...") if any (may be null)params- the additional parameters for the message if any (may be null)- Returns:
- this
-
setBeginningLog
LogbookParameters setBeginningLog(java.lang.String handlerId, java.lang.String subTaskId, java.lang.String additionalMessage, java.lang.String... params)
Update the current LogbookParameters with status and message- Parameters:
handlerId- the Handler IdsubTaskId- the subTask Id if any (may be null)additionalMessage- the additional message (as " Details= ...") if any (may be null)params- the additional parameters for the message if any (may be null)- Returns:
- this
-
-