KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > tc > config > schema > dynamic > ObjectArrayXPathBasedConfigItem


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.dynamic;
5
6 import org.apache.xmlbeans.XmlObject;
7
8 import com.tc.config.schema.context.ConfigContext;
9
10 /**
11  * An {@link XPathBasedConfigItem} that returns an array of objects. Subclasses must override the
12  * {@link #fetchDataFromXmlObject(XmlObject)} method to return the actual array in question.
13  */

14 public abstract class ObjectArrayXPathBasedConfigItem extends XPathBasedConfigItem implements ObjectArrayConfigItem {
15
16   public ObjectArrayXPathBasedConfigItem(ConfigContext context, String JavaDoc xpath) {
17     super(context, xpath);
18   }
19
20   public ObjectArrayXPathBasedConfigItem(ConfigContext context, String JavaDoc xpath, Object JavaDoc defaultValue) {
21     super(context, xpath, defaultValue);
22   }
23
24   public Object JavaDoc[] getObjects() {
25     return (Object JavaDoc[]) getObject();
26   }
27
28 }
29
Popular Tags