4747 */
4848@ ApiModel (description = "Container class for details of encryption." )
4949public class PdfEncryptionDetailsData {
50- /**
51- * Gets or sets the encryption algorithm to use.
52- */
53- @ JsonAdapter (EncryptionAlgorithmEnum .Adapter .class )
54- public enum EncryptionAlgorithmEnum {
55- RC4_40 ("RC4_40" ),
56- RC4_128 ("RC4_128" );
57-
58- private String value ;
59-
60- EncryptionAlgorithmEnum (String value ) {
61- this .value = value ;
62- }
63-
64- public String getValue () {
65- return value ;
66- }
67-
68- @ Override
69- public String toString () {
70- return String .valueOf (value );
71- }
72-
73- public static EncryptionAlgorithmEnum fromValue (String text ) {
74- for (EncryptionAlgorithmEnum b : EncryptionAlgorithmEnum .values ()) {
75- if (String .valueOf (b .value ).equals (text )) {
76- return b ;
77- }
78- }
79- return null ;
80- }
81-
82- public static class Adapter extends TypeAdapter < EncryptionAlgorithmEnum > {
83- @ Override
84- public void write (final JsonWriter jsonWriter , final EncryptionAlgorithmEnum enumeration ) throws IOException {
85- jsonWriter .value (enumeration .getValue ());
86- }
87-
88- @ Override
89- public EncryptionAlgorithmEnum read (final JsonReader jsonReader ) throws IOException {
90- String value = jsonReader .nextString ();
91- return EncryptionAlgorithmEnum .fromValue (String .valueOf (value ));
92- }
93- }
94- }
95-
96- @ SerializedName ("EncryptionAlgorithm" )
97- protected EncryptionAlgorithmEnum encryptionAlgorithm ;
98-
9950 @ SerializedName ("OwnerPassword" )
10051 protected String ownerPassword ;
10152
@@ -104,25 +55,6 @@ public EncryptionAlgorithmEnum read(final JsonReader jsonReader) throws IOExcept
10455
10556 @ SerializedName ("UserPassword" )
10657 protected String userPassword ;
107- /**
108- * Gets or sets the encryption algorithm to use.
109- * @return encryptionAlgorithm
110- **/
111- @ ApiModelProperty (value = "Gets or sets the encryption algorithm to use." )
112- public EncryptionAlgorithmEnum getEncryptionAlgorithm () {
113- return encryptionAlgorithm ;
114- }
115-
116- public PdfEncryptionDetailsData encryptionAlgorithm (EncryptionAlgorithmEnum encryptionAlgorithm ) {
117- this .encryptionAlgorithm = encryptionAlgorithm ;
118- return this ;
119- }
120-
121- public void setEncryptionAlgorithm (EncryptionAlgorithmEnum encryptionAlgorithm ) {
122- this .encryptionAlgorithm = encryptionAlgorithm ;
123- }
124-
125-
12658 /**
12759 * Gets or sets the owner password for the encrypted PDF document.
12860 * @return ownerPassword
@@ -190,7 +122,6 @@ public void setUserPassword(String userPassword) {
190122
191123
192124 public PdfEncryptionDetailsData () {
193- this .encryptionAlgorithm = null ;
194125 this .ownerPassword = null ;
195126 this .permissions = null ;
196127 this .userPassword = null ;
@@ -207,22 +138,20 @@ public boolean equals(java.lang.Object o) {
207138
208139 PdfEncryptionDetailsData pdfEncryptionDetailsData = (PdfEncryptionDetailsData ) o ;
209140 return
210- Objects .equals (this .encryptionAlgorithm , pdfEncryptionDetailsData .encryptionAlgorithm ) &&
211141 Objects .equals (this .ownerPassword , pdfEncryptionDetailsData .ownerPassword ) &&
212142 Objects .equals (this .permissions , pdfEncryptionDetailsData .permissions ) &&
213143 Objects .equals (this .userPassword , pdfEncryptionDetailsData .userPassword );
214144 }
215145
216146 @ Override
217147 public int hashCode () {
218- return Objects .hash (encryptionAlgorithm , ownerPassword , permissions , userPassword );
148+ return Objects .hash (ownerPassword , permissions , userPassword );
219149 }
220150
221151 @ Override
222152 public String toString () {
223153 StringBuilder sb = new StringBuilder ();
224154 sb .append ("class PdfEncryptionDetailsData {\n " );
225- sb .append (" encryptionAlgorithm: " ).append (toIndentedString (getEncryptionAlgorithm ())).append ("\n " );
226155 sb .append (" ownerPassword: " ).append (toIndentedString (getOwnerPassword ())).append ("\n " );
227156 sb .append (" permissions: " ).append (toIndentedString (getPermissions ())).append ("\n " );
228157 sb .append (" userPassword: " ).append (toIndentedString (getUserPassword ())).append ("\n " );
0 commit comments