1. Download our Official Android App: Forums for Android!

Apps TAG Constant

Discussion in 'Android Development' started by danny22, May 26, 2010.

  1. danny22

    danny22 Lurker
    Thread Starter
    Rank:
    None
    Points:
    5
    Posts:
    1
    Joined:
    May 26, 2010

    May 26, 2010
    1
    0
    5
    What is the TAG constant used for?

    ie: private static final String TAB = "........"
     

    Advertisement

  2. IanGClifton

    IanGClifton Well-Known Member
    Rank:
    None
    Points:
    58
    Posts:
    111
    Joined:
    Feb 7, 2010

    TAG is usually used to refer to your activity when logging (TAG = "com.mycompany.myapp.myactivity")

    Log.d(TAG, "Log something here");

    It allows you to easily identify where a log message originates.
     

Share This Page

Loading...