File tree Expand file tree Collapse file tree
jackson/src/main/java/org/baeldung/jackson/entities Expand file tree Collapse file tree Original file line number Diff line number Diff line change 33import java .util .Date ;
44import java .util .List ;
55
6- import com .fasterxml .jackson .databind .annotation .JsonDeserialize ;
7-
86public class ActorJackson {
97
108 private String imdbId ;
119 private Date dateOfBirth ;
1210 private List <String > filmography ;
1311
12+ public ActorJackson () {
13+ super ();
14+ }
15+
16+ public ActorJackson (String imdbId , Date dateOfBirth , List <String > filmography ) {
17+ super ();
18+ this .imdbId = imdbId ;
19+ this .dateOfBirth = dateOfBirth ;
20+ this .filmography = filmography ;
21+ }
22+
23+ @ Override
24+ public String toString () {
25+ return "ActorJackson [imdbId=" + imdbId + ", dateOfBirth=" + dateOfBirth + ", filmography=" + filmography + "]" ;
26+ }
27+
1428 public String getImdbId () {
1529 return imdbId ;
1630 }
@@ -35,21 +49,4 @@ public void setFilmography(List<String> filmography) {
3549 this .filmography = filmography ;
3650 }
3751
38- public ActorJackson (String imdbId , Date dateOfBirth , List <String > filmography ) {
39- super ();
40- this .imdbId = imdbId ;
41- this .dateOfBirth = dateOfBirth ;
42- this .filmography = filmography ;
43- }
44-
45- public ActorJackson () {
46-
47- super ();
48- }
49-
50- @ Override
51- public String toString () {
52- return "ActorJackson [imdbId=" + imdbId + ", dateOfBirth=" + dateOfBirth + ", filmography=" + filmography + "]" ;
53- }
54-
5552}
Original file line number Diff line number Diff line change 11package org .baeldung .jackson .entities ;
22
3- import java .util .List ;
4-
53import com .fasterxml .jackson .annotation .JsonIgnore ;
6- import com .google .gson .annotations .Expose ;
4+
5+ import java .util .List ;
76
87public class MovieWithNullValue {
98
You can’t perform that action at this time.
0 commit comments