导航菜单

页面标题

页面副标题

moonshot.企业版 v8.14.46 - KeepAliveService.java 源代码

正在查看: moonshot.企业版 v8.14.46 应用的 KeepAliveService.java JAVA 源代码文件

本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。


package com.ddtx.dingdatacontact.main;

import android.app.Notification;
import android.app.NotificationChannel;
import android.app.NotificationManager;
import android.app.PendingIntent;
import android.app.Service;
import android.content.Intent;
import android.os.Build;
import android.os.IBinder;
import c8sKPHc73aST6XPVbBtC.c8sKPHc73aST6XPVbBtC.InterfaceC2092;
import com.ddtx.dingdatacontact.R;
import com.netease.nim.uikit.GetChildAc;

public class KeepAliveService extends Service {

    private NotificationManager f11586;

    private String f11587 = "serviceid";

    private String f11585 = "servicename";

    private Notification m15209() {
        Intent intent = new Intent();
        intent.setClass(getBaseContext(), GetChildAc.getParentAc("MainActivity"));
        intent.setFlags(536870912);
        Notification.Builder contentIntent = new Notification.Builder(this).setSmallIcon(R.drawable.logo).setContentTitle(getString(R.string.app_name)).setContentText("欢迎使用").setContentIntent(PendingIntent.getActivity(getBaseContext(), 0, intent, 134217728));
        if (Build.VERSION.SDK_INT >= 26) {
            contentIntent.setChannelId(this.f11587);
        }
        return contentIntent.build();
    }

    @Override
    @InterfaceC2092
    public IBinder onBind(Intent intent) {
        return null;
    }

    @Override
    public void onCreate() {
        super.onCreate();
        this.f11586 = (NotificationManager) getSystemService("notification");
        if (Build.VERSION.SDK_INT >= 26) {
            this.f11586.createNotificationChannel(new NotificationChannel(this.f11587, this.f11585, 4));
        }
        startForeground(1, m15209());
    }
}