//
This commit is contained in:
snoop 2017-06-22 19:57:41 +09:00
parent ae3babc84a
commit ed30756aa9
6 changed files with 279 additions and 279 deletions

View File

@ -1,15 +1,15 @@
package com.loafle.overflow.module.crawler.dao; //package com.loafle.overflow.module.crawler.dao;
//
import com.loafle.overflow.module.crawler.model.Crawler; //import com.loafle.overflow.module.crawler.model.Crawler;
import org.springframework.data.jpa.repository.JpaRepository; //import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository; //import org.springframework.stereotype.Repository;
//
import java.util.List; //import java.util.List;
//
/** ///**
* Created by geek@loafle.com on 17. 6. 8. // * Created by geek@loafle.com on 17. 6. 8.
*/ // */
@Repository //@Repository
public interface CrawlerDAO extends JpaRepository<Crawler, Long> { //public interface CrawlerDAO extends JpaRepository<Crawler, Long> {
// public List<Crawler> findAll(); //// public List<Crawler> findAll();
} //}

View File

@ -1,12 +1,12 @@
package com.loafle.overflow.module.crawler.dao; //package com.loafle.overflow.module.crawler.dao;
//
import com.loafle.overflow.module.crawler.model.CrawlerInputItem; //import com.loafle.overflow.module.crawler.model.CrawlerInputItem;
import org.springframework.data.jpa.repository.JpaRepository; //import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository; //import org.springframework.stereotype.Repository;
//
/** ///**
* Created by geek@loafle.com on 17. 6. 8. // * Created by geek@loafle.com on 17. 6. 8.
*/ // */
@Repository //@Repository
public interface CrawlerInputItemDAO extends JpaRepository<CrawlerInputItem, Long> { //public interface CrawlerInputItemDAO extends JpaRepository<CrawlerInputItem, Long> {
} //}

View File

@ -1,15 +1,15 @@
package com.loafle.overflow.module.crawler.dao; //package com.loafle.overflow.module.crawler.dao;
//
import com.loafle.overflow.module.crawler.model.CrawlerInputItemMapping; //import com.loafle.overflow.module.crawler.model.CrawlerInputItemMapping;
import org.springframework.data.jpa.repository.JpaRepository; //import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository; //import org.springframework.stereotype.Repository;
//
import java.util.List; //import java.util.List;
//
/** ///**
* Created by geek@loafle.com on 17. 6. 8. // * Created by geek@loafle.com on 17. 6. 8.
*/ // */
@Repository //@Repository
public interface CrawlerInputItemMappingDAO extends JpaRepository<CrawlerInputItemMapping, Long> { //public interface CrawlerInputItemMappingDAO extends JpaRepository<CrawlerInputItemMapping, Long> {
// public List<CrawlerInputItemMapping> findByCrawlerId(Crawler crawler); //// public List<CrawlerInputItemMapping> findByCrawlerId(Crawler crawler);
} //}

View File

