All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.envision.eos.event.api.bo.EventSRQuery Maven / Gradle / Ivy

package com.envision.eos.event.api.bo;

import com.envision.eos.event.api.expression.OrderBy;

import java.io.Serializable;
import java.util.List;

/**
 * Copyright http://www.envisioncn.com/
 * All rights reserved.
 *
 * @author jonnas.li
 */
public class EventSRQuery implements Serializable {
    private static final long serialVersionUID = -8440543147285316018L;

    private String customer;
    private List mdmIds;
    private List siteIds;
    private List codes;
    private String start;
    private String end;
    private OrderBy orderBy;
    /**
     * "local":表示当地时间 "utc":表示utc时间
     */
    private String timezone;

    /**
     * 开始记录数
     */
    private int s = 0;
    /**
     * 截至记录数
     */
    private int n = 20;

    public EventSRQuery() {}

    public EventSRQuery(String customer, String start) {
        this(customer, start, "now");
    }

    /**
     * EventSR查询
     * 

* 可以支持多种格式的时间 *

    *
  • {@code now}: 当前时间
  • *
  • {@code xxxs-ago}: xxx秒之前
  • *
  • {@code xxxm-ago}: xxx分钟之前
  • *
  • {@code xxxh-ago}: xxx小时之前
  • *
  • {@code xxxd-ago}: xxx天之前
  • *
  • {@code xxxw-ago}: xxx周之前
  • *
  • {@code xxxn-ago}: xxx月之前 (30 天)
  • *
  • {@code xxxy-ago}: xxx年之前 (365 天)
  • *
  • {@code yyyy-MM-dd HH:mm:ss}: 当地的具体日期时间
  • *
* * @param start * 开始时间 * @param end * 结束时间. */ public EventSRQuery(String customer, String start, String end) { this(customer ,start, end, "local"); } /** * 告警查询 *

* 可以支持多种格式的时间 *

    *
  • {@code now}: 当前时间
  • *
  • {@code xxxm-ago}: xxx毫秒之前
  • *
  • {@code xxxs-ago}: xxx秒之前
  • *
  • {@code xxxm-ago}: xxx分钟之前
  • *
  • {@code xxxh-ago}: xxx小时之前
  • *
  • {@code xxxd-ago}: xxx天之前
  • *
  • {@code xxxw-ago}: xxx周之前
  • *
  • {@code xxxn-ago}: xxx月之前 (30 天)
  • *
  • {@code xxxy-ago}: xxx年之前 (365 天)
  • *
  • {@code yyyy-MM-dd HH:mm:ss}: 在timezone设定下的具体日期时间
  • *
* * @param start * 开始时间 * @param end * 结束时间. * @param timezone * 设置时区. "UTC": utc时区,"LOCAL": 当地时区 */ public EventSRQuery(String customer, String start, String end, String timezone) { this.customer = customer; this.start = start; this.end = end; this.timezone = timezone; } public String getCustomer() { return customer; } public void setCustomer(String customer) { this.customer = customer; } public List getMdmIds() { return mdmIds; } public void setMdmIds(List mdmIds) { this.mdmIds = mdmIds; } public List getSiteIds() { return siteIds; } public void setSiteIds(List siteIds) { this.siteIds = siteIds; } public List getCodes() { return codes; } public void setCodes(List codes) { this.codes = codes; } public String getStart() { return start; } public void setStart(String start) { this.start = start; } public String getEnd() { return end; } public void setEnd(String end) { this.end = end; } public String getTimezone() { return timezone; } public void setTimezone(String timezone) { this.timezone = timezone; } public int getS() { return s; } public void setS(int s) { this.s = s; } public int getN() { return n; } public void setN(int n) { this.n = n; } public OrderBy getOrderBy() { return orderBy; } public void setOrderBy(OrderBy orderBy) { this.orderBy = orderBy; } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy