From 070f4647e9d32111a145704c42c468631cbb7f47 Mon Sep 17 00:00:00 2001
From: yangys <y_ys79@sina.com>
Date: 星期四, 25 四月 2024 17:35:32 +0800
Subject: [PATCH] auth模块代码整理
---
smart-man-boot/src/main/java/com/qianwen/smartman/common/utils/DelayList.java | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/smart-man-boot/src/main/java/com/qianwen/smartman/common/utils/DelayList.java b/smart-man-boot/src/main/java/com/qianwen/smartman/common/utils/DelayList.java
index 64793f6..46325bf 100644
--- a/smart-man-boot/src/main/java/com/qianwen/smartman/common/utils/DelayList.java
+++ b/smart-man-boot/src/main/java/com/qianwen/smartman/common/utils/DelayList.java
@@ -36,7 +36,7 @@
return true;
}
if (o instanceof DelayList) {
- DelayList<?> other = (DelayList) o;
+ DelayList<?> other = (DelayList<?>) o;
if (other.canEqual(this) && getMaxWait() == other.getMaxWait() && getMaxLen() == other.getMaxLen()) {
Object this$queue = getQueue();
Object other$queue = other.getQueue();
@@ -105,13 +105,13 @@
}
public DelayList(int maxWait) {
- this.queue = new ArrayBlockingQueue(100000, true);
+ this.queue = new ArrayBlockingQueue<>(100000, true);
this.maxWait = maxWait;
this.maxLen = 1000;
}
public DelayList(int maxWait, int maxLen) {
- this.queue = new ArrayBlockingQueue(100000, true);
+ this.queue = new ArrayBlockingQueue<>(100000, true);
this.maxWait = maxWait;
this.maxLen = maxLen;
}
@@ -125,7 +125,7 @@
if (this.timer == null) {
System.out.println("鍒涘缓娑堣垂绾跨▼");
this.timer = new Thread(() -> {
- ArrayList arrayList = new ArrayList();
+ ArrayList<T> arrayList = new ArrayList<>();
Queues.drainUninterruptibly(this.queue, arrayList, this.maxLen, this.maxWait, TimeUnit.SECONDS);
if (arrayList.size() != 0) {
consumer.accept(arrayList);
--
Gitblit v1.9.3