In my windows mobile application i would like to deserialize and serialize JSON objects.
Have searched but could not find any.Could anyone please let me know if there is any API support or how can i do it if manually needs to be done.
Please share your valuable suggestions.
Thanks in advance :)
I'd suggest https://github.com/lloyd/yajl: it has windows build instructions and uses only ANSI C. I've in the past built it for Windows Mobile 6 projects, and it works well. The examples show how you can parse from a byte array, and it also support serializing a structure to a character array.
Related
I would like to know if it is possible to run an Elasticsearch server on a mobile device (android / iphone / ios) and if so, how I should go about doing it.
In my case, the reason for doing it is to have an offline database on the device that is easily searchable (with all elasticsearch advanced functions)
Optionally, I would maybe also use elasticsearch's cluster/replication capacities to keep the offline data on the device synced with a server.
Well, maybe (at least on Android, for iPhone the answer is no). Others have discussed it not certain that anyone has succeeded. The Android Dalvik is a JVM, just missing some things that are typically not required for mobile apps. In theory you should be able to try to compile ES and run it on Android. However, you are likely to run into issues with missing libraries and apis that ES requires, so it all depends on how comfortable you are diving in to ES source code to resolve them.
This previous discussion might be of help, you might try to reach out to those on the thread to see if anyone succeeded:
http://elasticsearch-users.115913.n3.nabble.com/ElasticSearch-HTTP-Server-on-Android-td4056423.html
I'm also looking for a fulltext search engine for Offline First mobile apps.
I haven't developped anything yet, but I think the easiest solution can be using the Clucene Library (a C++ version of Lucene) as fulltext search engine instead of ElasticSearch (which is based on Lucene - Java).
In fact, we don't need all the features of Elasticsearch for the mobile, such as webserver, restfull api, etc...
You can find some work around on Google:
https://github.com/asheeshv/CLucene-iOS-Android-Win8
https://github.com/saturnman/clucene-iOS
https://github.com/hurongliang/clucene-ios-example
Still looking for a Cordova/Phonegap solution...
Hope it can help.
Edit:
I have found this tool that provide Offline First capabilities in Javascript.
It will work with Cordova/Phone Gap and maybe with ReactNative:
http://elasticlunr.com/
No, you can't , at least for now there is no official build that can run in mobile devices.
Can you not use regular ajax calls in your app to connect to elasticsearch? I'm not sure if it would be the best way but that's how I have it going.
There is the ElasticSearch4Android project that seems to try to do just that, but I am not sure it is not dead.
It has total 6 commits 3 years ago.
Maybe we can put one shoulder there, and help build it.
I will contact the author to see what is the state of the project.
I'm woking now on my senior project, it about identify the places through pictures on windows phone 8 platform.
Any libraries or algorithms could help me ?
if the data is embedded in the image: see How to get the EXIF data from a file using C#
if not: Then perhaps a google api may help, I don't know Google's APIs but here is an article which may give you some idea for what to search for: http://www.labnol.org/internet/find-picture-location/21273/
I would love to have a fix metadata function for my music player, but as I know there is no library that could do such. However I found that some C# application could accomplish this.
Example
I need some advice and probably a good sources to get start this projects. Any help will be appreciated.
Thanks.
Edit: I also found this, this is very similar to what I want to do, but there is so few sources.
http://wmpoweruser.com/finally-mp3-tag-editor-for-windows-mobile-available/
Currently, the Windows Phone Platform doesn't provide a way to modify song data for songs on the device. There's no way to access the file system from a restricted Silverlight application, and the current XNA Media classes only provide read-only access to song data.
You need direct access to the file via an IsolatedStorage because there is no built-in support to change id3v2 tags.
Then you can use these libraries:
http://sourceforge.net/projects/audiogenie/
http://github.com/mono/taglib-sharp
I searched on google for how to do data(xml) and image caching on windows phone 7, but did not find any luck. Please direct me to the right place from where I can read about caching mechanism in wp7. (FYI : I use HttpWebRequest to make request to the server and receive response as xml).
Thanks in advance!
You might want to check the WP7Contrib - it provides pattern and implementations for caching transient data on WP7. It might give you some ideas on how you can achieve what you want.
I am a contributor to this OSS project and this is not a case of self publication honest :)
I know this is an old post, but I found this great class which others might find useful to know about:
Kawagoe Toolkit - PersistentImageCache
you could use the Isolated Storage to cache both your data & images.
Essentially, you could write key-value pairs or entire files (using byte stream) into the sand-boxed Isolated Storage.
See if the two links below help:
31 Days of Windows Phone | Day #15: Isolated Storage
Silverlight 2 - Saving and Retrieving Images from IsolatedStorage
There is also a really great auto request and caching framework that came out not too long ago. Its called AgFx and its available on codeplex and nuget I believe. I'm on my phone now or else I'd provide links.
Anyways, I've heard AgFx rocks, but personally i haven't worked with enough to personally offer comments. Hope that helps.
For caching images you can use JetImageLoader, I created it for application, where we need to load, cache and show big amount of logos, icons and so on.
It can be used as binding converter, so you should not even change your code! Just update your XAMLs!
Please, check out samples in repository, you'll love it ;)
Features:
Caching on disk
Caching in memory
Fully asynchronous
Available as binding converter or programmatically from your code
Fully open source, fork and improve it!
Here is the example:
<Image Source="{Binding ImageUrl, Converter={StaticResource MyAppJetImageLoaderConverter}}"/>
P.S. I am sorry, that I copying my answer from another questions, but image caching on windows phone is huge problem and I want to share my solution, so everybody can use it and improve for developers community
Does anyone know how to access SkyDrive programmatically from Windows Phone 7? What API do I use? I need to upload files from the Phone to SkyDrive and vice versa.
Some code samples would be great. :-)
You can now officially integrate parts of SkyDrive with Windows Phone 7 applications.
Details outlined here.
There is a new Live SDK available from Microsoft which I think can do this. It's also in a very early alpha or beta state:
http://msdn.microsoft.com/en-us/library/bb264574.aspx
I have developed a sample based on SkyPad (Developer Preview). Please install the Windows Live Developer preview SDK.
The sample allows to save a file to SkyDrive and dowload it again after saving.
Here the link:
http://blog.mecum.biz/2011/10/windows-phone-7-mango-skydrive-sample/
You can use the Live SDK to integrate SkyDrive into your Windows Phone applications. Please see our code samples on GitHub.
Not an answer, but there's hope that an answer is on the way:
However, when Mike Torres was asked about features such as better usability, third-party API support, Windows Live Mesh integration, and expandable storage, he acknowledged that these are "top asks" for SkyDrive and said that they are currently "hard at work on SkyDrive as we speak"
Source
Your requirements sound pretty much like mine - you just want to use skydrive as a basic cloud filesystem.
I thought Matt's suggestion was an outstanding idea. I obtained the library and set out to port it, but unfortunately the codebase is huge and elaborate and absolutely riddled with the [Serializable] attribute which is not compatible with WP7. It also makes extensive use of several pieces of framework not available in WP7x, including X509Chain and Authorization.
SkyDriveApi is not even compatible with VS2010 - an attempted conversion produced a big mess so I just tried it out in VS2008.
We could always write one. This looks like a fair bit of work so I invite you to collaborate.
Well, it's feature complete and working a treat. I'd like to thank people for all the support and assistance I received reverse engineering the protocol using Fiddler, and coding, testing and debugging the prototype into production ready code. I'd like to, but nobody contributed a damn thing. Good luck writing your own.
SkyDrive doesn't have an official API but here are some unofficial ones. I'd start by looking at http://skydriveapiclient.codeplex.com/.
It doesn't claim support for WP7 but you may be able to port it.