function send_message($uid, $msg, SendOptions $options = null) { if ($options == null) { $options = new SendOptions(); } raw_send_message($uid, $msg, $options->json()); }
function processTask(array $data = null) { send_message($data['uid'], $data['message'], SendOptions::fromJson($data['opt'])); }