// Path: provider/src/main/java/com/raygun/raygun4android/logging/RaygunLogger.java
// public class RaygunLogger {
// 
//     public static void d(String string) {
//         if (string != null) {
//             Timber.tag(RaygunSettings.LOGGING_TAG).d(string);
//         }
//     }
// 
//     public static void i(String string) {
//         if (string != null) {
//             Timber.tag(RaygunSettings.LOGGING_TAG).i(string);
//         }
//     }
// 
//     public static void w(String string) {
//         if (string != null) {
//             Timber.tag(RaygunSettings.LOGGING_TAG).w(string);
//         }
//     }
// 
//     public static void e(String string) {
//         if (string != null) {
//             Timber.tag(RaygunSettings.LOGGING_TAG).e(string);
//         }
//     }
// 
//     public static void v(String string) {
//         if (string != null) {
//             Timber.tag(RaygunSettings.LOGGING_TAG).v(string);
//         }
//     }
// 
//     public static void responseCode(int responseCode) {
//         switch (responseCode) {
//             case RaygunSettings.RESPONSE_CODE_ACCEPTED:
//                 RaygunLogger.d("Request succeeded");
//                 break;
//             case RaygunSettings.RESPONSE_CODE_BAD_MESSAGE:
//                 RaygunLogger.e("Bad message - could not parse the provided JSON. Check all fields are present, especially both occurredOn (ISO 8601 DateTime) and details { } at the top level");
//                 break;
//             case RaygunSettings.RESPONSE_CODE_INVALID_API_KEY:
//                 RaygunLogger.e("Invalid API Key - The value specified in the header X-ApiKey did not match with an application in Raygun");
//                 break;
//             case RaygunSettings.RESPONSE_CODE_LARGE_PAYLOAD:
//                 RaygunLogger.e("Request entity too large - The maximum size of a JSON payload is 128KB");
//                 break;
//             case RaygunSettings.RESPONSE_CODE_RATE_LIMITED:
//                 RaygunLogger.e("Too Many Requests - Plan limit exceeded for month or plan expired");
//                 break;
//             default:
//                 RaygunLogger.d("Response status code: " + responseCode);
// 
//         }
//     }
// 
// }
// 
// Path: provider/src/debug/java/com/raygun/raygun4android/logging/TimberRaygunLoggerImplementation.java
// public class TimberRaygunLoggerImplementation implements TimberRaygunLogger {
// 
//     public static void init() {
//         if (Timber.treeCount() == 0) {
//             Timber.plant(new Timber.DebugTree());
//         }
//     }
// }


import android.support.v4.app.JobIntentService;
import com.raygun.raygun4android.logging.RaygunLogger;
import com.raygun.raygun4android.logging.TimberRaygunLoggerImplementation;
package com.raygun.raygun4android.services;



/**
 * A JobIntentService that can validate Raygun API keys
 */
public abstract class RaygunPostService extends JobIntentService {
    /**
     * Validation to check if an API key has been supplied to the service
     *
     * @param apiKey      The API key of the app to deliver to
     * @return true or false
     */
    static Boolean validateApiKey(String apiKey) {
        if (apiKey.length() == 0) {
// Path: provider/src/main/java/com/raygun/raygun4android/logging/RaygunLogger.java
// public class RaygunLogger {
// 
//     public static void d(String string) {
//         if (string != null) {
//             Timber.tag(RaygunSettings.LOGGING_TAG).d(string);
//         }
//     }
// 
//     public static void i(String string) {
//         if (string != null) {
//             Timber.tag(RaygunSettings.LOGGING_TAG).i(string);
//         }
//     }
// 
//     public static void w(String string) {
//         if (string != null) {
//             Timber.tag(RaygunSettings.LOGGING_TAG).w(string);
//         }
//     }
// 
//     public static void e(String string) {
//         if (string != null) {
//             Timber.tag(RaygunSettings.LOGGING_TAG).e(string);
//         }
//     }
// 
//     public static void v(String string) {
//         if (string != null) {
//             Timber.tag(RaygunSettings.LOGGING_TAG).v(string);
//         }
//     }
// 
//     public static void responseCode(int responseCode) {
//         switch (responseCode) {
//             case RaygunSettings.RESPONSE_CODE_ACCEPTED:
//                 RaygunLogger.d("Request succeeded");
//                 break;
//             case RaygunSettings.RESPONSE_CODE_BAD_MESSAGE:
//                 RaygunLogger.e("Bad message - could not parse the provided JSON. Check all fields are present, especially both occurredOn (ISO 8601 DateTime) and details { } at the top level");
//                 break;
//             case RaygunSettings.RESPONSE_CODE_INVALID_API_KEY:
//                 RaygunLogger.e("Invalid API Key - The value specified in the header X-ApiKey did not match with an application in Raygun");
//                 break;
//             case RaygunSettings.RESPONSE_CODE_LARGE_PAYLOAD:
//                 RaygunLogger.e("Request entity too large - The maximum size of a JSON payload is 128KB");
//                 break;
//             case RaygunSettings.RESPONSE_CODE_RATE_LIMITED:
//                 RaygunLogger.e("Too Many Requests - Plan limit exceeded for month or plan expired");
//                 break;
//             default:
//                 RaygunLogger.d("Response status code: " + responseCode);
// 
//         }
//     }
// 
// }
// 
// Path: provider/src/debug/java/com/raygun/raygun4android/logging/TimberRaygunLoggerImplementation.java
// public class TimberRaygunLoggerImplementation implements TimberRaygunLogger {
// 
//     public static void init() {
//         if (Timber.treeCount() == 0) {
//             Timber.plant(new Timber.DebugTree());
//         }
//     }
// }


// Path: provider/src/main/java/com/raygun/raygun4android/services/RaygunPostService.java
import android.support.v4.app.JobIntentService;
import com.raygun.raygun4android.logging.RaygunLogger;
import com.raygun.raygun4android.logging.TimberRaygunLoggerImplementation;

package com.raygun.raygun4android.services;



/**
 * A JobIntentService that can validate Raygun API keys
 */
public abstract class RaygunPostService extends JobIntentService {
    /**
     * Validation to check if an API key has been supplied to the service
     *
     * @param apiKey      The API key of the app to deliver to
     * @return true or false
     */
    static Boolean validateApiKey(String apiKey) {
        if (apiKey.length() == 0) {
            RaygunLogger.e("API key is empty, nothing will be logged or reported");