incubator-connectors-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kwri...@apache.org
Subject svn commit: r1220353 [3/11] - in /incubator/lcf/branches/CONNECTORS-286/warthog-reimport: ./ src/main/java/org/apache/warthog/api/ src/main/java/org/apache/warthog/bytekeyvalue/ src/main/java/org/apache/warthog/common/ src/main/java/org/apache/warthog/...
Date Sun, 18 Dec 2011 08:36:56 GMT
Modified: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/IndexRelationship.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/IndexRelationship.java?rev=1220353&r1=1220352&r2=1220353&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/IndexRelationship.java (original)
+++ incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/IndexRelationship.java Sun Dec 18 08:36:52 2011
@@ -1,56 +1,56 @@
-/* $Id: IndexRelationship.java -1   $ */
-
-/**
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements. See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License. You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package org.apache.warthog.api;
-
-/** The index relationship basically views another relationship (a table) through
-* an index with criteria and ordering.
-*/
-public class IndexRelationship implements WHRelationship
-{
-  protected WHIndex index;
-  protected IndexCriteria[] criteria;
-  protected boolean[] orderReversed;
-  
-  /** Constructor */
-  public IndexRelationship(WHIndex index, IndexCriteria[] criteria, boolean[] orderReversed)
-  {
-    this.index = index;
-    this.criteria = criteria;
-    this.orderReversed = orderReversed;
-  }
-  
-  /** Get the column names represented by the relationship. */
-  public String[] getColumnNames()
-    throws WHException
-  {
-    return index.getColumnNames();
-  }
-
-  /** Get the row accessor.  This determines
-  * both the initial set of rows and the ordering.  The results can be later filtered to
-  * yield the final output data.
-  */
-  public WHAccessor buildAccessor()
-    throws WHException
-  {
-    return index.buildAccessor(criteria,orderReversed);
-  }
-  
-}
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.apache.warthog.api;
+
+/** The index relationship basically views another relationship (a table) through
+* an index with criteria and ordering.
+*/
+public class IndexRelationship implements WHRelationship
+{
+  protected WHIndex index;
+  protected IndexCriteria[] criteria;
+  protected boolean[] orderReversed;
+  
+  /** Constructor */
+  public IndexRelationship(WHIndex index, IndexCriteria[] criteria, boolean[] orderReversed)
+  {
+    this.index = index;
+    this.criteria = criteria;
+    this.orderReversed = orderReversed;
+  }
+  
+  /** Get the column names represented by the relationship. */
+  public String[] getColumnNames()
+    throws WHException
+  {
+    return index.getColumnNames();
+  }
+
+  /** Get the row accessor.  This determines
+  * both the initial set of rows and the ordering.  The results can be later filtered to
+  * yield the final output data.
+  */
+  public WHAccessor buildAccessor()
+    throws WHException
+  {
+    return index.buildAccessor(criteria,orderReversed);
+  }
+  
+}

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/IndexRelationship.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/IndexRelationship.java
------------------------------------------------------------------------------
    svn:keywords = Id

