Пользователи онлайн по типу (мобильные / пк)
Exemplo n.º 1
0
        /// <summary>
        /// Разобрать из json.
        /// </summary>
        /// <param name="response">Ответ сервера.</param>
        /// <returns></returns>
        public static FriendOnline FromJson(VkResponse response)
        {
            VkResponseArray mobile = response["online_mobile"];
            VkResponseArray pc     = response["online"];
            var             item   = new FriendOnline
            {
                MobileOnline = mobile.ToReadOnlyCollectionOf <long>(x => x),
                Online       = pc.ToReadOnlyCollectionOf <long>(x => x)
            };

            return(item);
        }
Exemplo n.º 2
0
        /// <summary>
        /// Разобрать из json.
        /// </summary>
        /// <param name="response">Ответ сервера.</param>
        /// <returns></returns>
        public static FriendOnline FromJson(VkResponse response)
        {
            VkResponseArray mobile = response["online_mobile"];
            VkResponseArray pc = response["online"];
            var item = new FriendOnline
            {
                MobileOnline = mobile.ToReadOnlyCollectionOf<long>(x => x),
                Online = pc.ToReadOnlyCollectionOf<long>(x => x)
            };

            return item;
        }