View Javadoc

1   package org.kuali.ole.describe.form;
2   
3   /**
4    * Created with IntelliJ IDEA.
5    * User: pp7788
6    * Date: 12/11/12
7    * Time: 2:57 PM
8    * To change this template use File | Settings | File Templates.
9    */
10  
11  import org.kuali.ole.docstore.model.xmlpojo.work.instance.oleml.*;
12  import org.kuali.ole.editor.bo.InstanceRecordMetaData;
13  import org.kuali.ole.editor.bo.SourceEditorForUI;
14  import org.kuali.rice.core.api.util.tree.Tree;
15  
16  import java.util.List;
17  
18  /**
19   *  InstanceEditorForm is the form class for Instance Editor
20   */
21  public class WorkInstanceOlemlForm extends EditorForm {
22  
23      private InstanceRecordMetaData itemRecordMetaData = new InstanceRecordMetaData();
24      private InstanceRecordMetaData holdingRecordMetaData = new InstanceRecordMetaData();
25      private OleHoldings selectedHolding;
26      private Instance instance;
27      private Item selectedItem;
28      private SourceEditorForUI selectedSourceHolding;
29  
30      public WorkInstanceOlemlForm () {
31          getSelectedHolding().getUri().add(new Uri());
32          getSelectedHolding().getNote().add(new Note());
33          getSelectedHolding().getExtentOfOwnership().add(new ExtentOfOwnership());
34          getSelectedHolding().getExtentOfOwnership().get(0).getNote().add(new Note());
35      }
36  
37  
38      public String getMessage() {
39          return message;
40      }
41  
42      public void setMessage(String message) {
43          this.message = message;
44      }
45  
46      public InstanceRecordMetaData getItemRecordMetaData() {
47          return itemRecordMetaData;
48      }
49  
50      public void setItemRecordMetaData(InstanceRecordMetaData itemRecordMetaData) {
51          this.itemRecordMetaData = itemRecordMetaData;
52      }
53  
54      public InstanceRecordMetaData getHoldingRecordMetaData() {
55          return holdingRecordMetaData;
56      }
57  
58      public void setHoldingRecordMetaData(InstanceRecordMetaData holdingRecordMetaData) {
59          this.holdingRecordMetaData = holdingRecordMetaData;
60      }
61  
62      public OleHoldings getSelectedHolding() {
63          if (null == selectedHolding) {
64              selectedHolding = new OleHoldings();
65              selectedHolding.setCallNumber(new CallNumber());
66          }
67          return selectedHolding;
68      }
69  
70      public void setSelectedHolding(OleHoldings selectedHolding) {
71          this.selectedHolding = selectedHolding;
72      }
73  
74      public Instance getInstance() {
75          return instance;
76      }
77  
78      public void setInstance(Instance instance) {
79          this.instance = instance;
80      }
81  
82      public Item getSelectedItem() {
83          return selectedItem;
84      }
85  
86      public void setSelectedItem(Item selectedItem) {
87          this.selectedItem = selectedItem;
88      }
89  
90      public SourceEditorForUI getSelectedSourceHolding() {
91          return selectedSourceHolding;
92      }
93  
94      public void setSelectedSourceHolding(SourceEditorForUI selectedSourceHolding) {
95          this.selectedSourceHolding = selectedSourceHolding;
96      }
97  }