KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > tc > config > schema > defaults > DefaultValueProvider


1 /*
2  * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright notice. All rights reserved.
3  */

4 package com.tc.config.schema.defaults;
5
6 import org.apache.xmlbeans.SchemaType;
7 import org.apache.xmlbeans.XmlException;
8 import org.apache.xmlbeans.XmlObject;
9
10 /**
11  * Knows how to tell you the default value for an element in the config.
12  */

13 public interface DefaultValueProvider {
14
15   boolean possibleForXPathToHaveDefault(String JavaDoc xpath);
16   
17   XmlObject defaultFor(SchemaType baseType, String JavaDoc xpath) throws XmlException;
18   
19   boolean hasDefault(SchemaType baseType, String JavaDoc xpath) throws XmlException;
20   
21   boolean isOptional(SchemaType baseType, String JavaDoc xpath) throws XmlException;
22
23 }
24
Popular Tags