Coverage Report - com.ctrip.framework.apollo.biz.entity.Release
 
Classes in this File Line Coverage Branch Coverage Complexity
Release
60%
15/25
N/A
1
 
 1  
 package com.ctrip.framework.apollo.biz.entity;
 2  
 
 3  
 import com.ctrip.framework.apollo.common.entity.BaseEntity;
 4  
 
 5  
 import org.hibernate.annotations.SQLDelete;
 6  
 import org.hibernate.annotations.Where;
 7  
 
 8  
 import javax.persistence.Column;
 9  
 import javax.persistence.Entity;
 10  
 import javax.persistence.Lob;
 11  
 import javax.persistence.Table;
 12  
 
 13  
 /**
 14  
  * @author Jason Song(song_s@ctrip.com)
 15  
  */
 16  
 @Entity
 17  
 @Table(name = "Release")
 18  
 @SQLDelete(sql = "Update Release set isDeleted = 1 where id = ?")
 19  
 @Where(clause = "isDeleted = 0")
 20  2
 public class Release extends BaseEntity {
 21  
   @Column(name = "ReleaseKey", nullable = false)
 22  
   private String releaseKey;
 23  
 
 24  
   @Column(name = "Name", nullable = false)
 25  
   private String name;
 26  
 
 27  
   @Column(name = "AppId", nullable = false)
 28  
   private String appId;
 29  
 
 30  
   @Column(name = "ClusterName", nullable = false)
 31  
   private String clusterName;
 32  
 
 33  
   @Column(name = "NamespaceName", nullable = false)
 34  
   private String namespaceName;
 35  
 
 36  
   @Column(name = "Configurations", nullable = false)
 37  
   @Lob
 38  
   private String configurations;
 39  
 
 40  
   @Column(name = "Comment", nullable = false)
 41  
   private String comment;
 42  
 
 43  
   public String getReleaseKey() {
 44  1
     return releaseKey;
 45  
   }
 46  
 
 47  
   public String getAppId() {
 48  1
     return appId;
 49  
   }
 50  
 
 51  
   public String getClusterName() {
 52  1
     return clusterName;
 53  
   }
 54  
 
 55  
   public String getComment() {
 56  0
     return comment;
 57  
   }
 58  
 
 59  
   public String getConfigurations() {
 60  1
     return configurations;
 61  
   }
 62  
 
 63  
   public String getNamespaceName() {
 64  0
     return namespaceName;
 65  
   }
 66  
 
 67  
   public String getName() {
 68  0
     return name;
 69  
   }
 70  
 
 71  
   public void setReleaseKey(String releaseKey) {
 72  1
     this.releaseKey = releaseKey;
 73  1
   }
 74  
 
 75  
   public void setAppId(String appId) {
 76  1
     this.appId = appId;
 77  1
   }
 78  
 
 79  
   public void setClusterName(String clusterName) {
 80  1
     this.clusterName = clusterName;
 81  1
   }
 82  
 
 83  
   public void setComment(String comment) {
 84  0
     this.comment = comment;
 85  0
   }
 86  
 
 87  
   public void setConfigurations(String configurations) {
 88  1
     this.configurations = configurations;
 89  1
   }
 90  
 
 91  
   public void setNamespaceName(String namespaceName) {
 92  1
     this.namespaceName = namespaceName;
 93  1
   }
 94  
 
 95  
   public void setName(String name) {
 96  0
     this.name = name;
 97  0
   }
 98  
 
 99  
   public String toString() {
 100  0
     return toStringHelper().add("name", name).add("appId", appId).add("clusterName", clusterName)
 101  0
         .add("namespaceName", namespaceName).add("configurations", configurations)
 102  0
         .add("comment", comment).toString();
 103  
   }
 104  
 }