mixconfig.panels.OwnCertificatesPanel Class Reference

Inherits mixconfig::panels::MixConfigPanel, java::awt::event::ActionListener, and javax::swing::event::ChangeListener.

List of all members.

Public Member Functions

 OwnCertificatesPanel (boolean isApplet)
void actionPerformed (ActionEvent ae)
String getHelpContext ()
Vector< String > check ()
void focusLost (FocusEvent a_event)
void stateChanged (ChangeEvent e)
boolean hasOperatorCert ()
void signMixCertificate (boolean chooseValidity)
void setConfiguration (MixConfiguration a_conf) throws IOException
Container getHelpExtractionDisplayContext ()
void save (JRadioButton a_cbx)

Static Public Attributes

static final String XMLPATH_LOCATION = "Description/Location"
static final String XMLPATH_OPERATOR = "Description/Operator"
static final String XMLPATH_LOCATION_CITY = XMLPATH_LOCATION + "/City"
static final String XMLPATH_LOCATION_COUNTRY = XMLPATH_LOCATION + "/Country"
static final String XMLPATH_LOCATION_STATE = XMLPATH_LOCATION + "/State"
static final String XMLPATH_LOCATION_LONGITUDE = XMLPATH_LOCATION + "/Position/Geo/Longitude"
static final String XMLPATH_LOCATION_LATITUDE = XMLPATH_LOCATION + "/Position/Geo/Latitude"
static final String XMLPATH_OPERATOR_ORGANISATION = XMLPATH_OPERATOR + "/Organisation"
static final String XMLPATH_OPERATOR_URL = XMLPATH_OPERATOR + "/URL"
static final String XMLPATH_OPERATOR_EMAIL = XMLPATH_OPERATOR + "/EMail"
static final String XMLPATH_OPERATOR_COUNTRY = XMLPATH_OPERATOR + "/Country"
static final String XMLPATH_OPERATOR_CITY = XMLPATH_OPERATOR + "/City"
static final String XMLPATH_OPERATOR_ORGA_UNIT = XMLPATH_OPERATOR + "/OrganisationalUnit"
static final String MSG_INVALID_POSITION = OwnCertificatesPanel.class.getName() + "_invalidPosition"
static final String MSG_INVALID_EMAIL = OwnCertificatesPanel.class.getName() + "_invalidEmail"
static final String MSG_INVALID_URL = OwnCertificatesPanel.class.getName() + "_invalidUrl"

Protected Member Functions

void save (JComboBox a_comboBox)
void load (JRadioButton a)
void load (JComboBox a_comboBox)
void enableComponents ()

Private Member Functions

void enableOperatorCertificateFields ()
void enableMixCertificateFields ()
void updateMixID ()
boolean checkCertificateField (String a_xmlPath, Vector< String > a_vecInvalidityMsg, Object[] msgArgs)

Private Attributes

CertPanel m_ownCert
CertPanel m_operatorCert
JButton m_buttonMapBox
JTextField m_txtCity
JTextField m_txtState
JTextField m_txtLongitude
JTextField m_txtLatitude
JTextField m_txtOperatorOrg
JTextField m_txtOperatorOrgaUnit
JTextField m_txtOperatorUrl
JTextField m_txtOperatorEmail
JComboBox m_cboxCountry
JComboBox m_cbxOperatorCountry
MapBox box
JTextField m_txtMixName
JTextField m_txtOperatorName
JRadioButton m_radioMixName
JRadioButton m_radioOperatorName
ButtonGroup m_groupCascadeName

Static Private Attributes

static final String MSG_CERT_NOT_VERIFYABLE = OwnCertificatesPanel.class.getName() + "_certNotVerifyable"

Classes

class  OperatorCertCreationValidator
class  OwnCertCreationValidator


Constructor & Destructor Documentation

mixconfig.panels.OwnCertificatesPanel.OwnCertificatesPanel ( boolean  isApplet  ) 

JLabel pos = new JLabel("Geographical Position"); pos.setToolTipText( "Example: University of Technology Dresden, CS Department: Longitude: 13.761, Latitude: 51.053"); panelLocation.addRow(pos, null);

