Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/arman-aminian/twitter-backend
/ functions
Functions
178 in github.com/arman-aminian/twitter-backend
⨍
Functions
178
◇
Types & classes
43
↓ 1 callers
Function
removeIndex
(s []model.Owner, index int)
handler/user.go:594
Method
AddCommentToTweet
(parent *model.Tweet, child *model.CommentTweet)
store/tweet.go:72
Method
AddFollower
(u *model.User, follower *model.User)
store/user.go:69
Method
AddHashtag
(ht *model.Hashtag)
store/hashtags.go:29
Method
AddLog
(u *model.User, e *model.Event)
store/user.go:157
Method
AddNotification
(u *model.User, e *model.Event)
store/user.go:166
Method
AddTweet
(u *model.User, t *model.Tweet)
store/user.go:136
Method
CreateTweet
(t *model.Tweet)
store/tweet.go:22
Method
CreateTweet
CreateTweet godoc @Summary Create an tweet @Description Create an tweet @ID create-tweet @Tags tweet @Accept json @Produce json @Param tweet body tw
handler/tweet.go:30
Method
DeleteTweet
DeleteTweet godoc @Description Delete a tweet from a user's tweets based on the token. Auth is required. @ID delete-tweet @Tags tweet @Produce json @
handler/tweet.go:182
Method
DeleteTweetHashtags
(t *model.Tweet, hashtags map[string]int)
store/hashtags.go:82
Method
Dummy
(c echo.Context)
handler/user.go:15
Method
ExtractHashtags
(t *model.Tweet)
store/tweet.go:140
Method
Follow
Follow godoc @Summary Follow a user @Description Follow a user by username @ID follow @Tags follow @Accept json @Produce json @Param username path s
handler/user.go:290
Method
GetAllTweets
()
store/tweet.go:60
Method
GetByEmail
(email string)
store/user.go:57
Method
GetFollowingAndFollowersList
GetFollowingAndFollowersList godoc @Summary Get the list of followings and followers of a user. Auth is required. @Description Get the list of followi
handler/user.go:476
Method
GetHashtagByName
O(n + O(exists))
hashtag/hashtag.go:10
Method
GetHashtagTweets
(name string)
store/hashtags.go:106
Method
GetHeaderPictureFile
GetHeaderPictureFile godoc @Summary Get the header picture @Description Get the header picture of a user based on the filename @ID get-header-picture
handler/user.go:269
Method
GetLogs
GetLogs godoc @Description Get the list of everything the user has done (logs). @ID get-logs @Tags logs @Produce json @Success 200 {object} EventList
handler/user.go:497
Method
GetNotifications
GetNotifications godoc @Description Get the list of everything done with the use being the target (notifications). @ID get-notifications @Tags notific
handler/user.go:520
Method
GetProfilePictureFile
GetProfilePictureFile godoc @Summary Get the profile picture @Description Get the profile picture of a user based on the filename @ID get-profile-pict
handler/user.go:256
Method
GetSuggestions
GetSuggestions godoc @Description Get the list of the users suggested to a user (followers of its followings) @ID get-suggestions @Tags suggestions @P
handler/user.go:540
Method
GetTimeline
GetTimeline godoc @Summary Get the timeline of your account @Description Get tweets of your followings. Auth is required. @ID get-timeline @Tags timel
handler/user.go:375
Method
GetTimelineFromTweetIDs
(tweetsIDs []primitive.ObjectID, day int)
store/tweet.go:154
Method
GetTrends
()
store/hashtags.go:132
Method
GetTrends
(c echo.Context)
handler/hashtag.go:31
Method
GetTweet
GetTweet godoc @Description Create an tweet. Auth is optional. @ID get-tweet @Tags tweet @Produce json @Success 201 {object} singleTweetResponse @Fai
handler/tweet.go:127
Method
GetTweetAssetFile
(c echo.Context)
handler/tweet.go:111
Method
GetTweetById
(id *string)
store/tweet.go:32
Method
GetTweetIdListFromUsernameList
(usernames []string)
store/user.go:188
Method
GetTweetLikeAndRetweetList
GetTweetLikeAndRetweetList godoc @Description Get the list of users who liked and retweeted this tweet. Auth not required. @ID get-likes-retweets-list
handler/tweet.go:242
Method
GetTweetSearchResult
(query string)
store/tweet.go:172
Method
GetTweets
(tweets []string)
store/tweet.go:42
Method
GetTweets
GetTweets godoc @Description Get all of the tweets of a user. Auth is required. @ID get-tweet @Tags tweet @Produce json @Success 201 {object} singleT
handler/tweet.go:150
Method
GetUserListFromUsernameList
(usernames []string)
user/user.go:26
Method
GetUserListFromUsernameList
(usernames []string)
store/user.go:175
Method
GetUsernameSearchResult
(username string)
store/user.go:205
Method
IsFollower
(username, followerUsername string)
store/user.go:110
Method
Like
Like godoc @Description Like a tweet. Auth is required. @ID like @Tags like @Produce json @Param id path string true "id of the article that you want
handler/tweet.go:267
Method
LikeTweet
(t *model.Tweet, u *model.User)
store/tweet.go:92
Method
ReadDoc
()
docs/docs.go:1518
Method
RemoveComment
(t *model.Tweet, id *primitive.ObjectID)
store/tweet.go:81
Method
RemoveFollower
(u *model.User, follower *model.User)
store/user.go:83
Method
RemoveHashtag
O(n)
hashtag/hashtag.go:11
Method
RemoveTweet
(u *model.User, id *string)
user/user.go:21
Method
RemoveTweet
(t *model.Tweet)
store/tweet.go:27
Method
RemoveTweet
(u *model.User, id *string)
store/user.go:142
Method
Retweet
(t *model.Tweet, u *model.User)
store/tweet.go:116
Method
Retweet
Retweet godoc @Description retweet a tweet. Auth is required. @ID retweet @Tags retweet @Produce json @Param id path string true "id of the article t
handler/tweet.go:361
Method
SearchHashtag
(c echo.Context)
handler/hashtag.go:45
Method
SearchTweets
SearchTweets godoc @Summary Search tweets related to query @Description Search all the tweets related to the query. @ID search-tweets @Tags search @Ac
handler/user.go:450
Method
SearchUsernames
SearchUsernames godoc @Summary Search a user by its username @Description Search by specifying the username. Auth is optional. @ID search-username @Ta
handler/user.go:427
Function
StartUpTrends
(ts *store.TweetStore, h *handler.Handler)
main.go:53
Function
TestFollowSuccess
(t *testing.T)
handler/user_test.go:172
Function
TestGetProfileSuccess
(t *testing.T)
handler/user_test.go:117
Function
TestLoginFailedNotFound
(t *testing.T)
handler/user_test.go:66
Function
TestLoginFailedWrongPassword
(t *testing.T)
handler/user_test.go:75
Function
TestLoginSuccess
(t *testing.T)
handler/user_test.go:53
Function
TestSignUpFailed
(t *testing.T)
handler/user_test.go:45
Function
TestSignUpSuccess
(t *testing.T)
handler/user_test.go:24
Function
TestUpdateProfileSuccess
(t *testing.T)
handler/user_test.go:145
Function
TestUpdateUserSuccess
(t *testing.T)
handler/user_test.go:83
Method
UnFollow
Unfollow godoc @Summary Unfollow a user @Description Unfollow a user by username @ID unfollow @Tags follow @Accept json @Produce json @Param usernam
handler/user.go:341
Method
UnLike
UnLike godoc @Description UnLike a tweet. Auth is required. @ID unlike @Tags like @Produce json @Param id path string true "id of the article that yo
handler/tweet.go:319
Method
UnLikeTweet
(t *model.Tweet, u *model.User)
store/tweet.go:101
Method
UnRetweet
(t *model.Tweet, u *model.User)
store/tweet.go:125
Method
UnRetweet
UnRetweet godoc @Description UnRetweet a tweet. Auth is required. @ID unretweet @Tags unretweet @Produce json @Param id path string true "id of the a
handler/tweet.go:417
Method
Update
(old *model.User, new *model.User)
user/user.go:11
Method
Update
(old *model.User, new *model.User)
store/user.go:31
Method
UpdateProfile
(u *model.User)
store/user.go:44
Method
UpdateProfile
UpdateProfile godoc @Summary Update a user's profile @Description Update user profile based on 4 entries: name, bio, and pictures @ID update-profile @
handler/user.go:181
Method
bind
(c echo.Context, u *model.User)
handler/request.go:83
Method
bind
(c echo.Context, u *model.User)
handler/request.go:116
Function
init
()
docs/docs.go:1540
Function
main
()
main.go:18
Method
populate
(u *model.User)
handler/request.go:68
← previous
101–178 of 178, ranked by callers