Overview | Package | Class | Tree | Deprecated | Index | Help
| SOA © 2004 SoS Group All Rights Reserved
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## sos.koa
Class ClearAdapter

    java.lang.Object
      sos.koa.Task
          sos.koa.ClearAdapter

All Implemented Interfaces:
  java.awt.event.ActionListener, java.util.EventListener, KOAConstants

class ClearAdapter
extends Task

Class to clear memory and files.

Version:
  $Id: ClearAdapter.java,v 1.21 2004/05/14 18:02:31 martijno Exp $
Author:
  Martijn Oostdijk (martijno@cs.kun.nl)

Class Specifications

Specifications inherited from class Task
invariant 0 <= subTaskCount&&subTaskCount <= maxSubTasks;

Nested Class Summary

Nested classes inherited from class sos.koa.Task
`Task.ActionThread, Task.MonitoredThread`

Field Summary
`(package private) boolean` | `systemIsCleared` A flag indicating if the system has been cleared.

Fields inherited from class sos.koa.Task
`maxSubTasks, monitor, stillWorking, subTaskCount, success`

Fields inherited from interface sos.koa.KOAConstants
`ADDITIONAL_INFO_EXTRA, ADDITIONAL_INFO_MAX_HEIGHT, ADDITIONAL_INFO_MAX_WIDTH, AUDITLOG, AUDITLOG_PDF, AUDITLOG_XML, AUDITLOG_XSL, BASEDIR, CANDIDATES_IMPORTED_STATE, CLEAR_BUT_TXT, CLEAR_FAILURE_MSG, CLEAR_SUCCESS_MSG, CLEAR_TASK_MSG, CLEAR_WARNING_MSG, CLEAR_WARNING_MSG_1, CLEAR_WARNING_MSG_2, CLEARED_STATE, COUNT_BUT_TXT, COUNT_FAILURE_MSG, COUNT_SUCCESS_MSG, COUNT_TASK_MSG, COUNT_WARNING_MSG, DECRYPT_BUT_TXT, DECRYPT_ERROR_MSG, DECRYPT_ERROR_TAG, DECRYPT_FAILURE_MSG, DECRYPT_SUCCESS_MSG, DECRYPT_TASK_MSG, DECRYPT_WARNING_MSG, DECRYPTEDFILE, DEFAULT_VOTING_INTERVAL, EXIT_BUT_TXT, EXIT_FAILURE_MSG, EXIT_SUCCESS_MSG, EXIT_TASK_MSG, EXIT_WARNING_MSG, FORWARD_BACK_OPTIONS, FORWARD_MOREINFO_BACK_OPTIONS, HELP_BUT_TXT, HELP_TASK_MSG, IMPORT_CANDIDATES_BUT_TXT, IMPORT_CANDIDATES_FAILURE_MSG, IMPORT_CANDIDATES_SUCCESS_MSG, IMPORT_CANDIDATES_TASK_MSG, IMPORT_CANDIDATES_WARNING_MSG, IMPORT_KEY_FAILURE_MSG, IMPORT_KEY_SUCCESS_MSG, IMPORT_KEY_WARNING_MSG, IMPORT_PRIVATE_KEY_BUT_TXT, IMPORT_PRIVATE_KEY_TASK_MSG, IMPORT_PUBLIC_KEY_BUT_TXT, IMPORT_PUBLIC_KEY_TASK_MSG, IMPORT_VOTES_BUT_TXT, IMPORT_VOTES_FAILURE_MSG, IMPORT_VOTES_SUCCESS_MSG, IMPORT_VOTES_TASK_MSG, IMPORT_VOTES_WARNING_MSG, INIT_STATE, LESSINFO_OPTION, MAX_ENCRYPTED_VOTE_LENGTH, MAX_KEY_LENGTH, MOREINFO_OPTION, NO_ERRORS_MSG, NUMBER_OF_REDUNDANT_FIELDS, OK_CANCEL_OPTIONS, OK_LESSINFO_CANCEL_OPTIONS, OK_LESSINFO_OPTIONS, OK_MOREINFO_CANCEL_OPTIONS, OK_MOREINFO_OPTIONS, OK_OPTIONS, OUTDIR, PRIVATE_KEY_IMPORTED_STATE, PRIVATE_KEYTYPE, PUBLIC_KEY_IMPORTED_STATE, PUBLIC_KEYTYPE, RECOUNT, RECOUNT_PDF, RECOUNT_XML, RECOUNT_XSL, RELEASE, REPORT_BUT_TXT, REPORT_FAILURE_MSG, REPORT_GENERATED_STATE, REPORT_OPTIONS, REPORT_SUCCESS_MSG, REPORT_TASK_MSG, REPORT_WARNING_MSG, RESTART_BUT_TXT, RESTART_FAILURE_MSG, RESTART_SUCCESS_MSG, RESTART_TASK_MSG, RESTART_WARNING_MSG, TASK_CANCELED_MSG, TITLE, VOTES_COUNTED_STATE, VOTES_DECRYPTED_STATE, VOTES_IGNORED_SEE_MORE_INFO_MSG, VOTES_IMPORTED_STATE, YES_CANCEL_OPTIONS, YES_NO_OPTIONS`

