org.apache.wicket.protocol.http.request.urlcompressing
Class UrlCompressor

java.lang.Object
  extended by org.apache.wicket.protocol.http.request.urlcompressing.UrlCompressor
All Implemented Interfaces:
Serializable, IClusterable

public class UrlCompressor
extends Object
implements IClusterable

This class generates UID for Component/Interface combinations when used in conjunction with UrlCompressingWebCodingStrategy Use it like this:

 protected IRequestCycleProcessor newRequestCycleProcessor()
 {
        return new UrlCompressingWebRequestProcessor();
 }
 

Since:
1.2
Author:
jcompagner
See Also:
UrlCompressingWebCodingStrategy, UrlCompressingWebRequestProcessor, Serialized Form

Nested Class Summary
static class UrlCompressor.ComponentAndInterface
           
 
Constructor Summary
UrlCompressor()
           
 
Method Summary
 UrlCompressor.ComponentAndInterface getComponentAndInterfaceForUID(String uidString)
          Gets the combination
 int getNewUID()
           
 int getUIDForComponentAndInterface(Component component, String interfaceName)
          Returns a uid for the combination component and the to call interface.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UrlCompressor

public UrlCompressor()
Method Detail

getComponentAndInterfaceForUID

public UrlCompressor.ComponentAndInterface getComponentAndInterfaceForUID(String uidString)
Gets the combination

Parameters:
uidString -
Returns:
ComponentAndInterface

getNewUID

public int getNewUID()
Returns:
the next uid for this url compressor

getUIDForComponentAndInterface

public int getUIDForComponentAndInterface(Component component,
                                          String interfaceName)
Returns a uid for the combination component and the to call interface. Will return the same uid if it was already called for this specific combination.

Parameters:
component - The Component
interfaceName - The interface name
Returns:
int The uid for the component/interfaceName combination


Copyright © 2004-2011 Apache Software Foundation. All Rights Reserved.