The comprehensive feed for all Computer Science enthusiasts.

 Some of the Live Templates of Android Studio for speed coding are collected here. These are meant for Quick reference. newInstance  - Gener...

Live Template Shortcodes - Android Studio

 Some of the Live Templates of Android Studio for speed coding are collected here.

These are meant for Quick reference.




  • newInstance - Generates the static newInstance function inside a Fragment

  • Toast - Generates Toast.makeText(context, "", Toast.LENGTH_SHORT).show();

  • fbc - findViewById with cast

  • const - Define a android style int constant

  • logd - Generates Log.d(TAG, "");

  • logm - Log current method name and its arguments.

  • logr - Log result of the current method

  • logt - static logtaf with current classname

  • psf - public static final

  • sout - Prints a string to System.out

  • soutm - Prints current class and method names to System.out

  • soutp - Prints method parameter names and values to System.out

  • visible - Set view visibility to VISIBLE

  • gone - Set view visibility to GONE

  • noInstance - private empty constructor to prohibit instance creation

We can create more as per our use cases.

List of all Live Templates here!!




Icons made by Freepik from www.flaticon.com



0 coment�rios: