RSS

Category Archives: General

General

Kotlin for Android (I) Why I love Kotlin


If there is only one sentence to describe Kotlin, it would be: “Kotlin is great”!

You will not appreciate the beauty of it if you do not suffer from the repetitive, boilerplate coding in java. Let’s see an example first.

Consider you have two classes, as shown below, they do the same thing, interchangeable, exactly the same in terms of functionality, which one do you choose? Left or right one?

  image  image

The left one is java implementation, and the right, Kotlin.

This is a real example that I encountered in developing an Android App. The App tries to get the new questions on StackOverflow site: Open the link below in your browser to see how you can get the json from StackExchange API:

https://api.stackexchange.com/2.2/questions?site=stackoverflow&key=JE1srJAZi8)AoOEHcHUWdg((

You will be presented a similar json as below:

stackoverflow-questions

In order to display a list of such questions in Android views, I need to deserialize this json string to a POJO (Plain Old Java Object) representation. To avoid hands dirty,  we can go to http://pojo.sodhanalibrary.com/ and paste the json string to get the POJO class:

Read the rest of this entry »

Advertisements
 
Leave a comment

Posted by on June 27, 2016 in General

 

Tags: , , , , , ,

Reverse Engineering of Android Apps


It is not uncommon that you find an amazing Android app on Google Play store and wish to know how the app is designed and developed.

You need then reverse engineer the Android app (from an APK file) and convert it to a project that you can understand and edit.

I found below three tools especially useful for such purposes.

The 1st one is APKTool. You can use it to “decode” the Android resources easily.

apktool d your.apk

 

 

 

 

 

 

 

Read the rest of this entry »

 
Leave a comment

Posted by on December 21, 2015 in General

 

Windows Live Essential offline installer


You can directly download the Windows Live Essential Offline Downloader from this official link!
Blog or bookmark this and happy installing!

 
Leave a comment

Posted by on August 16, 2015 in General, Windows

 

Tags: , , , , , , , , ,

Windows 10: Genymotion virtualization engine not found


If you encounter the same situation like me, this post is just for you:

We installed Genymotion in Window 7, 8 or Window 8.1, it worked well. But after upgrading the OS, it stopped working and complained:

“genymotion virtualization engine not found”

Genymotion

Read the rest of this entry »

 
Comments Off on Windows 10: Genymotion virtualization engine not found

Posted by on August 3, 2015 in Windows

 

Tags: , , , , , , ,

Reliable Delivery Pub/Sub Message Queues with Redis


Remember to Breathe

Redis-title

Redis is a high performance key-value datastore that differs from other key-value solutions in the way it handles values. Instead of just storing values as simple strings, it recognizes multiple specific data types such as Lists, Sets, Hashes (maps), Strings or Numbers. Each data type has its own set of features to manipulate the data it contains in an atomic manner, making it an ideal tool for highly distributed system where concurrency is a potential issue.

Combining those features in creative ways allows for novel ways of doing “traditional” things differently. One particular combination has recently allowed us to implement a moderately (read: good enough) reliable message delivery mechanism for multiple consumers consuming messages at their own pace.

The solution has advantages and some caveats, but if your problem allows you to live with the possible drawbacks, it’s a nice lightweight solution to a problem that is usually answered some…

View original post 1,276 more words

 
Leave a comment

Posted by on July 15, 2015 in General

 

Install Vmware tools disabled


In Vmware, if you find the “VM > Install Vmware Tools … ” menu disabled, you can easily enabled it by:

  • Right click a VM, and click Settings
  • Selecting Floppy in the left column
  • In the right column, Select Use physical drive option
  • Select Auto detect option
  • Restart. That is it!

image

 
Leave a comment

Posted by on June 21, 2015 in General, Windows

 

Tags: , , , , ,

Windows cannot read product key from unattend answer file


When trying the latest Windows 10 ISO on Vmware, the below annoying error pops again and again:

Windows cannot read <productkey> from unattend answer file

To solve this, in Vmware settings, right click the VM, and disable/uncheck the floppy disk “Connect at power on” option.

image

Restart, that is it!

image image

 
1 Comment

Posted by on June 20, 2015 in Windows

 

Tags: , , , ,