1 64 65 70 package com.jcorporate.expresso.services.html; 71 72 73 82 public class ReportPageParam { 83 private String paramCode = null; 84 private String paramDescrip = null; 85 private String paramType = null; 86 private String paramDefaultValue = null; 87 private String thisClass = (getClass().getName() + "."); 88 89 92 public ReportPageParam() { 93 } 94 95 104 public ReportPageParam(String newCode, String newDescrip, String newType, 105 String newDefaultValue) 106 throws HtmlException { 107 String myName = (thisClass + 108 "ReportPageParam(String, String" + 109 ", String, String)"); 110 111 if (newCode == null) { 112 throw new HtmlException(myName + ":Parameter code cannot be null"); 113 } 114 115 paramCode = newCode; 116 117 if (newDescrip == null) { 118 throw new HtmlException(myName + ":Description cannot be null"); 119 } 120 121 paramDescrip = newDescrip; 122 123 if (newType.equals("N") || newType.equals("C") || 124 newType.equals("D")) { 125 paramType = newType; 126 } else { 127 throw new HtmlException(myName + ":Parameter type must be " + 128 "(N)umeric, (C)haracter or (D)ate"); 129 } 130 131 paramDefaultValue = newDefaultValue; 132 } 133 134 139 public String getCode() { 140 return paramCode; 141 } 142 143 148 public String getDefaultValue() { 149 return paramDefaultValue; 150 } 151 152 157 public String getDescrip() { 158 return paramDescrip; 159 } 160 161 166 public String getType() { 167 return paramType; 168 } 169 170 } 171 | Popular Tags |