1
14
15 package com.liferay.portal.sharepoint.methods;
16
17 import com.liferay.portal.sharepoint.Leaf;
18 import com.liferay.portal.sharepoint.Property;
19 import com.liferay.portal.sharepoint.ResponseElement;
20 import com.liferay.portal.sharepoint.SharepointRequest;
21 import com.liferay.portal.sharepoint.Tree;
22
23 import java.util.ArrayList;
24 import java.util.List;
25
26
31 public class OpenServiceMethodImpl extends BaseMethodImpl {
32
33 public OpenServiceMethodImpl() {
34 Tree metaInfoTree = new Tree();
35
36 metaInfoTree.addChild(new Leaf("vti_casesensitiveurls", "IX|0", false));
37 metaInfoTree.addChild(new Leaf("vti_longfilenames", "IX|1", false));
38 metaInfoTree.addChild(
39 new Leaf("vti_welcomenames", "VX|index.html", false));
40 metaInfoTree.addChild(new Leaf("vti_username", "SX|joebloggs", false));
41 metaInfoTree.addChild(new Leaf("vti_servertz", "SX|-0700", false));
42 metaInfoTree.addChild(
43 new Leaf("vti_sourcecontrolsystem", "SR|lw", false));
44 metaInfoTree.addChild(
45 new Leaf("vti_sourcecontrolversion", "SR|V1", false));
46 metaInfoTree.addChild(
47 new Leaf("vti_doclibwebviewenabled", "IX|0", false));
48 metaInfoTree.addChild(
49 new Leaf("vti_sourcecontrolcookie", "SX|fp_internal", false));
50 metaInfoTree.addChild(
51 new Leaf(
52 "vti_sourcecontrolproject", "SX|<STS-based Locking>",
53 false));
54
55 Tree serviceTree = new Tree();
56
57 serviceTree.addChild(new Leaf("service_name", "/sharepoint", true));
58 serviceTree.addChild(new Leaf("meta_info", metaInfoTree));
59
60 Property serviceProperty = new Property("service", serviceTree);
61
62 _elements.add(serviceProperty);
63 }
64
65 public String getMethodName() {
66 return _METHOD_NAME;
67 }
68
69 protected List<ResponseElement> getElements(
70 SharepointRequest sharepointRequest) {
71
72 return _elements;
73 }
74
75 private static final String _METHOD_NAME = "open service";
76
77 private List<ResponseElement> _elements = new ArrayList<ResponseElement>();
78
79 }