References mixconfig.panels.CertPanel.addChangeListener(), mixconfig.panels.MixConfigPanel.getInitialConstraints(), mixconfig.panels.OwnCertificatesPanel.m_buttonMapBox, mixconfig.panels.OwnCertificatesPanel.m_cboxCountry, mixconfig.panels.OwnCertificatesPanel.m_cbxOperatorCountry, mixconfig.panels.OwnCertificatesPanel.m_groupCascadeName, mixconfig.panels.OwnCertificatesPanel.m_operatorCert, mixconfig.panels.OwnCertificatesPanel.m_ownCert, mixconfig.panels.OwnCertificatesPanel.m_radioMixName, mixconfig.panels.OwnCertificatesPanel.m_radioOperatorName, mixconfig.panels.OwnCertificatesPanel.m_txtCity, mixconfig.panels.OwnCertificatesPanel.m_txtLatitude, mixconfig.panels.OwnCertificatesPanel.m_txtLongitude, mixconfig.panels.OwnCertificatesPanel.m_txtMixName, mixconfig.panels.OwnCertificatesPanel.m_txtOperatorEmail, mixconfig.panels.OwnCertificatesPanel.m_txtOperatorName, mixconfig.panels.OwnCertificatesPanel.m_txtOperatorOrg, mixconfig.panels.OwnCertificatesPanel.m_txtOperatorOrgaUnit, mixconfig.panels.OwnCertificatesPanel.m_txtOperatorUrl, mixconfig.panels.OwnCertificatesPanel.m_txtState, mixconfig.panels.MixConfigPanel.MAX_COLUMN_LENGTH, mixconfig.panels.MixConfigPanel.MAX_COMBO_BOX_LENGTH, mixconfig.panels.MixConfigPanel.MAX_COORDINATE_FIELD_LENGTH, mixconfig.panels.CertPanel.setCertCreationValidator(), mixconfig.panels.CertPanel.setCertificateView(), mixconfig.panels.OwnCertificatesPanel.XMLPATH_LOCATION_CITY, mixconfig.panels.OwnCertificatesPanel.XMLPATH_LOCATION_COUNTRY, mixconfig.panels.OwnCertificatesPanel.XMLPATH_LOCATION_LATITUDE, mixconfig.panels.OwnCertificatesPanel.XMLPATH_LOCATION_LONGITUDE, mixconfig.panels.OwnCertificatesPanel.XMLPATH_LOCATION_STATE, mixconfig.panels.OwnCertificatesPanel.XMLPATH_OPERATOR_COUNTRY, mixconfig.panels.OwnCertificatesPanel.XMLPATH_OPERATOR_EMAIL, mixconfig.panels.OwnCertificatesPanel.XMLPATH_OPERATOR_ORGA_UNIT, mixconfig.panels.OwnCertificatesPanel.XMLPATH_OPERATOR_ORGANISATION, and mixconfig.panels.OwnCertificatesPanel.XMLPATH_OPERATOR_URL.


Member Function Documentation

void mixconfig.panels.OwnCertificatesPanel.actionPerformed ( ActionEvent  ae  ) 

String mixconfig.panels.OwnCertificatesPanel.getHelpContext (  ) 

Vector<String> mixconfig.panels.OwnCertificatesPanel.check (  )  [virtual]

Check the panel for inconsistencies and return a java.util.Vector object containing possible warnings and error messages

Returns:
Possible error and warning messages

Implements mixconfig.panels.MixConfigPanel.

References mixconfig.panels.CertPanel.getCert(), mixconfig.ICertCreationValidator.getInvalidityMessages(), mixconfig.ICertCreationValidator.isValid(), mixconfig.panels.OwnCertificatesPanel.m_operatorCert, and mixconfig.panels.OwnCertificatesPanel.m_ownCert.

void mixconfig.panels.OwnCertificatesPanel.focusLost ( FocusEvent  a_event  ) 

void mixconfig.panels.OwnCertificatesPanel.stateChanged ( ChangeEvent  e  ) 

