src/org/ohmage/domain/MobilityPoint.java
public static List<ColumnKey> validateKeyString(
			final String key) 
			throws DomainException {
		
		if(key == null) {
			throw new DomainException("The key cannot be null.");
		}
		
		try {
			if(key.startsWith(MobilityColumnKey.NAMESPACE)) {
				return MobilityColumnKey.valueOfString(key);
			}
			else if(key.startsWith(LocationColumnKey.NAMESPACE)) {
				return LocationColumnKey.valueOfString(key);
			}
			else if(key.startsWith(SensorDataColumnKey.NAMESPACE)) {
				return SensorDataColumnKey.valueOfString(key);
			}
			else if(key.startsWith(AccelDataColumnKey.NAMESPACE)) {
				return AccelDataColumnKey.valueOfString(key);
			}
			else if(key.startsWith(WifiDataColumnKey.NAMESPACE)) {
				return WifiDataColumnKey.valueOfString(key);
			}
			else if(key.startsWith(ClassifierDataColumnKey.NAMESPACE)) {
				return ClassifierDataColumnKey.valueOfString(key);
			}
			else {
				throw new DomainException("The key is unknown: " + key);
			}
		}
		catch(IllegalArgumentException e) {
			throw new DomainException("The key is unknown: " + key, e);
		}
	}
/**
	 * Validates a string that represents some key related to Mobility, this
	 * could be a Mobility key, a Location key, or any of Mobility inner class
	 * keys, and converts it to the appropriate key.
	 * 
	 * @param key The key string to be validated.
	 * 
	 * @return A ColumnKey representing the appropriate key.
	 * 
	 * @throws DomainException The key was null or could not be decoded.
	 */
Validates a string that represents some key related to Mobility, this
could be a Mobility key, a Location key, or any of Mobility inner class
keys, and converts it to the appropriate key.

@param key The key string to be validated.

@return A ColumnKey representing the appropriate key.

@throws DomainException The key was null or could not be decoded.
Validates a string that represents some key related to Mobility this could be a Mobility key a Location key or any of Mobility inner class keys and converts it to the appropriate key . @param key The key string to be validated . @return A ColumnKey representing the appropriate key . @throws DomainException The key was null or could not be decoded .
public static List<ColumnKey> validateKeyString(
			final String key) 
			throws DomainException {
		if(key == null) {
			throw new DomainException("The key cannot be null.");
		}
		try {
			if(key.startsWith(MobilityColumnKey.NAMESPACE)) {
				return MobilityColumnKey.valueOfString(key);
			}
			else if(key.startsWith(LocationColumnKey.NAMESPACE)) {
				return LocationColumnKey.valueOfString(key);
			}
			else if(key.startsWith(SensorDataColumnKey.NAMESPACE)) {
				return SensorDataColumnKey.valueOfString(key);
			}
			else if(key.startsWith(AccelDataColumnKey.NAMESPACE)) {
				return AccelDataColumnKey.valueOfString(key);
			}
			else if(key.startsWith(WifiDataColumnKey.NAMESPACE)) {
				return WifiDataColumnKey.valueOfString(key);
			}
			else if(key.startsWith(ClassifierDataColumnKey.NAMESPACE)) {
				return ClassifierDataColumnKey.valueOfString(key);
			}
			else {
				throw new DomainException("The key is unknown: " + key);
			}
		}
		catch(IllegalArgumentException e) {
			throw new DomainException("The key is unknown: " + key, e);
		}
	}
public static List < ColumnKey > validateKeyString ( final String key ) throws DomainException { if ( key == null ) { throw new DomainException ( "The key cannot be null." ) ; } try { if ( key . startsWith ( MobilityColumnKey . NAMESPACE ) ) { return MobilityColumnKey . valueOfString ( key ) ; } else if ( key . startsWith ( LocationColumnKey . NAMESPACE ) ) { return LocationColumnKey . valueOfString ( key ) ; } else if ( key . startsWith ( SensorDataColumnKey . NAMESPACE ) ) { return SensorDataColumnKey . valueOfString ( key ) ; } else if ( key . startsWith ( AccelDataColumnKey . NAMESPACE ) ) { return AccelDataColumnKey . valueOfString ( key ) ; } else if ( key . startsWith ( WifiDataColumnKey . NAMESPACE ) ) { return WifiDataColumnKey . valueOfString ( key ) ; } else if ( key . startsWith ( ClassifierDataColumnKey . NAMESPACE ) ) { return ClassifierDataColumnKey . valueOfString ( key ) ; } else { throw new DomainException ( "The key is unknown: " + key ) ; } } catch ( IllegalArgumentException e ) { throw new DomainException ( "The key is unknown: " + key , e ) ; } }
Validates a string that represents some key related to Mobility, this
 could be a Mobility key, a Location key, or any of Mobility inner class
 keys, and converts it to the appropriate key.
Validates a string that represents some key related to Mobility this could be a Mobility key a Location key or any of Mobility inner class keys and converts it to the appropriate key .