protected void set_Calendar(Calendar c) { int code = schemaType().getPrimitiveType().getBuiltinTypeCode(); GDateBuilder gDateBuilder = new GDateBuilder(c); gDateBuilder.setBuiltinTypeCode(code); GDate value = gDateBuilder.toGDate(); if (_validateOnSet()) validateValue(value, _schemaType, _voorVc); _value = value; }
public GDate getGDateValue() { check_dated(); if (_value == null) return null; return _value; }
protected void validate_simpleval(String lexical, ValidationContext ctx) { validateLexical(lexical, schemaType(), ctx); validateValue(gDateValue(), schemaType(), ctx); }
protected void set_text(String s) { GDate newVal; if (_validateOnSet()) newVal = validateLexical(s, _schemaType, _voorVc); else newVal = lex(s, _schemaType, _voorVc); if (_validateOnSet() && newVal != null) validateValue(newVal, _schemaType, _voorVc); _value = newVal; }
public int getIntValue() { int code = schemaType().getPrimitiveType().getBuiltinTypeCode(); if (code != SchemaType.BTC_G_DAY && code != SchemaType.BTC_G_MONTH && code != SchemaType.BTC_G_YEAR) throw new XmlValueOutOfRangeException(); check_dated(); if (_value == null) return 0; switch (code) { case SchemaType.BTC_G_DAY: return _value.getDay(); case SchemaType.BTC_G_MONTH: return _value.getMonth(); case SchemaType.BTC_G_YEAR: return _value.getYear(); default: assert(false); throw new IllegalStateException(); } }
public JavaGDateHolderEx(SchemaType type, boolean complex) { _schemaType = type; initComplexType(complex, false); }
public static GDate validateLexical(String v, SchemaType sType, ValidationContext context) { GDate date = lex(v, sType, context); if (date != null && sType.hasPatternFacet()) if (!sType.matchPatternFacet(v)) context.invalid(XmlErrorCodes.DATATYPE_VALID$PATTERN_VALID, new Object[] { "date", v, QNameHelper.readable(sType) }); return date; }
protected void set_text(String s) { GDate newVal; if (_validateOnSet()) newVal = validateLexical(s, _schemaType, _voorVc); else newVal = lex(s, _schemaType, _voorVc); if (_validateOnSet() && newVal != null) validateValue(newVal, _schemaType, _voorVc); _value = newVal; }
public int getIntValue() { int code = schemaType().getPrimitiveType().getBuiltinTypeCode(); if (code != SchemaType.BTC_G_DAY && code != SchemaType.BTC_G_MONTH && code != SchemaType.BTC_G_YEAR) throw new XmlValueOutOfRangeException(); check_dated(); if (_value == null) return 0; switch (code) { case SchemaType.BTC_G_DAY: return _value.getDay(); case SchemaType.BTC_G_MONTH: return _value.getMonth(); case SchemaType.BTC_G_YEAR: return _value.getYear(); default: assert(false); throw new IllegalStateException(); } }
public JavaGDateHolderEx(SchemaType type, boolean complex) { _schemaType = type; initComplexType(complex, false); }
public static GDate validateLexical(String v, SchemaType sType, ValidationContext context) { GDate date = lex(v, sType, context); if (date != null && sType.hasPatternFacet()) if (!sType.matchPatternFacet(v)) context.invalid(XmlErrorCodes.DATATYPE_VALID$PATTERN_VALID, new Object[] { "date", v, QNameHelper.readable(sType) }); return date; }
protected void set_Date(Date v) { int code = schemaType().getPrimitiveType().getBuiltinTypeCode(); if (code != SchemaType.BTC_DATE && code != SchemaType.BTC_DATE_TIME || v == null) throw new XmlValueOutOfRangeException(); GDateBuilder gDateBuilder = new GDateBuilder(v); gDateBuilder.setBuiltinTypeCode(code); GDate value = gDateBuilder.toGDate(); if (_validateOnSet()) validateValue(value, _schemaType, _voorVc); _value = value; }
protected void set_text(String s) { GDate newVal; if (_validateOnSet()) newVal = validateLexical(s, _schemaType, _voorVc); else newVal = lex(s, _schemaType, _voorVc); if (_validateOnSet() && newVal != null) validateValue(newVal, _schemaType, _voorVc); _value = newVal; }
protected void validate_simpleval(String lexical, ValidationContext ctx) { validateLexical(lexical, schemaType(), ctx); validateValue(gDateValue(), schemaType(), ctx); }
public int getIntValue() { int code = schemaType().getPrimitiveType().getBuiltinTypeCode(); if (code != SchemaType.BTC_G_DAY && code != SchemaType.BTC_G_MONTH && code != SchemaType.BTC_G_YEAR) throw new XmlValueOutOfRangeException(); check_dated(); if (_value == null) return 0; switch (code) { case SchemaType.BTC_G_DAY: return _value.getDay(); case SchemaType.BTC_G_MONTH: return _value.getMonth(); case SchemaType.BTC_G_YEAR: return _value.getYear(); default: assert(false); throw new IllegalStateException(); } }
public Date getDateValue() { check_dated(); if (_value == null) return null; return _value.getDate(); }
public JavaGDateHolderEx(SchemaType type, boolean complex) { _schemaType = type; initComplexType(complex, false); }
public static GDate validateLexical(String v, SchemaType sType, ValidationContext context) { GDate date = lex(v, sType, context); if (date != null && sType.hasPatternFacet()) if (!sType.matchPatternFacet(v)) context.invalid(XmlErrorCodes.DATATYPE_VALID$PATTERN_VALID, new Object[] { "date", v, QNameHelper.readable(sType) }); return date; }
protected void set_int(int v) { int code = schemaType().getPrimitiveType().getBuiltinTypeCode(); if (code != SchemaType.BTC_G_DAY && code != SchemaType.BTC_G_MONTH && code != SchemaType.BTC_G_YEAR) throw new XmlValueOutOfRangeException(); GDateBuilder value = new GDateBuilder(); switch (code) { case SchemaType.BTC_G_DAY: value.setDay(v); break; case SchemaType.BTC_G_MONTH: value.setMonth(v); break; case SchemaType.BTC_G_YEAR: value.setYear(v); break; } if (_validateOnSet()) validateValue(value, _schemaType, _voorVc); _value = value.toGDate(); }
protected void validate_simpleval(String lexical, ValidationContext ctx) { validateLexical(lexical, schemaType(), ctx); validateValue(gDateValue(), schemaType(), ctx); }