public static UsernameAttribute createUsernameAttribute(String username) {
		UsernameAttribute attribute = new UsernameAttribute();

		try {
			attribute.setUsername(username.getBytes("UTF-8"));
		} catch (UnsupportedEncodingException ueex) {
			throw new UndeclaredThrowableException(ueex);
		}
		return attribute;
	}
public static UsernameAttribute createUsernameAttribute ( String username ) { UsernameAttribute attribute = new UsernameAttribute ( ) ; try { attribute . setUsername ( username . getBytes ( "UTF-8" ) ) ; } catch ( UnsupportedEncodingException ueex ) { throw new UndeclaredThrowableException ( ueex ) ; } return attribute ; }
Creates a new <tt>UsernameAttribute</tt> instance.

@param username
the String value of the username
@return a new <tt>UsernameAttribute</tt> instance