code: public static String getProperty(String name, String def) {
          String ret = System.getProperty(name, System.getenv(name));
          if (ret != null) {
              return ret;
          }
          return def;
      }
docs: This method returns the named property, first checking the system properties
  and if not found, checking the environment.
  
  @param name The name
  @param def The default if not found
  @return The property, or the default value if not found