public static boolean validatePath ( String path ) { if ( path == null ) { Log . w ( TAG , "Uploading path not set" ) ; return false ; } try { uriFromString ( path ) ; return true ; } catch ( DataSinkException e ) { return false ; } }
Returns true if the path is not null and if it is a valid URI .