View Javadoc
1   package org.oxerr.viagogo.model.response.catalog;
2   
3   import java.time.OffsetDateTime;
4   import java.util.List;
5   
6   import org.apache.commons.lang3.builder.EqualsBuilder;
7   import org.apache.commons.lang3.builder.HashCodeBuilder;
8   import org.oxerr.viagogo.model.Money;
9   
10  import io.openapitools.jackson.dataformat.hal.HALLink;
11  import io.openapitools.jackson.dataformat.hal.annotation.EmbeddedResource;
12  import io.openapitools.jackson.dataformat.hal.annotation.Link;
13  
14  /**
15   * An event on the viagogo platform.
16   *
17   * <a href="https://developer.viagogo.net/api-reference/catalog#tag/Resource_Event">Event</a>
18   */
19  @io.openapitools.jackson.dataformat.hal.annotation.Resource
20  public class Event extends EmbeddedEvent {
21  
22  	private static final long serialVersionUID = 2023021301L;
23  
24  	/**
25  	 * True if the event start and end time have been confirmed; Otherwise, false.
26  	 */
27  	private Boolean timeConfirmed;
28  
29  	/**
30  	 * The type of the event. Can be {@code Main} or {@code Parking}.
31  	 */
32  	private String type;
33  
34  	/**
35  	 * The minimum ticket price of the event.
36  	 */
37  	private Money minTicketPrice;
38  
39  	/**
40  	 * The status of the event.
41  	 * Can be {@code Normal}, {@code Postponed}, {@code Cancelled},
42  	 * {@code Rescheduled}, {@code Relocated}, {@code RelocatedAndRescheduled},
43  	 * {@code Draft}, {@code Contingent} and {@code Deleted}.
44  	 */
45  	private String status;
46  
47  	/**
48  	 * Url on the website for the event.
49  	 */
50  	@Link("event:webpage")
51  	private HALLink webPageLink;
52  
53  	/**
54  	 * The categories for this event.
55  	 */
56  	@EmbeddedResource
57  	private List<EmbeddedCategory> categories;
58  
59  	/**
60  	 * The external mappings for this event.
61  	 */
62  	@EmbeddedResource
63  	private List<ExternalMapping> externalMappings;
64  
65  	/**
66  	 * The genre for this event.
67  	 */
68  	@EmbeddedResource
69  	private Genre genre;
70  
71  	/**
72  	 * The events that have been merged into this event.
73  	 */
74  	@EmbeddedResource
75  	private List<Event> mergedEvents;
76  
77  	/**
78  	 * The venue where the event is taking place.
79  	 */
80  	@EmbeddedResource
81  	private Venue venue;
82  
83  	public Event() {
84  	}
85  
86  	public Event(String name, OffsetDateTime startDate) {
87  		super(name, startDate);
88  	}
89  
90  	public Boolean getTimeConfirmed() {
91  		return timeConfirmed;
92  	}
93  
94  	public void setTimeConfirmed(Boolean timeConfirmed) {
95  		this.timeConfirmed = timeConfirmed;
96  	}
97  
98  	public String getType() {
99  		return type;
100 	}
101 
102 	public void setType(String type) {
103 		this.type = type;
104 	}
105 
106 	public Money getMinTicketPrice() {
107 		return minTicketPrice;
108 	}
109 
110 	public void setMinTicketPrice(Money minTicketPrice) {
111 		this.minTicketPrice = minTicketPrice;
112 	}
113 
114 	public String getStatus() {
115 		return status;
116 	}
117 
118 	public void setStatus(String status) {
119 		this.status = status;
120 	}
121 
122 	public HALLink getWebPageLink() {
123 		return webPageLink;
124 	}
125 
126 	public void setWebPageLink(HALLink webPageLink) {
127 		this.webPageLink = webPageLink;
128 	}
129 
130 	public List<EmbeddedCategory> getCategories() {
131 		return categories;
132 	}
133 
134 	public void setCategories(List<EmbeddedCategory> categories) {
135 		this.categories = categories;
136 	}
137 
138 	public List<ExternalMapping> getExternalMappings() {
139 		return externalMappings;
140 	}
141 
142 	public void setExternalMappings(List<ExternalMapping> externalMappings) {
143 		this.externalMappings = externalMappings;
144 	}
145 
146 	public Genre getGenre() {
147 		return genre;
148 	}
149 
150 	public void setGenre(Genre genre) {
151 		this.genre = genre;
152 	}
153 
154 	public List<Event> getMergedEvents() {
155 		return mergedEvents;
156 	}
157 
158 	public void setMergedEvents(List<Event> mergedEvents) {
159 		this.mergedEvents = mergedEvents;
160 	}
161 
162 	public Venue getVenue() {
163 		return venue;
164 	}
165 
166 	public void setVenue(Venue venue) {
167 		this.venue = venue;
168 	}
169 
170 	@Override
171 	public int hashCode() {
172 		return HashCodeBuilder.reflectionHashCode(this);
173 	}
174 
175 	@Override
176 	public boolean equals(Object obj) {
177 		if (this == obj) {
178 			return true;
179 		}
180 		if (!(obj instanceof Event)) {
181 			return false;
182 		}
183 		Event rhs = (Event) obj;
184 		return EqualsBuilder.reflectionEquals(this, rhs);
185 	}
186 
187 }