RxMagneto


Source link: https://github.com/aritraroy/RxMagneto

RxMagneto

A fast, light-weight and powerful Play Store information fetcher for Android.

Specs

This library allows you to fetch various live information from Play Store of your app or any other app of your choice. With just a few lines of code, you can get access to a lot of useful app data fetched fresh from the Play Store.

It has been named after the famous anti-villain from X-Men. This library has been completely written using RxJava giving you powerful controls to make the most use of it.

Download

This library is available in jCenter which is the default Maven repository used in Android Studio.

Gradle

dependencies {

  // other dependencies here

 compile 'com.andrognito.rxmagneto:rxmagneto:2.0.0' 
}

Maven

<dependency>
<groupId>com.andrognito.rxmagneto</groupId>
<artifactId>rxmagneto</artifactId>
<version>2.0.0</version>
<type>pom</type> </dependency>

Migrating to Version 2

RxMagneto 2 brings some breaking changes from version 1. The entire library is re-written using RxJava 2. All the Observables are now changed into Singles, so there will be some re-work for you. You also do NOT need to perform these operations in the background thread as it is automatically done for you.

The core functionality of the library remains the same. Every feature in the new version of this library works in the same way and returns the same result as the previous version.

Spread Some ❤?

Use Cases

There are several use cases of this library. Here are some common examples for you to get started, but you can always be creative and make the most use of it.

App Updates

This is a common problem for many developers wanting to check if their users are using the latest version of the app available on Play Store or not. With RxMagneto, you can get it done with just a single line of code and zero hassle.

Recent Changelog

You might want to show your users the latest changelog when they update the app. RxMagneto can help you fetch the most recent changelog directly from Play Store with just one line of code.

User Ratings

Many developers prompt their users to rate the app after a certain period of time. You can also show your current rating and ratings count directly from Play Store to encourage these users to rate your app even more.

Setup

Once you have downloaded the library in your project, setting up RxMagneto is super-easy.

RxMagneto rxMagneto = RxMagneto.getInstance();
 rxMagneto.initialize(this);

The initialize method takes a Context object. It can either be an Application context or Activity context.

Quick Example

Here is a quick example for you to get started right away in less than a minute.

RxMagneto rxMagneto = RxMagneto.getInstance();
 rxMagneto.initialize(this);
  Single<String> version = rxMagneto.grabVersion(packageName);
 version.observeOn(AndroidSchedulers.mainThread())

.subscribe(s -> {

Log.d("RxMagneto", "Version: " + s);

 
}
, throwable -> {

  Log.d("RxMagneto", "Error");

 
}
);

All Features

Here is a list of all the featues offered by RxMagneto. I will be actively taking more feature requests and expand the library over time.

Get Play Store URL

Gets the Play Store URL of the specified package. You can make this call in the main thread of the application.

Single<String> urlSingle = rxMagneto.grabUrl(packageName);

Get Verified Play Store URL

Gets the verified Play Store URL of the specified package. It automatically performs the operation in a background thread, so that you do NOT need to explicitly do it.

Single<String> urlSingle = rxMagneto.grabVerifiedUrl(packageName);

Get Version

Gets the latest version of the specified package from Play Store. It automatically performs the operation in a background thread, so that you do NOT need to explicitly do it.

Single<String> versionSingle = rxMagneto.grabVersion(packageName);

Check If Update Is Available

Check if an update is available for the specified package from Play Store. It automatically performs the operation in a background thread, so that you do NOT need to explicitly do it.

Single<Boolean> updateAvailableSingle = rxMagneto.isUpgradeAvailable(packageName);

Get Downloads

Gets the no. of downloads of the specified package from Play Store. It automatically performs the operation in a background thread, so that you do NOT need to explicitly do it.

Single<String> downloadsSingle = rxMagneto.grabDownloads(packageName);

Get Last Published Date

Gets the last published date of the specified package from Play Store. It automatically performs the operation in a background thread, so that you do NOT need to explicitly do it.

Single<String> publishedDateSingle = rxMagneto.grabPublishedDate(packageName);

Get OS Requirements

Gets the OS requirements of the specified package from Play Store. It automatically performs the operation in a background thread, so that you do NOT need to explicitly do it.

Single<String> osRequirementsSingle = rxMagneto.grabOsRequirements(packageName);

Get Content Rating

Gets the content rating of the specified package from Play Store. It automatically performs the operation in a background thread, so that you do NOT need to explicitly do it.

Single<String> contentRatingSingle = rxMagneto.grabContentRating(packageName);

Get App Rating

Gets the app rating of the specified package from Play Store. It automatically performs the operation in a background thread, so that you do NOT need to explicitly do it.

Single<String> appRatingSingle = rxMagneto.grabAppRating(packageName);

Get App Ratings Count

Gets the no. of app ratings of the specified package from Play Store. It automatically performs the operation in a background thread, so that you do NOT need to explicitly do it.

Single<String> appRatingsCountSingle = rxMagneto.grabAppRatingsCount(packageName);

Get Recent Changelog (as Array)

Gets the recent changelog (as array) of the specified package from Play Store. It automatically performs the operation in a background thread, so that you do NOT need to explicitly do it.

