| 1 | |
|
| 2 | |
|
| 3 | |
|
| 4 | |
|
| 5 | |
|
| 6 | |
|
| 7 | |
|
| 8 | |
|
| 9 | |
|
| 10 | |
|
| 11 | |
|
| 12 | |
|
| 13 | |
|
| 14 | |
|
| 15 | |
|
| 16 | |
package org.kuali.student.contract.model; |
| 17 | |
|
| 18 | |
import java.util.ArrayList; |
| 19 | |
import java.util.List; |
| 20 | |
|
| 21 | |
|
| 22 | |
|
| 23 | |
|
| 24 | |
|
| 25 | 0 | public class OrchestrationObjectField |
| 26 | |
{ |
| 27 | |
|
| 28 | |
private OrchestrationObject parent; |
| 29 | |
private String name; |
| 30 | |
private String type; |
| 31 | |
|
| 32 | 0 | public enum FieldTypeCategory |
| 33 | |
{ |
| 34 | |
|
| 35 | 0 | PRIMITIVE, |
| 36 | 0 | MAPPED_STRING, |
| 37 | 0 | DYNAMIC_ATTRIBUTE, |
| 38 | 0 | COMPLEX, |
| 39 | 0 | COMPLEX_INLINE, |
| 40 | 0 | LIST_OF_PRIMITIVE, |
| 41 | 0 | LIST_OF_MAPPED_STRING, |
| 42 | 0 | LIST_OF_COMPLEX, |
| 43 | 0 | LIST_OF_COMPLEX_INLINE; |
| 44 | |
} |
| 45 | |
|
| 46 | |
public OrchestrationObject getParent () |
| 47 | |
{ |
| 48 | 0 | return parent; |
| 49 | |
} |
| 50 | |
|
| 51 | |
public void setParent (OrchestrationObject parent) |
| 52 | |
{ |
| 53 | 0 | this.parent = parent; |
| 54 | 0 | } |
| 55 | |
|
| 56 | |
public void setName (String name) |
| 57 | |
{ |
| 58 | 0 | this.name = name; |
| 59 | 0 | } |
| 60 | |
|
| 61 | |
public String getName () |
| 62 | |
{ |
| 63 | 0 | return name; |
| 64 | |
} |
| 65 | |
|
| 66 | |
public String getPropertyName () |
| 67 | |
{ |
| 68 | 0 | return name.substring (0, 1).toLowerCase () + name.substring (1); |
| 69 | |
} |
| 70 | |
|
| 71 | |
public String getProperName () |
| 72 | |
{ |
| 73 | 0 | return name.substring (0, 1).toUpperCase () + name.substring (1); |
| 74 | |
} |
| 75 | |
|
| 76 | |
public void setType (String type) |
| 77 | |
{ |
| 78 | 0 | this.type = type; |
| 79 | 0 | } |
| 80 | |
|
| 81 | |
public String getType () |
| 82 | |
{ |
| 83 | 0 | return type; |
| 84 | |
} |
| 85 | |
|
| 86 | |
private FieldTypeCategory fieldTypeCategory; |
| 87 | |
|
| 88 | |
public FieldTypeCategory getFieldTypeCategory () |
| 89 | |
{ |
| 90 | 0 | return fieldTypeCategory; |
| 91 | |
} |
| 92 | |
|
| 93 | |
public void setFieldTypeCategory ( |
| 94 | |
FieldTypeCategory fieldTypeCategory) |
| 95 | |
{ |
| 96 | 0 | this.fieldTypeCategory = fieldTypeCategory; |
| 97 | 0 | } |
| 98 | |
|
| 99 | |
private OrchestrationObject inlineObject; |
| 100 | |
|
| 101 | |
public OrchestrationObject getInlineObject () |
| 102 | |
{ |
| 103 | 0 | return inlineObject; |
| 104 | |
} |
| 105 | |
|
| 106 | |
public void setInlineObject (OrchestrationObject inlineObject) |
| 107 | |
{ |
| 108 | 0 | this.inlineObject = inlineObject; |
| 109 | 0 | } |
| 110 | |
|
| 111 | |
private List<TypeStateConstraint> constraints; |
| 112 | |
|
| 113 | |
public List<TypeStateConstraint> getConstraints () |
| 114 | |
{ |
| 115 | 0 | if (constraints == null) |
| 116 | |
{ |
| 117 | 0 | constraints = new ArrayList (); |
| 118 | |
} |
| 119 | 0 | return constraints; |
| 120 | |
} |
| 121 | |
|
| 122 | |
public void setConstraints (List<TypeStateConstraint> constraints) |
| 123 | |
{ |
| 124 | 0 | this.constraints = constraints; |
| 125 | 0 | } |
| 126 | |
|
| 127 | |
private String defaultValue; |
| 128 | |
|
| 129 | |
public String getDefaultValue () |
| 130 | |
{ |
| 131 | 0 | return defaultValue; |
| 132 | |
} |
| 133 | |
|
| 134 | |
public void setDefaultValue (String defaultValue) |
| 135 | |
{ |
| 136 | 0 | this.defaultValue = defaultValue; |
| 137 | 0 | } |
| 138 | |
|
| 139 | |
private String defaultValuePath; |
| 140 | |
|
| 141 | |
public String getDefaultValuePath () |
| 142 | |
{ |
| 143 | 0 | return defaultValuePath; |
| 144 | |
} |
| 145 | |
|
| 146 | |
public void setDefaultValuePath (String defaultValuePath) |
| 147 | |
{ |
| 148 | 0 | this.defaultValuePath = defaultValuePath; |
| 149 | 0 | } |
| 150 | |
|
| 151 | |
public String getFullyQualifiedName () |
| 152 | |
{ |
| 153 | |
|
| 154 | 0 | StringBuffer buf = new StringBuffer (); |
| 155 | 0 | buf.append (getParent ().getName ()); |
| 156 | 0 | buf.append ("."); |
| 157 | 0 | buf.append (getProperName ()); |
| 158 | 0 | return buf.toString (); |
| 159 | |
} |
| 160 | |
|
| 161 | 0 | public enum WriteAccess |
| 162 | |
{ |
| 163 | |
|
| 164 | 0 | ALWAYS, NEVER, ON_CREATE; |
| 165 | |
} |
| 166 | |
private WriteAccess writeAccess; |
| 167 | |
|
| 168 | |
public WriteAccess getWriteAccess () |
| 169 | |
{ |
| 170 | 0 | return writeAccess; |
| 171 | |
} |
| 172 | |
|
| 173 | |
public void setWriteAccess (WriteAccess writeAccess) |
| 174 | |
{ |
| 175 | 0 | this.writeAccess = writeAccess; |
| 176 | 0 | } |
| 177 | |
|
| 178 | |
private String lookup; |
| 179 | |
|
| 180 | |
public String getLookup () |
| 181 | |
{ |
| 182 | 0 | return lookup; |
| 183 | |
} |
| 184 | |
|
| 185 | |
public void setLookup (String lookup) |
| 186 | |
{ |
| 187 | 0 | this.lookup = lookup; |
| 188 | 0 | } |
| 189 | |
|
| 190 | |
private List<String> additionalLookups; |
| 191 | |
|
| 192 | |
public List<String> getAdditionalLookups () |
| 193 | |
{ |
| 194 | 0 | return additionalLookups; |
| 195 | |
} |
| 196 | |
|
| 197 | |
public void setAdditionalLookups (List<String> additionalLookups) |
| 198 | |
{ |
| 199 | 0 | this.additionalLookups = additionalLookups; |
| 200 | 0 | } |
| 201 | |
|
| 202 | |
private String lookupContextPath; |
| 203 | |
|
| 204 | |
public String getLookupContextPath () |
| 205 | |
{ |
| 206 | 0 | return lookupContextPath; |
| 207 | |
} |
| 208 | |
|
| 209 | |
public void setLookupContextPath (String lookupContextPath) |
| 210 | |
{ |
| 211 | 0 | this.lookupContextPath = lookupContextPath; |
| 212 | 0 | } |
| 213 | |
|
| 214 | |
private Integer maxRecursions; |
| 215 | |
|
| 216 | |
public Integer getMaxRecursions () |
| 217 | |
{ |
| 218 | 0 | return maxRecursions; |
| 219 | |
} |
| 220 | |
|
| 221 | |
public void setMaxRecursions (Integer maxRecursions) |
| 222 | |
{ |
| 223 | 0 | this.maxRecursions = maxRecursions; |
| 224 | 0 | } |
| 225 | |
|
| 226 | |
} |