// Path: app/src/main/java/io/gresse/hugo/anecdote/Configuration.java
// public class Configuration {
// 
//     public static final boolean DEBUG                     = BuildConfig.DEBUG;
//     public static final String  API_VERSION               = "2";
//     public static final String  API_URL                   = "https://anecdote-api.firebaseio.com/v" + API_VERSION + "/websites.json";
//     public static final String  DOWNLOAD_FOLDER           = "Anecdote";
//     public static final int     IMAGE_SAVE_TOAST_DURATION = 5000;
//     public static final String  DONATION_LINK             = "https://paypal.me/HugoGresse/5";
// 
// }
// 
// Path: app/src/main/java/io/gresse/hugo/anecdote/anecdote/social/CopyAnecdoteEvent.java
// public class CopyAnecdoteEvent extends SocialEvent {
// 
//     public static final String TYPE_ANECDOTE = "Anecdote";
//     public static final String TYPE_MEDIA    = "Media";
// 
//     public final String type;
//     public final String shareString;
// 
//     public CopyAnecdoteEvent(String websiteName, Anecdote anecdote, String type, String shareString) {
//         super(websiteName, anecdote);
//         this.type = type;
//         this.shareString = shareString;
//     }
// }


import android.app.Activity;
import android.content.Context;
import android.support.annotation.Nullable;
import android.support.v4.app.Fragment;
import android.text.TextUtils;
import io.gresse.hugo.anecdote.Configuration;
import io.gresse.hugo.anecdote.anecdote.social.CopyAnecdoteEvent;
package io.gresse.hugo.anecdote.tracking;



/**
 * Main entry point for tracking application activity. Sub flavors are responsable to implement
 * {@link EventSenderInterface} with a class named "EventSender" and send the proper information to each services they
 * manage.
 * <p/>
 * Created by Hugo Gresse on 25/04/16.
 */
public class EventTracker {

    public static final String CONTENT_TYPE_ANECDOTE = "Anecdote";
    public static final String CONTENT_TYPE_APP = "App";
    public static final String TRACKING_WEBSITE_NAME = "Website name";

    private static EventSenderInterface sEvent;

    public EventTracker(Context context) {
        if (!isEventEnable()) return;

        sEvent = new EventSender(context);
    }

    /**
     * Return true if event reporting is enable, checking the BuildConfig
     *
     * @return true if enable, false otherweise
     */
    public static boolean isEventEnable() {
// Path: app/src/main/java/io/gresse/hugo/anecdote/Configuration.java
// public class Configuration {
// 
//     public static final boolean DEBUG                     = BuildConfig.DEBUG;
//     public static final String  API_VERSION               = "2";
//     public static final String  API_URL                   = "https://anecdote-api.firebaseio.com/v" + API_VERSION + "/websites.json";
//     public static final String  DOWNLOAD_FOLDER           = "Anecdote";
//     public static final int     IMAGE_SAVE_TOAST_DURATION = 5000;
//     public static final String  DONATION_LINK             = "https://paypal.me/HugoGresse/5";
// 
// }
// 
// Path: app/src/main/java/io/gresse/hugo/anecdote/anecdote/social/CopyAnecdoteEvent.java
// public class CopyAnecdoteEvent extends SocialEvent {
// 
//     public static final String TYPE_ANECDOTE = "Anecdote";
//     public static final String TYPE_MEDIA    = "Media";
// 
//     public final String type;
//     public final String shareString;
// 
//     public CopyAnecdoteEvent(String websiteName, Anecdote anecdote, String type, String shareString) {
//         super(websiteName, anecdote);
//         this.type = type;
//         this.shareString = shareString;
//     }
// }


// Path: app/src/main/java/io/gresse/hugo/anecdote/tracking/EventTracker.java
import android.app.Activity;
import android.content.Context;
import android.support.annotation.Nullable;
import android.support.v4.app.Fragment;
import android.text.TextUtils;
import io.gresse.hugo.anecdote.Configuration;
import io.gresse.hugo.anecdote.anecdote.social.CopyAnecdoteEvent;

package io.gresse.hugo.anecdote.tracking;



/**
 * Main entry point for tracking application activity. Sub flavors are responsable to implement
 * {@link EventSenderInterface} with a class named "EventSender" and send the proper information to each services they
 * manage.
 * <p/>
 * Created by Hugo Gresse on 25/04/16.
 */
public class EventTracker {

    public static final String CONTENT_TYPE_ANECDOTE = "Anecdote";
    public static final String CONTENT_TYPE_APP = "App";
    public static final String TRACKING_WEBSITE_NAME = "Website name";

    private static EventSenderInterface sEvent;

    public EventTracker(Context context) {
        if (!isEventEnable()) return;

        sEvent = new EventSender(context);
    }

    /**
     * Return true if event reporting is enable, checking the BuildConfig
     *
     * @return true if enable, false otherweise
     */
    public static boolean isEventEnable() {
        return !Configuration.DEBUG;