我正在使用Ubuntu 16服务器进行测试php7.1.我的一个应用程序使用bcadd功能.我知道我需要为此安装bcmath模块,但我无法找到php7.1-bcmath.当我尝试安装时apt install php-bcmath,它只是安装了php7.0-bcmath模块.
我无法php7.1-bcmath在我的服务器上随处找到模块.有人有想法吗?
apt install php7.1-bcmath 返回以下,
E: Unable to locate package php7.1-bcmath
E: Couldn't find any package by glob 'php7.1-bcmath'
E: Couldn't find any package by regex 'php7.1-bcmath'
Run Code Online (Sandbox Code Playgroud) 我有一个用于监听通知的 NotificationService 类。但是,当我调用 getActiveNotifications() 时,它会抛出一个 SecurityException。是的,我在调用此方法之前已检查过权限。
我在 NotificationService 中使用 AsyncTask 来获取通知。代码如下。
private class AsyncProcessNotification extends AsyncTask<Void, Void, Void> {
@Override
protected Void doInBackground(Void... params) {
int notificationType = MainApplication.settingNotificationType;
MainApplication.clearNotificationItems();
if (MainApplication.settingNotificationType == Constants.KEY_NOTIFICATION_TYPE_DISABLED) {
Log.i(TAG, "Notifications disabled");
return null;
}
if (PermissionHelper.isNotificationPermissionGranted(getApplicationContext())) {
if (getActiveNotifications() == null || getActiveNotifications().length == 0) {
Log.i(TAG, "No notifications found");
return null;
}
Log.i(TAG, "Getting " + getActiveNotifications().length +" notifications");
Log.i(TAG, "Notification type " + notificationType);
for (StatusBarNotification statusBarNotification : getActiveNotifications()) {
// …Run Code Online (Sandbox Code Playgroud) android android-notifications android-asynctask android-securityexception notification-listener
我是psql的新手,在Ubuntu上使用psql命令行.从命令行注销/退出的命令是什么?
谢谢!
在我的 android 应用程序中,我有几个小部件,我希望它们看起来像这些进度条。
现在我知道我不能使用任何外部库来做到这一点,因为小部件不支持大多数自定义视图。我见过大多数开发人员使用位图来绘制这样的东西。我可以设法画一个完整的圆圈。但是如何使用位图绘制这个弧形进度条或者还有其他方法吗?
感谢你的帮助。谢谢!
我尝试过但找不到这个问题的答案,所以我问这个问题。
我需要创建一个用于密码验证的正则表达式,它必须具有以下条件。
我创建了以下正则表达式,但它无法正常工作。
preg_match('/[A-Za-z\d$!^(){}?\[\]<>~%@#&*+=_-]{8,40}$/', $newpassword)
Run Code Online (Sandbox Code Playgroud)
有人可以帮我正确修复这个正则表达式吗?
谢谢。
android ×2
php ×2
bcmath ×1
command-line ×1
php-7.1 ×1
postgresql ×1
preg-match ×1
psql ×1
regex ×1
ubuntu-14.04 ×1
ubuntu-16.04 ×1