package com.ruoyi.rocketmq.domain.vo;

import lombok.Data;
import org.snmp4j.mp.SnmpConstants;
import org.snmp4j.security.SecurityLevel;

import java.util.List;
import java.util.Map;

@Data
public class SwitchOidVo {
    private Map<String, String> netOID;
    private Map<String, String> moduleOID;
    private Map<String, String> mpuOID;
    private Map<String, String> pwrOID;
    private Map<String, String> fanOID;
    private Map<String, String> otherOID;
    /** 团体名 */
    private String community;
    /** ip地址 */
    private String ip;
    /** 端口 */
    private Integer port;
    /** 过滤值 */
    private Map<String, List<String>> filters;

    private int version = SnmpConstants.version2c; // 默认v2c
    private int timeout = 5000;
    private int retries = 2;

    // SNMP v3特有参数
    private String securityName;
    private String authProtocol;
    private String authPassword;
    private String privProtocol;
    private String privPassword;
    private int securityLevel = SecurityLevel.AUTH_PRIV;
    /**
     * 判断是否为SNMP v3
     */
    public boolean isV3() {
        return version == SnmpConstants.version3;
    }
}
