Fluent builder that assembles a StreamEventBean and appends it to a profile's or lead's activity timeline. An instance is obtained from UserManager.streamEventBuilder(), populated with the profile or organisation the event belongs to and the details of the action, then finished with build() to produce the StreamEventBean. Every setter returns this builder so calls can be chained.
Group: Builders
Methods
profile(ProfileBean profileBean) · profile(UserResource user) · profile(Profile profile) · entity(BaseEntity entity) · org(OrgData orgData) · org(Organisation org) · category(String category) · date(Date d) · icon(String s) · desc(String s) · path(String s) · title(String s) · repo(Repository s) · branch(Branch s) · inbound(Boolean b) · data(Map data) · build()
profile(ProfileBean profileBean)
Returns: StreamEventBeanBuilder
Sets the profile that this event is for, from a ProfileBean.
| Parameter | Description |
|---|---|
profileBean | the profile bean identifying the profile |
profile(UserResource user)
Returns: StreamEventBeanBuilder
Sets the profile and organisation that this event is for, taken from a UserResource.
| Parameter | Description |
|---|---|
user | the user resource identifying the profile and organisation |
profile(Profile profile)
Returns: StreamEventBeanBuilder
Sets the profile that this event is for.
| Parameter | Description |
|---|---|
profile | the profile the event is for |
entity(BaseEntity entity)
Returns: StreamEventBeanBuilder
Sets the profile or organisation that this event is for, from an entity that is either a Profile or an Organisation. Has no effect if the entity is neither.
| Parameter | Description |
|---|---|
entity | the profile or organisation entity the event is for |
org(OrgData orgData)
Returns: StreamEventBeanBuilder
Sets the organisation this event belongs to, from an OrgData.
| Parameter | Description |
|---|---|
orgData | the org data identifying the organisation |
org(Organisation org)
Returns: StreamEventBeanBuilder
Sets the organisation this event belongs to.
| Parameter | Description |
|---|---|
org | the organisation the event belongs to |
category(String category)
Returns: StreamEventBeanBuilder
Sets the category for this event, used to style it on the timeline. Should be one of the bootstrap contextual classes, such as muted or primary.
| Parameter | Description |
|---|---|
category | the bootstrap contextual class name for this event |
date(Date d)
Returns: StreamEventBeanBuilder
Sets the date this event took place.
| Parameter | Description |
|---|---|
d | the date and time of the event |
icon(String s)
Returns: StreamEventBeanBuilder
Sets the icon to display for this item. Should correspond to the name of a font-awesome icon.
| Parameter | Description |
|---|---|
s | the font-awesome icon name |
desc(String s)
Returns: StreamEventBeanBuilder
Sets a short description of this event, for example "edited", "started job" or "sent email".
| Parameter | Description |
|---|---|
s | the description text |
path(String s)
Returns: StreamEventBeanBuilder
Sets the path used to link to the item this event relates to.
| Parameter | Description |
|---|---|
s | the path to link to |
title(String s)
Returns: StreamEventBeanBuilder
Sets the title of the item this event relates to, shown on the timeline entry.
| Parameter | Description |
|---|---|
s | the item title |
repo(Repository s)
Returns: StreamEventBeanBuilder
Sets the repository this event relates to.
| Parameter | Description |
|---|---|
s | the repository the event occurred in |
branch(Branch s)
Returns: StreamEventBeanBuilder
Sets the branch this event relates to.
| Parameter | Description |
|---|---|
s | the branch the event occurred in |
inbound(Boolean b)
Returns: StreamEventBeanBuilder
Sets whether this event represents an action coming from the user to the server, as opposed to an outbound action pushed from the server to the user.
| Parameter | Description |
|---|---|
b | true if the event is inbound from the user, false if it is outbound from the server |
data(Map data)
Returns: StreamEventBeanBuilder
Sets arbitrary additional data associated with this event.
| Parameter | Description |
|---|---|
data | a map of extra data for this event |
build()
Returns: StreamEventBean
Builds the StreamEventBean from the values set on this builder.