1 package com.thaiopensource.relaxng.impl; 2 3 import org.relaxng.datatype.Datatype; 4 import org.relaxng.datatype.DatatypeBuilder; 5 import org.relaxng.datatype.DatatypeException; 6 import org.relaxng.datatype.ValidationContext; 7 8 class BuiltinDatatypeBuilder implements DatatypeBuilder { 9 private final Datatype dt; 10 11 BuiltinDatatypeBuilder(Datatype dt) { 12 this.dt = dt; 13 } 14 15 public void addParameter(String name, 16 String value, 17 ValidationContext context) throws DatatypeException { 18 throw new DatatypeException(SchemaBuilderImpl.localizer.message("builtin_param")); 19 } 20 21 public Datatype createDatatype() { 22 return dt; 23 } 24 } 25 | Popular Tags |