Closes the supplied cursor iff it is not null. if (cursor != null) { cursor.close(); }
if (cursor != null) { cursor.close(); }
Closes the given file descriptor iff it is not null, ignoring exceptions. if (assetFileDescriptor != null) { try { assetFileDescriptor.close(); } catch (IOException e) { // Ignore exceptions when closing. } }
if (assetFileDescriptor != null) { try { assetFileDescriptor.close(); } catch (IOException e) { // Ignore exceptions when closing. } }