1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.kuali.ole.docstore.model.xmlpojo.ingest;
17
18 import java.util.ArrayList;
19 import java.util.HashSet;
20 import java.util.List;
21 import java.util.Set;
22
23
24
25
26
27
28
29
30 public class Request {
31
32 public static Set<String> validOperationSet = getValidOperationSet();
33
34 public enum Operation {
35 ingest, bulkIngest, checkIn, checkOut, delete, deleteVerify, deleteWithLinkedDocs, bind, unbind, transfer,
36 transferInstances, transferItems
37 }
38
39 private List<RequestDocument> requestDocuments = new ArrayList<RequestDocument>();
40 private String user;
41 private String operation;
42
43 public String getUser() {
44 return user;
45 }
46
47 public void setUser(String user) {
48 this.user = user;
49 }
50
51 public String getOperation() {
52 return operation;
53 }
54
55 public void setOperation(String operation) {
56 this.operation = operation;
57 }
58
59 public List<RequestDocument> getRequestDocuments() {
60 return requestDocuments;
61 }
62
63 public void setRequestDocuments(List<RequestDocument> requestDocuments) {
64 this.requestDocuments = requestDocuments;
65 }
66
67 private static Set<String> getValidOperationSet() {
68 validOperationSet = new HashSet<String>();
69 validOperationSet.add(Request.Operation.ingest.toString());
70 validOperationSet.add(Request.Operation.bulkIngest.toString());
71 validOperationSet.add(Request.Operation.checkIn.toString());
72 validOperationSet.add(Request.Operation.checkOut.toString());
73 validOperationSet.add(Request.Operation.delete.toString());
74 validOperationSet.add(Operation.deleteVerify.toString());
75 validOperationSet.add(Request.Operation.deleteWithLinkedDocs.toString());
76 validOperationSet.add(Request.Operation.bind.toString());
77 validOperationSet.add(Request.Operation.unbind.toString());
78 validOperationSet.add(Request.Operation.transfer.toString());
79 validOperationSet.add(Request.Operation.transferInstances.toString());
80 validOperationSet.add(Request.Operation.transferItems.toString());
81 return validOperationSet;
82 }
83 }