// Path: src/main/java/com/ebay/xcelite/annotate/NoConverterClass.java
// public final class NoConverterClass implements ColumnValueConverter<Object, Object> {
// 
//   @Override
//   public Object serialize(Object value) {
//     return value;
//   }
// 
//   @Override
//   public Object deserialize(Object value) {
//     return value;
//   }
// }
// 
// Path: src/main/java/com/ebay/xcelite/exceptions/XceliteException.java
// public class XceliteException extends RuntimeException {
// 
//   private static final long serialVersionUID = 1L;
// 
//   public XceliteException(String message) {
//     super(message);
//   }
// 
//   public XceliteException(Exception exception) {
//     super(exception);
//   }
// 
//   public XceliteException(String message, Exception exception) {
//     super(message, exception);
//   }
// }


import com.google.common.collect.Sets;
import static org.reflections.ReflectionUtils.withAnnotation;
import java.lang.reflect.Field;
import java.util.LinkedHashSet;
import java.util.Map;
import java.util.Set;
import org.reflections.ReflectionUtils;
import com.ebay.xcelite.annotate.NoConverterClass;
import com.ebay.xcelite.annotations.AnyColumn;
import com.ebay.xcelite.annotations.Column;
import com.ebay.xcelite.annotations.Row;
import com.ebay.xcelite.exceptions.XceliteException;
import com.google.common.collect.Maps;

      if (annotation.converter() != NoConverterClass.class) {
        col.setConverter(annotation.converter());
      }
      columns.add(col);
    }   
    
    if (colsOrdering != null) {
      orderColumns();
    }
    
    extractAnyColumn();
  }
  
  @SuppressWarnings("unchecked")
  private void extractAnyColumn() {
    Set<Field> anyColumnFields = ReflectionUtils.getAllFields(type, withAnnotation(AnyColumn.class));    
    if (anyColumnFields.size() > 0) {
      if (anyColumnFields.size() > 1) {
        throw new XceliteException("Multiple AnyColumn fields are not allowed");
      }
      Field anyColumnField = anyColumnFields.iterator().next();
      if (!anyColumnField.getType().isAssignableFrom(Map.class)) {
        throw new XceliteException(
            String.format("AnyColumn field \"%s\" should be of type Map.class or assignable from Map.class",
                anyColumnField.getName()));
      }
      anyColumn = new Col(anyColumnField.getName(), anyColumnField.getName());
      anyColumn.setAnyColumn(true);
      AnyColumn annotation = anyColumnField.getAnnotation(AnyColumn.class);
      anyColumn.setType(annotation.as());

// Path: src/main/java/com/ebay/xcelite/annotate/NoConverterClass.java
// public final class NoConverterClass implements ColumnValueConverter<Object, Object> {
// 
//   @Override
//   public Object serialize(Object value) {
//     return value;
//   }
// 
//   @Override
//   public Object deserialize(Object value) {
//     return value;
//   }
// }
// 
// Path: src/main/java/com/ebay/xcelite/exceptions/XceliteException.java
// public class XceliteException extends RuntimeException {
// 
//   private static final long serialVersionUID = 1L;
// 
//   public XceliteException(String message) {
//     super(message);
//   }
// 
//   public XceliteException(Exception exception) {
//     super(exception);
//   }
// 
//   public XceliteException(String message, Exception exception) {
//     super(message, exception);
//   }
// }


// Path: src/main/java/com/ebay/xcelite/column/ColumnsExtractor.java
import com.google.common.collect.Sets;
import static org.reflections.ReflectionUtils.withAnnotation;
import java.lang.reflect.Field;
import java.util.LinkedHashSet;
import java.util.Map;
import java.util.Set;
import org.reflections.ReflectionUtils;
import com.ebay.xcelite.annotate.NoConverterClass;
import com.ebay.xcelite.annotations.AnyColumn;
import com.ebay.xcelite.annotations.Column;
import com.ebay.xcelite.annotations.Row;
import com.ebay.xcelite.exceptions.XceliteException;
import com.google.common.collect.Maps;

      if (annotation.converter() != NoConverterClass.class) {
        col.setConverter(annotation.converter());
      }
      columns.add(col);
    }   
    
    if (colsOrdering != null) {
      orderColumns();
    }
    
    extractAnyColumn();
  }
  
  @SuppressWarnings("unchecked")
  private void extractAnyColumn() {
    Set<Field> anyColumnFields = ReflectionUtils.getAllFields(type, withAnnotation(AnyColumn.class));    
    if (anyColumnFields.size() > 0) {
      if (anyColumnFields.size() > 1) {
        throw new XceliteException("Multiple AnyColumn fields are not allowed");
      }
      Field anyColumnField = anyColumnFields.iterator().next();
      if (!anyColumnField.getType().isAssignableFrom(Map.class)) {
        throw new XceliteException(
            String.format("AnyColumn field \"%s\" should be of type Map.class or assignable from Map.class",
                anyColumnField.getName()));
      }
      anyColumn = new Col(anyColumnField.getName(), anyColumnField.getName());
      anyColumn.setAnyColumn(true);
      AnyColumn annotation = anyColumnField.getAnnotation(AnyColumn.class);
      anyColumn.setType(annotation.as());

      if (annotation.converter() != NoConverterClass.class) {
