方式一,Toast,几秒后自动消失
Toast.makeText(this, "通知消息", Toast.LENGTH_SHORT).show();
方式二,AlertDialog,需要点击一下才能消失
AlertDialog.Builder builder = new AlertDialog.Builder(getContext());
builder.setMessage("通知消息");
builder.setTitle("提示");
builder.create().show();