package com.hdl.log; import android.content.Context; import com.hdl.log.bean.LogBean; import com.hdl.log.utils.LogUtil; /** * Created by hxb on 2023/3/14. */ public class HDLLog { /** * 阿里云日志accessId */ private static String accessId; /** * 阿里云accessKey */ private static String accessKey; /** * 项目名 */ private static String projectName; /** * 异常日志库名 */ private static String exceptionLog; /** * 埋点库名 */ private static String eventTracking; private static String endPoint; private static Context context; /** * 获取当前Context * @return */ public static Context getContext() { return context; } public static void init(Context context, String endPoint,String accessId, String accessKey, String projectName,String exceptionLog,String eventTracking){ HDLLog.context=context; HDLLog.endPoint=endPoint; HDLLog.accessId = accessId; HDLLog.accessKey = accessKey; HDLLog.projectName = projectName; HDLLog.exceptionLog = exceptionLog; HDLLog.eventTracking = eventTracking; } public static String getAccessId() { return accessId; } public static void setAccessId(String accessId) { HDLLog.accessId = accessId; } public static String getAccessKey() { return accessKey; } public static void setAccessKey(String accessKey) { HDLLog.accessKey = accessKey; } public static String getProjectName() { return projectName; } public static void setProjectName(String projectName) { HDLLog.projectName = projectName; } public static String getExceptionLog() { return exceptionLog; } public static void setExceptionLog(String exceptionLog) { HDLLog.exceptionLog = exceptionLog; } public static String getEventTracking() { return eventTracking; } public static void setEventTracking(String eventTracking) { HDLLog.eventTracking = eventTracking; } public static String getEndPoint() { return endPoint; } public static void setEndPoint(String endPoint) { HDLLog.endPoint = endPoint; } }