RPC with classes