org.apache.hadoop.hive.serde2
Class SerDeUtils

java.lang.Object
  extended by org.apache.hadoop.hive.serde2.SerDeUtils

public final class SerDeUtils
extends Object

SerDeUtils.


Field Summary
static char COLON
           
static char COMMA
           
static String LBRACE
           
static String LBRACKET
           
static org.apache.commons.logging.Log LOG
           
static char QUOTE
           
static String RBRACE
           
static String RBRACKET
           
 
Method Summary
static String escapeString(String str)
          Escape a String in JSON format.
static String getJSONString(Object o, ObjectInspector oi)
           
static boolean hasAnyNullObject(List o, StandardStructObjectInspector loi, boolean[] nullSafes)
          return false though element is null if nullsafe flag is true for that
static boolean hasAnyNullObject(Object o, ObjectInspector oi)
          True if Object passed is representing null object.
static String lightEscapeString(String str)
           
static Deserializer lookupDeserializer(String name)
           
protected static boolean registerCoreSerDes()
           
static void registerSerDe(String name, Class<?> serde)
           
static boolean shouldGetColsFromSerDe(String serde)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

QUOTE

public static final char QUOTE
See Also:
Constant Field Values

COLON

public static final char COLON
See Also:
Constant Field Values

COMMA

public static final char COMMA
See Also:
Constant Field Values

LBRACKET

public static final String LBRACKET
See Also:
Constant Field Values

RBRACKET

public static final String RBRACKET
See Also:
Constant Field Values

LBRACE

public static final String LBRACE
See Also:
Constant Field Values

RBRACE

public static final String RBRACE
See Also:
Constant Field Values

LOG

public static final org.apache.commons.logging.Log LOG
Method Detail

registerSerDe

public static void registerSerDe(String name,
                                 Class<?> serde)

lookupDeserializer

public static Deserializer lookupDeserializer(String name)
                                       throws SerDeException
Throws:
SerDeException

shouldGetColsFromSerDe

public static boolean shouldGetColsFromSerDe(String serde)

registerCoreSerDes

protected static boolean registerCoreSerDes()

escapeString

public static String escapeString(String str)
Escape a String in JSON format.


lightEscapeString

public static String lightEscapeString(String str)

getJSONString

public static String getJSONString(Object o,
                                   ObjectInspector oi)

hasAnyNullObject

public static boolean hasAnyNullObject(List o,
                                       StandardStructObjectInspector loi,
                                       boolean[] nullSafes)
return false though element is null if nullsafe flag is true for that


hasAnyNullObject

public static boolean hasAnyNullObject(Object o,
                                       ObjectInspector oi)
True if Object passed is representing null object.

Parameters:
o - The object
oi - The ObjectInspector
Returns:
true if the object passed is representing NULL object false otherwise


Copyright © 2013 The Apache Software Foundation