/*
Copyright 2013 Edward Capriolo, Matt Landolf, Lodwin Cueto

Licensed 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 io.teknek.model;

import java.util.Map;

/**
 * Represents processing logic 
 *
 */
public abstract class Operator {

  protected Map<String,Object> properties;
  protected ICollector collector;
  
  public void setProperties(Map<String,Object> properties){
    this.properties = properties;
  }
  
  public abstract void handleTuple(ITuple t);
  
  public void setCollector(ICollector i){
    this.collector = i;
  }
  
  public ICollector getCollector(){
    return this.collector;
  }

  public Map<String, Object> getProperties() {
    return properties;
  }
  
}

@@ -576,16 +576,17 @@
 icense.%0A
+ 
 */%0Apacka
@@ -667,50 +667,233 @@
 ogic
- %0A *%0A */%0Apublic abstract class Operator %7B%0A
+. An operator takes a tuple as input and emits 0 or more tuples to the%0A * output collector.%0A * %0A */%0Apublic abstract class Operator %7B%0A%0A  /**%0A   * Configuration properties that are passed at initialization to the operator%0A   */
 %0A  p
@@ -904,32 +904,33 @@
 cted Map%3CString,
+ 
 Object%3E properti
@@ -932,16 +932,88 @@
 perties;
+%0A%0A  /**%0A   * Container that holds tuples emitted from the operator%0A   */
 %0A  prote
@@ -1039,18 +1039,213 @@
 lector;%0A
+%0A
   
+public Operator() %7B%0A    super();%0A  %7D%0A%0A  /**%0A   * Sets the properties of the operator. Called once after object construction and before the plan%0A   * is started%0A   * %0A   * @param properties%0A   */
 %0A  publi
@@ -1276,16 +1276,17 @@
 %3CString,
+ 
 Object%3E 
@@ -1296,16 +1296,17 @@
 perties)
+ 
 %7B%0A    th
@@ -1333,26 +1333,224 @@
 erties;%0A  %7D%0A
+%0A
   
+/**%0A   * Do some type of processing on this tuple. Note in many cases if this operator emit's a tuple a%0A   * new object should be created.%0A   * %0A   * @param tuple%0A   *          an input tuple%0A   */
 %0A  public ab
@@ -1581,21 +1581,23 @@
 ITuple t
+uple
 );%0A
-  
 %0A  publi
@@ -1629,16 +1629,17 @@
 ector i)
+ 
 %7B%0A    th
@@ -1660,18 +1660,16 @@
  i;%0A  %7D%0A
-  
 %0A  publi
@@ -1695,16 +1695,17 @@
 lector()
+ 
 %7B%0A    re
@@ -1804,13 +1804,11 @@
 es;%0A  %7D%0A
-  
 %0A%7D%0A

Document operator better-er