Clover coverage report - Clover results for XOM 1.2d1
Coverage timestamp: Wed Feb 8 2006 08:31:33 EST
file stats: LOC: 268   Methods: 2
NCLOC: 227   Classes: 1
 
 Source file Conditionals Statements Methods TOTAL
Latin3Writer.java 100% 100% 100% 100%
coverage
 1    /* Copyright 2002, 2003 Elliotte Rusty Harold
 2   
 3    This library is free software; you can redistribute it and/or modify
 4    it under the terms of version 2.1 of the GNU Lesser General Public
 5    License as published by the Free Software Foundation.
 6   
 7    This library is distributed in the hope that it will be useful,
 8    but WITHOUT ANY WARRANTY; without even the implied warranty of
 9    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 10    GNU Lesser General Public License for more details.
 11   
 12    You should have received a copy of the GNU Lesser General Public
 13    License along with this library; if not, write to the
 14    Free Software Foundation, Inc., 59 Temple Place, Suite 330,
 15    Boston, MA 02111-1307 USA
 16   
 17    You can contact Elliotte Rusty Harold by sending e-mail to
 18    elharo@metalab.unc.edu. Please include the word "XOM" in the
 19    subject line. The XOM home page is located at http://www.xom.nu/
 20    */
 21   
 22    package nu.xom;
 23   
 24    import java.io.Writer;
 25   
 26    /**
 27    * <p>
 28    * ISO 8859-3
 29    * </p>
 30    *
 31    * @author Elliotte Rusty Harold
 32    * @version 1.0
 33    *
 34    */
 35    class Latin3Writer extends TextWriter {
 36   
 37  1 Latin3Writer(Writer out, String encoding) {
 38  1 super(out, encoding);
 39    }
 40   
 41    /**
 42    * @see nu.xom.TextWriter#needsEscaping(char)
 43    */
 44  255083 boolean needsEscaping(char c) {
 45  191246 if (c <= 0xA0) return false;
 46  63837 switch (c) {
 47  1 case 0x00A1: return true; // place holder to enable table lookup
 48  1 case 0x00A2: return true; // place holder to enable table lookup
 49  1 case 0x00A3: return true; // place holder to enable table lookup
 50  1 case 0x00A4: return false; // CURRENCY SIGN
 51  1 case 0x00A5: return true; // place holder to enable table lookup
 52  1 case 0x00A6: return true; // place holder to enable table lookup
 53  1 case 0x00A7: return false; // SECTION SIGN
 54  1 case 0x00A8: return false; // DIAERESIS
 55  1 case 0x00A9: return true; // place holder to enable table lookup
 56  1 case 0x00AA: return true; // place holder to enable table lookup
 57  1 case 0x00AB: return true; // place holder to enable table lookup
 58  1 case 0x00AC: return true; // place holder to enable table lookup
 59  1 case 0x00AD: return false; // SOFT HYPHEN
 60  1 case 0x00AE: return true; // place holder to enable table lookup
 61  1 case 0x00AF: return true; // place holder to enable table lookup
 62  1 case 0x00B0: return false; // DEGREE SIGN
 63  1 case 0x00B1: return true; // place holder to enable table lookup
 64  1 case 0x00B2: return false; // SUPERSCRIPT TWO
 65  1 case 0x00B3: return false; // SUPERSCRIPT THREE
 66  1 case 0x00B4: return false; // ACUTE ACCENT
 67  1 case 0x00B5: return false; // MICRO SIGN
 68  1 case 0x00B7: return false; // MIDDLE DOT
 69  1 case 0x00B8: return false; // CEDILLA
 70  1 case 0x00B9: return true; // place holder to enable table lookup
 71  1 case 0x00BA: return true; // place holder to enable table lookup
 72  1 case 0x00BB: return true; // place holder to enable table lookup
 73  1 case 0x00BC: return true; // place holder to enable table lookup
 74  1 case 0x00BD: return false; // VULGAR FRACTION ONE HALF
 75  1 case 0x00BE: return true; // place holder to enable table lookup
 76  1 case 0x00BF: return true; // place holder to enable table lookup
 77  1 case 0x00C0: return false; // LATIN CAPITAL LETTER A WITH GRAVE
 78  1 case 0x00C1: return false; // LATIN CAPITAL LETTER A WITH ACUTE
 79  1 case 0x00C2: return false; // LATIN CAPITAL LETTER A WITH CIRCUMFLEX
 80  1 case 0x00C3: return true; // place holder to enable table lookup
 81  1 case 0x00C4: return false; // LATIN CAPITAL LETTER A WITH DIAERESIS
 82  1 case 0x00C5: return true; // place holder to enable table lookup
 83  1 case 0x00C6: return true; // place holder to enable table lookup
 84  1 case 0x00C7: return false; // LATIN CAPITAL LETTER C WITH CEDILLA
 85  1 case 0x00C8: return false; // LATIN CAPITAL LETTER E WITH GRAVE
 86  1 case 0x00C9: return false; // LATIN CAPITAL LETTER E WITH ACUTE
 87  1 case 0x00CA: return false; // LATIN CAPITAL LETTER E WITH CIRCUMFLEX
 88  1 case 0x00CB: return false; // LATIN CAPITAL LETTER E WITH DIAERESIS
 89  1 case 0x00CC: return false; // LATIN CAPITAL LETTER I WITH GRAVE
 90  1 case 0x00CD: return false; // LATIN CAPITAL LETTER I WITH ACUTE
 91  1 case 0x00CE: return false; // LATIN CAPITAL LETTER I WITH CIRCUMFLEX
 92  1 case 0x00CF: return false; // LATIN CAPITAL LETTER I WITH DIAERESIS
 93  1 case 0x00D0: return true; // place holder to enable table lookup
 94  1 case 0x00D1: return false; // LATIN CAPITAL LETTER N WITH TILDE
 95  1 case 0x00D2: return false; // LATIN CAPITAL LETTER O WITH GRAVE
 96  1 case 0x00D3: return false; // LATIN CAPITAL LETTER O WITH ACUTE
 97  1 case 0x00D4: return false; // LATIN CAPITAL LETTER O WITH CIRCUMFLEX
 98  1 case 0x00D6: return false; // LATIN CAPITAL LETTER O WITH DIAERESIS
 99  1 case 0x00D7: return false; // MULTIPLICATION SIGN
 100  1 case 0x00D9: return false; // LATIN CAPITAL LETTER U WITH GRAVE
 101  1 case 0x00DA: return false; // LATIN CAPITAL LETTER U WITH ACUTE
 102  1 case 0x00DB: return false; // LATIN CAPITAL LETTER U WITH CIRCUMFLEX
 103  1 case 0x00DC: return false; // LATIN CAPITAL LETTER U WITH DIAERESIS
 104  1 case 0x00DD: return true; // place holder to enable table lookup
 105  1 case 0x00DE: return true; // place holder to enable table lookup
 106  1 case 0x00DF: return false; // LATIN SMALL LETTER SHARP S
 107  1 case 0x00E0: return false; // LATIN SMALL LETTER A WITH GRAVE
 108  1 case 0x00E1: return false; // LATIN SMALL LETTER A WITH ACUTE
 109  1 case 0x00E2: return false; // LATIN SMALL LETTER A WITH CIRCUMFLEX
 110  1 case 0x00E3: return true; // place holder to enable table lookup
 111  1 case 0x00E4: return false; // LATIN SMALL LETTER A WITH DIAERESIS
 112  1 case 0x00E5: return true; // place holder to enable table lookup
 113  1 case 0x00E6: return true; // place holder to enable table lookup
 114  1 case 0x00E7: return false; // LATIN SMALL LETTER C WITH CEDILLA
 115  1 case 0x00E8: return false; // LATIN SMALL LETTER E WITH GRAVE
 116  1 case 0x00E9: return false; // LATIN SMALL LETTER E WITH ACUTE
 117  1 case 0x00EA: return false; // LATIN SMALL LETTER E WITH CIRCUMFLEX
 118  1 case 0x00EB: return false; // LATIN SMALL LETTER E WITH DIAERESIS
 119  1 case 0x00EC: return false; // LATIN SMALL LETTER I WITH GRAVE
 120  1 case 0x00ED: return false; // LATIN SMALL LETTER I WITH ACUTE
 121  1 case 0x00EE: return false; // LATIN SMALL LETTER I WITH CIRCUMFLEX
 122  1 case 0x00EF: return false; // LATIN SMALL LETTER I WITH DIAERESIS
 123  1 case 0x00F0: return true; // place holder to enable table lookup
 124  1 case 0x00F1: return false; // LATIN SMALL LETTER N WITH TILDE
 125  1 case 0x00F2: return false; // LATIN SMALL LETTER O WITH GRAVE
 126  1 case 0x00F3: return false; // LATIN SMALL LETTER O WITH ACUTE
 127  1 case 0x00F4: return false; // LATIN SMALL LETTER O WITH CIRCUMFLEX
 128  1 case 0x00F5: return true; // place holder to enable table lookup
 129  1 case 0x00F6: return false; // LATIN SMALL LETTER O WITH DIAERESIS
 130  1 case 0x00F7: return false; // DIVISION SIGN
 131  1 case 0x00F8: return true; // place holder to enable table lookup
 132  1 case 0x00F9: return false; // LATIN SMALL LETTER U WITH GRAVE
 133  1 case 0x00FA: return false; // LATIN SMALL LETTER U WITH ACUTE
 134  1 case 0x00FB: return false; // LATIN SMALL LETTER U WITH CIRCUMFLEX
 135  1 case 0x00FC: return false; // LATIN SMALL LETTER U WITH DIAERESIS
 136  1 case 0x00FD: return true; // place holder to enable table lookup
 137  1 case 0x00FE: return true; // place holder to enable table lookup
 138  1 case 0x00FF: return true; // place holder to enable table lookup
 139  1 case 0x0100: return true; // place holder to enable table lookup
 140  1 case 0x0101: return true; // place holder to enable table lookup
 141  1 case 0x0102: return true; // place holder to enable table lookup
 142  1 case 0x0103: return true; // place holder to enable table lookup
 143  1 case 0x0104: return true; // place holder to enable table lookup
 144  1 case 0x0105: return true; // place holder to enable table lookup
 145  1 case 0x0106: return true; // place holder to enable table lookup
 146  1 case 0x0107: return true; // place holder to enable table lookup
 147  1 case 0x0108: return false; // LATIN CAPITAL LETTER C WITH CIRCUMFLEX
 148  1 case 0x0109: return false; // LATIN SMALL LETTER C WITH CIRCUMFLEX
 149  1 case 0x010A: return false; // LATIN CAPITAL LETTER C WITH DOT ABOVE
 150  1 case 0x010B: return false; // LATIN SMALL LETTER C WITH DOT ABOVE
 151  1 case 0x010C: return true; // place holder to enable table lookup
 152  1 case 0x010D: return true; // place holder to enable table lookup
 153  1 case 0x010E: return true; // place holder to enable table lookup
 154  1 case 0x010F: return true; // place holder to enable table lookup
 155  1 case 0x0110: return true; // place holder to enable table lookup
 156  1 case 0x0111: return true; // place holder to enable table lookup
 157  1 case 0x0112: return true; // place holder to enable table lookup
 158  1 case 0x0113: return true; // place holder to enable table lookup
 159  1 case 0x0114: return true; // place holder to enable table lookup
 160  1 case 0x0115: return true; // place holder to enable table lookup
 161  1 case 0x0116: return true; // place holder to enable table lookup
 162  1 case 0x0117: return true; // place holder to enable table lookup
 163  1 case 0x0118: return true; // place holder to enable table lookup
 164  1 case 0x0119: return true; // place holder to enable table lookup
 165  1 case 0x011A: return true; // place holder to enable table lookup
 166  1 case 0x011B: return true; // place holder to enable table lookup
 167  1 case 0x011C: return false; // LATIN CAPITAL LETTER G WITH CIRCUMFLEX
 168  1 case 0x011D: return false; // LATIN SMALL LETTER G WITH CIRCUMFLEX
 169  1 case 0x011E: return false; // LATIN CAPITAL LETTER G WITH BREVE
 170  1 case 0x011F: return false; // LATIN SMALL LETTER G WITH BREVE
 171  1 case 0x0120: return false; // LATIN CAPITAL LETTER G WITH DOT ABOVE
 172  1 case 0x0121: return false; // LATIN SMALL LETTER G WITH DOT ABOVE
 173  1 case 0x0122: return true; // place holder to enable table lookup
 174  1 case 0x0123: return true; // place holder to enable table lookup
 175  1 case 0x0124: return false; // LATIN CAPITAL LETTER H WITH CIRCUMFLEX
 176  1 case 0x0125: return false; // LATIN SMALL LETTER H WITH CIRCUMFLEX
 177  1 case 0x0126: return false; // LATIN CAPITAL LETTER H WITH STROKE
 178  1 case 0x0127: return false; // LATIN SMALL LETTER H WITH STROKE
 179  1 case 0x0128: return true; // place holder to enable table lookup
 180  1 case 0x0129: return true; // place holder to enable table lookup
 181  1 case 0x0130: return false; // LATIN CAPITAL LETTER I WITH DOT ABOVE
 182  1 case 0x0131: return false; // LATIN SMALL LETTER DOTLESS I
 183  1 case 0x0132: return true; // place holder to enable table lookup
 184  1 case 0x0133: return true; // place holder to enable table lookup
 185  1 case 0x0134: return false; // LATIN CAPITAL LETTER J WITH CIRCUMFLEX
 186  1 case 0x0135: return false; // LATIN SMALL LETTER J WITH CIRCUMFLEX
 187  1 case 0x0136: return true; // place holder to enable table lookup
 188  1 case 0x0137: return true; // place holder to enable table lookup
 189  1 case 0x0138: return true; // place holder to enable table lookup
 190  1 case 0x0139: return true; // place holder to enable table lookup
 191  1 case 0x013A: return true; // place holder to enable table lookup
 192  1 case 0x013B: return true; // place holder to enable table lookup
 193  1 case 0x013C: return true; // place holder to enable table lookup
 194  1 case 0x013D: return true; // place holder to enable table lookup
 195  1 case 0x013E: return true; // place holder to enable table lookup
 196  1 case 0x013F: return true; // place holder to enable table lookup
 197  1 case 0x0140: return true; // place holder to enable table lookup
 198  1 case 0x0141: return true; // place holder to enable table lookup
 199  1 case 0x0142: return true; // place holder to enable table lookup
 200  1 case 0x0143: return true; // place holder to enable table lookup
 201  1 case 0x0144: return true; // place holder to enable table lookup
 202  1 case 0x0145: return true; // place holder to enable table lookup
 203  1 case 0x0146: return true; // place holder to enable table lookup
 204  1 case 0x0147: return true; // place holder to enable table lookup
 205  1 case 0x0148: return true; // place holder to enable table lookup
 206  1 case 0x0149: return true; // place holder to enable table lookup
 207  1 case 0x014A: return true; // place holder to enable table lookup
 208  1 case 0x014B: return true; // place holder to enable table lookup
 209  1 case 0x014C: return true; // place holder to enable table lookup
 210  1 case 0x014D: return true; // place holder to enable table lookup
 211  1 case 0x014E: return true; // place holder to enable table lookup
 212  1 case 0x014F: return true; // place holder to enable table lookup
 213  1 case 0x0150: return true; // place holder to enable table lookup
 214  1 case 0x0151: return true; // place holder to enable table lookup
 215  1 case 0x0152: return true; // place holder to enable table lookup
 216  1 case 0x0153: return true; // place holder to enable table lookup
 217  1 case 0x0154: return true; // place holder to enable table lookup
 218  1 case 0x0155: return true; // place holder to enable table lookup
 219  1 case 0x0156: return true; // place holder to enable table lookup
 220  1 case 0x0157: return true; // place holder to enable table lookup
 221  1 case 0x0158: return true; // place holder to enable table lookup
 222  1 case 0x0159: return true; // place holder to enable table lookup
 223  1 case 0x015A: return true; // place holder to enable table lookup
 224  1 case 0x015B: return true; // place holder to enable table lookup
 225  1 case 0x015C: return false; // LATIN CAPITAL LETTER S WITH CIRCUMFLEX
 226  1 case 0x015D: return false; // LATIN SMALL LETTER S WITH CIRCUMFLEX
 227  1 case 0x015E: return false; // LATIN CAPITAL LETTER S WITH CEDILLA
 228  1 case 0x015F: return false; // LATIN SMALL LETTER S WITH CEDILLA
 229  1 case 0x0160: return true; // place holder to enable table lookup
 230  1 case 0x0161: return true; // place holder to enable table lookup
 231  1 case 0x0162: return true; // place holder to enable table lookup
 232  1 case 0x0163: return true; // place holder to enable table lookup
 233  1 case 0x0164: return true; // place holder to enable table lookup
 234  1 case 0x0165: return true; // place holder to enable table lookup
 235  1 case 0x0166: return true; // place holder to enable table lookup
 236  1 case 0x0167: return true; // place holder to enable table lookup
 237  1 case 0x0168: return true; // place holder to enable table lookup
 238  1 case 0x0169: return true; // place holder to enable table lookup
 239  1 case 0x016A: return true; // place holder to enable table lookup
 240  1 case 0x016B: return true; // place holder to enable table lookup
 241  1 case 0x016C: return false; // LATIN CAPITAL LETTER U WITH BREVE
 242  1 case 0x016D: return false; // LATIN SMALL LETTER U WITH BREVE
 243  1 case 0x016E: return true; // place holder to enable table lookup
 244  1 case 0x016F: return true; // place holder to enable table lookup
 245  1 case 0x0170: return true; // place holder to enable table lookup
 246  1 case 0x0171: return true; // place holder to enable table lookup
 247  1 case 0x0172: return true; // place holder to enable table lookup
 248  1 case 0x0173: return true; // place holder to enable table lookup
 249  1 case 0x0174: return true; // place holder to enable table lookup
 250  1 case 0x0175: return true; // place holder to enable table lookup
 251  1 case 0x0176: return true; // place holder to enable table lookup
 252  1 case 0x0177: return true; // place holder to enable table lookup
 253  1 case 0x0178: return true; // place holder to enable table lookup
 254  1 case 0x0179: return true; // place holder to enable table lookup
 255  1 case 0x017A: return true; // place holder to enable table lookup
 256  1 case 0x017B: return false; // LATIN CAPITAL LETTER Z WITH DOT ABOVE
 257  1 case 0x017C: return false; // LATIN SMALL LETTER Z WITH DOT ABOVE
 258    }
 259  63626 switch (c) {
 260  1 case 0x02D8: return false; // BREVE
 261  1 case 0x02D9: return false; // DOT ABOVE
 262    }
 263   
 264  63624 return true;
 265   
 266    }
 267   
 268    }