Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/spring/13.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Java Spring社交Facebook-获取帖子的所有照片_Java_Spring_Facebook_Facebook Graph Api_Spring Social - Fatal编程技术网

Java Spring社交Facebook-获取帖子的所有照片

Java Spring社交Facebook-获取帖子的所有照片,java,spring,facebook,facebook-graph-api,spring-social,Java,Spring,Facebook,Facebook Graph Api,Spring Social,我在facebook上有一个帖子: 其中添加了3张照片。使用Spring Social Facebook API,我可以通过以下方式接收第一张照片: List<Post> posts = facebook.feedOperations().getFeed(pageId, new PagingParameters(FACEBOOK_FETCH_LIMIT, 0, null, null, null, null, null, null)); Post wantedPost = posts.

我在facebook上有一个帖子: 其中添加了3张照片。使用Spring Social Facebook API,我可以通过以下方式接收第一张照片:

List<Post> posts = facebook.feedOperations().getFeed(pageId, new PagingParameters(FACEBOOK_FETCH_LIMIT, 0, null, null, null, null, null, null));
Post wantedPost = posts.stream()
    .filter(post -> post.getId().contains("1295591900487178"))
    .collect(Collectors.toList())
    .get(FIRST);
post.getPicture(); // only returns the first picture of those 3
List posts=facebook.feedOperations().getFeed(pageId,新的分页参数(facebook_FETCH_LIMIT,0,null,null,null,null,null));
Post wantedPost=posts.stream()
.filter(post->post.getId().contains(“1295591900487178”))
.collect(收集器.toList())
.获得(第一);
post.getPicture();//仅返回这3张图片的第一张图片

我如何才能接收帖子中所有可见的3图片?

这是Graph API的方式。如何通过Spring Social API获取此信息?不知道,去查看文档。。。?Spring只向Graph API发出请求。现在你知道你在寻找什么API字段了——所以去阅读一下如何使用spring访问它们吧。我已经浏览了spring API文档——这就是问题所在。我找不到获取图像的API调用。可能只是没有一个。。。Spring不一定要实现这一点。我要检查post对象的
getProperties
方法是否以可访问的方式返回该数据;如果没有,您将不得不要求Spring人员为其实现一个方法。这是Graph API的方式。如何通过Spring Social API获取此信息?不知道,去查看文档。。。?Spring只向Graph API发出请求。现在你知道你在寻找什么API字段了——所以去阅读一下如何使用spring访问它们吧。我已经浏览了spring API文档——这就是问题所在。我找不到获取图像的API调用。可能只是没有一个。。。Spring不一定要实现这一点。我要检查post对象的
getProperties
方法是否以可访问的方式返回该数据;如果没有,您将不得不要求Spring人员为其实现一种方法。