Skip to content

Commit

Permalink
Read fields 'ignored contact friend family' from 'flickr.people.getIn…
Browse files Browse the repository at this point in the history
…fo' response. Fix #142
  • Loading branch information
boncey committed Aug 2, 2015
1 parent 7cf3a6a commit 4c00988
Show file tree
Hide file tree
Showing 2 changed files with 57 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,11 @@ public User getInfo(String userId) throws FlickrException {
user.setPathAlias(lPathAlias == null || "".equals(lPathAlias) ? null : lPathAlias);
user.setUsername(XMLUtilities.getChildValue(userElement, "username"));
user.setDescription(XMLUtilities.getChildValue(userElement, "description"));
user.setGender(XMLUtilities.getChildValue(userElement, "gender"));
user.setIgnored("1".equals(XMLUtilities.getChildValue(userElement, "ignored")));
user.setContact("1".equals(XMLUtilities.getChildValue(userElement, "contact")));
user.setFriend("1".equals(XMLUtilities.getChildValue(userElement, "friend")));
user.setFamily("1".equals(XMLUtilities.getChildValue(userElement, "family")));
user.setRealName(XMLUtilities.getChildValue(userElement, "realname"));
user.setLocation(XMLUtilities.getChildValue(userElement, "location"));
user.setMbox_sha1sum(XMLUtilities.getChildValue(userElement, "mbox_sha1sum"));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,16 @@ protected synchronized SimpleDateFormat initialValue() {

private String description;

private String gender;

private boolean ignored;

private boolean contact;

private boolean friend;

private boolean family;

private boolean admin;

private boolean pro;
Expand Down Expand Up @@ -124,12 +134,53 @@ public String getDescription() {
}

/**
* @param description the description to set
* @param description
* the description to set
*/
public void setDescription(String description) {
this.description = description;
}

public String getGender() {
return gender;
}

public void setGender(String gender) {
this.gender = gender;
}

public boolean isIgnored() {
return ignored;
}

public void setIgnored(boolean ignored) {
this.ignored = ignored;
}

public boolean isContact() {
return contact;
}

public void setContact(boolean contact) {
this.contact = contact;
}

public boolean isFriend() {
return friend;
}

public void setFriend(boolean friend) {
this.friend = friend;
}

public boolean isFamily() {
return family;
}

public void setFamily(boolean family) {
this.family = family;
}

public boolean isAdmin() {
return admin;
}
Expand Down

0 comments on commit 4c00988

Please sign in to comment.