|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object issrg.acm.SavingUtility issrg.acm.DefaultSavingUtility issrg.acm.DiskSavingUtility
public class DiskSavingUtility
This is the default saving utility. You do not have to prescribe it in the configuration file. It will be loaded automatically, if no other utilities has been registered for Attribute Certificate saving purposes.
This utility saves the given Attribute Certificate to a file, which a user can pick from a dialog.
Field Summary | |
---|---|
static java.lang.String |
AC_EXTENSION
This is the default AC file extension |
static javax.swing.filechooser.FileFilter |
ace_filter
|
static java.io.File |
dir
|
Fields inherited from class issrg.acm.DefaultSavingUtility |
---|
dialog, dialogMode, LOAD_MODE, modal_result, REVOKE_MODE, SAVE_MODE |
Constructor Summary | |
---|---|
DiskSavingUtility()
|
|
DiskSavingUtility(Registry where)
|
Method Summary | |
---|---|
void |
actionPerformed(java.awt.event.ActionEvent e)
|
void |
approveSelection()
This method should check, if the currently selected location is OK with the user (e.g. |
void |
delete()
This method is invoked only after revoke(). |
java.awt.Component |
getContentPane(java.util.Map Environment,
int dialogMode)
This method returns the Component that displays all the controls for the load/saving dialog. |
AttributeCertificate |
load()
This method returns an Attribute Certificate loaded by the utility, as specified by its controls. |
AttributeCertificate |
revoke()
This method returns an Attribute Certificate loaded for revocation by the utility, as specified by its controls. |
void |
save(byte[] ac)
This method saves the Attribute Certificate to the location, specified by the utility's controls. |
Methods inherited from class issrg.acm.DefaultSavingUtility |
---|
attachControlButtons, cancelDialog, load, revoke, save |
Methods inherited from class issrg.acm.SavingUtility |
---|
registerMe |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static java.lang.String AC_EXTENSION
public static final javax.swing.filechooser.FileFilter ace_filter
public static java.io.File dir
Constructor Detail |
---|
public DiskSavingUtility()
public DiskSavingUtility(Registry where)
Method Detail |
---|
public java.awt.Component getContentPane(java.util.Map Environment, int dialogMode)
DefaultSavingUtility
getContentPane
in class DefaultSavingUtility
Environment
- - the environment that allows the component to initialise its
fields and controlsdialogMode
- - set to one of LOAD_MODE, SAVE_MODE or REVOKE_MODE,
depending on the required content pane for the dialog
public void actionPerformed(java.awt.event.ActionEvent e)
actionPerformed
in interface java.awt.event.ActionListener
public void save(byte[] ac) throws ACCreationException
DefaultSavingUtility
save
in class DefaultSavingUtility
ACCreationException
public AttributeCertificate load() throws ACCreationException
DefaultSavingUtility
load
in class DefaultSavingUtility
ACCreationException
public AttributeCertificate revoke() throws ACCreationException
DefaultSavingUtility
revoke
in class DefaultSavingUtility
ACCreationException
public void delete() throws ACCreationException
SavingUtility
delete
in class SavingUtility
ACCreationException
- if anything went wrong and the AC could not
be removed.public void approveSelection()
DefaultSavingUtility
Override to ask questions or display error messages.
approveSelection
in class DefaultSavingUtility
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |