-2

I want to make an application that tracks the total consumption of Internet data or in other words a data tracker. If the set limit is reached I want the Internet data package connection to be disabled.

Is it possible with the iPhone SDK? If yes, then which API and the library should I be looking at?

Vadim Kotov
  • 8,084
  • 8
  • 48
  • 62
usman zafar
  • 220
  • 2
  • 9

2 Answers2

1

You can't do this without going the jailbreak route. What you could possibly do is maybe show a notification to the user if they are near to reaching the limit.

To get the amount of data consumed, some service providers provide APIs (I'm thinking of the consume app) where you can get the data consumed and data left from the provider side.

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
Suhail Patel
  • 13,644
  • 2
  • 44
  • 49
1

Manipulating the core system preferences (disabling data packages) and measuring packages sent and received are both outside the "quarantine-zone" of the Apple Developer Guidelines.

If you DO happen to find some tricky way to do this (that is, the private iOS frameworks) you must know that your app will never be approved.

The closest thing that comes to this was the talk about a statistics API, where apps could see the number of calls made, data transferred, etc. But this was not very well looked upon by the approval board, and will probably not be a reality any time soon.

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
Nils Munch
  • 8,805
  • 11
  • 51
  • 103
  • Hi Nils, thanks for your response, may i know which private ios framework you are referring (rough idea) that can be used to disable data package. i be transparent with you, the client is a telecom operator (already distribute iphone regionally) so hope if i go from their contact i might get a chance to be approved by iphone, whats your suggestion mate. – usman zafar Jul 24 '11 at 15:02
  • That better be a really solid contact. Apple are very strict with this framework, and not even AT&T was able to make them bulge on the rules. But if they are confident that they can make it through, then go for it. But its more plausible that you will be allowed as a installation made directly on the device once sold, than a downloadable app. – Nils Munch Jul 24 '11 at 16:08