[help] How to integrate it with Android Studio #6
Comments
At the moment, you will need to clone the squidb repository in order to use it with your projects. This is a temporary solution; we're working on deploying pre-built artifacts so that this step won't be required in the future. For now though, once squidb is cloned you can add it to your Android Studio workspace by declaring it in your settings.gradle:
Once it's in your settings.gradle file it should show up in studio, and you can then add it as a dependency in your build.gradle using this guide. As far as Jackson goes--I don't think the squidb-jackson plugin is quite what you want for your use case. It's really just a sample project that demonstrates how you can write plugins for the squidb code generator to serialize non-primitive data types to a single column (see this wiki page] for more details). However, there might be an opportunity to write a new plugin that would facilitate binding with Retrofit. What exactly did you have in mind? |
I've updated this page with instructions for cloning and adding to |
@sbosley re pre-built artifacts, would probably also want to create a fork of apt-utils and deploy it as a separate artifact, instead of the current apt-utils.jar file checked into source control. |
@tomxor yep we'll do the same for apt-utils, thanks! |
👍 |
@sbosley Thanks for helping, I am able to setup the Project. I am able to generate a Table and tried to save a record and was successful. I have another question. without setting facebook id as primary key I cannot update the record. It keeps on inserting the same record again and again. this is just one of the usecases. |
@RiinaV we are considering making this enhancement in the future, but for right now we only support _id as the primary key. You can use the facebook id column and make it unique, and use User user = ...;
// make modifications to user
databaseDao.update(User.FACEBOOK_ID.eq(id), user); We also support fetching a record by criterion, so you can lookup a User by facebook id, e.g.: User user = databaseDao.fetch(User.class, User.FACEBOOK_ID.eq(id), User.PROPERTIES); |
When you plan to add gradle maven? |
Soon! We'll post back to this issue once we've deployed pre-built artifacts with instructions on how to use squidb without building from source. |
Good news everyone! We now have pre-built binaries deployed so you don't have to build from source anymore. Updated instructions for including SquiDB as a dependency can be found at this wiki page. |
thanks, excellently |
I am unable to find any guide to add the library to AndroidStudio.
Is there a jar or aar file that can be directly added?
Also, please let us know how to integrate Jackson and squidb.
I want to use Retrofit for REST and want to bind all three together.
The text was updated successfully, but these errors were encountered: