home *** CD-ROM | disk | FTP | other *** search
/ Symantec Visual Cafe for Java 2.5 / symantec-visual-cafe-2.5-database-dev-edition.iso / VCafe / prosrc.bin / LongZipCodeMask.java < prev    next >
Encoding:
Java Source  |  1998-03-18  |  1.0 KB  |  41 lines

  1. /*
  2.  * @(#LongZipCodeMask.java
  3.  *
  4.  * Copyright (c) 1997 Symantec Corporation. All Rights Reserved.
  5.  *
  6.  */
  7.  
  8.  
  9. package symantec.itools.db.awt;
  10.  
  11. /**
  12.  * Creates a formatted text field in which your user can type in a 9-digit zip
  13.  * code.
  14.  * LongZipCodeMask limits the type of text that can be entered in the text
  15.  * box to a #####-#### format number.
  16.  * Text formatting logic is applied to the user input.
  17.  * If the text field already contains text, the user can select the default text
  18.  * and delete or edit it.
  19.  */
  20. public class LongZipCodeMask extends symantec.itools.db.awt.FormattedTextField
  21. {
  22.     /**
  23.      * Constructs a long zip code field.  This is a formatted text field
  24.      * with the following format: 99999/-9999
  25.      */
  26.     public LongZipCodeMask()
  27.     {
  28.         super(10);
  29.         super.setMask("99999/-9999");
  30.     }
  31.  
  32.     /**
  33.      * Takes no action.  Overrides setMask in FormattedTextField to prevent
  34.      * alteration of the long zip code mask.
  35.      */
  36.     public void setMask(String s)
  37.     {
  38.     }
  39.     
  40. }
  41.