Developing an Android App: Plugins?

clamum

Lifer
Feb 13, 2003
26,256
406
126
I'm in the process or working on an Android app and am wondering if the following is possible, before I get much further.

My plan is to finish the app and put it on the Marketplace, for say $0.99. Then, I would write plugins and post those on the Marketplace, but make them free. So if you buy the standard app, you'll be able to get any further plugins for free.

So I'm wondering if the Android system, and the Marketplace, would allow me to implement this sort of thing. I did some searching on the Internet about Android plugins and found a couple references (this seems to be the best I've found) but figured I'd ask you guys too.

Thanks.
 

Evadman

Administrator Emeritus<br>Elite Member
Feb 18, 2001
30,990
5
81
Yes, that is possible. But if that is the pricing strategy you want to use, I would not bother with a plugin framework. Just update the base app with whatever you add and the app store will host the updated package and deploy it for you.

Now, if you flip the pricing model so the base app is free and the plugins cost some incremental amount each, then I see a need for a plugin type framework.

Basically, a plugin would be another apk but not accessible to the user. To make a apk non-accessable, don't put the intent filter in the manifest:

Code:
<intent-filter>
   <action android:name="android.intent.action.MAIN" />
   <category android:name="android.intent.category.LAUNCHER" />
</intent-filter>

Then, if you want to know if a plugin is available on the device, you can use the package manager (PackageManager.queryIntentActivities) and look for whatever the intent is that you declared for the plugin.

The final step would be using the data/methods/whatever in the plugin by asking the package manager to make the resources available via getResourcesForActivity.

finally, you would need a way to secure the plugin apk so that it is more difficult to pass around. Something like verifying the phone serial against an approved list or whatever.
 

clamum

Lifer
Feb 13, 2003
26,256
406
126
Ah, I see what you mean re: my pricing model.

Thank you for the help. One question though, when you recommend verifying a phone serial against an approved list, would I need to query a database I host and insert a record when a person installs a plugin? And then check the database when a plugin is loaded and make sure there is a matching record? Sorry if it's a dumb question :)
 

Evadman

Administrator Emeritus<br>Elite Member
Feb 18, 2001
30,990
5
81
When you recommend verifying a phone serial against an approved list, would I need to query a database I host and insert a record when a person installs a plugin? And then check the database when a plugin is loaded and make sure there is a matching record?

That was my suggestion based on thinking for all of 10 seconds. There are probably better ways to do it. You also need to decide on if you are worried enough to verify anyway. No matter how you implement a verification model, a determined hacker will be able to undo it. Software can be changed (even compiled software) and hardware (like USB keys) can be emulated. It's only a matter of time, and someone with the determination.
 

clamum

Lifer
Feb 13, 2003
26,256
406
126
That was my suggestion based on thinking for all of 10 seconds. There are probably better ways to do it. You also need to decide on if you are worried enough to verify anyway. No matter how you implement a verification model, a determined hacker will be able to undo it. Software can be changed (even compiled software) and hardware (like USB keys) can be emulated. It's only a matter of time, and someone with the determination.
I see. Well I guess I need to decide on a pricing model I guess. Hmmm.

Well thanks a lot for your help!
 
Last edited:

clamum

Lifer
Feb 13, 2003
26,256
406
126
My reason for the pricing model I chose was that I figured that it would be an incentive to buy the app and get any free updates to it (in the form of plugins). By plugins I mean separate functionality apart from the main app, but would complement the app, that I would implement if users asked for it.

Do you guys think this is a good pricing model? Maybe I should just release it all for free? I'm Just wondering since I have no experience with this sorta thing.

Thank you!