net.sourceforge.sstringsearch.replace
Interface ReplacingHitListener

All Superinterfaces:
Serializable

public interface ReplacingHitListener
extends Serializable

Project: sstringsearch
File: ReplacingHitListener.java
Class: ReplacingHitListener
Created: 13. mar. 2008

Description:

A HitListener that is notified upon hits when calling StringSearch.searchAndReplace() The searchterm found is replaced in the result with the String returned from the replace() method. Implementations of this class should be fully serializable if one wants to serialize the finite state automata graph.

Version:
$Revision: 1.2 $
Author:
Kristian Andersen Email

Method Summary
 String replace(String stringToReplace, Object... callbackArguments)
          This method is called whenever the associated string is encountered in the input.
 

Method Detail

replace

String replace(String stringToReplace,
               Object... callbackArguments)
This method is called whenever the associated string is encountered in the input. In the result the encountered String is replaced by the String returned from this method

Parameters:
stringToReplace - The String found in input, will be replaced in output
callbackArguments - Optional callback arguments.
Returns:
The String that should replace the encountered String in the output.


Copyright 2005-2009 Kristian Andersen. All Rights Reserved.