protected Expression makeExpression() { if("preserve".equals(startTag.getAttribute("whiteSpace"))) return reader.pool.createValue( StringType.theInstance, new StringPair("","string"), text.toString() ); else return reader.pool.createValue( TokenType.theInstance, new StringPair("","token"), WhiteSpaceProcessor.collapse(text.toString()) ); // masquerade RELAX NG built-in datatypes } }
protected Expression makeExpression() { if("preserve".equals(startTag.getAttribute("whiteSpace"))) return reader.pool.createValue( StringType.theInstance, new StringPair("","string"), text.toString() ); else return reader.pool.createValue( TokenType.theInstance, new StringPair("","token"), WhiteSpaceProcessor.collapse(text.toString()) ); // masquerade RELAX NG built-in datatypes } }
protected Expression makeExpression() { if("preserve".equals(startTag.getAttribute("whiteSpace"))) return reader.pool.createValue( StringType.theInstance, new StringPair("","string"), text.toString() ); else return reader.pool.createValue( TokenType.theInstance, new StringPair("","token"), WhiteSpaceProcessor.collapse(text.toString()) ); // masquerade RELAX NG built-in datatypes } }
protected Expression makeExpression() { if("preserve".equals(startTag.getAttribute("whiteSpace"))) return reader.pool.createValue( StringType.theInstance, new StringPair("","string"), text.toString() ); else return reader.pool.createValue( TokenType.theInstance, new StringPair("","token"), WhiteSpaceProcessor.collapse(text.toString()) ); // masquerade RELAX NG built-in datatypes } }
public final Expression createValue( XSDatatype dt, Object value ) { return createValue( dt, new StringPair("",dt.displayName()), value ); }
public final Expression createValue( XSDatatype dt, Object value ) { return createValue( dt, new StringPair("",dt.displayName()), value ); }
public final Expression createValue( XSDatatype dt, Object value ) { return createValue( dt, new StringPair("",dt.displayName()), value ); }
public final Expression createValue( XSDatatype dt, Object value ) { return createValue( dt, new StringPair("",dt.displayName()), value ); }
/** * Creates an attribute body from the declaration * found in the DTD. */ protected Expression createAttributeBody( String elementName, String attributeName, String attributeType, String[] enums, short attributeUse, String defaultValue ) throws SAXException { // create Datatype that validates attribute value. Datatype dt = createDatatype(attributeType); StringPair str = new StringPair("",attributeType); if(enums!=null) { Expression exp = Expression.nullSet; for( int i=0; i<enums.length; i++ ) exp = grammar.pool.createChoice( exp, grammar.pool.createValue(dt,str, dt.createValue(enums[i],null))); return exp; } if( attributeUse == USE_FIXED ) { return grammar.pool.createValue(dt,str, dt.createValue(defaultValue,null)); } return grammar.pool.createData(dt,str); }
/** * Creates an attribute body from the declaration * found in the DTD. */ protected Expression createAttributeBody( String elementName, String attributeName, String attributeType, String[] enums, short attributeUse, String defaultValue ) throws SAXException { // create Datatype that validates attribute value. Datatype dt = createDatatype(attributeType); StringPair str = new StringPair("",attributeType); if(enums!=null) { Expression exp = Expression.nullSet; for( int i=0; i<enums.length; i++ ) exp = grammar.pool.createChoice( exp, grammar.pool.createValue(dt,str, dt.createValue(enums[i],null))); return exp; } if( attributeUse == USE_FIXED ) { return grammar.pool.createValue(dt,str, dt.createValue(defaultValue,null)); } return grammar.pool.createData(dt,str); }
/** * Creates an attribute body from the declaration * found in the DTD. */ protected Expression createAttributeBody( String elementName, String attributeName, String attributeType, String[] enums, short attributeUse, String defaultValue ) throws SAXException { // create Datatype that validates attribute value. Datatype dt = createDatatype(attributeType); StringPair str = new StringPair("",attributeType); if(enums!=null) { Expression exp = Expression.nullSet; for( int i=0; i<enums.length; i++ ) exp = grammar.pool.createChoice( exp, grammar.pool.createValue(dt,str, dt.createValue(enums[i],null))); return exp; } if( attributeUse == USE_FIXED ) { return grammar.pool.createValue(dt,str, dt.createValue(defaultValue,null)); } return grammar.pool.createData(dt,str); }
/** * Creates an attribute body from the declaration * found in the DTD. */ protected Expression createAttributeBody( String elementName, String attributeName, String attributeType, String[] enums, short attributeUse, String defaultValue ) throws SAXException { // create Datatype that validates attribute value. Datatype dt = createDatatype(attributeType); StringPair str = new StringPair("",attributeType); if(enums!=null) { Expression exp = Expression.nullSet; for( int i=0; i<enums.length; i++ ) exp = grammar.pool.createChoice( exp, grammar.pool.createValue(dt,str, dt.createValue(enums[i],null))); return exp; } if( attributeUse == USE_FIXED ) { return grammar.pool.createValue(dt,str, dt.createValue(defaultValue,null)); } return grammar.pool.createData(dt,str); }
return reader.pool.createValue( type, typeFullName, value );
return reader.pool.createValue( type, typeFullName, value );
return reader.pool.createValue( type, typeFullName, value );
return reader.pool.createValue( type, typeFullName, value );
contentType = reader.pool.createValue( com.sun.msv.datatype.xsd.TokenType.theInstance, new StringPair("","token"), fixed ); // emulate RELAX NG built-in token type
contentType = reader.pool.createValue( com.sun.msv.datatype.xsd.TokenType.theInstance, new StringPair("","token"), // emulate RELAX NG built-in "token" type
contentType = reader.pool.createValue( com.sun.msv.datatype.xsd.TokenType.theInstance, new StringPair("","token"), // emulate RELAX NG built-in "token" type
contentType = reader.pool.createValue( com.sun.msv.datatype.xsd.TokenType.theInstance, new StringPair("","token"), // emulate RELAX NG built-in "token" type