ActivityPresenter

public struct ActivityPresenter<T> where T : ActivityProtocol

Activity Presenter for the managing events for the activity.

Activity Presenter for Table View

  • A number of cells in the activity section.

    Declaration

    Swift

    public var cellsCount: Int { get }
  • Returns the type of the cell at a row.

    Declaration

    Swift

    public func cellType(at row: Int) -> ActivityPresenterCellType?
  • Check if activity table view section needs to show with reactions.

    Declaration

    Swift

    public var withReactions: Bool { get }

Available where T: ActivityProtocol, T.ReactionType: ReactionProtocol, T.ReactionType.UserType: (UserNameRepresentable & AvatarRepresentable)

  • Return a title for the activity reaction of a reaction kind.

    Declaration

    Swift

    public func reactionTitle(for activity: T, kindOf reactionKind: ReactionKind, suffix: String) -> String?
  • Returns a list of avatar URL’s for the activity reactions of a reaction kind.

    Declaration

    Swift

    public func reactionUserAvatarURLs(for activity: T, kindOf reactionKind: ReactionKind) -> [URL]
  • Returns a comment for the activity at an index.

    Declaration

    Swift

    public func comment(for activity: T, at index: Int) -> T.ReactionType?