|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.avalon.framework.logger.AbstractLogEnabled org.apache.cocoon.portal.impl.DefaultLinkService
public class DefaultLinkService
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface org.apache.cocoon.portal.LinkService |
---|
LinkService.ParameterDescription |
Field Summary | |
---|---|
protected Context |
context
The cocoon context |
protected EventConverter |
converter
The converter used to convert an event into a request parameter |
protected int |
defaultPort
Default port used for http. |
protected int |
defaultSecurePort
Default port used for https. |
protected Boolean |
eventsMarshalled
|
protected ServiceManager |
manager
The service manager |
Fields inherited from interface org.apache.cocoon.portal.LinkService |
---|
DEFAULT_CONVERTABLE_EVENT_PARAMETER_NAME, DEFAULT_REQUEST_EVENT_PARAMETER_NAME, ROLE |
Constructor Summary | |
---|---|
DefaultLinkService()
|
Method Summary | |
---|---|
protected boolean |
addEvent(StringBuffer buffer,
Event event,
boolean hasParams)
Add one event to the buffer |
void |
addEventToLink(Event event)
Add this event to the list of events contained in the uri |
void |
addParameterToLink(String name,
String value)
Add this parameter to every link. |
void |
addUniqueParameterToLink(String name,
String value)
Add this parameter to every link. |
void |
contextualize(Context context)
|
void |
dispose()
|
String |
encodeURL(String url)
|
protected LinkInfo |
getInfo()
Return the current info for the request. |
String |
getLinkURI(Event event)
Get the uri for this coplet containing the additional event |
String |
getLinkURI(Event event,
Boolean secure)
Get the uri for this coplet containing the additional event and using a secure protocol if requested. |
String |
getLinkURI(List events)
Get the uri for this coplet containing the additional events. |
String |
getLinkURI(List events,
Boolean secure)
Get a uri for this coplet containing the additional events. |
String |
getRefreshLinkURI()
Get a link that simply refreshs the portal |
String |
getRefreshLinkURI(Boolean secure)
Get a link that simply refreshs the portal |
protected String |
initBuffer(LinkInfo info,
Event event,
Boolean secure)
|
protected String |
initBuffer(LinkInfo info,
List events,
Boolean secure)
|
boolean |
isSecure()
Determine whether the current url is using a secure protocol |
void |
parameterize(Parameters params)
|
protected String |
processEvent(Event event,
StringBuffer value)
|
void |
service(ServiceManager manager)
|
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled |
---|
enableLogging, getLogger, setupLogger, setupLogger, setupLogger |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected EventConverter converter
protected ServiceManager manager
protected Context context
protected Boolean eventsMarshalled
protected int defaultPort
protected int defaultSecurePort
Constructor Detail |
---|
public DefaultLinkService()
Method Detail |
---|
public void service(ServiceManager manager) throws ServiceException
service
in interface Serviceable
ServiceException
Serviceable.service(org.apache.avalon.framework.service.ServiceManager)
public void parameterize(Parameters params) throws ParameterException
parameterize
in interface Parameterizable
ParameterException
Parameterizable.parameterize(org.apache.avalon.framework.parameters.Parameters)
protected LinkInfo getInfo()
public boolean isSecure()
LinkService
isSecure
in interface LinkService
LinkService.isSecure()
public String encodeURL(String url)
encodeURL
in interface LinkService
url
- The url to encode.
LinkService.encodeURL(String url)
public String getLinkURI(Event event)
LinkService
getLinkURI
in interface LinkService
event
- The event to add (null is also allowed for convenience)
LinkService.getLinkURI(org.apache.cocoon.portal.event.Event)
public String getLinkURI(Event event, Boolean secure)
LinkService
getLinkURI
in interface LinkService
event
- The event to add (null is also allowed for convenience)secure
- true if a secure protocol is required, false otherwise.
LinkService.getLinkURI(org.apache.cocoon.portal.event.Event, Boolean)
protected String initBuffer(LinkInfo info, Event event, Boolean secure)
protected boolean addEvent(StringBuffer buffer, Event event, boolean hasParams)
public String getLinkURI(List events)
LinkService
getLinkURI
in interface LinkService
events
- The events to add: These can either be Event
s or LinkService.ParameterDescription
s.
LinkService.getLinkURI(java.util.List)
public String getLinkURI(List events, Boolean secure)
LinkService
getLinkURI
in interface LinkService
events
- The events to add: These can either be Event
s or LinkService.ParameterDescription
s.secure
- true if a secure protocol is required, false otherwise.
LinkService.getLinkURI(java.util.List)
protected String initBuffer(LinkInfo info, List events, Boolean secure)
public void addEventToLink(Event event)
LinkService
addEventToLink
in interface LinkService
event
- Event to addLinkService.addEventToLink(org.apache.cocoon.portal.event.Event)
public void addParameterToLink(String name, String value)
LinkService
addParameterToLink
in interface LinkService
name
- The request parameter namevalue
- The value for the parameterLinkService.addParameterToLink(java.lang.String, java.lang.String)
public void addUniqueParameterToLink(String name, String value)
LinkService
addUniqueParameterToLink
in interface LinkService
name
- The request parameter namevalue
- The value for the parameterLinkService.addUniqueParameterToLink(java.lang.String, java.lang.String)
public String getRefreshLinkURI()
LinkService
getRefreshLinkURI
in interface LinkService
LinkService.getRefreshLinkURI()
public String getRefreshLinkURI(Boolean secure)
LinkService
getRefreshLinkURI
in interface LinkService
secure
- true if a secure protocol is required, false otherwise.
LinkService.getRefreshLinkURI(java.lang.Boolean)
public void dispose()
dispose
in interface Disposable
Disposable.dispose()
public void contextualize(Context context) throws ContextException
contextualize
in interface Contextualizable
ContextException
Contextualizable.contextualize(org.apache.avalon.framework.context.Context)
protected String processEvent(Event event, StringBuffer value)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |