1. /*
  2. * @(#)SpecialMapping.java 1.9 01/11/29
  3. *
  4. * Copyright 2002 Sun Microsystems, Inc. All rights reserved.
  5. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
  6. */
  7. /*
  8. * @(#)SpecialMapping.java 1.9 01/11/29
  9. *
  10. * (C) Copyright Taligent, Inc. 1996, 1997 - All Rights Reserved
  11. * (C) Copyright IBM Corp. 1996 - 1998 - All Rights Reserved
  12. *
  13. * Portions copyright (c) 1996-1998 Sun Microsystems, Inc.
  14. * All Rights Reserved.
  15. *
  16. * The original version of this source code and documentation
  17. * is copyrighted and owned by Taligent, Inc., a wholly-owned
  18. * subsidiary of IBM. These materials are provided under terms
  19. * of a License Agreement between Taligent and Sun. This technology
  20. * is protected by multiple US and International patents.
  21. *
  22. * This notice and attribution to Taligent may not be removed.
  23. * Taligent is a registered trademark of Taligent, Inc.
  24. *
  25. * Permission to use, copy, modify, and distribute this software
  26. * and its documentation for NON-COMMERCIAL purposes and without
  27. * fee is hereby granted provided that this copyright notice
  28. * appears in all copies. Please refer to the file "copyright.html"
  29. * for further important copyright and licensing information.
  30. *
  31. * SUN MAKES NO REPRESENTATIONS OR WARRANTIES ABOUT THE SUITABILITY OF
  32. * THE SOFTWARE, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
  33. * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
  34. * PARTICULAR PURPOSE, OR NON-INFRINGEMENT. SUN SHALL NOT BE LIABLE FOR
  35. * ANY DAMAGES SUFFERED BY LICENSEE AS A RESULT OF USING, MODIFYING OR
  36. * DISTRIBUTING THIS SOFTWARE OR ITS DERIVATIVES.
  37. *
  38. */
  39. package java.text;
  40. /**
  41. * This class represents exceptions to the normal unicode category
  42. * mapping provided by Character. It is internal only. It represents
  43. * a range of characters that don't follow the category mapping.
  44. */
  45. final class SpecialMapping
  46. {
  47. /**
  48. * The first character in exception range
  49. */
  50. public char startChar;
  51. /**
  52. * The last character in the exception range
  53. */
  54. public char endChar;
  55. /**
  56. * The category for characters in the range
  57. */
  58. public int newValue;
  59. /**
  60. * Construct a mapping for a single character
  61. * @param ch the character
  62. * @param newValue the new category for the character
  63. */
  64. public SpecialMapping(char ch, int newValue)
  65. {
  66. this(ch, ch, newValue);
  67. }
  68. /**
  69. * Construct a mapping for a range of characters
  70. * @param startChar the first character in the range
  71. * @param endChar the last character in the range
  72. * @param newValue the category for the range
  73. */
  74. public SpecialMapping(char startChar, char endChar, int newValue)
  75. {
  76. this.startChar = startChar;
  77. this.endChar = endChar;
  78. this.newValue = newValue;
  79. }
  80. }