References mixconfig.panels.OwnCertificatesPanel.enableComponents(), mixconfig.panels.CertPanel.getCert(), mixconfig.panels.CertPanel.getCertificateView(), mixconfig.OperatorCertificateView.getCommonName(), mixconfig.MixCertificateView.getCommonName(), mixconfig.OperatorCertificateView.getCountry(), mixconfig.MixCertificateView.getCountry(), mixconfig.OperatorCertificateView.getCountryMapper(), mixconfig.MixCertificateView.getCountryMapper(), mixconfig.OperatorCertificateView.getEMail(), mixconfig.MixCertificateView.getLatitude(), mixconfig.MixCertificateView.getLocalityName(), mixconfig.MixCertificateView.getLongitude(), mixconfig.ConfigurationEvent.getModifiedXMLPath(), mixconfig.OperatorCertificateView.getOrganisation(), mixconfig.OperatorCertificateView.getOrganisationalUnit(), mixconfig.MixCertificateView.getStateOrProvince(), mixconfig.OperatorCertificateView.getURL(), mixconfig.OperatorCertificateView.isCA(), mixconfig.MixCertificateView.isCA(), mixconfig.panels.MixConfigPanel.load(), mixconfig.panels.OwnCertificatesPanel.m_cboxCountry, mixconfig.panels.OwnCertificatesPanel.m_cbxOperatorCountry, mixconfig.panels.OwnCertificatesPanel.m_operatorCert, mixconfig.panels.OwnCertificatesPanel.m_ownCert, mixconfig.panels.OwnCertificatesPanel.m_txtCity, mixconfig.panels.OwnCertificatesPanel.m_txtLatitude, mixconfig.panels.OwnCertificatesPanel.m_txtLongitude, mixconfig.panels.OwnCertificatesPanel.m_txtMixName, mixconfig.panels.OwnCertificatesPanel.m_txtOperatorEmail, mixconfig.panels.OwnCertificatesPanel.m_txtOperatorName, mixconfig.panels.OwnCertificatesPanel.m_txtOperatorOrg, mixconfig.panels.OwnCertificatesPanel.m_txtOperatorOrgaUnit, mixconfig.panels.OwnCertificatesPanel.m_txtOperatorUrl, mixconfig.panels.OwnCertificatesPanel.m_txtState, mixconfig.panels.MixConfigPanel.MSG_WARNING_NO_MIX_CERT, mixconfig.panels.MixConfigPanel.MSG_WARNING_NO_OPERATOR_CERT, mixconfig.panels.MixConfigPanel.save(), mixconfig.panels.CertPanel.setAdditionalVerifier(), mixconfig.panels.OwnCertificatesPanel.signMixCertificate(), mixconfig.panels.CertPanel.updateCertificateIcon(), and mixconfig.panels.OwnCertificatesPanel.updateMixID().

boolean mixconfig.panels.OwnCertificatesPanel.hasOperatorCert (  ) 

Returns:
True if there is an operator certificate set, else return False

References mixconfig.panels.CertPanel.getCert(), and mixconfig.panels.OwnCertificatesPanel.m_operatorCert.

void mixconfig.panels.OwnCertificatesPanel.signMixCertificate ( boolean  chooseValidity  ) 

void mixconfig.panels.OwnCertificatesPanel.setConfiguration ( MixConfiguration  a_mixConf  )  throws IOException

Informs the panel about a new Mix configuration and makes it load the attribute values from the configuration object into the text fields, combo boxes etc.

Parameters:
a_mixConf The new configuration
Exceptions:
IOException If an error occurs while transferring the data

Reimplemented from mixconfig.panels.MixConfigPanel.

References mixconfig.panels.OwnCertificatesPanel.enableComponents(), and mixconfig.panels.OwnCertificatesPanel.updateMixID().

Container mixconfig.panels.OwnCertificatesPanel.getHelpExtractionDisplayContext (  ) 

void mixconfig.panels.OwnCertificatesPanel.save ( JComboBox  a  )  [protected]

Saves the values of a combo box to the configuration object. The value is only saved if the component is currently enabled, otherwise, the element with the same XML path as the component's name is removed from the XML structure.

Parameters:
a A combo box

Reimplemented from mixconfig.panels.MixConfigPanel.

References mixconfig.panels.MixConfigPanel.getConfiguration(), mixconfig.panels.OwnCertificatesPanel.m_cboxCountry, mixconfig.panels.OwnCertificatesPanel.m_cbxOperatorCountry, and mixconfig.MixConfiguration.setValue().

void mixconfig.panels.OwnCertificatesPanel.save ( JRadioButton  a  ) 

Saves the values of a radio button to the configuration object. This method does not save the value directly, but tries to retrieve the radio button's group and invokes the appropriate save method.

Parameters:
a A radio button the encoding is UTF-8. If this encoding is not supported, an exception is thrown.