Constructor Summary
`(package private)` | `ClearAdapter()` Constructs a new ClearAdaptor.

Method Summary
`private void` | `clearPDFFiles()` Clear the PDF files.
`(package private) void` | `clearSystem()`
`void` | `clearTXTFiles()` Clear the intermediate TXT files.
`static void` | `clearXMLFiles()` Clear the intermediate XML files.
`(package private) void` | `doAction()` Gets called when the clear button is pressed.
`(package private) java.lang.String` | `getFailureMessage()`
`(package private) java.lang.String` | `getSuccessMessage()`
`(package private) int` | `getSuccessState()`
`(package private) java.lang.String` | `getTitle()`
`(package private) java.lang.String` | `getWarningMessage()` What to print in warning dialog used to ask user if he/she is sure to perform this task.
`(package private) boolean` | `isDangerousTask()` Indicates whether the user should be warned that we're about to start this task.
`(package private) boolean` | `isPreStateAllowed(int state)`

Methods inherited from class sos.koa.Task
`actionPerformed, clear, getAdditionalInfo, getInfo, isAdditionalInfoAvailable, isCancelableTask, isModalTask, isProgressMonitoredTask, logCanceled, logCompleted, logFailed, logOpenedFile, logStarted, popupAdditionalInfo, popupAdditionalInfo, popupFailure, popupGetFile, popupGetPassword, popupNext, popupNextOrBack, popupSuccess, popupWarning, setMaxSubTasks, setSubTaskCount, stopAction`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### systemIsCleared

    boolean systemIsCleared

  A flag indicating if the system has been cleared.

Constructor Detail

### ClearAdapter

    ClearAdapter()

  Constructs a new ClearAdaptor.

  Specifications: pure
    normal_behavior
    ensures !systemIsCleared;

Method Detail

### getTitle

    java.lang.String getTitle()

  Description copied from class: `Task`
  The title of this task. Is used in title-bar of dialogs.

  Specifications: (inherited)pure
  Specifications inherited from overridden method in class Task:
  pure

### getSuccessMessage

    java.lang.String getSuccessMessage()

  Description copied from class: `Task`
  What to print in success dialog.

  Specifications: (inherited)pure
  Specifications inherited from overridden method in class Task:
  pure

### getFailureMessage

    java.lang.String getFailureMessage()

  Description copied from class: `Task`
  What to print in failure dialog.

  Specifications: (inherited)pure
  Specifications inherited from overridden method in class Task:
  pure

### getWarningMessage

    java.lang.String getWarningMessage()

  Description copied from class: `Task`
  What to print in warning dialog used to ask user if he/she is sure to perform this task.

  Overrides:
    `getWarningMessage` in class `Task`
  Specifications: (inherited)pure
  Specifications inherited from overridden method in class Task:
  pure

### doAction

    void doAction()

  Gets called when the clear button is pressed.

  Specifications:
  also
    normal_behavior
    assignable \everything;
    ensures systemIsCleared;
  Specifications inherited from overridden method in class Task:
    assignable objectState;

### isDangerousTask

    boolean isDangerousTask()

  Description copied from class: `Task`
  Indicates whether the user should be warned that we're about to start this task. Default is false.

  Overrides:
    `isDangerousTask` in class `Task`
  Specifications: (inherited)pure
  Specifications inherited from overridden method in class Task:
  pure

### isPreStateAllowed

    boolean isPreStateAllowed(int state)

  Specifications: (inherited)pure
  Specifications inherited from overridden method in class Task:
  pure

### getSuccessState

    int getSuccessState()

  Description copied from class: `Task`
  The application state after successful termination of this task.

  Specifications: (inherited)pure
  Specifications inherited from overridden method in class Task:
  pure

### clearSystem

    void clearSystem()

  Specifications:
    normal_behavior
    assignable \everything;
    ensures systemIsCleared;

### clearXMLFiles

    public static void clearXMLFiles()

  Clear the intermediate XML files. Public because they may be called from anywhere. Static because this method doesn't seem to depend on the state of this object. -- MO

### clearTXTFiles

    public void clearTXTFiles()

  Clear the intermediate TXT files. Public because they may be called from anywhere.

### clearPDFFiles

    private void clearPDFFiles()

  Clear the PDF files. Private because they may not be called from anywhere.

Overview | Package | Class | Tree | Deprecated | Index | Help
| SOA © 2004 SoS Group All Rights Reserved
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD