1 package org.kuali.ole.editor.keyvalue;
2
3
4 import org.kuali.ole.catalog.bo.OleAccessMethod;
5 import org.kuali.rice.core.api.util.ConcreteKeyValue;
6 import org.kuali.rice.core.api.util.KeyValue;
7 import org.kuali.rice.krad.keyvalues.KeyValuesBase;
8 import org.kuali.rice.krad.service.KRADServiceLocator;
9
10 import java.util.ArrayList;
11 import java.util.Collection;
12 import java.util.List;
13
14
15
16
17 public class AdditionalAccessMethodInformation extends KeyValuesBase {
18
19
20
21
22
23
24 @Override
25 public List<KeyValue> getKeyValues() {
26 List<KeyValue> options = new ArrayList<KeyValue>();
27 Collection<OleAccessMethod> oleAccessMethods =
28 KRADServiceLocator.getBusinessObjectService().findAll(OleAccessMethod.class);
29 options.add(new ConcreteKeyValue("", ""));
30 for (OleAccessMethod type : oleAccessMethods) {
31 options.add(new ConcreteKeyValue(type.getAccessMethodCode(), type.getAccessMethodName()));
32 }
33 return options;
34 }
35 }