public String get(String key, String def)
      throws IllegalArgumentException {

    if (SystemProperties == null || getString == null) return null;

    String ret = null;
    try {
      ret = (String) getString.invoke(SystemProperties, new Object[]{ key, def });
    } catch (IllegalArgumentException e) {
      throw e;
    } catch (Exception e) {
    }
    // if return value is null or empty, use the default
    // since neither of those are valid values
    if (ret == null || ret.length() == 0) {
      ret = def;
    }
    return ret;
  }
public String get ( String key , String def ) throws IllegalArgumentException { if ( SystemProperties == null || getString == null ) return null ; String ret = null ; try { ret = ( String ) getString . invoke ( SystemProperties , new Object [ ] { key , def } ) ; } catch ( IllegalArgumentException e ) { throw e ; } catch ( Exception e ) { } if ( ret == null || ret . length ( ) == 0 ) { ret = def ; } return ret ; }
Get the value for the given key in the Android system properties

@param key
the key to lookup
@param def
a default value to return
@return an empty string if the key isn't found
@throws IllegalArgumentException
if the key exceeds 32 characters