title: How can I get programatically any single Log generated by my App?
body: <p>Any Android App produces Logs in the LogCat, even those not generated by developer's source code via <code>Log.d</code>, <code>Log.i</code>, <code>Log.w</code> and <code>Log.e</code> etc. etc. etc.. Perhaps Google Developers has some &quot;automagic&quot; thing for this, I don't know about that...</p>
  <p>The point is I remember, years ago, <strong>I could somehow extend the class <code>Application</code></strong>, override one or several of it's methods, and then:</p>
  <ul>
  <li>Add my own code to process any single <code>Log</code> object generated by my
  App in the LogCat</li>
  <li><strong>Do whatever I wanted with them</strong> (getting the label and the description strings, and then send them via mail, Slack etc., basically)</li>
  <li>And then, calling <code>super</code> on that method and let the system do with that Log whatever <code>Application</code> by default does with it...</li>
  </ul>
  <p><strong>or something like that</strong>... if I recall correctly, I could do this with any log in my app's namespace. Or maybe it was just the crash handler? I can't remember...</p>
  <p>It's been so long since I accomplished that (several years already!), so I don't remember how could I do that anymore... I search the internet like crazy trying to recall, but I am struggling to find it again... :-S</p>
  <pre><code>// ...public?? oO
  [¿¿??] class MyApp extends Application [...] {
  // [...]
  
      @Override
      public void whateverMethodItWasIDontRemember(params) {
          // My coding stuff for the error reports
          /* magic :D */
          sendTheLogsMyWay();
  
          // I bet this is important
          super.whateverMethodItWasIDontRemember(params);
      }
  
      // [...]
  }
  </code></pre>
  <hr />
  <p>I am about to launch the first Beta version of a new app, so I want beta testers to have a reliable way to send me LogCat's feed if anything has to be reported due to crashes, unexpected behaviour etc.</p>
  <hr />
  <p>I mean, it would be ridiculous having to fill with <code>CustomLog</code>s every inch of source code for the beta version, when, <strong>in most cases, default logs are more than enough</strong> to see why it crashed (errors), or what optimization problems (usually warnings) might the Beta Tester have... not to mention that, if I forget to monitor something this way, the ridiculously big effort to log every single line of my code would be useless... oO</p>
  <pre><code>// -__- Mmm... perhaps extending Log itself
  //        would be more elegant... 
  import android.util.Log
  
  public final class CustomLog {
      public static void d(String label, String msg) {
          // AKA My code to handle it
          packItForNextErrorReport(label, msg);
  
          Log.d(label, msg);
      }
  
      /*
        * ... and so on with Log.i, w and e.
        *    ...I think you get the idea
        */
  }
  </code></pre>