Source code for /engineering/autohit-1998/autohit/verify/TestVerify.javaOriginal file TestVerify.java
   1 /**
   2  * .
   3  * Copyright � 1999 Erich P G.
   4  *
   5  */
   6  
   7 package autohit.verify;
   8 
   9 import autohit.transport.Response;
  10 
  11 /**
  12  * This is a test verification implementation..
  13  * <p>
  14  *
  15  * @author Erich P. Gatejen
  16  * @version 1.0
  17  * <i>Version History</i>
  18  * <code>EPG - Initial - 7Feb99</code> 
  19  * 
  20  */
  21 public class TestVerify implements Verify {
  22 	
  23 	// --- FINAL FIELDS ------------------------------------------------------
  24 
  25 	// --- FIELDS ------------------------------------------------------------
  26 
  27 	// --- PUBLIC METHODS ----------------------------------------------------  
  28         
  29     /**
  30      *  Create a fresh verification context.
  31      *  
  32      *  @param address Address specification.
  33      *
  34      *  @throws autohit.transport.VerifyException     
  35      */     
  36     public void fresh(Response  context) throws VerifyException {
  37                   
  38     }
  39 
  40     /**
  41      *  Reset the current verification context.
  42      *  
  43      *  @param address Address specification.
  44      *
  45      *  @throws autohit.transport.VerifyException     
  46      */     
  47     public void reset() throws VerifyException {
  48     
  49     }
  50 
  51     /**
  52      *  A seek operation.  
  53      *  
  54      *  @param expected the string to seek.
  55      *  @return always true..
  56      *
  57      *  @throws autohit.transport.VerifyException     
  58      */     
  59     public boolean seek(String     expected) throws VerifyException {
  60         System.out.println("TEST VERIFY: SEEK.  expected = " + expected);
  61         return true;        
  62     }    
  63 
  64     /**
  65      *  A CRC check operation.  
  66      *  
  67      *  @param expected the expected CRC value.
  68      *  @return always true.
  69      *
  70      *  @throws autohit.transport.VerifyException     
  71      */     
  72     public boolean crc(int     expected) throws VerifyException {
  73         System.out.println("TEST VERIFY: CRC.  expected = " + expected);
  74         return true;        
  75     }           
  76  
  77     /**
  78      *  A size check operation.  
  79      *  
  80      *  @param expected the expected size.
  81      *  @return true always true.
  82      *
  83      *  @throws autohit.transport.VerifyException     
  84      */     
  85     public boolean size(int     expected) throws VerifyException {
  86         System.out.println("TEST VERIFY: SIZE.  expected = " + expected);        
  87         return true;        
  88     }           
  89 
  90     /**
  91      *  Returns the numeric difference from the previous operation.  Currently,
  92      *  if will return the diff between the expected and actual values calculated  
  93      *  in crc and size.  
  94      *
  95      *  @return Alway returns 0.
  96      *
  97      *  @throws autohit.transport.VerifyException     
  98      */     
  99     public int lastDelta() throws VerifyException {
 100         return 0;    
 101     }
 102     
 103 
 104     /**
 105      *  Run a sub-executable to perform a verification.  
 106      *  
 107      *  @param invocation an invocation string.  used by the specific verification
 108      *         to determine what to run and how to run it.
 109      *  @param content passed to the sun-executable as content.
 110      *  @return true if it passes verification,otherwise false.
 111      *
 112      *  @throws autohit.transport.VerifyException     
 113      */     
 114     public boolean exec(String  invocation, String  content) throws VerifyException {
 115         System.out.println("TEST VERIFY: EXEC");
 116         return true;        
 117     }           
 118     
 119 	// --- PRIVATE METHODS ---------------------------------------------------	
 120 
 121      
 122 
 123 }