KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > exoplatform > services > wsrp > consumer > WSRPBaseRequest


1 package org.exoplatform.services.wsrp.consumer;
2
3 import org.exoplatform.services.wsrp.type.ClientData;
4
5 /**
6  * The <code>WSRPRequest</code> is the base interface for all
7  * requests to a consumer side invocation of a integrated remote portlet.
8  * Specialized interfaces exist for markup and action calls.
9  *
10  * @author Benjamin Mestrallet
11  *
12  * @see WSRPMarkupRequest
13  * @see InteractionRequest
14  */

15 public interface WSRPBaseRequest {
16   /**
17    * Get the ID of the session context
18    *
19    * @return The session context
20    */

21   public String JavaDoc getSessionID();
22
23   /**
24    * Get an opaque string which corresponds to a unique reference to this use of the portlet.
25    *
26    * @return The portlet instance key
27    */

28   public String JavaDoc getPortletInstanceKey();
29
30   /**
31    * Get the current navigational state of the portlet
32    *
33    * @return The navigational state
34    */

35   public String JavaDoc getNavigationalState();
36
37   /**
38    * Get the current window state of the portlet
39    *
40    * @return The window state
41    */

42   public String JavaDoc getWindowState();
43
44   /**
45    * Get the current mode of the portlet
46    *
47    * @return The mode of the portlet
48    */

49   public String JavaDoc getMode();
50
51   /**
52    * Get the <code>ClientData</code> structure which carries
53    * information about the end user agent.
54    *
55    * @return The <code>ClientData</code> specifying the user agent.
56    */

57   public ClientData getClientData();
58
59   /**
60    * Get the locales which are supported by the portlet according to the client connecting to it.
61    * The Locales returned are in the form of (ISO-639 + "-" + ISO-3166)
62    *
63    * @return Array with string representations of the locales which are
64    * supported by the consumer
65    */

66   public String JavaDoc[] getLocales();
67
68   /**
69    * Get the list of wsrp modes which are supported by the portlet.
70    * This should returned the list of all actuall supported modes and
71    * not necessarily the modes returned in the portlet description of the producer.
72    *
73    * @return Array with string representations of the portlet modes
74    * supported by the portlet or null
75    */

76   public String JavaDoc[] getModes();
77
78   /**
79    * Get the list of wsrp window states which are supported by the portlet.
80    * This should returned the list of all actuall supported window states and
81    * not necessarily the window states returned in the portlet description of the producer.
82    *
83    * @return Array with string representations of the window states
84    * supported by the portlet or null
85    */

86   public String JavaDoc[] getWindowStates();
87
88   /**
89    * Get an array of mime types which are supported by the end user device.
90    * The order in the array defines the order of preference of the end user.
91    *
92    * @return An array of mimes types the consumer supports or null
93    */

94   public String JavaDoc[] getMimeTypes();
95
96   /**
97    * Get the character sets the consumer wants the remote portlet to use for encoding the markup.
98    * Valid character sets are defined <a HREF='http://www.iana.org/assignments/character-sets'>here</a>
99    *
100    * @return Array of string representations of the character encoding.
101    */

102   public String JavaDoc[] getCharacterEncodingSet();
103
104   /**
105    * Checks wether a given wsrp mode is supported by the portlet.
106    *
107    * @param wsrpMode The wsrp mode
108    * @return True if the mode is supported by the portlet, false otherwise
109    */

110   public boolean isModeSupported(String JavaDoc wsrpMode);
111
112   /**
113    * Checks wether a given wsrp window state is supported by the portlet.
114    *
115    * @param wsrpWindowState The wsrp window state
116    * @return True if the window state is supported by the portlet, false otherwise
117    */

118   public boolean isWindowStateSupported(String JavaDoc wsrpWindowState);
119
120   /**
121    * Get the method which is used by the consumer to authenticate its users.
122    *
123    * @return String indicating how end-users were authenticated by the consumer.
124    */

125   public String JavaDoc getUserAuthentication();
126 }
127
Popular Tags