hivemind-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ahue...@apache.org
Subject svn commit: r491594 - in /hivemind/branches/branch-2-0-annot: framework/src/java/org/apache/hivemind/definition/ConfigurationParser.java xml/src/java/org/apache/hivemind/xml/definition/impl/HiveMindSchemaParser.java
Date Mon, 01 Jan 2007 15:49:08 GMT
Author: ahuegen
Date: Mon Jan  1 07:49:08 2007
New Revision: 491594

URL: http://svn.apache.org/viewvc?view=rev&rev=491594
Log:
ConfigurationParser can parse streams

Modified:
    hivemind/branches/branch-2-0-annot/framework/src/java/org/apache/hivemind/definition/ConfigurationParser.java
    hivemind/branches/branch-2-0-annot/xml/src/java/org/apache/hivemind/xml/definition/impl/HiveMindSchemaParser.java

Modified: hivemind/branches/branch-2-0-annot/framework/src/java/org/apache/hivemind/definition/ConfigurationParser.java
URL: http://svn.apache.org/viewvc/hivemind/branches/branch-2-0-annot/framework/src/java/org/apache/hivemind/definition/ConfigurationParser.java?view=diff&rev=491594&r1=491593&r2=491594
==============================================================================
--- hivemind/branches/branch-2-0-annot/framework/src/java/org/apache/hivemind/definition/ConfigurationParser.java
(original)
+++ hivemind/branches/branch-2-0-annot/framework/src/java/org/apache/hivemind/definition/ConfigurationParser.java
Mon Jan  1 07:49:08 2007
@@ -1,5 +1,7 @@
 package org.apache.hivemind.definition;
 
+import java.io.InputStream;
+
 import org.apache.hivemind.definition.construction.ContributionContext;
 
 public interface ConfigurationParser
@@ -7,7 +9,15 @@
     /**
      * Parses a configuration and returns the converted data.
      * @param context  context
-     * @param data     the data to parse. What kind of data is expected here is parser specific.

+     * @param data     the data to parse as stream. 
+     * @return  the converted data.
+     */
+    public Object parse(ContributionContext context, InputStream data);
+    
+    /**
+     * Parses a configuration and returns the converted data.
+     * @param context  context
+     * @param data     the data to parse. What kind of object is expected here is parser
specific. 
      * @return  the converted data.
      */
     public Object parse(ContributionContext context, Object data);

Modified: hivemind/branches/branch-2-0-annot/xml/src/java/org/apache/hivemind/xml/definition/impl/HiveMindSchemaParser.java
URL: http://svn.apache.org/viewvc/hivemind/branches/branch-2-0-annot/xml/src/java/org/apache/hivemind/xml/definition/impl/HiveMindSchemaParser.java?view=diff&rev=491594&r1=491593&r2=491594
==============================================================================
--- hivemind/branches/branch-2-0-annot/xml/src/java/org/apache/hivemind/xml/definition/impl/HiveMindSchemaParser.java
(original)
+++ hivemind/branches/branch-2-0-annot/xml/src/java/org/apache/hivemind/xml/definition/impl/HiveMindSchemaParser.java
Mon Jan  1 07:49:08 2007
@@ -14,6 +14,7 @@
 
 package org.apache.hivemind.xml.definition.impl;
 
+import java.io.InputStream;
 import java.util.List;
 
 import org.apache.hivemind.Element;
@@ -63,6 +64,12 @@
                 contributionsSchema.getLocation());
     }
 
+    
+    public Object parse(ContributionContext context, InputStream data)
+    {
+        throw new UnsupportedOperationException("Parsing of an InputStream is not currently
supported");
+    }
+    
     public Schema getSchema()
     {
         return _schema;



Mime
View raw message