Files
sumoc-backend/src/main/java/SuMoC/backend/trend/config/TrendProperties.java
T

30 lines
893 B
Java

package SuMoC.backend.trend.config;
import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;
import java.time.LocalTime;
@Data
@Component
@ConfigurationProperties(prefix = "sumoc.trenddetection")
public class TrendProperties {
/**
* Minimum percentage change to detect a positive trend (e.g., 25.0 for 25%)
*/
private double positiveThreshold = 25.0;
/**
* Minimum percentage change to detect a negative trend (e.g., -25.0 for -25%)
*/
private double negativeThreshold = -25.0;
/**
* Time of day from which on trend notifications might be sent.
* Useful since we dont want to inform about trend changes in the middle of night when calculating jobs might run.
*/
private LocalTime earliestTrendNotificationTimeOfDay = LocalTime.of(12, 0);
}