diff --git a/pom.xml b/pom.xml index 38c9d27..3e51811 100644 --- a/pom.xml +++ b/pom.xml @@ -13,7 +13,7 @@ com.loafle.overflow commons-java jar - 1.0.1-SNAPSHOT + 1.0.3-SNAPSHOT com.loafle.overflow.commons-java diff --git a/src/main/java/com/loafle/overflow/core/annotation/ProbeAPI.java b/src/main/java/com/loafle/overflow/core/annotation/ProbeAPI.java index 26ba45f..ab2f819 100644 --- a/src/main/java/com/loafle/overflow/core/annotation/ProbeAPI.java +++ b/src/main/java/com/loafle/overflow/core/annotation/ProbeAPI.java @@ -5,7 +5,7 @@ import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; -@Target({ElementType.METHOD}) +@Target({ ElementType.METHOD }) @Retention(RetentionPolicy.RUNTIME) public @interface ProbeAPI { String value() default ""; diff --git a/src/main/java/com/loafle/overflow/core/annotation/RPCService.java b/src/main/java/com/loafle/overflow/core/annotation/RPCService.java index 4fd2bf8..6e946b0 100644 --- a/src/main/java/com/loafle/overflow/core/annotation/RPCService.java +++ b/src/main/java/com/loafle/overflow/core/annotation/RPCService.java @@ -8,10 +8,10 @@ import java.lang.annotation.Target; import org.springframework.core.annotation.AliasFor; import org.springframework.stereotype.Component; -@Target({ElementType.TYPE}) +@Target({ ElementType.TYPE }) @Retention(RetentionPolicy.RUNTIME) @Component public @interface RPCService { - @AliasFor(annotation = Component.class) - String value() default ""; + @AliasFor(annotation = Component.class) + String value() default ""; } diff --git a/src/main/java/com/loafle/overflow/core/annotation/WebappAPI.java b/src/main/java/com/loafle/overflow/core/annotation/WebappAPI.java index a0be732..522d961 100644 --- a/src/main/java/com/loafle/overflow/core/annotation/WebappAPI.java +++ b/src/main/java/com/loafle/overflow/core/annotation/WebappAPI.java @@ -5,7 +5,7 @@ import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; -@Target({ElementType.METHOD}) +@Target({ ElementType.METHOD }) @Retention(RetentionPolicy.RUNTIME) public @interface WebappAPI { String value() default ""; diff --git a/src/main/java/com/loafle/overflow/core/exception/OverflowException.java b/src/main/java/com/loafle/overflow/core/exception/OverflowException.java index b1d1b7c..8f3eb1c 100644 --- a/src/main/java/com/loafle/overflow/core/exception/OverflowException.java +++ b/src/main/java/com/loafle/overflow/core/exception/OverflowException.java @@ -1,9 +1,13 @@ package com.loafle.overflow.core.exception; public class OverflowException extends Exception { - private static final long serialVersionUID = -2737018677113628699L; - public OverflowException(String message){ super(message); } - public OverflowException(String message, Throwable throwable) { - super(message, throwable); - } + private static final long serialVersionUID = -2737018677113628699L; + + public OverflowException(String message) { + super(message); + } + + public OverflowException(String message, Throwable throwable) { + super(message, throwable); + } } diff --git a/src/main/java/com/loafle/overflow/core/model/Mail.java b/src/main/java/com/loafle/overflow/core/model/Mail.java index b616507..c09ac02 100644 --- a/src/main/java/com/loafle/overflow/core/model/Mail.java +++ b/src/main/java/com/loafle/overflow/core/model/Mail.java @@ -8,103 +8,102 @@ import java.util.Map; * Created by geek on 18. 1. 3. */ public class Mail { - private String mailFrom; - private String mailTo; - private String mailCc; - private String mailBcc; - private String mailSubject; - private String mailContent; - private String contentType; - private List< Object > attachments; - private Map< String, Object > model; - private String templateLoacation; + private String mailFrom; + private String mailTo; + private String mailCc; + private String mailBcc; + private String mailSubject; + private String mailContent; + private String contentType; + private List attachments; + private Map model; + private String templateLoacation; + public Mail() { + contentType = "text/plain"; + } - public Mail() { - contentType = "text/plain"; - } + public String getContentType() { + return contentType; + } - public String getContentType() { - return contentType; - } + public void setContentType(String contentType) { + this.contentType = contentType; + } - public void setContentType(String contentType) { - this.contentType = contentType; - } + public String getMailBcc() { + return mailBcc; + } - public String getMailBcc() { - return mailBcc; - } + public void setMailBcc(String mailBcc) { + this.mailBcc = mailBcc; + } - public void setMailBcc(String mailBcc) { - this.mailBcc = mailBcc; - } + public String getMailCc() { + return mailCc; + } - public String getMailCc() { - return mailCc; - } + public void setMailCc(String mailCc) { + this.mailCc = mailCc; + } - public void setMailCc(String mailCc) { - this.mailCc = mailCc; - } + public String getMailFrom() { + return mailFrom; + } - public String getMailFrom() { - return mailFrom; - } + public void setMailFrom(String mailFrom) { + this.mailFrom = mailFrom; + } - public void setMailFrom(String mailFrom) { - this.mailFrom = mailFrom; - } + public String getMailSubject() { + return mailSubject; + } - public String getMailSubject() { - return mailSubject; - } + public void setMailSubject(String mailSubject) { + this.mailSubject = mailSubject; + } - public void setMailSubject(String mailSubject) { - this.mailSubject = mailSubject; - } + public String getMailTo() { + return mailTo; + } - public String getMailTo() { - return mailTo; - } + public void setMailTo(String mailTo) { + this.mailTo = mailTo; + } - public void setMailTo(String mailTo) { - this.mailTo = mailTo; - } + public Date getMailSendDate() { + return new Date(); + } - public Date getMailSendDate() { - return new Date(); - } + public String getMailContent() { + return mailContent; + } - public String getMailContent() { - return mailContent; - } + public void setMailContent(String mailContent) { + this.mailContent = mailContent; + } - public void setMailContent(String mailContent) { - this.mailContent = mailContent; - } + public List getAttachments() { + return attachments; + } - public List< Object > getAttachments() { - return attachments; - } + public void setAttachments(List attachments) { + this.attachments = attachments; + } - public void setAttachments(List < Object > attachments) { - this.attachments = attachments; - } + public Map getModel() { + return model; + } - public Map< String, Object > getModel() { - return model; - } + public void setModel(Map model) { + this.model = model; + } - public void setModel(Map < String, Object > model) { - this.model = model; - } + public String getTemplateLoacation() { + return templateLoacation; + } - public String getTemplateLoacation() { - return templateLoacation; - } - - public void setTemplateLoacation(String templateLoacation) { - this.templateLoacation = templateLoacation; - } + public void setTemplateLoacation(String templateLoacation) { + this.templateLoacation = templateLoacation; + } } diff --git a/src/main/java/com/loafle/overflow/core/model/PageParams.java b/src/main/java/com/loafle/overflow/core/model/PageParams.java index 064265c..8ac0367 100644 --- a/src/main/java/com/loafle/overflow/core/model/PageParams.java +++ b/src/main/java/com/loafle/overflow/core/model/PageParams.java @@ -11,34 +11,34 @@ public class PageParams { private String sortDirection; public Integer getPageNo() { - return pageNo; + return pageNo; } public void setPageNo(Integer pageNo) { - this.pageNo = pageNo; + this.pageNo = pageNo; } public Integer getCountPerPage() { - return countPerPage; + return countPerPage; } public void setCountPerPage(Integer countPerPage) { - this.countPerPage = countPerPage; + this.countPerPage = countPerPage; } public String getSortCol() { - return sortCol; + return sortCol; } public void setSortCol(String sortCol) { - this.sortCol = sortCol; + this.sortCol = sortCol; } public String getSortDirection() { - return sortDirection; + return sortDirection; } public void setSortDirection(String sortDirection) { - this.sortDirection = sortDirection; + this.sortDirection = sortDirection; } } diff --git a/src/main/java/com/loafle/overflow/core/model/PublishMessage.java b/src/main/java/com/loafle/overflow/core/model/PublishMessage.java index 034f511..582cf27 100644 --- a/src/main/java/com/loafle/overflow/core/model/PublishMessage.java +++ b/src/main/java/com/loafle/overflow/core/model/PublishMessage.java @@ -40,9 +40,7 @@ public class PublishMessage { } public static enum TargetType { - MEMBER_SESSION("MEMBER_SESSION"), - MEMBER("MEMBER"), - PROBE("PROBE"); + MEMBER_SESSION("MEMBER_SESSION"), MEMBER("MEMBER"), PROBE("PROBE"); final private String name; diff --git a/src/main/java/com/loafle/overflow/core/type/CryptoType.java b/src/main/java/com/loafle/overflow/core/type/CryptoType.java index bf490fc..7694869 100644 --- a/src/main/java/com/loafle/overflow/core/type/CryptoType.java +++ b/src/main/java/com/loafle/overflow/core/type/CryptoType.java @@ -4,14 +4,17 @@ package com.loafle.overflow.core.type; * Created by snoop on 17. 6. 27. */ public enum CryptoType { - NONE(""), - TLS("TLS"); + NONE(""), + TLS("TLS"); - private String stringValue; - CryptoType(String string) {stringValue = string;} + private String stringValue; - @Override - public String toString() { - return stringValue; - } + CryptoType(String string) { + stringValue = string; + } + + @Override + public String toString() { + return stringValue; + } } \ No newline at end of file diff --git a/src/main/java/com/loafle/overflow/core/type/PortType.java b/src/main/java/com/loafle/overflow/core/type/PortType.java index ab85e4b..e46caa3 100644 --- a/src/main/java/com/loafle/overflow/core/type/PortType.java +++ b/src/main/java/com/loafle/overflow/core/type/PortType.java @@ -4,15 +4,18 @@ package com.loafle.overflow.core.type; * Created by snoop on 17. 6. 27. */ public enum PortType { - TCP("TCP"), - UDP("UDP"), - TLS("TLS"); + TCP("TCP"), + UDP("UDP"), + TLS("TLS"); - private String stringValue; - PortType(String string) {stringValue = string;} + private String stringValue; - @Override - public String toString() { - return stringValue; - } + PortType(String string) { + stringValue = string; + } + + @Override + public String toString() { + return stringValue; + } } \ No newline at end of file diff --git a/src/main/java/com/loafle/overflow/model/apikey/ApiKey.java b/src/main/java/com/loafle/overflow/model/apikey/ApiKey.java index c5aa24b..9833c25 100644 --- a/src/main/java/com/loafle/overflow/model/apikey/ApiKey.java +++ b/src/main/java/com/loafle/overflow/model/apikey/ApiKey.java @@ -8,71 +8,73 @@ import java.util.Date; @Entity @Table(name = "API_KEY", schema = "public") public class ApiKey { - private Long id; - private String apiKey; - private Date createDate; - private Domain domain; + private Long id; + private String apiKey; + private Date createDate; + private Domain domain; - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @Column(name = "API_KEY", nullable = false, unique = true,length = 50) - public String getApiKey() { - return apiKey; - } + @Column(name = "API_KEY", nullable = false, unique = true, length = 50) + public String getApiKey() { + return apiKey; + } - public void setApiKey(String apiKey) { - this.apiKey = apiKey; - } + public void setApiKey(String apiKey) { + this.apiKey = apiKey; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name="CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - @ManyToOne - @JoinColumn(name = "DOMAIN_ID", nullable=false) - public Domain getDomain() { - return domain; - } + @ManyToOne + @JoinColumn(name = "DOMAIN_ID", nullable = false) + public Domain getDomain() { + return domain; + } - public void setDomain(Domain domain) { - this.domain = domain; - } -// -// @Override -// public boolean equals(Object o) { -// if (this == o) return true; -// if (o == null || getClass() != o.getClass()) return false; -// -// TblApiKey tblApiKey = (TblApiKey) o; -// -// if (id != tblApiKey.id) return false; -// if (domainId != tblApiKey.domainId) return false; -// if (apiKey != null ? !apiKey.equals(tblApiKey.apiKey) : tblApiKey.apiKey != null) return false; -// if (createDate != null ? !createDate.equals(tblApiKey.createDate) : tblApiKey.createDate != null) return false; -// -// return true; -// } -// -// @Override -// public int hashCode() { -// int result = (int) (id ^ (id >>> 32)); -// result = 31 * result + (apiKey != null ? apiKey.hashCode() : 0); -// result = 31 * result + (createDate != null ? createDate.hashCode() : 0); -// result = 31 * result + (int) (domainId ^ (domainId >>> 32)); -// return result; -// } + public void setDomain(Domain domain) { + this.domain = domain; + } + // + // @Override + // public boolean equals(Object o) { + // if (this == o) return true; + // if (o == null || getClass() != o.getClass()) return false; + // + // TblApiKey tblApiKey = (TblApiKey) o; + // + // if (id != tblApiKey.id) return false; + // if (domainId != tblApiKey.domainId) return false; + // if (apiKey != null ? !apiKey.equals(tblApiKey.apiKey) : tblApiKey.apiKey != + // null) return false; + // if (createDate != null ? !createDate.equals(tblApiKey.createDate) : + // tblApiKey.createDate != null) return false; + // + // return true; + // } + // + // @Override + // public int hashCode() { + // int result = (int) (id ^ (id >>> 32)); + // result = 31 * result + (apiKey != null ? apiKey.hashCode() : 0); + // result = 31 * result + (createDate != null ? createDate.hashCode() : 0); + // result = 31 * result + (int) (domainId ^ (domainId >>> 32)); + // return result; + // } } diff --git a/src/main/java/com/loafle/overflow/model/auth/AuthCrawler.java b/src/main/java/com/loafle/overflow/model/auth/AuthCrawler.java index 0660cac..1f833b9 100644 --- a/src/main/java/com/loafle/overflow/model/auth/AuthCrawler.java +++ b/src/main/java/com/loafle/overflow/model/auth/AuthCrawler.java @@ -14,59 +14,59 @@ import java.util.Date; @Entity @Table(name = "AUTH_CRAWLER", schema = "public") public class AuthCrawler { - private Long id; - private MetaCrawler crawler; - private Target target; - private String authJson; - private Date createDate; + private Long id; + private MetaCrawler metaCrawler; + private Target target; + private String authJson; + private Date createDate; - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @ManyToOne - @JoinColumn(name = "CRAWLER_ID", nullable = false) - public MetaCrawler getCrawler() { - return crawler; - } + @ManyToOne + @JoinColumn(name = "META_CRAWLER_ID", nullable = false) + public MetaCrawler getMetaCrawler() { + return metaCrawler; + } - public void setCrawler(MetaCrawler crawler) { - this.crawler = crawler; - } + public void setMetaCrawler(MetaCrawler metaCrawler) { + this.metaCrawler = metaCrawler; + } - @ManyToOne - @OnDelete(action = OnDeleteAction.CASCADE) - @JoinColumn(name = "TARGET_ID", nullable = false) - public Target getTarget() { - return target; - } + @ManyToOne + @OnDelete(action = OnDeleteAction.CASCADE) + @JoinColumn(name = "TARGET_ID", nullable = false) + public Target getTarget() { + return target; + } - public void setTarget(Target target) { - this.target = target; - } + public void setTarget(Target target) { + this.target = target; + } - @Column(name = "AUTH_JSON", nullable = false) - public String getAuthJson() { - return authJson; - } + @Column(name = "AUTH_JSON", nullable = false) + public String getAuthJson() { + return authJson; + } - public void setAuthJson(String authJson) { - this.authJson = authJson; - } + public void setAuthJson(String authJson) { + this.authJson = authJson; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/data/Metric.java b/src/main/java/com/loafle/overflow/model/data/Metric.java index 13be922..ea0032c 100644 --- a/src/main/java/com/loafle/overflow/model/data/Metric.java +++ b/src/main/java/com/loafle/overflow/model/data/Metric.java @@ -27,30 +27,35 @@ public class Metric { public String getSensorConfigID() { return sensorConfigID; } + /** * @param sensorConfigID the sensorConfigID to set */ public void setSensorConfigID(String sensorConfigID) { this.sensorConfigID = sensorConfigID; } + /** * @return the data */ public Map getData() { return data; } + /** * @param data the data to set */ public void setData(Map data) { this.data = data; } + /** * @return the collectDate */ public Date getCollectDate() { return collectDate; } + /** * @param collectDate the collectDate to set */ diff --git a/src/main/java/com/loafle/overflow/model/discovery/DiscoveryStartInfo.java b/src/main/java/com/loafle/overflow/model/discovery/DiscoveryStartInfo.java index 336338b..52440b7 100644 --- a/src/main/java/com/loafle/overflow/model/discovery/DiscoveryStartInfo.java +++ b/src/main/java/com/loafle/overflow/model/discovery/DiscoveryStartInfo.java @@ -6,87 +6,87 @@ import java.util.List; * Created by snoop on 17. 9. 29. */ public class DiscoveryStartInfo { - String startIpv4; - String endIPv4; - String excludeIpv4; + String startIpv4; + String endIPv4; + String excludeIpv4; - String startIpv6; - String endIPv6; - String excludeIpv6; + String startIpv6; + String endIPv6; + String excludeIpv6; - String startPort; - String endPort; - List services; + String startPort; + String endPort; + List services; - public String getStartIpv4() { - return startIpv4; - } + public String getStartIpv4() { + return startIpv4; + } - public void setStartIpv4(String startIpv4) { - this.startIpv4 = startIpv4; - } + public void setStartIpv4(String startIpv4) { + this.startIpv4 = startIpv4; + } - public String getEndIPv4() { - return endIPv4; - } + public String getEndIPv4() { + return endIPv4; + } - public void setEndIPv4(String endIPv4) { - this.endIPv4 = endIPv4; - } + public void setEndIPv4(String endIPv4) { + this.endIPv4 = endIPv4; + } - public String getExcludeIpv4() { - return excludeIpv4; - } + public String getExcludeIpv4() { + return excludeIpv4; + } - public void setExcludeIpv4(String excludeIpv4) { - this.excludeIpv4 = excludeIpv4; - } + public void setExcludeIpv4(String excludeIpv4) { + this.excludeIpv4 = excludeIpv4; + } - public String getStartIpv6() { - return startIpv6; - } + public String getStartIpv6() { + return startIpv6; + } - public void setStartIpv6(String startIpv6) { - this.startIpv6 = startIpv6; - } + public void setStartIpv6(String startIpv6) { + this.startIpv6 = startIpv6; + } - public String getEndIPv6() { - return endIPv6; - } + public String getEndIPv6() { + return endIPv6; + } - public void setEndIPv6(String endIPv6) { - this.endIPv6 = endIPv6; - } + public void setEndIPv6(String endIPv6) { + this.endIPv6 = endIPv6; + } - public String getExcludeIpv6() { - return excludeIpv6; - } + public String getExcludeIpv6() { + return excludeIpv6; + } - public void setExcludeIpv6(String excludeIpv6) { - this.excludeIpv6 = excludeIpv6; - } + public void setExcludeIpv6(String excludeIpv6) { + this.excludeIpv6 = excludeIpv6; + } - public String getStartPort() { - return startPort; - } + public String getStartPort() { + return startPort; + } - public void setStartPort(String startPort) { - this.startPort = startPort; - } + public void setStartPort(String startPort) { + this.startPort = startPort; + } - public String getEndPort() { - return endPort; - } + public String getEndPort() { + return endPort; + } - public void setEndPort(String endPort) { - this.endPort = endPort; - } + public void setEndPort(String endPort) { + this.endPort = endPort; + } - public List getServices() { - return services; - } + public List getServices() { + return services; + } - public void setServices(List services) { - this.services = services; - } + public void setServices(List services) { + this.services = services; + } } diff --git a/src/main/java/com/loafle/overflow/model/discovery/Host.java b/src/main/java/com/loafle/overflow/model/discovery/Host.java index d791e64..fb7b292 100644 --- a/src/main/java/com/loafle/overflow/model/discovery/Host.java +++ b/src/main/java/com/loafle/overflow/model/discovery/Host.java @@ -1,6 +1,5 @@ package com.loafle.overflow.model.discovery; - import java.util.Date; import java.util.List; @@ -9,89 +8,89 @@ import java.util.List; */ public class Host { - private Long id; - private String ipv4; - private String ipv6; - private String mac; - private String os; + private Long id; + private String ipv4; + private String ipv6; + private String mac; + private String os; - private Date discoveredDate; + private Date discoveredDate; - private Zone zone; + private Zone zone; - private boolean target; + private boolean target; - private List portList; + private List portList; - public Long getId() { - return id; - } + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - public String getIpv4() { - return ipv4; - } + public String getIpv4() { + return ipv4; + } - public void setIpv4(String ipv4) { - this.ipv4 = ipv4; - } + public void setIpv4(String ipv4) { + this.ipv4 = ipv4; + } - public String getIpv6() { - return ipv6; - } + public String getIpv6() { + return ipv6; + } - public void setIpv6(String ipv6) { - this.ipv6 = ipv6; - } + public void setIpv6(String ipv6) { + this.ipv6 = ipv6; + } - public String getMac() { - return mac; - } + public String getMac() { + return mac; + } - public void setMac(String mac) { - this.mac = mac; - } + public void setMac(String mac) { + this.mac = mac; + } - public String getOs() { - return os; - } + public String getOs() { + return os; + } - public void setOs(String os) { - this.os = os; - } + public void setOs(String os) { + this.os = os; + } - public Date getDiscoveredDate() { - return discoveredDate; - } + public Date getDiscoveredDate() { + return discoveredDate; + } - public void setDiscoveredDate(Date discoveredDate) { - this.discoveredDate = discoveredDate; - } + public void setDiscoveredDate(Date discoveredDate) { + this.discoveredDate = discoveredDate; + } - public Zone getZone() { - return zone; - } + public Zone getZone() { + return zone; + } - public void setZone(Zone zone) { - this.zone = zone; - } + public void setZone(Zone zone) { + this.zone = zone; + } - public boolean isTarget() { - return target; - } + public boolean isTarget() { + return target; + } - public void setTarget(boolean target) { - this.target = target; - } + public void setTarget(boolean target) { + this.target = target; + } - public List getPortList() { - return portList; - } + public List getPortList() { + return portList; + } - public void setPortList(List portList) { - this.portList = portList; - } + public void setPortList(List portList) { + this.portList = portList; + } } diff --git a/src/main/java/com/loafle/overflow/model/discovery/Port.java b/src/main/java/com/loafle/overflow/model/discovery/Port.java index 321139b..e8a5097 100644 --- a/src/main/java/com/loafle/overflow/model/discovery/Port.java +++ b/src/main/java/com/loafle/overflow/model/discovery/Port.java @@ -10,71 +10,71 @@ import java.util.List; */ public class Port { - private Long id; - private PortType portType; - private Integer portNumber; + private Long id; + private PortType portType; + private Integer portNumber; - private Date discoveredDate; + private Date discoveredDate; - private Host host; + private Host host; - private Boolean target; + private Boolean target; - private List serviceList; + private List serviceList; - public Long getId() { - return id; - } + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - public PortType getPortType() { - return portType; - } + public PortType getPortType() { + return portType; + } - public void setPortType(PortType portType) { - this.portType = portType; - } + public void setPortType(PortType portType) { + this.portType = portType; + } - public Integer getPortNumber() { - return portNumber; - } + public Integer getPortNumber() { + return portNumber; + } - public void setPortNumber(Integer portNumber) { - this.portNumber = portNumber; - } + public void setPortNumber(Integer portNumber) { + this.portNumber = portNumber; + } - public Date getDiscoveredDate() { - return discoveredDate; - } + public Date getDiscoveredDate() { + return discoveredDate; + } - public void setDiscoveredDate(Date discoveredDate) { - this.discoveredDate = discoveredDate; - } + public void setDiscoveredDate(Date discoveredDate) { + this.discoveredDate = discoveredDate; + } - public Host getHost() { - return host; - } + public Host getHost() { + return host; + } - public void setHost(Host host) { - this.host = host; - } + public void setHost(Host host) { + this.host = host; + } - public Boolean isTarget() { - return target; - } + public Boolean isTarget() { + return target; + } - public void setTarget(Boolean target) { - this.target = target; - } + public void setTarget(Boolean target) { + this.target = target; + } - public List getServiceList() { - return serviceList; - } + public List getServiceList() { + return serviceList; + } - public void setServiceList(List serviceList) { - this.serviceList = serviceList; - } + public void setServiceList(List serviceList) { + this.serviceList = serviceList; + } } diff --git a/src/main/java/com/loafle/overflow/model/discovery/Service.java b/src/main/java/com/loafle/overflow/model/discovery/Service.java index 1a2fd4c..22bf142 100644 --- a/src/main/java/com/loafle/overflow/model/discovery/Service.java +++ b/src/main/java/com/loafle/overflow/model/discovery/Service.java @@ -1,6 +1,5 @@ package com.loafle.overflow.model.discovery; - import java.util.Date; import com.loafle.overflow.core.type.CryptoType; @@ -10,61 +9,61 @@ import com.loafle.overflow.core.type.CryptoType; */ public class Service { - private Long id; - private CryptoType cryptoType; - private String serviceName; + private Long id; + private CryptoType cryptoType; + private String serviceName; - private Date discoveredDate; + private Date discoveredDate; - private Port port; + private Port port; - private Boolean target; + private Boolean target; - public Long getId() { - return id; - } + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - public CryptoType getCryptoType() { - return cryptoType; - } + public CryptoType getCryptoType() { + return cryptoType; + } - public void setCryptoType(CryptoType cryptoType) { - this.cryptoType = cryptoType; - } + public void setCryptoType(CryptoType cryptoType) { + this.cryptoType = cryptoType; + } - public String getServiceName() { - return serviceName; - } + public String getServiceName() { + return serviceName; + } - public void setServiceName(String serviceName) { - this.serviceName = serviceName; - } + public void setServiceName(String serviceName) { + this.serviceName = serviceName; + } - public Date getDiscoveredDate() { - return discoveredDate; - } + public Date getDiscoveredDate() { + return discoveredDate; + } - public void setDiscoveredDate(Date discoveredDate) { - this.discoveredDate = discoveredDate; - } + public void setDiscoveredDate(Date discoveredDate) { + this.discoveredDate = discoveredDate; + } - public Port getPort() { - return port; - } + public Port getPort() { + return port; + } - public void setPort(Port port) { - this.port = port; - } + public void setPort(Port port) { + this.port = port; + } - public Boolean isTarget() { - return target; - } + public Boolean isTarget() { + return target; + } - public void setTarget(Boolean target) { - this.target = target; - } + public void setTarget(Boolean target) { + this.target = target; + } } diff --git a/src/main/java/com/loafle/overflow/model/domain/Domain.java b/src/main/java/com/loafle/overflow/model/domain/Domain.java index 9f3676a..9d5e4d8 100644 --- a/src/main/java/com/loafle/overflow/model/domain/Domain.java +++ b/src/main/java/com/loafle/overflow/model/domain/Domain.java @@ -9,44 +9,45 @@ import java.util.Date; @Entity @Table(name = "DOMAIN", schema = "public") public class Domain { - private Long id; - private String name; - private Date createDate; + private Long id; + private String name; + private Date createDate; - public Domain() { - } - public Domain(Long id) { - this.id = id; - } + public Domain() { + } - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + public Domain(Long id) { + this.id = id; + } - public void setId(Long id) { - this.id = id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - @Basic - @Column(name = "NAME", nullable = true, length = 50) - public String getName() { - return name; - } + public void setId(Long id) { + this.id = id; + } - public void setName(String name) { - this.name = name; - } + @Basic + @Column(name = "NAME", nullable = true, length = 50) + public String getName() { + return name; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + public void setName(String name) { + this.name = name; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } + + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/domain/DomainMember.java b/src/main/java/com/loafle/overflow/model/domain/DomainMember.java index 3d359da..7f878c1 100644 --- a/src/main/java/com/loafle/overflow/model/domain/DomainMember.java +++ b/src/main/java/com/loafle/overflow/model/domain/DomainMember.java @@ -11,49 +11,48 @@ import java.sql.Timestamp; @Entity @Table(name = "DOMAIN_MEMBER", schema = "public") public class DomainMember { - private Long id; - private Timestamp createDate; - private Member member; - private Domain domain; + private Long id; + private Timestamp createDate; + private Member member; + private Domain domain; - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @Basic - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Timestamp getCreateDate() { - return createDate; - } + @Basic + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Timestamp getCreateDate() { + return createDate; + } - public void setCreateDate(Timestamp createDate) { - this.createDate = createDate; - } + public void setCreateDate(Timestamp createDate) { + this.createDate = createDate; + } + @ManyToOne + @JoinColumn(name = "MEMBER_ID", nullable = false) + public Member getMember() { + return member; + } - @ManyToOne - @JoinColumn(name = "MEMBER_ID", nullable = false) - public Member getMember() { - return member; - } + public void setMember(Member member) { + this.member = member; + } - public void setMember(Member member) { - this.member = member; - } + @ManyToOne + @JoinColumn(name = "DOMAIN_ID", nullable = false) + public Domain getDomain() { + return domain; + } - @ManyToOne - @JoinColumn(name = "DOMAIN_ID", nullable = false) - public Domain getDomain() { - return domain; - } - - public void setDomain(Domain domain) { - this.domain = domain; - } + public void setDomain(Domain domain) { + this.domain = domain; + } } diff --git a/src/main/java/com/loafle/overflow/model/email/EmailAuth.java b/src/main/java/com/loafle/overflow/model/email/EmailAuth.java index 7464548..014978c 100644 --- a/src/main/java/com/loafle/overflow/model/email/EmailAuth.java +++ b/src/main/java/com/loafle/overflow/model/email/EmailAuth.java @@ -12,70 +12,70 @@ import java.util.Date; @Entity @Table(name = "EMAIL_AUTH", schema = "public") public class EmailAuth { - private Long id; - private String emailAuthKey; - private Date createDate; - private Date authConfirmDate; - private Member member; - private MetaEmailStatus emailStatus; + private Long id; + private String emailAuthKey; + private Date createDate; + private Date authConfirmDate; + private Member member; + private MetaEmailStatus metaEmailStatus; - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @Basic - @Column(name = "EMAIL_AUTH_KEY", nullable = true, length = 50) - public String getEmailAuthKey() { - return emailAuthKey; - } + @Basic + @Column(name = "EMAIL_AUTH_KEY", nullable = true, length = 50) + public String getEmailAuthKey() { + return emailAuthKey; + } - public void setEmailAuthKey(String emailAuthKey) { - this.emailAuthKey = emailAuthKey; - } + public void setEmailAuthKey(String emailAuthKey) { + this.emailAuthKey = emailAuthKey; + } - @Basic - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Basic + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - @Basic - @Column(name = "AUTH_CONFIRM_DATE", nullable = true, insertable = true, updatable = true) - public Date getAuthConfirmDate() { - return authConfirmDate; - } + @Basic + @Column(name = "AUTH_CONFIRM_DATE", nullable = true, insertable = true, updatable = true) + public Date getAuthConfirmDate() { + return authConfirmDate; + } - public void setAuthConfirmDate(Date authConfirmDate) { - this.authConfirmDate = authConfirmDate; - } + public void setAuthConfirmDate(Date authConfirmDate) { + this.authConfirmDate = authConfirmDate; + } - @ManyToOne - @JoinColumn(name = "MEMBER_ID", nullable = false) - public Member getMember() { - return member; - } + @ManyToOne + @JoinColumn(name = "MEMBER_ID", nullable = false) + public Member getMember() { + return member; + } - public void setMember(Member member) { - this.member = member; - } + public void setMember(Member member) { + this.member = member; + } - @ManyToOne - @JoinColumn(name = "STATUS", nullable = false) - public MetaEmailStatus getEmailStatus() { - return emailStatus; - } + @ManyToOne + @JoinColumn(name = "META_EMAIL_STATUS_ID", nullable = false) + public MetaEmailStatus getMetaEmailStatus() { + return metaEmailStatus; + } - public void setEmailStatus(MetaEmailStatus emailStatus) { - this.emailStatus = emailStatus; - } + public void setMetaEmailStatus(MetaEmailStatus metaEmailStatus) { + this.metaEmailStatus = metaEmailStatus; + } } diff --git a/src/main/java/com/loafle/overflow/model/history/History.java b/src/main/java/com/loafle/overflow/model/history/History.java index e8180f4..5099d93 100644 --- a/src/main/java/com/loafle/overflow/model/history/History.java +++ b/src/main/java/com/loafle/overflow/model/history/History.java @@ -14,103 +14,106 @@ import java.util.Date; @Entity @Table(name = "HISTORY", schema = "public") public class History { - private Long id; - private Date createDate; - private MetaHistoryType type; - private String message; - private Probe probe; - private Member member; - private Domain domain; + private Long id; + private Date createDate; + private MetaHistoryType metaHistoryType; + private String message; + private Probe probe; + private Member member; + private Domain domain; - //private MetaResultType resultType; // i'm not sure this is necessary + // private MetaResultType resultType; // i'm not sure this is necessary + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + public void setId(Long id) { + this.id = id; + } - public void setId(Long id) { - this.id = id; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + @ManyToOne + @JoinColumn(name = "META_HISTORY_TYPE_ID", nullable = false) + public MetaHistoryType getMetaHistoryType() { + return metaHistoryType; + } - @ManyToOne - @JoinColumn(name = "TYPE_ID", nullable = false) - public MetaHistoryType getType() { - return type; - } + public void setMetaHistoryType(MetaHistoryType metaHistoryType) { + this.metaHistoryType = metaHistoryType; + } - public void setType(MetaHistoryType type) { - this.type = type; - } + @Column(name = "MESSAGE", nullable = false, length = 255) + public String getMessage() { + return message; + } - @Column(name = "MESSAGE", nullable = false, length = 255) - public String getMessage() { - return message; - } + public void setMessage(String message) { + this.message = message; + } - public void setMessage(String message) { - this.message = message; - } + @ManyToOne + @JoinColumn(name = "PROBE_ID", nullable = false) + public Probe getProbe() { + return probe; + } - @ManyToOne - @JoinColumn(name = "PROBE_ID", nullable = false) - public Probe getProbe() { - return probe; - } + public void setProbe(Probe probe) { + this.probe = probe; + } - public void setProbe(Probe probe) { - this.probe = probe; - } + @ManyToOne + @JoinColumn(name = "MEMBER_ID", nullable = false) + public Member getMember() { + return member; + } - @ManyToOne - @JoinColumn(name = "MEMBER_ID", nullable = false) - public Member getMember() { - return member; - } + public void setMember(Member member) { + this.member = member; + } - public void setMember(Member member) { - this.member = member; - } + @ManyToOne + @JoinColumn(name = "DOMAIN_ID", nullable = false) + public Domain getDomain() { + return domain; + } - @ManyToOne - @JoinColumn(name = "DOMAIN_ID", nullable = false) - public Domain getDomain() { - return domain; - } + public void setDomain(Domain domain) { + this.domain = domain; + } - public void setDomain(Domain domain) { - this.domain = domain; - } + @Override + public boolean equals(Object o) { + if (this == o) + return true; + if (o == null || getClass() != o.getClass()) + return false; - @Override - public boolean equals(Object o) { - if (this == o) return true; - if (o == null || getClass() != o.getClass()) return false; + History that = (History) o; - History that = (History) o; + if (id != that.id) + return false; + if (createDate != null ? !createDate.equals(that.createDate) : that.createDate != null) + return false; - if (id != that.id) return false; - if (createDate != null ? !createDate.equals(that.createDate) : that.createDate != null) return false; + return true; + } - return true; - } - - @Override - public int hashCode() { - int result = (int) (id ^ (id >>> 32)); - result = 31 * result + (createDate != null ? createDate.hashCode() : 0); - return result; - } + @Override + public int hashCode() { + int result = (int) (id ^ (id >>> 32)); + result = 31 * result + (createDate != null ? createDate.hashCode() : 0); + return result; + } } diff --git a/src/main/java/com/loafle/overflow/model/infra/Infra.java b/src/main/java/com/loafle/overflow/model/infra/Infra.java index a6549a4..38ceb50 100644 --- a/src/main/java/com/loafle/overflow/model/infra/Infra.java +++ b/src/main/java/com/loafle/overflow/model/infra/Infra.java @@ -1,6 +1,5 @@ package com.loafle.overflow.model.infra; - import com.loafle.overflow.model.meta.MetaInfraType; import com.loafle.overflow.model.probe.Probe; import javax.persistence.*; @@ -14,50 +13,49 @@ import java.util.Date; @Inheritance(strategy = InheritanceType.JOINED) @DiscriminatorColumn(name = "INFRA_TYPE", discriminatorType = DiscriminatorType.INTEGER) public abstract class Infra { - private Long id; - private MetaInfraType infraType; - private Date createDate; - private Probe probe; + private Long id; + private MetaInfraType metaInfraType; + private Date createDate; + private Probe probe; - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @ManyToOne - @JoinColumn(name = "TYPE_ID", nullable = false) - public MetaInfraType getInfraType() { - return infraType; - } + @ManyToOne + @JoinColumn(name = "META_INFRA_TYPE_ID", nullable = false) + public MetaInfraType getMetaInfraType() { + return metaInfraType; + } - public void setInfraType(MetaInfraType infraType) { - this.infraType = infraType; - } + public void setMetaInfraType(MetaInfraType metaInfraType) { + this.metaInfraType = metaInfraType; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - @ManyToOne - @JoinColumn(name = "PROBE_ID", nullable = true) - public Probe getProbe() { - return probe; - } - - public void setProbe(Probe probe) { - this.probe = probe; - } + @ManyToOne + @JoinColumn(name = "PROBE_ID", nullable = true) + public Probe getProbe() { + return probe; + } + public void setProbe(Probe probe) { + this.probe = probe; + } } diff --git a/src/main/java/com/loafle/overflow/model/infra/InfraHost.java b/src/main/java/com/loafle/overflow/model/infra/InfraHost.java index 750790e..33bbc05 100644 --- a/src/main/java/com/loafle/overflow/model/infra/InfraHost.java +++ b/src/main/java/com/loafle/overflow/model/infra/InfraHost.java @@ -10,71 +10,71 @@ import java.util.Date; @Table(name = "INFRA_HOST", schema = "public") @DiscriminatorValue("2") public class InfraHost extends Infra { -// private Long id; - private InfraOS os; - private String ipv4; - private String ipv6; - private String mac; - private Date createDate; + // private Long id; + private InfraOS infraOS; + private String ipv4; + private String ipv6; + private String mac; + private Date createDate; -// @Id -// @GeneratedValue(strategy= GenerationType.IDENTITY) -// public Long getId() { -// return id; -// } -// -// public void setId(Long id) { -// this.id = id; -// } + // @Id + // @GeneratedValue(strategy= GenerationType.IDENTITY) + // public Long getId() { + // return id; + // } + // + // public void setId(Long id) { + // this.id = id; + // } - @ManyToOne - @JoinColumn(name = "OS_ID", nullable = true) - public InfraOS getOs() { - return os; - } + @ManyToOne + @JoinColumn(name = "INFRA_OS_ID", nullable = true) + public InfraOS getInfraOS() { + return infraOS; + } - public void setOs(InfraOS os) { - this.os = os; - } + public void setInfraOS(InfraOS infraOS) { + this.infraOS = infraOS; + } - @Basic - @Column(name = "IP_V4", nullable = true) - public String getIpv4() { - return ipv4; - } + @Basic + @Column(name = "IP_V4", nullable = true) + public String getIpv4() { + return ipv4; + } - public void setIpv4(String ipv4) { - this.ipv4 = ipv4; - } + public void setIpv4(String ipv4) { + this.ipv4 = ipv4; + } - @Basic - @Column(name = "IP_V6", nullable = true) - public String getIpv6() { - return ipv6; - } + @Basic + @Column(name = "IP_V6", nullable = true) + public String getIpv6() { + return ipv6; + } - public void setIpv6(String ipv6) { - this.ipv6 = ipv6; - } + public void setIpv6(String ipv6) { + this.ipv6 = ipv6; + } - @Basic - @Column(name = "MAC", nullable = true) - public String getMac() { - return mac; - } + @Basic + @Column(name = "MAC", nullable = true) + public String getMac() { + return mac; + } - public void setMac(String mac) { - this.mac = mac; - } + public void setMac(String mac) { + this.mac = mac; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = true, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = true, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/infra/InfraMachine.java b/src/main/java/com/loafle/overflow/model/infra/InfraMachine.java index 17bb286..42e2d3c 100644 --- a/src/main/java/com/loafle/overflow/model/infra/InfraMachine.java +++ b/src/main/java/com/loafle/overflow/model/infra/InfraMachine.java @@ -10,46 +10,43 @@ import java.util.Date; @Table(name = "INFRA_MACHINE", schema = "public") @DiscriminatorValue("1") public class InfraMachine extends Infra { -// private Long id; + // private Long id; - private String meta; - private Date createDate; + private String meta; + private Date createDate; - /* - private Long id; - private String meta; - private Date createDate; - */ + /* + * private Long id; private String meta; private Date createDate; + */ -// @Id -// @GeneratedValue(strategy= GenerationType.IDENTITY) -// public Long getId() { -// return id; -// } -// -// public void setId(Long id) { -// this.id = id; -// } + // @Id + // @GeneratedValue(strategy= GenerationType.IDENTITY) + // public Long getId() { + // return id; + // } + // + // public void setId(Long id) { + // this.id = id; + // } - @Basic - @Column(name = "META", nullable = true, length = 1000) - public String getMeta() { - return meta; - } + @Basic + @Column(name = "META", nullable = true, length = 1000) + public String getMeta() { + return meta; + } - public void setMeta(String meta) { - this.meta = meta; - } + public void setMeta(String meta) { + this.meta = meta; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } - diff --git a/src/main/java/com/loafle/overflow/model/infra/InfraOS.java b/src/main/java/com/loafle/overflow/model/infra/InfraOS.java index e7bfda9..d291d74 100644 --- a/src/main/java/com/loafle/overflow/model/infra/InfraOS.java +++ b/src/main/java/com/loafle/overflow/model/infra/InfraOS.java @@ -1,6 +1,5 @@ package com.loafle.overflow.model.infra; - import com.loafle.overflow.model.meta.MetaInfraVendor; import javax.persistence.*; @@ -13,60 +12,60 @@ import java.util.Date; @Table(name = "INFRA_OS", schema = "public") @DiscriminatorValue("3") public class InfraOS extends Infra { -// private Long id; - private InfraMachine machine; - private String meta; - private Date createDate; - private MetaInfraVendor vendor; + // private Long id; + private InfraMachine infraMachine; + private String meta; + private Date createDate; + private MetaInfraVendor metaInfraVendor; -// @Id -// @GeneratedValue(strategy= GenerationType.IDENTITY) -// public Long getId() { -// return id; -// } -// -// public void setId(Long id) { -// this.id = id; -// } + // @Id + // @GeneratedValue(strategy= GenerationType.IDENTITY) + // public Long getId() { + // return id; + // } + // + // public void setId(Long id) { + // this.id = id; + // } - @ManyToOne - @JoinColumn(name = "MACHINE_ID", nullable = true) - public InfraMachine getMachine() { - return machine; - } + @ManyToOne + @JoinColumn(name = "INFRA_MACHINE_ID", nullable = true) + public InfraMachine getInfraMachine() { + return infraMachine; + } - public void setMachine(InfraMachine machine) { - this.machine = machine; - } + public void setInfraMachine(InfraMachine infraMachine) { + this.infraMachine = infraMachine; + } - @Basic - @Column(name = "META", nullable = true, length = 255) - public String getMeta() { - return meta; - } + @Basic + @Column(name = "META", nullable = true, length = 255) + public String getMeta() { + return meta; + } - public void setMeta(String meta) { - this.meta = meta; - } + public void setMeta(String meta) { + this.meta = meta; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = true, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = true, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - @ManyToOne - @JoinColumn(name = "VENDOR_ID", nullable = true) - public MetaInfraVendor getVendor() { - return vendor; - } + @ManyToOne + @JoinColumn(name = "META_INFRA_VENDOR_ID", nullable = true) + public MetaInfraVendor getMetaInfraVendor() { + return metaInfraVendor; + } - public void setVendor(MetaInfraVendor vendor) { - this.vendor = vendor; - } + public void setMetaInfraVendor(MetaInfraVendor metaInfraVendor) { + this.metaInfraVendor = metaInfraVendor; + } } diff --git a/src/main/java/com/loafle/overflow/model/infra/InfraOSApplication.java b/src/main/java/com/loafle/overflow/model/infra/InfraOSApplication.java index 06f4f88..d271284 100644 --- a/src/main/java/com/loafle/overflow/model/infra/InfraOSApplication.java +++ b/src/main/java/com/loafle/overflow/model/infra/InfraOSApplication.java @@ -10,49 +10,49 @@ import java.util.Date; @Table(name = "INFRA_OS_APPLICATION", schema = "public") @DiscriminatorValue("4") public class InfraOSApplication extends Infra { -// private Long id; - private InfraOS os; - private String name; - private Date createDate; + // private Long id; + private InfraOS infraOS; + private String name; + private Date createDate; -// @Id -// @GeneratedValue(strategy= GenerationType.IDENTITY) -// public Long getId() { -// return id; -// } -// -// public void setId(Long id) { -// this.id = id; -// } + // @Id + // @GeneratedValue(strategy= GenerationType.IDENTITY) + // public Long getId() { + // return id; + // } + // + // public void setId(Long id) { + // this.id = id; + // } - @ManyToOne - @JoinColumn(name = "OS_ID", nullable = true) - public InfraOS getOs() { - return os; - } + @ManyToOne + @JoinColumn(name = "INFRA_OS_ID", nullable = true) + public InfraOS getInfraOS() { + return infraOS; + } - public void setOs(InfraOS os) { - this.os = os; - } + public void setInfraOS(InfraOS infraOS) { + this.infraOS = infraOS; + } - @Basic - @Column(name = "NAME", nullable = true, length = 50) - public String getName() { - return name; - } + @Basic + @Column(name = "NAME", nullable = true, length = 50) + public String getName() { + return name; + } - public void setName(String name) { - this.name = name; - } + public void setName(String name) { + this.name = name; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = true, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = true, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/infra/InfraOSDaemon.java b/src/main/java/com/loafle/overflow/model/infra/InfraOSDaemon.java index e007606..a1ec37a 100644 --- a/src/main/java/com/loafle/overflow/model/infra/InfraOSDaemon.java +++ b/src/main/java/com/loafle/overflow/model/infra/InfraOSDaemon.java @@ -10,48 +10,48 @@ import java.util.Date; @Table(name = "INFRA_OS_DAEMON", schema = "public") @DiscriminatorValue("5") public class InfraOSDaemon extends Infra { -// private Long id; - private InfraOS os; - private String name; - private Date createDate; + // private Long id; + private InfraOS infraOS; + private String name; + private Date createDate; -// @Id -// @GeneratedValue(strategy= GenerationType.IDENTITY) -// public Long getId() { -// return id; -// } -// -// public void setId(Long id) { -// this.id = id; -// } + // @Id + // @GeneratedValue(strategy= GenerationType.IDENTITY) + // public Long getId() { + // return id; + // } + // + // public void setId(Long id) { + // this.id = id; + // } - @ManyToOne - @JoinColumn(name = "OS_ID", nullable = true) - public InfraOS getOs() { - return os; - } + @ManyToOne + @JoinColumn(name = "INFRA_OS_ID", nullable = true) + public InfraOS getInfraOS() { + return infraOS; + } - public void setOs(InfraOS os) { - this.os = os; - } + public void setInfraOS(InfraOS infraOS) { + this.infraOS = infraOS; + } - @Basic - @Column(name = "NAME", nullable = true, length = 50) - public String getName() { - return name; - } + @Basic + @Column(name = "NAME", nullable = true, length = 50) + public String getName() { + return name; + } - public void setName(String name) { - this.name = name; - } + public void setName(String name) { + this.name = name; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = true, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = true, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/infra/InfraOSPort.java b/src/main/java/com/loafle/overflow/model/infra/InfraOSPort.java index c27b4ce..382d301 100644 --- a/src/main/java/com/loafle/overflow/model/infra/InfraOSPort.java +++ b/src/main/java/com/loafle/overflow/model/infra/InfraOSPort.java @@ -1,6 +1,5 @@ package com.loafle.overflow.model.infra; - import com.loafle.overflow.model.meta.MetaInfraVendor; import javax.persistence.*; @@ -13,82 +12,82 @@ import java.util.Date; @Table(name = "INFRA_OS_PORT", schema = "public") @DiscriminatorValue("6") public class InfraOSPort extends Infra { -// private Long id; - private InfraOS os; - private Date createDate; - private Integer port; - private String portType; - private MetaInfraVendor vendor; - private Boolean tlsType; -// -// @Id -// @GeneratedValue(strategy= GenerationType.IDENTITY) -// public Long getId() { -// return id; -// } -// -// public void setId(Long id) { -// this.id = id; -// } + // private Long id; + private InfraOS infraOS; + private Date createDate; + private Integer port; + private String portType; + private MetaInfraVendor metaInfraVendor; + private Boolean tlsType; + // + // @Id + // @GeneratedValue(strategy= GenerationType.IDENTITY) + // public Long getId() { + // return id; + // } + // + // public void setId(Long id) { + // this.id = id; + // } - @ManyToOne - @JoinColumn(name = "OS_ID", nullable = true) - public InfraOS getOs() { - return this.os; - } + @ManyToOne + @JoinColumn(name = "INFRA_OS_ID", nullable = true) + public InfraOS getInfraOS() { + return infraOS; + } - public void setOs(InfraOS os) { - this.os = os; - } + public void setInfraOS(InfraOS infraOS) { + this.infraOS = infraOS; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = true, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = true, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - @Basic - @Column(name = "PORT", nullable = true) - public Integer getPort() { - return port; - } + @Basic + @Column(name = "PORT", nullable = true) + public Integer getPort() { + return port; + } - public void setPort(Integer port) { - this.port = port; - } + public void setPort(Integer port) { + this.port = port; + } - @Basic - @Column(name = "PORT_TYPE", nullable = true) - public String getPortType() { - return portType; - } + @Basic + @Column(name = "PORT_TYPE", nullable = true) + public String getPortType() { + return portType; + } - public void setPortType(String portType) { - this.portType = portType; - } + public void setPortType(String portType) { + this.portType = portType; + } - @ManyToOne - @JoinColumn(name = "VENDOR_ID", nullable = true) - public MetaInfraVendor getVendor() { - return vendor; - } + @ManyToOne + @JoinColumn(name = "META_INFRA_VENDOR_ID", nullable = true) + public MetaInfraVendor getMetaInfraVendor() { + return metaInfraVendor; + } - public void setVendor(MetaInfraVendor vendor) { - this.vendor = vendor; - } + public void setMetaInfraVendor(MetaInfraVendor metaInfraVendor) { + this.metaInfraVendor = metaInfraVendor; + } - @Basic - @Column(name = "TLS_TYPE", nullable = true) - public Boolean isTlsType() { - return tlsType; - } + @Basic + @Column(name = "TLS_TYPE", nullable = true) + public Boolean isTlsType() { + return tlsType; + } - public void setTlsType(Boolean tlsType) { - this.tlsType = tlsType; - } + public void setTlsType(Boolean tlsType) { + this.tlsType = tlsType; + } } diff --git a/src/main/java/com/loafle/overflow/model/infra/InfraService.java b/src/main/java/com/loafle/overflow/model/infra/InfraService.java index 3b2cf99..5ae8c72 100644 --- a/src/main/java/com/loafle/overflow/model/infra/InfraService.java +++ b/src/main/java/com/loafle/overflow/model/infra/InfraService.java @@ -1,6 +1,5 @@ package com.loafle.overflow.model.infra; - import com.loafle.overflow.model.meta.MetaInfraVendor; import javax.persistence.*; @@ -12,82 +11,82 @@ import java.util.Date; @Entity(name = "INFRA_SERVICE") @Table(name = "INFRA_SERVICE", schema = "public") @DiscriminatorValue("7") -public class InfraService extends Infra{ -// private Long id; - private InfraHost host; - private String portType; - private Integer port; - private MetaInfraVendor vendor; - private Date createDate; - private Boolean tlsType; +public class InfraService extends Infra { + // private Long id; + private InfraHost infraHost; + private String portType; + private Integer port; + private MetaInfraVendor metaInfraVendor; + private Date createDate; + private Boolean tlsType; -// @Id -// @GeneratedValue(strategy= GenerationType.IDENTITY) -// public Long getId() { -// return id; -// } -// -// public void setId(Long id) { -// this.id = id; -// } + // @Id + // @GeneratedValue(strategy= GenerationType.IDENTITY) + // public Long getId() { + // return id; + // } + // + // public void setId(Long id) { + // this.id = id; + // } - @ManyToOne - @JoinColumn(name = "HOST_ID", nullable = true) - public InfraHost getHost() { - return host; - } + @ManyToOne + @JoinColumn(name = "INFRA_HOST_ID", nullable = true) + public InfraHost getInfraHost() { + return infraHost; + } - public void setHost(InfraHost host) { - this.host = host; - } + public void setInfraHost(InfraHost infraHost) { + this.infraHost = infraHost; + } - @Basic - @Column(name = "PORT_TYPE", nullable = true) - public String getPortType() { - return portType; - } + @Basic + @Column(name = "PORT_TYPE", nullable = true) + public String getPortType() { + return portType; + } - public void setPortType(String portType) { - this.portType = portType; - } + public void setPortType(String portType) { + this.portType = portType; + } - @Basic - @Column(name = "PORT", nullable = true) - public Integer getPort() { - return port; - } + @Basic + @Column(name = "PORT", nullable = true) + public Integer getPort() { + return port; + } - public void setPort(Integer port) { - this.port = port; - } + public void setPort(Integer port) { + this.port = port; + } - @ManyToOne - @JoinColumn(name = "VENDOR_ID", nullable = true) - public MetaInfraVendor getVendor() { - return vendor; - } + @ManyToOne + @JoinColumn(name = "META_INFRA_VENDOR_ID", nullable = true) + public MetaInfraVendor getMetaInfraVendor() { + return metaInfraVendor; + } - public void setVendor(MetaInfraVendor vendor) { - this.vendor = vendor; - } + public void setMetaInfraVendor(MetaInfraVendor metaInfraVendor) { + this.metaInfraVendor = metaInfraVendor; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = true, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = true, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - @Basic - @Column(name = "TLS_TYPE", nullable = true) - public Boolean isTlsType() { - return tlsType; - } + @Basic + @Column(name = "TLS_TYPE", nullable = true) + public Boolean isTlsType() { + return tlsType; + } - public void setTlsType(Boolean tlsType) { - this.tlsType = tlsType; - } + public void setTlsType(Boolean tlsType) { + this.tlsType = tlsType; + } } diff --git a/src/main/java/com/loafle/overflow/model/member/Member.java b/src/main/java/com/loafle/overflow/model/member/Member.java index 1ef477f..9e06f48 100644 --- a/src/main/java/com/loafle/overflow/model/member/Member.java +++ b/src/main/java/com/loafle/overflow/model/member/Member.java @@ -13,122 +13,121 @@ import java.util.Date; @Entity @Table(name = "MEMBER", schema = "public") public class Member { - private Long id; - private String email; - private transient String pw; - private String name; - private String phone; - private String companyName; - private Date createDate; - private MetaMemberStatus status; - private Integer signinFailCount; - private Boolean totpType; + private Long id; + private String email; + private transient String pw; + private String name; + private String phone; + private String companyName; + private Date createDate; + private MetaMemberStatus metaMemberStatus; + private Integer signinFailCount; + private Boolean totpType; - public Member() { - } + public Member() { + } - public Member(Long id) { - this.id = id; - } + public Member(Long id) { + this.id = id; + } - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @Basic - @Column(name = "EMAIL", nullable = false, length = 50) - public String getEmail() { - return email; - } + @Basic + @Column(name = "EMAIL", nullable = false, length = 50) + public String getEmail() { + return email; + } - public void setEmail(String email) { - this.email = email; - } + public void setEmail(String email) { + this.email = email; + } - @Basic - @JsonIgnore - @Column(name = "PW", nullable = true, length = 64) - public String getPw() { - return pw; - } + @Basic + @JsonIgnore + @Column(name = "PW", nullable = true, length = 64) + public String getPw() { + return pw; + } - public void setPw(String pw) { - this.pw = pw; - } + public void setPw(String pw) { + this.pw = pw; + } - @Basic - @Column(name = "NAME", nullable = true, length = 50) - public String getName() { - return name; - } + @Basic + @Column(name = "NAME", nullable = true, length = 50) + public String getName() { + return name; + } - public void setName(String name) { - this.name = name; - } + public void setName(String name) { + this.name = name; + } - @Basic - @Column(name = "PHONE", nullable = true, length = 50) - public String getPhone() { - return phone; - } + @Basic + @Column(name = "PHONE", nullable = true, length = 50) + public String getPhone() { + return phone; + } - public void setPhone(String phone) { - this.phone = phone; - } + public void setPhone(String phone) { + this.phone = phone; + } - @Basic - @Column(name = "COMPANY_NAME", nullable = true, length = 50) - public String getCompanyName() { - return companyName; - } + @Basic + @Column(name = "COMPANY_NAME", nullable = true, length = 50) + public String getCompanyName() { + return companyName; + } - public void setCompanyName(String companyName) { - this.companyName = companyName; - } + public void setCompanyName(String companyName) { + this.companyName = companyName; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - @ManyToOne - @JoinColumn(name = "STATUS_ID", nullable = false) - public MetaMemberStatus getStatus() { - return status; - } + @ManyToOne + @JoinColumn(name = "META_MEMBER_STATUS_ID", nullable = false) + public MetaMemberStatus getMetaMemberStatus() { + return metaMemberStatus; + } - public void setStatus(MetaMemberStatus status) { - this.status = status; - } + public void setMetaMemberStatus(MetaMemberStatus metaMemberStatus) { + this.metaMemberStatus = metaMemberStatus; + } - @Column(name = "SIGNIN_FAIL_COUNT", nullable = true, columnDefinition = "int default 0") - public Integer getSigninFailCount(){ - return this.signinFailCount; - } + @Column(name = "SIGNIN_FAIL_COUNT", nullable = true, columnDefinition = "int default 0") + public Integer getSigninFailCount() { + return this.signinFailCount; + } - public void setSigninFailCount(Integer failCount) { - this.signinFailCount = failCount; - } + public void setSigninFailCount(Integer failCount) { + this.signinFailCount = failCount; + } - @Basic - @Column(name = "TOTP_TYPE", nullable = false, columnDefinition = "Boolean default false") - public Boolean isTotpType() { - return totpType; - } + @Basic + @Column(name = "TOTP_TYPE", nullable = false, columnDefinition = "Boolean default false") + public Boolean isTotpType() { + return totpType; + } - public void setTotpType(Boolean totpType) { - this.totpType = totpType; - } + public void setTotpType(Boolean totpType) { + this.totpType = totpType; + } } - diff --git a/src/main/java/com/loafle/overflow/model/member/MemberTotp.java b/src/main/java/com/loafle/overflow/model/member/MemberTotp.java index f6b6441..db322f7 100644 --- a/src/main/java/com/loafle/overflow/model/member/MemberTotp.java +++ b/src/main/java/com/loafle/overflow/model/member/MemberTotp.java @@ -1,6 +1,5 @@ package com.loafle.overflow.model.member; - import javax.persistence.*; import java.util.Date; @@ -10,76 +9,76 @@ import java.util.Date; @Entity @Table(name = "MEMBER_TOTP", schema = "public") public class MemberTotp { - private Long id; - private Member member; - private String secretCode; - private Date createDate; - private Date updateDate; - private String otpAuth; + private Long id; + private Member member; + private String secretCode; + private Date createDate; + private Date updateDate; + private String otpAuth; - public MemberTotp() { - } + public MemberTotp() { + } - public MemberTotp(Long id) { - this.id = id; - } + public MemberTotp(Long id) { + this.id = id; + } - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @OneToOne - @JoinColumn(name = "MEMBER_ID", nullable = false) - public Member getMember() { - return member; - } + @OneToOne + @JoinColumn(name = "MEMBER_ID", nullable = false) + public Member getMember() { + return member; + } - public void setMember(Member member) { - this.member = member; - } + public void setMember(Member member) { + this.member = member; + } - @Basic - @Column(name = "SECRET_CODE", nullable = false, length = 20) - public String getSecretCode() { - return secretCode; - } + @Basic + @Column(name = "SECRET_CODE", nullable = false, length = 20) + public String getSecretCode() { + return secretCode; + } - public void setSecretCode(String secretCode) { - this.secretCode = secretCode; - } + public void setSecretCode(String secretCode) { + this.secretCode = secretCode; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "UPDATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = true) - public Date getUpdateDate() { - return updateDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "UPDATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = true) + public Date getUpdateDate() { + return updateDate; + } - public void setUpdateDate(Date updateDate) { - this.updateDate = updateDate; - } + public void setUpdateDate(Date updateDate) { + this.updateDate = updateDate; + } - @Transient - public String getOtpAuth() { - return otpAuth; - } + @Transient + public String getOtpAuth() { + return otpAuth; + } - public void setOtpAuth(String otpAuthURL) { - this.otpAuth = otpAuthURL; - } + public void setOtpAuth(String otpAuthURL) { + this.otpAuth = otpAuthURL; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaCrawler.java b/src/main/java/com/loafle/overflow/model/meta/MetaCrawler.java index 755e348..2638905 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaCrawler.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaCrawler.java @@ -9,47 +9,46 @@ import java.util.Date; @Entity @Table(name = "META_CRAWLER", schema = "public") public class MetaCrawler { - private Short id; - private Date createDate; - private String name; - private String description; + private Short id; + private Date createDate; + private String name; + private String description; - @Id - public Short getId() { - return id; - } + @Id + public Short getId() { + return id; + } - public void setId(Short id) { - this.id = id; - } + public void setId(Short id) { + this.id = id; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name="CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - @Column(name = "NAME", nullable = true, length = 50) - public String getName() { - return name; - } + @Column(name = "NAME", nullable = true, length = 50) + public String getName() { + return name; + } - public void setName(String name) { - this.name = name; - } + public void setName(String name) { + this.name = name; + } - @Column(name = "DESCRIPTION", nullable = true, length = 100) - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } + @Column(name = "DESCRIPTION", nullable = true, length = 100) + public String getDescription() { + return description; + } + public void setDescription(String description) { + this.description = description; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaCrawlerInputItem.java b/src/main/java/com/loafle/overflow/model/meta/MetaCrawlerInputItem.java index 43614d7..0fed166 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaCrawlerInputItem.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaCrawlerInputItem.java @@ -9,159 +9,160 @@ import java.util.Date; @Entity @Table(name = "META_CRAWLER_INPUT_ITEM", schema = "public") public class MetaCrawlerInputItem { - private Integer id; - private MetaInputType inputType; - private MetaCrawler crawler; - private String description; - private String name; - private Date createDate; - private Boolean required; - private String defaultValue; - private String pattern; - private String keyName; - private String keyValue; + private Integer id; + private MetaInputType metaInputType; + private MetaCrawler metaCrawler; + private String description; + private String name; + private Date createDate; + private Boolean required; + private String defaultValue; + private String pattern; + private String keyName; + private String keyValue; - @Id - public Integer getId() { - return id; - } + @Id + public Integer getId() { + return id; + } - public void setId(Integer id) { - this.id = id; - } + public void setId(Integer id) { + this.id = id; + } + @ManyToOne + @JoinColumn(name = "META_INPUT_TYPE_ID", nullable = false) + public MetaInputType getMetaInputType() { + return metaInputType; + } - @ManyToOne - @JoinColumn(name = "TYPE_ID", nullable = false) - public MetaInputType getInputType() { - return inputType; - } + public void setMetaInputType(MetaInputType metaInputType) { + this.metaInputType = metaInputType; + } - public void setInputType(MetaInputType inputType) { - this.inputType = inputType; - } + @ManyToOne + @JoinColumn(name = "META_CRAWLER_ID", nullable = false) + public MetaCrawler getMetaCrawler() { + return metaCrawler; + } - @ManyToOne - @JoinColumn(name = "CRAWLER_ID", nullable = false) - public MetaCrawler getCrawler() { - return crawler; - } + public void setMetaCrawler(MetaCrawler metaCrawler) { + this.metaCrawler = metaCrawler; + } - public void setCrawler(MetaCrawler crawler) { - this.crawler = crawler; - } + @Column(name = "DESCRIPTION", nullable = true, length = 50) + public String getDescription() { + return description; + } - @Column(name = "DESCRIPTION", nullable = true, length = 50) - public String getDescription() { - return description; - } + public void setDescription(String description) { + this.description = description; + } - public void setDescription(String description) { - this.description = description; - } + @Column(name = "NAME", nullable = true, length = 50) + public String getName() { + return name; + } - @Column(name = "NAME", nullable = true, length = 50) - public String getName() { - return name; - } + public void setName(String name) { + this.name = name; + } - public void setName(String name) { - this.name = name; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + @Column(name = "REQUIRED", nullable = false) + public Boolean isRequired() { + return required; + } - @Column(name = "REQUIRED", nullable = false) - public Boolean isRequired() { - return required; - } + public void setRequired(Boolean required) { + this.required = required; + } - public void setRequired(Boolean required) { - this.required = required; - } + @Column(name = "DEFAULT_VALUE", nullable = true, length = 50) + public String getDefaultValue() { + return defaultValue; + } - @Column(name = "DEFAULT_VALUE", nullable = true, length = 50) - public String getDefaultValue() { - return defaultValue; - } + public void setDefaultValue(String defaultValue) { + this.defaultValue = defaultValue; + } - public void setDefaultValue(String defaultValue) { - this.defaultValue = defaultValue; - } + @Column(name = "PATTERN", nullable = true, length = 50) + public String getPattern() { + return pattern; + } + public void setPattern(String pattern) { + this.pattern = pattern; + } - @Column(name = "PATTERN", nullable = true, length = 50) - public String getPattern() { - return pattern; - } + @Column(name = "KEY_NAME", nullable = true, length = 50) + public String getKeyName() { + return keyName; + } - public void setPattern(String pattern) { - this.pattern = pattern; - } + public void setKeyName(String keyName) { + this.keyName = keyName; + } + @Column(name = "KEY_VALUE", nullable = true, length = 50) + public String getKeyValue() { + return keyValue; + } - @Column(name = "KEY_NAME", nullable = true, length = 50) - public String getKeyName() { - return keyName; - } + public void setKeyValue(String keyValue) { + this.keyValue = keyValue; + } - public void setKeyName(String keyName) { - this.keyName = keyName; - } - - - @Column(name = "KEY_VALUE", nullable = true, length = 50) - public String getKeyValue() { - return keyValue; - } - - public void setKeyValue(String keyValue) { - this.keyValue = keyValue; - } - -// @Override -// public Boolean equals(Object o) { -// if (this == o) return true; -// if (o == null || getClass() != o.getClass()) return false; -// -// MetaCrawlerInputItem that = (MetaCrawlerInputItem) o; -// -// if (id != that.id) return false; -// if (typeId != that.typeId) return false; -// if (crawlerId != that.crawlerId) return false; -// if (required != that.required) return false; -// if (desc != null ? !desc.equals(that.desc) : that.desc != null) return false; -// if (name != null ? !name.equals(that.name) : that.name != null) return false; -// if (createDate != null ? !createDate.equals(that.createDate) : that.createDate != null) return false; -// if (defaultValue != null ? !defaultValue.equals(that.defaultValue) : that.defaultValue != null) return false; -// if (pattern != null ? !pattern.equals(that.pattern) : that.pattern != null) return false; -// if (keyName != null ? !keyName.equals(that.keyName) : that.keyName != null) return false; -// if (keyValue != null ? !keyValue.equals(that.keyValue) : that.keyValue != null) return false; -// -// return true; -// } -// -// @Override -// public int hashCode() { -// int result = id; -// result = 31 * result + (int) typeId; -// result = 31 * result + (int) crawlerId; -// result = 31 * result + (desc != null ? desc.hashCode() : 0); -// result = 31 * result + (name != null ? name.hashCode() : 0); -// result = 31 * result + (createDate != null ? createDate.hashCode() : 0); -// result = 31 * result + (required ? 1 : 0); -// result = 31 * result + (defaultValue != null ? defaultValue.hashCode() : 0); -// result = 31 * result + (pattern != null ? pattern.hashCode() : 0); -// result = 31 * result + (keyName != null ? keyName.hashCode() : 0); -// result = 31 * result + (keyValue != null ? keyValue.hashCode() : 0); -// return result; -// } + // @Override + // public Boolean equals(Object o) { + // if (this == o) return true; + // if (o == null || getClass() != o.getClass()) return false; + // + // MetaCrawlerInputItem that = (MetaCrawlerInputItem) o; + // + // if (id != that.id) return false; + // if (typeId != that.typeId) return false; + // if (crawlerId != that.crawlerId) return false; + // if (required != that.required) return false; + // if (desc != null ? !desc.equals(that.desc) : that.desc != null) return false; + // if (name != null ? !name.equals(that.name) : that.name != null) return false; + // if (createDate != null ? !createDate.equals(that.createDate) : + // that.createDate != null) return false; + // if (defaultValue != null ? !defaultValue.equals(that.defaultValue) : + // that.defaultValue != null) return false; + // if (pattern != null ? !pattern.equals(that.pattern) : that.pattern != null) + // return false; + // if (keyName != null ? !keyName.equals(that.keyName) : that.keyName != null) + // return false; + // if (keyValue != null ? !keyValue.equals(that.keyValue) : that.keyValue != + // null) return false; + // + // return true; + // } + // + // @Override + // public int hashCode() { + // int result = id; + // result = 31 * result + (int) typeId; + // result = 31 * result + (int) crawlerId; + // result = 31 * result + (desc != null ? desc.hashCode() : 0); + // result = 31 * result + (name != null ? name.hashCode() : 0); + // result = 31 * result + (createDate != null ? createDate.hashCode() : 0); + // result = 31 * result + (required ? 1 : 0); + // result = 31 * result + (defaultValue != null ? defaultValue.hashCode() : 0); + // result = 31 * result + (pattern != null ? pattern.hashCode() : 0); + // result = 31 * result + (keyName != null ? keyName.hashCode() : 0); + // result = 31 * result + (keyValue != null ? keyValue.hashCode() : 0); + // return result; + // } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaEmailStatus.java b/src/main/java/com/loafle/overflow/model/meta/MetaEmailStatus.java index 38a36b4..92d334f 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaEmailStatus.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaEmailStatus.java @@ -7,42 +7,42 @@ import java.util.Date; @Table(name = "META_EMAIL_STATUS", schema = "public") public class MetaEmailStatus { - private Integer id; - private String name; - private Date createDate; + private Integer id; + private String name; + private Date createDate; - public MetaEmailStatus(){} + public MetaEmailStatus() { + } - public MetaEmailStatus(Integer id) { - this.id = id; - } + public MetaEmailStatus(Integer id) { + this.id = id; + } - @Id - public Integer getId() { - return id; - } + @Id + public Integer getId() { + return id; + } - public void setId(Integer id) { - this.id = id; - } + public void setId(Integer id) { + this.id = id; + } + @Column(name = "NAME", nullable = true, length = 50) + public String getName() { + return name; + } - @Column(name = "NAME", nullable = true, length = 50) - public String getName() { - return name; - } + public void setName(String name) { + this.name = name; + } - public void setName(String name) { - this.name = name; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name="CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } - - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaHistoryType.java b/src/main/java/com/loafle/overflow/model/meta/MetaHistoryType.java index 30a8d2e..4e8179b 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaHistoryType.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaHistoryType.java @@ -9,45 +9,44 @@ import java.util.Date; @Entity @Table(name = "META_HISTORY_TYPE", schema = "public") public class MetaHistoryType { - private Integer id; - private String name; - private Date createDate; + private Integer id; + private String name; + private Date createDate; - public MetaHistoryType() { + public MetaHistoryType() { - } + } - public MetaHistoryType(Integer id) { - this.id = id; - } + public MetaHistoryType(Integer id) { + this.id = id; + } - @Id - public Integer getId() { - return id; - } + @Id + public Integer getId() { + return id; + } - public void setId(Integer id) { - this.id = id; - } + public void setId(Integer id) { + this.id = id; + } + @Column(name = "NAME", nullable = true, length = 50) + public String getName() { + return name; + } - @Column(name = "NAME", nullable = true, length = 50) - public String getName() { - return name; - } + public void setName(String name) { + this.name = name; + } - public void setName(String name) { - this.name = name; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name="CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } - - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaInfraType.java b/src/main/java/com/loafle/overflow/model/meta/MetaInfraType.java index f90b73b..437aed3 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaInfraType.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaInfraType.java @@ -9,37 +9,40 @@ import java.util.Date; @Entity @Table(name = "META_INFRA_TYPE", schema = "public") public class MetaInfraType { - private Integer id; - private String name; - private Date createDate; + private Integer id; + private String name; + private Date createDate; - @Id - public Integer getId() { - return id; - } + public MetaInfraType(Integer id) { + this.id = id; + } - public void setId(Integer id) { - this.id = id; - } + @Id + public Integer getId() { + return id; + } + public void setId(Integer id) { + this.id = id; + } - @Column(name = "NAME", nullable = true, length = 50) - public String getName() { - return name; - } + @Column(name = "NAME", nullable = true, length = 50) + public String getName() { + return name; + } - public void setName(String name) { - this.name = name; - } + public void setName(String name) { + this.name = name; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaInfraVendor.java b/src/main/java/com/loafle/overflow/model/meta/MetaInfraVendor.java index 98cd42a..00a5d6d 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaInfraVendor.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaInfraVendor.java @@ -9,98 +9,89 @@ import java.util.Date; @Entity @Table(name = "META_INFRA_VENDOR", schema = "public") public class MetaInfraVendor { - private Integer id; - private String name; - private Date createDate; - private MetaInfraType infraType; + private Integer id; + private String name; + private Date createDate; + private MetaInfraType metaInfraType; - @Id - public Integer getId() { - return id; + @Id + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + @Column(name = "NAME", nullable = true, length = 50) + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } + + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } + + @ManyToOne + @JoinColumn(name = "META_INFRA_TYPE_ID", nullable = false) + public MetaInfraType getMetaInfraType() { + return metaInfraType; + } + + public void setMetaInfraType(MetaInfraType metaInfraType) { + this.metaInfraType = metaInfraType; + } + + public static MetaInfraVendor CreateInfraVendorByOS(String osName) { + + MetaInfraVendor vendor = new MetaInfraVendor(); + + if (osName == null || osName.length() <= 0) { + vendor.setId(24); // FIXME: Unknown + return vendor; } - public void setId(Integer id) { - this.id = id; + if (osName.equals("Windows")) { + vendor.setId(26); + } else if (osName.equals("Linux")) { + vendor.setId(28); // ubuntu + } else { + vendor.setId(24); // FIXME: Unknown } + return vendor; + } - @Column(name = "NAME", nullable = true, length = 50) - public String getName() { - return name; + public static MetaInfraVendor CreateInfraVendorByPort(int portNumber) { + return null; + } + + public static MetaInfraVendor CreateInfraVendorByService(String serviceName) { + + MetaInfraVendor vendor = new MetaInfraVendor(); + + if (serviceName.equals("mysql")) { + vendor.setId(11); + } else if (serviceName.equals("portgresql")) { + vendor.setId(15); + } else if (serviceName.equals("wmi")) { + vendor.setId(23); + } else if (serviceName.equals("snmpv2")) { + vendor.setId(20); + } else { + vendor.setId(24); // unknown } - public void setName(String name) { - this.name = name; - } - - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } - - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } - - - @ManyToOne - @JoinColumn(name = "TYPE_ID", nullable=false) - public MetaInfraType getInfraType() { - return infraType; - } - - public void setInfraType(MetaInfraType infraType) { - this.infraType = infraType; - } - - - public static MetaInfraVendor CreateInfraVendorByOS(String osName) { - - MetaInfraVendor vendor = new MetaInfraVendor(); - - if(osName == null || osName.length() <= 0) { - vendor.setId(24); // FIXME: Unknown - return vendor; - } - - if(osName.equals("Windows")) { - vendor.setId(26); - } - else if(osName.equals("Linux")) { - vendor.setId(28); // ubuntu - } else { - vendor.setId(24); // FIXME: Unknown - } - - return vendor; - } - - public static MetaInfraVendor CreateInfraVendorByPort(int portNumber) { - return null; - } - - public static MetaInfraVendor CreateInfraVendorByService(String serviceName) { - - MetaInfraVendor vendor = new MetaInfraVendor(); - - if(serviceName.equals("mysql")) { - vendor.setId(11); - } - else if(serviceName.equals("portgresql")) { - vendor.setId(15); - } - else if(serviceName.equals("wmi")) { - vendor.setId(23); - } - else if(serviceName.equals("snmpv2")) { - vendor.setId(20); - } - else { - vendor.setId(24); // unknown - } - - - return vendor; - } + return vendor; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaInputType.java b/src/main/java/com/loafle/overflow/model/meta/MetaInputType.java index eb6d110..63920e4 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaInputType.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaInputType.java @@ -9,47 +9,45 @@ import java.util.Date; @Entity @Table(name = "META_INPUT_TYPE", schema = "public") public class MetaInputType { - private Short id; - private String name; - private String description; - private Date createDate; + private Short id; + private String name; + private String description; + private Date createDate; - @Id - public Short getId() { - return id; - } + @Id + public Short getId() { + return id; + } - public void setId(Short id) { - this.id = id; - } + public void setId(Short id) { + this.id = id; + } + @Column(name = "NAME", nullable = true, length = 50) + public String getName() { + return name; + } - @Column(name = "NAME", nullable = true, length = 50) - public String getName() { - return name; - } + public void setName(String name) { + this.name = name; + } - public void setName(String name) { - this.name = name; - } + @Column(name = "DESCRIPTION", nullable = true, length = 50) + public String getDescription() { + return description; + } + public void setDescription(String description) { + this.description = description; + } - @Column(name = "DESCRIPTION", nullable = true, length = 50) - public String getDescription() { - return description; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setDescription(String description) { - this.description = description; - } - - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } - - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaMemberStatus.java b/src/main/java/com/loafle/overflow/model/meta/MetaMemberStatus.java index 341c195..7ebf9e3 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaMemberStatus.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaMemberStatus.java @@ -11,34 +11,33 @@ import javax.persistence.Table; @Entity @Table(name = "META_MEMBER_STATUS", schema = "public") public class MetaMemberStatus { - private Short id; - private String name; + private Short id; + private String name; - public MetaMemberStatus() { + public MetaMemberStatus() { - } + } - public MetaMemberStatus(Short id) { - this.id = id; - } + public MetaMemberStatus(Short id) { + this.id = id; + } - @Id - public Short getId() { - return id; - } + @Id + public Short getId() { + return id; + } - public void setId(Short id) { - this.id = id; - } + public void setId(Short id) { + this.id = id; + } - - @Column(name = "Name", nullable = false, length = 10) - public String getName() { - return name; - } + @Column(name = "Name", nullable = false, length = 10) + public String getName() { + return name; + } - public void setName(String name) { - this.name = name; - } + public void setName(String name) { + this.name = name; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaNoAuthProbeStatus.java b/src/main/java/com/loafle/overflow/model/meta/MetaNoAuthProbeStatus.java index 41200da..bcdadcd 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaNoAuthProbeStatus.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaNoAuthProbeStatus.java @@ -11,33 +11,32 @@ import javax.persistence.Table; @Entity @Table(name = "META_NOAUTH_PROBE_STATUS", schema = "public") public class MetaNoAuthProbeStatus { - private Short id; - private String name; + private Short id; + private String name; - public MetaNoAuthProbeStatus() { + public MetaNoAuthProbeStatus() { - } + } - public MetaNoAuthProbeStatus(Short id) { - this.id = id; - } + public MetaNoAuthProbeStatus(Short id) { + this.id = id; + } - @Id - public Short getId() { - return id; - } + @Id + public Short getId() { + return id; + } - public void setId(Short id) { - this.id = id; - } + public void setId(Short id) { + this.id = id; + } + @Column(name = "Name", nullable = false, length = 10) + public String getName() { + return name; + } - @Column(name = "Name", nullable = false, length = 10) - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } + public void setName(String name) { + this.name = name; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaNotification.java b/src/main/java/com/loafle/overflow/model/meta/MetaNotification.java index 058dfb6..99d848d 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaNotification.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaNotification.java @@ -9,46 +9,45 @@ import java.util.Date; @Entity @Table(name = "META_NOTIFICATION", schema = "public") public class MetaNotification { - private Long id; - private Date createDate; - private String name; - private String description; + private Long id; + private Date createDate; + private String name; + private String description; - @Id - public Long getId() { - return id; - } + @Id + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } + @Column(name = "NAME", nullable = true, length = 50) + public String getName() { + return name; + } - @Column(name = "NAME", nullable = true, length = 50) - public String getName() { - return name; - } + public void setName(String name) { + this.name = name; + } - public void setName(String name) { - this.name = name; - } + @Column(name = "DESCRIPTION", nullable = true, length = 50) + public String getDescription() { + return description; + } - @Column(name = "DESCRIPTION", nullable = true, length = 50) - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } + public void setDescription(String description) { + this.description = description; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaProbeArchitecture.java b/src/main/java/com/loafle/overflow/model/meta/MetaProbeArchitecture.java index ca4264a..eb01272 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaProbeArchitecture.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaProbeArchitecture.java @@ -9,37 +9,36 @@ import java.util.Date; @Entity @Table(name = "META_PROBE_ARCHITECTURE", schema = "public") public class MetaProbeArchitecture { - private Short id; - private String architecture; - private Date createDate; + private Short id; + private String architecture; + private Date createDate; - @Id - public Short getId() { - return id; - } + @Id + public Short getId() { + return id; + } - public void setId(Short id) { - this.id = id; - } + public void setId(Short id) { + this.id = id; + } + @Column(name = "ARCHITECTURE", nullable = true, length = 10) + public String getArchitecture() { + return architecture; + } - @Column(name = "ARCHITECTURE", nullable = true, length = 10) - public String getArchitecture() { - return architecture; - } + public void setArchitecture(String architecture) { + this.architecture = architecture; + } - public void setArchitecture(String architecture) { - this.architecture = architecture; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } - - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaProbeOs.java b/src/main/java/com/loafle/overflow/model/meta/MetaProbeOs.java index 7ad05bc..eb99230 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaProbeOs.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaProbeOs.java @@ -9,37 +9,36 @@ import java.util.Date; @Entity @Table(name = "META_PROBE_OS", schema = "public") public class MetaProbeOs { - private Short id; - private String name; - private Date createDate; + private Short id; + private String name; + private Date createDate; - @Id - public Short getId() { - return id; - } + @Id + public Short getId() { + return id; + } - public void setId(Short id) { - this.id = id; - } + public void setId(Short id) { + this.id = id; + } + @Column(name = "NAME", nullable = true, length = 50) + public String getName() { + return name; + } - @Column(name = "NAME", nullable = true, length = 50) - public String getName() { - return name; - } + public void setName(String name) { + this.name = name; + } - public void setName(String name) { - this.name = name; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } - - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaProbePackage.java b/src/main/java/com/loafle/overflow/model/meta/MetaProbePackage.java index 0c33ec7..a676425 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaProbePackage.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaProbePackage.java @@ -9,60 +9,60 @@ import java.util.Date; @Entity @Table(name = "META_PROBE_PACKAGE", schema = "public") public class MetaProbePackage { - private Long id; - private MetaProbeVersion version; - private MetaProbeOs os; - private MetaProbeArchitecture architecture; - private Date createDate; + private Long id; + private MetaProbeVersion metaProbeVersion; + private MetaProbeOs metaProbeOs; + private MetaProbeArchitecture metaProbeArchitecture; + private Date createDate; - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @ManyToOne - @JoinColumn(name = "VERSION_ID", nullable = false) - public MetaProbeVersion getVersion() { - return version; - } + @ManyToOne + @JoinColumn(name = "META_PROBE_VERSION_ID", nullable = false) + public MetaProbeVersion getMetaProbeVersion() { + return metaProbeVersion; + } - public void setVersion(MetaProbeVersion version) { - this.version = version; - } + public void setMetaProbeVersion(MetaProbeVersion metaProbeVersion) { + this.metaProbeVersion = metaProbeVersion; + } - @ManyToOne - @JoinColumn(name = "OS_ID", nullable = false) - public MetaProbeOs getOs() { - return os; - } + @ManyToOne + @JoinColumn(name = "META_PROBE_OS_ID", nullable = false) + public MetaProbeOs getMetaProbeOs() { + return metaProbeOs; + } - public void setOs(MetaProbeOs os) { - this.os = os; - } + public void setMetaProbeOs(MetaProbeOs metaProbeOs) { + this.metaProbeOs = metaProbeOs; + } - @ManyToOne - @JoinColumn(name = "ARCHITECTURE_ID", nullable = false) - public MetaProbeArchitecture getArchitecture() { - return architecture; - } + @ManyToOne + @JoinColumn(name = "META_PROBE_ARCHITECTURE_ID", nullable = false) + public MetaProbeArchitecture getMetaProbeArchitecture() { + return metaProbeArchitecture; + } - public void setArchitecture(MetaProbeArchitecture architecture) { - this.architecture = architecture; - } + public void setMetaProbeArchitecture(MetaProbeArchitecture metaProbeArchitecture) { + this.metaProbeArchitecture = metaProbeArchitecture; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaProbeStatus.java b/src/main/java/com/loafle/overflow/model/meta/MetaProbeStatus.java index 213d0bd..0948b5f 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaProbeStatus.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaProbeStatus.java @@ -11,33 +11,32 @@ import javax.persistence.Table; @Entity @Table(name = "META_PROBE_STATUS", schema = "public") public class MetaProbeStatus { - private Short id; - private String name; + private Short id; + private String name; - public MetaProbeStatus() { + public MetaProbeStatus() { - } + } - public MetaProbeStatus(Short id) { - this.id = id; - } + public MetaProbeStatus(Short id) { + this.id = id; + } - @Id - public Short getId() { - return id; - } + @Id + public Short getId() { + return id; + } - public void setId(Short id) { - this.id = id; - } + public void setId(Short id) { + this.id = id; + } + @Column(name = "Name", nullable = false, length = 10) + public String getName() { + return name; + } - @Column(name = "Name", nullable = false, length = 10) - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } + public void setName(String name) { + this.name = name; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaProbeTaskType.java b/src/main/java/com/loafle/overflow/model/meta/MetaProbeTaskType.java index b1bfaa8..b35c5d0 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaProbeTaskType.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaProbeTaskType.java @@ -9,48 +9,46 @@ import java.util.Date; @Entity @Table(name = "META_PROBE_TASK_TYPE", schema = "public") public class MetaProbeTaskType { - private Short id; - private String name; - private String description; - private Date createDate; + private Short id; + private String name; + private String description; + private Date createDate; - @Id - public Short getId() { - return id; - } + @Id + public Short getId() { + return id; + } - public void setId(Short id) { - this.id = id; - } + public void setId(Short id) { + this.id = id; + } + @Column(name = "NAME", nullable = false, length = 50) + public String getName() { + return name; + } - @Column(name = "NAME", nullable = false, length = 50) - public String getName() { - return name; - } + public void setName(String name) { + this.name = name; + } - public void setName(String name) { - this.name = name; - } + @Column(name = "DESCRIPTION", nullable = false, length = 50) + public String getDescription() { + return description; + } - @Column(name = "DESCRIPTION", nullable = false, length = 50) - public String getDescription() { - return description; - } + public void setDescription(String description) { + this.description = description; + } - public void setDescription(String description) { - this.description = description; - } - - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } - - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaProbeVersion.java b/src/main/java/com/loafle/overflow/model/meta/MetaProbeVersion.java index 11df9f9..9970104 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaProbeVersion.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaProbeVersion.java @@ -9,38 +9,37 @@ import java.util.Date; @Entity @Table(name = "META_PROBE_VERSION", schema = "public") public class MetaProbeVersion { - private Short id; - private String version; - private Date createDate; + private Short id; + private String version; + private Date createDate; - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Short getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Short getId() { + return id; + } - public void setId(Short id) { - this.id = id; - } + public void setId(Short id) { + this.id = id; + } + @Column(name = "VERSION", nullable = true, length = 10) + public String getVersion() { + return version; + } - @Column(name = "VERSION", nullable = true, length = 10) - public String getVersion() { - return version; - } + public void setVersion(String version) { + this.version = version; + } - public void setVersion(String version) { - this.version = version; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } - - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaSensorDisplayItem.java b/src/main/java/com/loafle/overflow/model/meta/MetaSensorDisplayItem.java index 2293a2c..245b843 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaSensorDisplayItem.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaSensorDisplayItem.java @@ -1,6 +1,5 @@ package com.loafle.overflow.model.meta; - import javax.persistence.*; import java.util.Date; @@ -11,109 +10,108 @@ import java.util.Date; @Table(name = "META_SENSOR_DISPLAY_ITEM", schema = "public") public class MetaSensorDisplayItem { - private Long id; - private String key; - private String displayName; - private String description; - private MetaCrawler crawler; - private MetaSensorItemUnit unit; - private Date createDate; - private Boolean isDefault; - private MetaSensorItemType itemType; + private Long id; + private String key; + private String displayName; + private String description; + private MetaCrawler metaCrawler; + private MetaSensorItemUnit metaSensorItemUnit; + private Date createDate; + private Boolean isDefault; + private MetaSensorItemType metaSensorItemType; - public MetaSensorDisplayItem() { + public MetaSensorDisplayItem() { - } - public MetaSensorDisplayItem(Long id) { - this.id = id; - } + } - @Id - public Long getId() { - return id; - } + public MetaSensorDisplayItem(Long id) { + this.id = id; + } - public void setId(Long id) { - this.id = id; - } + @Id + public Long getId() { + return id; + } - @Column(name = "KEY", nullable = false) - public String getKey() { - return key; - } + public void setId(Long id) { + this.id = id; + } - public void setKey(String key) { - this.key = key; - } + @Column(name = "KEY", nullable = false) + public String getKey() { + return key; + } - @Column(name = "DISPLAY_NAME", nullable = false) - public String getDisplayName() { - return displayName; - } + public void setKey(String key) { + this.key = key; + } - public void setDisplayName(String displayName) { - this.displayName = displayName; - } + @Column(name = "DISPLAY_NAME", nullable = false) + public String getDisplayName() { + return displayName; + } - @Column(name = "DESCRIPTION", nullable = false) - public String getDescription() { - return description; - } + public void setDisplayName(String displayName) { + this.displayName = displayName; + } - public void setDescription(String description) { - this.description = description; - } + @Column(name = "DESCRIPTION", nullable = false) + public String getDescription() { + return description; + } + public void setDescription(String description) { + this.description = description; + } - @ManyToOne - @JoinColumn(name = "CRAWLER_ID", nullable = false) - public MetaCrawler getCrawler() { - return crawler; - } + @ManyToOne + @JoinColumn(name = "META_CRAWLER_ID", nullable = false) + public MetaCrawler getMetaCrawler() { + return metaCrawler; + } - public void setCrawler(MetaCrawler crawler) { - this.crawler = crawler; - } + public void setMetaCrawler(MetaCrawler metaCrawler) { + this.metaCrawler = metaCrawler; + } - @ManyToOne - @JoinColumn(name = "UNIT_ID", nullable = true) - public MetaSensorItemUnit getUnit() { - return unit; - } + @ManyToOne + @JoinColumn(name = "META_SENSOR_ITEM_UNIT_ID", nullable = true) + public MetaSensorItemUnit getMetaSensorItemUnit() { + return metaSensorItemUnit; + } - public void setUnit(MetaSensorItemUnit unit) { - this.unit = unit; - } + public void setMetaSensorItemUnit(MetaSensorItemUnit metaSensorItemUnit) { + this.metaSensorItemUnit = metaSensorItemUnit; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name="CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } + @Basic + @Column(name = "IS_DEFAULT", nullable = false, columnDefinition = "Boolean default false") + public Boolean getDefault() { + return isDefault; + } - @Basic - @Column(name="IS_DEFAULT", nullable = false, columnDefinition = "Boolean default false") - public Boolean getDefault() { - return isDefault; - } + public void setDefault(Boolean aDefault) { + isDefault = aDefault; + } - public void setDefault(Boolean aDefault) { - isDefault = aDefault; - } + @ManyToOne + @JoinColumn(name = "META_SENSOR_ITEM_TYPE_ID", nullable = false) + public MetaSensorItemType getMetaSensorItemType() { + return metaSensorItemType; + } - @ManyToOne - @JoinColumn(name = "TYPE_ID", nullable = false) - public MetaSensorItemType getItemType() { - return itemType; - } - - public void setItemType(MetaSensorItemType itemType) { - this.itemType = itemType; - } + public void setMetaSensorItemType(MetaSensorItemType metaSensorItemType) { + this.metaSensorItemType = metaSensorItemType; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaSensorDisplayMapping.java b/src/main/java/com/loafle/overflow/model/meta/MetaSensorDisplayMapping.java index e7d2a51..a8d2f4f 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaSensorDisplayMapping.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaSensorDisplayMapping.java @@ -9,37 +9,37 @@ import javax.persistence.*; @Table(name = "META_SENSOR_DISPLAY_MAPPING", schema = "public") public class MetaSensorDisplayMapping { - private Long id; - private MetaSensorDisplayItem displayItem; - private MetaSensorItemKey itemKey; + private Long id; + private MetaSensorDisplayItem metaSensorDisplayItem; + private MetaSensorItemKey metaSensorItemKey; - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @ManyToOne - @JoinColumn(name = "DISPLAY_ITEM_ID", nullable = false) - public MetaSensorDisplayItem getDisplayItem() { - return displayItem; - } + @ManyToOne + @JoinColumn(name = "META_SENSOR_DISPLAY_ITEM_ID", nullable = false) + public MetaSensorDisplayItem getMetaSensorDisplayItem() { + return metaSensorDisplayItem; + } - public void setDisplayItem(MetaSensorDisplayItem displayItem) { - this.displayItem = displayItem; - } + public void setMetaSensorDisplayItem(MetaSensorDisplayItem metaSensorDisplayItem) { + this.metaSensorDisplayItem = metaSensorDisplayItem; + } - @ManyToOne - @JoinColumn(name = "ITEM_KEY_ID", nullable = false) - public MetaSensorItemKey getItemKey() { - return itemKey; - } + @ManyToOne + @JoinColumn(name = "META_SENSOR_ITEM_KEY_ID", nullable = false) + public MetaSensorItemKey getMetaSensorItemKey() { + return metaSensorItemKey; + } - public void setItemKey(MetaSensorItemKey itemKey) { - this.itemKey = itemKey; - } + public void setMetaSensorItemKey(MetaSensorItemKey metaSensorItemKey) { + this.metaSensorItemKey = metaSensorItemKey; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaSensorItem.java b/src/main/java/com/loafle/overflow/model/meta/MetaSensorItem.java index b6b1114..bd720aa 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaSensorItem.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaSensorItem.java @@ -9,46 +9,45 @@ import java.util.Date; @Entity @Table(name = "META_SENSOR_ITEM", schema = "public") public class MetaSensorItem { - private Integer id; - private String key; - private String name; - private Date createDate; + private Integer id; + private String key; + private String name; + private Date createDate; - @Id - public Integer getId() { - return id; - } + @Id + public Integer getId() { + return id; + } - public void setId(Integer id) { - this.id = id; - } + public void setId(Integer id) { + this.id = id; + } + @Column(name = "KEY", nullable = true, length = 100) + public String getKey() { + return key; + } - @Column(name = "KEY", nullable = true, length = 100) - public String getKey() { - return key; - } + public void setKey(String key) { + this.key = key; + } - public void setKey(String key) { - this.key = key; - } + @Column(name = "NAME", nullable = true, length = 100) + public String getName() { + return name; + } - @Column(name = "NAME", nullable = true, length = 100) - public String getName() { - return name; - } + public void setName(String name) { + this.name = name; + } - public void setName(String name) { - this.name = name; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false) + public Date getCreateDate() { + return createDate; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false) - public Date getCreateDate() { - return createDate; - } - - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaSensorItemKey.java b/src/main/java/com/loafle/overflow/model/meta/MetaSensorItemKey.java index 9383622..8c11ce7 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaSensorItemKey.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaSensorItemKey.java @@ -9,89 +9,89 @@ import java.util.Date; @Entity @Table(name = "META_SENSOR_ITEM_KEY", schema = "public") public class MetaSensorItemKey { - private Long id; - private MetaSensorItem item; - private String key; - private String froms; - private String option; - private MetaCrawler crawler; - private Date createDate; - private MetaSensorItemUnit unit; + private Long id; + private MetaSensorItem metaSensorItem; + private String key; + private String froms; + private String option; + private MetaCrawler metaCrawler; + private Date createDate; + private MetaSensorItemUnit metaSensorItemUnit; - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @ManyToOne - @JoinColumn(name = "ITEM_ID", nullable = false) - public MetaSensorItem getItem() { - return item; - } + @ManyToOne + @JoinColumn(name = "META_SENSOR_ITEM_ID", nullable = false) + public MetaSensorItem getMetaSensorItem() { + return metaSensorItem; + } - public void setItem(MetaSensorItem item) { - this.item = item; - } + public void setMetaSensorItem(MetaSensorItem metaSensorItem) { + this.metaSensorItem = metaSensorItem; + } - @Column(name = "KEY", nullable = false, length = 100) - public String getKey() { - return key; - } + @Column(name = "KEY", nullable = false, length = 100) + public String getKey() { + return key; + } - public void setKey(String key) { - this.key = key; - } + public void setKey(String key) { + this.key = key; + } - @Column(name = "FROMS", nullable = false, length = 100) - public String getFroms() { - return froms; - } + @Column(name = "FROMS", nullable = false, length = 100) + public String getFroms() { + return froms; + } - public void setFroms(String froms) { - this.froms = froms; - } + public void setFroms(String froms) { + this.froms = froms; + } - @Column(name = "OPTION_JSON", nullable = true) - public String getOption() { - return option; - } + @Column(name = "OPTION_JSON", nullable = true) + public String getOption() { + return option; + } - public void setOption(String option) { - this.option = option; - } + public void setOption(String option) { + this.option = option; + } - @ManyToOne - @JoinColumn(name = "CRAWLER_ID", nullable = false) - public MetaCrawler getCrawler() { - return crawler; - } + @ManyToOne + @JoinColumn(name = "META_CRAWLER_ID", nullable = false) + public MetaCrawler getMetaCrawler() { + return metaCrawler; + } - public void setCrawler(MetaCrawler crawler) { - this.crawler = crawler; - } + public void setMetaCrawler(MetaCrawler metaCrawler) { + this.metaCrawler = metaCrawler; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name="CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - @ManyToOne - @JoinColumn(name = "UNIT_ID", nullable = true) - public MetaSensorItemUnit getUnit() { - return unit; - } + @ManyToOne + @JoinColumn(name = "META_SENSOR_ITEM_UNIT_ID", nullable = true) + public MetaSensorItemUnit getMetaSensorItemUnit() { + return metaSensorItemUnit; + } - public void setUnit(MetaSensorItemUnit unit) { - this.unit = unit; - } + public void setMetaSensorItemUnit(MetaSensorItemUnit metaSensorItemUnit) { + this.metaSensorItemUnit = metaSensorItemUnit; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaSensorItemType.java b/src/main/java/com/loafle/overflow/model/meta/MetaSensorItemType.java index 8974b99..99000e1 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaSensorItemType.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaSensorItemType.java @@ -9,55 +9,53 @@ import java.util.Date; @Entity @Table(name = "META_SENSOR_ITEM_TYPE", schema = "public") public class MetaSensorItemType { - private Short id; - private String name; - private String description; - private Date createDate; + private Short id; + private String name; + private String description; + private Date createDate; - public MetaSensorItemType() { - } + public MetaSensorItemType() { + } - public MetaSensorItemType(Short id) { - this.id = id; - } + public MetaSensorItemType(Short id) { + this.id = id; + } - @Id - public Short getId() { - return id; - } + @Id + public Short getId() { + return id; + } - public void setId(Short id) { - this.id = id; - } + public void setId(Short id) { + this.id = id; + } + @Column(name = "NAME", nullable = true, length = 50) + public String getName() { + return name; + } - @Column(name = "NAME", nullable = true, length = 50) - public String getName() { - return name; - } + public void setName(String name) { + this.name = name; + } - public void setName(String name) { - this.name = name; - } + @Column(name = "DESCRIPTION", nullable = true, length = 50) + public String getDescription() { + return description; + } + public void setDescription(String description) { + this.description = description; + } - @Column(name = "DESCRIPTION", nullable = true, length = 50) - public String getDescription() { - return description; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false) + public Date getCreateDate() { + return createDate; + } - public void setDescription(String description) { - this.description = description; - } - - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false) - public Date getCreateDate() { - return createDate; - } - - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaSensorItemUnit.java b/src/main/java/com/loafle/overflow/model/meta/MetaSensorItemUnit.java index 29f5aec..2550684 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaSensorItemUnit.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaSensorItemUnit.java @@ -9,45 +9,45 @@ import java.util.Date; @Entity @Table(name = "META_SENSOR_ITEM_UNIT", schema = "public") public class MetaSensorItemUnit { - private Short id; - private String unit; - private Date createDate; - private String mark; + private Short id; + private String unit; + private Date createDate; + private String mark; - @Id - public Short getId() { - return id; - } + @Id + public Short getId() { + return id; + } - public void setId(Short id) { - this.id = id; - } + public void setId(Short id) { + this.id = id; + } - @Column(name = "UNIT", nullable = false) - public String getUnit() { - return unit; - } + @Column(name = "UNIT", nullable = false) + public String getUnit() { + return unit; + } - public void setUnit(String unit) { - this.unit = unit; - } + public void setUnit(String unit) { + this.unit = unit; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name="CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - @Column(name = "MARK", nullable = false) - public String getMark() { - return mark; - } + @Column(name = "MARK", nullable = false) + public String getMark() { + return mark; + } - public void setMark(String mark) { - this.mark = mark; - } + public void setMark(String mark) { + this.mark = mark; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaSensorStatus.java b/src/main/java/com/loafle/overflow/model/meta/MetaSensorStatus.java index b95d30c..dacae60 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaSensorStatus.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaSensorStatus.java @@ -11,33 +11,32 @@ import javax.persistence.Table; @Entity @Table(name = "META_SENSOR_STATUS", schema = "public") public class MetaSensorStatus { - private Short id; - private String name; + private Short id; + private String name; - public MetaSensorStatus() { + public MetaSensorStatus() { - } + } - public MetaSensorStatus(Short id) { - this.id = id; - } + public MetaSensorStatus(Short id) { + this.id = id; + } - @Id - public Short getId() { - return id; - } + @Id + public Short getId() { + return id; + } - public void setId(Short id) { - this.id = id; - } + public void setId(Short id) { + this.id = id; + } + @Column(name = "Name", nullable = false, length = 10) + public String getName() { + return name; + } - @Column(name = "Name", nullable = false, length = 10) - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } + public void setName(String name) { + this.name = name; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaVendorCrawler.java b/src/main/java/com/loafle/overflow/model/meta/MetaVendorCrawler.java index 5290f06..d0f6e1d 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaVendorCrawler.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaVendorCrawler.java @@ -9,68 +9,68 @@ import java.util.Date; @Entity @Table(name = "META_VENDOR_CRAWLER", schema = "public") public class MetaVendorCrawler { - private Integer id; - private MetaCrawler crawler; - private MetaInfraVendor infraVendor; - private Date createDate; + private Integer id; + private MetaCrawler metaCrawler; + private MetaInfraVendor metaInfraVendor; + private Date createDate; - @Id - public Integer getId() { - return id; - } + @Id + public Integer getId() { + return id; + } - public void setId(Integer id) { - this.id = id; - } + public void setId(Integer id) { + this.id = id; + } - @ManyToOne - @JoinColumn(name = "CRAWLER_ID", nullable = false) - public MetaCrawler getCrawler() { - return crawler; - } + @ManyToOne + @JoinColumn(name = "META_CRAWLER_ID", nullable = false) + public MetaCrawler getMetaCrawler() { + return metaCrawler; + } - public void setCrawler(MetaCrawler crawler) { - this.crawler = crawler; - } + public void setMetaCrawler(MetaCrawler metaCrawler) { + this.metaCrawler = metaCrawler; + } - @ManyToOne - @JoinColumn(name = "VENDOR_ID", nullable = false) - public MetaInfraVendor getInfraVendor() { - return infraVendor; - } + @ManyToOne + @JoinColumn(name = "META_INFRA_VENDOR_ID", nullable = false) + public MetaInfraVendor getMetaInfraVendor() { + return metaInfraVendor; + } - public void setInfraVendor(MetaInfraVendor infraVendor) { - this.infraVendor = infraVendor; - } + public void setMetaInfraVendor(MetaInfraVendor metaInfraVendor) { + this.metaInfraVendor = metaInfraVendor; + } - // @Basic -// @Column(name = "CRAWLER_ID", nullable = false) -// public short getCrawlerId() { -// return crawlerId; -// } -// -// public void setCrawlerId(short crawlerId) { -// this.crawlerId = crawlerId; -// } -// -// @Basic -// @Column(name = "VENDOR_ID", nullable = false) -// public int getVendorId() { -// return vendorId; -// } -// -// public void setVendorId(int vendorId) { -// this.vendorId = vendorId; -// } + // @Basic + // @Column(name = "CRAWLER_ID", nullable = false) + // public short getCrawlerId() { + // return crawlerId; + // } + // + // public void setCrawlerId(short crawlerId) { + // this.crawlerId = crawlerId; + // } + // + // @Basic + // @Column(name = "VENDOR_ID", nullable = false) + // public int getVendorId() { + // return vendorId; + // } + // + // public void setVendorId(int vendorId) { + // this.vendorId = vendorId; + // } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/MetaVendorCrawlerSensorItem.java b/src/main/java/com/loafle/overflow/model/meta/MetaVendorCrawlerSensorItem.java index db1d56b..86d43f6 100644 --- a/src/main/java/com/loafle/overflow/model/meta/MetaVendorCrawlerSensorItem.java +++ b/src/main/java/com/loafle/overflow/model/meta/MetaVendorCrawlerSensorItem.java @@ -9,83 +9,80 @@ import java.util.Date; @Entity @Table(name = "META_VENDOR_CRAWLER_SENSOR_ITEM", schema = "public") public class MetaVendorCrawlerSensorItem { - private Long id; - private String interval; - private String warnCondition; - private Date createDate; - private MetaSensorItem sensorItem; - private MetaInfraVendor vendor; - private Short crawlerId; + private Long id; + private String interval; + private String warnCondition; + private Date createDate; + private MetaSensorItem metaSensorItem; + private MetaInfraVendor metaInfraVendor; + private Short crawlerId; - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } + @Column(name = "INTERVAL", nullable = true, length = 50) + public String getInterval() { + return interval; + } - @Column(name = "INTERVAL", nullable = true, length = 50) - public String getInterval() { - return interval; - } + public void setInterval(String interval) { + this.interval = interval; + } - public void setInterval(String interval) { - this.interval = interval; - } + @Column(name = "WARN_CONDITION", nullable = true, length = 50) + public String getWarnCondition() { + return warnCondition; + } + public void setWarnCondition(String warnCondition) { + this.warnCondition = warnCondition; + } - @Column(name = "WARN_CONDITION", nullable = true, length = 50) - public String getWarnCondition() { - return warnCondition; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false) + public Date getCreateDate() { + return createDate; + } - public void setWarnCondition(String warnCondition) { - this.warnCondition = warnCondition; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false) - public Date getCreateDate() { - return createDate; - } + @ManyToOne + @JoinColumn(name = "META_SENSOR_ITEM_ID", nullable = false) + public MetaSensorItem getMetaSensorItem() { + return metaSensorItem; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setMetaSensorItem(MetaSensorItem metaSensorItem) { + this.metaSensorItem = metaSensorItem; + } + @ManyToOne + @JoinColumn(name = "VENDOR_ID", nullable = false) + public MetaInfraVendor getMetaInfraVendor() { + return metaInfraVendor; + } - @ManyToOne - @JoinColumn(name = "ITEM_ID", nullable = false) - public MetaSensorItem getSensorItem() { - return sensorItem; - } + public void setMetaInfraVendor(MetaInfraVendor metaInfraVendor) { + this.metaInfraVendor = metaInfraVendor; + } - public void setSensorItem(MetaSensorItem sensorItem) { - this.sensorItem = sensorItem; - } + @Basic + @Column(name = "CRAWLER_ID", nullable = false) + public Short getCrawlerId() { + return crawlerId; + } - @ManyToOne - @JoinColumn(name = "VENDOR_ID", nullable = false) - public MetaInfraVendor getVendor() { - return vendor; - } - - public void setVendor(MetaInfraVendor vendor) { - this.vendor = vendor; - } - - @Basic - @Column(name = "CRAWLER_ID", nullable = false) - public Short getCrawlerId() { - return crawlerId; - } - - public void setCrawlerId(Short crawlerId) { - this.crawlerId = crawlerId; - } + public void setCrawlerId(Short crawlerId) { + this.crawlerId = crawlerId; + } } diff --git a/src/main/java/com/loafle/overflow/model/meta/type/MetaCrawlerEnum.java b/src/main/java/com/loafle/overflow/model/meta/type/MetaCrawlerEnum.java index 5bccf91..0b8e32b 100644 --- a/src/main/java/com/loafle/overflow/model/meta/type/MetaCrawlerEnum.java +++ b/src/main/java/com/loafle/overflow/model/meta/type/MetaCrawlerEnum.java @@ -5,40 +5,39 @@ package com.loafle.overflow.model.meta.type; */ public enum MetaCrawlerEnum { - ACTIVEDIRECTORY_CRAWLER((short)1), - CASSANDRA_CRAWLER((short)2), - DHCP_CRAWLER((short)3), - DNS_CRAWLER((short)4), - FTP_CRAWLER((short)5), - HTTP_CRAWLER((short)6), - IMAP_CRAWLER((short)7), - LDAP_CRAWLER((short)8), - MONGODB_CRAWLER((short)9), - MSSQL_CRAWLER((short)10), - MYSQL_CRAWLER((short)11), - NETBIOS_CRAWLER((short)12), - ORACLE_CRAWLER((short)13), - POP_CRAWLER((short)14), - POSTGRESQL_CRAWLER((short)15), - REDIS_CRAWLER((short)16), - JMX_CRAWLER((short)17), - SMB_CRAWLER((short)18), - SMTP_CRAWLER((short)19), - SNMP_CRAWLER((short)20), - SSH_CRAWLER((short)21), - TELNET_CRAWLER((short)22), - WMI_CRAWLER((short)23), - UNKNOWN_CRAWLER((short)24); + ACTIVEDIRECTORY_CRAWLER((short) 1), + CASSANDRA_CRAWLER((short) 2), + DHCP_CRAWLER((short) 3), + DNS_CRAWLER((short) 4), + FTP_CRAWLER((short) 5), + HTTP_CRAWLER((short) 6), + IMAP_CRAWLER((short) 7), + LDAP_CRAWLER((short) 8), + MONGODB_CRAWLER((short) 9), + MSSQL_CRAWLER((short) 10), + MYSQL_CRAWLER((short) 11), + NETBIOS_CRAWLER((short) 12), + ORACLE_CRAWLER((short) 13), + POP_CRAWLER((short) 14), + POSTGRESQL_CRAWLER((short) 15), + REDIS_CRAWLER((short) 16), + JMX_CRAWLER((short) 17), + SMB_CRAWLER((short) 18), + SMTP_CRAWLER((short) 19), + SNMP_CRAWLER((short) 20), + SSH_CRAWLER((short) 21), + TELNET_CRAWLER((short) 22), + WMI_CRAWLER((short) 23), + UNKNOWN_CRAWLER((short) 24); + private Short value; - private Short value; + private MetaCrawlerEnum(Short value) { + this.value = value; + } - private MetaCrawlerEnum(Short value) { - this.value = value; - } - - public Short getValue() { - return this.value; - } + public Short getValue() { + return this.value; + } } diff --git a/src/main/java/com/loafle/overflow/model/noauthprobe/NoAuthProbe.java b/src/main/java/com/loafle/overflow/model/noauthprobe/NoAuthProbe.java index 0450470..e4cd30f 100644 --- a/src/main/java/com/loafle/overflow/model/noauthprobe/NoAuthProbe.java +++ b/src/main/java/com/loafle/overflow/model/noauthprobe/NoAuthProbe.java @@ -1,6 +1,5 @@ package com.loafle.overflow.model.noauthprobe; - import com.loafle.overflow.model.domain.Domain; import com.loafle.overflow.model.meta.MetaNoAuthProbeStatus; import com.loafle.overflow.model.probe.Probe; @@ -14,146 +13,154 @@ import java.util.Date; @Entity @Table(name = "NOAUTH_PROBE", schema = "public") public class NoAuthProbe { - private Long id; - private String description; - private MetaNoAuthProbeStatus status; - private String tempProbeKey; - private Date connectDate; - private String apiKey; - private Domain domain; - private Probe probe; - private String connectAddress; - private Date createDate; + private Long id; + private String description; + private MetaNoAuthProbeStatus metaNoAuthProbeStatus; + private String tempProbeKey; + private Date connectDate; + private String apiKey; + private Domain domain; + private Probe probe; + private String connectAddress; + private Date createDate; - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @Column(name = "DESCRIPTION", nullable = true, length = 1000) - public String getDescription() { - return description; - } + @Column(name = "DESCRIPTION", nullable = true, length = 1000) + public String getDescription() { + return description; + } - public void setDescription(String description) { - this.description = description; - } + public void setDescription(String description) { + this.description = description; + } - @ManyToOne - @JoinColumn(name = "STATUS", nullable = false) - public MetaNoAuthProbeStatus getStatus() { - return status; - } + @ManyToOne + @JoinColumn(name = "META_NOAUTH_PROBE_STATUS_ID", nullable = false) + public MetaNoAuthProbeStatus getMetaNoAuthProbeStatus() { + return metaNoAuthProbeStatus; + } - public void setStatus(MetaNoAuthProbeStatus status) { - this.status = status; - } + public void setMetaNoAuthProbeStatus(MetaNoAuthProbeStatus metaNoAuthProbeStatus) { + this.metaNoAuthProbeStatus = metaNoAuthProbeStatus; + } - @Column(name = "TEMP_PROBE_KEY", nullable = false, length = 50, unique = true) - public String getTempProbeKey() { - return tempProbeKey; - } + @Column(name = "TEMP_PROBE_KEY", nullable = false, length = 50, unique = true) + public String getTempProbeKey() { + return tempProbeKey; + } - public void setTempProbeKey(String tempProbeKey) { - this.tempProbeKey = tempProbeKey; - } + public void setTempProbeKey(String tempProbeKey) { + this.tempProbeKey = tempProbeKey; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - @Column(name = "API_KEY", nullable = true, length = 50) - public String getApiKey() { - return apiKey; - } + @Column(name = "API_KEY", nullable = true, length = 50) + public String getApiKey() { + return apiKey; + } - public void setApiKey(String apiKey) { - this.apiKey = apiKey; - } + public void setApiKey(String apiKey) { + this.apiKey = apiKey; + } - @ManyToOne - @JoinColumn(name = "DOMAIN_ID", nullable=false) - public Domain getDomain() { - return domain; - } + @ManyToOne + @JoinColumn(name = "DOMAIN_ID", nullable = false) + public Domain getDomain() { + return domain; + } - public void setDomain(Domain domain) { - this.domain = domain; - } + public void setDomain(Domain domain) { + this.domain = domain; + } - @ManyToOne - @JoinColumn(name = "PROBE_ID", nullable = true) - public Probe getProbe() { - return probe; - } + @ManyToOne + @JoinColumn(name = "PROBE_ID", nullable = true) + public Probe getProbe() { + return probe; + } - public void setProbe(Probe probe) { - this.probe = probe; - } + public void setProbe(Probe probe) { + this.probe = probe; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CONNECT_DATE", nullable = true) - public Date getConnectDate() { - return connectDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CONNECT_DATE", nullable = true) + public Date getConnectDate() { + return connectDate; + } - public void setConnectDate(Date connectDate) { - this.connectDate = connectDate; - } + public void setConnectDate(Date connectDate) { + this.connectDate = connectDate; + } - @Column(name = "CONNECT_ADDRESS", nullable = true, length = 50) - public String getConnectAddress() { - return connectAddress; - } + @Column(name = "CONNECT_ADDRESS", nullable = true, length = 50) + public String getConnectAddress() { + return connectAddress; + } - public void setConnectAddress(String connectAddress) { - this.connectAddress = connectAddress; - } + public void setConnectAddress(String connectAddress) { + this.connectAddress = connectAddress; + } -// @Override -// public boolean equals(Object o) { -// if (this == o) return true; -// if (o == null || getClass() != o.getClass()) return false; -// -// NoAuthProbe that = (NoAuthProbe) o; -// -// if (id != that.id) return false; -// if (domainId != that.domainId) return false; -// if (hostName != null ? !hostName.equals(that.hostName) : that.hostName != null) return false; -// if (macAddress != null ? !macAddress.equals(that.macAddress) : that.macAddress != null) return false; -// if (ipAddress != null ? !ipAddress.equals(that.ipAddress) : that.ipAddress != null) return false; -// if (status != null ? !status.equals(that.status) : that.status != null) return false; -// if (tempProbeKey != null ? !tempProbeKey.equals(that.tempProbeKey) : that.tempProbeKey != null) return false; -// if (createDate != null ? !createDate.equals(that.createDate) : that.createDate != null) return false; -// if (apiKey != null ? !apiKey.equals(that.apiKey) : that.apiKey != null) return false; -// if (probeId != null ? !probeId.equals(that.probeId) : that.probeId != null) return false; -// -// return true; -// } -// -// @Override -// public int hashCode() { -// int result = (int) (id ^ (id >>> 32)); -// result = 31 * result + (hostName != null ? hostName.hashCode() : 0); -// result = 31 * result + (macAddress != null ? macAddress.hashCode() : 0); -// result = 31 * result + (ipAddress != null ? ipAddress.hashCode() : 0); -// result = 31 * result + (status != null ? status.hashCode() : 0); -// result = 31 * result + (tempProbeKey != null ? tempProbeKey.hashCode() : 0); -// result = 31 * result + (createDate != null ? createDate.hashCode() : 0); -// result = 31 * result + (apiKey != null ? apiKey.hashCode() : 0); -// result = 31 * result + (int) (domainId ^ (domainId >>> 32)); -// result = 31 * result + (probeId != null ? probeId.hashCode() : 0); -// return result; -// } + // @Override + // public boolean equals(Object o) { + // if (this == o) return true; + // if (o == null || getClass() != o.getClass()) return false; + // + // NoAuthProbe that = (NoAuthProbe) o; + // + // if (id != that.id) return false; + // if (domainId != that.domainId) return false; + // if (hostName != null ? !hostName.equals(that.hostName) : that.hostName != + // null) return false; + // if (macAddress != null ? !macAddress.equals(that.macAddress) : + // that.macAddress != null) return false; + // if (ipAddress != null ? !ipAddress.equals(that.ipAddress) : that.ipAddress != + // null) return false; + // if (status != null ? !status.equals(that.status) : that.status != null) + // return false; + // if (tempProbeKey != null ? !tempProbeKey.equals(that.tempProbeKey) : + // that.tempProbeKey != null) return false; + // if (createDate != null ? !createDate.equals(that.createDate) : + // that.createDate != null) return false; + // if (apiKey != null ? !apiKey.equals(that.apiKey) : that.apiKey != null) + // return false; + // if (probeId != null ? !probeId.equals(that.probeId) : that.probeId != null) + // return false; + // + // return true; + // } + // + // @Override + // public int hashCode() { + // int result = (int) (id ^ (id >>> 32)); + // result = 31 * result + (hostName != null ? hostName.hashCode() : 0); + // result = 31 * result + (macAddress != null ? macAddress.hashCode() : 0); + // result = 31 * result + (ipAddress != null ? ipAddress.hashCode() : 0); + // result = 31 * result + (status != null ? status.hashCode() : 0); + // result = 31 * result + (tempProbeKey != null ? tempProbeKey.hashCode() : 0); + // result = 31 * result + (createDate != null ? createDate.hashCode() : 0); + // result = 31 * result + (apiKey != null ? apiKey.hashCode() : 0); + // result = 31 * result + (int) (domainId ^ (domainId >>> 32)); + // result = 31 * result + (probeId != null ? probeId.hashCode() : 0); + // return result; + // } } diff --git a/src/main/java/com/loafle/overflow/model/noauthprobe/NoAuthProbeDescription.java b/src/main/java/com/loafle/overflow/model/noauthprobe/NoAuthProbeDescription.java index 51b44bc..5be9291 100644 --- a/src/main/java/com/loafle/overflow/model/noauthprobe/NoAuthProbeDescription.java +++ b/src/main/java/com/loafle/overflow/model/noauthprobe/NoAuthProbeDescription.java @@ -6,24 +6,28 @@ package com.loafle.overflow.model.noauthprobe; public class NoAuthProbeDescription { private NoAuthProbeDescriptionHost host; private NoAuthProbeDescriptionNetwork network; + /** * @return the host */ public NoAuthProbeDescriptionHost getHost() { return host; } + /** * @param host the host to set */ public void setHost(NoAuthProbeDescriptionHost host) { this.host = host; } + /** * @return the network */ public NoAuthProbeDescriptionNetwork getNetwork() { return network; } + /** * @param network the network to set */ @@ -31,5 +35,4 @@ public class NoAuthProbeDescription { this.network = network; } - } \ No newline at end of file diff --git a/src/main/java/com/loafle/overflow/model/noauthprobe/NoAuthProbeDescriptionHost.java b/src/main/java/com/loafle/overflow/model/noauthprobe/NoAuthProbeDescriptionHost.java index 004a095..02a9419 100644 --- a/src/main/java/com/loafle/overflow/model/noauthprobe/NoAuthProbeDescriptionHost.java +++ b/src/main/java/com/loafle/overflow/model/noauthprobe/NoAuthProbeDescriptionHost.java @@ -13,18 +13,21 @@ public class NoAuthProbeDescriptionHost { private String platformVersion; private String kernelVersion; private String hostID; + /** * @return the name */ public String getName() { return name; } + /** * @param name the name to set */ public void setName(String name) { this.name = name; } + /** * @return the os */ @@ -32,6 +35,7 @@ public class NoAuthProbeDescriptionHost { public String getOS() { return os; } + /** * @param os the os to set */ @@ -39,60 +43,70 @@ public class NoAuthProbeDescriptionHost { public void setOS(String os) { this.os = os; } + /** * @return the platform */ public String getPlatform() { return platform; } + /** * @param platform the platform to set */ public void setPlatform(String platform) { this.platform = platform; } + /** * @return the platformFamily */ public String getPlatformFamily() { return platformFamily; } + /** * @param platformFamily the platformFamily to set */ public void setPlatformFamily(String platformFamily) { this.platformFamily = platformFamily; } + /** * @return the platformVersion */ public String getPlatformVersion() { return platformVersion; } + /** * @param platformVersion the platformVersion to set */ public void setPlatformVersion(String platformVersion) { this.platformVersion = platformVersion; } + /** * @return the kernelVersion */ public String getKernelVersion() { return kernelVersion; } + /** * @param kernelVersion the kernelVersion to set */ public void setKernelVersion(String kernelVersion) { this.kernelVersion = kernelVersion; } + /** * @return the hostID */ public String getHostID() { return hostID; } + /** * @param hostID the hostID to set */ diff --git a/src/main/java/com/loafle/overflow/model/noauthprobe/NoAuthProbeDescriptionNetwork.java b/src/main/java/com/loafle/overflow/model/noauthprobe/NoAuthProbeDescriptionNetwork.java index 3e6f1d6..c6e7802 100644 --- a/src/main/java/com/loafle/overflow/model/noauthprobe/NoAuthProbeDescriptionNetwork.java +++ b/src/main/java/com/loafle/overflow/model/noauthprobe/NoAuthProbeDescriptionNetwork.java @@ -8,48 +8,56 @@ public class NoAuthProbeDescriptionNetwork { private String address; private String gateway; private String macAddress; + /** * @return the name */ public String getName() { return name; } + /** * @param name the name to set */ public void setName(String name) { this.name = name; } + /** * @return the address */ public String getAddress() { return address; } + /** * @param address the address to set */ public void setAddress(String address) { this.address = address; } + /** * @return the gateway */ public String getGateway() { return gateway; } + /** * @param gateway the gateway to set */ public void setGateway(String gateway) { this.gateway = gateway; } + /** * @return the macAddress */ public String getMacAddress() { return macAddress; } + /** * @param macAddress the macAddress to set */ @@ -57,5 +65,4 @@ public class NoAuthProbeDescriptionNetwork { this.macAddress = macAddress; } - } \ No newline at end of file diff --git a/src/main/java/com/loafle/overflow/model/notification/Notification.java b/src/main/java/com/loafle/overflow/model/notification/Notification.java index f77386a..5705fb2 100644 --- a/src/main/java/com/loafle/overflow/model/notification/Notification.java +++ b/src/main/java/com/loafle/overflow/model/notification/Notification.java @@ -11,79 +11,78 @@ import java.util.Date; @Entity @Table(name = "NOTIFICATION", schema = "public") public class Notification { - private Long id; - private Date createDate; - private String title; - private String message; - private Member member; - private Date confirmDate; - private String url; + private Long id; + private Date createDate; + private String title; + private String message; + private Member member; + private Date confirmDate; + private String url; - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - @Column(name = "TITLE", nullable = false, length = 50) - public String getTitle() { - return title; - } + @Column(name = "TITLE", nullable = false, length = 50) + public String getTitle() { + return title; + } - public void setTitle(String title) { - this.title = title; - } + public void setTitle(String title) { + this.title = title; + } - @Column(name = "MESSAGE", nullable = false, length = 255) - public String getMessage() { - return message; - } + @Column(name = "MESSAGE", nullable = false, length = 255) + public String getMessage() { + return message; + } - public void setMessage(String message) { - this.message = message; - } + public void setMessage(String message) { + this.message = message; + } - @ManyToOne - @JoinColumn(name = "MEMBER_ID", nullable = false) - public Member getMember() { - return member; - } + @ManyToOne + @JoinColumn(name = "MEMBER_ID", nullable = false) + public Member getMember() { + return member; + } - public void setMember(Member member) { - this.member = member; - } + public void setMember(Member member) { + this.member = member; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CONFIRM_DATE", nullable = true) - public Date getConfirmDate() { - return confirmDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CONFIRM_DATE", nullable = true) + public Date getConfirmDate() { + return confirmDate; + } - public void setConfirmDate(Date confirmDate) { - this.confirmDate = confirmDate; - } + public void setConfirmDate(Date confirmDate) { + this.confirmDate = confirmDate; + } + @Column(name = "URL", nullable = false, length = 255) + public String getUrl() { + return url; + } - @Column(name = "URL", nullable = false, length = 255) - public String getUrl() { - return url; - } - - public void setUrl(String url) { - this.url = url; - } + public void setUrl(String url) { + this.url = url; + } } diff --git a/src/main/java/com/loafle/overflow/model/probe/Probe.java b/src/main/java/com/loafle/overflow/model/probe/Probe.java index ea2d05e..55165d4 100644 --- a/src/main/java/com/loafle/overflow/model/probe/Probe.java +++ b/src/main/java/com/loafle/overflow/model/probe/Probe.java @@ -4,7 +4,6 @@ import com.loafle.overflow.model.domain.Domain; import com.loafle.overflow.model.member.Member; import com.loafle.overflow.model.meta.MetaProbeStatus; - import javax.persistence.*; import java.util.Date; @@ -15,165 +14,165 @@ import java.util.Date; @Table(name = "PROBE", schema = "public") public class Probe { - private Long id; - private MetaProbeStatus status; - private String description; - private Date createDate; - private Domain domain; - private String probeKey; - private String encryptionKey; - private String displayName; - private String cidr; - private Date authorizeDate; - private Member authorizeMember; - private Integer targetCount; - private Date connectDate; - private String connectAddress; + private Long id; + private MetaProbeStatus metaProbeStatus; + private String description; + private Date createDate; + private Domain domain; + private String probeKey; + private String encryptionKey; + private String displayName; + private String cidr; + private Date authorizeDate; + private Member authorizeMember; + private Integer targetCount; + private Date connectDate; + private String connectAddress; - public Probe() { + public Probe() { - } + } - public Probe(Long id) { - this.id = id; - } + public Probe(Long id) { + this.id = id; + } - @Id - @GeneratedValue(strategy = GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @ManyToOne - @JoinColumn(name = "STATUS", nullable = false) - public MetaProbeStatus getStatus() { - return status; - } + @ManyToOne + @JoinColumn(name = "META_PROBE_STATUS_ID", nullable = false) + public MetaProbeStatus getMetaProbeStatus() { + return metaProbeStatus; + } - public void setStatus(MetaProbeStatus status) { - this.status = status; - } + public void setMetaProbeStatus(MetaProbeStatus metaProbeStatus) { + this.metaProbeStatus = metaProbeStatus; + } - @Column(name = "DESCRIPTION", nullable = true, length = 50) - public String getDescription() { - return description; - } + @Column(name = "DESCRIPTION", nullable = true, length = 50) + public String getDescription() { + return description; + } - public void setDescription(String description) { - this.description = description; - } + public void setDescription(String description) { + this.description = description; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - @ManyToOne - @JoinColumn(name = "DOMAIN_ID", nullable = false) - public Domain getDomain() { - return domain; - } + @ManyToOne + @JoinColumn(name = "DOMAIN_ID", nullable = false) + public Domain getDomain() { + return domain; + } - public void setDomain(Domain domain) { - this.domain = domain; - } + public void setDomain(Domain domain) { + this.domain = domain; + } - @Column(name = "PROBE_KEY", nullable = false, unique = true) - public String getProbeKey() { - return probeKey; - } + @Column(name = "PROBE_KEY", nullable = false, unique = true) + public String getProbeKey() { + return probeKey; + } - public void setProbeKey(String probeKey) { - this.probeKey = probeKey; - } + public void setProbeKey(String probeKey) { + this.probeKey = probeKey; + } - @Column(name = "ENCRYPTION_KEY", nullable = false, length = 100, unique = true) - public String getEncryptionKey() { - return encryptionKey; - } + @Column(name = "ENCRYPTION_KEY", nullable = false, length = 100, unique = true) + public String getEncryptionKey() { + return encryptionKey; + } - public void setEncryptionKey(String encryptionKey) { - this.encryptionKey = encryptionKey; - } + public void setEncryptionKey(String encryptionKey) { + this.encryptionKey = encryptionKey; + } - @Column(name = "DISPLAY_NAME") - public String getDisplayName() { - return displayName; - } + @Column(name = "DISPLAY_NAME") + public String getDisplayName() { + return displayName; + } - public void setDisplayName(String displayName) { - this.displayName = displayName; - } + public void setDisplayName(String displayName) { + this.displayName = displayName; + } - @Column(name = "CIDR") - public String getCidr() { - return cidr; - } + @Column(name = "CIDR") + public String getCidr() { + return cidr; + } - public void setCidr(String cidr) { - this.cidr = cidr; - } + public void setCidr(String cidr) { + this.cidr = cidr; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "AUTHORIZE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getAuthorizeDate() { - return authorizeDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "AUTHORIZE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getAuthorizeDate() { + return authorizeDate; + } - public void setAuthorizeDate(Date authorizeDate) { - this.authorizeDate = authorizeDate; - } + public void setAuthorizeDate(Date authorizeDate) { + this.authorizeDate = authorizeDate; + } - @ManyToOne - @JoinColumn(name = "AUTHORIZE_MEMBER_ID", nullable = false) - public Member getAuthorizeMember() { - return authorizeMember; - } + @ManyToOne + @JoinColumn(name = "AUTHORIZE_MEMBER_ID", nullable = false) + public Member getAuthorizeMember() { + return authorizeMember; + } - public void setAuthorizeMember(Member authorizeMember) { - this.authorizeMember = authorizeMember; - } + public void setAuthorizeMember(Member authorizeMember) { + this.authorizeMember = authorizeMember; + } - @Column(name = "TARGET_COUNT", nullable = false) - public Integer getTargetCount() { - return targetCount; - } + @Column(name = "TARGET_COUNT", nullable = false) + public Integer getTargetCount() { + return targetCount; + } - public void setTargetCount(Integer targetCount) { - this.targetCount = targetCount; - } + public void setTargetCount(Integer targetCount) { + this.targetCount = targetCount; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CONNECT_DATE", nullable = true) - public Date getConnectDate() { - return connectDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CONNECT_DATE", nullable = true) + public Date getConnectDate() { + return connectDate; + } - public void setConnectDate(Date connectDate) { - this.connectDate = connectDate; - } + public void setConnectDate(Date connectDate) { + this.connectDate = connectDate; + } - @Column(name = "CONNECT_ADDRESS", nullable = true, length = 50) - public String getConnectAddress() { - return connectAddress; - } + @Column(name = "CONNECT_ADDRESS", nullable = true, length = 50) + public String getConnectAddress() { + return connectAddress; + } - public void setConnectAddress(String connectAddress) { - this.connectAddress = connectAddress; - } + public void setConnectAddress(String connectAddress) { + this.connectAddress = connectAddress; + } - @PrePersist - void preInsert() { - this.targetCount = 0; - } + @PrePersist + void preInsert() { + this.targetCount = 0; + } } diff --git a/src/main/java/com/loafle/overflow/model/probe/ProbeHost.java b/src/main/java/com/loafle/overflow/model/probe/ProbeHost.java index 2e835e3..206398d 100644 --- a/src/main/java/com/loafle/overflow/model/probe/ProbeHost.java +++ b/src/main/java/com/loafle/overflow/model/probe/ProbeHost.java @@ -12,37 +12,37 @@ import javax.persistence.*; @Table(name = "PROBE_HOST", schema = "public") public class ProbeHost { - private Long id; - private Probe probe; - private InfraHost host; + private Long id; + private Probe probe; + private InfraHost host; - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @OneToOne - @JoinColumn(name = "PROBE_ID", nullable = false) - public Probe getProbe() { - return probe; - } + @OneToOne + @JoinColumn(name = "PROBE_ID", nullable = false) + public Probe getProbe() { + return probe; + } - public void setProbe(Probe probe) { - this.probe = probe; - } + public void setProbe(Probe probe) { + this.probe = probe; + } - @OneToOne - @JoinColumn(name = "HOST_ID", nullable = false) - public InfraHost getHost() { - return host; - } + @OneToOne + @JoinColumn(name = "HOST_ID", nullable = false) + public InfraHost getHost() { + return host; + } - public void setHost(InfraHost infraHost) { - this.host = infraHost; - } + public void setHost(InfraHost infraHost) { + this.host = infraHost; + } } diff --git a/src/main/java/com/loafle/overflow/model/probe/ProbeTask.java b/src/main/java/com/loafle/overflow/model/probe/ProbeTask.java index 1f1a0ba..386fbc5 100644 --- a/src/main/java/com/loafle/overflow/model/probe/ProbeTask.java +++ b/src/main/java/com/loafle/overflow/model/probe/ProbeTask.java @@ -1,6 +1,5 @@ package com.loafle.overflow.model.probe; - import com.loafle.overflow.model.meta.MetaProbeTaskType; import javax.persistence.*; @@ -12,132 +11,137 @@ import java.util.Date; @Entity @Table(name = "PROBE_TASK", schema = "public") public class ProbeTask { - private Long id; - private MetaProbeTaskType taskType; - private Probe probe; - private String data; - private Date createDate; - private Date sendDate; - private Date startDate; - private Date endDate; - private Boolean succeed; + private Long id; + private MetaProbeTaskType metaProbeTaskType; + private Probe probe; + private String data; + private Date createDate; + private Date sendDate; + private Date startDate; + private Date endDate; + private Boolean succeed; - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @ManyToOne - @JoinColumn(name = "TYPE_ID", nullable = false) - public MetaProbeTaskType getTaskType() { - return taskType; - } + @ManyToOne + @JoinColumn(name = "META_PROBE_TASK_TYPE_ID", nullable = false) + public MetaProbeTaskType getMetaProbeTaskType() { + return metaProbeTaskType; + } - public void setTaskType(MetaProbeTaskType taskType) { - this.taskType = taskType; - } + public void setMetaProbeTaskType(MetaProbeTaskType metaProbeTaskType) { + this.metaProbeTaskType = metaProbeTaskType; + } - @ManyToOne - @JoinColumn(name = "PROBE_ID", nullable = false) - public Probe getProbe() { - return probe; - } + @ManyToOne + @JoinColumn(name = "PROBE_ID", nullable = false) + public Probe getProbe() { + return probe; + } - public void setProbe(Probe probe) { - this.probe = probe; - } + public void setProbe(Probe probe) { + this.probe = probe; + } - @Column(name = "DATA", nullable = true, length = 255) - public String getData() { - return data; - } + @Column(name = "DATA", nullable = true, length = 255) + public String getData() { + return data; + } - public void setData(String data) { - this.data = data; - } + public void setData(String data) { + this.data = data; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - @Column(name = "SEND_DATE", nullable = true) - public Date getSendDate() { - return sendDate; - } + @Column(name = "SEND_DATE", nullable = true) + public Date getSendDate() { + return sendDate; + } - public void setSendDate(Date sendDate) { - this.sendDate = sendDate; - } + public void setSendDate(Date sendDate) { + this.sendDate = sendDate; + } - @Column(name = "START_DATE", nullable = true) - public Date getStartDate() { - return startDate; - } + @Column(name = "START_DATE", nullable = true) + public Date getStartDate() { + return startDate; + } - public void setStartDate(Date startDate) { - this.startDate = startDate; - } + public void setStartDate(Date startDate) { + this.startDate = startDate; + } - @Column(name = "END_DATE", nullable = true) - public Date getEndDate() { - return endDate; - } + @Column(name = "END_DATE", nullable = true) + public Date getEndDate() { + return endDate; + } - public void setEndDate(Date endDate) { - this.endDate = endDate; - } + public void setEndDate(Date endDate) { + this.endDate = endDate; + } - @Column(name = "SUCCEED", nullable = true) - public Boolean getSucceed() { - return succeed; - } + @Column(name = "SUCCEED", nullable = true) + public Boolean getSucceed() { + return succeed; + } - public void setSucceed(Boolean succeed) { - this.succeed = succeed; - } + public void setSucceed(Boolean succeed) { + this.succeed = succeed; + } -// @Override -// public boolean equals(Object o) { -// if (this == o) return true; -// if (o == null || getClass() != o.getClass()) return false; -// -// ProbeTask that = (ProbeTask) o; -// -// if (id != that.id) return false; -// if (typeId != that.typeId) return false; -// if (probeId != that.probeId) return false; -// if (data != null ? !data.equals(that.data) : that.data != null) return false; -// if (createDate != null ? !createDate.equals(that.createDate) : that.createDate != null) return false; -// if (sendDate != null ? !sendDate.equals(that.sendDate) : that.sendDate != null) return false; -// if (startDate != null ? !startDate.equals(that.startDate) : that.startDate != null) return false; -// if (endDate != null ? !endDate.equals(that.endDate) : that.endDate != null) return false; -// if (succeed != null ? !succeed.equals(that.succeed) : that.succeed != null) return false; -// -// return true; -// } -// -// @Override -// public int hashCode() { -// int result = (int) (id ^ (id >>> 32)); -// result = 31 * result + (int) typeId; -// result = 31 * result + (int) (probeId ^ (probeId >>> 32)); -// result = 31 * result + (data != null ? data.hashCode() : 0); -// result = 31 * result + (createDate != null ? createDate.hashCode() : 0); -// result = 31 * result + (sendDate != null ? sendDate.hashCode() : 0); -// result = 31 * result + (startDate != null ? startDate.hashCode() : 0); -// result = 31 * result + (endDate != null ? endDate.hashCode() : 0); -// result = 31 * result + (succeed != null ? succeed.hashCode() : 0); -// return result; -// } + // @Override + // public boolean equals(Object o) { + // if (this == o) return true; + // if (o == null || getClass() != o.getClass()) return false; + // + // ProbeTask that = (ProbeTask) o; + // + // if (id != that.id) return false; + // if (typeId != that.typeId) return false; + // if (probeId != that.probeId) return false; + // if (data != null ? !data.equals(that.data) : that.data != null) return false; + // if (createDate != null ? !createDate.equals(that.createDate) : + // that.createDate != null) return false; + // if (sendDate != null ? !sendDate.equals(that.sendDate) : that.sendDate != + // null) return false; + // if (startDate != null ? !startDate.equals(that.startDate) : that.startDate != + // null) return false; + // if (endDate != null ? !endDate.equals(that.endDate) : that.endDate != null) + // return false; + // if (succeed != null ? !succeed.equals(that.succeed) : that.succeed != null) + // return false; + // + // return true; + // } + // + // @Override + // public int hashCode() { + // int result = (int) (id ^ (id >>> 32)); + // result = 31 * result + (int) typeId; + // result = 31 * result + (int) (probeId ^ (probeId >>> 32)); + // result = 31 * result + (data != null ? data.hashCode() : 0); + // result = 31 * result + (createDate != null ? createDate.hashCode() : 0); + // result = 31 * result + (sendDate != null ? sendDate.hashCode() : 0); + // result = 31 * result + (startDate != null ? startDate.hashCode() : 0); + // result = 31 * result + (endDate != null ? endDate.hashCode() : 0); + // result = 31 * result + (succeed != null ? succeed.hashCode() : 0); + // return result; + // } } diff --git a/src/main/java/com/loafle/overflow/model/sensor/Sensor.java b/src/main/java/com/loafle/overflow/model/sensor/Sensor.java index 3675c40..79acf7a 100644 --- a/src/main/java/com/loafle/overflow/model/sensor/Sensor.java +++ b/src/main/java/com/loafle/overflow/model/sensor/Sensor.java @@ -17,119 +17,118 @@ import java.util.List; @Entity @Table(name = "SENSOR", schema = "public") public class Sensor { - private Long id; - private Date createDate; - private String description; - private MetaSensorStatus status; - private Target target; - private MetaCrawler crawler; - private String crawlerInputItems; - private Short itemCount = 0; - private String displayName; + private Long id; + private Date createDate; + private String description; + private MetaSensorStatus metaSensorStatus; + private Target target; + private MetaCrawler metaCrawler; + private String crawlerInputItems; + private Short itemCount = 0; + private String displayName; - // Transient property - private List sensorItems; + // Transient property + private List sensorItems; - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - @Column(name = "DESCRIPTION", nullable = true, length = 50) - public String getDescription() { - return description; - } + @Column(name = "DESCRIPTION", nullable = true, length = 50) + public String getDescription() { + return description; + } - public void setDescription(String description) { - this.description = description; - } + public void setDescription(String description) { + this.description = description; + } - @ManyToOne - @JoinColumn(name = "STATUS") - public MetaSensorStatus getStatus() { - return status; - } + @ManyToOne + @JoinColumn(name = "META_SENSOR_STATUS_ID") + public MetaSensorStatus getMetaSensorStatus() { + return metaSensorStatus; + } - public void setStatus(MetaSensorStatus status) { - this.status = status; - } + public void setMetaSensorStatus(MetaSensorStatus metaSensorStatus) { + this.metaSensorStatus = metaSensorStatus; + } - @ManyToOne - @OnDelete(action = OnDeleteAction.CASCADE) - @JoinColumn(name = "TARGET_ID", nullable = false) - public Target getTarget() { - return target; - } + @ManyToOne + @OnDelete(action = OnDeleteAction.CASCADE) + @JoinColumn(name = "TARGET_ID", nullable = false) + public Target getTarget() { + return target; + } - public void setTarget(Target target) { - this.target = target; - } + public void setTarget(Target target) { + this.target = target; + } - @ManyToOne - @JoinColumn(name = "CRAWLER_ID", nullable = false) - public MetaCrawler getCrawler() { - return crawler; - } + @ManyToOne + @JoinColumn(name = "META_CRAWLER_ID", nullable = false) + public MetaCrawler getMetaCrawler() { + return metaCrawler; + } - public void setCrawler(MetaCrawler crawler) { - this.crawler = crawler; - } + public void setMetaCrawler(MetaCrawler metaCrawler) { + this.metaCrawler = metaCrawler; + } - @Column(name = "CRAWLER_INPUT_ITEMS", nullable = true, length = 50) - public String getCrawlerInputItems() { - return crawlerInputItems; - } + @Column(name = "CRAWLER_INPUT_ITEMS", nullable = true, length = 50) + public String getCrawlerInputItems() { + return crawlerInputItems; + } - public void setCrawlerInputItems(String crawlerInputItems) { - this.crawlerInputItems = crawlerInputItems; - } + public void setCrawlerInputItems(String crawlerInputItems) { + this.crawlerInputItems = crawlerInputItems; + } - @Column(name = "ITEM_COUNT", nullable = false) - public Short getItemCount() { - return itemCount; - } + @Column(name = "ITEM_COUNT", nullable = false) + public Short getItemCount() { + return itemCount; + } - public void setItemCount(Short itemCount) { - this.itemCount = itemCount; - } + public void setItemCount(Short itemCount) { + this.itemCount = itemCount; + } - @Column(name = "DISPLAY_NAME", nullable = false, length = 50) - public String getDisplayName() { - return displayName; - } + @Column(name = "DISPLAY_NAME", nullable = false, length = 50) + public String getDisplayName() { + return displayName; + } - public void setDisplayName(String displayName) { - this.displayName = displayName; - } - - @PrePersist - void preInsert() { - this.itemCount = 0; - } + public void setDisplayName(String displayName) { + this.displayName = displayName; + } - @Transient - public List getSensorItems() { - return sensorItems; - } + @PrePersist + void preInsert() { + this.itemCount = 0; + } - public void setSensorItems(List sensorItems) { - this.sensorItems = sensorItems; - } + @Transient + public List getSensorItems() { + return sensorItems; + } + public void setSensorItems(List sensorItems) { + this.sensorItems = sensorItems; + } } diff --git a/src/main/java/com/loafle/overflow/model/sensor/SensorItem.java b/src/main/java/com/loafle/overflow/model/sensor/SensorItem.java index 28dab4c..15f38ad 100644 --- a/src/main/java/com/loafle/overflow/model/sensor/SensorItem.java +++ b/src/main/java/com/loafle/overflow/model/sensor/SensorItem.java @@ -13,50 +13,50 @@ import java.util.Date; @Entity @Table(name = "SENSOR_ITEM", schema = "public") public class SensorItem { - private Long id; - private Sensor sensor; - private MetaSensorDisplayItem item; - private Date createDate; + private Long id; + private Sensor sensor; + private MetaSensorDisplayItem metaSensorDisplayItem; + private Date createDate; - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } - @ManyToOne - @JoinColumn(name = "SENSOR_ID", nullable = false) - @OnDelete(action = OnDeleteAction.CASCADE) - public Sensor getSensor() { - return this.sensor; - } + @ManyToOne + @JoinColumn(name = "SENSOR_ID", nullable = false) + @OnDelete(action = OnDeleteAction.CASCADE) + public Sensor getSensor() { + return this.sensor; + } - public void setSensor(Sensor sensor) { - this.sensor = sensor; - } + public void setSensor(Sensor sensor) { + this.sensor = sensor; + } - @ManyToOne - @JoinColumn(name = "ITEM_ID", nullable = false) - public MetaSensorDisplayItem getItem() { - return item; - } + @ManyToOne + @JoinColumn(name = "META_SENSOR_DISPLAY_ITEM_ID", nullable = false) + public MetaSensorDisplayItem getMetaSensorDisplayItem() { + return metaSensorDisplayItem; + } - public void setItem(MetaSensorDisplayItem item) { - this.item = item; - } + public void setMetaSensorDisplayItem(MetaSensorDisplayItem metaSensorDisplayItem) { + this.metaSensorDisplayItem = metaSensorDisplayItem; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } } diff --git a/src/main/java/com/loafle/overflow/model/sensor/SensorItemDependency.java b/src/main/java/com/loafle/overflow/model/sensor/SensorItemDependency.java index 2c2d89b..8815521 100644 --- a/src/main/java/com/loafle/overflow/model/sensor/SensorItemDependency.java +++ b/src/main/java/com/loafle/overflow/model/sensor/SensorItemDependency.java @@ -11,38 +11,37 @@ import javax.persistence.*; @Entity @Table(name = "SENSOR_ITEM_DEPENDENCY", schema = "public") public class SensorItemDependency { - private Long id; - private MetaSensorDisplayItem displayItem; - private MetaSensorItemKey sensorItem; + private Long id; + private MetaSensorDisplayItem metaSensorDisplayItem; + private MetaSensorItemKey metaSensorItemKey; - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - public void setId(Long id) { - this.id = id; - } + public void setId(Long id) { + this.id = id; + } + @ManyToOne + @JoinColumn(name = "META_SENSOR_DISPLAY_ITEM_ID", nullable = false) + public MetaSensorDisplayItem getMetaSensorDisplayItem() { + return metaSensorDisplayItem; + } - @ManyToOne - @JoinColumn(name = "DISPLAY_ITEM_ID", nullable = false) - public MetaSensorDisplayItem getDisplayItem() { - return displayItem; - } + public void setMetaSensorDisplayItem(MetaSensorDisplayItem metaSensorDisplayItem) { + this.metaSensorDisplayItem = metaSensorDisplayItem; + } - public void setDisplayItem(MetaSensorDisplayItem displayItem) { - this.displayItem = displayItem; - } + @ManyToOne + @JoinColumn(name = "META_SENSOR_ITEM_KEY_ID", nullable = false) + public MetaSensorItemKey getMetaSensorItemKey() { + return metaSensorItemKey; + } - @ManyToOne - @JoinColumn(name = "SENSOR_ITEM_ID", nullable = false) - public MetaSensorItemKey getSensorItem() { - return sensorItem; - } - - public void setSensorItem(MetaSensorItemKey sensorItem) { - this.sensorItem = sensorItem; - } + public void setMetaSensorItemKey(MetaSensorItemKey metaSensorItemKey) { + this.metaSensorItemKey = metaSensorItemKey; + } } diff --git a/src/main/java/com/loafle/overflow/model/target/Target.java b/src/main/java/com/loafle/overflow/model/target/Target.java index b7b915c..6ce4bef 100644 --- a/src/main/java/com/loafle/overflow/model/target/Target.java +++ b/src/main/java/com/loafle/overflow/model/target/Target.java @@ -15,113 +15,109 @@ import java.util.List; @Table(name = "TARGET", schema = "public") public class Target { - private Long id; - private Date createDate; - private String displayName; - private String description; - private Integer sensorCount; - private Infra infra; + private Long id; + private Date createDate; + private String displayName; + private String description; + private Integer sensorCount; + private Infra infra; - // Transient property - private List sensors; + // Transient property + private List sensors; + @Id + @GeneratedValue(strategy = GenerationType.IDENTITY) + public Long getId() { + return id; + } - @Id - @GeneratedValue(strategy= GenerationType.IDENTITY) - public Long getId() { - return id; - } + public void setId(Long id) { + this.id = id; + } - public void setId(Long id) { - this.id = id; - } + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) + public Date getCreateDate() { + return createDate; + } - @Temporal(TemporalType.TIMESTAMP) - @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) - public Date getCreateDate() { - return createDate; - } + public void setCreateDate(Date createDate) { + this.createDate = createDate; + } - public void setCreateDate(Date createDate) { - this.createDate = createDate; - } + @Column(name = "DISPLAY_NAME") + public String getDisplayName() { + return displayName; + } - @Column(name = "DISPLAY_NAME") - public String getDisplayName() { - return displayName; - } + public void setDisplayName(String displayName) { + this.displayName = displayName; + } - public void setDisplayName(String displayName) { - this.displayName = displayName; - } + @Column(name = "DESCRIPTION") + public String getDescription() { + return description; + } - @Column(name = "DESCRIPTION") - public String getDescription() { - return description; - } + public void setDescription(String description) { + this.description = description; + } - public void setDescription(String description) { - this.description = description; - } + @Column(name = "SENSOR_COUNT", nullable = false) + public Integer getSensorCount() { + return sensorCount; + } + public void setSensorCount(Integer sensorCount) { + this.sensorCount = sensorCount; + } - @Column(name = "SENSOR_COUNT", nullable = false) - public Integer getSensorCount() { - return sensorCount; - } + @Transient + public List getSensors() { + return sensors; + } - public void setSensorCount(Integer sensorCount) { - this.sensorCount = sensorCount; - } + public void setSensors(List sensors) { + this.sensors = sensors; + } - @Transient - public List getSensors() { - return sensors; - } + @PrePersist + void preInsert() { + this.sensorCount = 0; + } - public void setSensors(List sensors) { - this.sensors = sensors; - } - - @PrePersist - void preInsert() { - this.sensorCount = 0; - } + @OneToOne + @JoinColumn(name = "INFRA_ID", nullable = false) + public Infra getInfra() { + return infra; + } - @OneToOne - @JoinColumn(name = "INFRA_ID", nullable = false) - public Infra getInfra() { - return infra; - } - - /** - * @param infra the infra to set - */ - public void setInfra(Infra infra) { - this.infra = infra; - } - - -// @ManyToOne -// @JoinColumn(name = "PROBE_ID", nullable = false) -// @OnDelete(action = OnDeleteAction.CASCADE) -// public Probe getProbe() { -// return probe; -// } -// -// public void setProbe(Probe probe) { -// this.probe = probe; -// } -// -// @ManyToOne -// @JoinColumn(name = "INFRA_ID", nullable = false) -// public Infra getInfra() { -// return infra; -// } -// -// public void setInfra(Infra infra) { -// this.infra = infra; -// } + /** + * @param infra the infra to set + */ + public void setInfra(Infra infra) { + this.infra = infra; + } + // @ManyToOne + // @JoinColumn(name = "PROBE_ID", nullable = false) + // @OnDelete(action = OnDeleteAction.CASCADE) + // public Probe getProbe() { + // return probe; + // } + // + // public void setProbe(Probe probe) { + // this.probe = probe; + // } + // + // @ManyToOne + // @JoinColumn(name = "INFRA_ID", nullable = false) + // public Infra getInfra() { + // return infra; + // } + // + // public void setInfra(Infra infra) { + // this.infra = infra; + // } } diff --git a/src/main/java/com/loafle/overflow/service/central/apikey/ApiKeyService.java b/src/main/java/com/loafle/overflow/service/central/apikey/ApiKeyService.java index a63f975..2a1c182 100644 --- a/src/main/java/com/loafle/overflow/service/central/apikey/ApiKeyService.java +++ b/src/main/java/com/loafle/overflow/service/central/apikey/ApiKeyService.java @@ -8,11 +8,14 @@ import com.loafle.overflow.model.apikey.ApiKey; * Created by geek on 17. 11. 7. */ public interface ApiKeyService { - @WebappAPI - ApiKey regist(ApiKey apiKey) throws OverflowException; - @WebappAPI - ApiKey readByDomainID(Long domainID) throws OverflowException; - boolean check(String apiKey) throws OverflowException; - @WebappAPI - ApiKey readByApiKey(String apiKey) throws OverflowException; + @WebappAPI + ApiKey regist(ApiKey apiKey) throws OverflowException; + + @WebappAPI + ApiKey readByDomainID(Long domainID) throws OverflowException; + + boolean check(String apiKey) throws OverflowException; + + @WebappAPI + ApiKey readByApiKey(String apiKey) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/auth/AuthCrawlerService.java b/src/main/java/com/loafle/overflow/service/central/auth/AuthCrawlerService.java index f40544e..1859af7 100644 --- a/src/main/java/com/loafle/overflow/service/central/auth/AuthCrawlerService.java +++ b/src/main/java/com/loafle/overflow/service/central/auth/AuthCrawlerService.java @@ -4,16 +4,17 @@ import com.loafle.overflow.model.auth.AuthCrawler; import com.loafle.overflow.core.annotation.WebappAPI; import com.loafle.overflow.core.exception.OverflowException; import com.loafle.overflow.model.meta.MetaCrawler; -import com.loafle.overflow.model.target.Target; /** * Created by geek on 17. 11. 7. */ public interface AuthCrawlerService { - @WebappAPI - AuthCrawler regist(AuthCrawler authCrawler) throws OverflowException; - @WebappAPI - boolean checkAuthCrawler(Long infraId, MetaCrawler crawler, String authJson) throws OverflowException; - @WebappAPI - AuthCrawler readAuth(MetaCrawler metaCrawler, Target target) throws OverflowException; + @WebappAPI + AuthCrawler regist(AuthCrawler authCrawler) throws OverflowException; + + @WebappAPI + boolean checkAuthCrawler(Long infraId, MetaCrawler metaCrawler, String authJson) throws OverflowException; + + @WebappAPI + AuthCrawler readByMCrawlerIDAndTargetID(Short metaCrawlerID, Long targetID) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/discovery/DiscoveryService.java b/src/main/java/com/loafle/overflow/service/central/discovery/DiscoveryService.java index 1ece113..049c1dc 100644 --- a/src/main/java/com/loafle/overflow/service/central/discovery/DiscoveryService.java +++ b/src/main/java/com/loafle/overflow/service/central/discovery/DiscoveryService.java @@ -20,23 +20,34 @@ import com.loafle.overflow.model.discovery.Zone; public interface DiscoveryService { @WebappAPI void discoverZone(String probeID, DiscoverZone discoverZone) throws OverflowException; + @WebappAPI void discoverHost(String probeID, Zone zone, DiscoverHost discoverHost) throws OverflowException; + @WebappAPI void discoverPort(String probeID, Host host, DiscoverPort discoverPort) throws OverflowException; + @WebappAPI void discoverService(String probeID, Port port, DiscoverService discoverService) throws OverflowException; + @WebappAPI + void stopDiscovery(String probeID) throws OverflowException; + @ProbeAPI void discoveryStart(String requesterSessionID, Date startDate) throws OverflowException; + @ProbeAPI void discoveryStop(String requesterSessionID, Date stopDate) throws OverflowException; + @ProbeAPI void discoveredZone(String requesterSessionID, Zone zone) throws OverflowException; + @ProbeAPI void discoveredHost(String requesterSessionID, Host host) throws OverflowException; + @ProbeAPI void discoveredPort(String requesterSessionID, Port port) throws OverflowException; + @ProbeAPI void discoveredService(String requesterSessionID, Service service) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/domain/DomainMemberService.java b/src/main/java/com/loafle/overflow/service/central/domain/DomainMemberService.java index 825c3d0..a609416 100644 --- a/src/main/java/com/loafle/overflow/service/central/domain/DomainMemberService.java +++ b/src/main/java/com/loafle/overflow/service/central/domain/DomainMemberService.java @@ -14,10 +14,13 @@ import com.loafle.overflow.model.member.Member; public interface DomainMemberService { @WebappAPI void regist(DomainMember domainMember) throws OverflowException; + @WebappAPI Domain readDomainByMemberID(Long memberID) throws OverflowException; + @WebappAPI DomainMember readByMemberEmail(String email) throws OverflowException; + @WebappAPI List readAllMemberByDomainID(final Long domainID) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/history/HistoryService.java b/src/main/java/com/loafle/overflow/service/central/history/HistoryService.java index 4aaedb7..71e8bfb 100644 --- a/src/main/java/com/loafle/overflow/service/central/history/HistoryService.java +++ b/src/main/java/com/loafle/overflow/service/central/history/HistoryService.java @@ -7,15 +7,18 @@ import com.loafle.overflow.model.meta.MetaHistoryType; import org.springframework.data.domain.Page; public interface HistoryService { - // ?? - History regist(History history); + // ?? + History regist(History history); - @WebappAPI - Page readAllByProbeIDAndType(Long probeID, MetaHistoryType type, PageParams pageParams); - @WebappAPI - Page readAllByProbeID(Long probeID, PageParams pageParams); - @WebappAPI - Page readAllByDomainID(Long domainID, PageParams pageParams); - @WebappAPI - Page readAllByDomainIDAndType(Long domainID, MetaHistoryType type, PageParams pageParams); + @WebappAPI + Page readAllByProbeIDAndMetaHistoryTypeID(Long probeID, Integer metaHistoryTypeID, PageParams pageParams); + + @WebappAPI + Page readAllByProbeID(Long probeID, PageParams pageParams); + + @WebappAPI + Page readAllByDomainID(Long domainID, PageParams pageParams); + + @WebappAPI + Page readAllByDomainIDAndMetaHistoryTypeID(Long domainID, Integer metaHistoryTypeID, PageParams pageParams); } diff --git a/src/main/java/com/loafle/overflow/service/central/infra/InfraHostService.java b/src/main/java/com/loafle/overflow/service/central/infra/InfraHostService.java index 2b8b2be..ee304b6 100644 --- a/src/main/java/com/loafle/overflow/service/central/infra/InfraHostService.java +++ b/src/main/java/com/loafle/overflow/service/central/infra/InfraHostService.java @@ -9,6 +9,8 @@ import com.loafle.overflow.model.infra.InfraHost; public interface InfraHostService { InfraHost regist(InfraHost infraHost) throws OverflowException; + InfraHost read(Long id) throws OverflowException; + InfraHost readByIp(String ip) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/infra/InfraMachineService.java b/src/main/java/com/loafle/overflow/service/central/infra/InfraMachineService.java index 024423f..4bfb97b 100644 --- a/src/main/java/com/loafle/overflow/service/central/infra/InfraMachineService.java +++ b/src/main/java/com/loafle/overflow/service/central/infra/InfraMachineService.java @@ -8,5 +8,6 @@ import com.loafle.overflow.model.infra.InfraMachine; */ public interface InfraMachineService { InfraMachine regist(InfraMachine infraMachine) throws OverflowException; + InfraMachine read(Long id) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/infra/InfraOSApplicationService.java b/src/main/java/com/loafle/overflow/service/central/infra/InfraOSApplicationService.java index 490d2bb..c61fd5a 100644 --- a/src/main/java/com/loafle/overflow/service/central/infra/InfraOSApplicationService.java +++ b/src/main/java/com/loafle/overflow/service/central/infra/InfraOSApplicationService.java @@ -9,5 +9,6 @@ import com.loafle.overflow.model.infra.InfraOSApplication; public interface InfraOSApplicationService { InfraOSApplication regist(InfraOSApplication infraOSApplication) throws OverflowException; + InfraOSApplication read(Long id) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/infra/InfraOSDaemonService.java b/src/main/java/com/loafle/overflow/service/central/infra/InfraOSDaemonService.java index cdee739..3b279f1 100644 --- a/src/main/java/com/loafle/overflow/service/central/infra/InfraOSDaemonService.java +++ b/src/main/java/com/loafle/overflow/service/central/infra/InfraOSDaemonService.java @@ -9,5 +9,6 @@ import com.loafle.overflow.model.infra.InfraOSDaemon; public interface InfraOSDaemonService { InfraOSDaemon regist(InfraOSDaemon infraOSDaemon) throws OverflowException; + InfraOSDaemon read(Long id) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/infra/InfraOSPortService.java b/src/main/java/com/loafle/overflow/service/central/infra/InfraOSPortService.java index de1438a..63a28d1 100644 --- a/src/main/java/com/loafle/overflow/service/central/infra/InfraOSPortService.java +++ b/src/main/java/com/loafle/overflow/service/central/infra/InfraOSPortService.java @@ -9,6 +9,8 @@ import com.loafle.overflow.model.infra.InfraOSPort; public interface InfraOSPortService { InfraOSPort regist(InfraOSPort infraOSPort) throws OverflowException; + InfraOSPort read(Long id) throws OverflowException; - InfraOSPort readByPort(Long osId, int portNumber, String portType) throws OverflowException; + + InfraOSPort readByInfraOSIDAndPortAndPortType(Long infraOSID, Integer port, String portType) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/infra/InfraOSService.java b/src/main/java/com/loafle/overflow/service/central/infra/InfraOSService.java index bc706b8..7fd184a 100644 --- a/src/main/java/com/loafle/overflow/service/central/infra/InfraOSService.java +++ b/src/main/java/com/loafle/overflow/service/central/infra/InfraOSService.java @@ -9,5 +9,6 @@ import com.loafle.overflow.model.infra.InfraOS; public interface InfraOSService { InfraOS regist(InfraOS infraOS) throws OverflowException; + InfraOS read(Long id) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/infra/InfraService.java b/src/main/java/com/loafle/overflow/service/central/infra/InfraService.java index e596b3b..3776b73 100644 --- a/src/main/java/com/loafle/overflow/service/central/infra/InfraService.java +++ b/src/main/java/com/loafle/overflow/service/central/infra/InfraService.java @@ -16,10 +16,16 @@ import org.springframework.data.domain.Page; public interface InfraService { Infra regist(Infra infra) throws OverflowException; + Infra read(Long id) throws OverflowException; + Page readAllByProbeID(Long probeID, PageParams pageParams) throws OverflowException; + Page readAllByDomainID(Long domainID, PageParams pageParams) throws OverflowException; + List readAllTargetByDomainID(Long domainID) throws OverflowException; - List readAllTargetByProbeList(List probeList) throws OverflowException; + + List readAllTargetByProbes(List probes) throws OverflowException; + Infra readByTargetID(Long targetID) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/member/MemberService.java b/src/main/java/com/loafle/overflow/service/central/member/MemberService.java index 3063cdc..f4a0f6e 100644 --- a/src/main/java/com/loafle/overflow/service/central/member/MemberService.java +++ b/src/main/java/com/loafle/overflow/service/central/member/MemberService.java @@ -13,24 +13,34 @@ import java.util.List; public interface MemberService { @WebappAPI DomainMember signin(String signinId, String signinPw) throws OverflowException; + @WebappAPI Member signup(Member member, String pw) throws OverflowException; + @WebappAPI Member sendEmailForPassword(String email) throws OverflowException; + @WebappAPI Member resetPassword(String token, String pw) throws OverflowException; + @WebappAPI Member modify(Member member, String pw) throws OverflowException; + @WebappAPI Member forgotPassword(String signinId, String newPw) throws OverflowException; + @WebappAPI Member read(Long memberId) throws OverflowException; + @WebappAPI void withdrawal(Long memberId) throws OverflowException; + @WebappAPI List readAllByProbeKey(String probeKey) throws OverflowException; + @WebappAPI List readAllByApiKey(String apikey) throws OverflowException; + @WebappAPI List readAllByDomainID(final Long domainID) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/member/MemberTotpService.java b/src/main/java/com/loafle/overflow/service/central/member/MemberTotpService.java index 091ee30..7888896 100644 --- a/src/main/java/com/loafle/overflow/service/central/member/MemberTotpService.java +++ b/src/main/java/com/loafle/overflow/service/central/member/MemberTotpService.java @@ -12,16 +12,22 @@ import java.util.Map; public interface MemberTotpService { @WebappAPI void regist(Member member, String secretCode, String code) throws OverflowException; + @WebappAPI MemberTotp modify(MemberTotp totp) throws OverflowException; + @WebappAPI void remove(Long id) throws OverflowException; + @WebappAPI MemberTotp read(Long id) throws OverflowException; + @WebappAPI - boolean checkCodeForMember(Member member, String code) throws OverflowException; + boolean checkCodeForMember(String email, String code) throws OverflowException; + @WebappAPI boolean checkCode(String secretCode, String code) throws OverflowException; + @WebappAPI Map createTotp(Member member) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaCrawlerInputItemService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaCrawlerInputItemService.java index 5a8b76e..7a6f062 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaCrawlerInputItemService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaCrawlerInputItemService.java @@ -2,7 +2,6 @@ package com.loafle.overflow.service.central.meta; import com.loafle.overflow.core.annotation.WebappAPI; import com.loafle.overflow.core.exception.OverflowException; -import com.loafle.overflow.model.meta.MetaCrawler; import com.loafle.overflow.model.meta.MetaCrawlerInputItem; import java.util.List; @@ -12,6 +11,6 @@ import java.util.List; */ public interface MetaCrawlerInputItemService { - @WebappAPI - List readAllByMetaCrawler(MetaCrawler metaCrawler) throws OverflowException; + @WebappAPI + List readAllByMetaCrawlerID(Short metaCrawlerID) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaCrawlerService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaCrawlerService.java index ff1be50..281c576 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaCrawlerService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaCrawlerService.java @@ -11,6 +11,6 @@ import java.util.List; */ public interface MetaCrawlerService { - @WebappAPI - List readAll() throws OverflowException; + @WebappAPI + List readAll() throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaHistoryTypeService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaHistoryTypeService.java index 6c9d8c7..683d547 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaHistoryTypeService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaHistoryTypeService.java @@ -1,6 +1,5 @@ package com.loafle.overflow.service.central.meta; - import com.loafle.overflow.core.annotation.WebappAPI; import com.loafle.overflow.core.exception.OverflowException; import com.loafle.overflow.model.meta.MetaHistoryType; @@ -12,13 +11,13 @@ import java.util.List; */ public interface MetaHistoryTypeService { - @WebappAPI - List readAll() throws OverflowException; + @WebappAPI + List readAll() throws OverflowException; - @WebappAPI - MetaHistoryType regist(MetaHistoryType type) throws OverflowException; + @WebappAPI + MetaHistoryType regist(MetaHistoryType metaHistoryType) throws OverflowException; - @WebappAPI - List registAll(List types) throws OverflowException; + @WebappAPI + List registAllByMetaHistoryTypes(List metaHistoryTypes) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaInfraTypeService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaInfraTypeService.java index e17372b..70b1a01 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaInfraTypeService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaInfraTypeService.java @@ -11,6 +11,6 @@ import java.util.List; */ public interface MetaInfraTypeService { - @WebappAPI - List readAll() throws OverflowException; + @WebappAPI + List readAll() throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaInfraVendorService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaInfraVendorService.java index f723d1c..5a13efe 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaInfraVendorService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaInfraVendorService.java @@ -2,7 +2,6 @@ package com.loafle.overflow.service.central.meta; import com.loafle.overflow.core.annotation.WebappAPI; import com.loafle.overflow.core.exception.OverflowException; -import com.loafle.overflow.model.meta.MetaInfraType; import com.loafle.overflow.model.meta.MetaInfraVendor; import java.util.List; @@ -11,6 +10,6 @@ import java.util.List; * Created by snoop on 17. 7. 27. */ public interface MetaInfraVendorService { - @WebappAPI - List readAllByMetaInfraType(MetaInfraType infraType) throws OverflowException; + @WebappAPI + List readAllByMetaInfraTypeID(Integer metaInfraTypeID) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaInputTypeService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaInputTypeService.java index 9e4e3a9..b9f98c5 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaInputTypeService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaInputTypeService.java @@ -10,6 +10,6 @@ import java.util.List; * Created by snoop on 17. 7. 27. */ public interface MetaInputTypeService { - @WebappAPI - List readAll() throws OverflowException; + @WebappAPI + List readAll() throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaMemberStatusService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaMemberStatusService.java index b6a03cf..acb6533 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaMemberStatusService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaMemberStatusService.java @@ -10,6 +10,6 @@ import java.util.List; * Created by snoop on 17. 7. 27. */ public interface MetaMemberStatusService { - @WebappAPI - List readAll() throws OverflowException; + @WebappAPI + List readAll() throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaNoAuthProbeStatusService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaNoAuthProbeStatusService.java index 94bb70d..7ed4d1a 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaNoAuthProbeStatusService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaNoAuthProbeStatusService.java @@ -10,6 +10,6 @@ import java.util.List; * Created by snoop on 17. 7. 27. */ public interface MetaNoAuthProbeStatusService { - @WebappAPI - List readAll() throws OverflowException; + @WebappAPI + List readAll() throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeArchitectureService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeArchitectureService.java index 99578b3..e201bca 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeArchitectureService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeArchitectureService.java @@ -10,6 +10,6 @@ import java.util.List; * Created by snoop on 17. 7. 27. */ public interface MetaProbeArchitectureService { - @WebappAPI - List readAll() throws OverflowException; + @WebappAPI + List readAll() throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeOsService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeOsService.java index b12d7fa..a754bea 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeOsService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeOsService.java @@ -10,6 +10,6 @@ import java.util.List; * Created by snoop on 17. 7. 27. */ public interface MetaProbeOsService { - @WebappAPI - List readAll() throws OverflowException; + @WebappAPI + List readAll() throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaProbePackageService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaProbePackageService.java index 5a13f31..4f41e1b 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaProbePackageService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaProbePackageService.java @@ -11,6 +11,6 @@ import java.util.List; * Created by snoop on 17. 7. 27. */ public interface MetaProbePackageService { - @WebappAPI - List readAllByOs(MetaProbeOs metaProbeOs) throws OverflowException; + @WebappAPI + List readAllByMetaProbeOs(MetaProbeOs metaProbeOs) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeStatusService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeStatusService.java index 1c52ec8..4ecb295 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeStatusService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeStatusService.java @@ -10,7 +10,7 @@ import java.util.List; * Created by snoop on 17. 7. 27. */ public interface MetaProbeStatusService { - @WebappAPI - List readAll() throws OverflowException; + @WebappAPI + List readAll() throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeTaskTypeService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeTaskTypeService.java index c7e1097..9f42e77 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeTaskTypeService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeTaskTypeService.java @@ -10,6 +10,6 @@ import java.util.List; * Created by snoop on 17. 7. 27. */ public interface MetaProbeTaskTypeService { - @WebappAPI - List readAll() throws OverflowException; + @WebappAPI + List readAll() throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeVersionService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeVersionService.java index e6e4ea9..01defae 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeVersionService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaProbeVersionService.java @@ -10,6 +10,6 @@ import java.util.List; * Created by snoop on 17. 7. 27. */ public interface MetaProbeVersionService { - @WebappAPI - List readAll() throws OverflowException; + @WebappAPI + List readAll() throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorDisplayItemService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorDisplayItemService.java index 21ad5f1..01aa133 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorDisplayItemService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorDisplayItemService.java @@ -2,7 +2,6 @@ package com.loafle.overflow.service.central.meta; import com.loafle.overflow.core.annotation.WebappAPI; import com.loafle.overflow.core.exception.OverflowException; -import com.loafle.overflow.model.meta.MetaCrawler; import com.loafle.overflow.model.meta.MetaSensorDisplayItem; import java.util.List; @@ -12,12 +11,12 @@ import java.util.List; */ public interface MetaSensorDisplayItemService { - @WebappAPI - MetaSensorDisplayItem regist(MetaSensorDisplayItem item) throws OverflowException; + @WebappAPI + MetaSensorDisplayItem regist(MetaSensorDisplayItem metaSensorDisplayItem) throws OverflowException; - @WebappAPI - MetaSensorDisplayItem read(Long id) throws OverflowException; + @WebappAPI + MetaSensorDisplayItem read(Long id) throws OverflowException; - @WebappAPI - List readAllByCrawler(MetaCrawler crawler) throws OverflowException; + @WebappAPI + List readAllByCrawlerID(Short metaCrawlerID) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorDisplayMappingService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorDisplayMappingService.java index ab9d7ea..4d476e9 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorDisplayMappingService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorDisplayMappingService.java @@ -2,7 +2,6 @@ package com.loafle.overflow.service.central.meta; import com.loafle.overflow.core.annotation.WebappAPI; import com.loafle.overflow.core.exception.OverflowException; -import com.loafle.overflow.model.meta.MetaSensorDisplayItem; import com.loafle.overflow.model.meta.MetaSensorDisplayMapping; import com.loafle.overflow.model.meta.MetaSensorItemKey; @@ -12,9 +11,9 @@ import java.util.List; * Created by snoop on 18. 4. 24. */ public interface MetaSensorDisplayMappingService { - @WebappAPI - MetaSensorDisplayMapping regist(MetaSensorDisplayMapping m) throws OverflowException; + @WebappAPI + MetaSensorDisplayMapping regist(MetaSensorDisplayMapping metaSensorDisplayMapping) throws OverflowException; - @WebappAPI - List readAllMetaSensorItemKeyByDisplayItem(MetaSensorDisplayItem displayItem) throws OverflowException; + @WebappAPI + List readAllMetaSensorItemKeyByDisplayItemID(Long metaSensorDisplayItemID) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorItemKeyService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorItemKeyService.java index 9129c13..8263e85 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorItemKeyService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorItemKeyService.java @@ -2,7 +2,6 @@ package com.loafle.overflow.service.central.meta; import com.loafle.overflow.core.annotation.WebappAPI; import com.loafle.overflow.core.exception.OverflowException; -import com.loafle.overflow.model.meta.MetaCrawler; import com.loafle.overflow.model.meta.MetaSensorItemKey; import java.util.List; @@ -12,9 +11,9 @@ import java.util.Map; * Created by snoop on 17. 8. 29. */ public interface MetaSensorItemKeyService { - @WebappAPI - List readAllByCrawler(MetaCrawler metaCrawler) throws OverflowException; + @WebappAPI + List readAllByMetaCrawlerID(Short metaCrawlerID) throws OverflowException; - @WebappAPI - Map readAllMapByCrawler(MetaCrawler metaCrawler) throws OverflowException; + @WebappAPI + Map readAllMapByMetaCrawlerID(Short metaCrawlerID) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorItemService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorItemService.java index 349aaab..0696e85 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorItemService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorItemService.java @@ -11,7 +11,7 @@ import java.util.List; */ public interface MetaSensorItemService { - @WebappAPI - List readAll() throws OverflowException; + @WebappAPI + List readAll() throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorItemTypeService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorItemTypeService.java index 0c19ba5..10e1763 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorItemTypeService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorItemTypeService.java @@ -10,13 +10,13 @@ import java.util.List; * Created by snoop on 17. 7. 27. */ public interface MetaSensorItemTypeService { - @WebappAPI - List readAll() throws OverflowException; + @WebappAPI + List readAll() throws OverflowException; - @WebappAPI - MetaSensorItemType regist(MetaSensorItemType type) throws OverflowException; + @WebappAPI + MetaSensorItemType regist(MetaSensorItemType metaSensorItemType) throws OverflowException; - @WebappAPI - List registAll(List list) throws OverflowException; + @WebappAPI + List registAll(List metaSensorItemTypes) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorItemUnitService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorItemUnitService.java index 7e1eda6..f7f163c 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorItemUnitService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorItemUnitService.java @@ -9,6 +9,6 @@ import com.loafle.overflow.model.meta.MetaSensorItemUnit; */ public interface MetaSensorItemUnitService { - @WebappAPI - MetaSensorItemUnit regist(MetaSensorItemUnit sensorItemUnit) throws OverflowException; + @WebappAPI + MetaSensorItemUnit regist(MetaSensorItemUnit metaSensorItemUnit) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorStatusService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorStatusService.java index d767006..8704408 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorStatusService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaSensorStatusService.java @@ -11,7 +11,7 @@ import java.util.List; */ public interface MetaSensorStatusService { - @WebappAPI - List readAll() throws OverflowException; + @WebappAPI + List readAll() throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/meta/MetaVendorCrawlerService.java b/src/main/java/com/loafle/overflow/service/central/meta/MetaVendorCrawlerService.java index a6b8e15..375ade4 100644 --- a/src/main/java/com/loafle/overflow/service/central/meta/MetaVendorCrawlerService.java +++ b/src/main/java/com/loafle/overflow/service/central/meta/MetaVendorCrawlerService.java @@ -2,7 +2,6 @@ package com.loafle.overflow.service.central.meta; import com.loafle.overflow.core.annotation.WebappAPI; import com.loafle.overflow.core.exception.OverflowException; -import com.loafle.overflow.model.meta.MetaInfraVendor; import com.loafle.overflow.model.meta.MetaVendorCrawler; import java.util.List; @@ -12,9 +11,9 @@ import java.util.List; */ public interface MetaVendorCrawlerService { - @WebappAPI - List readAllByInfraVendor(MetaInfraVendor infraVendor) throws OverflowException; + @WebappAPI + List readAllByMetaInfraVendorID(Integer metaInfraVendorID) throws OverflowException; - @WebappAPI - MetaVendorCrawler regist(MetaVendorCrawler metaVendorCrawler) throws OverflowException; + @WebappAPI + MetaVendorCrawler regist(MetaVendorCrawler metaVendorCrawler) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/noauthprobe/NoAuthProbeService.java b/src/main/java/com/loafle/overflow/service/central/noauthprobe/NoAuthProbeService.java index e023e05..e4dc4ae 100644 --- a/src/main/java/com/loafle/overflow/service/central/noauthprobe/NoAuthProbeService.java +++ b/src/main/java/com/loafle/overflow/service/central/noauthprobe/NoAuthProbeService.java @@ -11,20 +11,25 @@ import java.util.List; * Created by snoop on 17. 6. 28. */ public interface NoAuthProbeService { - @ProbeAPI - NoAuthProbe regist(NoAuthProbe noAuthProbe) throws OverflowException; - @ProbeAPI - NoAuthProbe readByTempProbeKey(String tempKey) throws OverflowException; - @ProbeAPI - void onConnect(String tempKey, String connectAddress) throws OverflowException; - @ProbeAPI - void onDisconnect(String tempKey) throws OverflowException; + @ProbeAPI + NoAuthProbe regist(NoAuthProbe noAuthProbe) throws OverflowException; - @WebappAPI - List readAllByDomainID(Long id) throws OverflowException; - @WebappAPI - List acceptNoAuthProbe(Long id) throws OverflowException; - @WebappAPI - List denyNoauthProbe(Long id) throws OverflowException; + @ProbeAPI + NoAuthProbe readByTempProbeKey(String tempKey) throws OverflowException; + + @ProbeAPI + void onConnect(String tempKey, String connectAddress) throws OverflowException; + + @ProbeAPI + void onDisconnect(String tempKey) throws OverflowException; + + @WebappAPI + List readAllByDomainID(Long id) throws OverflowException; + + @WebappAPI + List acceptNoAuthProbe(Long id) throws OverflowException; + + @WebappAPI + List denyNoauthProbe(Long id) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/notification/NotificationService.java b/src/main/java/com/loafle/overflow/service/central/notification/NotificationService.java index 9956467..59ca841 100644 --- a/src/main/java/com/loafle/overflow/service/central/notification/NotificationService.java +++ b/src/main/java/com/loafle/overflow/service/central/notification/NotificationService.java @@ -6,22 +6,29 @@ import com.loafle.overflow.core.model.PageParams; import com.loafle.overflow.model.member.Member; import com.loafle.overflow.model.notification.Notification; import org.springframework.data.domain.Page; + /** * Created by insanity on 17. 8. 25. */ public interface NotificationService { - @WebappAPI - Notification regist(Notification notification) throws OverflowException; - @WebappAPI - Page readAllByMember(Member member, PageParams pageParams) throws OverflowException; - @WebappAPI - Page readAllUnconfirmedByMember(Member member, PageParams pageParams) throws OverflowException; - @WebappAPI - int readUnconfirmedCount(Member member) throws OverflowException; - @WebappAPI - Page markAllAsRead(Member member, PageParams pageParams) throws OverflowException; - @WebappAPI - Page markAllAsUnread(Member member, PageParams pageParams) throws OverflowException; - @WebappAPI - Notification markAsRead(Notification notification) throws OverflowException; + @WebappAPI + Notification regist(Notification notification) throws OverflowException; + + @WebappAPI + Page readAllByMemberEmail(String memberEmail, PageParams pageParams) throws OverflowException; + + @WebappAPI + Page readAllUnconfirmedByMemberEmail(String memberEmail, PageParams pageParams) throws OverflowException; + + @WebappAPI + int readUnconfirmedCountByMemberEmail(String memberEmail) throws OverflowException; + + @WebappAPI + Page markAllAsReadByMemberEmail(String memberEmail, PageParams pageParams) throws OverflowException; + + @WebappAPI + Page markAllAsUnreadMemberEmail(String memberEmail, PageParams pageParams) throws OverflowException; + + @WebappAPI + Notification markAsRead(Long notificationID) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/probe/ProbeHostService.java b/src/main/java/com/loafle/overflow/service/central/probe/ProbeHostService.java index 9a0b159..ed12a79 100644 --- a/src/main/java/com/loafle/overflow/service/central/probe/ProbeHostService.java +++ b/src/main/java/com/loafle/overflow/service/central/probe/ProbeHostService.java @@ -10,10 +10,12 @@ import com.loafle.overflow.model.probe.ProbeHost; * Created by snoop on 17. 8. 21. */ public interface ProbeHostService { - ProbeHost read(Long id) throws OverflowException; - ProbeHost readByProbeID(Long probeID) throws OverflowException; - ProbeHost regist(ProbeHost probeHost) throws OverflowException; - - @WebappAPI - List readAllByDomainID(Long domain) throws OverflowException; + ProbeHost read(Long id) throws OverflowException; + + ProbeHost readByProbeID(Long probeID) throws OverflowException; + + ProbeHost regist(ProbeHost probeHost) throws OverflowException; + + @WebappAPI + List readAllByDomainID(Long domain) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/probe/ProbeService.java b/src/main/java/com/loafle/overflow/service/central/probe/ProbeService.java index e805657..4e4c6a7 100644 --- a/src/main/java/com/loafle/overflow/service/central/probe/ProbeService.java +++ b/src/main/java/com/loafle/overflow/service/central/probe/ProbeService.java @@ -11,26 +11,31 @@ import java.util.List; * Created by snoop on 17. 6. 28. */ public interface ProbeService { - // NoauthProbe.acceptNoAuthProbe - Probe regist(Probe probe) throws OverflowException; - // NoauthProbe.acceptNoAuthProbe - List regist(List probes) throws OverflowException; + // NoauthProbe.acceptNoAuthProbe + Probe regist(Probe probe) throws OverflowException; - @WebappAPI - List readAllByDomainID(Long id) throws OverflowException; - @WebappAPI - Probe read(Long id) throws OverflowException; - @WebappAPI - Probe modifyDisplayName(Long probeId, String displayName) throws OverflowException; + // NoauthProbe.acceptNoAuthProbe + List regist(List probes) throws OverflowException; - @ProbeAPI //? - Probe readByProbeKey(String probeKey) throws OverflowException; - @ProbeAPI //? - Probe modify(Probe probe) throws OverflowException; + @WebappAPI + List readAllByDomainID(Long id) throws OverflowException; - @ProbeAPI - void onConnect(String probeKey, String connectAddress) throws OverflowException; - @ProbeAPI - void onDisconnect(String probeKey) throws OverflowException; + @WebappAPI + Probe read(Long id) throws OverflowException; + + @WebappAPI + Probe modifyDisplayName(Long probeId, String displayName) throws OverflowException; + + @ProbeAPI // ? + Probe readByProbeKey(String probeKey) throws OverflowException; + + @ProbeAPI // ? + Probe modify(Probe probe) throws OverflowException; + + @ProbeAPI + void onConnect(String probeKey, String connectAddress) throws OverflowException; + + @ProbeAPI + void onDisconnect(String probeKey) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/probe/ProbeTaskService.java b/src/main/java/com/loafle/overflow/service/central/probe/ProbeTaskService.java index a77ca2c..19a4c21 100644 --- a/src/main/java/com/loafle/overflow/service/central/probe/ProbeTaskService.java +++ b/src/main/java/com/loafle/overflow/service/central/probe/ProbeTaskService.java @@ -10,8 +10,9 @@ import java.util.List; * Created by snoop on 17. 6. 28. */ public interface ProbeTaskService { - @ProbeAPI - ProbeTask regist(ProbeTask probeTask) throws OverflowException; - @ProbeAPI - List readAllByProbeID(Long probeID) throws OverflowException; + @ProbeAPI + ProbeTask regist(ProbeTask probeTask) throws OverflowException; + + @ProbeAPI + List readAllByProbeID(Long probeID) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/sensor/SensorItemDependencyService.java b/src/main/java/com/loafle/overflow/service/central/sensor/SensorItemDependencyService.java index 0724b19..1f79e7d 100644 --- a/src/main/java/com/loafle/overflow/service/central/sensor/SensorItemDependencyService.java +++ b/src/main/java/com/loafle/overflow/service/central/sensor/SensorItemDependencyService.java @@ -14,11 +14,14 @@ import java.util.Map; */ public interface SensorItemDependencyService { - @WebappAPI - SensorItemDependency regist(SensorItemDependency dependency) throws OverflowException; - @WebappAPI - List readAllByDisplayItem(MetaSensorDisplayItem displayItem) throws OverflowException; - @WebappAPI - Map> readAllByDisplayItems(List displayItems) throws OverflowException; + @WebappAPI + SensorItemDependency regist(SensorItemDependency dependency) throws OverflowException; + + @WebappAPI + List readAllMetaSensorItemKeyByMetaSensorDisplayItemID(Long metaSensorDisplayItemID) throws OverflowException; + + @WebappAPI + Map> readAllMapByMetaSensorDisplayItems(List metaSensorDisplayItems) + throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/sensor/SensorItemService.java b/src/main/java/com/loafle/overflow/service/central/sensor/SensorItemService.java index 12bb86a..8f72895 100644 --- a/src/main/java/com/loafle/overflow/service/central/sensor/SensorItemService.java +++ b/src/main/java/com/loafle/overflow/service/central/sensor/SensorItemService.java @@ -3,7 +3,6 @@ package com.loafle.overflow.service.central.sensor; import com.loafle.overflow.core.annotation.WebappAPI; import com.loafle.overflow.core.exception.OverflowException; import com.loafle.overflow.core.model.PageParams; -import com.loafle.overflow.model.sensor.Sensor; import com.loafle.overflow.model.sensor.SensorItem; import org.springframework.data.domain.Page; @@ -13,14 +12,18 @@ import java.util.List; * Created by insanity on 17. 6. 28. */ public interface SensorItemService { - @WebappAPI - SensorItem regist(SensorItem sensorItem) throws OverflowException; - @WebappAPI - boolean registAll(List sensorItemList) throws OverflowException; - @WebappAPI - SensorItem read(String id) throws OverflowException; - @WebappAPI - Page readAllBySensor(Sensor sensor, PageParams pageParams) throws OverflowException; - @WebappAPI - void remove(SensorItem sensorItem) throws OverflowException; + @WebappAPI + SensorItem regist(SensorItem sensorItem) throws OverflowException; + + @WebappAPI + boolean registAll(List sensorItemList) throws OverflowException; + + @WebappAPI + SensorItem read(String id) throws OverflowException; + + @WebappAPI + Page readAllBySensorID(Long sensorID, PageParams pageParams) throws OverflowException; + + @WebappAPI + void remove(SensorItem sensorItem) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/sensor/SensorService.java b/src/main/java/com/loafle/overflow/service/central/sensor/SensorService.java index 2716989..a63fd0e 100644 --- a/src/main/java/com/loafle/overflow/service/central/sensor/SensorService.java +++ b/src/main/java/com/loafle/overflow/service/central/sensor/SensorService.java @@ -12,26 +12,34 @@ import java.util.List; /** * Created by insanity on 17. 6. 28. */ -public interface SensorService { - @WebappAPI - Sensor regist(Sensor sensor) throws OverflowException; - @WebappAPI - Sensor read(Long id) throws OverflowException; - @WebappAPI - void remove(Long id) throws OverflowException; - @WebappAPI - Sensor start(Long id) throws OverflowException; - @WebappAPI - Sensor stop(Long id) throws OverflowException; - @WebappAPI - Sensor registSensorConfig(Sensor sensor, List sensorItemList, String etcJson) throws OverflowException; - @WebappAPI - String generateSensorConfig(Sensor sensor) throws OverflowException; +public interface SensorService { + @WebappAPI + Sensor regist(Sensor sensor) throws OverflowException; - @WebappAPI - Page readAllByDomainID(Long domainID, PageParams pageParams) throws OverflowException; - @WebappAPI - Page readAllByInfraID(Long infraID, PageParams pageParams) throws OverflowException; - @WebappAPI - Page readAllByTargetID(Long targetID, PageParams pageParams) throws OverflowException; + @WebappAPI + Sensor read(Long id) throws OverflowException; + + @WebappAPI + void remove(Long id) throws OverflowException; + + @WebappAPI + Sensor start(Long id) throws OverflowException; + + @WebappAPI + Sensor stop(Long id) throws OverflowException; + + @WebappAPI + Sensor registSensorConfig(Sensor sensor, List sensorItemList, String etcJson) throws OverflowException; + + @WebappAPI + String generateSensorConfig(Sensor sensor) throws OverflowException; + + @WebappAPI + Page readAllByDomainID(Long domainID, PageParams pageParams) throws OverflowException; + + @WebappAPI + Page readAllByInfraID(Long infraID, PageParams pageParams) throws OverflowException; + + @WebappAPI + Page readAllByTargetID(Long targetID, PageParams pageParams) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/target/TargetDiscoveryService.java b/src/main/java/com/loafle/overflow/service/central/target/TargetDiscoveryService.java index 9038fa6..175a655 100644 --- a/src/main/java/com/loafle/overflow/service/central/target/TargetDiscoveryService.java +++ b/src/main/java/com/loafle/overflow/service/central/target/TargetDiscoveryService.java @@ -12,6 +12,6 @@ import java.util.List; */ public interface TargetDiscoveryService { - @WebappAPI - boolean saveAllTarget(List hosts, Probe probe) throws OverflowException; + @WebappAPI + boolean saveAllTarget(List hosts, Probe probe) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/central/target/TargetService.java b/src/main/java/com/loafle/overflow/service/central/target/TargetService.java index 0d6e9a3..b1b3205 100644 --- a/src/main/java/com/loafle/overflow/service/central/target/TargetService.java +++ b/src/main/java/com/loafle/overflow/service/central/target/TargetService.java @@ -10,14 +10,19 @@ import com.loafle.overflow.model.target.Target; */ public interface TargetService { - public Target regist(Target target, Probe probe) throws OverflowException; - public void remove(Target target, Probe probe) throws OverflowException; - public Target read(String id) throws OverflowException; - public Target increaseSensorCount(Target target) throws OverflowException; - public Target decreaseSensorCount(Target target) throws OverflowException; - - @WebappAPI - public Target modify(Target target) throws OverflowException; - @WebappAPI - void remove(Target target) throws OverflowException; + public Target regist(Target target, Probe probe) throws OverflowException; + + public void remove(Target target, Probe probe) throws OverflowException; + + public Target read(String id) throws OverflowException; + + public Target increaseSensorCount(Target target) throws OverflowException; + + public Target decreaseSensorCount(Target target) throws OverflowException; + + @WebappAPI + public Target modify(Target target) throws OverflowException; + + @WebappAPI + void remove(Target target) throws OverflowException; } diff --git a/src/main/java/com/loafle/overflow/service/container/SensorConfigService.java b/src/main/java/com/loafle/overflow/service/container/SensorConfigService.java index 70ac9e8..d43b923 100644 --- a/src/main/java/com/loafle/overflow/service/container/SensorConfigService.java +++ b/src/main/java/com/loafle/overflow/service/container/SensorConfigService.java @@ -13,10 +13,13 @@ import com.loafle.overflow.model.sensorconfig.SensorConfig; public interface SensorConfigService extends Service { @ProbeAPI void InitConfig(List sensorConfigs) throws OverflowException; + @ProbeAPI void AddConfig(SensorConfig sensorConfig) throws OverflowException; + @ProbeAPI void UpdateConfig(SensorConfig sensorConfig) throws OverflowException; + @ProbeAPI void RemoveConfig(String configID) throws OverflowException; } \ No newline at end of file