com.waveset.adapter.ScriptedConnection
Class ScriptToken.WaitForIgnoreCase

java.lang.Object
  extended bycom.waveset.adapter.ScriptedConnection.ScriptToken
      extended bycom.waveset.adapter.ScriptedConnection.ScriptToken.WaitForIgnoreCase
Enclosing class:
ScriptToken

public static class ScriptToken.WaitForIgnoreCase
extends ScriptToken

Waits for and consumes up to a string in the input. Optionally can cause an error if a rejected string is found first. This class is identical to WaitFor except that it ignores the case of the string to wait for and any reject strings. It would be preferrable to have this class inherit from the WaitFor class. However, since there are methods that are overridden and these are static inner classes Java will not allow that. The result is some redundant code (with the WaitFor class) here and code which does implicit casting in ScriptedConnection.java.


Nested Class Summary
 
Nested classes inherited from class com.waveset.adapter.ScriptedConnection.ScriptToken
ScriptToken.Capture, ScriptToken.Send, ScriptToken.SendPassword, ScriptToken.Sleep, ScriptToken.Timeout, ScriptToken.WaitFor, ScriptToken.WaitForIgnoreCase
 
Field Summary
 
Fields inherited from class com.waveset.adapter.ScriptedConnection.ScriptToken
CAPTURE_TIMEOUT, CLASS, code_id, DEFAULT_TIMEOUT, DEFAULT_TIMEOUT_PROPERTY, RESOURCE_POLICY_GLOBAL_SCOPE, SCRIPTTOKEN_TIMEOUT, WAITFOR_TIMEOUT, WAITFORIGNORECASE_TIMEOUT
 
Constructor Summary
ScriptToken.WaitForIgnoreCase(java.lang.String value)
          Constructor takes the string to wait for.
ScriptToken.WaitForIgnoreCase(java.lang.String value, int timeout)
          Constructor takes the string to wait for.
ScriptToken.WaitForIgnoreCase(java.lang.String value, java.lang.String reject)
          Constructor takes the string to wait for and any reject strings to error out on.
ScriptToken.WaitForIgnoreCase(java.lang.String value, java.lang.String[] reject)
          Constructor takes the string to wait for and any reject strings to error out on.
ScriptToken.WaitForIgnoreCase(java.lang.String value, java.lang.String[] reject, int timeout)
          Constructor takes the string to wait for and any reject strings to error out on.
ScriptToken.WaitForIgnoreCase(java.lang.String value, java.lang.String reject, int timeout)
          Constructor takes the string to wait for and any reject strings to error out on.
 
Method Summary
 java.lang.String[] getAllRejects()
          Returns the | delimited reject strings or null if there are none.
 java.lang.String getRejects()
          Returns the | delimited reject strings or null if there are none.
 boolean hasReject()
          Returns true if the token has any reject strings.
 boolean includesReject(java.lang.String s)
           
 java.lang.String toString()
          Makes a string of this.
 
Methods inherited from class com.waveset.adapter.ScriptedConnection.ScriptToken
getTimeout, getValue, isTimeoutSpecified, setTimeout
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ScriptToken.WaitForIgnoreCase

public ScriptToken.WaitForIgnoreCase(java.lang.String value)
Constructor takes the string to wait for. Will not look for any reject string.


ScriptToken.WaitForIgnoreCase

public ScriptToken.WaitForIgnoreCase(java.lang.String value,
                                     int timeout)
Constructor takes the string to wait for. Will not look for any reject string and will timeout in the specfied number of miliseconds. The default value is specified by the DEFAULT_TIMEOUT define above.


ScriptToken.WaitForIgnoreCase

public ScriptToken.WaitForIgnoreCase(java.lang.String value,
                                     java.lang.String[] reject)
Constructor takes the string to wait for and any reject strings to error out on.


ScriptToken.WaitForIgnoreCase

public ScriptToken.WaitForIgnoreCase(java.lang.String value,
                                     java.lang.String reject)
Constructor takes the string to wait for and any reject strings to error out on.


ScriptToken.WaitForIgnoreCase

public ScriptToken.WaitForIgnoreCase(java.lang.String value,
                                     java.lang.String reject,
                                     int timeout)
Constructor takes the string to wait for and any reject strings to error out on.


ScriptToken.WaitForIgnoreCase

public ScriptToken.WaitForIgnoreCase(java.lang.String value,
                                     java.lang.String[] reject,
                                     int timeout)
Constructor takes the string to wait for and any reject strings to error out on. Wait for the number of specfied miliseconds. The default value is 10000 milliseconds. ( 10 seconds )

Method Detail

getRejects

public java.lang.String getRejects()
Returns the | delimited reject strings or null if there are none.


getAllRejects

public java.lang.String[] getAllRejects()
Returns the | delimited reject strings or null if there are none.


hasReject

public boolean hasReject()
Returns true if the token has any reject strings.


toString

public java.lang.String toString()
Makes a string of this.

Overrides:
toString in class ScriptToken

includesReject

public boolean includesReject(java.lang.String s)