List of usage examples for android.support.v4 BuildConfig APPLICATION_ID
String APPLICATION_ID
To view the source code for android.support.v4 BuildConfig APPLICATION_ID.
Click Source Link
From source file:com.google.android.apps.location.gps.gnsslogger.FileLogger.java
/** * Send the current log via email or other options selected from a pop menu shown to the user. A * new log is started when calling this function. *//*from w w w .j a v a 2s . c o m*/ public void send() { if (mFile == null) { return; } Intent emailIntent = new Intent(Intent.ACTION_SEND); emailIntent.setType("*/*"); emailIntent.putExtra(Intent.EXTRA_SUBJECT, "SensorLog"); emailIntent.putExtra(Intent.EXTRA_TEXT, ""); // attach the file Uri fileURI = FileProvider.getUriForFile(mContext, BuildConfig.APPLICATION_ID + ".provider", mFile); emailIntent.putExtra(Intent.EXTRA_STREAM, fileURI); getUiComponent().startActivity(Intent.createChooser(emailIntent, "Send log..")); if (mFileWriter != null) { try { mFileWriter.flush(); mFileWriter.close(); mFileWriter = null; } catch (IOException e) { logException("Unable to close all file streams.", e); return; } } }