public void pushObjectValue(Object obj) throws LuaException
  {
    if (obj == null)
    {
      pushNil();
    }
    else if (obj instanceof Boolean)
    {
      Boolean bool = (Boolean) obj;
      pushBoolean(bool.booleanValue());
    }
    else if (obj instanceof Number)
    {
      pushNumber(((Number) obj).doubleValue());
    }
    else if (obj instanceof String)
    {
      pushString((String) obj);
    }
    else if (obj instanceof JavaFunction)
    {
      JavaFunction func = (JavaFunction) obj;
      pushJavaFunction(func);
    }
    else if (obj instanceof LuaObject)
    {
      LuaObject ref = (LuaObject) obj;
      ref.push();
    }
    else if (obj instanceof byte[])
    {
      pushString((byte[]) obj);
    }
    else
    {
      pushJavaObject(obj);
    }
  }