Package com.example.breeze_seas
Class TicketUIModel
java.lang.Object
com.example.breeze_seas.TicketUIModel
TicketUIModel represents a single event "ticket" entry displayed in the Tickets feature UI.
Role: - Lightweight view model used by RecyclerView adapters to render ticket cards. - Presentation model mapped from Firestore-backed ticket data.
Outstanding: - Expand with additional display fields only if the Tickets UI needs them.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumPresentation states used by the Active Tickets UI. -
Constructor Summary
ConstructorsConstructorDescriptionTicketUIModel(String eventId, String title, String dateLabel, TicketUIModel.Status status) Creates a presentation model for one active ticket card.TicketUIModel(String eventId, String title, String dateLabel, TicketUIModel.Status status, boolean privateEvent) Creates a presentation model for one active ticket card.TicketUIModel(String eventId, String title, String dateLabel, TicketUIModel.Status status, boolean privateEvent, boolean inboxDecisionRequired) Creates a presentation model for one active ticket card.TicketUIModel(String eventId, String title, String dateLabel, TicketUIModel.Status status, boolean privateEvent, boolean inboxDecisionRequired, String imageDocId) Creates a presentation model for one active ticket card. -
Method Summary
-
Constructor Details
-
TicketUIModel
Creates a presentation model for one active ticket card.- Parameters:
eventId- Firestore event identifier for the related event.title- Event title shown on the card.dateLabel- Human-readable date string shown on the card.status- Active-ticket state that drives the chip and click behavior.
-
TicketUIModel
public TicketUIModel(String eventId, String title, String dateLabel, TicketUIModel.Status status, boolean privateEvent) Creates a presentation model for one active ticket card.- Parameters:
eventId- Firestore event identifier for the related event.title- Event title shown on the card.dateLabel- Human-readable date string shown on the card.status- Active-ticket state that drives the chip and click behavior.privateEvent- Whether the related event is private.
-
TicketUIModel
public TicketUIModel(String eventId, String title, String dateLabel, TicketUIModel.Status status, boolean privateEvent, boolean inboxDecisionRequired) Creates a presentation model for one active ticket card.- Parameters:
eventId- Firestore event identifier for the related event.title- Event title shown on the card.dateLabel- Human-readable date string shown on the card.status- Active-ticket state that drives the chip and click behavior.privateEvent- Whether the related event is private.inboxDecisionRequired- Whether the entrant must go through Notifications to respond.
-
TicketUIModel
public TicketUIModel(String eventId, String title, String dateLabel, TicketUIModel.Status status, boolean privateEvent, boolean inboxDecisionRequired, @Nullable String imageDocId) Creates a presentation model for one active ticket card.- Parameters:
eventId- Firestore event identifier for the related event.title- Event title shown on the card.dateLabel- Human-readable date string shown on the card.status- Active-ticket state that drives the chip and click behavior.privateEvent- Whether the related event is private.inboxDecisionRequired- Whether the entrant must go through Notifications to respond.imageDocId- Optional image document id for the event poster.
-
-
Method Details
-
getEventId
- Returns:
- Firestore event id for the related event document.
-
getTitle
- Returns:
- Event title shown on the ticket card.
-
getDateLabel
- Returns:
- Human-readable date label (e.g., "Mon, Mar 4 • 6:00 PM").
-
getStatus
- Returns:
- Ticket status used to drive chip text and click behavior.
-
isPrivateEvent
public boolean isPrivateEvent()- Returns:
truewhen the related event is private.
-
isPrivateInvitePending
public boolean isPrivateInvitePending()- Returns:
truewhen this card is still a private invite awaiting accept/decline.
-
requiresInboxDecision
public boolean requiresInboxDecision()- Returns:
truewhen this card is still a private invite awaiting accept/decline.
-
getImageDocId
- Returns:
- Optional image document id for the related event poster.
-