def GetFieldValue(field):
  if not field:
    return None
  value = field.value().string_value()
  value_type = field.value().type()

  if value_type in TEXT_DOCUMENT_FIELD_TYPES:
    return value
  if value_type == document_pb.FieldValue.DATE:
    return DeserializeDate(value)
  if value_type == document_pb.FieldValue.NUMBER:
    return float(value)
  raise TypeError('No conversion defined for type %s' % value_type)
test binding in/out with cursor.var() method
dataset/ETHPy150Open AppScale/appscale/AppServer/google/appengine/api/search/search_util.py/GetFieldValue--crossover with--dataset/ETHPy150Open cloudera/hue/desktop/core/ext-py/cx_Oracle-5.1.2/test/IntervalVar.py/TestIntervalVar.testBindInOutVarDirectSet