1 | |
|
2 | |
|
3 | |
|
4 | |
|
5 | |
|
6 | |
|
7 | |
|
8 | |
|
9 | |
|
10 | |
|
11 | |
|
12 | |
|
13 | |
|
14 | |
|
15 | |
|
16 | |
package org.kuali.rice.kim.impl.type |
17 | |
|
18 | |
import org.kuali.rice.kim.api.type.KimTypeAttribute |
19 | |
import org.kuali.rice.kim.api.type.KimTypeAttributeContract |
20 | |
import org.kuali.rice.kim.impl.common.attribute.KimAttributeBo |
21 | |
import org.kuali.rice.krad.bo.PersistableBusinessObjectBase |
22 | |
|
23 | |
class KimTypeAttributeBo extends PersistableBusinessObjectBase implements KimTypeAttributeContract { |
24 | |
String id |
25 | |
String sortCode |
26 | |
String kimAttributeId |
27 | |
KimAttributeBo kimAttribute |
28 | |
String kimTypeId |
29 | |
boolean active |
30 | |
|
31 | |
|
32 | |
|
33 | |
|
34 | |
|
35 | |
|
36 | |
static KimTypeAttribute to(KimTypeAttributeBo bo) { |
37 | 0 | if (bo == null) { |
38 | 0 | return null |
39 | |
} |
40 | |
|
41 | 0 | return KimTypeAttribute.Builder.create(bo).build(); |
42 | |
} |
43 | |
|
44 | |
|
45 | |
|
46 | |
|
47 | |
|
48 | |
|
49 | |
static KimTypeAttributeBo from(KimTypeAttribute im) { |
50 | 0 | if (im == null) { |
51 | 0 | return null |
52 | |
} |
53 | |
|
54 | 0 | KimTypeAttributeBo bo = new KimTypeAttributeBo() |
55 | 0 | bo.id = im.id |
56 | 0 | bo.sortCode = im.sortCode |
57 | 0 | bo.kimAttributeId = im.kimAttribute.id |
58 | 0 | bo.kimAttribute = KimAttributeBo.from(im.kimAttribute) |
59 | 0 | bo.kimTypeId = im.kimTypeId |
60 | 0 | bo.active = im.active |
61 | 0 | bo.versionNumber = im.versionNumber |
62 | 0 | bo.objectId = im.objectId |
63 | |
|
64 | 0 | return bo |
65 | |
} |
66 | |
|
67 | |
KimAttributeBo getKimAttribute() { |
68 | 0 | return kimAttribute; |
69 | |
} |
70 | |
} |