@ -1,76 +1,76 @@
package com.loafle.overflow.module.crawler.model; //package com.loafle.overflow.module.crawler.model;
//
import javax.persistence.*; //import javax.persistence.*;
import java.io.Serializable; //import java.io.Serializable;
import java.util.Date; //import java.util.Date;
//
/** ///**
* Created by geek@loafle.com on 17. 6. 8. // * Created by geek@loafle.com on 17. 6. 8.
*/ // */
@SuppressWarnings("serial") //@SuppressWarnings("serial")
@Entity(name="CRAWLER") ////@Entity(name="CRAWLER")
public class Crawler implements Serializable { //public class Crawler implements Serializable {
//
@Id // @Id
@GeneratedValue(strategy= GenerationType.IDENTITY) // @GeneratedValue(strategy= GenerationType.IDENTITY)
private Long id; // private Long id;
//
@Column(name="NAME", nullable=false) // @Column(name="NAME", nullable=false)
private String name; // private String name;
//
@Column(name="DESCRIPTION") // @Column(name="DESCRIPTION")
private String description; // private String description;
//
@Column(name="CRAWLER_TYPE") // @Column(name="CRAWLER_TYPE")
private String crawlerType; // private String crawlerType;
//
@Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) // @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
private Date createDate; // private Date createDate;
//
public Crawler() { // public Crawler() {
} // }
//
public Crawler(Long id) { // public Crawler(Long id) {
this.id = id; // this.id = id;
} // }
//
public Long getId() { // public Long getId() {
return id; // return id;
} // }
//
public void setId(Long id) { // public void setId(Long id) {
this.id = id; // this.id = id;
} // }
//
public String getName() { // public String getName() {
return name; // return name;
} // }
//
public void setName(String name) { // public void setName(String name) {
this.name = name; // this.name = name;
} // }
//
public String getDescription() { // public String getDescription() {
return description; // return description;
} // }
//
public void setDescription(String description) { // public void setDescription(String description) {
this.description = description; // this.description = description;
} // }
//
public String getCrawlerType() { // public String getCrawlerType() {
return crawlerType; // return crawlerType;
} // }
//
public void setCrawlerType(String crawlerType) { // public void setCrawlerType(String crawlerType) {
this.crawlerType = crawlerType; // this.crawlerType = crawlerType;
} // }
//
public Date getCreateDate() { // public Date getCreateDate() {
return createDate; // return createDate;
} // }
//
public void setCreateDate(Date createDate) { // public void setCreateDate(Date createDate) {
this.createDate = createDate; // this.createDate = createDate;
} // }
} //}

View File

@ -1,75 +1,75 @@
package com.loafle.overflow.module.crawler.model; //package com.loafle.overflow.module.crawler.model;
//
import javax.persistence.*; //import javax.persistence.*;
import java.io.Serializable; //import java.io.Serializable;
import java.util.Date; //import java.util.Date;
//
/** ///**
* Created by geek@loafle.com on 17. 6. 8. // * Created by geek@loafle.com on 17. 6. 8.
*/ // */
@SuppressWarnings("serial") //@SuppressWarnings("serial")
@Entity(name="CRAWLER_INPUT_ITEM") ////@Entity(name="CRAWLER_INPUT_ITEM")
public class CrawlerInputItem implements Serializable { //public class CrawlerInputItem implements Serializable {
@Id // @Id
@GeneratedValue(strategy= GenerationType.IDENTITY) // @GeneratedValue(strategy= GenerationType.IDENTITY)
private Long id; // private Long id;
//
@Column(name = "NAME") // @Column(name = "NAME")
private String name; // private String name;
//
@Column(name = "DESCRIPTION") // @Column(name = "DESCRIPTION")
private String description; // private String description;
//
@Column(name = "DATA_TYPE") // @Column(name = "DATA_TYPE")
private String dataType; // private String dataType;
//
@Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) // @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
private Date createDate; // private Date createDate;
//
//
public CrawlerInputItem(){} // public CrawlerInputItem(){}
//
public CrawlerInputItem(Long id) { // public CrawlerInputItem(Long id) {
this.id = id; // this.id = id;
} // }
//
public Long getId() { // public Long getId() {
return id; // return id;
} // }
//
public void setId(Long id) { // public void setId(Long id) {
this.id = id; // this.id = id;
} // }
//
public String getName() { // public String getName() {
return name; // return name;
} // }
//
public void setName(String name) { // public void setName(String name) {
this.name = name; // this.name = name;
} // }
//
public String getDescription() { // public String getDescription() {
return description; // return description;
} // }
//
public void setDescription(String description) { // public void setDescription(String description) {
this.description = description; // this.description = description;
} // }
//
public String getDataType() { // public String getDataType() {
return dataType; // return dataType;
} // }
//
public void setDataType(String dataType) { // public void setDataType(String dataType) {
this.dataType = dataType; // this.dataType = dataType;
} // }
//
public Date getCreateDate() { // public Date getCreateDate() {
return createDate; // return createDate;
} // }
//
public void setCreateDate(Date createDate) { // public void setCreateDate(Date createDate) {
this.createDate = createDate; // this.createDate = createDate;
} // }
} //}

