/** * Creates an {@link Identifier} from the given String, without checking its syntax. * This should ONLY be used for identifiers that are known to be valid, such as the ones * defined in the QTI specification. */ public static Identifier assumedLegal(final String value) { return new Identifier(value); }
/** * Parses the given Identifier String, making sure it follows the required syntax. * <p> * Use this factory method for user-supplied identifiers. * * @throws QtiParseException if value is not a valid identifier */ public static Identifier parseString(final String value) { verifyIdentifier(value); return new Identifier(value); }