- Integer profileBirthDay = Numbers.safeParseInteger(profileXml.getValue("birth-day", null));
- Integer profileBirthMonth = Numbers.safeParseInteger(profileXml.getValue("birth-month", null));
- Integer profileBirthYear = Numbers.safeParseInteger(profileXml.getValue("birth-year", null));
- Profile profile = new Profile().setFirstName(profileFirstName).setMiddleName(profileMiddleName).setLastName(profileLastName);
+ Integer profileBirthDay = Ints.tryParse(profileXml.getValue("birth-day", null));
+ Integer profileBirthMonth = Ints.tryParse(profileXml.getValue("birth-month", null));
+ Integer profileBirthYear = Ints.tryParse(profileXml.getValue("birth-year", null));
+ Profile profile = new Profile(sone).setFirstName(profileFirstName).setMiddleName(profileMiddleName).setLastName(profileLastName);