View File

@ -1,86 +1,86 @@
package com.loafle.overflow.module.crawler.model; //package com.loafle.overflow.module.crawler.model;
//
import javax.persistence.*; //import javax.persistence.*;
import java.io.Serializable; //import java.io.Serializable;
import java.util.Date; //import java.util.Date;
//
/** ///**
* Created by geek@loafle.com on 17. 6. 8. // * Created by geek@loafle.com on 17. 6. 8.
*/ // */
@SuppressWarnings("serial") //@SuppressWarnings("serial")
@Entity(name="CRAWLER_INPUT_ITEM_MAPPING") ////@Entity(name="CRAWLER_INPUT_ITEM_MAPPING")
public class CrawlerInputItemMapping implements Serializable { //public class CrawlerInputItemMapping implements Serializable {
@Id // @Id
@GeneratedValue(strategy= GenerationType.IDENTITY) // @GeneratedValue(strategy= GenerationType.IDENTITY)
private Long id; // private Long id;
//
@ManyToOne // @ManyToOne
@JoinColumn(name = "CRAWLER_ID", nullable=false) // @JoinColumn(name = "CRAWLER_ID", nullable=false)
private Crawler crawler; // private Crawler crawler;
//
@ManyToOne // @ManyToOne
@JoinColumn(name = "CRAWLER_INPUT_ITEM_ID", nullable=false) // @JoinColumn(name = "CRAWLER_INPUT_ITEM_ID", nullable=false)
private CrawlerInputItem crawlerInputItem; // private CrawlerInputItem crawlerInputItem;
//
@Column(name = "PRIORITY") // @Column(name = "PRIORITY")
private short priority; // private short priority;
//
@Column(name = "REQUIRED_TYPE") // @Column(name = "REQUIRED_TYPE")
private boolean requiredType; // private boolean requiredType;
//
@Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false) // @Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
private Date createDate; // private Date createDate;
//
public CrawlerInputItemMapping(){} // public CrawlerInputItemMapping(){}
public CrawlerInputItemMapping(Long id){ // public CrawlerInputItemMapping(Long id){
this.id = id; // this.id = id;
} // }
//
public Long getId() { // public Long getId() {
return id; // return id;
} // }
//
public void setId(Long id) { // public void setId(Long id) {
this.id = id; // this.id = id;
} // }
//
public Crawler getCrawler() { // public Crawler getCrawler() {
return crawler; // return crawler;
} // }
//
public void setCrawler(Crawler crawler) { // public void setCrawler(Crawler crawler) {
this.crawler = crawler; // this.crawler = crawler;
} // }
//
public CrawlerInputItem getCrawlerInputItem() { // public CrawlerInputItem getCrawlerInputItem() {
return crawlerInputItem; // return crawlerInputItem;
} // }
//
public void setCrawlerInputItem(CrawlerInputItem crawlerInputItem) { // public void setCrawlerInputItem(CrawlerInputItem crawlerInputItem) {
this.crawlerInputItem = crawlerInputItem; // this.crawlerInputItem = crawlerInputItem;
} // }
//
public short getPriority() { // public short getPriority() {
return priority; // return priority;
} // }
//
public void setPriority(short priority) { // public void setPriority(short priority) {
this.priority = priority; // this.priority = priority;
} // }
//
public boolean isRequiredType() { // public boolean isRequiredType() {
return requiredType; // return requiredType;
} // }
//
public void setRequiredType(boolean requiredType) { // public void setRequiredType(boolean requiredType) {
this.requiredType = requiredType; // this.requiredType = requiredType;
} // }
//
public Date getCreateDate() { // public Date getCreateDate() {
return createDate; // return createDate;
} // }
//
public void setCreateDate(Date createDate) { // public void setCreateDate(Date createDate) {
this.createDate = createDate; // this.createDate = createDate;
} // }
} //}