| Home >> All |
| | surfboard.applet.* (1) | | surfboard.filter.* (27) | | surfboard.tool.* (6) | | surfboard.uservlet.* (12) |
| | surfboard.util.* (7) |
surfboard: Javadoc index of package surfboard.
Package Samples:
surfboard.uservlet
surfboard.filter
surfboard.tool
surfboard.util
surfboard.applet
Classes:
Configuration: This class stores all configurable data, as defined in the XML config file. The configurable attributes must be public since they are modified through reflection. To add a configurable parameter: add a public variable with a suitable default, and optionally a getter method. No changes are required to the parsing routines. Each attribute can be set from the xml file with a line like: <TagName VALUE="123456" TYPE="int">attributeName</TagName> supported types are int, String, and boolean. The file also contains a special tag called Startup that defines the filters and tunnels to be initialized ...
Capture: Capture - a session-capture tool. This class writes XML session files (session-#.xml). This is used in conjunction with three filters: inbound and outbound body filters to record form posts and HTML documents, and an outbound header filter to watch for responses. The GET and POST requests are recorded when these result in either a response with type text/html, or 302 responses that ultimately lead to a response with type text/html. Each URL traversed is compared with the previous HTML document received; if the current URL is found, a regular expression will be inserted on the previous request to ...
NewsBannerFilter: NewsBannerFilter - replace banner ads with news headlines Todo: [x] Streamify by transmitting buffers that don't have the potential for "dangling ads". Right now, all buffers are appended to a StringBuffer and then processed in-bulk at the end of the transfer. Instead, each incoming buffer should use this algorithm: L = existing buffer (H, T) = split incoming buffer at end of last tag L += H if L complete filter and send L L = T else L += T end if
fmExample: This is a (silly) example of using the Playback tool with session scripts that use the CALL tag. This will log in to your freshmeat account and indicate how many new projects there are; it will log in only once, and then reuse the same session to periodically resample your "my freshmeat" page and display the number of new projects. The period is set to 30 minutes. Before trying this, edit the fm-login.xml script to include your login name and password. For an example of extending Playback to handle other tags, see OmniBiff http://omnibiff.sourceforge.net/
Playback: This is a generic session-playback tool. It reads an XML-based session file that describes a series of GET and POST operations, and rules for managing session tokens and parsing HTML pages. Each GET/POST will manage cookies and follow redirections automatically. Tags in the script define what to do with the resulting HTML documents, usually executing a command (passing the file as input) or instantiating a java class and passing it as a string parameter. This class can be extended to support other XML tags. Any such derived classes should overload the handleExtendedTag method.
Tsunami: This is the test suite for Surfboard. It consists of a server portion and a client portion. The server listens on a socket for HTTP connections, and responds with content as defined before the beginning of the transfer. The client portion sends one or more HTTP requests through the proxy to the server side of the Tsunami, and verifies that the response is what was expected. todo: [x] Add "negate" property for tests that are expected to fail [x] Add expects tag for transfers in which expected results are different from what is sent
MicroServlet: This is the base interface implemented by all MicroServlets. A MicroServlet, as the name implies, is a stripped down Servlet that can respond to an HTTP request. There are only two methods in this interface, one to determine if this MicroServlet should be applied to a specific request, and another to handle the request.
Surfboard: This is the main Surfboard class. It is responsible for initializing the proxy, managing the resource pools, and accepting incoming connections. Incoming connections are dispatched to an HttpReader from the browserPool. This class uses the singleton pattern.
BaseHeaderFilter: This class provides an abstract implementation of HeaderFilter and can be extended to create new filters. The getName method should be implemented by any derived classes to satisfy the HeaderFilter interface.
BaseBodyFilter: This class provides an abstract implementation of BodyFilter and can be extended to create new filters. The getName method should be implemented by any derived classes to satisfy the BodyFilter interface.
ServletRegistry: This class records all active uServlets that can be accessed from the console. Servlets registered here will have links appearing on the console's navbar. This class uses the singleton pattern.
Toggleable: This interface is implemented by filters that wish to be made manually toggleable through the ToggleServlet servlet (and hence the wmFilter applet).
HTMLRecipient: This interface is implemented by any classes that are to be invoked from the CALL tag of a session script, when executed by Playback.
PipelineHandler: This interface is implemented by any class that can participate in a filter pipeline, such as BodyFilters and HttpReaders.
Synchronizer: Provides a general purpose lock object, similar to a semaphore. It is used between Preemptables and the TrafficCop.
DataBank: This class buffers data for periodic transmission to external clients. This class uses the singleton pattern.
IFrameBannerFilter: This filter replaces 468x60 banner ads with an applet that shows current news headlines.
AppletBannerFilter: This filter replaces 468x60 banner ads with an applet that shows current news headlines.
Preemptable: This interface is implemented by any classes that are managed by the TrafficCop class.
Stats: This class is used to store information describing the current status of Surfboard.
Keys: This interface defines constant values used to identify data in the DataBank.
HeaderFilter: This is the interface implemented by all Header Filters.
Filter: This is the base interface implemented by all Filters.
| Home | Contact Us | Privacy Policy | Terms of Service |