1 4 5 package org.enhydra.shark.appmappersistence; 6 7 import org.enhydra.shark.api.internal.appmappersistence.ApplicationMap; 8 9 15 public class HibernateApplicationMap implements ApplicationMap { 16 17 private String toolAgentName; 18 19 private String username; 20 21 private String password; 22 23 private String applicationName; 24 25 private Integer applicationMode; 26 27 private String processDefId; 28 29 private String packageId; 30 31 private String applicationDefinitionId; 32 33 private int id; 34 35 public HibernateApplicationMap() { 36 } 37 38 public HibernateApplicationMap(String toolAgentName, String username, 39 String password, String appName, Integer appMode) { 40 41 setToolAgentClassName(toolAgentName); 42 setUsername(username); 43 setPassword(password); 44 setApplicationName(appName); 45 setApplicationMode(appMode); 46 47 } 48 49 public String getToolAgentClassName() { 50 return toolAgentName; 51 } 52 53 public void setToolAgentClassName(String name) { 54 if (name != null && !name.trim().equals("")) 55 this.toolAgentName = name; 56 else 57 this.toolAgentName = null; 58 } 59 60 public String getPackageId() { 61 return packageId; 62 } 63 64 public void setPackageId(String packageId) { 65 if (packageId != null && !packageId.trim().equals("")) 66 this.packageId = packageId; 67 else 68 this.packageId = null; 69 } 70 71 public String getApplicationDefinitionId() { 72 return applicationDefinitionId; 73 } 74 75 public void setApplicationDefinitionId(String applicationDefinitionId) { 76 if (applicationDefinitionId != null 77 && !applicationDefinitionId.trim().equals("")) 78 this.applicationDefinitionId = applicationDefinitionId; 79 else 80 this.applicationDefinitionId = null; 81 } 82 83 public String getProcessDefinitionId() { 84 return processDefId; 85 } 86 87 public void setProcessDefinitionId(String processDefId) { 88 if (processDefId != null && !processDefId.trim().equals("")) 89 this.processDefId = processDefId; 90 else 91 this.processDefId = null; 92 } 93 94 public String getUsername() { 95 return username; 96 } 97 98 public void setUsername(String username) { 99 this.username = username; 100 } 101 102 public String getPassword() { 103 return password; 104 } 105 106 public void setPassword(String password) { 107 this.password = password; 108 } 109 110 public String getApplicationName() { 111 return applicationName; 112 } 113 114 public void setApplicationName(String appName) { 115 if (appName != null && !appName.trim().equals("")) 116 this.applicationName = appName; 117 else 118 this.applicationName = null; 119 } 120 121 public Integer getApplicationMode() { 122 return applicationMode; 123 } 124 125 public void setApplicationMode(Integer appMode) { 126 this.applicationMode = appMode; 127 } 128 129 public int getId() { 130 return id; 131 } 132 133 public void setId(int i) { 134 id = i; 135 } 136 137 public String toString() { 138 String retVal = ""; 139 retVal += "toolAgentClassName=" + toolAgentName + "\n"; 140 retVal += "username=" + username + "\n"; 141 retVal += "password=" + password + "\n"; 142 retVal += "applicationName=" + applicationName + "\n"; 143 retVal += "applicationMode=" + applicationMode + "\n"; 144 retVal += "processDefId=" + processDefId + "\n"; 145 retVal += "packageId=" + packageId + "\n"; 146 retVal += "applicationDefinitionId=" + applicationDefinitionId + "\n"; 147 return retVal; 148 } 149 } | Popular Tags |