Reimplemented from mixconfig.panels.MixConfigPanel.

References mixconfig.panels.MixConfigPanel.getConfiguration(), mixconfig.panels.MixConfigPanel.isAutoSaveEnabled(), mixconfig.panels.OwnCertificatesPanel.m_radioMixName, mixconfig.panels.OwnCertificatesPanel.m_radioOperatorName, and mixconfig.MixConfiguration.setAttribute().

void mixconfig.panels.OwnCertificatesPanel.load ( JRadioButton  a  )  [protected]

Loads the value with the same name as the specified combo box from the configuration object and sets its value accordingly.

Parameters:
a A radio button

Reimplemented from mixconfig.panels.MixConfigPanel.

References mixconfig.panels.MixConfigPanel.getConfiguration(), mixconfig.MixConfiguration.getValue(), mixconfig.panels.OwnCertificatesPanel.m_radioMixName, and mixconfig.panels.OwnCertificatesPanel.m_radioOperatorName.

void mixconfig.panels.OwnCertificatesPanel.load ( JComboBox  a  )  [protected]

Loads the value with the same name as the specified combo box from the configuration object and sets its value accordingly. If the value in the configuration is not an int, a value of 0 (zero) is assumed by default.

Parameters:
a A combo box

Reimplemented from mixconfig.panels.MixConfigPanel.

References mixconfig.panels.MixConfigPanel.getConfiguration(), mixconfig.panels.OwnCertificatesPanel.m_cboxCountry, and mixconfig.panels.OwnCertificatesPanel.m_cbxOperatorCountry.

void mixconfig.panels.OwnCertificatesPanel.enableComponents (  )  [protected, virtual]

Enables used and disables unused components. Some configuration values are mutually exclusive; the panels must ensure that of two components corresponding to contradictory attributes, only one at a time is enabled.

Implements mixconfig.panels.MixConfigPanel.

References mixconfig.panels.OwnCertificatesPanel.enableMixCertificateFields(), and mixconfig.panels.OwnCertificatesPanel.enableOperatorCertificateFields().

Referenced by mixconfig.panels.OwnCertificatesPanel.focusLost(), mixconfig.panels.OwnCertificatesPanel.setConfiguration(), and mixconfig.panels.OwnCertificatesPanel.stateChanged().

void mixconfig.panels.OwnCertificatesPanel.enableOperatorCertificateFields (  )  [private]

void mixconfig.panels.OwnCertificatesPanel.enableMixCertificateFields (  )  [private]

void mixconfig.panels.OwnCertificatesPanel.updateMixID (  )  [private]

boolean mixconfig.panels.OwnCertificatesPanel.checkCertificateField ( String  a_xmlPath,
Vector< String >  a_vecInvalidityMsg,
Object[]  msgArgs 
) [private]


Member Data Documentation

final String mixconfig.panels.OwnCertificatesPanel.XMLPATH_LOCATION = "Description/Location" [static]

XML paths

final String mixconfig.panels.OwnCertificatesPanel.XMLPATH_OPERATOR = "Description/Operator" [static]

final String mixconfig.panels.OwnCertificatesPanel.XMLPATH_LOCATION_LONGITUDE = XMLPATH_LOCATION + "/Position/Geo/Longitude" [static]

final String mixconfig.panels.OwnCertificatesPanel.XMLPATH_LOCATION_LATITUDE = XMLPATH_LOCATION + "/Position/Geo/Latitude" [static]

final String mixconfig.panels.OwnCertificatesPanel.MSG_INVALID_POSITION = OwnCertificatesPanel.class.getName() + "_invalidPosition" [static]

final String mixconfig.panels.OwnCertificatesPanel.MSG_INVALID_EMAIL = OwnCertificatesPanel.class.getName() + "_invalidEmail" [static]

final String mixconfig.panels.OwnCertificatesPanel.MSG_INVALID_URL = OwnCertificatesPanel.class.getName() + "_invalidUrl" [static]

final String mixconfig.panels.OwnCertificatesPanel.MSG_CERT_NOT_VERIFYABLE = OwnCertificatesPanel.class.getName() + "_certNotVerifyable" [static, private]


The documentation for this class was generated from the following file:

Generated on Mon Nov 16 23:24:48 2009 for MixConfig by  doxygen 1.5.6