src/org/ohmage/validator/ObserverValidators.java
public static final String validateObserverId(
			final String value)
			throws ValidationException {
		
		if(StringUtils.isEmptyOrWhitespaceOnly(value)) {
			return null;
		}
		
		try {
			return Observer.sanitizeId(value);
		}
		catch(DomainException e) {
			throw new ValidationException(
				ErrorCode.OBSERVER_INVALID_ID,
				"The observer ID is invalid: " + value,
				e);
		}
	}
/**
	 * Validates that an observer ID is valid.
	 * 
	 * @param value The observer ID.
	 * 
	 * @return The sanitized observer ID or null if the value was null or only
	 * 		   whitespace.
	 * 
	 * @throws ValidationException The observer ID is invalid.
	 */
Validates that an observer ID is valid.

@param value The observer ID.

@return The sanitized observer ID or null if the value was null or only
whitespace.

@throws ValidationException The observer ID is invalid.
Validates that an observer ID is valid . @param value The observer ID . @return The sanitized observer ID or null if the value was null or only whitespace . @throws ValidationException The observer ID is invalid .
public static final String validateObserverId(
			final String value)
			throws ValidationException {
		if(StringUtils.isEmptyOrWhitespaceOnly(value)) {
			return null;
		}
		try {
			return Observer.sanitizeId(value);
		}
		catch(DomainException e) {
			throw new ValidationException(
				ErrorCode.OBSERVER_INVALID_ID,
				"The observer ID is invalid: " + value,
				e);
		}
	}
public static final String validateObserverId ( final String value ) throws ValidationException { if ( StringUtils . isEmptyOrWhitespaceOnly ( value ) ) { return null ; } try { return Observer . sanitizeId ( value ) ; } catch ( DomainException e ) { throw new ValidationException ( ErrorCode . OBSERVER_INVALID_ID , "The observer ID is invalid: " + value , e ) ; } }
Validates that an observer ID is valid.
Validates that an observer ID is valid .