public void saveRun(int userID, String run, String distance, String year, String nationality, String tshirt, String chipNumber, String groupName, String bestTime, String goalTime, Locale locale) {
public void saveRun(int userID, String run, String distance, String year, String nationality, String tshirt, String chipOwnershipStatus, String chipNumber, String groupName, String bestTime, String goalTime, Locale locale) {
	public void saveRun(int userID, String run, String distance, String year, String nationality, String tshirt, String chipNumber, String groupName, String bestTime, String goalTime, Locale locale) {		Group groupRun = null;		Group disGroup = null;		User user = null;		try {			groupRun = getGroupBiz().getGroupByGroupID(Integer.parseInt(run));		}		catch (IBOLookupException e) {			e.printStackTrace();		}		catch (NumberFormatException e) {			e.printStackTrace();		}		catch (RemoteException e) {			e.printStackTrace();		}		catch (UnavailableIWContext e) {			e.printStackTrace();		}		catch (FinderException e) {			e.printStackTrace();		}		String distanceType = null;		try {			user = getUserBiz().getUser(userID);			int age = getUserAge(user);			if (distance != null && !distance.equals("")) {				int disGroupID = Integer.parseInt(distance);								try {					disGroup = getGroupBiz().getGroupByGroupID(disGroupID);					distanceType = disGroup.getName();				}				catch (UnavailableIWContext e1) {					e1.printStackTrace();				}				catch (FinderException e1) {					e1.printStackTrace();				}				String[] groupType = { IWMarathonConstants.GROUP_TYPE_RUN_GROUP };				Collection groups = getGroupBiz().getChildGroupsRecursive(disGroup, groupType, true);				Iterator groupsIter = groups.iterator();				while (groupsIter.hasNext()) {					Group group = (Group) groupsIter.next();					if (group.getName().equals(getGroupName(age, groupRun, user.getGenderID()))) {						group.addGroup(user);						group.store();					}				}			}			RunHome runHome = (RunHome) getIDOHome(Run.class);			Run r = runHome.create();			r.setUserID(userID);			r.setRunTypeGroupID(Integer.parseInt(run));			r.setRunDistanceGroupID(Integer.parseInt(distance));			r.setRunYearGroupID(Integer.parseInt(year));			r.setTShirtSize(tshirt);			r.setChipNumber(chipNumber);			r.setRunGroupName(groupName);			r.setUserNationality(nationality);			if (bestTime != null && !bestTime.equals("")) {				r.setBestTime(bestTime);			}			if (goalTime != null && !goalTime.equals("")) {				r.setGoalTime(goalTime);			}			if (distanceType != null) {				try {					int participantNumber = runHome.getNextAvailableParticipantNumber(getMinParticipantNumber(distanceType), getMaxParticipantNumber(distanceType));					if (participantNumber == 0) {						participantNumber = getMinParticipantNumber(distanceType);					}					else {						participantNumber++;					}					r.setParticipantNumber(participantNumber);				}				catch (IDOException ie) {					ie.printStackTrace();				}			}			r.store();			Email email = getUserBiz().getUserMail(user);			if (groupRun != null && user != null && email != null && email.getEmailAddress() != null) {				IWResourceBundle iwrb = getIWApplicationContext().getIWMainApplication().getBundle(IW_BUNDLE_IDENTIFIER).getResourceBundle(locale);				Object[] args = { user.getName(), iwrb.getLocalizedString(groupRun.getName(),groupRun.getName()), iwrb.getLocalizedString(disGroup.getName(),disGroup.getName()), iwrb.getLocalizedString(tshirt, tshirt) };				String subject = iwrb.getLocalizedString("registration_received_subject_mail", "Your registration has been received.");				String body = MessageFormat.format(iwrb.getLocalizedString("registration_received_body_mail", "Your registration has been received."), args);				sendMessage(email.getEmailAddress(), subject, body);			}		}		catch (RemoteException rme) {		}		catch (CreateException cre) {		}	}