开发者

Android intent filter data path example

开发者 https://www.devze.com 2023-01-13 00:32 出处:网络
I tried using the following data in my intent filter: <data android:scheme=开发者_StackOverflow社区\"http\" android:host=\"an.example.i.p\" android:pathPrefix=\"t\" />

I tried using the following data in my intent filter:

<data android:scheme=开发者_StackOverflow社区"http" android:host="an.example.i.p" android:pathPrefix="t" />

Why doesn't the following url trigger it?

http://an.example.i.p/t/v2.aspx/chase/a.test.auto


Try android:pathPrefix="/t". The IntentFilter calls Uri#getPath and pass the resulting string to the PatternMatcher and Uri#getPath returns with the starting /.

0

精彩评论

暂无评论...
验证码 换一张
取 消