RSE
Release 3.2

org.eclipse.rse.ui.validators
Class ValidatorUserId

java.lang.Object
  extended by org.eclipse.rse.ui.validators.ValidatorSpecialChar
      extended by org.eclipse.rse.ui.validators.ValidatorUserId
All Implemented Interfaces:
IInputValidator, ICellEditorValidator, ISystemValidator

public class ValidatorUserId
extends ValidatorSpecialChar

This class is used in dialogs that prompt for a userId. This does very basic userId validation, just to ensure there are no problems when the user Id is saved in the preferences. This means restricting use of a couple special characters that would mess up the key/value processing of the preference data. The IInputValidator interface is used by jface's InputDialog class and numerous other platform and system classes.


Field Summary
 
Fields inherited from class org.eclipse.rse.ui.validators.ValidatorSpecialChar
currentMessage, EMPTY_ALLOWED_NO, EMPTY_ALLOWED_YES, msg_Empty, msg_Invalid, specialChars
 
Constructor Summary
ValidatorUserId(boolean isEmptyAllowed)
          Constructor
 
Method Summary
 SystemMessage isSyntaxOk(String newText)
          We could do additional syntax checking here if we decide to.
 
Methods inherited from class org.eclipse.rse.ui.validators.ValidatorSpecialChar
containsSpecialCharacters, doMessageSubstitution, getMaximumNameLength, getSystemMessage, getSystemMessageText, isValid, isValid, setErrorMessages, validate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ValidatorUserId

public ValidatorUserId(boolean isEmptyAllowed)
Constructor

Method Detail

isSyntaxOk

public SystemMessage isSyntaxOk(String newText)
We could do additional syntax checking here if we decide to. This method is called by parent class if all other error checking passes.

Overrides:
isSyntaxOk in class ValidatorSpecialChar

RSE
Release 3.2

Copyright (c) IBM Corporation and others 2000, 2010. All Rights Reserved.