1 /*
2 * Copyright (c) 2002-2024, City of Paris
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 *
9 * 1. Redistributions of source code must retain the above copyright notice
10 * and the following disclaimer.
11 *
12 * 2. Redistributions in binary form must reproduce the above copyright notice
13 * and the following disclaimer in the documentation and/or other materials
14 * provided with the distribution.
15 *
16 * 3. Neither the name of 'Mairie de Paris' nor 'Lutece' nor the names of its
17 * contributors may be used to endorse or promote products derived from
18 * this software without specific prior written permission.
19 *
20 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
21 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
22 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
23 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE
24 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
25 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
26 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
27 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
28 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
29 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
30 * POSSIBILITY OF SUCH DAMAGE.
31 *
32 * License 1.0
33 */
34 package fr.paris.lutece.plugins.identitystore.v1.web.rs.dto;
35
36 import com.fasterxml.jackson.annotation.JsonProperty;
37 import com.fasterxml.jackson.annotation.JsonPropertyOrder;
38 import com.fasterxml.jackson.annotation.JsonRootName;
39
40 /**
41 * AuthorDto
42 *
43 */
44 @JsonRootName( DtoFormatConstants.KEY_AUTHOR )
45 @JsonPropertyOrder( {
46 DtoFormatConstants.KEY_AUTHOR_USERNAME, DtoFormatConstants.KEY_AUTHOR_EMAIL, DtoFormatConstants.KEY_AUTHOR_TYPE,
47 DtoFormatConstants.KEY_AUTHOR_APPLICATION_NAME
48 } )
49 public class AuthorDto
50 {
51 private String _strUserName;
52 private String _strEmail;
53 private int _nType;
54 private String _strApplicationName;
55 private String _strApplicationCode;
56
57 /**
58 * @return the _strUserName
59 */
60 @JsonProperty( DtoFormatConstants.KEY_AUTHOR_USERNAME )
61 public String getUserName( )
62 {
63 return _strUserName;
64 }
65
66 /**
67 * @param strUserName
68 * the _strUserName to set
69 */
70 @JsonProperty( DtoFormatConstants.KEY_AUTHOR_USERNAME )
71 public void setUserName( String strUserName )
72 {
73 this._strUserName = strUserName;
74 }
75
76 /**
77 * @return the _strEmail
78 */
79 @JsonProperty( DtoFormatConstants.KEY_AUTHOR_EMAIL )
80 public String getEmail( )
81 {
82 return _strEmail;
83 }
84
85 /**
86 * @param strEmail
87 * the _strEmail to set
88 */
89 @JsonProperty( DtoFormatConstants.KEY_AUTHOR_EMAIL )
90 public void setEmail( String strEmail )
91 {
92 this._strEmail = strEmail;
93 }
94
95 /**
96 * @return the _type
97 */
98 @JsonProperty( DtoFormatConstants.KEY_AUTHOR_TYPE )
99 public int getType( )
100 {
101 return _nType;
102 }
103
104 /**
105 * @param nType
106 * the _nType to set
107 */
108 @JsonProperty( DtoFormatConstants.KEY_AUTHOR_TYPE )
109 public void setType( int nType )
110 {
111 this._nType = nType;
112 }
113
114 /**
115 * @return the _strApplicationName
116 */
117 @JsonProperty( DtoFormatConstants.KEY_AUTHOR_APPLICATION_NAME )
118 public String getApplicationName( )
119 {
120 return _strApplicationName;
121 }
122
123 /**
124 * @param strApplicationName
125 * the _strApplicationName to set
126 */
127 @JsonProperty( DtoFormatConstants.KEY_AUTHOR_APPLICATION_NAME )
128 public void setApplicationName( String strApplicationName )
129 {
130 this._strApplicationName = strApplicationName;
131 }
132
133 /**
134 * @return the _strApplicationCode
135 */
136 @JsonProperty( DtoFormatConstants.KEY_AUTHOR_APPLICATION_CODE )
137 public String getApplicationCode( )
138 {
139 return _strApplicationCode;
140 }
141
142 /**
143 * @param strApplicationCode
144 * the _strApplicationName to set
145 */
146 @JsonProperty( DtoFormatConstants.KEY_AUTHOR_APPLICATION_CODE )
147 public void setApplicationCode( String strApplicationCode )
148 {
149 this._strApplicationCode = strApplicationCode;
150 }
151 }