Search code examples
androidandroid-intentintentfilter

ACTION_MAIN filter , expecting to receive data


I've been reading the documentation about Intents and Intent-Filters, and I was wondering if there is not such a thing as a predefined action to launch an activity expecting some data, for example, an IP address to connect.

I understand ACTION_MAIN is to offer an entry point to the Application, so not to expect data makes sense. But I don't think the case I'm talking about it's that strange.

Maybe I'm thinking too much and I just need a custom ACTION, but I wanted to find the proper way.

Any suggestion is welcome.

Manuel.


Solution

  • I was wondering if there is not such a thing as a predefined action to launch an activity expecting some data, for example, an IP address to connect.

    Many Intent actions expect some data. There is no generic "Hi! I want to send you some data!" Intent. You pick (or create) an Intent action based on the operation you want done on that data.