ReactionPresenter

open class ReactionPresenter : ReactionPresenterProtocol

A reaction presenter.

  • Add a reaction to an activity.

    Declaration

    Swift

    public func addReaction<T: ActivityProtocol,
        E: ReactionExtraDataProtocol,
        U: UserProtocol>(for activity: T,
                         kindOf kind: ReactionKind,
                         parentReaction: GetStream.Reaction<E, U>? = nil,
                         targetsFeedIds: [FeedId],
                         extraData: E,
                         userTypeOf userType: U.Type,
                         _ completion: @escaping Completion<T>) where T.ReactionType == GetStream.Reaction<E, U>
  • Add a comment to an activity.

    Declaration

    Swift

    public func addComment<T: ActivityProtocol,
        E: ReactionExtraDataProtocol,
        U: UserProtocol>(for activity: T,
                         parentReaction: T.ReactionType? = nil,
                         extraData: E,
                         userTypeOf userType: U.Type,
                         _ completion: @escaping Completion<T>) where T.ReactionType == GetStream.Reaction<E, U>
  • Remove a reaction from an activity.

    Declaration

    Swift

    public func remove<T: ActivityProtocol>(reaction: T.ReactionType, activity: T, _ completion: @escaping Completion<T>)
        where T.ReactionType: ReactionProtocol
  • Remove a reaction from a parent reaction.

    Declaration

    Swift

    public func remove<T: ReactionProtocol>(reaction: T,
                                            parentReaction: T,
                                            _ completion: @escaping (_ result: Result<T, ClientError>) -> Void)