Modified: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/IndexRelationshipBuilder.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/IndexRelationshipBuilder.java?rev=1220353&r1=1220352&r2=1220353&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/IndexRelationshipBuilder.java (original)
+++ incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/IndexRelationshipBuilder.java Sun Dec 18 08:36:52 2011
@@ -1,111 +1,111 @@
-/* $Id: IndexRelationshipBuilder.java -1   $ */
-
-/**
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements. See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License. You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package org.apache.warthog.api;
-
-import java.lang.reflect.*;
-
-/** Build an index relationship based on a row in an accessor.
-*/
-public class IndexRelationshipBuilder implements WHRelationshipBuilder
-{
-  protected WHIndex index;
-  protected IndexCriteria[] criteria;
-  protected String[] accessorColumn;
-  protected String[] criteriaClassName;
-  protected boolean[] orderReversed;
-
-  /** Constructor.  The criteria passed to the index will include
-  * both criteria we specify in the constructor, and criteria based
-  * the accessor row we see.  Thus the segregation of the incoming
-  * arguments.
-  * The way it works is that whenever the accessorColumn value is non-null, then
-  * the matching criteriaClass is instantiated (with a single WHValue argument).
-  * Otherwise, the criteria passed in the "criteria" argument is used.
-  */
-  public IndexRelationshipBuilder(WHIndex index,
-    IndexCriteria[] criteria,
-    String[] accessorColumn,
-    String[] criteriaClassName,
-    boolean[] orderReversed)
-    throws WHException
-  {
-    if (criteria.length != accessorColumn.length ||
-      criteria.length != criteriaClassName.length ||
-      criteria.length != orderReversed.length)
-      throw new WHException("Criteria, accessorColumn, criteriaClassName, and orderReversed all must be the same size");
-    this.index = index;
-    this.criteria = criteria;
-    this.orderReversed = orderReversed;
-    this.accessorColumn = accessorColumn;
-    this.criteriaClassName = criteriaClassName;
-  }
-  
-  /** Construct a relationship based on the specified accessor row.
-  */
-  public WHRelationship createRelationship(WHAccessor accessor)
-    throws WHException
-  {
-    IndexCriteria[] currentCriteria = new IndexCriteria[criteria.length];
-    
-    // Fill in the missing pieces from the current accessor.
-    for (int i = 0 ; i < criteria.length ; i++)
-    {
-      if (accessorColumn[i] != null && criteriaClassName[i] != null)
-      {
-        WHValue theMatchValue = accessor.getValue(accessorColumn[i]);
-        try
-        {
-          Class classValue = Class.forName(criteriaClassName[i]);
-          Constructor constructor = classValue.getConstructor(new Class[]{WHValue.class});
-          Object object = constructor.newInstance(new Object[]{theMatchValue});
-          if (!(object instanceof IndexCriteria))
-            throw new WHException("Criteria class '"+criteriaClassName[i]+"' does not extend IndexCriteria");
-          currentCriteria[i] = (IndexCriteria)object;
-        }
-        catch (ClassNotFoundException e)
-        {
-          throw new WHException("Can't find criteria class '"+criteriaClassName[i]+"': "+e.getMessage(),e);
-        }
-        catch (NoSuchMethodException e)
-        {
-          throw new WHException("Criteria class '"+criteriaClassName[i]+"' does not have a constructor with a WHValue argument: "+e.getMessage(),e);
-        }
-        catch (InvocationTargetException e)
-        {
-          throw new WHException("Constructor exception instantiating criteria class '"+criteriaClassName[i]+"': "+e.getMessage(),e);
-        }
-        catch (InstantiationException e)
-        {
-          throw new WHException("Instantiation exception for criteria class '"+criteriaClassName[i]+"': "+e.getMessage(),e);
-        }
-        catch (IllegalAccessException e)
-        {
-          throw new WHException("Criteria class '"+criteriaClassName[i]+"' WHValue constructor has protected access",e);
-        }
-      }
-      else
-        currentCriteria[i] = criteria[i];
-    }
-    
-    // Create an index relationship so we can get its accessor
-    return new IndexRelationship(index,currentCriteria,orderReversed);
-  }
-  
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.apache.warthog.api;
+
+import java.lang.reflect.*;
+
+/** Build an index relationship based on a row in an accessor.
+*/
+public class IndexRelationshipBuilder implements WHRelationshipBuilder
+{
+  protected WHIndex index;
+  protected IndexCriteria[] criteria;
+  protected String[] accessorColumn;
+  protected String[] criteriaClassName;
+  protected boolean[] orderReversed;
+
+  /** Constructor.  The criteria passed to the index will include
+  * both criteria we specify in the constructor, and criteria based
+  * the accessor row we see.  Thus the segregation of the incoming
+  * arguments.
+  * The way it works is that whenever the accessorColumn value is non-null, then
+  * the matching criteriaClass is instantiated (with a single WHValue argument).
+  * Otherwise, the criteria passed in the "criteria" argument is used.
+  */
+  public IndexRelationshipBuilder(WHIndex index,
+    IndexCriteria[] criteria,
+    String[] accessorColumn,
+    String[] criteriaClassName,
+    boolean[] orderReversed)
+    throws WHException
+  {
+    if (criteria.length != accessorColumn.length ||
+      criteria.length != criteriaClassName.length ||
+      criteria.length != orderReversed.length)
+      throw new WHException("Criteria, accessorColumn, criteriaClassName, and orderReversed all must be the same size");
+    this.index = index;
+    this.criteria = criteria;
+    this.orderReversed = orderReversed;
+    this.accessorColumn = accessorColumn;
+    this.criteriaClassName = criteriaClassName;
+  }
+  
+  /** Construct a relationship based on the specified accessor row.
+  */
+  public WHRelationship createRelationship(WHAccessor accessor)
+    throws WHException
+  {
+    IndexCriteria[] currentCriteria = new IndexCriteria[criteria.length];
+    
+    // Fill in the missing pieces from the current accessor.
+    for (int i = 0 ; i < criteria.length ; i++)
+    {
+      if (accessorColumn[i] != null && criteriaClassName[i] != null)
+      {
+        WHValue theMatchValue = accessor.getValue(accessorColumn[i]);
+        try
+        {
+          Class classValue = Class.forName(criteriaClassName[i]);
+          Constructor constructor = classValue.getConstructor(new Class[]{WHValue.class});
+          Object object = constructor.newInstance(new Object[]{theMatchValue});
+          if (!(object instanceof IndexCriteria))
+            throw new WHException("Criteria class '"+criteriaClassName[i]+"' does not extend IndexCriteria");
+          currentCriteria[i] = (IndexCriteria)object;
+        }
+        catch (ClassNotFoundException e)
+        {
+          throw new WHException("Can't find criteria class '"+criteriaClassName[i]+"': "+e.getMessage(),e);
+        }
+        catch (NoSuchMethodException e)
+        {
+          throw new WHException("Criteria class '"+criteriaClassName[i]+"' does not have a constructor with a WHValue argument: "+e.getMessage(),e);
+        }
+        catch (InvocationTargetException e)
+        {
+          throw new WHException("Constructor exception instantiating criteria class '"+criteriaClassName[i]+"': "+e.getMessage(),e);
+        }
+        catch (InstantiationException e)
+        {
+          throw new WHException("Instantiation exception for criteria class '"+criteriaClassName[i]+"': "+e.getMessage(),e);
+        }
+        catch (IllegalAccessException e)
+        {
+          throw new WHException("Criteria class '"+criteriaClassName[i]+"' WHValue constructor has protected access",e);
+        }
+      }
+      else
+        currentCriteria[i] = criteria[i];
+    }
+    
+    // Create an index relationship so we can get its accessor
+    return new IndexRelationship(index,currentCriteria,orderReversed);
+  }
+  
 }
\ No newline at end of file

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/IndexRelationshipBuilder.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/IndexRelationshipBuilder.java
------------------------------------------------------------------------------
    svn:keywords = Id

Modified: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/JoinAccessor.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/JoinAccessor.java?rev=1220353&r1=1220352&r2=1220353&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/JoinAccessor.java (original)
+++ incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/JoinAccessor.java Sun Dec 18 08:36:52 2011
@@ -1,120 +1,120 @@
-/* $Id: JoinAccessor.java -1   $ */
-
-/**
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements. See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License. You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package org.apache.warthog.api;
-
-import java.util.*;
-
-/** Accessor class that returns a join of two tables.
-*/
-public class JoinAccessor implements WHAccessor
-{
-  protected WHAccessor primeAccessor;
-  protected WHRelationshipBuilder secondaryRelationshipBuilder;
-  protected Map<String,String> secondaryColumnMap;
-  
-  protected WHAccessor currentSecondaryAccessor;
-  protected WHRowID currentRowID;
-    
-  public JoinAccessor(WHAccessor primeAccessor, WHRelationshipBuilder secondaryRelationshipBuilder,
-    Map<String,String> secondaryColumnMap)
-    throws WHException
-  {
-    this.primeAccessor = primeAccessor;
-    this.secondaryRelationshipBuilder = secondaryRelationshipBuilder;
-    this.secondaryColumnMap = secondaryColumnMap;
-    goToNextLegalRow();
-  }
-  
-  protected void goToNextLegalRow()
-    throws WHException
-  {
-    while (true)
-    {
-      WHRowID primeRowID = primeAccessor.getCurrentRowID();
-      if (primeRowID == null)
-      {
-        currentRowID = null;
-        return;
-      }
-      if (currentSecondaryAccessor == null)
-      {
-        currentSecondaryAccessor = secondaryRelationshipBuilder.createRelationship(primeAccessor).buildAccessor();
-      }
-      WHRowID secondaryRowID = currentSecondaryAccessor.getCurrentRowID();
-      if (secondaryRowID == null)
-      {
-        // Done with secondary for this primary row, so advance primary
-        primeAccessor.advance();
-        currentSecondaryAccessor = null;
-        // Since we haven't found a row yet, loop
-        continue;
-      }
-      // We've found a row!  Construct a row ID
-      currentRowID = new JoinRowID(primeRowID,secondaryRowID);
-      break;
-    }
-  }
-
-  /** Advance to the next row.
-  */
-  public void advance()
-    throws WHException
-  {
-    if (currentRowID != null)
-    {
-      currentSecondaryAccessor.advance();
-      goToNextLegalRow();
-    }
-  }
-  
-  /** Read the current relationship row ID,  Null will be returned if we are
-  * at the end of the sequence.
-  */
-  public WHRowID getCurrentRowID()
-    throws WHException
-  {
-    return currentRowID;
-  }
-	
-  /** Get the data for the current row and specified column. 
-  */
-  public WHValue getValue(String columnName)
-    throws WHException
-  {
-    String secondaryKey = secondaryColumnMap.get(columnName);
-    if (secondaryKey == null)
-      return primeAccessor.getValue(columnName);
-    return currentSecondaryAccessor.getValue(secondaryKey);
-  }
-
-  /** This class represents a joined rowID */
-  protected static class JoinRowID implements WHRowID
-  {
-    protected WHRowID primaryRow;
-    protected WHRowID secondaryRow;
-    
-    public JoinRowID(WHRowID primaryRow, WHRowID secondaryRow)
-    {
-      this.primaryRow = primaryRow;
-      this.secondaryRow = secondaryRow;
-    }
-  }
-  
-}
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.apache.warthog.api;
+
+import java.util.*;
+
+/** Accessor class that returns a join of two tables.
+*/
+public class JoinAccessor implements WHAccessor
+{
+  protected WHAccessor primeAccessor;
+  protected WHRelationshipBuilder secondaryRelationshipBuilder;
+  protected Map<String,String> secondaryColumnMap;
+  
+  protected WHAccessor currentSecondaryAccessor;
+  protected WHRowID currentRowID;
+    
+  public JoinAccessor(WHAccessor primeAccessor, WHRelationshipBuilder secondaryRelationshipBuilder,
+    Map<String,String> secondaryColumnMap)
+    throws WHException
+  {
+    this.primeAccessor = primeAccessor;
+    this.secondaryRelationshipBuilder = secondaryRelationshipBuilder;
+    this.secondaryColumnMap = secondaryColumnMap;
+    goToNextLegalRow();
+  }
+  
+  protected void goToNextLegalRow()
+    throws WHException
+  {
+    while (true)
+    {
+      WHRowID primeRowID = primeAccessor.getCurrentRowID();
+      if (primeRowID == null)
+      {
+        currentRowID = null;
+        return;
+      }
+      if (currentSecondaryAccessor == null)
+      {
+        currentSecondaryAccessor = secondaryRelationshipBuilder.createRelationship(primeAccessor).buildAccessor();
+      }
+      WHRowID secondaryRowID = currentSecondaryAccessor.getCurrentRowID();
+      if (secondaryRowID == null)
+      {
+        // Done with secondary for this primary row, so advance primary
+        primeAccessor.advance();
+        currentSecondaryAccessor = null;
+        // Since we haven't found a row yet, loop
+        continue;
+      }
+      // We've found a row!  Construct a row ID
+      currentRowID = new JoinRowID(primeRowID,secondaryRowID);
+      break;
+    }
+  }
+
+  /** Advance to the next row.
+  */
+  public void advance()
+    throws WHException
+  {
+    if (currentRowID != null)
+    {
+      currentSecondaryAccessor.advance();
+      goToNextLegalRow();
+    }
+  }
+  
+  /** Read the current relationship row ID,  Null will be returned if we are
+  * at the end of the sequence.
+  */
+  public WHRowID getCurrentRowID()
+    throws WHException
+  {
+    return currentRowID;
+  }
+	
+  /** Get the data for the current row and specified column. 
+  */
+  public WHValue getValue(String columnName)
+    throws WHException
+  {
+    String secondaryKey = secondaryColumnMap.get(columnName);
+    if (secondaryKey == null)
+      return primeAccessor.getValue(columnName);
+    return currentSecondaryAccessor.getValue(secondaryKey);
+  }
+
+  /** This class represents a joined rowID */
+  protected static class JoinRowID implements WHRowID
+  {
+    protected WHRowID primaryRow;
+    protected WHRowID secondaryRow;
+    
+    public JoinRowID(WHRowID primaryRow, WHRowID secondaryRow)
+    {
+      this.primaryRow = primaryRow;
+      this.secondaryRow = secondaryRow;
+    }
+  }
+  
+}

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/JoinAccessor.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/JoinAccessor.java
------------------------------------------------------------------------------
    svn:keywords = Id

Modified: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/JoinRelationship.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/JoinRelationship.java?rev=1220353&r1=1220352&r2=1220353&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/JoinRelationship.java (original)
+++ incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/JoinRelationship.java Sun Dec 18 08:36:52 2011
@@ -1,80 +1,80 @@
-/* $Id: JoinRelationship.java -1   $ */
-
-/**
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements. See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License. You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package org.apache.warthog.api;
-
-import java.util.*;
-
-/** This relationship type represents the joining of a primary relationship and a
-* secondary relationship, plus a joining criteria, yielding a result with columns that
-* includes the columns from both.  To build a three-way join, just nest join
-* relationships appropriately.
-*/
-public class JoinRelationship implements WHRelationship
-{
-  protected WHRelationship primeRelationship;
-  protected WHRelationshipBuilder secondaryRelationshipBuilder;
-  
-  protected Map<String,String> secondaryColumnMap;
-  protected String[] returnColumns;
-  
-  /** Constructor. */
-  public JoinRelationship(WHRelationship primeRelationship,
-    String[] secondaryColumns,
-    String[] secondaryReturnColumns,
-    WHRelationshipBuilder secondaryRelationshipBuilder)
-    throws WHException
-  {
-    if (secondaryColumns.length != secondaryReturnColumns.length)
-      throw new WHException("Secondary columns and return columns must be the same number");
-    this.primeRelationship = primeRelationship;
-    this.secondaryRelationshipBuilder = secondaryRelationshipBuilder;
-    String[] primaryColumns = primeRelationship.getColumnNames();
-    returnColumns = new String[primaryColumns.length + secondaryReturnColumns.length];
-    int position = 0;
-    for (int i = 0 ; i < primaryColumns.length ; i++)
-    {
-      returnColumns[position++] = primaryColumns[i];
-    }
-    secondaryColumnMap = new HashMap<String,String>();
-    for (int i = 0 ; i < secondaryReturnColumns.length ; i++)
-    {
-      returnColumns[position++] = secondaryReturnColumns[i];
-      secondaryColumnMap.put(secondaryReturnColumns[i],secondaryColumns[i]);
-    }
-  }
-  
-  /** Get the column names represented by the relationship. */
-  public String[] getColumnNames()
-    throws WHException
-  {
-    return returnColumns;
-  }
-
-  /** Get the row accessor.  This determines
-  * both the initial set of rows and the ordering.  The results can be later filtered to
-  * yield the final output data.
-  */
-  public WHAccessor buildAccessor()
-    throws WHException
-  {
-    return new JoinAccessor(primeRelationship.buildAccessor(),secondaryRelationshipBuilder,secondaryColumnMap);
-  }
-  
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.apache.warthog.api;
+
+import java.util.*;
+
+/** This relationship type represents the joining of a primary relationship and a
+* secondary relationship, plus a joining criteria, yielding a result with columns that
+* includes the columns from both.  To build a three-way join, just nest join
+* relationships appropriately.
+*/
+public class JoinRelationship implements WHRelationship
+{
+  protected WHRelationship primeRelationship;
+  protected WHRelationshipBuilder secondaryRelationshipBuilder;
+  
+  protected Map<String,String> secondaryColumnMap;
+  protected String[] returnColumns;
+  
+  /** Constructor. */
+  public JoinRelationship(WHRelationship primeRelationship,
+    String[] secondaryColumns,
+    String[] secondaryReturnColumns,
+    WHRelationshipBuilder secondaryRelationshipBuilder)
+    throws WHException
+  {
+    if (secondaryColumns.length != secondaryReturnColumns.length)
+      throw new WHException("Secondary columns and return columns must be the same number");
+    this.primeRelationship = primeRelationship;
+    this.secondaryRelationshipBuilder = secondaryRelationshipBuilder;
+    String[] primaryColumns = primeRelationship.getColumnNames();
+    returnColumns = new String[primaryColumns.length + secondaryReturnColumns.length];
+    int position = 0;
+    for (int i = 0 ; i < primaryColumns.length ; i++)
+    {
+      returnColumns[position++] = primaryColumns[i];
+    }
+    secondaryColumnMap = new HashMap<String,String>();
+    for (int i = 0 ; i < secondaryReturnColumns.length ; i++)
+    {
+      returnColumns[position++] = secondaryReturnColumns[i];
+      secondaryColumnMap.put(secondaryReturnColumns[i],secondaryColumns[i]);
+    }
+  }
+  
+  /** Get the column names represented by the relationship. */
+  public String[] getColumnNames()
+    throws WHException
+  {
+    return returnColumns;
+  }
+
+  /** Get the row accessor.  This determines
+  * both the initial set of rows and the ordering.  The results can be later filtered to
+  * yield the final output data.
+  */
+  public WHAccessor buildAccessor()
+    throws WHException
+  {
+    return new JoinAccessor(primeRelationship.buildAccessor(),secondaryRelationshipBuilder,secondaryColumnMap);
+  }
+  
 }
\ No newline at end of file

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/JoinRelationship.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/JoinRelationship.java
------------------------------------------------------------------------------
    svn:keywords = Id

Modified: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/RowSkipAccessor.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/RowSkipAccessor.java?rev=1220353&r1=1220352&r2=1220353&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/RowSkipAccessor.java (original)
+++ incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/RowSkipAccessor.java Sun Dec 18 08:36:52 2011
@@ -1,96 +1,96 @@
-/* $Id: RowSkipAccessor.java -1   $ */
-
-/**
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements. See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License. You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package org.apache.warthog.api;
-
-/** Accessor class that returns only rows from a parent between a specific numeric range.
-*/
-public class RowSkipAccessor implements WHAccessor
-{
-  protected WHAccessor baseAccessor;
-  protected Long startRow;
-  protected Long endRow;
-  protected WHRowID currentRowID;
-  long rowNumber = 0L;
-    
-  public RowSkipAccessor(WHAccessor baseAccessor, Long startRow, Long rowCount)
-    throws WHException
-  {
-    this.baseAccessor = baseAccessor;
-    this.startRow = startRow;
-    if (rowCount != null)
-      endRow = new Long(((startRow==null)?0L:startRow.longValue())+rowCount.longValue());
-    else
-      endRow = null;
-    goToNextLegalRow();
-  }
-  
-  protected void goToNextLegalRow()
-    throws WHException
-  {
-    while (true)
-    {
-      currentRowID = baseAccessor.getCurrentRowID();
-      if (currentRowID == null)
-        return;
-      if (startRow != null && rowNumber < startRow.longValue())
-      {
-        rowNumber++;
-        baseAccessor.advance();
-        continue;
-      }
-      if (endRow != null && rowNumber >= endRow.longValue())
-      {
-        currentRowID = null;
-        return;
-      }
-      break;
-    }
-  }
-
-  /** Advance to the next row.
-  */
-  public void advance()
-    throws WHException
-  {
-    if (currentRowID != null)
-    {
-      baseAccessor.advance();
-      goToNextLegalRow();
-    }
-  }
-  
-  /** Read the current relationship row ID,  Null will be returned if we are
-  * at the end of the sequence.
-  */
-  public WHRowID getCurrentRowID()
-    throws WHException
-  {
-    return currentRowID;
-  }
-	
-  /** Get the data for the current row and specified column. 
-  */
-  public WHValue getValue(String columnName)
-    throws WHException
-  {
-    return baseAccessor.getValue(columnName);
-  }
-
-}
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.apache.warthog.api;
+
+/** Accessor class that returns only rows from a parent between a specific numeric range.
+*/
+public class RowSkipAccessor implements WHAccessor
+{
+  protected WHAccessor baseAccessor;
+  protected Long startRow;
+  protected Long endRow;
+  protected WHRowID currentRowID;
+  long rowNumber = 0L;
+    
+  public RowSkipAccessor(WHAccessor baseAccessor, Long startRow, Long rowCount)
+    throws WHException
+  {
+    this.baseAccessor = baseAccessor;
+    this.startRow = startRow;
+    if (rowCount != null)
+      endRow = new Long(((startRow==null)?0L:startRow.longValue())+rowCount.longValue());
+    else
+      endRow = null;
+    goToNextLegalRow();
+  }
+  
+  protected void goToNextLegalRow()
+    throws WHException
+  {
+    while (true)
+    {
+      currentRowID = baseAccessor.getCurrentRowID();
+      if (currentRowID == null)
+        return;
+      if (startRow != null && rowNumber < startRow.longValue())
+      {
+        rowNumber++;
+        baseAccessor.advance();
+        continue;
+      }
+      if (endRow != null && rowNumber >= endRow.longValue())
+      {
+        currentRowID = null;
+        return;
+      }
+      break;
+    }
+  }
+
+  /** Advance to the next row.
+  */
+  public void advance()
+    throws WHException
+  {
+    if (currentRowID != null)
+    {
+      baseAccessor.advance();
+      goToNextLegalRow();
+    }
+  }
+  
+  /** Read the current relationship row ID,  Null will be returned if we are
+  * at the end of the sequence.
+  */
+  public WHRowID getCurrentRowID()
+    throws WHException
+  {
+    return currentRowID;
+  }
+	
+  /** Get the data for the current row and specified column. 
+  */
+  public WHValue getValue(String columnName)
+    throws WHException
+  {
+    return baseAccessor.getValue(columnName);
+  }
+
+}

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/RowSkipAccessor.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/RowSkipAccessor.java
------------------------------------------------------------------------------
    svn:keywords = Id

Modified: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/RowSkipRelationship.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/RowSkipRelationship.java?rev=1220353&r1=1220352&r2=1220353&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/RowSkipRelationship.java (original)
+++ incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/RowSkipRelationship.java Sun Dec 18 08:36:52 2011
@@ -1,55 +1,55 @@
-/* $Id: RowSkipRelationship.java -1   $ */
-
-/**
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements. See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License. You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package org.apache.warthog.api;
-
-/** This relationship type applies row filtering on top of another relationship.
-*/
-public class RowSkipRelationship implements WHRelationship
-{
-  protected WHRelationship relationshipToFilter;
-  Long startRow;
-  Long rowCount;
-  
-  /** Constructor */
-  public RowSkipRelationship(WHRelationship relationshipToFilter, Long startRow, Long rowCount)
-  {
-    this.relationshipToFilter = relationshipToFilter;
-    this.startRow = startRow;
-    this.rowCount = rowCount;
-  }
-  
-  /** Get the column names represented by the relationship. */
-  public String[] getColumnNames()
-    throws WHException
-  {
-    return relationshipToFilter.getColumnNames();
-  }
-
-  /** Get the row accessor.  This determines
-  * both the initial set of rows and the ordering.  The results can be later filtered to
-  * yield the final output data.
-  */
-  public WHAccessor buildAccessor()
-    throws WHException
-  {
-    return new RowSkipAccessor(relationshipToFilter.buildAccessor(),startRow,rowCount);
-  }
-  
-}
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.apache.warthog.api;
+
+/** This relationship type applies row filtering on top of another relationship.
+*/
+public class RowSkipRelationship implements WHRelationship
+{
+  protected WHRelationship relationshipToFilter;
+  Long startRow;
+  Long rowCount;
+  
+  /** Constructor */
+  public RowSkipRelationship(WHRelationship relationshipToFilter, Long startRow, Long rowCount)
+  {
+    this.relationshipToFilter = relationshipToFilter;
+    this.startRow = startRow;
+    this.rowCount = rowCount;
+  }
+  
+  /** Get the column names represented by the relationship. */
+  public String[] getColumnNames()
+    throws WHException
+  {
+    return relationshipToFilter.getColumnNames();
+  }
+
+  /** Get the row accessor.  This determines
+  * both the initial set of rows and the ordering.  The results can be later filtered to
+  * yield the final output data.
+  */
+  public WHAccessor buildAccessor()
+    throws WHException
+  {
+    return new RowSkipAccessor(relationshipToFilter.buildAccessor(),startRow,rowCount);
+  }
+  
+}

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/RowSkipRelationship.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/RowSkipRelationship.java
------------------------------------------------------------------------------
    svn:keywords = Id

Modified: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHAccessor.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHAccessor.java?rev=1220353&r1=1220352&r2=1220353&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHAccessor.java (original)
+++ incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHAccessor.java Sun Dec 18 08:36:52 2011
@@ -1,44 +1,44 @@
-/* $Id: WHAccessor.java -1   $ */
-
-/**
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements. See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License. You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package org.apache.warthog.api;
-
-/** Use one of several means to find rows within a relationship.  The implementer
-* of this interface determines just how this is to be done.
-*/
-public interface WHAccessor
-{
-  /** Advance to the next row.
-  */
-  public void advance()
-    throws WHException;
-  
-  /** Read the current relationship row ID,  Null will be returned if we are
-  * at the end of the sequence.
-  */
-  public WHRowID getCurrentRowID()
-    throws WHException;
-	
-  /** Get the data for the current row and specified column. 
-  */
-  public WHValue getValue(String columnName)
-    throws WHException;
-
-
-}
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.apache.warthog.api;
+
+/** Use one of several means to find rows within a relationship.  The implementer
+* of this interface determines just how this is to be done.
+*/
+public interface WHAccessor
+{
+  /** Advance to the next row.
+  */
+  public void advance()
+    throws WHException;
+  
+  /** Read the current relationship row ID,  Null will be returned if we are
+  * at the end of the sequence.
+  */
+  public WHRowID getCurrentRowID()
+    throws WHException;
+	
+  /** Get the data for the current row and specified column. 
+  */
+  public WHValue getValue(String columnName)
+    throws WHException;
+
+
+}

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHAccessor.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHAccessor.java
------------------------------------------------------------------------------
    svn:keywords = Id

Modified: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHColumnCalculator.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHColumnCalculator.java?rev=1220353&r1=1220352&r2=1220353&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHColumnCalculator.java (original)
+++ incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHColumnCalculator.java Sun Dec 18 08:36:52 2011
@@ -1,65 +1,65 @@
-/* $Id: WHColumnCalculator.java -1   $ */
-
-/**
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements. See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License. You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package org.apache.warthog.api;
-
-/** Interface describing a set of return values for a result set.
-* This interface describes both row-based calculations AND
-* cross-row aggregations.  In order to do that, each instance receives
-* data from each row, and optionally coughs out a result value for the column.
-* Every time any column coughs out a value, the done() method will be called for all
-* the other columns as well, yielding a row of data.
-*
-* For some kinds of aggregation to work right it may require the accessor to order
-* results in a certain way.  This should be readily acheivable, however, with the use
-* of the proper indexes.
-* 
-* Note that the single-valued version of this abstraction is able to handle the
-* following well-known SQL constructs easily: SUM(), AVG(), MIN(), MAX(),
-* COUNT(), DISTINCT, and GROUP BY.
-*/
-public interface WHColumnCalculator
-{
-  /** Check whether a row can be added to to the column calculator.
-  * Does NOT actually change the result of the calculator!
-  *@param accessor is the current accessor.
-  *@return true if the row can be added, and false if it can't and a tally should be done immediately.
-  */
-  public boolean canProcessRowValue(WHAccessor accessor)
-    throws WHException;
-  
-  /** Check whether this calculator is capable of generating a final summary row value.
-  *@return true if it is capable.  tally() will only be called at the end for the summary
-  *     row if all columns are capable of generating a summary value.
-  */
-  public boolean canGenerateSummaryValue()
-    throws WHException;
-  
-  /** Feed a row to the column calculator.
-  */
-  public void processRowValue(WHAccessor accessor)
-    throws WHException;
-  
-  /** Tally a final result, obtaining whatever current aggregate value there is.
-  * Also resets the calculator in preparation for another set of rows.
-  */
-  public WHValue tally()
-    throws WHException;
-
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.apache.warthog.api;
+
+/** Interface describing a set of return values for a result set.
+* This interface describes both row-based calculations AND
+* cross-row aggregations.  In order to do that, each instance receives
+* data from each row, and optionally coughs out a result value for the column.
+* Every time any column coughs out a value, the done() method will be called for all
+* the other columns as well, yielding a row of data.
+*
+* For some kinds of aggregation to work right it may require the accessor to order
+* results in a certain way.  This should be readily acheivable, however, with the use
+* of the proper indexes.
+* 
+* Note that the single-valued version of this abstraction is able to handle the
+* following well-known SQL constructs easily: SUM(), AVG(), MIN(), MAX(),
+* COUNT(), DISTINCT, and GROUP BY.
+*/
+public interface WHColumnCalculator
+{
+  /** Check whether a row can be added to to the column calculator.
+  * Does NOT actually change the result of the calculator!
+  *@param accessor is the current accessor.
+  *@return true if the row can be added, and false if it can't and a tally should be done immediately.
+  */
+  public boolean canProcessRowValue(WHAccessor accessor)
+    throws WHException;
+  
+  /** Check whether this calculator is capable of generating a final summary row value.
+  *@return true if it is capable.  tally() will only be called at the end for the summary
+  *     row if all columns are capable of generating a summary value.
+  */
+  public boolean canGenerateSummaryValue()
+    throws WHException;
+  
+  /** Feed a row to the column calculator.
+  */
+  public void processRowValue(WHAccessor accessor)
+    throws WHException;
+  
+  /** Tally a final result, obtaining whatever current aggregate value there is.
+  * Also resets the calculator in preparation for another set of rows.
+  */
+  public WHValue tally()
+    throws WHException;
+
 }
\ No newline at end of file

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHColumnCalculator.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHColumnCalculator.java
------------------------------------------------------------------------------
    svn:keywords = Id

Modified: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHColumnDescription.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHColumnDescription.java?rev=1220353&r1=1220352&r2=1220353&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHColumnDescription.java (original)
+++ incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHColumnDescription.java Sun Dec 18 08:36:52 2011
@@ -1,37 +1,37 @@
-/* $Id: WHColumnDescription.java -1   $ */
-
-/**
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements. See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License. You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package org.apache.warthog.api;
-
-/** Interface describing a return value for a result set.
-* This interface describes the name of the returned column,
-* and provides a factory for creating a matching column calculator,
-* to go along with each accessor.
-*/
-public interface WHColumnDescription
-{
-  /** Get the name of the return column */
-  public String getReturnColumnName()
-    throws WHException;
-  
-  /** Create a return column calculator for this column.
-  */
-  public WHColumnCalculator createCalculator()
-    throws WHException;
-}
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.apache.warthog.api;
+
+/** Interface describing a return value for a result set.
+* This interface describes the name of the returned column,
+* and provides a factory for creating a matching column calculator,
+* to go along with each accessor.
+*/
+public interface WHColumnDescription
+{
+  /** Get the name of the return column */
+  public String getReturnColumnName()
+    throws WHException;
+  
+  /** Create a return column calculator for this column.
+  */
+  public WHColumnCalculator createCalculator()
+    throws WHException;
+}

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHColumnDescription.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHColumnDescription.java
------------------------------------------------------------------------------
    svn:keywords = Id

Modified: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHComparator.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHComparator.java?rev=1220353&r1=1220352&r2=1220353&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHComparator.java (original)
+++ incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHComparator.java Sun Dec 18 08:36:52 2011
@@ -1,39 +1,39 @@
-/* $Id: WHComparator.java -1   $ */
-
-/**
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements. See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License. You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package org.apache.warthog.api;
-
-/** Interface that describes comparison functionality.
-* This is an underpinning of the btree structure.
-*/
-public interface WHComparator
-{
-  // Comparison result values
-  
-  public static int RESULT_EQUALS = 0;
-  public static int RESULT_LESS = -1;
-  public static int RESULT_GREATER = 1;
-  
-  /** Comparison method.
-  * This is only ever used to compare values; it cannot be used to compare null vs. non-null.
-  */
-  public int compare(WHValue leftValue, WHValue rightValue)
-    throws WHException;
-  
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.apache.warthog.api;
+
+/** Interface that describes comparison functionality.
+* This is an underpinning of the btree structure.
+*/
+public interface WHComparator
+{
+  // Comparison result values
+  
+  public static int RESULT_EQUALS = 0;
+  public static int RESULT_LESS = -1;
+  public static int RESULT_GREATER = 1;
+  
+  /** Comparison method.
+  * This is only ever used to compare values; it cannot be used to compare null vs. non-null.
+  */
+  public int compare(WHValue leftValue, WHValue rightValue)
+    throws WHException;
+  
 }
\ No newline at end of file

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHComparator.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHComparator.java
------------------------------------------------------------------------------
    svn:keywords = Id

Modified: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHConcurrencyException.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHConcurrencyException.java?rev=1220353&r1=1220352&r2=1220353&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHConcurrencyException.java (original)
+++ incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHConcurrencyException.java Sun Dec 18 08:36:52 2011
@@ -1,36 +1,36 @@
-/* $Id: WHConcurrencyException.java -1   $ */
-
-/**
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements. See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License. You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package org.apache.warthog.api;
-
-/** This exception is special in that it indicates a deadlock detection, which means
-* transaction has to be backed out and retried from start.
-*/
-public class WHConcurrencyException extends WHException
-{
-  public WHConcurrencyException()
-  {
-    super("Concurrent modification detected");
-  }
-  
-  public WHConcurrencyException(String msg)
-  {
-    super(msg);
-  }
-}
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.apache.warthog.api;
+
+/** This exception is special in that it indicates a deadlock detection, which means
+* transaction has to be backed out and retried from start.
+*/
+public class WHConcurrencyException extends WHException
+{
+  public WHConcurrencyException()
+  {
+    super("Concurrent modification detected");
+  }
+  
+  public WHConcurrencyException(String msg)
+  {
+    super(msg);
+  }
+}

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHConcurrencyException.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHConcurrencyException.java
------------------------------------------------------------------------------
    svn:keywords = Id

Modified: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHException.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHException.java?rev=1220353&r1=1220352&r2=1220353&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHException.java (original)
+++ incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHException.java Sun Dec 18 08:36:52 2011
@@ -1,34 +1,34 @@
-/* $Id: WHException.java -1   $ */
-
-/**
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements. See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License. You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package org.apache.warthog.api;
-
-/** General exception */
-public class WHException extends Exception
-{
-  public WHException(String message)
-  {
-    super(message);
-  }
-  
-  public WHException(String message, Throwable e)
-  {
-    super(message,e);
-  }
-}
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.apache.warthog.api;
+
+/** General exception */
+public class WHException extends Exception
+{
+  public WHException(String message)
+  {
+    super(message);
+  }
+  
+  public WHException(String message, Throwable e)
+  {
+    super(message,e);
+  }
+}

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHException.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHException.java
------------------------------------------------------------------------------
    svn:keywords = Id

Modified: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHIndex.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHIndex.java?rev=1220353&r1=1220352&r2=1220353&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHIndex.java (original)
+++ incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHIndex.java Sun Dec 18 08:36:52 2011
@@ -1,49 +1,49 @@
-/* $Id: WHIndex.java -1   $ */
-
-/**
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements. See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License. You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package org.apache.warthog.api;
-
-/** This abstraction provides access to a btree index.   Note: This is a permanent
-* structure, and can only index a permanent table.
-*/
-public interface WHIndex extends WHRelationship
-{
-  /** Get the underlying relationship the index applies to.
-  */
-  public WHRelationship getRelationship()
-    throws WHException;
-  
-  // Additional accessor support method.
-  //
-  // Index access supports any kind of matches which allow pruning of whole subtrees
-  // during index scanning.  Effectively this means that any criteria supplied must have
-  // something to do with the comparator order for this index and the column in
-  // question.
-  
-  /** Create an accessor based on this index which uses the provided criteria.  The
-  * criteria must align with the index's columns.  Null values are permitted where
-  * no criteria are present. 
-  *@param criteria are the criteria that apply to each individual index column; null for no criteria at all.
-  *@param orderReversed is a boolean for each individual index column; true if the comparator order of that column
-  * should be reversed for the accessor.  Null indicates no reversal for any column.
-  */
-  public WHAccessor buildAccessor(IndexCriteria[] criteria, boolean[] orderReversed)
-    throws WHException;
-  
-}
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.apache.warthog.api;
+
+/** This abstraction provides access to a btree index.   Note: This is a permanent
+* structure, and can only index a permanent table.
+*/
+public interface WHIndex extends WHRelationship
+{
+  /** Get the underlying relationship the index applies to.
+  */
+  public WHRelationship getRelationship()
+    throws WHException;
+  
+  // Additional accessor support method.
+  //
+  // Index access supports any kind of matches which allow pruning of whole subtrees
+  // during index scanning.  Effectively this means that any criteria supplied must have
+  // something to do with the comparator order for this index and the column in
+  // question.
+  
+  /** Create an accessor based on this index which uses the provided criteria.  The
+  * criteria must align with the index's columns.  Null values are permitted where
+  * no criteria are present. 
+  *@param criteria are the criteria that apply to each individual index column; null for no criteria at all.
+  *@param orderReversed is a boolean for each individual index column; true if the comparator order of that column
+  * should be reversed for the accessor.  Null indicates no reversal for any column.
+  */
+  public WHAccessor buildAccessor(IndexCriteria[] criteria, boolean[] orderReversed)
+    throws WHException;
+  
+}

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHIndex.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHIndex.java
------------------------------------------------------------------------------
    svn:keywords = Id

Modified: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRelationship.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRelationship.java?rev=1220353&r1=1220352&r2=1220353&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRelationship.java (original)
+++ incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRelationship.java Sun Dec 18 08:36:52 2011
@@ -1,39 +1,39 @@
-/* $Id: WHRelationship.java -1   $ */
-
-/**
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements. See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License. You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package org.apache.warthog.api;
-
-/** This describes an abstract "table" of rows and columns.  This can be implemented
-* in a number of ways: as a straight table, as a join (with join criteria), and as the
-* result of a query.
-*/
-public interface WHRelationship
-{
-  /** Get the column names represented by the relationship. */
-  public String[] getColumnNames()
-    throws WHException;
-  
-  /** Get the row accessor.  This determines
-  * both the initial set of rows and the ordering.  The results can be later filtered to
-  * yield the final output data.
-  */
-  public WHAccessor buildAccessor()
-    throws WHException;
-  
-}
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.apache.warthog.api;
+
+/** This describes an abstract "table" of rows and columns.  This can be implemented
+* in a number of ways: as a straight table, as a join (with join criteria), and as the
+* result of a query.
+*/
+public interface WHRelationship
+{
+  /** Get the column names represented by the relationship. */
+  public String[] getColumnNames()
+    throws WHException;
+  
+  /** Get the row accessor.  This determines
+  * both the initial set of rows and the ordering.  The results can be later filtered to
+  * yield the final output data.
+  */
+  public WHAccessor buildAccessor()
+    throws WHException;
+  
+}

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRelationship.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRelationship.java
------------------------------------------------------------------------------
    svn:keywords = Id

Modified: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRelationshipBuilder.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRelationshipBuilder.java?rev=1220353&r1=1220352&r2=1220353&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRelationshipBuilder.java (original)
+++ incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRelationshipBuilder.java Sun Dec 18 08:36:52 2011
@@ -1,33 +1,33 @@
-/* $Id: WHRelationshipBuilder.java -1   $ */
-
-/**
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements. See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License. You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package org.apache.warthog.api;
-
-/** Classes that implement this interface construct WHRelationship objects based
-* on criteria they receive from a specific row in another relationship.
-*/
-public interface WHRelationshipBuilder
-{
-  /** Construct a relationship based on the specified row of the specified
-  * relationship.
-  */
-  public WHRelationship createRelationship(WHAccessor accessor)
-    throws WHException;
-  
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.apache.warthog.api;
+
+/** Classes that implement this interface construct WHRelationship objects based
+* on criteria they receive from a specific row in another relationship.
+*/
+public interface WHRelationshipBuilder
+{
+  /** Construct a relationship based on the specified row of the specified
+  * relationship.
+  */
+  public WHRelationship createRelationship(WHAccessor accessor)
+    throws WHException;
+  
 }
\ No newline at end of file

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRelationshipBuilder.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRelationshipBuilder.java
------------------------------------------------------------------------------
    svn:keywords = Id

Modified: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRowID.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRowID.java?rev=1220353&r1=1220352&r2=1220353&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRowID.java (original)
+++ incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRowID.java Sun Dec 18 08:36:52 2011
@@ -1,32 +1,32 @@
-/* $Id: WHRowID.java -1   $ */
-
-/**
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements. See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License. You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package org.apache.warthog.api;
-
-/** This interface describes a kind of key or value that is used to describe
-* a table row.  For simple tables, the implementation is likely to be just a 
-* LongValue, but for joins there is likely to be a compound value consisting of
-* individual WHRowID's from each table participating in the join.  The basic
-* idea is that the precise form of a row ID is only known to the relationship
-* from which it came (and in which it will be interpreted).
-*/
-public interface WHRowID
-{
-  // Right at the moment, there are no special methods needed
-}
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.apache.warthog.api;
+
+/** This interface describes a kind of key or value that is used to describe
+* a table row.  For simple tables, the implementation is likely to be just a 
+* LongValue, but for joins there is likely to be a compound value consisting of
+* individual WHRowID's from each table participating in the join.  The basic
+* idea is that the precise form of a row ID is only known to the relationship
+* from which it came (and in which it will be interpreted).
+*/
+public interface WHRowID
+{
+  // Right at the moment, there are no special methods needed
+}

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRowID.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHRowID.java
------------------------------------------------------------------------------
    svn:keywords = Id

Modified: incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHTable.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHTable.java?rev=1220353&r1=1220352&r2=1220353&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHTable.java (original)
+++ incubator/lcf/branches/CONNECTORS-286/warthog-reimport/src/main/java/org/apache/warthog/api/WHTable.java Sun Dec 18 08:36:52 2011
@@ -1,41 +1,41 @@
-/* $Id: WHTable.java -1   $ */
-
-/**
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements. See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License. You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-package org.apache.warthog.api;
-
-/** This abstraction permits access to a table structure.  An object of this kind can ONLY
-* be used within the context of the WHTableStore object that created it.  Note: This is a
-* permanent structure.
-*/
-public interface WHTable extends WHRelationship
-{
-  /** Insert a row */
-  public void insertRow(String[] columns, WHValue[] values)
-    throws WHException;
-  
-  /** Update row(s) */
-  public void updateRows(String[] columns, WHValue[] values,
-    WHAccessor accessor)
-    throws WHException;
-    
-  /** Delete row(s) */
-  public void deleteRows(WHAccessor accessor)
-    throws WHException;
-  
+/* $Id$ */
+
+/**
+* Licensed to the Apache Software Foundation (ASF) under one or more
+* contributor license agreements. See the NOTICE file distributed with
+* this work for additional information regarding copyright ownership.
+* The ASF licenses this file to You under the Apache License, Version 2.0
+* (the "License"); you may not use this file except in compliance with
+* the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+package org.apache.warthog.api;
+
+/** This abstraction permits access to a table structure.  An object of this kind can ONLY
+* be used within the context of the WHTableStore object that created it.  Note: This is a
+* permanent structure.
+*/
+public interface WHTable extends WHRelationship
+{
+  /** Insert a row */
+  public void insertRow(String[] columns, WHValue[] values)
+    throws WHException;
+  
+  /** Update row(s) */
+  public void updateRows(String[] columns, WHValue[] values,
+    WHAccessor accessor)
+    throws WHException;
+    
+  /** Delete row(s) */
+  public void deleteRows(WHAccessor accessor)
+    throws WHException;
+  
 }
\ No newline at end of file



Mime
View raw message