I use the following code to download the ics file from mail by using my application. In the Intent filter I use
<data android:mimeType="*/*" />
<data android:pathPattern=".*\\.ics" />
By using that I can download the ics file and it also supports to download all the file formats from my application. I need to download the ics file only. How to download a specified file format?