Get Android Hash Key and MD5 Fingerprint

To get android key hash code follow these steps:
  1. Download the openssl for windows
  2. now unzip to c drive
  3. open cmd prompt
  4. type cd C:\Program Files\Java\jdk1.6.0_26\bin
  5. then type only
  6. keytool -export -alias myAlias -keystore C:\Users\your user name\.android\myKeyStore | C:\openssl-0.9.8k_WIN32 \bin\openssl sha1 -binary | C:\openssl-0.9.8k_WIN32\bin\openssl enc -a -e
  7. Done
To get Certificate fingerprint(MD5) code follow these steps:
  1. go to – C:\Program Files\Java\jdk1.6.0_26\bin
  2. inside the bin folder run the jarsigner.exe file
  3. open cmd prompt
  4. type cd C:\Program Files\Java\jdk1.6.0_26\bin
  5. then again type on cmd
  6. keytool -list -keystore “C:/Documents and Settings/your user name/.android/debug.keystore”
  7. it will ask for Keystore password now. The default is “android” type and enter
  8. Done.

Dream not Hope.

I sometimes dream  I had the magic stick to make things happen possible whatever I wish for. I dreamt of so and dreaming of so. I always wished that some supernatural powers be there in my body to make every wish of mine come true.

Dreaming is never a bad thing but hope is. I remember hearing this quote in The Shawshank Redemption by Red as “Let me tell you something my friend. Hope is a dangerous thing. Hope can drive a man insane.”

I sometimes dream that everything will be fine after the blink of my eyes. But my friend every time I find nothing except disappointment. I never get the things I wished for. I know I am not only person to think so. But here I always blame god why only me? Why did you make me this unlucky that I always get things which ain’t in my favour.

I feel so pity on myself sometimes that I don’t find ears to hear me, voices to listen , shoulders to lie on , lap to sleep. I feel so lonely someday. Confined only inside the wall of cement and bricks has been eating me. I don’t remember when did I laugh so carefreely.

I wish things get turn on my side as well . I dreamt,am dreaming and shall be dreaming.

Mount Everest Peak

While I was a kid , I always had this question whenever I heard the news that this many climbers climbed the Mount Everest. The question that always strike me was how would they stand on the peak of the world? Would not they fall as I always imagined it to be like sharp edges. I was always fascinated to hear people climbing the mountains which was continuously again asking me the same question “HOW?” .

Mt. Everest

Mt. Everest

But today I found the  fact that the peak of the Mt. Everest is 7 sq. meter in area. Reading this fact gave nothing more than the smile on my face realizing what had been troubling me these many years to digest. I never tried searching for the facts previously too as I always used to forget this. But today coming to this point of time and realizing the misconception about the peak of the word gives me smile.

Thinking so makes me realize how beautiful were our childhood moments. We get stuck to very small things and when we get the solution for that gives us ultimate happiness like the way I am feeling at the moment writing the blog and sharing things with you.

Have query inside, don’t remember it. Let the time come in such a way that you get the solution accidently  and realize it.

Generating SSH key in linux using terminal

Secure Shell (SSH) is a cryptographic network protocol (Application Layer Protocol)for secure data communication, remote command-line login, remote command execution, and other secure network services between two networked computers. It connects, via a secure channel over an insecure network, a server and a client running SSH server and SSH client programs, respectively.
To check the ssh key already in the system : ls -al ~/.ssh
To generate the new SSH key : ssh-keygen -t rsa -C “your_email@example.com”
Press enter , enter for the all the prompt.
Check connectivity with github : ssh -T git@github.com
Source: wikipedia(Definition)

Difference between ++i and i++

There are lots of questions seen on the forum that what exactly does the ++ placement will to the concept. This is really is good question and if answered will be the best thing for the programmer to understand and implement.

Here is my perception on the subject provided.

++I is the pre-incremental value for I and I++ is the post-incremental value for I.


 ++i will increment the value of i, and then return the incremented value.

For instance: 
i = 1;
j = ++i;
(i is 2, j is 2)


 i++ will increment the value of i, but return the original value that i held before being incremented.

For instance: 

i = 1;
j = i++;
(i is 2, j is 1)


 I hope this will help you to understand the basics of the operator overloading feature for + values.

Happy coding! 🙂

Canvas.clippath Support For ICS

Problem statement :
Crash during cropping the image from existed gallery or from newly taken picture in ICS

Reason of the problem :

In ICS, hardware acceleration was turned on by default.
        Until 4.0, the default was that hardware acceleration was off. Hardware acceleration does not support clipPath.

Solution:
clipPath is only supported with hardware acceleration turned off.

So for that we need to add following permission in our android manifest between <application /> tag.

<application>
...........................
...........................
android:hardwareAccelerated="false"
...........................
</application>

Studying this link below may also be helpful about hardware acceleration for android 3.0 and above:
Android 3.0 Hardware Acceleration

Log : methods and types

According to the  Android Developers , Log is a logging class that you can utilize in your code to print out messages to the LogCat.

To write log statements, we use the android.util.Log class

There are different Log methods. These are listed below:

  • Log.v(); // V=Verbose
  • Log.d(); // D=Debug
  • Log.i(); // I=Info
  • Log.w(); // W=Warning
  • Log.e(); // E=Error

Each method having individual functionality, they are described as:

Log.d() – Send a DEBUG log message and log the exception.

Log.e() – Send an ERROR log message. Use this tag in places like inside a catch statement.

Log.i() – Use this to post useful information to the log. For example: that you have successfully connected to a server. Basically use it to report successes.

Log.w() – Anything that happens that is unusual or suspicious, but not necessarily an error.

Log.v() – Printouts of state at different intervals, or upon any events occurring which my component processes. Also possibly very detailed printouts of the payloads of messages/events that my component receives or sends.

—————————————————————————————————————————–

The priority is one of the following character values, ordered from lowest to highest priority:

  • V — Verbose (lowest priority)
  • D — Debug
  • I — Info
  • W — Warning
  • E — Error
  • F — Fatal
  • S — Silent (highest priority, on which nothing is ever printed)