001// Generated by delombok at Wed Jan 31 21:27:42 UTC 2024
002/*
003 * Copyright (c) 2010-2024 Mark Allen, Norbert Bartels.
004 *
005 * Permission is hereby granted, free of charge, to any person obtaining a copy
006 * of this software and associated documentation files (the "Software"), to deal
007 * in the Software without restriction, including without limitation the rights
008 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
009 * copies of the Software, and to permit persons to whom the Software is
010 * furnished to do so, subject to the following conditions:
011 *
012 * The above copyright notice and this permission notice shall be included in
013 * all copies or substantial portions of the Software.
014 *
015 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
016 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
017 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
018 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
019 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
020 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
021 * THE SOFTWARE.
022 */
023package com.restfb.types.ads;
024
025import java.util.ArrayList;
026import java.util.Collections;
027import java.util.List;
028import com.restfb.Facebook;
029
030/**
031 */
032public class AdKeywordStats extends NamedAdsObject {
033  private static final long serialVersionUID = 1L;
034  /**
035   * The number of times your ad was served. On our mobile apps an ad is counted as served the first time it's viewed.
036   * On all other Facebook interfaces, an ad is served the first time it's placed in a person's News Feed or each time
037   * it's placed in the right column.
038   */
039  @Facebook
040  private Integer impressions;
041  /**
042   * The number of people your ad was served to.
043   */
044  @Facebook("unique_impressions")
045  private Integer uniqueImpressions;
046  /**
047   * The number of people your ad was served to.
048   */
049  @Facebook
050  private Integer reach;
051  /**
052   * The total number of clicks on your ad. Depending on what you're promoting, this can include Page likes, event
053   * responses or app installs.
054   */
055  @Facebook
056  private Integer clicks;
057  /**
058   * The total number of unique people who have clicked on your ad. For example, if 3 people click on the same ad 5
059   * times, it will count as 3 unique clicks.
060   */
061  @Facebook("unique_clicks")
062  private Integer uniqueClicks;
063  /**
064   * The number of actions taken on your ad, Page, app or event after your ad was served to someone, even if they didn't
065   * click on it. Actions include Page likes, app installs, conversions, event responses and more. For example, 2 Page
066   * likes and 2 comments would be counted as 4 actions.
067   */
068  @Facebook("total_actions")
069  private Integer totalActions;
070  /**
071   * The number of unique people who took an action such as liking your Page or installing your app as a result of your
072   * ad. For example, if the same person likes and comments on a post, they will be counted as 1 unique person.
073   */
074  @Facebook("total_unique_actions")
075  private Integer totalUniqueActions;
076  /**
077   * The number of actions taken on your ad, Page, app or event after your ad was served to someone, even if they didn't
078   * click on it. Actions include Page likes, app installs, conversions, event responses and more. For example, 2 Page
079   * likes and 2 comments would be counted as 4 actions.
080   */
081  @Facebook
082  private List<AdsActionStats> actions = new ArrayList<>();
083
084  public List<AdsActionStats> getActions() {
085    return Collections.unmodifiableList(actions);
086  }
087
088  public boolean addAction(AdsActionStats action) {
089    return actions.add(action);
090  }
091
092  public boolean removeAction(AdsActionStats action) {
093    return actions.remove(action);
094  }
095
096  /**
097   * The number of unique people who took an action such as liking your Page or installing your app as a result of your
098   * ad. For example, if the same person likes and comments on a post, they will be counted as 1 unique person.
099   */
100  @Facebook("unique_actions")
101  private List<AdsActionStats> uniqueActions = new ArrayList<>();
102
103  public List<AdsActionStats> getUniqueActions() {
104    return Collections.unmodifiableList(uniqueActions);
105  }
106
107  public boolean addUniqueAction(AdsActionStats uniqueAction) {
108    return uniqueActions.add(uniqueAction);
109  }
110
111  public boolean removeUniqueAction(AdsActionStats uniqueAction) {
112    return uniqueActions.remove(uniqueAction);
113  }
114
115  /**
116   * The total amount you've spent so far.
117   */
118  @Facebook
119  private Double spend;
120  /**
121   * The number of clicks you received divided by the number of impressions.
122   */
123  @Facebook
124  private Double ctr;
125  /**
126   * The number of people who clicked on your ad divided by the number of people you reached. For example, if you
127   * received 20 unique clicks and your ad was served to 1,000 unique people, your unique click-through rate would be
128   * 2%.
129   */
130  @Facebook("unique_ctr")
131  private Double uniqueCtr;
132  /**
133   * The average cost you've paid to have 1,000 impressions on your ad.
134   */
135  @Facebook
136  private Double cpm;
137  /**
138   * The average cost you've paid to have your ad served to 1,000 unique people.
139   */
140  @Facebook
141  private Double cpp;
142  /**
143   * The average cost per click for these ads, calculated as the amount spent divided by the number of clicks received.
144   */
145  @Facebook
146  private Double cpc;
147  /**
148   * The average you've spent on actions. For example, if you spent $20 and you got 10 Page likes, each one cost an
149   * average of $2.
150   */
151  @Facebook("cost_per_total_action")
152  private Double costPerTotalAction;
153  /**
154   * The average cost per unique click for these ads, calculated as the amount spent divided by the number of unique
155   * clicks received.
156   */
157  @Facebook("cost_per_unique_click")
158  private Double costPerUniqueClick;
159  /**
160   * The average number of times your ad was served to each person.
161   */
162  @Facebook
163  private Double frequency;
164
165  /**
166   * The number of times your ad was served. On our mobile apps an ad is counted as served the first time it's viewed.
167   * On all other Facebook interfaces, an ad is served the first time it's placed in a person's News Feed or each time
168   * it's placed in the right column.
169   */
170  @java.lang.SuppressWarnings("all")
171  public Integer getImpressions() {
172    return this.impressions;
173  }
174
175  /**
176   * The number of times your ad was served. On our mobile apps an ad is counted as served the first time it's viewed.
177   * On all other Facebook interfaces, an ad is served the first time it's placed in a person's News Feed or each time
178   * it's placed in the right column.
179   */
180  @java.lang.SuppressWarnings("all")
181  public void setImpressions(final Integer impressions) {
182    this.impressions = impressions;
183  }
184
185  /**
186   * The number of people your ad was served to.
187   */
188  @java.lang.SuppressWarnings("all")
189  public Integer getUniqueImpressions() {
190    return this.uniqueImpressions;
191  }
192
193  /**
194   * The number of people your ad was served to.
195   */
196  @java.lang.SuppressWarnings("all")
197  public void setUniqueImpressions(final Integer uniqueImpressions) {
198    this.uniqueImpressions = uniqueImpressions;
199  }
200
201  /**
202   * The number of people your ad was served to.
203   */
204  @java.lang.SuppressWarnings("all")
205  public Integer getReach() {
206    return this.reach;
207  }
208
209  /**
210   * The number of people your ad was served to.
211   */
212  @java.lang.SuppressWarnings("all")
213  public void setReach(final Integer reach) {
214    this.reach = reach;
215  }
216
217  /**
218   * The total number of clicks on your ad. Depending on what you're promoting, this can include Page likes, event
219   * responses or app installs.
220   */
221  @java.lang.SuppressWarnings("all")
222  public Integer getClicks() {
223    return this.clicks;
224  }
225
226  /**
227   * The total number of clicks on your ad. Depending on what you're promoting, this can include Page likes, event
228   * responses or app installs.
229   */
230  @java.lang.SuppressWarnings("all")
231  public void setClicks(final Integer clicks) {
232    this.clicks = clicks;
233  }
234
235  /**
236   * The total number of unique people who have clicked on your ad. For example, if 3 people click on the same ad 5
237   * times, it will count as 3 unique clicks.
238   */
239  @java.lang.SuppressWarnings("all")
240  public Integer getUniqueClicks() {
241    return this.uniqueClicks;
242  }
243
244  /**
245   * The total number of unique people who have clicked on your ad. For example, if 3 people click on the same ad 5
246   * times, it will count as 3 unique clicks.
247   */
248  @java.lang.SuppressWarnings("all")
249  public void setUniqueClicks(final Integer uniqueClicks) {
250    this.uniqueClicks = uniqueClicks;
251  }
252
253  /**
254   * The number of actions taken on your ad, Page, app or event after your ad was served to someone, even if they didn't
255   * click on it. Actions include Page likes, app installs, conversions, event responses and more. For example, 2 Page
256   * likes and 2 comments would be counted as 4 actions.
257   */
258  @java.lang.SuppressWarnings("all")
259  public Integer getTotalActions() {
260    return this.totalActions;
261  }
262
263  /**
264   * The number of actions taken on your ad, Page, app or event after your ad was served to someone, even if they didn't
265   * click on it. Actions include Page likes, app installs, conversions, event responses and more. For example, 2 Page
266   * likes and 2 comments would be counted as 4 actions.
267   */
268  @java.lang.SuppressWarnings("all")
269  public void setTotalActions(final Integer totalActions) {
270    this.totalActions = totalActions;
271  }
272
273  /**
274   * The number of unique people who took an action such as liking your Page or installing your app as a result of your
275   * ad. For example, if the same person likes and comments on a post, they will be counted as 1 unique person.
276   */
277  @java.lang.SuppressWarnings("all")
278  public Integer getTotalUniqueActions() {
279    return this.totalUniqueActions;
280  }
281
282  /**
283   * The number of unique people who took an action such as liking your Page or installing your app as a result of your
284   * ad. For example, if the same person likes and comments on a post, they will be counted as 1 unique person.
285   */
286  @java.lang.SuppressWarnings("all")
287  public void setTotalUniqueActions(final Integer totalUniqueActions) {
288    this.totalUniqueActions = totalUniqueActions;
289  }
290
291  /**
292   * The total amount you've spent so far.
293   */
294  @java.lang.SuppressWarnings("all")
295  public Double getSpend() {
296    return this.spend;
297  }
298
299  /**
300   * The total amount you've spent so far.
301   */
302  @java.lang.SuppressWarnings("all")
303  public void setSpend(final Double spend) {
304    this.spend = spend;
305  }
306
307  /**
308   * The number of clicks you received divided by the number of impressions.
309   */
310  @java.lang.SuppressWarnings("all")
311  public Double getCtr() {
312    return this.ctr;
313  }
314
315  /**
316   * The number of clicks you received divided by the number of impressions.
317   */
318  @java.lang.SuppressWarnings("all")
319  public void setCtr(final Double ctr) {
320    this.ctr = ctr;
321  }
322
323  /**
324   * The number of people who clicked on your ad divided by the number of people you reached. For example, if you
325   * received 20 unique clicks and your ad was served to 1,000 unique people, your unique click-through rate would be
326   * 2%.
327   */
328  @java.lang.SuppressWarnings("all")
329  public Double getUniqueCtr() {
330    return this.uniqueCtr;
331  }
332
333  /**
334   * The number of people who clicked on your ad divided by the number of people you reached. For example, if you
335   * received 20 unique clicks and your ad was served to 1,000 unique people, your unique click-through rate would be
336   * 2%.
337   */
338  @java.lang.SuppressWarnings("all")
339  public void setUniqueCtr(final Double uniqueCtr) {
340    this.uniqueCtr = uniqueCtr;
341  }
342
343  /**
344   * The average cost you've paid to have 1,000 impressions on your ad.
345   */
346  @java.lang.SuppressWarnings("all")
347  public Double getCpm() {
348    return this.cpm;
349  }
350
351  /**
352   * The average cost you've paid to have 1,000 impressions on your ad.
353   */
354  @java.lang.SuppressWarnings("all")
355  public void setCpm(final Double cpm) {
356    this.cpm = cpm;
357  }
358
359  /**
360   * The average cost you've paid to have your ad served to 1,000 unique people.
361   */
362  @java.lang.SuppressWarnings("all")
363  public Double getCpp() {
364    return this.cpp;
365  }
366
367  /**
368   * The average cost you've paid to have your ad served to 1,000 unique people.
369   */
370  @java.lang.SuppressWarnings("all")
371  public void setCpp(final Double cpp) {
372    this.cpp = cpp;
373  }
374
375  /**
376   * The average cost per click for these ads, calculated as the amount spent divided by the number of clicks received.
377   */
378  @java.lang.SuppressWarnings("all")
379  public Double getCpc() {
380    return this.cpc;
381  }
382
383  /**
384   * The average cost per click for these ads, calculated as the amount spent divided by the number of clicks received.
385   */
386  @java.lang.SuppressWarnings("all")
387  public void setCpc(final Double cpc) {
388    this.cpc = cpc;
389  }
390
391  /**
392   * The average you've spent on actions. For example, if you spent $20 and you got 10 Page likes, each one cost an
393   * average of $2.
394   */
395  @java.lang.SuppressWarnings("all")
396  public Double getCostPerTotalAction() {
397    return this.costPerTotalAction;
398  }
399
400  /**
401   * The average you've spent on actions. For example, if you spent $20 and you got 10 Page likes, each one cost an
402   * average of $2.
403   */
404  @java.lang.SuppressWarnings("all")
405  public void setCostPerTotalAction(final Double costPerTotalAction) {
406    this.costPerTotalAction = costPerTotalAction;
407  }
408
409  /**
410   * The average cost per unique click for these ads, calculated as the amount spent divided by the number of unique
411   * clicks received.
412   */
413  @java.lang.SuppressWarnings("all")
414  public Double getCostPerUniqueClick() {
415    return this.costPerUniqueClick;
416  }
417
418  /**
419   * The average cost per unique click for these ads, calculated as the amount spent divided by the number of unique
420   * clicks received.
421   */
422  @java.lang.SuppressWarnings("all")
423  public void setCostPerUniqueClick(final Double costPerUniqueClick) {
424    this.costPerUniqueClick = costPerUniqueClick;
425  }
426
427  /**
428   * The average number of times your ad was served to each person.
429   */
430  @java.lang.SuppressWarnings("all")
431  public Double getFrequency() {
432    return this.frequency;
433  }
434
435  /**
436   * The average number of times your ad was served to each person.
437   */
438  @java.lang.SuppressWarnings("all")
439  public void setFrequency(final Double frequency) {
440    this.frequency = frequency;
441  }
442}