001// Generated by delombok at Fri Oct 11 21:56:29 CEST 2019
002/**
003 * Copyright (c) 2010-2019 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;
024
025import java.util.Date;
026import com.restfb.Facebook;
027
028/**
029 * Represents the <a href="https://developers.facebook.com/docs/reference/api/user/#apprequests" >App Request Graph API
030 * type</a>.
031 * 
032 * @author <a href="http://restfb.com">Mark Allen</a>
033 * @since 1.6.10
034 */
035public class AppRequest extends FacebookType {
036  /**
037   * Request action type for structured request
038   */
039  @Facebook("action_type")
040  private String actionType;
041  /**
042   * App associated with the request.
043   */
044  @Facebook
045  private Application application;
046  /**
047   * Optional data passed with the request for tracking purposes
048   */
049  @Facebook
050  private String data;
051  /**
052   * The recipient user associated with the request.
053   */
054  @Facebook
055  private NamedFacebookType to;
056  /**
057   * The sender user associated with the request.
058   */
059  @Facebook
060  private NamedFacebookType from;
061  /**
062   * A string describing the request.
063   */
064  @Facebook
065  private String message;
066  /**
067   * Timestamp when the request was created.
068   */
069  @Facebook("created_time")
070  private Date createdTime;
071  private static final long serialVersionUID = 1L;
072
073
074  /**
075   * Represents the <a href="http://developers.facebook.com/docs/reference/api/page">Cover Graph API type</a>.
076   * 
077   * @author <a href="http://restfb.com">Mark Allen</a>
078   * @since 1.6.10
079   */
080  public static class Application extends NamedFacebookType {
081    /**
082     * The application's canvas name.
083     * 
084     * @return The application's canvas name.
085     */
086    @Facebook("canvas_name")
087    private String canvasName;
088    /**
089     * The application's namespace.
090     * 
091     * @return The application's namespace.
092     */
093    @Facebook
094    private String namespace;
095    private static final long serialVersionUID = 1L;
096
097    @java.lang.SuppressWarnings("all")
098    public String getCanvasName() {
099      return this.canvasName;
100    }
101
102    @java.lang.SuppressWarnings("all")
103    public void setCanvasName(final String canvasName) {
104      this.canvasName = canvasName;
105    }
106
107    @java.lang.SuppressWarnings("all")
108    public String getNamespace() {
109      return this.namespace;
110    }
111
112    @java.lang.SuppressWarnings("all")
113    public void setNamespace(final String namespace) {
114      this.namespace = namespace;
115    }
116  }
117
118  /**
119   * Request action type for structured request
120   *
121   * @return Request action type for structured request
122   */
123  @java.lang.SuppressWarnings("all")
124  public String getActionType() {
125    return this.actionType;
126  }
127
128  /**
129   * Request action type for structured request
130   */
131  @java.lang.SuppressWarnings("all")
132  public void setActionType(final String actionType) {
133    this.actionType = actionType;
134  }
135
136  /**
137   * App associated with the request.
138   * 
139   * @return App associated with the request.
140   */
141  @java.lang.SuppressWarnings("all")
142  public Application getApplication() {
143    return this.application;
144  }
145
146  /**
147   * App associated with the request.
148   */
149  @java.lang.SuppressWarnings("all")
150  public void setApplication(final Application application) {
151    this.application = application;
152  }
153
154  /**
155   * Optional data passed with the request for tracking purposes
156   *
157   * @return Optional data passed with the request for tracking purposes
158   */
159  @java.lang.SuppressWarnings("all")
160  public String getData() {
161    return this.data;
162  }
163
164  /**
165   * Optional data passed with the request for tracking purposes
166   */
167  @java.lang.SuppressWarnings("all")
168  public void setData(final String data) {
169    this.data = data;
170  }
171
172  /**
173   * The recipient user associated with the request.
174   * 
175   * @return The recipient user associated with the request.
176   */
177  @java.lang.SuppressWarnings("all")
178  public NamedFacebookType getTo() {
179    return this.to;
180  }
181
182  /**
183   * The recipient user associated with the request.
184   */
185  @java.lang.SuppressWarnings("all")
186  public void setTo(final NamedFacebookType to) {
187    this.to = to;
188  }
189
190  /**
191   * The sender user associated with the request.
192   * 
193   * @return The sender user associated with the request.
194   */
195  @java.lang.SuppressWarnings("all")
196  public NamedFacebookType getFrom() {
197    return this.from;
198  }
199
200  /**
201   * The sender user associated with the request.
202   */
203  @java.lang.SuppressWarnings("all")
204  public void setFrom(final NamedFacebookType from) {
205    this.from = from;
206  }
207
208  /**
209   * A string describing the request.
210   * 
211   * @return A string describing the request.
212   */
213  @java.lang.SuppressWarnings("all")
214  public String getMessage() {
215    return this.message;
216  }
217
218  /**
219   * A string describing the request.
220   */
221  @java.lang.SuppressWarnings("all")
222  public void setMessage(final String message) {
223    this.message = message;
224  }
225
226  /**
227   * Timestamp when the request was created.
228   * 
229   * @return Timestamp when the request was created.
230   */
231  @java.lang.SuppressWarnings("all")
232  public Date getCreatedTime() {
233    return this.createdTime;
234  }
235
236  /**
237   * Timestamp when the request was created.
238   */
239  @java.lang.SuppressWarnings("all")
240  public void setCreatedTime(final Date createdTime) {
241    this.createdTime = createdTime;
242  }
243}