2009-01-09 1.2.0

org.eclipse.soda.dk.filter
Class SimpleFilter

java.lang.Object
  extended by org.eclipse.soda.dk.filter.SimpleFilter
All Implemented Interfaces:
FilterService

public class SimpleFilter
extends java.lang.Object
implements FilterService

The SimpleFilter class implements the FilterService interface. Simple filters are filters that contain a byte mask that is all on (a mask of 0xff) for each byte in the mask.

Since:
1.0
Version:
1.2.0
See Also:
FilterService

Constructor Summary
SimpleFilter(int index)
          Constructs an instance of this class from the specified index parameter.
SimpleFilter(int index, int size)
          Constructs an SimpleFilter object using the input parameter(s).
 
Method Summary
 boolean matches(byte[] bytes0, byte[] bytes1)
          Matches with the specified bytes0 and bytes1 parameters and return the boolean result.
 boolean matches(MessageService message0, MessageService message1)
          Perform the matches method and return the boolean result.
 java.lang.String toString()
          Returns the string value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SimpleFilter

public SimpleFilter(int index)
Constructs an instance of this class from the specified index parameter.

Parameters:
index - The index (int) parameter.
See Also:
SimpleFilter(int,int)

SimpleFilter

public SimpleFilter(int index,
                    int size)
Constructs an SimpleFilter object using the input parameter(s).

Parameters:
index - Starting byte index to compare parameter.
size - Size in bytes to compare parameter.
See Also:
SimpleFilter(int)
Method Detail

matches

public boolean matches(MessageService message0,
                       MessageService message1)
Perform the matches method and return the boolean result.

Specified by:
matches in interface FilterService
Parameters:
message0 - org.eclipse.soda.dk.message.service.MessageService
message1 - org.eclipse.soda.dk.message.service.MessageService
Returns:
Results of the matches (boolean) value.
See Also:
matches(byte[],byte[])

matches

public boolean matches(byte[] bytes0,
                       byte[] bytes1)
Matches with the specified bytes0 and bytes1 parameters and return the boolean result.

Specified by:
matches in interface FilterService
Parameters:
bytes0 - The bytes0 (byte[]) parameter.
bytes1 - The bytes1 (byte[]) parameter.
Returns:
Results of the matches (boolean) value.
See Also:
matches(MessageService,MessageService)

toString

public java.lang.String toString()
Returns the string value.

Overrides:
toString in class java.lang.Object
Returns:
The string (String) value.

2009-01-09 1.2.0

Copyright (c) 2009 IBM. See license in Legal section.