/** * Construct CountryCode by the parsing the given string * * @param countryCode * The String to be parsed into CountryCode * @throws IllegalArgumentException if the given argument is not a valid CountryCode */ public CountryCode(String countryCode) throws IllegalArgumentException { if (!isValid(countryCode)) { throw new IllegalArgumentException("parameter is invalid for datatype CountryCode"); } // validate 'token' type which is defined in W3C schema // http://www.w3.org/TR/xmlschema-2/#token if (!W3CSchemaType.isValid("token", countryCode)) { throw new IllegalArgumentException("parameter is invalid for datatype CountryCode"); } mCountryCode = countryCode; }
/** * Construct CountryCode by the parsing the given string * * @param countryCode * The String to be parsed into CountryCode * @throws IllegalArgumentException if the given argument is not a valid CountryCode */ public CountryCode(String countryCode) throws IllegalArgumentException { if (!isValid(countryCode)) { throw new IllegalArgumentException("parameter is invalid for datatype CountryCode"); } // validate 'token' type which is defined in W3C schema // http://www.w3.org/TR/xmlschema-2/#token if (!W3CSchemaType.isValid("token", countryCode)) { throw new IllegalArgumentException("parameter is invalid for datatype CountryCode"); } mCountryCode = countryCode; }
/** * Construct CountryCode by the parsing the given string * * @param countryCode * The String to be parsed into CountryCode * @throws IllegalArgumentException if the given argument is not a valid CountryCode */ public CountryCode(String countryCode) throws IllegalArgumentException { if (!isValid(countryCode)) { throw new IllegalArgumentException("parameter is invalid for datatype CountryCode"); } // validate 'token' type which is defined in W3C schema // http://www.w3.org/TR/xmlschema-2/#token if (!W3CSchemaType.isValid("token", countryCode)) { throw new IllegalArgumentException("parameter is invalid for datatype CountryCode"); } mCountryCode = countryCode; }