1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17 package org.apache.jetspeed.portalsite.menu;
18
19 import org.apache.jetspeed.om.folder.impl.StandardMenuOptionsDefinitionImpl;
20
21 /***
22 * This class provides a menu options definition for options
23 * constructed directly from menu definitions.
24 *
25 * @author <a href="mailto:rwatler@apache.org">Randy Watler</a>
26 * @version $Id: DefaultMenuOptionsDefinition.java 516448 2007-03-09 16:25:47Z ate $
27 */
28 public class DefaultMenuOptionsDefinition extends StandardMenuOptionsDefinitionImpl
29 {
30 /***
31 * options - options path specification for menu
32 */
33 private String options;
34
35 /***
36 * depth - inclusion depth for menu options
37 */
38 private int depth;
39
40 /***
41 * paths - generate ordered paths flag for menu options
42 */
43 private boolean paths;
44
45 /***
46 * regexp - regexp flag for menu options
47 */
48 private boolean regexp;
49
50 /***
51 * profile - profile locator for menu options
52 */
53 private String profile;
54
55 /***
56 * order - comma separated regexp ordering patterns for menu options
57 */
58 private String order;
59
60 /***
61 * DefaultMenuOptionsDefinition - constructor
62 */
63 public DefaultMenuOptionsDefinition(String options, int depth, boolean paths, boolean regexp, String locatorName, String order)
64 {
65 super();
66 this.options = options;
67 this.depth = depth;
68 this.paths = paths;
69 this.regexp = regexp;
70 this.profile = locatorName;
71 this.order = order;
72 }
73
74 /***
75 * getOptions - get comma separated menu options if not specified as elements
76 *
77 * @return option paths specification
78 */
79 public String getOptions()
80 {
81 return options;
82 }
83
84 /***
85 * getDepth - get depth of inclusion for folder menu options
86 *
87 * @return inclusion depth
88 */
89 public int getDepth()
90 {
91 return depth;
92 }
93
94 /***
95 * isPaths - get generate ordered path options
96 *
97 * @return paths options flag
98 */
99 public boolean isPaths()
100 {
101 return paths;
102 }
103
104 /***
105 * isRegexp - get regexp flag for interpreting options
106 *
107 * @return regexp flag
108 */
109 public boolean isRegexp()
110 {
111 return regexp;
112 }
113
114 /***
115 * getProfile - get profile locator used to filter specified options
116 *
117 * @return profile locator name
118 */
119 public String getProfile()
120 {
121 return profile;
122 }
123
124 /***
125 * getOrder - get comma separated regexp ordering patterns
126 *
127 * @return ordering patterns list
128 */
129 public String getOrder()
130 {
131 return order;
132 }
133 }