Class PlayHistory.Builder
- java.lang.Object
-
- com.wrapper.spotify.model_objects.AbstractModelObject.Builder
-
- com.wrapper.spotify.model_objects.specification.PlayHistory.Builder
-
- All Implemented Interfaces:
IModelObject.Builder
- Enclosing class:
- PlayHistory
public static final class PlayHistory.Builder extends AbstractModelObject.Builder
Builder class for buildingPlayHistoryinstances.
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PlayHistorybuild()Build a model object with the information set in the builder object.PlayHistory.BuildersetContext(Context context)The context setter.PlayHistory.BuildersetPlayedAt(Date playedAt)The played at date setter.PlayHistory.BuildersetTrack(TrackSimplified track)The track setter.
-
-
-
Method Detail
-
setTrack
public PlayHistory.Builder setTrack(TrackSimplified track)
The track setter.- Parameters:
track- The track the user listened to.- Returns:
- A
PlayHistory.Builder.
-
setPlayedAt
public PlayHistory.Builder setPlayedAt(Date playedAt)
The played at date setter.- Parameters:
playedAt- The date and time the track was played.- Returns:
- A
PlayHistory.Builder.
-
setContext
public PlayHistory.Builder setContext(Context context)
The context setter.- Parameters:
context- The context the track was played from.- Returns:
- A
PlayHistory.Builder.
-
build
public PlayHistory build()
Description copied from interface:IModelObject.BuilderBuild a model object with the information set in the builder object.
The type of the model object and its methods depend on its corresponding implementation.- Returns:
- A model object.
-
-