Single<ArrayList<String>> changelogSingle = rxMagneto.grabPlayStoreRecentChangelogArray(packageName);

Get Recent Changelog (as String)

Gets the recent changelog (as string) of the specified package from Play Store. It automatically performs the operation in a background thread, so that you do NOT need to explicitly do it.

Single<String> changelogSingle = rxMagneto.grabPlayStoreRecentChangelog(packageName);

Contribution

This library is quite powerful and offers a lot of features. But I will love to have more feature requests from you to expand it further. If you find a bug or would like to improve any aspect of it, feel free to contribute with pull requests.

About The Author

Aritra Roy

Android & Backend Developer. Blogger. Designer. Fitness Enthusiast.

License

Copyright 2017 aritraroy  Licensed under the Apache License, Version 2.0 (the "License");
 you may not use this file except in compliance with the License. You may obtain a copy of the License at
  http://www.apache.org/licenses/LICENSE-2.0  Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. 

Resources

Android library project for selecting/capturing multiple images from the device.

Features:

  • Allows taking pictures from camera as well.
  • Multi-selection of images from gallery.
  • Ability to select/capture images upto a specified limit.
  • Preview thumbnails of selected images.
  • No dependency.

It's Gradle Plug-in for Android Play-store Publisher API.

A type-safe interface of image processing algorithms.

Alexei has some predefined image processing calculus that are accessible from the class ImageProcessingThing:

  • Dominant Color
  • Color Palette
  • Average RGB

Blur Navigation Drawer like Etsy app.

Just replace your default toggle with this awesome blurred toggle effect by adding 4 letters!

Bubble Notification with an explosion animation.

This plugin adds support for writing Android applications using the Groovy language.

Plugin has been successfully tested with Android Studio. It is recommended, for performance, memory and battery life, that you use @CompileStatic wherever possible.

Topics


2D Engines   3D Engines   9-Patch   Action Bars   Activities   ADB   Advertisements   Analytics   Animations   ANR   AOP   API   APK   APT   Architecture   Audio   Autocomplete   Background Processing   Backward Compatibility   Badges   Bar Codes   Benchmarking   Bitmaps   Bluetooth   Blur Effects   Bread Crumbs   BRMS   Browser Extensions   Build Systems   Bundles   Buttons   Caching   Camera   Canvas   Cards   Carousels   Changelog   Checkboxes   Cloud Storages   Color Analysis   Color Pickers   Colors   Comet/Push   Compass Sensors   Conferences   Content Providers   Continuous Integration   Crash Reports   Credit Cards   Credits   CSV   Curl/Flip   Data Binding   Data Generators   Data Structures   Database   Database Browsers   Date &   Debugging   Decompilers   Deep Links   Dependency Injections   Design   Design Patterns   Dex   Dialogs   Distributed Computing   Distribution Platforms   Download Managers   Drawables   Emoji   Emulators   EPUB   Equalizers &   Event Buses   Exception Handling   Face Recognition   Feedback &   File System   File/Directory   Fingerprint   Floating Action   Fonts   Forms   Fragments   FRP   FSM   Functional Programming   Gamepads   Games   Geocaching   Gestures   GIF   Glow Pad   Gradle Plugins   Graphics   Grid Views   Highlighting   HTML   HTTP Mocking   Icons   IDE   IDE Plugins   Image Croppers   Image Loaders   Image Pickers   Image Processing   Image Views   Instrumentation   Intents   Job Schedulers   JSON   Keyboard   Kotlin   Layouts   Library Demos   List View   List Views   Localization   Location   Lock Patterns   Logcat   Logging   Mails   Maps   Markdown   Mathematics   Maven Plugins   MBaaS   Media   Menus   Messaging   MIME   Mobile Web   Native Image   Navigation   NDK   Networking   NFC   NoSQL   Number Pickers   OAuth   Object Mocking   OCR Engines   OpenGL   ORM   Other Pickers   Parallax List   Parcelables   Particle Systems   Password Inputs   PDF   Permissions   Physics Engines   Platforms   Plugin Frameworks   Preferences   Progress Indicators   ProGuard   Properties   Protocol Buffer   Pull To   Purchases   Push/Pull   QR Codes   Quick Return   Radio Buttons   Range Bars   Ratings   Recycler Views   Resources   REST   Ripple Effects   RSS   Screenshots   Scripting   Scroll Views   SDK   Search Inputs   Security   Sensors   Services   Showcase Views   Signatures   Sliding Panels   Snackbars   SOAP   Social Networks   Spannable   Spinners   Splash Screens   SSH   Static Analysis   Status Bars   Styling   SVG   System   Tags   Task Managers   TDD &   Template Engines   Testing   Testing Tools   Text Formatting   Text Views   Text Watchers   Text-to   Toasts   Toolkits For   Tools   Tooltips   Trainings   TV   Twitter   Updaters   USB   User Stories   Utils   Validation   Video   View Adapters   View Pagers   Views   Watch Face   Wearable Data   Wearables   Weather   Web Tools   Web Views   WebRTC   WebSockets   Wheel Widgets   Wi-Fi   Widgets   Windows   Wizards   XML   XMPP   YAML   ZIP Codes