先自我介绍一下,小编浙江大学毕业,去过华为、字节跳动等大厂,目前阿里P7
深知大多数程序员,想要提升技能,往往是自己摸索成长,但自己不成体系的自学效果低效又漫长,而且极易碰到天花板技术停滞不前!
因此收集整理了一份《2024年最新Android移动开发全套学习资料》,初衷也很简单,就是希望能够帮助到想自学提升又不知道该从何学起的朋友。
既有适合小白学习的零基础资料,也有适合3年以上经验的小伙伴深入学习提升的进阶课程,涵盖了95%以上Android开发知识点,真正体系化!
由于文件比较多,这里只是将部分目录截图出来,全套包含大厂面经、学习笔记、源码讲义、实战项目、大纲路线、讲解视频,并且后续会持续更新
如果你需要这些资料,可以添加V获取:vip204888 (备注Android)
正文
/**
-
ProjectName: Myditukaifa
-
Author: lgq
-
Date: 2018/1/30 0030 14:37
*/
public class MyJPushReceiver extends BroadcastReceiver {
private String body;
private int num;
// private Intent mForegroundService;
private int tzid=0;
@Override
public void onReceive(Context context, Intent intent) {
try {
Bundle bundle = intent.getExtras();
String action = intent.getAction();
Log.i(“lgqq”,“body=====自定义消息=”+action);
if (action.equals(“cn.jpush.android.intent.NOTIFICATION_OPENED”)) {
//处理点击事件
ShareUtil.sharedPint(“num”,0);
ShortcutBadger.removeCount(context); //for 1.1.4+ 桌面信息
context.startActivity(new Intent(context, ShowJpushActivity.class).putExtra(“tz”,bundle.getString(“cn.jpush.android.ALERT”)));
}
if (JPushInterface.ACTION_REGISTRATION_ID.equals(intent.getAction())) {//注册
// Util.soutLong(TAG, “JPush用户注册成功”);
} else if (JPushInterface.ACTION_NOTIFICATION_RECEIVED.equals(intent.getAction())) {
// 这里会显示极光推送默认的通知,自定义能力有限
int num = ShareUtil.getSharedInt(“num”);
num++;
ShareUtil.sharedPint(“num”,num);
ShortcutBadger.applyCount(context, num);
Log.i(“lgqq”,“body=====通知=”+bundle.getString(“cn.jpush.android.ALERT”));
}
String param = bundle.getString(JPushInterface.EXTRA_REGISTRATION_ID);
Log.v(“lgqq”,“body=====action=”+num+“…”+param);
if (action.equals(“cn.jpush.android.intent.NOTIFICATION_RECEIVED”)) {
//处理滑动清除和点击删除事件
Log.v(“lgqq”,“body=====shoudaotz=”);
}
body = bundle.getString(“cn.jpush.android.ALERT”);
Log.v(“lgqq”,“body======”+body);
if (JPushInterface.ACTION_REGISTRATION_ID.equals(intent.getAction())) {
String regId = bundle.getString(JPushInterface.EXTRA_REGISTRATION_ID);
Logger.d("[MyReceiver] 接收Registration Id : " + regId);
//send the Registration Id to your server…
// EventBus.getDefault().post(new LoginEvent(regId));
} else if (JPushInterface.ACTION_MESSAGE_RECEIVED.equals(intent.getAction())) {
Logger.d("[MyReceiver] 接收到推送下来的自定义消息: " + bundle.getString(JPushInterface.EXTRA_MESSAGE));
Log.i(“lgqq”,“body=====接受到推送下来的消息=666666666666自定义消息6”);
tzid=tzid+1;
int num = ShareUtil.getSharedInt(“num”);
num++;
ShareUtil.sharedPint(“num”,num);
ShortcutBadger.applyCount(context, num);
processCustomMessage(context, bundle);
} else if (JPushInterface.ACTION_NOTIFICATION_RECEIVED.equals(intent.getAction())) {
Logger.d(“[MyReceiver] 接收到推送下来的通知”);
int notifactionId = bundle.getInt(JPushInterface.EXTRA_NOTIFICATION_ID);
Logger.d("[MyReceiver] 接收到推送下来的通知的ID: " + notifactionId);
} else if (JPushInterface.ACTION_RICHPUSH_CALLBACK.equals(intent.getAction())) {
Logger.d("[MyReceiver] 用户收到到RICH PUSH CALLBACK: " + bundle.getString(JPushInterface.EXTRA_EXTRA));
//在这里根据 JPushInterface.EXTRA_EXTRA 的内容处理代码,比如打开新的Activity, 打开一个网页等…
} else if(JPushInterface.ACTION_CONNECTION_CHANGE.equals(intent.getAction())) {
boolean connected = intent.getBooleanExtra(JPushInterface.EXTRA_CONNECTION_CHANGE, false);
Logger.w(“[MyReceiver]” + intent.getAction() +" connected state change to "+connected);
} else {
Logger.d("[MyReceiver] Unhandled intent - " + intent.getAction());
}
} catch (Exception e){
}
// context.startActivity(new Intent(context, TwoAcitvity.class));
}
//send msg to MainActivity
public String getTime(){
long currentTime = System.currentTimeMillis();
SimpleDateFormat formatter = new SimpleDateFormat(“HH时mm分”);
Date date = new Date(currentTime);
System.out.println(formatter.format(date));
// long time=System.currentTimeMillis()/1000;//获取系统时间的10位的时间戳
String str=String.valueOf(formatter.format(date));
return str;
}
private void processCustomMessage(Context context, Bundle bundle) {
RemoteViews customView = new RemoteViews(context.getPackageName(), R.layout.kongreveiver);
NotificationCompat.Builder mBuilder = new NotificationCompat.Builder(context);
String time = getTime();
// String hhmm = timetodate(time);
customView.setTextViewText(R.id.timemy,time);
if (!TextUtils.isEmpty(bundle.getString(JPushInterface.EXTRA_TITLE))){
customView.setTextViewText(R.id.name,bundle.getString(JPushInterface.EXTRA_TITLE));
}
customView.setTextViewText(R.id.neirongte,bundle.getString(JPushInterface.EXTRA_MESSAGE));
Intent intentCancel = new Intent(context,NotificationBroadcastReceiver.class);
PendingIntent pendingIntentCancel = PendingIntent.getBroadcast(context,0,
intentCancel,PendingIntent.FLAG_ONE_SHOT);
Intent companyIntroduce = new Intent(context, ShowJpushActivity.class);
companyIntroduce.putExtra(“tz”,bundle.getString(JPushInterface.EXTRA_MESSAGE));
// companyIntroduce.putExtra(“name”, name);
int notifyId = (int) System.currentTimeMillis();
PendingIntent pendingIntent = PendingIntent.getActivity(context, notifyId, companyIntroduce, PendingIntent.FLAG_UPDATE_CURRENT);
NotificationManager mNotificationManager = (NotificationManager) context.getSystemService(Context.NOTIFICATION_SERVICE);
mBuilder//设置通知栏标题
// .setContentText(bundle.getString(JPushInterface.EXTRA_MESSAGE)) //设置通知栏显示内容
.setContent(customView)
.setContentIntent(pendingIntent) //设置通知栏点击意图
.setDeleteIntent(pendingIntentCancel)//取消消息回调
// .setTicker(context.getPackageName() + “消息”)//通知首次出现在通知栏,带上升动画效果的
.setWhen(System.currentTimeMillis())//通知产生的时间,会在通知信息里显示,一般是系统获取到的时间
.setPriority(Notification.PRIORITY_DEFAULT) //设置该通知优先级
.setAutoCancel(true)//设置这个标志当用户单击面板就可以让通知将自动取消
//.setOngoing(false)//ture,设置他为一个正在进行的通知。他们通常是用来表示一个后台任务,用户积极参与(如播放音乐)或以某种方式正在等待,因此占用设备(如一个文件下载,同步操作,主动网络连接)
// .setDefaults(Notification.DEFAULT_VIBRATE)//向通知添加声音、闪灯和振动效果的最简单、最一致的方式是使用当前的用户默认设置,使用defaults属性,可以组合
// .setDefaults(Notification.DEFAULT_SOUND)
//Notification.DEFAULT_ALL Notification.DEFAULT_SOUND 添加声音 // requires VIBRATE permission
.setSmallIcon(R.mipmap.mylog);
// mNotificationManager.notify(notifyId, notify);
Log.i(“lgqq”,“body=id========”+tzid+“…”);
int num = ShareUtil.getSharedInt(“num”);
num++;
ShareUtil.sharedPint(“num”,num);
mNotificationManager.notify(num, mBuilder.build());
}
}
4、次要receiver
/**
-
自定义JPush message 接收器,包括操作tag/alias的结果返回(仅仅包含tag/alias新接口部分)
-
*/
public class MyJPushMessageReceiver extends JPushMessageReceiver {
最后
那我们该怎么做才能做到年薪60万+呢,对于程序员来说,只有不断学习,不断提升自己的实力。我之前有篇文章提到过,感兴趣的可以看看,到底要学习哪些知识才能达到年薪60万+。
通过职友集数据可以查看,以北京 Android 相关岗位为例,其中 【20k-30k】 薪酬的 Android 工程师,占到了整体从业者的 30.8%!
北京 Android 工程师「工资收入水平 」
今天重点内容是怎么去学,怎么提高自己的技术。
1.合理安排时间
2.找对好的系统的学习资料
3.有老师带,可以随时解决问题
4.有明确的学习路线
当然图中有什么需要补充的或者是需要改善的,可以在评论区写下来,一起交流学习。
网上学习资料一大堆,但如果学到的知识不成体系,遇到问题时只是浅尝辄止,不再深入研究,那么很难做到真正的技术提升。
需要这份系统化的资料的朋友,可以添加V获取:vip204888 (备注Android)
一个人可以走的很快,但一群人才能走的更远!不论你是正从事IT行业的老鸟或是对IT行业感兴趣的新人,都欢迎加入我们的的圈子(技术交流、学习资源、职场吐槽、大厂内推、面试辅导),让我们一起学习成长!
3.有老师带,可以随时解决问题
4.有明确的学习路线
当然图中有什么需要补充的或者是需要改善的,可以在评论区写下来,一起交流学习。
[外链图片转存中…(img-wom9zHkd-1713622707512)]
网上学习资料一大堆,但如果学到的知识不成体系,遇到问题时只是浅尝辄止,不再深入研究,那么很难做到真正的技术提升。
需要这份系统化的资料的朋友,可以添加V获取:vip204888 (备注Android)
[外链图片转存中…(img-HCmwMwpl-1713622707512)]
一个人可以走的很快,但一群人才能走的更远!不论你是正从事IT行业的老鸟或是对IT行业感兴趣的新人,都欢迎加入我们的的圈子(技术交流、学习资源、职场吐槽、大厂内推、面试辅导),让我们一起学习成长!