Package facebook4j.internal.http

Examples of facebook4j.internal.http.HttpResponse


        return factory.createRSVPStatusList(get(buildEndpoint(eventId, "declined/" + userId)));
    }

    public boolean rsvpEventAsDeclined(String eventId) throws FacebookException {
        ensureAuthorizationEnabled();
        HttpResponse res = post(buildEndpoint(eventId, "declined"));
        return Boolean.valueOf(res.asString().trim());
    }
View Full Code Here


        return _getPictureURL(eventId, size);
    }

    public boolean updateEventPicture(String eventId, Media source) throws FacebookException {
        ensureAuthorizationEnabled();
        HttpResponse res = post(buildEndpoint(eventId, "picture"),
                                new HttpParameter[] {source.asHttpParameter("source")});
        return Boolean.valueOf(res.asString().trim());
    }
View Full Code Here

        return Boolean.valueOf(res.asString().trim());
    }

    public boolean deleteEventPicture(String eventId) throws FacebookException {
        ensureAuthorizationEnabled();
        HttpResponse res = delete(buildEndpoint(eventId, "picture"));
        return Boolean.valueOf(res.asString().trim());
    }
View Full Code Here

        return factory.createPost(get(buildEndpoint(postId, reading)));
    }

    public boolean deletePost(String postId) throws FacebookException {
        ensureAuthorizationEnabled();
        HttpResponse res = delete(buildEndpoint(postId));
        return Boolean.valueOf(res.asString().trim());
    }
View Full Code Here

                          .asJSONObject();
        return getRawString("id", json);
    }
    public boolean deleteFriendlist(String friendlistId) throws FacebookException {
        ensureAuthorizationEnabled();
        HttpResponse res = delete(buildEndpoint(friendlistId));
        return Boolean.valueOf(res.asString().trim());
    }
View Full Code Here

        return Boolean.valueOf(res.asString().trim());
    }

    public boolean addFriendlistMember(String friendlistId, String userId) throws FacebookException {
        ensureAuthorizationEnabled();
        HttpResponse res = post(buildEndpoint(friendlistId + "/members/" + userId));
        return Boolean.valueOf(res.asString().trim());
    }
View Full Code Here

        return Boolean.valueOf(res.asString().trim());
    }

    public boolean removeFriendlistMember(String friendlistId, String userId) throws FacebookException {
        ensureAuthorizationEnabled();
        HttpResponse res = delete(buildEndpoint(friendlistId + "/members/" + userId));
        return Boolean.valueOf(res.asString().trim());
    }
View Full Code Here

        return factory.createGroupMemberList(get(buildEndpoint(groupId, "members", reading)));
    }

    public URL getGroupPictureURL(String groupId) throws FacebookException {
        ensureAuthorizationEnabled();
        HttpResponse res = get(buildEndpoint(groupId, "picture"));
        try {
            return new URL(res.getResponseHeader("Location"));
        } catch (MalformedURLException urle) {
            throw new FacebookException(urle.getMessage(), urle);
        }
    }
View Full Code Here

    public Comment getComment(String commentId) throws FacebookException {
        return factory.createComment(get(buildEndpoint(commentId)));
    }
    public boolean deleteComment(String commentId) throws FacebookException {
        ensureAuthorizationEnabled();
        HttpResponse res = delete(buildEndpoint(commentId));
        return Boolean.valueOf(res.asString().trim());
    }
View Full Code Here

        return getNotifications(userId, reading, false);
    }
    public ResponseList<Notification> getNotifications(String userId, Reading reading, boolean includeRead) throws FacebookException {
        ensureAuthorizationEnabled();
        String url = buildEndpoint(userId, "notifications", reading);
        HttpResponse res;
        if (includeRead) {
            res = get(url, new HttpParameter[]{new HttpParameter("include_read", 1)});
        } else {
            res = get(url);
        }
View Full Code Here

TOP

Related Classes of facebook4j.internal.http.HttpResponse

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.