chore: removed lombok and upgraded copyright

This commit is contained in:
zihluwang
2025-01-25 19:53:04 +08:00
parent f771b1af19
commit 971037f160
48 changed files with 220 additions and 507 deletions
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2024-2024 OnixByte.
* Copyright (C) 2024-2025 OnixByte.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -17,7 +17,8 @@
package com.onixbyte.nums;
import lombok.Getter;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.math.BigDecimal;
import java.math.RoundingMode;
@@ -90,9 +91,10 @@ import java.util.function.Function;
* @see BigDecimal
* @since 1.0.0
*/
@Getter
public final class ChainedCalcUtil {
private final static Logger log = LoggerFactory.getLogger(ChainedCalcUtil.class);
/**
* Creates a {@code ChainedCalcUtil} instance with the specified initial value.
*
@@ -235,6 +237,15 @@ public final class ChainedCalcUtil {
return value.setScale(scale, RoundingMode.HALF_UP);
}
/**
* Returns the current value as a {@link BigDecimal}.
*
* @return the current value as a {@link BigDecimal}
*/
public BigDecimal getValue() {
return value;
}
/**
* Returns the current value as a {@link Double}.
*
@@ -297,7 +308,7 @@ public final class ChainedCalcUtil {
Object other,
Integer beforeOperateScale) {
return baseOperator((otherValue) ->
operator.apply(this.value, otherValue),
operator.apply(this.value, otherValue),
other,
beforeOperateScale);
}
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2024 OnixByte.
* Copyright (C) 2024-2025 OnixByte.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -14,9 +14,12 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.onixbyte.nums;
import com.onixbyte.nums.model.QuartileBounds;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.util.List;
@@ -48,6 +51,8 @@ import java.util.List;
*/
public final class PercentileCalculator {
private final static Logger log = LoggerFactory.getLogger(PercentileCalculator.class);
/**
* Private constructor prevents from being initialised.
*/
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2024-2024 OnixByte.
* Copyright (C) 2024-2025 OnixByte.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.