C# Class Rapptor.Api.PostsService

Inheritance: IPostsService
显示文件 Open project: jdscolam/Rapptor Class Usage Examples

Public Methods

Method Description
CreatePost ( CreatePostRequest createPostRequest ) : ResponseEnvelope

Creates a new post as the current AccessToken.

DeletePost ( string postId ) : ResponseEnvelope

Deletes a post by postId as the current AccessToken.

GetGeneralParameters ( PostStreamGeneralParameters postStreamGeneralParameters ) : IEnumerable

Parses a PostStreamGeneralParameters into the proper request parameters for App.net.

GetPostRequestParameters ( CreatePostRequest createPostRequest ) : IEnumerable

Parses a CreatePostRequest instance into the proper request parameters for App.net.

PostsService ( IApiCaller apiCaller ) : System.Collections.Generic
Repost ( string postId ) : ResponseEnvelope
RetrieveCurrentUsersStream ( PostStreamGeneralParameters postStreamGeneralParameters = null ) : ResponseEnvelope>

Retrieves the stream for the current AccessToken. NOTE: Unless changed by the postStreamGeneralParameters, only the latest 20 posts will be returned.

RetrieveGlobalStream ( PostStreamGeneralParameters postStreamGeneralParameters = null ) : ResponseEnvelope>

Retrieves the global stream for the current AccessToken. NOTE: Unless changed by the postStreamGeneralParameters, only the latest 20 posts will be returned.

RetrievePost ( string postId ) : ResponseEnvelope

Retrieves a post by postId.

RetrievePostReplies ( string postId, PostStreamGeneralParameters postStreamGeneralParameters = null ) : ResponseEnvelope>

Retrieves a list of posts that have replied to the given postId.

RetrievePostsCreatedByUser ( string userId, PostStreamGeneralParameters postStreamGeneralParameters = null ) : ResponseEnvelope>

Retrieves a list of posts created by a given userId.

RetrievePostsMentioningUser ( string userId, PostStreamGeneralParameters postStreamGeneralParameters = null ) : ResponseEnvelope>

Retrieves a list of posts where the given userId was mentioned.

RetrievePostsStarredByUser ( string userId, PostStreamGeneralParameters postStreamGeneralParameters = null ) : ResponseEnvelope>

Retrieves a list of posts starred by a given userId.

RetrieveTaggedPosts ( string hashtag, PostStreamGeneralParameters postStreamGeneralParameters = null ) : ResponseEnvelope>

Retrieves posts matching the given hashtag. NOTE: Unless changed by the postStreamGeneralParameters, only the latest 20 posts will be returned.

StarPost ( string postId ) : ResponseEnvelope
Unrepost ( string postId ) : ResponseEnvelope
UnstarPost ( string postId ) : ResponseEnvelope

Method Details

CreatePost() public method

Creates a new post as the current AccessToken.
public CreatePost ( CreatePostRequest createPostRequest ) : ResponseEnvelope
createPostRequest Rapptor.Domain.Request.CreatePostRequest
return ResponseEnvelope

DeletePost() public method

Deletes a post by postId as the current AccessToken.
public DeletePost ( string postId ) : ResponseEnvelope
postId string
return ResponseEnvelope

GetGeneralParameters() public static method

Parses a PostStreamGeneralParameters into the proper request parameters for App.net.
public static GetGeneralParameters ( PostStreamGeneralParameters postStreamGeneralParameters ) : IEnumerable
postStreamGeneralParameters PostStreamGeneralParameters
return IEnumerable

GetPostRequestParameters() public static method

Parses a CreatePostRequest instance into the proper request parameters for App.net.
public static GetPostRequestParameters ( CreatePostRequest createPostRequest ) : IEnumerable
createPostRequest Rapptor.Domain.Request.CreatePostRequest
return IEnumerable

PostsService() public method

public PostsService ( IApiCaller apiCaller ) : System.Collections.Generic
apiCaller IApiCaller
return System.Collections.Generic

Repost() public method

public Repost ( string postId ) : ResponseEnvelope
postId string
return ResponseEnvelope

RetrieveCurrentUsersStream() public method

Retrieves the stream for the current AccessToken. NOTE: Unless changed by the postStreamGeneralParameters, only the latest 20 posts will be returned.
public RetrieveCurrentUsersStream ( PostStreamGeneralParameters postStreamGeneralParameters = null ) : ResponseEnvelope>
postStreamGeneralParameters PostStreamGeneralParameters
return ResponseEnvelope>

RetrieveGlobalStream() public method

Retrieves the global stream for the current AccessToken. NOTE: Unless changed by the postStreamGeneralParameters, only the latest 20 posts will be returned.
public RetrieveGlobalStream ( PostStreamGeneralParameters postStreamGeneralParameters = null ) : ResponseEnvelope>
postStreamGeneralParameters PostStreamGeneralParameters
return ResponseEnvelope>

RetrievePost() public method

Retrieves a post by postId.
public RetrievePost ( string postId ) : ResponseEnvelope
postId string
return ResponseEnvelope

RetrievePostReplies() public method

Retrieves a list of posts that have replied to the given postId.
public RetrievePostReplies ( string postId, PostStreamGeneralParameters postStreamGeneralParameters = null ) : ResponseEnvelope>
postId string
postStreamGeneralParameters PostStreamGeneralParameters
return ResponseEnvelope>

RetrievePostsCreatedByUser() public method

Retrieves a list of posts created by a given userId.
public RetrievePostsCreatedByUser ( string userId, PostStreamGeneralParameters postStreamGeneralParameters = null ) : ResponseEnvelope>
userId string May be a userId, Username, or "me" for the current user.
postStreamGeneralParameters PostStreamGeneralParameters
return ResponseEnvelope>

RetrievePostsMentioningUser() public method

Retrieves a list of posts where the given userId was mentioned.
public RetrievePostsMentioningUser ( string userId, PostStreamGeneralParameters postStreamGeneralParameters = null ) : ResponseEnvelope>
userId string May be a userId, Username, or "me" for the current user.
postStreamGeneralParameters PostStreamGeneralParameters
return ResponseEnvelope>

RetrievePostsStarredByUser() public method

Retrieves a list of posts starred by a given userId.
public RetrievePostsStarredByUser ( string userId, PostStreamGeneralParameters postStreamGeneralParameters = null ) : ResponseEnvelope>
userId string May be a userId, Username, or "me" for the current user.
postStreamGeneralParameters PostStreamGeneralParameters
return ResponseEnvelope>

RetrieveTaggedPosts() public method

Retrieves posts matching the given hashtag. NOTE: Unless changed by the postStreamGeneralParameters, only the latest 20 posts will be returned.
public RetrieveTaggedPosts ( string hashtag, PostStreamGeneralParameters postStreamGeneralParameters = null ) : ResponseEnvelope>
hashtag string The hashtag to search without the # character.
postStreamGeneralParameters PostStreamGeneralParameters
return ResponseEnvelope>

StarPost() public method

public StarPost ( string postId ) : ResponseEnvelope
postId string
return ResponseEnvelope

Unrepost() public method

public Unrepost ( string postId ) : ResponseEnvelope
postId string
return ResponseEnvelope

UnstarPost() public method

public UnstarPost ( string postId ) : ResponseEnvelope
postId string
return ResponseEnvelope