07
Июл
2017

Почему wall.get выдает пустые объекты java sdk vk?

Использую Java SDK:

try {
    GetResponse getQuery = vk.wall().get(actor)
        .ownerId(-9165838) 
        .offset(0)
        .count(10)
        .filter(WallGetFilter.ALL)
        .execute();
    System.out.println(getQuery);
} catch (ApiException e) {
    e.printStackTrace();
} catch (ClientException e) {
    e.printStackTrace();
}

Но результат всегда такой:

GetResponse{
    count=3983, 
    items=[
        WallpostFull{
            copyHistory=null,
            canEdit=null,
            createdBy=null,
            canDelete=null,
            canPin=null,
            isPinned=1,
            comments=CommentsInfo{count=0, canPost=1}, 
            likes=LikesInfo{
                count=0,
                userLikes=0,
                canLike=1,
                canPublish=1
            },
            reposts=RepostsInfo{count=0, userReposted=0}
        },

        WallpostFull{
            copyHistory=null,
            canEdit=null,
            createdBy=null,
            canDelete=null,
            canPin=null,
            isPinned=null,
            comments=CommentsInfo{count=0, canPost=1}, 
            likes=LikesInfo{
                count=0,
                userLikes=0,
                canLike=1,
                canPublish=0
            },
            reposts=RepostsInfo{count=0, userReposted=0}
        },

        WallpostFull{
            copyHistory=null,
            canEdit=1,
            createdBy=854708,
            canDelete=1,
            canPin=null,
            isPinned=null,
            comments=CommentsInfo{count=0, canPost=1}, 
            likes=LikesInfo{
                count=0,
                userLikes=0,
                canLike=1,
                canPublish=0
            },
            reposts=RepostsInfo{count=0, userReposted=0}
        }, 

        ...
    ]
}

Источник: https://ru.stackoverflow.com/questions/688476/%D0%9F%D0%BE%D1%87%D0%B5%D0%BC%D1%83-wall-get-%D0%B2%D1%8B%D0%B4%D0%B0%D0%B5%D1%82-%D0%BF%D1%83%D1%81%D1%82%D1%8B%D0%B5-%D0%BE%D0%B1%D1%8A%D0%B5%D0%BA%D1%82%D1%8B-java-sdk-vk

Share

Тебе может это понравится...