Package org.apache.hadoop.hive.serde2.io

Examples of org.apache.hadoop.hive.serde2.io.HiveVarcharWritable


    // check input object's length, if it doesn't match
    // then output new writable with correct params.
    if (o == null) {
      return null;
    }
    HiveVarcharWritable writable = ((HiveVarcharWritable)o);
    if (doesWritableMatchTypeParams((HiveVarcharWritable)o)) {
      return writable;
    }

    return getWritableWithParams(writable);
View Full Code Here


    hv.setValue(val.getHiveVarchar(), getMaxLength());
    return hv;
  }

  private HiveVarcharWritable getWritableWithParams(HiveVarcharWritable val) {
    HiveVarcharWritable newValue = new HiveVarcharWritable();
    newValue.set(val, getMaxLength());
    return newValue;
  }
View Full Code Here

  @Override
  public Object copyObject(Object o) {
    if (o == null) {
      return null;
    }
    HiveVarcharWritable writable = (HiveVarcharWritable)o;
    if (doesWritableMatchTypeParams((HiveVarcharWritable)o)) {
      return new HiveVarcharWritable(writable);
    }
    return getWritableWithParams(writable);
  }
View Full Code Here

    return getWritableWithParams(writable);
  }

  @Override
  public Object set(Object o, HiveVarchar value) {
    HiveVarcharWritable writable = (HiveVarcharWritable)o;
    writable.set(value, getMaxLength());
    return o;
  }
View Full Code Here

    return o;
  }

  @Override
  public Object set(Object o, String value) {
    HiveVarcharWritable writable = (HiveVarcharWritable)o;
    writable.set(value, getMaxLength());
    return o;
  }
View Full Code Here

    return o;
  }

  @Override
  public Object create(HiveVarchar value) {
    HiveVarcharWritable ret;
    ret = new HiveVarcharWritable();
    ret.set(value, getMaxLength());
    return ret;
  }
View Full Code Here

  }

<#if entry.drillType == "VarChar">
  @Override
  public HiveVarcharWritable getPrimitiveWritableObject(Object o) {
    HiveVarcharWritable valW = new HiveVarcharWritable();
    valW.set(getPrimitiveJavaObject(o));
    return valW;
  }
View Full Code Here

  }

  public OrcLazyShort(OrcLazyShort copy) {
    super(copy);
    if (copy.previous != null) {
      previous = new ShortWritable(((ShortWritable)copy.previous).get());
    }
  }
View Full Code Here

  }

  public OrcLazyTimestamp(OrcLazyTimestamp copy) {
    super(copy);
    if (copy.previous != null) {
      previous = new TimestampWritable(((TimestampWritable)copy.previous));
    }
  }
View Full Code Here

    if (o == null || o.getClass() != getClass()) {
      return false;
    } else if (o == this) {
      return true;
    } else {
      ObjectInspector other = ((OrcLazyListObjectInspector) o).child;
      return other.equals(child);
    }
  }
View Full Code Here

TOP

Related Classes of org.apache.hadoop.hive.serde2.io.HiveVarcharWritable

Copyright © 2018 www.massapicom. 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.