| | |
| | | { |
| | | private long timeInterval; |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public void initializeLogRotationPolicy(TimeLimitLogRotationPolicyCfg config) |
| | | { |
| | | timeInterval = config.getRotationInterval(); |
| | |
| | | config.addTimeLimitChangeListener(this); |
| | | } |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public boolean isConfigurationChangeAcceptable( |
| | | TimeLimitLogRotationPolicyCfg config, List<LocalizableMessage> unacceptableReasons) |
| | | { |
| | |
| | | return true; |
| | | } |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public ConfigChangeResult applyConfigurationChange( |
| | | TimeLimitLogRotationPolicyCfg config) |
| | | { |
| | |
| | | * @param writer The multi file text writer written the log file. |
| | | * @return true if the file should be rotated, false otherwise. |
| | | */ |
| | | @Override |
| | | public boolean rotateFile(RotatableLogFile writer) |
| | | { |
| | | long currInterval = TimeThread.getTime() - |