I have been trying to figure out the best way to structure my watch apps for the last couple of days, and haven't had a lot of success. Currently in my iPhone apps I have several libraries that I use for various standard things. This includes things like the base class of my data objects, helpers for converting them from JSON, and base classes for my services.
The problem that this causes for me is that I am unable to find a way to include these libraries in my watch extension, and this means that I can't even share any of the data objects from my main application because all of them rely on the library.
So, my question is, is there a way that I can share a library between my main app, and the watch app?
Related
I have several small apps that share common data (images, sounds files, etc). This data bloats the size of each app. When the user installs 2 or more of these apps that will bloat the device space with duplicate data. Is there a way that I can share this data between my apps so that each app doesn't duplicate this data within its bundle?
You can have a common file space between apps by using app groups. An example of how to use them can be found here: Sharing data in between apps in IOS
You can use this as part of a solve for not duplicating the data in every bundle. One way might be to have the data hosted on a server somewhere and when the app is installed you can check the App Group for the common data, if it is not there, you can download it and store it there. Then the next app that is installed will have the data already available. This should help avoid having to include it in every small app.
You can set up the code to check the shared location and download the data in a framework and share it between all your apps making it a bit easier to maintain. If you do not already have a content management system then you could google for a few that have iOS support. There are many out there. You would then host the shared data there. This would give you the ability to update the data for each app while they are in the field which could be a time saver. If these apps are very small though, this may be overkill.
No, this is not currently possible. Ideally, this kind of resource-sharing would require creating a common framework bundle that would have to
be submitted separately to the App Store as a third-party framework, so that even if only one of your apps is present on the
device, it would be able to load the appropriate resources and function properly.
Apple currently only allows third-party frameworks embedded within the app bundle.
Even if two of your apps use the same exact version of your framework, they have to embed it separately.
I am making an app that involves sending and receiving files from one iPhone to several other iPhones. I did a lot of googling and came nowhere in finding the classes that support the above said features. I am wondering whether it is possible and if it is possible what are the classes that i can use to do that
Take a look at my library https://github.com/abdullahselek/Merhaba
you can send data with Bonjour networking
I have two iPad apps, one which downloads data from a server and stores it on the iPad and another one (the main app) which uses the data later.
(It would make sense to combine the two but it's a client requirement)
But I see no way to share the data between the two apps.
I have heard there are ways to do it using:
Custom URL Schemes
Document Support on iPad Devices
UIPasteboard
But I cannot find any thing explaining how to use any of these effectively.
Can anyone point me in the right direction.
Just to clarify:
It is an iPad only app
Both apps will not run at the same time
Basically I need to access the documents or caches folder of one app from another
Using iCloud or any other third part service is not possible
It would be great if I could make the downloader app into a sort of configuration page for the main app (if it is even possible)
So keeping these in mind which one would be the most suitable?
This link at github may be useful... Looks like someone has already made a file manager, using these elements you may be able to do what you are looking for. But as far as I know, your app is extremely sandboxed and does not really interact with other apps/the file system very much at all (Apple is very limiting that way)
EDIT
this post seems to have the explanations of local data sharing methods you were looking for. None of the methods in this post requires any connectivity, just a device and 2 apps :) Good luck!
I have been doing some research before beginning my first iOS app, and I was wondering - what are some advantages and disadvantages of creating a mobile web app and wrapping it in a UIWebView vs. native components and classes?
I've read about OkCupid discussing their issues with the web view and caching.
Can anyone share their thoughts on what might be the most appropriate route?
As a user, I prefer to use an app made natively for the device, rather than web app. I consider it somewhat lame when I download an app from the app store only to discover that it's simply a UIWebView. The only reason (as a developer) that you might consider doing this is because you do not have the resources needed to make a native app, yet you would still like to distribute your web app in the same way as you would a normal, native application.
In other words, if you can, don't make a web app. Using the native iOS frameworks gives you a more rich set of libraries and tools, and generally produces an app that feels more natural and works a lot more seamlessly.
I understand that it's possible to access the iPad Photo library using the UIImagePickerController. The problem with this is that it makes it possible to access only one image at a time. I'm building an app that needs to be able to select multiple images from this library simultaneously (without loading them into memory) to save for further manipulation. This would require obtaining the file paths.
I've read that it's possible to access the Photos file system using the photolibrary.framework. This is a private API though, which would presumably disqualify the app from the App Store.
There are apps in the store that apparently have this capability though. Are they braking Apple's rules or have they found a "legal" way around them?
I've also heard that iOS 4.2 (coming this November) is supposed to make direct access straightforward.
Anyone know of a legal way to access the Photos file system using the current iPad OS?
Thanks,
Paul
There is no API currently available to support that functionality
Have a look at this project on github: https://github.com/elc/ELCImagePickerController
It generally is an ImagePicker that allows to select multiple images at once. Therefore, it needs to read the iOS Photo Library. So looking at the code you should be able to figure out how to do it.