Examples of TimestampConverter


Examples of org.apache.ddlutils.io.converters.TimestampConverter

        NumberConverter          numberConverter = new NumberConverter();
        ByteArrayBase64Converter binaryConverter = new ByteArrayBase64Converter();

        registerConverter(Types.DATE,          new DateConverter());
        registerConverter(Types.TIME,          new TimeConverter());
        registerConverter(Types.TIMESTAMP,     new TimestampConverter());
        registerConverter(Types.BIGINT,        numberConverter);
        registerConverter(Types.BIT,           numberConverter);
        registerConverter(Types.DECIMAL,       numberConverter);
        registerConverter(Types.DOUBLE,        numberConverter);
        registerConverter(Types.FLOAT,         numberConverter);
View Full Code Here

Examples of org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorConverter.TimestampConverter

    } catch (ClassCastException e) {
      throw new UDFArgumentException(
          "The function TIMESTAMP takes only primitive types");
    }

    tc = new TimestampConverter(argumentOI,
        PrimitiveObjectInspectorFactory.writableTimestampObjectInspector);
    return PrimitiveObjectInspectorFactory.writableTimestampObjectInspector;
  }
View Full Code Here

Examples of org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorConverter.TimestampConverter

    } catch (ClassCastException e) {
      throw new UDFArgumentException(
          "The function " + getName() + " takes only primitive types");
    }

    timestampConverter = new TimestampConverter(argumentOIs[0],
        PrimitiveObjectInspectorFactory.writableTimestampObjectInspector);
    textConverter = new TextConverter(argumentOIs[1]);
    return PrimitiveObjectInspectorFactory.javaTimestampObjectInspector;
  }
View Full Code Here

Examples of org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorConverter.TimestampConverter

      textConverter = ObjectInspectorConverters.getConverter(
        (PrimitiveObjectInspector) arguments[0],
        PrimitiveObjectInspectorFactory.writableStringObjectInspector);
      break;
    case TIMESTAMP:
      timestampConverter = new TimestampConverter((PrimitiveObjectInspector) arguments[0],
        PrimitiveObjectInspectorFactory.writableTimestampObjectInspector);
      break;
    case DATE:
      dateWritableConverter = ObjectInspectorConverters.getConverter(
        (PrimitiveObjectInspector) arguments[0],
View Full Code Here

Examples of org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorConverter.TimestampConverter

    } catch (ClassCastException e) {
      throw new UDFArgumentException(
          "The function TIMESTAMP takes only primitive types");
    }

    tc = new TimestampConverter(argumentOI,
        PrimitiveObjectInspectorFactory.writableTimestampObjectInspector);
    return PrimitiveObjectInspectorFactory.writableTimestampObjectInspector;
  }
View Full Code Here

Examples of org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorConverter.TimestampConverter

      textConverter = ObjectInspectorConverters.getConverter(
        (PrimitiveObjectInspector) arguments[0],
        PrimitiveObjectInspectorFactory.writableStringObjectInspector);
      break;
    case TIMESTAMP:
      timestampConverter = new TimestampConverter((PrimitiveObjectInspector) arguments[0],
        PrimitiveObjectInspectorFactory.writableTimestampObjectInspector);
      break;
    case DATE:
      dateWritableConverter = ObjectInspectorConverters.getConverter(
        (PrimitiveObjectInspector) arguments[0],
View Full Code Here

Examples of org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorConverter.TimestampConverter

      converter = ObjectInspectorConverters.getConverter(
        (PrimitiveObjectInspector) arguments[i],
        PrimitiveObjectInspectorFactory.writableStringObjectInspector);
      break;
    case TIMESTAMP:
      converter = new TimestampConverter((PrimitiveObjectInspector) arguments[i],
        PrimitiveObjectInspectorFactory.writableTimestampObjectInspector);
      break;
    case DATE:
      converter = ObjectInspectorConverters.getConverter((PrimitiveObjectInspector)arguments[i],
        PrimitiveObjectInspectorFactory.writableDateObjectInspector);
View Full Code Here

Examples of org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorConverter.TimestampConverter

      inputType = PrimitiveCategory.STRING;
      textConverter = ObjectInspectorConverters.getConverter(
        argumentOI, PrimitiveObjectInspectorFactory.writableStringObjectInspector);
      break;
    case TIMESTAMP:
      timestampConverter = new TimestampConverter(argumentOI,
        PrimitiveObjectInspectorFactory.writableTimestampObjectInspector);
      break;
    case DATE:
      dateWritableConverter = ObjectInspectorConverters.getConverter(argumentOI,
          PrimitiveObjectInspectorFactory.writableDateObjectInspector);
View Full Code Here

Examples of org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorConverter.TimestampConverter

    } catch (ClassCastException e) {
      throw new UDFArgumentException(
          "The function " + getName() + " takes only primitive types");
    }

    timestampConverter = new TimestampConverter(argumentOIs[0],
        PrimitiveObjectInspectorFactory.writableTimestampObjectInspector);
    textConverter = new TextConverter(argumentOIs[1]);
    return PrimitiveObjectInspectorFactory.javaTimestampObjectInspector;
  }
View Full Code Here

Examples of org.apache.hadoop.hive.serde2.objectinspector.primitive.PrimitiveObjectInspectorConverter.TimestampConverter

      converter = ObjectInspectorConverters.getConverter(
        (PrimitiveObjectInspector) arguments[i],
        PrimitiveObjectInspectorFactory.writableStringObjectInspector);
      break;
    case TIMESTAMP:
      converter = new TimestampConverter((PrimitiveObjectInspector) arguments[i],
        PrimitiveObjectInspectorFactory.writableTimestampObjectInspector);
      break;
    case DATE:
      converter = ObjectInspectorConverters.getConverter((PrimitiveObjectInspector)arguments[i],
        PrimitiveObjectInspectorFactory.writableDateObjectInspector);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.