jakarta-regexp-1.5/ 40755 0 0 0 10577337777 11345 5ustar 0 0 jakarta-regexp-1.5/docs/ 40755 0 0 0 10577337776 12274 5ustar 0 0 jakarta-regexp-1.5/docs/api/ 40755 0 0 0 10577337776 13045 5ustar 0 0 jakarta-regexp-1.5/docs/api/org/ 40755 0 0 0 10577337776 13634 5ustar 0 0 jakarta-regexp-1.5/docs/api/org/apache/ 40755 0 0 0 10577337776 15055 5ustar 0 0 jakarta-regexp-1.5/docs/api/org/apache/regexp/ 40755 0 0 0 10577337776 16347 5ustar 0 0 jakarta-regexp-1.5/docs/api/org/apache/regexp/class-use/ 40755 0 0 0 10577337776 20246 5ustar 0 0 jakarta-regexp-1.5/src/ 40755 0 0 0 10577337776 12133 5ustar 0 0 jakarta-regexp-1.5/src/java/ 40755 0 0 0 10577337776 13054 5ustar 0 0 jakarta-regexp-1.5/src/java/org/ 40755 0 0 0 10577337776 13643 5ustar 0 0 jakarta-regexp-1.5/src/java/org/apache/ 40755 0 0 0 10577337776 15064 5ustar 0 0 jakarta-regexp-1.5/src/java/org/apache/regexp/ 40755 0 0 0 10577337776 16356 5ustar 0 0 jakarta-regexp-1.5/xdocs/ 40755 0 0 0 10577337776 12464 5ustar 0 0 jakarta-regexp-1.5/xdocs/stylesheets/ 40755 0 0 0 10577337776 15040 5ustar 0 0 jakarta-regexp-1.5/LICENSE100644 0 0 26135 10577337776 12475 0ustar 0 0 Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. jakarta-regexp-1.5/NOTICE100644 0 0 456 10577337777 12333 0ustar 0 0 This product includes software developed by The Apache Software Foundation (http://www.apache.org/). It consists of voluntary contributions made by many individuals on behalf of the Apache Software Foundation. Please visit the project homepage (http://jakarta.apache.org/regexp) for more information. jakarta-regexp-1.5/README100644 0 0 1605 10577337777 12324 0ustar 0 0 Ant is a build system that was developed for the Jakarta Tomcat project and was used internally at Sun. It was originally developed by James Davidson and has been extended by others including myself. When Jakarta was released as Open Source, the developer community also obtained the source to Ant as well. This is a great addition to the community. You can obtain the Ant source code from . It is currently located in the jakarta-tools CVS repository. The build.xml file is the "code" that tells Ant what to do. The beauty of Ant is that it is entirely XML based so creating installation scripts is as easy as creating a XML file. You should not need to edit the build.xml file unless you wish to change paths of things. To build regexp, download and install Ant and invoke 'ant' script from this directory. -jon stevens jons@apache.org jakarta-regexp-1.5/build.xml100644 0 0 24672 10577337776 13315 0ustar 0 0 jakarta-regexp-1.5/docs/RETest.txt100644 0 0 21500 10577337776 14316 0ustar 0 0 ## Licensed to the Apache Software Foundation (ASF) under one or more ## contributor license agreements. See the NOTICE file distributed with ## this work for additional information regarding copyright ownership. ## The ASF licenses this file to You under the Apache License, Version 2.0 ## (the "License"); you may not use this file except in compliance with ## the License. You may obtain a copy of the License at ## ## http://www.apache.org/licenses/LICENSE-2.0 ## ## Unless required by applicable law or agreed to in writing, software ## distributed under the License is distributed on an "AS IS" BASIS, ## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ## See the License for the specific language governing permissions and ## limitations under the License. #1 abc abc YES 1 abc #2 abc xbc NO #3 abc axc NO #4 abc abx NO #5 abc xabcy YES 1 abc #6 abc ababc YES 1 abc #7 ab*c abc YES 1 abc #8 ab*bc abc YES 1 abc #9 ab*bc abbc YES 1 abbc #10 ab*bc abbbbc YES 1 abbbbc #11 ab+bc abbc YES 1 abbc #12 ab+bc abc NO #13 ab+bc abq NO #14 ab+bc abbbbc YES 1 abbbbc #15 ab?bc abbc YES 1 abbc #16 ab?bc abc YES 1 abc #17 ab?bc abbbbc NO #18 ab?c abc YES 1 abc #19 a.c abc YES 1 abc #20 a.c axc YES 1 axc #21 a.*c axyzc YES 1 axyzc #22 a.*c axyzd NO #23 a[bc]d abc NO #24 a[bc]d abd YES 1 abd #25 a[b-d]e abd NO #26 a[b-d]e ace YES 1 ace #27 a[b-d] aac YES 1 ac #28 a[b-a] ERR #29 a[-b] aa YES 1 aa #30 a[b-] ac YES 1 ac #31 a[]b ERR #32 a[ ERR #33 a] ERR #34 a[]] ERR #35 a[^bc]d aed YES 1 aed #36 a[^bc] abd NO #37 ab|cd abc YES 1 ab #38 ab|cd abcd YES 1 ab #39 ab|cd bcda YES 1 cd #40 a[]b ERR #41 ()ef ef YES 2 ef #42 ()* ERR #43 *a ERR #44 (*)b ERR #45 a\ ERR #46 a\(b a(b YES 1 a(b #47 a\(*b ab YES 1 ab #48 a\(*b a((b YES 1 a((b #49 a\\b a\b YES 1 a\b #50 abc) ERR #51 (abc ERR #52 ((a)) abc YES 3 a a a #53 (a)b(c) abc YES 3 abc a c #54 a+b+c aabbabc YES 1 abc #55 a** ERR #56 a++ ERR #57 a* aaaa YES 1 aaaa #58 a* baaaa YES 1 #59 (a*)* ERR #60 (a*)+ ERR #61 (a|)* ERR #62 (ab|cd)e abcde YES 2 cde cd #63 [abhgefdc]ij hij YES 1 hij #64 ab* xabyabbbz YES 1 ab #65 ab* xayabbbz YES 1 a #66 abcd*efg abcdefg YES 1 abcdefg #67 (ab|ab*)bc abc YES 2 abc a #68 (a|b|c|d|e)f ef YES 2 ef e #69 a|b|c|d|e e YES 1 e #70 (.*)c(.*) abcde YES 3 abcde ab de #71 \((.*), (.*)\) (a, b) YES 3 (a, b) a b #72 a(bc)d abcd YES 2 abcd bc #73 a* x YES 1 #74 ([abc])*d abbbcd YES 2 abbbcd c #75 a* YES 1 #76 ([abc])*bcd abcd YES 2 abcd a #77 (a|b)c*d abcd YES 2 bcd b #78 a([bc]*)c* abc YES 2 abc bc #79 [a-zA-Z_][a-zA-Z0-9_]* alpha YES 1 alpha #80 ((a)(b)c)(d) abcd YES 5 abcd abc a b d #81 (ab|a)b*c abc YES 2 abc ab #82 a[bcd]+dcdcde adcdcde NO #83 ((((((((((a))))))))) ERR #84 (((((((((a))))))))) a YES 10 a a a a a a a a a a #85 [k] ab NO #86 abcd abcd YES 1 abcd #87 a[-]?c abc YES 1 abc #88 multiple words of text uh-uh NO #89 multiple words multiple words, yeah YES 1 multiple words #90 a[bcd]*dcdcde adcdcde YES 1 adcdcde #91 a([bc]*)(c*d) abcd YES 3 abcd bc d #92 a([bc]+)(c*d) abcd YES 3 abcd bc d #93 a([bc]*)(c+d) abcd YES 3 abcd b cd #94 abc NO #95 ^* ERR #96 $* ERR #97 ^abc$ abc YES 1 abc #98 ^abc$ abcc NO #99 ^abc abcc YES 1 abc #100 ^abc$ aabc NO #101 abc$ aabc YES 1 abc #102 ^ abc YES 1 #103 $ abc YES 1 #104 $b b NO #105 (a+|b)* ab YES 2 ab b #106 (a+|b)+ ab YES 2 ab b #107 (a+|b)? ab YES 2 a a #108 (^* ERR #109 )( ERR #110 [^ab]* cde YES 1 cde #111 ^(ab|cd)e abcde NO #112 ^a(bc+|b[eh])g|.h$ abh YES 1 bh #113 (bc+d$|ef*g.|h?i(j|k)) effgz YES 2 effgz effgz #114 (bc+d$|ef*g.|h?i(j|k)) ij YES 3 ij ij j #115 (bc+d$|ef*g.|h?i(j|k)) effg NO #116 (bc+d$|ef*g.|h?i(j|k)) bcdd NO #117 (bc+d$|ef*g.|h?i(j|k)) reffgz YES 2 effgz effgz #118 a*b\s+c aaaab c YES 1 aaaab c #119 a*b\s+c aaaabfc NO #120 a*(b*c*) aabbcc YES 2 aabbcc bbcc #121 a?b+c* b YES 1 b #122 \d+ 99 YES 1 99 #123 ^[:javastart:]+[:javapart:]+$ javaIdentifier0 YES 1 javaIdentifier0 #124 ^[:javastart:]+[:javapart:]+$ ?javaIdentifier NO #125 [a-e]?d\\e yyzabecd\eyyz YES 1 cd\e #126 ((\w+)/)*(\w+) foo/bar/baz YES 4 foo/bar/baz bar/ bar baz #127 i am a green (giant|man|martian) i am a green man YES 2 i am a green man man #128 ([a-c]+?)c abcabcabc YES 2 abc ab #129 ([ab]*?)b aaaaabaaaababab YES 2 aaaaab aaaaa #130 ([ab]*)b aaaaabaaaababab YES 2 aaaaabaaaababab aaaaabaaaababa #131 ([ab]??)b bb YES 2 b #132 (c[ab]?)b cbb YES 2 cbb cb #133 (c[ab]??)b cbb YES 2 cb c #134 (c[ab]*?)b cbb YES 2 cb c #135 [:digit:]+ 789 YES 1 789 #136 [:digit:]+ abc NO #137 [:xdigit:]+ ffe5a YES 1 ffe5a #138 [:wacky:]+ ERR #139 (wee|week)(knights|knight) weeknights YES 3 weeknights wee knights #140 (ac*)c*d[ac]*\1 acdacaa YES 2 acdac ac #141 (a.*b)(a.*b) accbaccccb YES 3 accbaccccb accb accccb #142 (.)=\1 x=x YES 2 x=x x #143 ([ab])=\1 a=a YES 2 a=a a #144 ([ab]+)=\1 abba=abba YES 2 abba=abba abba #145 \u004a J YES 1 J #146 \x4a J YES 1 J #147 \[([:javastart:][:javapart:]*)\] foo[bar]baz YES 2 [bar] bar #148 (\s*\w+)? aa YES 2 aa aa #149 (?:a) a YES 1 a #150 (?:a) aa YES 1 a #151 (?:\w) abc YES 1 a #152 (?:\w\s\w)+ a b c YES 1 a b #153 (a\w)(?:,(a\w))+ ab,ac,ad YES 3 ab,ac,ad ab ad #154 z(\w\s+(?:\w\s+\w)+)z za b bc cd dz YES 2 za b bc cd dz a b bc cd d #155 (([hH][tT]{2}[pP]|[fF][tT][pP]):\/\/)?[a-zA-Z0-9\-]+(\.[a-zA-Z0-9\-]+)* http://www.test.com YES 4 http://www.test.com http:// http .com #156 ((?:[hH][tT]{2}[pP]|[fF][tT][pP]):\/\/)?[a-zA-Z0-9\-]+(\.[a-zA-Z0-9\-]+)* ftp://www.test.com YES 3 ftp://www.test.com ftp:// .com #157 (([hH][tT]{2}[pP]|[fF][tT][pP]):\/\/)?[a-zA-Z0-9\-]+(?:\.[a-zA-Z0-9\-]+)* htTp://www.test.com YES 3 htTp://www.test.com htTp:// htTp #158 (?:([hH][tT]{2}[pP]|[fF][tT][pP]):\/\/)?[a-zA-Z0-9\-]+(\.[a-zA-Z0-9\-]+)* FTP://www.test.com YES 3 FTP://www.test.com FTP .com #159 ^(?:([hH][tT]{2}[pP]|[fF][tT][pP]):\/\/)?[a-zA-Z0-9\-]+(\.[a-zA-Z0-9\-]+)*$ http://.www.test.com NO #160 ^(?:(?:[hH][tT]{2}[pP]|[fF][tT][pP]):\/\/)?[a-zA-Z0-9\-]+(?:\.[a-zA-Z0-9\-]+)*$ FtP://www.test.com YES 1 FtP://www.test.com #161 ^(?:(?:[hH][tT]{2}[pP]|[fF][tT][pP]):\/\/)?[a-zA-Z0-9\-]+(?:\.[a-zA-Z0-9\-]+)*$ FtTP://www.test.com NO #162 ^(?:(?:[hH][tT]{2}[pP]|[fF][tT][pP]):\/\/)?[a-zA-Z0-9\-]+(?:\.[a-zA-Z0-9\-]+)*$ www.test.com YES 1 www.test.com #163 abc.*?x+yz abcaaaaaxyzbbbbxyz YES 1 abcaaaaaxyz #164 abc.+?x+yz abcaaaaaxyzbbbbxyz YES 1 abcaaaaaxyz #165 a.+?(c|d) aaaacaaaaad YES 2 aaaac c #166 a.+(c|d) aaaacaaaaad YES 2 aaaacaaaaad d #167 a+?b+?c+? aaabccaaabbbccc YES 1 aaabc #168 a(.+)b(.+)c(.+)d(.+)e(.+)f(.+)g(.+)h(.+)i(.+)j(.+)k(.+)l(.+)m(.+)n(.+)o(.+)p(.+)q(.+)r a01b02c03d04e05f06g07h08i09j10k11l12m13n14o15p16q17r YES 18 a01b02c03d04e05f06g07h08i09j10k11l12m13n14o15p16q17r 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 16 17 #169 \bfly\b flying NO #170 \bfly\b housefly NO #171 [^ac]+ bd YES 1 bd #172 [^ca]+ bd YES 1 bd #173 [^ac]+ acb YES 1 b #174 [a-z]{0,3} 123abcdefg123 YES 1 #175 ab{0,1}a aa YES 1 aa #176 ab{0,1}a aba YES 1 aba #177 ab{0,1}a abba NO #178 ab{0,2}a aa YES 1 aa #179 ab{0,2}a aba YES 1 aba #180 ab{0,2}a abba YES 1 abba #181 ab{0,2}a abbba NO #182 ab{1,1}a aa NO #183 ab{1,1}a aba YES 1 aba #184 ab{1,1}a abba NO #185 ab{1,2}a aa NO #186 ab{1,2}a aba YES 1 aba #187 ab{1,2}a abba YES 1 abba #188 ab{1,2}a abbba NO #189 ab{0,}a aa YES 1 aa #190 ab{0,}a aba YES 1 aba #191 ab{0,}a abba YES 1 abba #192 ab{1,}a aa NO #193 ab{1,}a aba YES 1 aba #194 ab{1,}a abba YES 1 abba #195 ab{1}a aa NO #196 ab{1}a aba YES 1 aba #197 ab{1}a abba NO #198 ab{0}a aa YES 1 aa #199 ab{0}a aba NO #200 ab{2}a aa NO #201 ab{2}a aba NO #202 ab{2}a abba YES 1 abba #203 ab{2}a abbba NO #204 [ \-] - YES 1 - #205 [a-z0-9\.\-]+ {regexp-1.2} YES 1 regexp-1.2 #206 [a-z0-9\-\.]+ {regexp-1.2} YES 1 regexp-1.2 #207 [a-z\-0-9\.]+ {regexp-1.2} YES 1 regexp-1.2 #208 \w+ a_b YES 1 a_b #209 ([0123])??((((1st)|(2nd))|(3rd))|(\dth)) 1st YES 6 1st null 1st 1st 1st 1st #210 [^\s\]'<>(),;:\.\[] - YES 1 - #211 ^\(?(\d{3})\)?[\- ]?(\d{3})[\- ]?(\d{4})$ (425) 576+1202 NO #212 [^\s\(\)<>@,;:\\\"\.\[\]] - YES 1 - #213 a{0,1}b{0,1}c{0,1}d{0,1}e{0,1}f{0,1}g{0,1}h{0,1}i{0,1}j{0,1}k{0,1}l{0,1} acghij YES 1 acghij #214 [^02468ACEGIKMOQSUW] 012 YES 1 1 #215 [^02468ACEGIKMOQSUW] UVW YES 1 V #216 UUID=(\w{8}\.){3}\w{8} UUID=3babc217.0007d4e1.74726163.006e616d YES 4 UUID=3babc217.0007d4e1.74726163.006e616d 3babc217. 0007d4e1. 74726163. #217 ^\d{4}(-\d{2}){2}$ 2004-01-01 YES 3 2004-01-01 -01 -01 #218 [\W] a NO #219 [\W] 1 NO #220 [\W] ! YES 1 ! #221 [^\W] a YES 1 a #222 [^\W] _ YES 1 _ #223 [\D\S]+ @0 1 _1AByz YES 1 @0 1 _1AByz #224 [^\D\S] @0 1 _1AByz NO #225 ^(a{1}){0,2}$ aa YES 3 aa a a #226 (a{1,3}b){1,3} abaabaaab YES 4 abaabaaab ab aab aaab #227 ^(1_*)??_$ 1__ YES 2 1__ 1_ #228 ^(1_*)*?_$ 1__ YES 2 1__ 1_ #229 ^(1_*)+?_$ 1__ YES 2 1__ 1_ #230 a+?b+?c+?a aaabccaaabbbccc YES 1 aaabcca #231 ^a{1,35}$ aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab NO jakarta-regexp-1.5/docs/api/allclasses-frame.html100644 0 0 3565 10577337776 17257 0ustar 0 0 All Classes All Classes
CharacterArrayCharacterIterator
CharacterIterator
RE
ReaderCharacterIterator
recompile
RECompiler
REDebugCompiler
REDemo
REProgram
RESyntaxException
RETest
RETestCase
REUtil
StreamCharacterIterator
StringCharacterIterator
jakarta-regexp-1.5/docs/api/deprecated-list.html100644 0 0 7273 10577337776 17112 0ustar 0 0 Jakarta-Regexp 1.5 API: Deprecated List

Deprecated API



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/help-doc.html100644 0 0 16504 10577337776 15551 0ustar 0 0 Jakarta-Regexp 1.5 API: API Help

How This API Document Is Organized

This API (Application Programming Interface) document has pages corresponding to the items in the navigation bar, described as follows.

Package

Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain four categories:

  • Interfaces (italic)
  • Classes
  • Exceptions
  • Errors

Class/Interface

Each class, interface, inner class and inner interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:

  • Class inheritance diagram
  • Direct Subclasses
  • All Known Subinterfaces
  • All Known Implementing Classes
  • Class/interface declaration
  • Class/interface description

  • Inner Class Summary
  • Field Summary
  • Constructor Summary
  • Method Summary

  • Field Detail
  • Constructor Detail
  • Method Detail
Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.

Use

Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.

Tree (Class Hierarchy)

There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with java.lang.Object. The interfaces do not inherit from java.lang.Object.
  • When viewing the Overview page, clicking on "Tree" displays the hierarchy for all packages.
  • When viewing a particular package, class or interface page, clicking "Tree" displays the hierarchy for only that package.

Deprecated API

The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.

Index

The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.

Prev/Next

These links take you to the next or previous class, interface, package, or related page.

Frames/No Frames

These links show and hide the HTML frames. All pages are available with or without frames.

Serialized Form

Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description.

This help file applies to API documentation generated using the standard doclet.



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/index-all.html100644 0 0 207762 10577337776 15763 0ustar 0 0 Jakarta-Regexp 1.5 API: Index
< A B C D E F G H I L M N O P R S T U

<

() - Static method in class org.apache.regexp.RECompiler
 
() - Static method in class org.apache.regexp.REDebugCompiler
 

A

allocParens() - Method in class org.apache.regexp.RE
Performs lazy allocation of subexpression arrays
assertEquals(StringBuffer, String, int, int) - Method in class org.apache.regexp.RETestCase
 
assertEquals(StringBuffer, String, String, String) - Method in class org.apache.regexp.RETestCase
 
assertEquals(String, int, int) - Method in class org.apache.regexp.RETest
 
assertEquals(String, String, String) - Method in class org.apache.regexp.RETest
 
atom() - Method in class org.apache.regexp.RECompiler
Absorb an atomic character string.

B

badPattern - Variable in class org.apache.regexp.RETestCase
 
bracket() - Method in class org.apache.regexp.RECompiler
Match bracket {m,n} expression put results in bracket member variables
bracketMin - Variable in class org.apache.regexp.RECompiler
 
bracketOpt - Variable in class org.apache.regexp.RECompiler
 
bracketUnbounded - Static variable in class org.apache.regexp.RECompiler
 
branch(int[]) - Method in class org.apache.regexp.RECompiler
Compile body of one branch of an or operator (implements concatenation)
buff - Variable in class org.apache.regexp.ReaderCharacterIterator
Buffer of read chars
buff - Variable in class org.apache.regexp.StreamCharacterIterator
Buffer of read chars

C

CharacterArrayCharacterIterator - class org.apache.regexp.CharacterArrayCharacterIterator.
Encapsulates char[] as CharacterIterator
CharacterArrayCharacterIterator(char[], int, int) - Constructor for class org.apache.regexp.CharacterArrayCharacterIterator
 
characterClass() - Method in class org.apache.regexp.RECompiler
Compile a character class
CharacterIterator - interface org.apache.regexp.CharacterIterator.
Encapsulates different types of character sources - String, InputStream, ...
charAt(int) - Method in interface org.apache.regexp.CharacterIterator
 
charAt(int) - Method in class org.apache.regexp.CharacterArrayCharacterIterator
 
charAt(int) - Method in class org.apache.regexp.ReaderCharacterIterator
 
charAt(int) - Method in class org.apache.regexp.StringCharacterIterator
 
charAt(int) - Method in class org.apache.regexp.StreamCharacterIterator
 
charToString(char) - Method in class org.apache.regexp.REDebugCompiler
Return a string describing a (possibly unprintable) character.
checkParens() - Method in class org.apache.regexp.RETestCase
 
checkResult(boolean) - Method in class org.apache.regexp.RETestCase
 
closed - Variable in class org.apache.regexp.ReaderCharacterIterator
read end?
closed - Variable in class org.apache.regexp.StreamCharacterIterator
read end?
closure(int[]) - Method in class org.apache.regexp.RECompiler
Compile a possibly closured terminal
compareChars(char, char, boolean) - Method in class org.apache.regexp.RE
Compares two characters.
compile(String) - Method in class org.apache.regexp.RECompiler
Compiles a regular expression pattern into a program runnable by the pattern matcher class 'RE'.
compiler - Variable in class org.apache.regexp.RETest
 
compiler - Variable in class org.apache.regexp.REDemo
 
complexPrefix - Static variable in class org.apache.regexp.REUtil
complex:
createRE(String) - Static method in class org.apache.regexp.REUtil
Creates a regular expression, permitting simple or complex syntax
createRE(String, int) - Static method in class org.apache.regexp.REUtil
Creates a regular expression, permitting simple or complex syntax

D

delete(int) - Method in class org.apache.regexp.RECompiler.RERange
Deletes the range at a given index from the range lists
die(String) - Method in class org.apache.regexp.RETest
Exit with a fatal error.
dumpProgram() - Method in class org.apache.regexp.REDebugCompiler
Dumps the current program to a System.out.
dumpProgram(PrintWriter) - Method in class org.apache.regexp.REDebugCompiler
Dumps the current program to a PrintWriter.

E

E_ALNUM - Static variable in class org.apache.regexp.RE
 
E_BOUND - Static variable in class org.apache.regexp.RE
 
E_DIGIT - Static variable in class org.apache.regexp.RE
 
E_NALNUM - Static variable in class org.apache.regexp.RE
 
E_NBOUND - Static variable in class org.apache.regexp.RE
 
E_NDIGIT - Static variable in class org.apache.regexp.RE
 
E_NSPACE - Static variable in class org.apache.regexp.RE
 
E_SPACE - Static variable in class org.apache.regexp.RE
 
emit(char) - Method in class org.apache.regexp.RECompiler
Emit a single character into the program stream.
end0 - Variable in class org.apache.regexp.RE
 
end1 - Variable in class org.apache.regexp.RE
 
end2 - Variable in class org.apache.regexp.RE
 
endBackref - Variable in class org.apache.regexp.RE
 
endn - Variable in class org.apache.regexp.RE
 
ensure(int) - Method in class org.apache.regexp.ReaderCharacterIterator
Reads chars up to the idx
ensure(int) - Method in class org.apache.regexp.RECompiler
Ensures that n more characters can fit in the program buffer.
ensure(int) - Method in class org.apache.regexp.StreamCharacterIterator
Reads chars up to the idx
ESC_BACKREF - Static variable in class org.apache.regexp.RECompiler
 
ESC_CLASS - Static variable in class org.apache.regexp.RECompiler
 
ESC_COMPLEX - Static variable in class org.apache.regexp.RECompiler
 
ESC_MASK - Static variable in class org.apache.regexp.RECompiler
 
escape() - Method in class org.apache.regexp.RECompiler
Match an escape sequence.
expr(int[]) - Method in class org.apache.regexp.RECompiler
Compile an expression with possible parens around it.

F

fail(String) - Method in class org.apache.regexp.RETest
Fail with an error.
fail(StringBuffer, String) - Method in class org.apache.regexp.RETest
Fail with an error.
failures - Variable in class org.apache.regexp.RETest
 
fieldMatch - Variable in class org.apache.regexp.REDemo
 
fieldRE - Variable in class org.apache.regexp.REDemo
Components
findNextTest(BufferedReader) - Method in class org.apache.regexp.RETest
Finds next test description in a given script.
flags - Variable in class org.apache.regexp.REProgram
 

G

getExpectedResult(String) - Method in class org.apache.regexp.RETest
Converts yesno string to boolean.
getInstructions() - Method in class org.apache.regexp.REProgram
Returns a copy of the current regular expression program in a character array that is exactly the right length to hold the program.
getMatchFlags() - Method in class org.apache.regexp.RE
Returns the current match behaviour flags.
getNextTestCase(BufferedReader) - Method in class org.apache.regexp.RETest
Creates testcase for the next test description in the script file.
getParen(int) - Method in class org.apache.regexp.RE
Gets the contents of a parenthesized subexpression after a successful match.
getParenCount() - Method in class org.apache.regexp.RE
Returns the number of parenthesized subexpressions available after a successful match.
getParenEnd(int) - Method in class org.apache.regexp.RE
Returns the end index of a given paren level.
getParenLength(int) - Method in class org.apache.regexp.RE
Returns the length of a given paren level.
getParenStart(int) - Method in class org.apache.regexp.RE
Returns the start index of a given paren level.
getPrefix() - Method in class org.apache.regexp.REProgram
Returns a copy of the prefix of current regular expression program in a character array.
getProgram() - Method in class org.apache.regexp.RE
Returns the current regular expression program in use by this matcher object.
grep(Object[]) - Method in class org.apache.regexp.RE
Returns an array of Strings, whose toString representation matches a regular expression.

H

hashOpcode - Static variable in class org.apache.regexp.REDebugCompiler
Mapping from opcodes to descriptive strings
hashPOSIX - Static variable in class org.apache.regexp.RECompiler
 

I

idx - Variable in class org.apache.regexp.RECompiler
 
include(char, boolean) - Method in class org.apache.regexp.RECompiler.RERange
Includes a range with the same min and max
include(int, int, boolean) - Method in class org.apache.regexp.RECompiler.RERange
Includes (or excludes) the range from min to max, inclusive.
init() - Method in class org.apache.regexp.REDemo
Add controls and init applet
instruction - Variable in class org.apache.regexp.REProgram
 
instruction - Variable in class org.apache.regexp.RECompiler
 
internalError() - Method in class org.apache.regexp.RECompiler
Throws a new internal error exception
internalError(String) - Method in class org.apache.regexp.RE
Throws an Error representing an internal error condition probably resulting from a bug in the regular expression compiler (or possibly data corruption).
is - Variable in class org.apache.regexp.StreamCharacterIterator
Underlying is
isEnd(int) - Method in interface org.apache.regexp.CharacterIterator
 
isEnd(int) - Method in class org.apache.regexp.CharacterArrayCharacterIterator
 
isEnd(int) - Method in class org.apache.regexp.ReaderCharacterIterator
 
isEnd(int) - Method in class org.apache.regexp.StringCharacterIterator
 
isEnd(int) - Method in class org.apache.regexp.StreamCharacterIterator
 
isNewline(int) - Method in class org.apache.regexp.RE
 

L

len - Variable in class org.apache.regexp.CharacterArrayCharacterIterator
used portion of the array
len - Variable in class org.apache.regexp.RECompiler
 
lenInstruction - Variable in class org.apache.regexp.REProgram
 
lenInstruction - Variable in class org.apache.regexp.RECompiler
 
log - Variable in class org.apache.regexp.RETestCase
 

M

main(String[]) - Static method in class org.apache.regexp.RETest
Main program entrypoint.
main(String[]) - Static method in class org.apache.regexp.recompile
Main application entrypoint.
main(String[]) - Static method in class org.apache.regexp.REDemo
Main application entrypoint.
MATCH_CASEINDEPENDENT - Static variable in class org.apache.regexp.RE
Flag to indicate that matching should be case-independent (folded)
MATCH_MULTILINE - Static variable in class org.apache.regexp.RE
Newlines should match as BOL/EOL (^ and $)
MATCH_NORMAL - Static variable in class org.apache.regexp.RE
Specifies normal, case-sensitive matching behaviour.
MATCH_SINGLELINE - Static variable in class org.apache.regexp.RE
Consider all input a single body of text - newlines are matched by .
match(CharacterIterator, int) - Method in class org.apache.regexp.RE
Matches the current regular expression program against a character array, starting at a given index.
match(String) - Method in class org.apache.regexp.RE
Matches the current regular expression program against a String.
match(String, int) - Method in class org.apache.regexp.RE
Matches the current regular expression program against a character array, starting at a given index.
matchAt(int) - Method in class org.apache.regexp.RE
Match the current regular expression program against the current input string, starting at index i of the input string.
matchFlags - Variable in class org.apache.regexp.RE
 
matchNodes(int, int, int) - Method in class org.apache.regexp.RE
Try to match a string against a subset of nodes in the program
MAX_PAREN - Static variable in class org.apache.regexp.RE
 
maxNode - Static variable in class org.apache.regexp.RE
 
maxParen - Variable in class org.apache.regexp.RE
 
maxParens - Variable in class org.apache.regexp.REProgram
 
maxRange - Variable in class org.apache.regexp.RECompiler.RERange
 
merge(int, int) - Method in class org.apache.regexp.RECompiler.RERange
Merges a range into the range list, coalescing ranges if possible.
minRange - Variable in class org.apache.regexp.RECompiler.RERange
 

N

NEW_LINE - Static variable in class org.apache.regexp.RETest
 
NODE_NORMAL - Static variable in class org.apache.regexp.RECompiler
 
NODE_NULLABLE - Static variable in class org.apache.regexp.RECompiler
 
NODE_TOPLEVEL - Static variable in class org.apache.regexp.RECompiler
 
node(char, int) - Method in class org.apache.regexp.RECompiler
Adds a new node
nodeInsert(char, int, int) - Method in class org.apache.regexp.RECompiler
Inserts a node with a given opcode and opdata at insertAt.
nodeSize - Static variable in class org.apache.regexp.RE
 
nodeToString(int) - Method in class org.apache.regexp.REDebugCompiler
Returns a descriptive string for a node in a regular expression program.
num - Variable in class org.apache.regexp.RECompiler.RERange
 
number - Variable in class org.apache.regexp.RETestCase
 

O

off - Variable in class org.apache.regexp.CharacterArrayCharacterIterator
offset in the char array
offsetNext - Static variable in class org.apache.regexp.RE
 
offsetOpcode - Static variable in class org.apache.regexp.RE
 
offsetOpdata - Static variable in class org.apache.regexp.RE
 
OP_ANY - Static variable in class org.apache.regexp.RE
 
OP_ANYOF - Static variable in class org.apache.regexp.RE
 
OP_ATOM - Static variable in class org.apache.regexp.RE
 
OP_BACKREF - Static variable in class org.apache.regexp.RE
 
OP_BOL - Static variable in class org.apache.regexp.RE
 
OP_BRANCH - Static variable in class org.apache.regexp.RE
 
OP_CLOSE - Static variable in class org.apache.regexp.RE
 
OP_CLOSE_CLUSTER - Static variable in class org.apache.regexp.RE
 
OP_CONTINUE - Static variable in class org.apache.regexp.RE
 
OP_END - Static variable in class org.apache.regexp.RE
* The format of a node in a program is: * * [ OPCODE ] [ OPDATA ] [ OPNEXT ] [ OPERAND ] * * char OPCODE - instruction * char OPDATA - modifying data * char OPNEXT - next node (relative offset) * *
OP_EOL - Static variable in class org.apache.regexp.RE
 
OP_ESCAPE - Static variable in class org.apache.regexp.RE
 
OP_GOTO - Static variable in class org.apache.regexp.RE
 
OP_MAYBE - Static variable in class org.apache.regexp.RE
 
OP_NOTHING - Static variable in class org.apache.regexp.RE
 
OP_OPEN - Static variable in class org.apache.regexp.RE
 
OP_OPEN_CLUSTER - Static variable in class org.apache.regexp.RE
 
OP_PLUS - Static variable in class org.apache.regexp.RE
 
OP_POSIXCLASS - Static variable in class org.apache.regexp.RE
 
OP_RELUCTANTMAYBE - Static variable in class org.apache.regexp.RE
 
OP_RELUCTANTPLUS - Static variable in class org.apache.regexp.RE
 
OP_RELUCTANTSTAR - Static variable in class org.apache.regexp.RE
 
OP_STAR - Static variable in class org.apache.regexp.RE
 
opcodeToString(char) - Method in class org.apache.regexp.REDebugCompiler
Returns a descriptive string for an opcode.
OPT_HASBACKREFS - Static variable in class org.apache.regexp.REProgram
 
OPT_HASBOL - Static variable in class org.apache.regexp.REProgram
 
org.apache.regexp - package org.apache.regexp
 
outMatch - Variable in class org.apache.regexp.REDemo
 
outRE - Variable in class org.apache.regexp.REDemo
 

P

parenCount - Variable in class org.apache.regexp.RE
 
parens - Variable in class org.apache.regexp.RETestCase
 
parens - Variable in class org.apache.regexp.RECompiler
 
pattern - Variable in class org.apache.regexp.RETestCase
 
pattern - Variable in class org.apache.regexp.RECompiler
 
POSIX_CLASS_ALNUM - Static variable in class org.apache.regexp.RE
 
POSIX_CLASS_ALPHA - Static variable in class org.apache.regexp.RE
 
POSIX_CLASS_BLANK - Static variable in class org.apache.regexp.RE
 
POSIX_CLASS_CNTRL - Static variable in class org.apache.regexp.RE
 
POSIX_CLASS_DIGIT - Static variable in class org.apache.regexp.RE
 
POSIX_CLASS_GRAPH - Static variable in class org.apache.regexp.RE
 
POSIX_CLASS_JPART - Static variable in class org.apache.regexp.RE
 
POSIX_CLASS_JSTART - Static variable in class org.apache.regexp.RE
 
POSIX_CLASS_LOWER - Static variable in class org.apache.regexp.RE
 
POSIX_CLASS_PRINT - Static variable in class org.apache.regexp.RE
 
POSIX_CLASS_PUNCT - Static variable in class org.apache.regexp.RE
 
POSIX_CLASS_SPACE - Static variable in class org.apache.regexp.RE
 
POSIX_CLASS_UPPER - Static variable in class org.apache.regexp.RE
 
POSIX_CLASS_XDIGIT - Static variable in class org.apache.regexp.RE
 
prefix - Variable in class org.apache.regexp.REProgram
 
program - Variable in class org.apache.regexp.RE
 

R

r - Variable in class org.apache.regexp.REDemo
Matcher and compiler objects
RE - class org.apache.regexp.RE.
RE is an efficient, lightweight regular expression evaluator/matcher class.
RE() - Constructor for class org.apache.regexp.RE
Constructs a regular expression matcher with no initial program.
RE(REProgram) - Constructor for class org.apache.regexp.RE
Construct a matcher for a pre-compiled regular expression from program (bytecode) data.
RE(REProgram, int) - Constructor for class org.apache.regexp.RE
Construct a matcher for a pre-compiled regular expression from program (bytecode) data.
RE(String) - Constructor for class org.apache.regexp.RE
Constructs a regular expression matcher from a String by compiling it using a new instance of RECompiler.
RE(String, int) - Constructor for class org.apache.regexp.RE
Constructs a regular expression matcher from a String by compiling it using a new instance of RECompiler.
read(int) - Method in class org.apache.regexp.ReaderCharacterIterator
Reads n characters from the stream and appends them to the buffer
read(int) - Method in class org.apache.regexp.StreamCharacterIterator
Reads n characters from the stream and appends them to the buffer
readAll() - Method in class org.apache.regexp.ReaderCharacterIterator
Reads rest of the stream.
readAll() - Method in class org.apache.regexp.StreamCharacterIterator
Reads rest of the stream.
reader - Variable in class org.apache.regexp.ReaderCharacterIterator
Underlying reader
ReaderCharacterIterator - class org.apache.regexp.ReaderCharacterIterator.
Encapsulates java.io.Reader as CharacterIterator
ReaderCharacterIterator(Reader) - Constructor for class org.apache.regexp.ReaderCharacterIterator
 
recompile - class org.apache.regexp.recompile.
'recompile' is a command line tool that pre-compiles one or more regular expressions for use with the regular expression matcher class 'RE'.
recompile() - Constructor for class org.apache.regexp.recompile
 
RECompiler - class org.apache.regexp.RECompiler.
A regular expression compiler class.
RECompiler.RERange - class org.apache.regexp.RECompiler.RERange.
Local, nested class for maintaining character ranges for character classes.
RECompiler.RERange(RECompiler) - Constructor for class org.apache.regexp.RECompiler.RERange
 
RECompiler() - Constructor for class org.apache.regexp.RECompiler
Constructor.
REDebugCompiler - class org.apache.regexp.REDebugCompiler.
A subclass of RECompiler which can dump a regular expression program for debugging purposes.
REDebugCompiler() - Constructor for class org.apache.regexp.REDebugCompiler
 
REDemo - class org.apache.regexp.REDemo.
Interactive demonstration and testing harness for regular expressions classes.
REDemo() - Constructor for class org.apache.regexp.REDemo
 
regexp - Variable in class org.apache.regexp.RETestCase
 
remove(int, int) - Method in class org.apache.regexp.RECompiler.RERange
Removes a range by deleting or shrinking all other ranges
REPLACE_ALL - Static variable in class org.apache.regexp.RE
Flag bit that indicates that subst should replace all occurrences of this regular expression.
REPLACE_BACKREFERENCES - Static variable in class org.apache.regexp.RE
Flag bit that indicates that subst should replace backreferences
REPLACE_FIRSTONLY - Static variable in class org.apache.regexp.RE
Flag bit that indicates that subst should only replace the first occurrence of this regular expression.
REProgram - class org.apache.regexp.REProgram.
A class that holds compiled regular expressions.
REProgram(char[]) - Constructor for class org.apache.regexp.REProgram
Constructs a program object from a character array
REProgram(char[], int) - Constructor for class org.apache.regexp.REProgram
Constructs a program object from a character array
REProgram(int, char[]) - Constructor for class org.apache.regexp.REProgram
Constructs a program object from a character array
RESyntaxException - exception org.apache.regexp.RESyntaxException.
Exception thrown to indicate a syntax error in a regular expression.
RESyntaxException(String) - Constructor for class org.apache.regexp.RESyntaxException
Constructor.
RETest - class org.apache.regexp.RETest.
Data driven (and optionally interactive) testing harness to exercise regular expression compiler and matching engine.
RETest() - Constructor for class org.apache.regexp.RETest
Constructor
RETestCase - class org.apache.regexp.RETestCase.
 
RETestCase(RETest, String, String, String, boolean, boolean, String[]) - Constructor for class org.apache.regexp.RETestCase
 
REUtil - class org.apache.regexp.REUtil.
This is a class that contains utility helper methods for this package.
REUtil() - Constructor for class org.apache.regexp.REUtil
 
runAutomatedTests(String) - Method in class org.apache.regexp.RETest
Run automated tests in RETest.txt file (from Perl 4.0 test battery)
runInteractiveTests(String) - Method in class org.apache.regexp.RETest
Compile and test matching against a single expression
runTest() - Method in class org.apache.regexp.RETestCase
 

S

say(String) - Method in class org.apache.regexp.RETest
Say something to standard out
sayMatch(String) - Method in class org.apache.regexp.REDemo
Say something into match text area
sayRE(String) - Method in class org.apache.regexp.REDemo
Say something into RE text area
search - Variable in class org.apache.regexp.RE
 
setInstructions(char[], int) - Method in class org.apache.regexp.REProgram
Sets a new regular expression program to run.
setMatchFlags(int) - Method in class org.apache.regexp.RE
Sets match behaviour flags which alter the way RE does matching.
setNextOfEnd(int, int) - Method in class org.apache.regexp.RECompiler
Appends a node to the end of a node chain
setParenEnd(int, int) - Method in class org.apache.regexp.RE
Sets the end of a paren level
setParenStart(int, int) - Method in class org.apache.regexp.RE
Sets the start of a paren level
setProgram(REProgram) - Method in class org.apache.regexp.RE
Sets the current regular expression program used by this matcher object.
shouldMatch - Variable in class org.apache.regexp.RETestCase
 
showParens(RE) - Method in class org.apache.regexp.RETest
Dump parenthesized subexpressions found by a regular expression matcher object
showSuccesses - Static variable in class org.apache.regexp.RETest
 
simplePatternToFullRegularExpression(String) - Static method in class org.apache.regexp.RE
Converts a 'simplified' regular expression to a full regular expression
size - Variable in class org.apache.regexp.RECompiler.RERange
 
split(String) - Method in class org.apache.regexp.RE
Splits a string into an array of strings on regular expression boundaries.
src - Variable in class org.apache.regexp.CharacterArrayCharacterIterator
encapsulated
src - Variable in class org.apache.regexp.StringCharacterIterator
encapsulated
start0 - Variable in class org.apache.regexp.RE
 
start1 - Variable in class org.apache.regexp.RE
 
start2 - Variable in class org.apache.regexp.RE
 
startBackref - Variable in class org.apache.regexp.RE
 
startn - Variable in class org.apache.regexp.RE
 
StreamCharacterIterator - class org.apache.regexp.StreamCharacterIterator.
Encapsulates java.io.InputStream as CharacterIterator.
StreamCharacterIterator(InputStream) - Constructor for class org.apache.regexp.StreamCharacterIterator
 
StringCharacterIterator - class org.apache.regexp.StringCharacterIterator.
Encapsulates String as CharacterIterator.
StringCharacterIterator(String) - Constructor for class org.apache.regexp.StringCharacterIterator
 
subst(String, String) - Method in class org.apache.regexp.RE
Substitutes a string for this regular expression in another string.
subst(String, String, int) - Method in class org.apache.regexp.RE
Substitutes a string for this regular expression in another string.
substring(int) - Method in interface org.apache.regexp.CharacterIterator
 
substring(int) - Method in class org.apache.regexp.CharacterArrayCharacterIterator
 
substring(int) - Method in class org.apache.regexp.ReaderCharacterIterator
 
substring(int) - Method in class org.apache.regexp.StringCharacterIterator
 
substring(int) - Method in class org.apache.regexp.StreamCharacterIterator
 
substring(int, int) - Method in interface org.apache.regexp.CharacterIterator
 
substring(int, int) - Method in class org.apache.regexp.CharacterArrayCharacterIterator
 
substring(int, int) - Method in class org.apache.regexp.ReaderCharacterIterator
 
substring(int, int) - Method in class org.apache.regexp.StringCharacterIterator
 
substring(int, int) - Method in class org.apache.regexp.StreamCharacterIterator
 
success(String) - Method in class org.apache.regexp.RETestCase
Show a success
syntaxError(String) - Method in class org.apache.regexp.RECompiler
Throws a new syntax error exception

T

tag - Variable in class org.apache.regexp.RETestCase
 
terminal(int[]) - Method in class org.apache.regexp.RECompiler
Match a terminal node.
test - Variable in class org.apache.regexp.RETestCase
 
test(String[]) - Static method in class org.apache.regexp.RETest
Testing entrypoint.
testCount - Variable in class org.apache.regexp.RETest
 
testCreation() - Method in class org.apache.regexp.RETestCase
 
testMatch() - Method in class org.apache.regexp.RETestCase
 
testOther() - Method in class org.apache.regexp.RETest
Run automated unit test
testPrecompiledRE() - Method in class org.apache.regexp.RETest
 
testSplitAndGrep() - Method in class org.apache.regexp.RETest
 
testSubst() - Method in class org.apache.regexp.RETest
 
textValueChanged(TextEvent) - Method in class org.apache.regexp.REDemo
Called when text values change
throwableToString(Throwable) - Method in class org.apache.regexp.REDemo
Convert throwable to string
toMatch - Variable in class org.apache.regexp.RETestCase
 
tryMatchUsingCI(CharacterIterator) - Method in class org.apache.regexp.RETestCase
 

U

updateMatch(String) - Method in class org.apache.regexp.REDemo
Update matching info by matching the string against the current compiled regular expression.
updateRE(String) - Method in class org.apache.regexp.REDemo
Change regular expression

< A B C D E F G H I L M N O P R S T U

Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/index.html100644 0 0 1256 10577337776 15143 0ustar 0 0 Jakarta-Regexp 1.5 API <H2> Frame Alert</H2> <P> This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. <BR> Link to <A HREF="org/apache/regexp/package-summary.html">Non-frame version.</A> jakarta-regexp-1.5/docs/api/org/apache/regexp/CharacterArrayCharacterIterator.html100644 0 0 33253 10577337776 25602 0ustar 0 0 Jakarta-Regexp 1.5 API: Class CharacterArrayCharacterIterator

org.apache.regexp
Class CharacterArrayCharacterIterator

java.lang.Object
  |
  +--org.apache.regexp.CharacterArrayCharacterIterator
All Implemented Interfaces:
CharacterIterator

public final class CharacterArrayCharacterIterator
extends java.lang.Object
implements CharacterIterator

Encapsulates char[] as CharacterIterator

Version:
CVS $Id: CharacterArrayCharacterIterator.java 518156 2007-03-14 14:31:26Z vgritsenko $
Author:
Ales Novak

Field Summary
private  int len
          used portion of the array
private  int off
          offset in the char array
private  char[] src
          encapsulated
 
Constructor Summary
CharacterArrayCharacterIterator(char[] src, int off, int len)
           
 
Method Summary
 char charAt(int pos)
           
 boolean isEnd(int pos)
           
 java.lang.String substring(int beginIndex)
           
 java.lang.String substring(int beginIndex, int endIndex)
           
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

src

private final char[] src
encapsulated

off

private final int off
offset in the char array

len

private final int len
used portion of the array
Constructor Detail

CharacterArrayCharacterIterator

public CharacterArrayCharacterIterator(char[] src,
                                       int off,
                                       int len)
Parameters:
src - - encapsulated String
Method Detail

substring

public java.lang.String substring(int beginIndex,
                                  int endIndex)
Specified by:
substring in interface CharacterIterator
Returns:
a substring

substring

public java.lang.String substring(int beginIndex)
Specified by:
substring in interface CharacterIterator
Returns:
a substring

charAt

public char charAt(int pos)
Specified by:
charAt in interface CharacterIterator
Returns:
a character at the specified position.

isEnd

public boolean isEnd(int pos)
Specified by:
isEnd in interface CharacterIterator
Returns:
true iff if the specified index is after the end of the character stream


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/CharacterIterator.html100644 0 0 21401 10577337776 22756 0ustar 0 0 Jakarta-Regexp 1.5 API: Interface CharacterIterator

org.apache.regexp
Interface CharacterIterator

All Known Implementing Classes:
CharacterArrayCharacterIterator, ReaderCharacterIterator, StringCharacterIterator, StreamCharacterIterator

public interface CharacterIterator

Encapsulates different types of character sources - String, InputStream, ... Defines a set of common methods

Version:
CVS $Id: CharacterIterator.java 518156 2007-03-14 14:31:26Z vgritsenko $
Author:
Ales Novak

Method Summary
 char charAt(int pos)
           
 boolean isEnd(int pos)
           
 java.lang.String substring(int beginIndex)
           
 java.lang.String substring(int beginIndex, int endIndex)
           
 

Method Detail

substring

public java.lang.String substring(int beginIndex,
                                  int endIndex)
Returns:
a substring

substring

public java.lang.String substring(int beginIndex)
Returns:
a substring

charAt

public char charAt(int pos)
Returns:
a character at the specified position.

isEnd

public boolean isEnd(int pos)
Returns:
true iff if the specified index is after the end of the character stream


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/RE.html100644 0 0 247107 10577337776 17713 0ustar 0 0 Jakarta-Regexp 1.5 API: Class RE

org.apache.regexp
Class RE

java.lang.Object
  |
  +--org.apache.regexp.RE
All Implemented Interfaces:
java.io.Serializable

public class RE
extends java.lang.Object
implements java.io.Serializable

RE is an efficient, lightweight regular expression evaluator/matcher class. Regular expressions are pattern descriptions which enable sophisticated matching of strings. In addition to being able to match a string against a pattern, you can also extract parts of the match. This is especially useful in text parsing! Details on the syntax of regular expression patterns are given below.

To compile a regular expression (RE), you can simply construct an RE matcher object from the string specification of the pattern, like this:

  RE r = new RE("a*b");
 

Once you have done this, you can call either of the RE.match methods to perform matching on a String. For example:

  boolean matched = r.match("aaaab");
 
will cause the boolean matched to be set to true because the pattern "a*b" matches the string "aaaab".

If you were interested in the number of a's which matched the first part of our example expression, you could change the expression to "(a*)b". Then when you compiled the expression and matched it against something like "xaaaab", you would get results like this:

  RE r = new RE("(a*)b");                  // Compile expression
  boolean matched = r.match("xaaaab");     // Match against "xaaaab"

  String wholeExpr = r.getParen(0);        // wholeExpr will be 'aaaab'
  String insideParens = r.getParen(1);     // insideParens will be 'aaaa'

  int startWholeExpr = r.getParenStart(0); // startWholeExpr will be index 1
  int endWholeExpr = r.getParenEnd(0);     // endWholeExpr will be index 6
  int lenWholeExpr = r.getParenLength(0);  // lenWholeExpr will be 5

  int startInside = r.getParenStart(1);    // startInside will be index 1
  int endInside = r.getParenEnd(1);        // endInside will be index 5
  int lenInside = r.getParenLength(1);     // lenInside will be 4
 
You can also refer to the contents of a parenthesized expression within a regular expression itself. This is called a 'backreference'. The first backreference in a regular expression is denoted by \1, the second by \2 and so on. So the expression:
  ([0-9]+)=\1
 
will match any string of the form n=n (like 0=0 or 2=2).

The full regular expression syntax accepted by RE is described here:


  Characters

    unicodeChar   Matches any identical unicode character
    \                    Used to quote a meta-character (like '*')
    \\                   Matches a single '\' character
    \0nnn                Matches a given octal character
    \xhh                 Matches a given 8-bit hexadecimal character
    \\uhhhh              Matches a given 16-bit hexadecimal character
    \t                   Matches an ASCII tab character
    \n                   Matches an ASCII newline character
    \r                   Matches an ASCII return character
    \f                   Matches an ASCII form feed character


  Character Classes

    [abc]                Simple character class
    [a-zA-Z]             Character class with ranges
    [^abc]               Negated character class
 
NOTE: Incomplete ranges will be interpreted as "starts from zero" or "ends with last character".
I.e. [-a] is the same as [\\u0000-a], and [a-] is the same as [a-\\uFFFF], [-] means "all characters".

  Standard POSIX Character Classes

    [:alnum:]            Alphanumeric characters.
    [:alpha:]            Alphabetic characters.
    [:blank:]            Space and tab characters.
    [:cntrl:]            Control characters.
    [:digit:]            Numeric characters.
    [:graph:]            Characters that are printable and are also visible.
                         (A space is printable, but not visible, while an
                         `a' is both.)
    [:lower:]            Lower-case alphabetic characters.
    [:print:]            Printable characters (characters that are not
                         control characters.)
    [:punct:]            Punctuation characters (characters that are not letter,
                         digits, control characters, or space characters).
    [:space:]            Space characters (such as space, tab, and formfeed,
                         to name a few).
    [:upper:]            Upper-case alphabetic characters.
    [:xdigit:]           Characters that are hexadecimal digits.


  Non-standard POSIX-style Character Classes

    [:javastart:]        Start of a Java identifier
    [:javapart:]         Part of a Java identifier


  Predefined Classes

    .         Matches any character other than newline
    \w        Matches a "word" character (alphanumeric plus "_")
    \W        Matches a non-word character
    \s        Matches a whitespace character
    \S        Matches a non-whitespace character
    \d        Matches a digit character
    \D        Matches a non-digit character


  Boundary Matchers

    ^         Matches only at the beginning of a line
    $         Matches only at the end of a line
    \b        Matches only at a word boundary
    \B        Matches only at a non-word boundary


  Greedy Closures

    A*        Matches A 0 or more times (greedy)
    A+        Matches A 1 or more times (greedy)
    A?        Matches A 1 or 0 times (greedy)
    A{n}      Matches A exactly n times (greedy)
    A{n,}     Matches A at least n times (greedy)
    A{n,m}    Matches A at least n but not more than m times (greedy)


  Reluctant Closures

    A*?       Matches A 0 or more times (reluctant)
    A+?       Matches A 1 or more times (reluctant)
    A??       Matches A 0 or 1 times (reluctant)


  Logical Operators

    AB        Matches A followed by B
    A|B       Matches either A or B
    (A)       Used for subexpression grouping
   (?:A)      Used for subexpression clustering (just like grouping but
              no backrefs)


  Backreferences

    \1    Backreference to 1st parenthesized subexpression
    \2    Backreference to 2nd parenthesized subexpression
    \3    Backreference to 3rd parenthesized subexpression
    \4    Backreference to 4th parenthesized subexpression
    \5    Backreference to 5th parenthesized subexpression
    \6    Backreference to 6th parenthesized subexpression
    \7    Backreference to 7th parenthesized subexpression
    \8    Backreference to 8th parenthesized subexpression
    \9    Backreference to 9th parenthesized subexpression
 

All closure operators (+, *, ?, {m,n}) are greedy by default, meaning that they match as many elements of the string as possible without causing the overall match to fail. If you want a closure to be reluctant (non-greedy), you can simply follow it with a '?'. A reluctant closure will match as few elements of the string as possible when finding matches. {m,n} closures don't currently support reluctancy.

Line terminators
A line terminator is a one- or two-character sequence that marks the end of a line of the input character sequence. The following are recognized as line terminators:

RE runs programs compiled by the RECompiler class. But the RE matcher class does not include the actual regular expression compiler for reasons of efficiency. In fact, if you want to pre-compile one or more regular expressions, the 'recompile' class can be invoked from the command line to produce compiled output like this:

    // Pre-compiled regular expression "a*b"
    char[] re1Instructions =
    {
        0x007c, 0x0000, 0x001a, 0x007c, 0x0000, 0x000d, 0x0041,
        0x0001, 0x0004, 0x0061, 0x007c, 0x0000, 0x0003, 0x0047,
        0x0000, 0xfff6, 0x007c, 0x0000, 0x0003, 0x004e, 0x0000,
        0x0003, 0x0041, 0x0001, 0x0004, 0x0062, 0x0045, 0x0000,
        0x0000,
    };


    REProgram re1 = new REProgram(re1Instructions);
 
You can then construct a regular expression matcher (RE) object from the pre-compiled expression re1 and thus avoid the overhead of compiling the expression at runtime. If you require more dynamic regular expressions, you can construct a single RECompiler object and re-use it to compile each expression. Similarly, you can change the program run by a given matcher object at any time. However, RE and RECompiler are not threadsafe (for efficiency reasons, and because requiring thread safety in this class is deemed to be a rare requirement), so you will need to construct a separate compiler or matcher object for each thread (unless you do thread synchronization yourself). Once expression compiled into the REProgram object, REProgram can be safely shared across multiple threads and RE objects.


ISSUES:

Version:
$Id: RE.java 518156 2007-03-14 14:31:26Z vgritsenko $
Author:
Jonathan Locke, Tobias Schäfer
See Also:
recompile, RECompiler, Serialized Form

Field Summary
(package private) static char E_ALNUM
           
(package private) static char E_BOUND
           
(package private) static char E_DIGIT
           
(package private) static char E_NALNUM
           
(package private) static char E_NBOUND
           
(package private) static char E_NDIGIT
           
(package private) static char E_NSPACE
           
(package private) static char E_SPACE
           
(package private)  int end0
           
(package private)  int end1
           
(package private)  int end2
           
(package private)  int[] endBackref
           
(package private)  int[] endn
           
static int MATCH_CASEINDEPENDENT
          Flag to indicate that matching should be case-independent (folded)
static int MATCH_MULTILINE
          Newlines should match as BOL/EOL (^ and $)
static int MATCH_NORMAL
          Specifies normal, case-sensitive matching behaviour.
static int MATCH_SINGLELINE
          Consider all input a single body of text - newlines are matched by .
(package private)  int matchFlags
           
(package private) static int MAX_PAREN
           
(package private) static int maxNode
           
(package private)  int maxParen
           
(package private) static int nodeSize
           
(package private) static int offsetNext
           
(package private) static int offsetOpcode
           
(package private) static int offsetOpdata
           
(package private) static char OP_ANY
           
(package private) static char OP_ANYOF
           
(package private) static char OP_ATOM
           
(package private) static char OP_BACKREF
           
(package private) static char OP_BOL
           
(package private) static char OP_BRANCH
           
(package private) static char OP_CLOSE
           
(package private) static char OP_CLOSE_CLUSTER
           
(package private) static char OP_CONTINUE
           
(package private) static char OP_END
          * The format of a node in a program is: * * [ OPCODE ] [ OPDATA ] [ OPNEXT ] [ OPERAND ] * * char OPCODE - instruction * char OPDATA - modifying data * char OPNEXT - next node (relative offset) * *
(package private) static char OP_EOL
           
(package private) static char OP_ESCAPE
           
(package private) static char OP_GOTO
           
(package private) static char OP_MAYBE
           
(package private) static char OP_NOTHING
           
(package private) static char OP_OPEN
           
(package private) static char OP_OPEN_CLUSTER
           
(package private) static char OP_PLUS
           
(package private) static char OP_POSIXCLASS
           
(package private) static char OP_RELUCTANTMAYBE
           
(package private) static char OP_RELUCTANTPLUS
           
(package private) static char OP_RELUCTANTSTAR
           
(package private) static char OP_STAR
           
(package private)  int parenCount
           
(package private) static char POSIX_CLASS_ALNUM
           
(package private) static char POSIX_CLASS_ALPHA
           
(package private) static char POSIX_CLASS_BLANK
           
(package private) static char POSIX_CLASS_CNTRL
           
(package private) static char POSIX_CLASS_DIGIT
           
(package private) static char POSIX_CLASS_GRAPH
           
(package private) static char POSIX_CLASS_JPART
           
(package private) static char POSIX_CLASS_JSTART
           
(package private) static char POSIX_CLASS_LOWER
           
(package private) static char POSIX_CLASS_PRINT
           
(package private) static char POSIX_CLASS_PUNCT
           
(package private) static char POSIX_CLASS_SPACE
           
(package private) static char POSIX_CLASS_UPPER
           
(package private) static char POSIX_CLASS_XDIGIT
           
(package private)  REProgram program
           
static int REPLACE_ALL
          Flag bit that indicates that subst should replace all occurrences of this regular expression.
static int REPLACE_BACKREFERENCES
          Flag bit that indicates that subst should replace backreferences
static int REPLACE_FIRSTONLY
          Flag bit that indicates that subst should only replace the first occurrence of this regular expression.
(package private)  CharacterIterator search
           
(package private)  int start0
           
(package private)  int start1
           
(package private)  int start2
           
(package private)  int[] startBackref
           
(package private)  int[] startn
           
 
Constructor Summary
RE()
          Constructs a regular expression matcher with no initial program.
RE(REProgram program)
          Construct a matcher for a pre-compiled regular expression from program (bytecode) data.
RE(REProgram program, int matchFlags)
          Construct a matcher for a pre-compiled regular expression from program (bytecode) data.
RE(java.lang.String pattern)
          Constructs a regular expression matcher from a String by compiling it using a new instance of RECompiler.
RE(java.lang.String pattern, int matchFlags)
          Constructs a regular expression matcher from a String by compiling it using a new instance of RECompiler.
 
Method Summary
private  void allocParens()
          Performs lazy allocation of subexpression arrays
private  int compareChars(char c1, char c2, boolean caseIndependent)
          Compares two characters.
 int getMatchFlags()
          Returns the current match behaviour flags.
 java.lang.String getParen(int which)
          Gets the contents of a parenthesized subexpression after a successful match.
 int getParenCount()
          Returns the number of parenthesized subexpressions available after a successful match.
 int getParenEnd(int which)
          Returns the end index of a given paren level.
 int getParenLength(int which)
          Returns the length of a given paren level.
 int getParenStart(int which)
          Returns the start index of a given paren level.
 REProgram getProgram()
          Returns the current regular expression program in use by this matcher object.
 java.lang.String[] grep(java.lang.Object[] search)
          Returns an array of Strings, whose toString representation matches a regular expression.
protected  void internalError(java.lang.String s)
          Throws an Error representing an internal error condition probably resulting from a bug in the regular expression compiler (or possibly data corruption).
private  boolean isNewline(int i)
           
 boolean match(CharacterIterator search, int i)
          Matches the current regular expression program against a character array, starting at a given index.
 boolean match(java.lang.String search)
          Matches the current regular expression program against a String.
 boolean match(java.lang.String search, int i)
          Matches the current regular expression program against a character array, starting at a given index.
protected  boolean matchAt(int i)
          Match the current regular expression program against the current input string, starting at index i of the input string.
protected  int matchNodes(int firstNode, int lastNode, int idxStart)
          Try to match a string against a subset of nodes in the program
 void setMatchFlags(int matchFlags)
          Sets match behaviour flags which alter the way RE does matching.
protected  void setParenEnd(int which, int i)
          Sets the end of a paren level
protected  void setParenStart(int which, int i)
          Sets the start of a paren level
 void setProgram(REProgram program)
          Sets the current regular expression program used by this matcher object.
static java.lang.String simplePatternToFullRegularExpression(java.lang.String pattern)
          Converts a 'simplified' regular expression to a full regular expression
 java.lang.String[] split(java.lang.String s)
          Splits a string into an array of strings on regular expression boundaries.
 java.lang.String subst(java.lang.String substituteIn, java.lang.String substitution)
          Substitutes a string for this regular expression in another string.
 java.lang.String subst(java.lang.String substituteIn, java.lang.String substitution, int flags)
          Substitutes a string for this regular expression in another string.
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

MATCH_NORMAL

public static final int MATCH_NORMAL
Specifies normal, case-sensitive matching behaviour.

MATCH_CASEINDEPENDENT

public static final int MATCH_CASEINDEPENDENT
Flag to indicate that matching should be case-independent (folded)

MATCH_MULTILINE

public static final int MATCH_MULTILINE
Newlines should match as BOL/EOL (^ and $)

MATCH_SINGLELINE

public static final int MATCH_SINGLELINE
Consider all input a single body of text - newlines are matched by .

OP_END

static final char OP_END
* The format of a node in a program is: * * [ OPCODE ] [ OPDATA ] [ OPNEXT ] [ OPERAND ] * * char OPCODE - instruction * char OPDATA - modifying data * char OPNEXT - next node (relative offset) * *

OP_BOL

static final char OP_BOL

OP_EOL

static final char OP_EOL

OP_ANY

static final char OP_ANY

OP_ANYOF

static final char OP_ANYOF

OP_BRANCH

static final char OP_BRANCH

OP_ATOM

static final char OP_ATOM

OP_STAR

static final char OP_STAR

OP_PLUS

static final char OP_PLUS

OP_MAYBE

static final char OP_MAYBE

OP_ESCAPE

static final char OP_ESCAPE

OP_OPEN

static final char OP_OPEN

OP_OPEN_CLUSTER

static final char OP_OPEN_CLUSTER

OP_CLOSE

static final char OP_CLOSE

OP_CLOSE_CLUSTER

static final char OP_CLOSE_CLUSTER

OP_BACKREF

static final char OP_BACKREF

OP_GOTO

static final char OP_GOTO

OP_NOTHING

static final char OP_NOTHING

OP_CONTINUE

static final char OP_CONTINUE

OP_RELUCTANTSTAR

static final char OP_RELUCTANTSTAR

OP_RELUCTANTPLUS

static final char OP_RELUCTANTPLUS

OP_RELUCTANTMAYBE

static final char OP_RELUCTANTMAYBE

OP_POSIXCLASS

static final char OP_POSIXCLASS

E_ALNUM

static final char E_ALNUM

E_NALNUM

static final char E_NALNUM

E_BOUND

static final char E_BOUND

E_NBOUND

static final char E_NBOUND

E_SPACE

static final char E_SPACE

E_NSPACE

static final char E_NSPACE

E_DIGIT

static final char E_DIGIT

E_NDIGIT

static final char E_NDIGIT

POSIX_CLASS_ALNUM

static final char POSIX_CLASS_ALNUM

POSIX_CLASS_ALPHA

static final char POSIX_CLASS_ALPHA

POSIX_CLASS_BLANK

static final char POSIX_CLASS_BLANK

POSIX_CLASS_CNTRL

static final char POSIX_CLASS_CNTRL

POSIX_CLASS_DIGIT

static final char POSIX_CLASS_DIGIT

POSIX_CLASS_GRAPH

static final char POSIX_CLASS_GRAPH

POSIX_CLASS_LOWER

static final char POSIX_CLASS_LOWER

POSIX_CLASS_PRINT

static final char POSIX_CLASS_PRINT

POSIX_CLASS_PUNCT

static final char POSIX_CLASS_PUNCT

POSIX_CLASS_SPACE

static final char POSIX_CLASS_SPACE

POSIX_CLASS_UPPER

static final char POSIX_CLASS_UPPER

POSIX_CLASS_XDIGIT

static final char POSIX_CLASS_XDIGIT

POSIX_CLASS_JSTART

static final char POSIX_CLASS_JSTART

POSIX_CLASS_JPART

static final char POSIX_CLASS_JPART

maxNode

static final int maxNode

MAX_PAREN

static final int MAX_PAREN

offsetOpcode

static final int offsetOpcode

offsetOpdata

static final int offsetOpdata

offsetNext

static final int offsetNext

nodeSize

static final int nodeSize

program

REProgram program

search

transient CharacterIterator search

matchFlags

int matchFlags

maxParen

int maxParen

parenCount

transient int parenCount

start0

transient int start0

end0

transient int end0

start1

transient int start1

end1

transient int end1

start2

transient int start2

end2

transient int end2

startn

transient int[] startn

endn

transient int[] endn

startBackref

transient int[] startBackref

endBackref

transient int[] endBackref

REPLACE_ALL

public static final int REPLACE_ALL
Flag bit that indicates that subst should replace all occurrences of this regular expression.

REPLACE_FIRSTONLY

public static final int REPLACE_FIRSTONLY
Flag bit that indicates that subst should only replace the first occurrence of this regular expression.

REPLACE_BACKREFERENCES

public static final int REPLACE_BACKREFERENCES
Flag bit that indicates that subst should replace backreferences
Constructor Detail

RE

public RE(java.lang.String pattern)
   throws RESyntaxException
Constructs a regular expression matcher from a String by compiling it using a new instance of RECompiler. If you will be compiling many expressions, you may prefer to use a single RECompiler object instead.
Parameters:
pattern - The regular expression pattern to compile.
Throws:
RESyntaxException - Thrown if the regular expression has invalid syntax.
See Also:
RECompiler, recompile

RE

public RE(java.lang.String pattern,
          int matchFlags)
   throws RESyntaxException
Constructs a regular expression matcher from a String by compiling it using a new instance of RECompiler. If you will be compiling many expressions, you may prefer to use a single RECompiler object instead.
Parameters:
pattern - The regular expression pattern to compile.
matchFlags - The matching style
Throws:
RESyntaxException - Thrown if the regular expression has invalid syntax.
See Also:
RECompiler, recompile

RE

public RE(REProgram program,
          int matchFlags)
Construct a matcher for a pre-compiled regular expression from program (bytecode) data. Permits special flags to be passed in to modify matching behaviour.
Parameters:
program - Compiled regular expression program (see RECompiler and/or recompile)
matchFlags - One or more of the RE match behaviour flags (RE.MATCH_*):
   MATCH_NORMAL              // Normal (case-sensitive) matching
   MATCH_CASEINDEPENDENT     // Case folded comparisons
   MATCH_MULTILINE           // Newline matches as BOL/EOL
 
See Also:
RECompiler, REProgram, recompile

RE

public RE(REProgram program)
Construct a matcher for a pre-compiled regular expression from program (bytecode) data.
Parameters:
program - Compiled regular expression program
See Also:
RECompiler, recompile

RE

public RE()
Constructs a regular expression matcher with no initial program. This is likely to be an uncommon practice, but is still supported.
Method Detail

simplePatternToFullRegularExpression

public static java.lang.String simplePatternToFullRegularExpression(java.lang.String pattern)
Converts a 'simplified' regular expression to a full regular expression
Parameters:
pattern - The pattern to convert
Returns:
The full regular expression

setMatchFlags

public void setMatchFlags(int matchFlags)
Sets match behaviour flags which alter the way RE does matching.
Parameters:
matchFlags - One or more of the RE match behaviour flags (RE.MATCH_*):
   MATCH_NORMAL              // Normal (case-sensitive) matching
   MATCH_CASEINDEPENDENT     // Case folded comparisons
   MATCH_MULTILINE           // Newline matches as BOL/EOL
 

getMatchFlags

public int getMatchFlags()
Returns the current match behaviour flags.
Returns:
Current match behaviour flags (RE.MATCH_*).
   MATCH_NORMAL              // Normal (case-sensitive) matching
   MATCH_CASEINDEPENDENT     // Case folded comparisons
   MATCH_MULTILINE           // Newline matches as BOL/EOL
 
See Also:
setMatchFlags(int)

setProgram

public void setProgram(REProgram program)
Sets the current regular expression program used by this matcher object.
Parameters:
program - Regular expression program compiled by RECompiler.
See Also:
RECompiler, REProgram, recompile

getProgram

public REProgram getProgram()
Returns the current regular expression program in use by this matcher object.
Returns:
Regular expression program
See Also:
setProgram(org.apache.regexp.REProgram)

getParenCount

public int getParenCount()
Returns the number of parenthesized subexpressions available after a successful match.
Returns:
Number of available parenthesized subexpressions

getParen

public java.lang.String getParen(int which)
Gets the contents of a parenthesized subexpression after a successful match.
Parameters:
which - Nesting level of subexpression
Returns:
String

getParenStart

public final int getParenStart(int which)
Returns the start index of a given paren level.
Parameters:
which - Nesting level of subexpression
Returns:
String index

getParenEnd

public final int getParenEnd(int which)
Returns the end index of a given paren level.
Parameters:
which - Nesting level of subexpression
Returns:
String index

getParenLength

public final int getParenLength(int which)
Returns the length of a given paren level.
Parameters:
which - Nesting level of subexpression
Returns:
Number of characters in the parenthesized subexpression

setParenStart

protected final void setParenStart(int which,
                                   int i)
Sets the start of a paren level
Parameters:
which - Which paren level
i - Index in input array

setParenEnd

protected final void setParenEnd(int which,
                                 int i)
Sets the end of a paren level
Parameters:
which - Which paren level
i - Index in input array

internalError

protected void internalError(java.lang.String s)
                      throws java.lang.Error
Throws an Error representing an internal error condition probably resulting from a bug in the regular expression compiler (or possibly data corruption). In practice, this should be very rare.
Parameters:
s - Error description

allocParens

private void allocParens()
Performs lazy allocation of subexpression arrays

matchNodes

protected int matchNodes(int firstNode,
                         int lastNode,
                         int idxStart)
Try to match a string against a subset of nodes in the program
Parameters:
firstNode - Node to start at in program
lastNode - Last valid node (used for matching a subexpression without matching the rest of the program as well).
idxStart - Starting position in character array
Returns:
Final input array index if match succeeded. -1 if not.

matchAt

protected boolean matchAt(int i)
Match the current regular expression program against the current input string, starting at index i of the input string. This method is only meant for internal use.
Parameters:
i - The input string index to start matching at
Returns:
True if the input matched the expression

match

public boolean match(java.lang.String search,
                     int i)
Matches the current regular expression program against a character array, starting at a given index.
Parameters:
search - String to match against
i - Index to start searching at
Returns:
True if string matched

match

public boolean match(CharacterIterator search,
                     int i)
Matches the current regular expression program against a character array, starting at a given index.
Parameters:
search - String to match against
i - Index to start searching at
Returns:
True if string matched

match

public boolean match(java.lang.String search)
Matches the current regular expression program against a String.
Parameters:
search - String to match against
Returns:
True if string matched

split

public java.lang.String[] split(java.lang.String s)
Splits a string into an array of strings on regular expression boundaries. This function works the same way as the Perl function of the same name. Given a regular expression of "[ab]+" and a string to split of "xyzzyababbayyzabbbab123", the result would be the array of Strings "[xyzzy, yyz, 123]".

Please note that the first string in the resulting array may be an empty string. This happens when the very first character of input string is matched by the pattern.

Parameters:
s - String to split on this regular exression
Returns:
Array of strings

subst

public java.lang.String subst(java.lang.String substituteIn,
                              java.lang.String substitution)
Substitutes a string for this regular expression in another string. This method works like the Perl function of the same name. Given a regular expression of "a*b", a String to substituteIn of "aaaabfooaaabgarplyaaabwackyb" and the substitution String "-", the resulting String returned by subst would be "-foo-garply-wacky-".
Parameters:
substituteIn - String to substitute within
substitution - String to substitute for all matches of this regular expression.
Returns:
The string substituteIn with zero or more occurrences of the current regular expression replaced with the substitution String (if this regular expression object doesn't match at any position, the original String is returned unchanged).

subst

public java.lang.String subst(java.lang.String substituteIn,
                              java.lang.String substitution,
                              int flags)
Substitutes a string for this regular expression in another string. This method works like the Perl function of the same name. Given a regular expression of "a*b", a String to substituteIn of "aaaabfooaaabgarplyaaabwackyb" and the substitution String "-", the resulting String returned by subst would be "-foo-garply-wacky-".

It is also possible to reference the contents of a parenthesized expression with $0, $1, ... $9. A regular expression of "http://[\\.\\w\\-\\?/~_@&=%]+", a String to substituteIn of "visit us: http://www.apache.org!" and the substitution String "<a href=\"$0\">$0</a>", the resulting String returned by subst would be "visit us: <a href=\"http://www.apache.org\">http://www.apache.org</a>!".

Note: $0 represents the whole match.

Parameters:
substituteIn - String to substitute within
substitution - String to substitute for matches of this regular expression
flags - One or more bitwise flags from REPLACE_*. If the REPLACE_FIRSTONLY flag bit is set, only the first occurrence of this regular expression is replaced. If the bit is not set (REPLACE_ALL), all occurrences of this pattern will be replaced. If the flag REPLACE_BACKREFERENCES is set, all backreferences will be processed.
Returns:
The string substituteIn with zero or more occurrences of the current regular expression replaced with the substitution String (if this regular expression object doesn't match at any position, the original String is returned unchanged).

grep

public java.lang.String[] grep(java.lang.Object[] search)
Returns an array of Strings, whose toString representation matches a regular expression. This method works like the Perl function of the same name. Given a regular expression of "a*b" and an array of String objects of [foo, aab, zzz, aaaab], the array of Strings returned by grep would be [aab, aaaab].
Parameters:
search - Array of Objects to search
Returns:
Array of Strings whose toString() value matches this regular expression.

isNewline

private boolean isNewline(int i)
Returns:
true if character at i-th position in the search string is a newline

compareChars

private int compareChars(char c1,
                         char c2,
                         boolean caseIndependent)
Compares two characters.
Parameters:
c1 - first character to compare.
c2 - second character to compare.
caseIndependent - whether comparision is case insensitive or not.
Returns:
negative, 0, or positive integer as the first character less than, equal to, or greater then the second.


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/RECompiler.RERange.html100644 0 0 34061 10577337776 22641 0ustar 0 0 Jakarta-Regexp 1.5 API: Class RECompiler.RERange

org.apache.regexp
Class RECompiler.RERange

java.lang.Object
  |
  +--org.apache.regexp.RECompiler.RERange
Enclosing class:
RECompiler

class RECompiler.RERange
extends java.lang.Object

Local, nested class for maintaining character ranges for character classes.


Field Summary
(package private)  int[] maxRange
           
(package private)  int[] minRange
           
(package private)  int num
           
(package private)  int size
           
 
Constructor Summary
(package private) RECompiler.RERange()
           
 
Method Summary
(package private)  void delete(int index)
          Deletes the range at a given index from the range lists
(package private)  void include(char minmax, boolean include)
          Includes a range with the same min and max
(package private)  void include(int min, int max, boolean include)
          Includes (or excludes) the range from min to max, inclusive.
(package private)  void merge(int min, int max)
          Merges a range into the range list, coalescing ranges if possible.
(package private)  void remove(int min, int max)
          Removes a range by deleting or shrinking all other ranges
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

size

int size

minRange

int[] minRange

maxRange

int[] maxRange

num

int num
Constructor Detail

RECompiler.RERange

RECompiler.RERange()
Method Detail

delete

void delete(int index)
Deletes the range at a given index from the range lists
Parameters:
index - Index of range to delete from minRange and maxRange arrays.

merge

void merge(int min,
           int max)
Merges a range into the range list, coalescing ranges if possible.
Parameters:
min - Minimum end of range
max - Maximum end of range

remove

void remove(int min,
            int max)
Removes a range by deleting or shrinking all other ranges
Parameters:
min - Minimum end of range
max - Maximum end of range

include

void include(int min,
             int max,
             boolean include)
Includes (or excludes) the range from min to max, inclusive.
Parameters:
min - Minimum end of range
max - Maximum end of range
include - True if range should be included. False otherwise.

include

void include(char minmax,
             boolean include)
Includes a range with the same min and max
Parameters:
minmax - Minimum and maximum end of range (inclusive)
include - True if range should be included. False otherwise.


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/RECompiler.html100644 0 0 100725 10577337776 21400 0ustar 0 0 Jakarta-Regexp 1.5 API: Class RECompiler

org.apache.regexp
Class RECompiler

java.lang.Object
  |
  +--org.apache.regexp.RECompiler
Direct Known Subclasses:
REDebugCompiler

public class RECompiler
extends java.lang.Object

A regular expression compiler class. This class compiles a pattern string into a regular expression program interpretable by the RE evaluator class. The 'recompile' command line tool uses this compiler to pre-compile regular expressions for use with RE. For a description of the syntax accepted by RECompiler and what you can do with regular expressions, see the documentation for the RE matcher class.

Version:
$Id: RECompiler.java 518156 2007-03-14 14:31:26Z vgritsenko $
Author:
Jonathan Locke, Michael McCallum
See Also:
RE, recompile

Inner Class Summary
(package private)  class RECompiler.RERange
          Local, nested class for maintaining character ranges for character classes.
 
Field Summary
(package private)  int bracketMin
           
(package private)  int bracketOpt
           
(package private) static int bracketUnbounded
           
(package private) static int ESC_BACKREF
           
(package private) static int ESC_CLASS
           
(package private) static int ESC_COMPLEX
           
(package private) static int ESC_MASK
           
(package private) static java.util.Hashtable hashPOSIX
           
(package private)  int idx
           
(package private)  char[] instruction
           
(package private)  int len
           
(package private)  int lenInstruction
           
(package private) static int NODE_NORMAL
           
(package private) static int NODE_NULLABLE
           
(package private) static int NODE_TOPLEVEL
           
(package private)  int parens
           
(package private)  java.lang.String pattern
           
 
Constructor Summary
RECompiler()
          Constructor.
 
Method Summary
(package private) static void ()
           
(package private)  int atom()
          Absorb an atomic character string.
(package private)  void bracket()
          Match bracket {m,n} expression put results in bracket member variables
(package private)  int branch(int[] flags)
          Compile body of one branch of an or operator (implements concatenation)
(package private)  int characterClass()
          Compile a character class
(package private)  int closure(int[] flags)
          Compile a possibly closured terminal
 REProgram compile(java.lang.String pattern)
          Compiles a regular expression pattern into a program runnable by the pattern matcher class 'RE'.
(package private)  void emit(char c)
          Emit a single character into the program stream.
(package private)  void ensure(int n)
          Ensures that n more characters can fit in the program buffer.
(package private)  int escape()
          Match an escape sequence.
(package private)  int expr(int[] flags)
          Compile an expression with possible parens around it.
(package private)  void internalError()
          Throws a new internal error exception
(package private)  int node(char opcode, int opdata)
          Adds a new node
(package private)  void nodeInsert(char opcode, int opdata, int insertAt)
          Inserts a node with a given opcode and opdata at insertAt.
(package private)  void setNextOfEnd(int node, int pointTo)
          Appends a node to the end of a node chain
(package private)  void syntaxError(java.lang.String s)
          Throws a new syntax error exception
(package private)  int terminal(int[] flags)
          Match a terminal node.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

instruction

char[] instruction

lenInstruction

int lenInstruction

pattern

java.lang.String pattern

len

int len

idx

int idx

parens

int parens

NODE_NORMAL

static final int NODE_NORMAL

NODE_NULLABLE

static final int NODE_NULLABLE

NODE_TOPLEVEL

static final int NODE_TOPLEVEL

ESC_MASK

static final int ESC_MASK

ESC_BACKREF

static final int ESC_BACKREF

ESC_COMPLEX

static final int ESC_COMPLEX

ESC_CLASS

static final int ESC_CLASS

bracketUnbounded

static final int bracketUnbounded

bracketMin

int bracketMin

bracketOpt

int bracketOpt

hashPOSIX

static final java.util.Hashtable hashPOSIX
Constructor Detail

RECompiler

public RECompiler()
Constructor. Creates (initially empty) storage for a regular expression program.
Method Detail

static void ()

ensure

void ensure(int n)
Ensures that n more characters can fit in the program buffer. If n more can't fit, then the size is doubled until it can.
Parameters:
n - Number of additional characters to ensure will fit.

emit

void emit(char c)
Emit a single character into the program stream.
Parameters:
c - Character to add

nodeInsert

void nodeInsert(char opcode,
                int opdata,
                int insertAt)
Inserts a node with a given opcode and opdata at insertAt. The node relative next pointer is initialized to 0.
Parameters:
opcode - Opcode for new node
opdata - Opdata for new node (only the low 16 bits are currently used)
insertAt - Index at which to insert the new node in the program

setNextOfEnd

void setNextOfEnd(int node,
                  int pointTo)
Appends a node to the end of a node chain
Parameters:
node - Start of node chain to traverse
pointTo - Node to have the tail of the chain point to

node

int node(char opcode,
         int opdata)
Adds a new node
Parameters:
opcode - Opcode for node
opdata - Opdata for node (only the low 16 bits are currently used)
Returns:
Index of new node in program

internalError

void internalError()
             throws java.lang.Error
Throws a new internal error exception
Throws:
java.lang.Error - Thrown in the event of an internal error.

syntaxError

void syntaxError(java.lang.String s)
           throws RESyntaxException
Throws a new syntax error exception
Throws:
RESyntaxException - Thrown if the regular expression has invalid syntax.

bracket

void bracket()
       throws RESyntaxException
Match bracket {m,n} expression put results in bracket member variables
Throws:
RESyntaxException - Thrown if the regular expression has invalid syntax.

escape

int escape()
     throws RESyntaxException
Match an escape sequence. Handles quoted chars and octal escapes as well as normal escape characters. Always advances the input stream by the right amount. This code "understands" the subtle difference between an octal escape and a backref. You can access the type of ESC_CLASS or ESC_COMPLEX or ESC_BACKREF by looking at pattern[idx - 1].
Returns:
ESC_* code or character if simple escape
Throws:
RESyntaxException - Thrown if the regular expression has invalid syntax.

characterClass

int characterClass()
             throws RESyntaxException
Compile a character class
Returns:
Index of class node
Throws:
RESyntaxException - Thrown if the regular expression has invalid syntax.

atom

int atom()
   throws RESyntaxException
Absorb an atomic character string. This method is a little tricky because it can un-include the last character of string if a closure operator follows. This is correct because *+? have higher precedence than concatentation (thus ABC* means AB(C*) and NOT (ABC)*).
Returns:
Index of new atom node
Throws:
RESyntaxException - Thrown if the regular expression has invalid syntax.

terminal

int terminal(int[] flags)
       throws RESyntaxException
Match a terminal node.
Parameters:
flags - Flags
Returns:
Index of terminal node (closeable)
Throws:
RESyntaxException - Thrown if the regular expression has invalid syntax.

closure

int closure(int[] flags)
      throws RESyntaxException
Compile a possibly closured terminal
Parameters:
flags - Flags passed by reference
Returns:
Index of closured node
Throws:
RESyntaxException - Thrown if the regular expression has invalid syntax.

branch

int branch(int[] flags)
     throws RESyntaxException
Compile body of one branch of an or operator (implements concatenation)
Parameters:
flags - Flags passed by reference
Returns:
Pointer to first node in the branch
Throws:
RESyntaxException - Thrown if the regular expression has invalid syntax.

expr

int expr(int[] flags)
   throws RESyntaxException
Compile an expression with possible parens around it. Paren matching is done at this level so we can tie the branch tails together.
Parameters:
flags - Flag value passed by reference
Returns:
Node index of expression in instruction array
Throws:
RESyntaxException - Thrown if the regular expression has invalid syntax.

compile

public REProgram compile(java.lang.String pattern)
                  throws RESyntaxException
Compiles a regular expression pattern into a program runnable by the pattern matcher class 'RE'.
Parameters:
pattern - Regular expression pattern to compile (see RECompiler class for details).
Returns:
A compiled regular expression program.
Throws:
RESyntaxException - Thrown if the regular expression has invalid syntax.
See Also:
RECompiler, RE


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/REDebugCompiler.html100644 0 0 42241 10577337776 22325 0ustar 0 0 Jakarta-Regexp 1.5 API: Class REDebugCompiler

org.apache.regexp
Class REDebugCompiler

java.lang.Object
  |
  +--org.apache.regexp.RECompiler
        |
        +--org.apache.regexp.REDebugCompiler

public class REDebugCompiler
extends RECompiler

A subclass of RECompiler which can dump a regular expression program for debugging purposes.

Version:
$Id: REDebugCompiler.java 518169 2007-03-14 15:03:35Z vgritsenko $
Author:
Jonathan Locke

Inner classes inherited from class org.apache.regexp.RECompiler
RECompiler.RERange
 
Field Summary
(package private) static java.util.Hashtable hashOpcode
          Mapping from opcodes to descriptive strings
 
Fields inherited from class org.apache.regexp.RECompiler
bracketMin, bracketOpt, bracketUnbounded, ESC_BACKREF, ESC_CLASS, ESC_COMPLEX, ESC_MASK, hashPOSIX, idx, instruction, len, lenInstruction, NODE_NORMAL, NODE_NULLABLE, NODE_TOPLEVEL, parens, pattern
 
Constructor Summary
REDebugCompiler()
           
 
Method Summary
(package private) static void ()
           
(package private)  java.lang.String charToString(char c)
          Return a string describing a (possibly unprintable) character.
 void dumpProgram()
          Dumps the current program to a System.out.
 void dumpProgram(java.io.PrintWriter p)
          Dumps the current program to a PrintWriter.
(package private)  java.lang.String nodeToString(int node)
          Returns a descriptive string for a node in a regular expression program.
(package private)  java.lang.String opcodeToString(char opcode)
          Returns a descriptive string for an opcode.
 
Methods inherited from class org.apache.regexp.RECompiler
atom, bracket, branch, characterClass, closure, compile, emit, ensure, escape, expr, internalError, node, nodeInsert, setNextOfEnd, syntaxError, terminal
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

hashOpcode

static java.util.Hashtable hashOpcode
Mapping from opcodes to descriptive strings
Constructor Detail

REDebugCompiler

public REDebugCompiler()
Method Detail

static void ()

opcodeToString

java.lang.String opcodeToString(char opcode)
Returns a descriptive string for an opcode.
Parameters:
opcode - Opcode to convert to a string
Returns:
Description of opcode

charToString

java.lang.String charToString(char c)
Return a string describing a (possibly unprintable) character.
Parameters:
c - Character to convert to a printable representation
Returns:
String representation of character

nodeToString

java.lang.String nodeToString(int node)
Returns a descriptive string for a node in a regular expression program.
Parameters:
node - Node to describe
Returns:
Description of node

dumpProgram

public void dumpProgram(java.io.PrintWriter p)
Dumps the current program to a PrintWriter.
Parameters:
p - PrintWriter for program dump output

dumpProgram

public void dumpProgram()
Dumps the current program to a System.out.


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/REDemo.html100644 0 0 65426 10577337776 20502 0ustar 0 0 Jakarta-Regexp 1.5 API: Class REDemo

org.apache.regexp
Class REDemo

java.lang.Object
  |
  +--java.awt.Component
        |
        +--java.awt.Container
              |
              +--java.awt.Panel
                    |
                    +--java.applet.Applet
                          |
                          +--org.apache.regexp.REDemo
All Implemented Interfaces:
javax.accessibility.Accessible, java.util.EventListener, java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, java.awt.event.TextListener

public class REDemo
extends java.applet.Applet
implements java.awt.event.TextListener

Interactive demonstration and testing harness for regular expressions classes.

Version:
$Id: REDemo.java 518156 2007-03-14 14:31:26Z vgritsenko $
Author:
Jonathan Locke
See Also:
Serialized Form

Inner classes inherited from class java.applet.Applet
java.applet.Applet.AccessibleApplet
 
Inner classes inherited from class java.awt.Panel
java.awt.Panel.AccessibleAWTPanel
 
Inner classes inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Inner classes inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.AWTTreeLock
 
Field Summary
(package private)  REDebugCompiler compiler
           
(package private)  java.awt.TextField fieldMatch
           
(package private)  java.awt.TextField fieldRE
          Components
(package private)  java.awt.TextArea outMatch
           
(package private)  java.awt.TextArea outRE
           
(package private)  RE r
          Matcher and compiler objects
 
Fields inherited from class java.applet.Applet
accessibleContext, serialVersionUID, stub
 
Fields inherited from class java.awt.Panel
base, nameCounter
 
Fields inherited from class java.awt.Container
component, containerListener, containerSerializedDataVersion, dbg, dispatcher, layoutMgr, listeningBoundsChildren, listeningChildren, maxSize, ncomponents, printing, printingThreads
 
Fields inherited from class java.awt.Component
actionListenerK, adjustmentListenerK, appContext, background, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, changeSupport, componentListener, componentListenerK, componentOrientation, componentSerializedDataVersion, containerListenerK, cursor, dropTarget, enabled, eventMask, focusListener, focusListenerK, font, foreground, graphicsConfig, hasFocus, height, hierarchyBoundsListener, hierarchyBoundsListenerK, hierarchyListener, hierarchyListenerK, incRate, inputMethodListener, inputMethodListenerK, isInc, isPacked, itemListenerK, keyListener, keyListenerK, LEFT_ALIGNMENT, locale, LOCK, metrics, minSize, mouseListener, mouseListenerK, mouseMotionListener, mouseMotionListenerK, name, nameExplicitlySet, newEventsOnly, ownedWindowK, parent, peer, peerFont, popups, prefSize, privateKey, RIGHT_ALIGNMENT, textListenerK, TOP_ALIGNMENT, valid, visible, width, windowClosingException, windowListenerK, x, y
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
REDemo()
           
 
Method Summary
 void init()
          Add controls and init applet
static void main(java.lang.String[] arg)
          Main application entrypoint.
(package private)  void sayMatch(java.lang.String s)
          Say something into match text area
(package private)  void sayRE(java.lang.String s)
          Say something into RE text area
 void textValueChanged(java.awt.event.TextEvent e)
          Called when text values change
(package private)  java.lang.String throwableToString(java.lang.Throwable t)
          Convert throwable to string
(package private)  void updateMatch(java.lang.String match)
          Update matching info by matching the string against the current compiled regular expression.
(package private)  void updateRE(java.lang.String expr)
          Change regular expression
 
Methods inherited from class java.applet.Applet
destroy, getAccessibleContext, getAppletContext, getAppletInfo, getAudioClip, getAudioClip, getCodeBase, getDocumentBase, getImage, getImage, getLocale, getParameter, getParameterInfo, isActive, newAudioClip, play, play, resize, resize, setStub, showStatus, start, stop
 
Methods inherited from class java.awt.Panel
, addNotify, constructComponentName
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, adjustListeningChildren, applyOrientation, checkGD, countComponents, createChildHierarchyEvents, createHierarchyEvents, deliverEvent, dispatchEventImpl, dispatchEventToSelf, doLayout, eventEnabled, findComponentAt, findComponentAt, findComponentAt, getAccessibleAt, getAccessibleChild, getAccessibleChildrenCount, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents_NoClientCode, getComponents, getInsets, getLayout, getListeners, getMaximumSize, getMinimumSize, getMouseEventTarget, getPreferredSize, getWindow, initIDs, insets, invalidate, invalidateTree, isAncestorOf, layout, lightweightPaint, lightweightPrint, list, list, locate, minimumSize, nextFocus, numListening, paint, paintComponents, paintHeavyweightComponents, paramString, postProcessKeyEvent, postsOldMouseEvents, preferredSize, preProcessKeyEvent, print, printComponents, printHeavyweightComponents, processContainerEvent, processEvent, proxyEnableEvents, proxyRequestFocus, readObject, remove, remove, removeAll, removeContainerListener, removeNotify, setFocusOwner, setFont, setLayout, transferFocus, update, validate, validateTree, writeObject
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addPropertyChangeListener, addPropertyChangeListener, areInputMethodsEnabled, bounds, checkImage, checkImage, checkWindowClosingException, coalesceEvents, contains, contains, createImage, createImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, getAccessibleIndexInParent, getAccessibleStateSet, getBackground, getBounds, getBounds, getColorModel, getComponentOrientation, getCursor, getDropTarget, getFont_NoClientCode, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getInputContext, getInputMethodRequests, getLocation, getLocation, getLocationOnScreen_NoTreeLock, getLocationOnScreen, getName, getNativeContainer, getParent_NoClientCode, getParent, getPeer, getSize, getSize, getToolkit, getToolkitImpl, getTreeLock, getWidth, getWindowForObject, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isDisplayable, isDoubleBuffered, isEnabled, isEnabledImpl, isFocusTraversable, isLightweight, isOpaque, isRecursivelyVisible, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, resetGC, reshape, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setForeground, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, show, show, size, toString, transferFocus
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, wait, wait, wait
 

Field Detail

r

RE r
Matcher and compiler objects

compiler

REDebugCompiler compiler

fieldRE

java.awt.TextField fieldRE
Components

fieldMatch

java.awt.TextField fieldMatch

outRE

java.awt.TextArea outRE

outMatch

java.awt.TextArea outMatch
Constructor Detail

REDemo

public REDemo()
Method Detail

init

public void init()
Add controls and init applet
Overrides:
init in class java.applet.Applet

sayRE

void sayRE(java.lang.String s)
Say something into RE text area
Parameters:
s - What to say

sayMatch

void sayMatch(java.lang.String s)
Say something into match text area
Parameters:
s - What to say

throwableToString

java.lang.String throwableToString(java.lang.Throwable t)
Convert throwable to string
Parameters:
t - Throwable to convert to string

updateRE

void updateRE(java.lang.String expr)
Change regular expression
Parameters:
expr - Expression to compile

updateMatch

void updateMatch(java.lang.String match)
Update matching info by matching the string against the current compiled regular expression.
Parameters:
match - String to match against

textValueChanged

public void textValueChanged(java.awt.event.TextEvent e)
Called when text values change
Specified by:
textValueChanged in interface java.awt.event.TextListener
Parameters:
e - TextEvent

main

public static void main(java.lang.String[] arg)
Main application entrypoint.
Parameters:
arg - Command line arguments


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/REProgram.html100644 0 0 40766 10577337776 21225 0ustar 0 0 Jakarta-Regexp 1.5 API: Class REProgram

org.apache.regexp
Class REProgram

java.lang.Object
  |
  +--org.apache.regexp.REProgram
All Implemented Interfaces:
java.io.Serializable

public class REProgram
extends java.lang.Object
implements java.io.Serializable

A class that holds compiled regular expressions. This is exposed mainly for use by the recompile utility (which helps you produce precompiled REProgram objects). You should not otherwise need to work directly with this class.

Version:
$Id: REProgram.java 518156 2007-03-14 14:31:26Z vgritsenko $
Author:
Jonathan Locke
See Also:
RE, RECompiler, Serialized Form

Field Summary
(package private)  int flags
           
(package private)  char[] instruction
           
(package private)  int lenInstruction
           
(package private)  int maxParens
           
(package private) static int OPT_HASBACKREFS
           
(package private) static int OPT_HASBOL
           
(package private)  char[] prefix
           
 
Constructor Summary
REProgram(char[] instruction)
          Constructs a program object from a character array
REProgram(char[] instruction, int lenInstruction)
          Constructs a program object from a character array
REProgram(int parens, char[] instruction)
          Constructs a program object from a character array
 
Method Summary
 char[] getInstructions()
          Returns a copy of the current regular expression program in a character array that is exactly the right length to hold the program.
 char[] getPrefix()
          Returns a copy of the prefix of current regular expression program in a character array.
 void setInstructions(char[] instruction, int lenInstruction)
          Sets a new regular expression program to run.
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

OPT_HASBACKREFS

static final int OPT_HASBACKREFS

OPT_HASBOL

static final int OPT_HASBOL

instruction

char[] instruction

lenInstruction

int lenInstruction

prefix

char[] prefix

flags

int flags

maxParens

int maxParens
Constructor Detail

REProgram

public REProgram(char[] instruction)
Constructs a program object from a character array
Parameters:
instruction - Character array with RE opcode instructions in it

REProgram

public REProgram(int parens,
                 char[] instruction)
Constructs a program object from a character array
Parameters:
parens - Count of parens in the program
instruction - Character array with RE opcode instructions in it

REProgram

public REProgram(char[] instruction,
                 int lenInstruction)
Constructs a program object from a character array
Parameters:
instruction - Character array with RE opcode instructions in it
lenInstruction - Amount of instruction array in use
Method Detail

getInstructions

public char[] getInstructions()
Returns a copy of the current regular expression program in a character array that is exactly the right length to hold the program. If there is no program compiled yet, getInstructions() will return null.
Returns:
A copy of the current compiled RE program

setInstructions

public void setInstructions(char[] instruction,
                            int lenInstruction)
Sets a new regular expression program to run. It is this method which performs any special compile-time search optimizations. Currently only two optimizations are in place - one which checks for backreferences (so that they can be lazily allocated) and another which attempts to find an prefix anchor string so that substantial amounts of input can potentially be skipped without running the actual program.
Parameters:
instruction - Program instruction buffer
lenInstruction - Length of instruction buffer in use

getPrefix

public char[] getPrefix()
Returns a copy of the prefix of current regular expression program in a character array. If there is no prefix, or there is no program compiled yet, getPrefix will return null.
Returns:
A copy of the prefix of current compiled RE program


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/RESyntaxException.html100644 0 0 21542 10577337776 22752 0ustar 0 0 Jakarta-Regexp 1.5 API: Class RESyntaxException

org.apache.regexp
Class RESyntaxException

java.lang.Object
  |
  +--java.lang.Throwable
        |
        +--java.lang.Exception
              |
              +--java.lang.RuntimeException
                    |
                    +--org.apache.regexp.RESyntaxException
All Implemented Interfaces:
java.io.Serializable

public class RESyntaxException
extends java.lang.RuntimeException

Exception thrown to indicate a syntax error in a regular expression. This is a non-checked exception because you should only have problems compiling a regular expression during development. If you are making regular expresion programs dynamically then you can catch it if you wish. But should not be forced to.

Version:
$Id: RESyntaxException.java 518156 2007-03-14 14:31:26Z vgritsenko $
Author:
Jonathan Locke, Serialized Form

Fields inherited from class java.lang.Throwable
backtrace, detailMessage, serialVersionUID
 
Constructor Summary
RESyntaxException(java.lang.String s)
          Constructor.
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getLocalizedMessage, getMessage, printStackTrace, printStackTrace, printStackTrace, printStackTrace0, toString
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, wait, wait, wait
 

Constructor Detail

RESyntaxException

public RESyntaxException(java.lang.String s)
Constructor.
Parameters:
s - Further description of the syntax error


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/RETest.html100644 0 0 57455 10577337776 20540 0ustar 0 0 Jakarta-Regexp 1.5 API: Class RETest

org.apache.regexp
Class RETest

java.lang.Object
  |
  +--org.apache.regexp.RETest

public class RETest
extends java.lang.Object

Data driven (and optionally interactive) testing harness to exercise regular expression compiler and matching engine.

Version:
$Id: RETest.java 518156 2007-03-14 14:31:26Z vgritsenko $
Author:
Jonathan Locke, Jon S. Stevens, Michael McCallum

Field Summary
(package private)  REDebugCompiler compiler
           
(package private)  int failures
           
(package private) static java.lang.String NEW_LINE
           
(package private) static boolean showSuccesses
           
(package private)  int testCount
           
 
Constructor Summary
RETest()
          Constructor
 
Method Summary
 void assertEquals(java.lang.String message, int expected, int actual)
           
 void assertEquals(java.lang.String message, java.lang.String expected, java.lang.String actual)
           
(package private)  void die(java.lang.String s)
          Exit with a fatal error.
(package private)  void fail(java.lang.String s)
          Fail with an error.
(package private)  void fail(java.lang.StringBuffer log, java.lang.String s)
          Fail with an error.
private  java.lang.String findNextTest(java.io.BufferedReader br)
          Finds next test description in a given script.
private  boolean getExpectedResult(java.lang.String yesno)
          Converts yesno string to boolean.
private  RETestCase getNextTestCase(java.io.BufferedReader br)
          Creates testcase for the next test description in the script file.
static void main(java.lang.String[] args)
          Main program entrypoint.
(package private)  void runAutomatedTests(java.lang.String testDocument)
          Run automated tests in RETest.txt file (from Perl 4.0 test battery)
(package private)  void runInteractiveTests(java.lang.String expr)
          Compile and test matching against a single expression
(package private)  void say(java.lang.String s)
          Say something to standard out
(package private)  void showParens(RE r)
          Dump parenthesized subexpressions found by a regular expression matcher object
static boolean test(java.lang.String[] args)
          Testing entrypoint.
(package private)  void testOther()
          Run automated unit test
private  void testPrecompiledRE()
           
private  void testSplitAndGrep()
           
private  void testSubst()
           
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

showSuccesses

static final boolean showSuccesses

NEW_LINE

static final java.lang.String NEW_LINE

compiler

final REDebugCompiler compiler

testCount

int testCount

failures

int failures
Constructor Detail

RETest

public RETest()
Constructor
Method Detail

main

public static void main(java.lang.String[] args)
Main program entrypoint. If an argument is given, it will be compiled and interactive matching will ensue. If no argument is given, the file RETest.txt will be used as automated testing input.
Parameters:
args - Command line arguments (optional regular expression)

test

public static boolean test(java.lang.String[] args)
                    throws java.lang.Exception
Testing entrypoint.
Parameters:
args - Command line arguments
Throws:
java.lang.Exception - thrown in case of error

runInteractiveTests

void runInteractiveTests(java.lang.String expr)
Compile and test matching against a single expression
Parameters:
expr - Expression to compile and test

die

void die(java.lang.String s)
Exit with a fatal error.
Parameters:
s - Last famous words before exiting

fail

void fail(java.lang.StringBuffer log,
          java.lang.String s)
Fail with an error. Will print a big failure message to System.out.
Parameters:
log - Output before failure
s - Failure description

fail

void fail(java.lang.String s)
Fail with an error. Will print a big failure message to System.out.
Parameters:
s - Failure description

say

void say(java.lang.String s)
Say something to standard out
Parameters:
s - What to say

showParens

void showParens(RE r)
Dump parenthesized subexpressions found by a regular expression matcher object
Parameters:
r - Matcher object with results to show

runAutomatedTests

void runAutomatedTests(java.lang.String testDocument)
                 throws java.lang.Exception
Run automated tests in RETest.txt file (from Perl 4.0 test battery)
Throws:
java.lang.Exception - thrown in case of error

testOther

void testOther()
         throws java.lang.Exception
Run automated unit test
Throws:
java.lang.Exception - thrown in case of error

testPrecompiledRE

private void testPrecompiledRE()

testSplitAndGrep

private void testSplitAndGrep()

testSubst

private void testSubst()

assertEquals

public void assertEquals(java.lang.String message,
                         java.lang.String expected,
                         java.lang.String actual)

assertEquals

public void assertEquals(java.lang.String message,
                         int expected,
                         int actual)

getExpectedResult

private boolean getExpectedResult(java.lang.String yesno)
Converts yesno string to boolean.
Parameters:
yesno - string representation of expected result
Returns:
true if yesno is "YES", false if yesno is "NO" stops program otherwise.

findNextTest

private java.lang.String findNextTest(java.io.BufferedReader br)
                               throws java.io.IOException
Finds next test description in a given script.
Parameters:
br - BufferedReader for a script file
Returns:
strign tag for next test description
Throws:
java.io.IOException - if some io problems occured

getNextTestCase

private RETestCase getNextTestCase(java.io.BufferedReader br)
                            throws java.io.IOException
Creates testcase for the next test description in the script file.
Parameters:
br - BufferedReader for script file.
Returns:
a new tescase or null.
Throws:
java.io.IOException - if some io problems occured


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/RETestCase.html100644 0 0 45472 10577337776 21330 0ustar 0 0 Jakarta-Regexp 1.5 API: Class RETestCase

org.apache.regexp
Class RETestCase

java.lang.Object
  |
  +--org.apache.regexp.RETestCase

final class RETestCase
extends java.lang.Object


Field Summary
private  boolean badPattern
           
private  java.lang.StringBuffer log
           
private  int number
           
private  java.lang.String[] parens
           
private  java.lang.String pattern
           
private  RE regexp
           
private  boolean shouldMatch
           
private  java.lang.String tag
           
private  RETest test
           
private  java.lang.String toMatch
           
 
Constructor Summary
RETestCase(RETest test, java.lang.String tag, java.lang.String pattern, java.lang.String toMatch, boolean badPattern, boolean shouldMatch, java.lang.String[] parens)
           
 
Method Summary
 boolean assertEquals(java.lang.StringBuffer log, java.lang.String message, int expected, int actual)
           
 boolean assertEquals(java.lang.StringBuffer log, java.lang.String message, java.lang.String expected, java.lang.String actual)
           
private  boolean checkParens()
           
private  boolean checkResult(boolean result)
           
 void runTest()
           
(package private)  void success(java.lang.String s)
          Show a success
(package private)  boolean testCreation()
           
private  void testMatch()
           
(package private)  boolean tryMatchUsingCI(CharacterIterator matchAgainst)
           
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

log

private final java.lang.StringBuffer log

number

private final int number

tag

private final java.lang.String tag

pattern

private final java.lang.String pattern

toMatch

private final java.lang.String toMatch

badPattern

private final boolean badPattern

shouldMatch

private final boolean shouldMatch

parens

private final java.lang.String[] parens

test

private final RETest test

regexp

private RE regexp
Constructor Detail

RETestCase

public RETestCase(RETest test,
                  java.lang.String tag,
                  java.lang.String pattern,
                  java.lang.String toMatch,
                  boolean badPattern,
                  boolean shouldMatch,
                  java.lang.String[] parens)
Method Detail

runTest

public void runTest()

testCreation

boolean testCreation()

testMatch

private void testMatch()

checkResult

private boolean checkResult(boolean result)

checkParens

private boolean checkParens()

tryMatchUsingCI

boolean tryMatchUsingCI(CharacterIterator matchAgainst)

assertEquals

public boolean assertEquals(java.lang.StringBuffer log,
                            java.lang.String message,
                            java.lang.String expected,
                            java.lang.String actual)

assertEquals

public boolean assertEquals(java.lang.StringBuffer log,
                            java.lang.String message,
                            int expected,
                            int actual)

success

void success(java.lang.String s)
Show a success
Parameters:
s - Success story


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/REUtil.html100644 0 0 26276 10577337776 20533 0ustar 0 0 Jakarta-Regexp 1.5 API: Class REUtil

org.apache.regexp
Class REUtil

java.lang.Object
  |
  +--org.apache.regexp.REUtil

public class REUtil
extends java.lang.Object

This is a class that contains utility helper methods for this package.

Version:
$Id: REUtil.java 518156 2007-03-14 14:31:26Z vgritsenko $
Author:
Jonathan Locke

Field Summary
private static java.lang.String complexPrefix
          complex:
 
Constructor Summary
REUtil()
           
 
Method Summary
static RE createRE(java.lang.String expression)
          Creates a regular expression, permitting simple or complex syntax
static RE createRE(java.lang.String expression, int matchFlags)
          Creates a regular expression, permitting simple or complex syntax
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

complexPrefix

private static final java.lang.String complexPrefix
complex:
Constructor Detail

REUtil

public REUtil()
Method Detail

createRE

public static RE createRE(java.lang.String expression,
                          int matchFlags)
                   throws RESyntaxException
Creates a regular expression, permitting simple or complex syntax
Parameters:
expression - The expression, beginning with a prefix if it's complex or having no prefix if it's simple
matchFlags - Matching style flags
Returns:
The regular expression object
Throws:
RESyntaxException - thrown in case of error

createRE

public static RE createRE(java.lang.String expression)
                   throws RESyntaxException
Creates a regular expression, permitting simple or complex syntax
Parameters:
expression - The expression, beginning with a prefix if it's complex or having no prefix if it's simple
Returns:
The regular expression object
Throws:
RESyntaxException - thrown in case of error


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/ReaderCharacterIterator.html100644 0 0 36427 10577337776 24117 0ustar 0 0 Jakarta-Regexp 1.5 API: Class ReaderCharacterIterator

org.apache.regexp
Class ReaderCharacterIterator

java.lang.Object
  |
  +--org.apache.regexp.ReaderCharacterIterator
All Implemented Interfaces:
CharacterIterator

public final class ReaderCharacterIterator
extends java.lang.Object
implements CharacterIterator

Encapsulates java.io.Reader as CharacterIterator

Version:
CVS $Id: ReaderCharacterIterator.java 518156 2007-03-14 14:31:26Z vgritsenko $
Author:
Ales Novak

Field Summary
private  java.lang.StringBuffer buff
          Buffer of read chars
private  boolean closed
          read end?
private  java.io.Reader reader
          Underlying reader
 
Constructor Summary
ReaderCharacterIterator(java.io.Reader reader)
           
 
Method Summary
 char charAt(int pos)
           
private  void ensure(int idx)
          Reads chars up to the idx
 boolean isEnd(int pos)
           
private  int read(int n)
          Reads n characters from the stream and appends them to the buffer
private  void readAll()
          Reads rest of the stream.
 java.lang.String substring(int beginIndex)
           
 java.lang.String substring(int beginIndex, int endIndex)
           
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

reader

private final java.io.Reader reader
Underlying reader

buff

private final java.lang.StringBuffer buff
Buffer of read chars

closed

private boolean closed
read end?
Constructor Detail

ReaderCharacterIterator

public ReaderCharacterIterator(java.io.Reader reader)
Parameters:
reader - a Reader, which is parsed
Method Detail

substring

public java.lang.String substring(int beginIndex,
                                  int endIndex)
Specified by:
substring in interface CharacterIterator
Returns:
a substring

substring

public java.lang.String substring(int beginIndex)
Specified by:
substring in interface CharacterIterator
Returns:
a substring

charAt

public char charAt(int pos)
Specified by:
charAt in interface CharacterIterator
Returns:
a character at the specified position.

isEnd

public boolean isEnd(int pos)
Specified by:
isEnd in interface CharacterIterator
Returns:
true iff if the specified index is after the end of the character stream

read

private int read(int n)
          throws java.io.IOException
Reads n characters from the stream and appends them to the buffer

readAll

private void readAll()
              throws java.io.IOException
Reads rest of the stream.

ensure

private void ensure(int idx)
             throws java.io.IOException
Reads chars up to the idx


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/StreamCharacterIterator.html100644 0 0 36475 10577337776 24153 0ustar 0 0 Jakarta-Regexp 1.5 API: Class StreamCharacterIterator

org.apache.regexp
Class StreamCharacterIterator

java.lang.Object
  |
  +--org.apache.regexp.StreamCharacterIterator
All Implemented Interfaces:
CharacterIterator

public final class StreamCharacterIterator
extends java.lang.Object
implements CharacterIterator

Encapsulates java.io.InputStream as CharacterIterator.

Version:
CVS $Id: StreamCharacterIterator.java 518156 2007-03-14 14:31:26Z vgritsenko $
Author:
Ales Novak

Field Summary
private  java.lang.StringBuffer buff
          Buffer of read chars
private  boolean closed
          read end?
private  java.io.InputStream is
          Underlying is
 
Constructor Summary
StreamCharacterIterator(java.io.InputStream is)
           
 
Method Summary
 char charAt(int pos)
           
private  void ensure(int idx)
          Reads chars up to the idx
 boolean isEnd(int pos)
           
private  int read(int n)
          Reads n characters from the stream and appends them to the buffer
private  void readAll()
          Reads rest of the stream.
 java.lang.String substring(int beginIndex)
           
 java.lang.String substring(int beginIndex, int endIndex)
           
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

is

private final java.io.InputStream is
Underlying is

buff

private final java.lang.StringBuffer buff
Buffer of read chars

closed

private boolean closed
read end?
Constructor Detail

StreamCharacterIterator

public StreamCharacterIterator(java.io.InputStream is)
Parameters:
is - an InputStream, which is parsed
Method Detail

substring

public java.lang.String substring(int beginIndex,
                                  int endIndex)
Specified by:
substring in interface CharacterIterator
Returns:
a substring

substring

public java.lang.String substring(int beginIndex)
Specified by:
substring in interface CharacterIterator
Returns:
a substring

charAt

public char charAt(int pos)
Specified by:
charAt in interface CharacterIterator
Returns:
a character at the specified position.

isEnd

public boolean isEnd(int pos)
Specified by:
isEnd in interface CharacterIterator
Returns:
true iff if the specified index is after the end of the character stream

read

private int read(int n)
          throws java.io.IOException
Reads n characters from the stream and appends them to the buffer

readAll

private void readAll()
              throws java.io.IOException
Reads rest of the stream.

ensure

private void ensure(int idx)
             throws java.io.IOException
Reads chars up to the idx


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/StringCharacterIterator.html100644 0 0 30720 10577337776 24151 0ustar 0 0 Jakarta-Regexp 1.5 API: Class StringCharacterIterator

org.apache.regexp
Class StringCharacterIterator

java.lang.Object
  |
  +--org.apache.regexp.StringCharacterIterator
All Implemented Interfaces:
CharacterIterator

public final class StringCharacterIterator
extends java.lang.Object
implements CharacterIterator

Encapsulates String as CharacterIterator.

Version:
CVS $Id: StringCharacterIterator.java 518156 2007-03-14 14:31:26Z vgritsenko $
Author:
Ales Novak

Field Summary
private  java.lang.String src
          encapsulated
 
Constructor Summary
StringCharacterIterator(java.lang.String src)
           
 
Method Summary
 char charAt(int pos)
           
 boolean isEnd(int pos)
           
 java.lang.String substring(int beginIndex)
           
 java.lang.String substring(int beginIndex, int endIndex)
           
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

src

private final java.lang.String src
encapsulated
Constructor Detail

StringCharacterIterator

public StringCharacterIterator(java.lang.String src)
Parameters:
src - - encapsulated String
Method Detail

substring

public java.lang.String substring(int beginIndex,
                                  int endIndex)
Specified by:
substring in interface CharacterIterator
Returns:
a substring

substring

public java.lang.String substring(int beginIndex)
Specified by:
substring in interface CharacterIterator
Returns:
a substring

charAt

public char charAt(int pos)
Specified by:
charAt in interface CharacterIterator
Returns:
a character at the specified position.

isEnd

public boolean isEnd(int pos)
Specified by:
isEnd in interface CharacterIterator
Returns:
true iff if the specified index is after the end of the character stream


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/class-use/CharacterArrayCharacterIterator.html100644 0 0 10455 10577337776 27500 0ustar 0 0 Jakarta-Regexp 1.5 API: Uses of Class org.apache.regexp.CharacterArrayCharacterIterator

Uses of Class
org.apache.regexp.CharacterArrayCharacterIterator

No usage of org.apache.regexp.CharacterArrayCharacterIterator



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/class-use/CharacterIterator.html100644 0 0 21160 10577337776 24657 0ustar 0 0 Jakarta-Regexp 1.5 API: Uses of Interface org.apache.regexp.CharacterIterator

Uses of Interface
org.apache.regexp.CharacterIterator

Uses of CharacterIterator in org.apache.regexp
 

Classes in org.apache.regexp that implement CharacterIterator
 class CharacterArrayCharacterIterator
          Encapsulates char[] as CharacterIterator
 class ReaderCharacterIterator
          Encapsulates java.io.Reader as CharacterIterator
 class StreamCharacterIterator
          Encapsulates java.io.InputStream as CharacterIterator.
 class StringCharacterIterator
          Encapsulates String as CharacterIterator.
 

Fields in org.apache.regexp declared as CharacterIterator
(package private)  CharacterIterator RE.search
           
 

Methods in org.apache.regexp with parameters of type CharacterIterator
 boolean RE.match(CharacterIterator search, int i)
          Matches the current regular expression program against a character array, starting at a given index.
(package private)  boolean RETestCase.tryMatchUsingCI(CharacterIterator matchAgainst)
           
 



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/class-use/RE.html100644 0 0 17316 10577337776 21567 0ustar 0 0 Jakarta-Regexp 1.5 API: Uses of Class org.apache.regexp.RE

Uses of Class
org.apache.regexp.RE

Uses of RE in org.apache.regexp
 

Fields in org.apache.regexp declared as RE
private  RE RETestCase.regexp
           
(package private)  RE REDemo.r
          Matcher and compiler objects
 

Methods in org.apache.regexp that return RE
static RE REUtil.createRE(java.lang.String expression, int matchFlags)
          Creates a regular expression, permitting simple or complex syntax
static RE REUtil.createRE(java.lang.String expression)
          Creates a regular expression, permitting simple or complex syntax
 

Methods in org.apache.regexp with parameters of type RE
(package private)  void RETest.showParens(RE r)
          Dump parenthesized subexpressions found by a regular expression matcher object
 



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/class-use/RECompiler.RERange.html100644 0 0 10322 10577337776 24532 0ustar 0 0 Jakarta-Regexp 1.5 API: Uses of Class org.apache.regexp.RECompiler.RERange

Uses of Class
org.apache.regexp.RECompiler.RERange

No usage of org.apache.regexp.RECompiler.RERange



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/class-use/RECompiler.html100644 0 0 13560 10577337776 23257 0ustar 0 0 Jakarta-Regexp 1.5 API: Uses of Class org.apache.regexp.RECompiler

Uses of Class
org.apache.regexp.RECompiler

Uses of RECompiler in org.apache.regexp
 

Subclasses of RECompiler in org.apache.regexp
 class REDebugCompiler
          A subclass of RECompiler which can dump a regular expression program for debugging purposes.
 

Constructors in org.apache.regexp with parameters of type RECompiler
RECompiler.RERange()
           
 



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/class-use/REDebugCompiler.html100644 0 0 13324 10577337776 24224 0ustar 0 0 Jakarta-Regexp 1.5 API: Uses of Class org.apache.regexp.REDebugCompiler

Uses of Class
org.apache.regexp.REDebugCompiler

Uses of REDebugCompiler in org.apache.regexp
 

Fields in org.apache.regexp declared as REDebugCompiler
(package private)  REDebugCompiler RETest.compiler
           
(package private)  REDebugCompiler REDemo.compiler
           
 



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/class-use/REDemo.html100644 0 0 10176 10577337776 22371 0ustar 0 0 Jakarta-Regexp 1.5 API: Uses of Class org.apache.regexp.REDemo

Uses of Class
org.apache.regexp.REDemo

No usage of org.apache.regexp.REDemo



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/class-use/REProgram.html100644 0 0 21057 10577337776 23114 0ustar 0 0 Jakarta-Regexp 1.5 API: Uses of Class org.apache.regexp.REProgram

Uses of Class
org.apache.regexp.REProgram

Uses of REProgram in org.apache.regexp
 

Fields in org.apache.regexp declared as REProgram
(package private)  REProgram RE.program
           
 

Methods in org.apache.regexp that return REProgram
 REProgram RE.getProgram()
          Returns the current regular expression program in use by this matcher object.
 REProgram RECompiler.compile(java.lang.String pattern)
          Compiles a regular expression pattern into a program runnable by the pattern matcher class 'RE'.
 

Methods in org.apache.regexp with parameters of type REProgram
 void RE.setProgram(REProgram program)
          Sets the current regular expression program used by this matcher object.
 

Constructors in org.apache.regexp with parameters of type REProgram
RE(REProgram program, int matchFlags)
          Construct a matcher for a pre-compiled regular expression from program (bytecode) data.
RE(REProgram program)
          Construct a matcher for a pre-compiled regular expression from program (bytecode) data.
 



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/class-use/RESyntaxException.html100644 0 0 26205 10577337776 24652 0ustar 0 0 Jakarta-Regexp 1.5 API: Uses of Class org.apache.regexp.RESyntaxException

Uses of Class
org.apache.regexp.RESyntaxException

Uses of RESyntaxException in org.apache.regexp
 

Methods in org.apache.regexp that throw RESyntaxException
static RE REUtil.createRE(java.lang.String expression, int matchFlags)
          Creates a regular expression, permitting simple or complex syntax
static RE REUtil.createRE(java.lang.String expression)
          Creates a regular expression, permitting simple or complex syntax
(package private)  void RECompiler.syntaxError(java.lang.String s)
          Throws a new syntax error exception
(package private)  void RECompiler.bracket()
          Match bracket {m,n} expression put results in bracket member variables
(package private)  int RECompiler.escape()
          Match an escape sequence.
(package private)  int RECompiler.characterClass()
          Compile a character class
(package private)  int RECompiler.atom()
          Absorb an atomic character string.
(package private)  int RECompiler.terminal(int[] flags)
          Match a terminal node.
(package private)  int RECompiler.closure(int[] flags)
          Compile a possibly closured terminal
(package private)  int RECompiler.branch(int[] flags)
          Compile body of one branch of an or operator (implements concatenation)
(package private)  int RECompiler.expr(int[] flags)
          Compile an expression with possible parens around it.
 REProgram RECompiler.compile(java.lang.String pattern)
          Compiles a regular expression pattern into a program runnable by the pattern matcher class 'RE'.
 

Constructors in org.apache.regexp that throw RESyntaxException
RE(java.lang.String pattern)
          Constructs a regular expression matcher from a String by compiling it using a new instance of RECompiler.
RE(java.lang.String pattern, int matchFlags)
          Constructs a regular expression matcher from a String by compiling it using a new instance of RECompiler.
 



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/class-use/RETest.html100644 0 0 14254 10577337776 22425 0ustar 0 0 Jakarta-Regexp 1.5 API: Uses of Class org.apache.regexp.RETest

Uses of Class
org.apache.regexp.RETest

Uses of RETest in org.apache.regexp
 

Fields in org.apache.regexp declared as RETest
private  RETest RETestCase.test
           
 

Constructors in org.apache.regexp with parameters of type RETest
RETestCase(RETest test, java.lang.String tag, java.lang.String pattern, java.lang.String toMatch, boolean badPattern, boolean shouldMatch, java.lang.String[] parens)
           
 



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/class-use/RETestCase.html100644 0 0 12545 10577337776 23222 0ustar 0 0 Jakarta-Regexp 1.5 API: Uses of Class org.apache.regexp.RETestCase

Uses of Class
org.apache.regexp.RETestCase

Uses of RETestCase in org.apache.regexp
 

Methods in org.apache.regexp that return RETestCase
private  RETestCase RETest.getNextTestCase(java.io.BufferedReader br)
          Creates testcase for the next test description in the script file.
 



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/class-use/REUtil.html100644 0 0 10176 10577337776 22422 0ustar 0 0 Jakarta-Regexp 1.5 API: Uses of Class org.apache.regexp.REUtil

Uses of Class
org.apache.regexp.REUtil

No usage of org.apache.regexp.REUtil



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/class-use/ReaderCharacterIterator.html100644 0 0 10365 10577337776 26007 0ustar 0 0 Jakarta-Regexp 1.5 API: Uses of Class org.apache.regexp.ReaderCharacterIterator

Uses of Class
org.apache.regexp.ReaderCharacterIterator

No usage of org.apache.regexp.ReaderCharacterIterator



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/class-use/StreamCharacterIterator.html100644 0 0 10365 10577337776 26040 0ustar 0 0 Jakarta-Regexp 1.5 API: Uses of Class org.apache.regexp.StreamCharacterIterator

Uses of Class
org.apache.regexp.StreamCharacterIterator

No usage of org.apache.regexp.StreamCharacterIterator



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/class-use/StringCharacterIterator.html100644 0 0 10365 10577337776 26053 0ustar 0 0 Jakarta-Regexp 1.5 API: Uses of Class org.apache.regexp.StringCharacterIterator

Uses of Class
org.apache.regexp.StringCharacterIterator

No usage of org.apache.regexp.StringCharacterIterator



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/class-use/recompile.html100644 0 0 10223 10577337776 23226 0ustar 0 0 Jakarta-Regexp 1.5 API: Uses of Class org.apache.regexp.recompile

Uses of Class
org.apache.regexp.recompile

No usage of org.apache.regexp.recompile



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/package-frame.html100644 0 0 4167 10577337776 22025 0ustar 0 0 Jakarta-Regexp 1.5 API: Package org.apache.regexp org.apache.regexp
Interfaces 
CharacterIterator
Classes 
CharacterArrayCharacterIterator
RE
ReaderCharacterIterator
recompile
RECompiler
REDebugCompiler
REDemo
REProgram
RETest
RETestCase
REUtil
StreamCharacterIterator
StringCharacterIterator
Exceptions 
RESyntaxException
jakarta-regexp-1.5/docs/api/org/apache/regexp/package-summary.html100644 0 0 16755 10577337776 22456 0ustar 0 0 Jakarta-Regexp 1.5 API: Package org.apache.regexp

Package org.apache.regexp

Interface Summary
CharacterIterator Encapsulates different types of character sources - String, InputStream, ...
 

Class Summary
CharacterArrayCharacterIterator Encapsulates char[] as CharacterIterator
RE RE is an efficient, lightweight regular expression evaluator/matcher class.
ReaderCharacterIterator Encapsulates java.io.Reader as CharacterIterator
recompile 'recompile' is a command line tool that pre-compiles one or more regular expressions for use with the regular expression matcher class 'RE'.
RECompiler A regular expression compiler class.
REDebugCompiler A subclass of RECompiler which can dump a regular expression program for debugging purposes.
REDemo Interactive demonstration and testing harness for regular expressions classes.
REProgram A class that holds compiled regular expressions.
RETest Data driven (and optionally interactive) testing harness to exercise regular expression compiler and matching engine.
RETestCase  
REUtil This is a class that contains utility helper methods for this package.
StreamCharacterIterator Encapsulates java.io.InputStream as CharacterIterator.
StringCharacterIterator Encapsulates String as CharacterIterator.
 

Exception Summary
RESyntaxException Exception thrown to indicate a syntax error in a regular expression.
 



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/package-tree.html100644 0 0 16017 10577337776 21707 0ustar 0 0 Jakarta-Regexp 1.5 API: org.apache.regexp Class Hierarchy

Hierarchy For Package org.apache.regexp

Class Hierarchy

Interface Hierarchy



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/package-use.html100644 0 0 15257 10577337776 21551 0ustar 0 0 Jakarta-Regexp 1.5 API: Uses of Package org.apache.regexp

Uses of Package
org.apache.regexp

Classes in org.apache.regexp used by org.apache.regexp
CharacterIterator
          Encapsulates different types of character sources - String, InputStream, ...
RE
          RE is an efficient, lightweight regular expression evaluator/matcher class.
RECompiler
          A regular expression compiler class.
REDebugCompiler
          A subclass of RECompiler which can dump a regular expression program for debugging purposes.
REProgram
          A class that holds compiled regular expressions.
RESyntaxException
          Exception thrown to indicate a syntax error in a regular expression.
RETest
          Data driven (and optionally interactive) testing harness to exercise regular expression compiler and matching engine.
RETestCase
           
 



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/org/apache/regexp/recompile.html100644 0 0 22345 10577337776 21337 0ustar 0 0 Jakarta-Regexp 1.5 API: Class recompile

org.apache.regexp
Class recompile

java.lang.Object
  |
  +--org.apache.regexp.recompile

public class recompile
extends java.lang.Object

'recompile' is a command line tool that pre-compiles one or more regular expressions for use with the regular expression matcher class 'RE'. For example, the command java org.apache.regexp.recompile re1 "a*b" produces output like this:


    // Pre-compiled regular expression 'a*b'
    private static final char[] re1Instructions =
    {
        0x002a, 0x0000, 0x0007, 0x0041, 0x0001, 0xfffd, 0x0061,
        0x0041, 0x0001, 0x0004, 0x0062, 0x0045, 0x0000, 0x0000,
    };

    private static final REProgram re1 = new REProgram(re1Instructions);

 
By pasting this output into your code, you can construct a regular expression matcher (RE) object directly from the pre-compiled data (the character array re1), thus avoiding the overhead of compiling the expression at runtime. For example:

    RE r = new RE(re1);

 

Version:
$Id: recompile.java 518156 2007-03-14 14:31:26Z vgritsenko $
Author:
Jonathan Locke
See Also:
RE, RECompiler

Constructor Summary
recompile()
           
 
Method Summary
static void main(java.lang.String[] arg)
          Main application entrypoint.
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Constructor Detail

recompile

public recompile()
Method Detail

main

public static void main(java.lang.String[] arg)
Main application entrypoint.
Parameters:
arg - Command line arguments


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/overview-tree.html100644 0 0 15417 10577337776 16663 0ustar 0 0 Jakarta-Regexp 1.5 API: Class Hierarchy

Hierarchy For All Packages

Package Hierarchies:
org.apache.regexp

Class Hierarchy

Interface Hierarchy



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/package-list100644 0 0 22 10577337776 15363 0ustar 0 0 org.apache.regexp jakarta-regexp-1.5/docs/api/packages.html100644 0 0 1254 10577337776 15610 0ustar 0 0 Jakarta-Regexp 1.5 API


The front page has been relocated.Please see:
          Frame version
          Non-frame version.
jakarta-regexp-1.5/docs/api/serialized-form.html100644 0 0 16232 10577337776 17150 0ustar 0 0 Serialized Form

Serialized Form


Package org.apache.regexp

Class org.apache.regexp.RE implements Serializable

Serialized Fields

program

REProgram program

matchFlags

int matchFlags

maxParen

int maxParen

Class org.apache.regexp.REDemo implements Serializable

Serialized Fields

r

RE r
Matcher and compiler objects

compiler

REDebugCompiler compiler

fieldRE

java.awt.TextField fieldRE
Components

fieldMatch

java.awt.TextField fieldMatch

outRE

java.awt.TextArea outRE

outMatch

java.awt.TextArea outMatch

Class org.apache.regexp.REProgram implements Serializable

Serialized Fields

instruction

char[] instruction

lenInstruction

int lenInstruction

prefix

char[] prefix

flags

int flags

maxParens

int maxParens

Class org.apache.regexp.RESyntaxException implements Serializable



Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved. jakarta-regexp-1.5/docs/api/stylesheet.css100644 0 0 2330 10577337776 16043 0ustar 0 0 /* Javadoc style sheet */ /* Define colors, fonts and other style attributes here to override the defaults */ /* Page background color */ body { background-color: #FFFFFF } /* Table colors */ .TableHeadingColor { background: #CCCCFF } /* Dark mauve */ .TableSubHeadingColor { background: #EEEEFF } /* Light mauve */ .TableRowColor { background: #FFFFFF } /* White */ /* Font used in left-hand frame lists */ .FrameTitleFont { font-size: normal; font-family: normal } .FrameHeadingFont { font-size: normal; font-family: normal } .FrameItemFont { font-size: normal; font-family: normal } /* Example of smaller, sans-serif font in frames */ /* .FrameItemFont { font-size: 10pt; font-family: Helvetica, Arial, sans-serif } */ /* Navigation bar fonts and colors */ .NavBarCell1 { background-color:#EEEEFF;}/* Light mauve */ .NavBarCell1Rev { background-color:#00008B;}/* Dark Blue */ .NavBarFont1 { font-family: Arial, Helvetica, sans-serif; color:#000000;} .NavBarFont1Rev { font-family: Arial, Helvetica, sans-serif; color:#FFFFFF;} .NavBarCell2 { font-family: Arial, Helvetica, sans-serif; background-color:#FFFFFF;} .NavBarCell3 { font-family: Arial, Helvetica, sans-serif; background-color:#FFFFFF;} jakarta-regexp-1.5/docs/applet.html100644 0 0 5543 10577337776 14553 0ustar 0 0 Jakarta Regexp - Jakarta Regexp Applet

Regexp

Get Involved

Related Projects

This simple applet provides way for visual debugging and testing Jakarta Regexp package.


jakarta-regexp-1.5/docs/changes.html100644 0 0 23771 10577337776 14721 0ustar 0 0 Jakarta Regexp - Jakarta Regexp History of Changes

Regexp

Get Involved

Related Projects

This document reflects the changes between releases for the Jakarta Regexp package.

Version 1.5 (18 Mar 2007)

  • Fixed Bug 36405: Referencing an optional backreference returns null (VG)
  • Implemented optimization: RE compiler omits branch instruction if only one branch is present (VG)
  • Fixed Bug 9153: {m,n} implementation had exponential complexity (VG)
  • Fixed Bug 27763: RE incorrectly processed reluctant matchers (VG)
  • Fixed Bug 38331: RE compiler creates incorrect program if pattern results in large program with offsets exceeding capacity of the short (VG)
  • Fixed Bug 37275: RE incorrectly processes nested {n,m} closures (ex: (A{1}){0,2}) (VG)
  • Added accessor for REProgram.prefix (VG)

Version 1.4 (17 Aug 2005)

  • Fixed Bug: RE creates wrong character class when overlapping character ranges are used (ex: [a-h0f-z]) (VG)
  • Fixed Bug 30126: Support negated character classes (\W, \D, \S) in custom character class (VG)
  • Applied patches for Bug 27795: Add optimization for regexps which start with ^ (BOL) (VG)
  • Fixed Bug 25985: In MATCH_MULTILINE mode $ does not match end of line (VG)
  • Fixed Bug 2121: '.' or '-' in bracket expression gives unexpected results (VG)
  • Regexp is relicensed to Apache License, Version 2.0 (VG)
  • Fixed Bug 2525: Leading zero-length string splitted by RE (VG)
  • Applied patches for Bug 4137: Regexp match gets different results on different platforms (VG)
  • Applied patches for Bug 3303: Unicode 3.0 character \\uFFFD (VG)
  • Applied patches for Bug 3773: Problem with parsing greedy match modifiers (VG)
  • Applied patches for Bug 3273: CharacterArrayCharacterIterator docs and implementation mismatch (VG)
  • Fixed Bug 22928: subst() with REPLACE_BACKREFERENCES cuts first 2 characters (VG)

Version 1.3 (2 Sep 2003)

  • Fixed Bug 22804: ArrayIndexOutOfBoundsException on negated classes (VG)
  • New Feature: subst() can now process backreferences when flag REPLACE_BACKREFERENCES is set. See API docs for details. Patch provided by Tobias Schaefer. (VG)
  • Applied patches for Bug 16592: Syntax error: Too many bracketed closures (limit is 10) (VG)
  • Fixed Bug 5212, aka 14954: A bug caused by '-' in character class definition ('[...]') (VG)
  • Fixed Bug 4057: \w does not match underscore (VG)
  • Fixed Bug 1030, aka 10893: {n.m} notation work incorrect if n=0 (VG)
  • Re-visited Bug 3879: Expressions using {0,n} match 0 to n+1 times instead of 0 to n times. Now, expression "[a-z]{0,3}" matches "123abcdefg123" resulting in "" (empty string). (VG)
  • Fixed Bug 306: Why is the RE class not Serializable? (VG)
  • Applied patches for Bug 3879: Expressions using {0,n} match 0 to n+1 times instead of 0 to n times. (JSS)
  • Applied patches for Bug 7288: Bug in negative character ranges. (JSS)
  • Applied patches for Bug 986: Leading "\b" word boundary is ignored. (JSS)
  • Applied patches for Bug 3877: {n} and {n,m} not thread safe. (JSS)
  • Applied patches for Bug 8467: Number of paren pairs limited to 16 (JSS)
  • Fixed RE.grep() documentation to reflect a String[] is returned instead of an Object[].
  • New Feature: Clustering (i.e. non backref'd grouping)
  • Rebuilt website with latest Jakarta-Site dependency

Version 1.2 (27 Nov 2000)

  • Updated to Ant 1.2 (JSS)
  • Documentation now built with Anakia (JSS)
  • Fixed bug
  • Fixed bug: StringIndexOutOfBoundsException if paren is empty
  • Fixed bug: Case independent flag does not work in prefix optimization code
  • New Feature: Added flag MATCH_SINGLELINE - newlines are matched by '.'

Version 1.1 (14 May 2000)

Contributions by Ales Novak:

  • RECompiler.compile() - copy on return
  • RE.matchNodes() - BOL and EOL cases if RE.MATCH_MULTILINE is specified. - Think of RETest.java which prints MATCH!!!: ...... two times while in the older version only one time.
  • RE.java also contains an extension which allow to parse InputStreams, Readers and char arrays in addition to Strings. All needed modifications are only in the RE class.

Contributions by Jon S. Stevens:

  • Fix in the build system for building on NT
  • Documentation fixes / additions

Version 1.0

  • Repackaging from original contribution. No major code changes.


jakarta-regexp-1.5/docs/index.html100644 0 0 10704 10577337776 14410 0ustar 0 0 Jakarta Regexp - Jakarta Regexp

Regexp

Get Involved

Related Projects

Jakarta Regexp is a 100% Pure Java Regular Expression package that was graciously donated to the Apache Software Foundation by Jonathan Locke. He originally wrote this software back in 1996 and it has stood up quite well to the test of time. It includes complete Javadoc documentation as well as a simple applet for visual debugging and testing suite for compatibility.

This package is intended to be an answer to a question we commonly hear in the Java world:

"Why isn't there a decent regular expression package available for Java under a BSD-Style (ie: Apache) license?"

You can:

  • Download builds.
  • View the list of changes between revisions.
  • Launch applet and run regular expressions interactively.
  • View Javadoc online. It is also included in the distribution download.

If you would like to get involved with this project in one way or another (Mailing lists, SVN, Contributions), please see the Getting Involved section of the Jakarta Website.

Contributors

  • Jonathan Locke wrote the original code.
  • James Davidson for making the contact with Jonathan and asking him to release his source code.
  • Jon S. Stevens is responsible for re-packaging it and preparing it for release.
  • Craig McClanahan is responsible for setting up the CVS and mailing lists.
  • Ales Novak has contributed bug fixes and feature enhancements.
  • Michael McCallum contributed a patch to add clustering support.


jakarta-regexp-1.5/docs/jakarta-regexp.jar100644 0 0 100404 10577337776 16033 0ustar 0 0 PK r6 META-INF/þÊPK r6sGV^jMETA-INF/MANIFEST.MFóMÌËLK-.Ñ K-*ÎÌϳR0Ô3àårÌCq,HLÎHUŠ%ÍôLy¹œ‹RKRSt*Aêõ ã ,u-Ì4” rRœós JKR‹t<ó’õ”4y¹x¹PK r6org/PK r6 org/apache/PK r6org/apache/regexp/PK r6¸ ƒR7org/apache/regexp/CharacterArrayCharacterIterator.class}R]OÓP~κ­¥TÄ9'¬C§ˆ”N?LJ°p±Ä„ äÆÒÒŽ¶3ÓÄ_â• ‰7^hâXâ½÷Gß³Õ¡0mrÞó>ïGßçüøùõ$Ì㙊4¦†p·…˜Â1#ÃT‘Ä”‚Y¡ç„˜WpG肊î*XPpOÆ}£XT)2ÉxÌ ¾ÍÛ-‘éU« ¬LÖ!w’KŽë„+ ²±[*—g¶â%¯Â†‚Æ^úŽ[cÈz~`½² ‡–[+luï‹ WŒÁ÷I{ßò×B*Fj›p‚ ·Òs_hÐñDCW5Œa\Cã “§eÊn…77áfuÝk¸•`£iózèx4oæl³õFµÊ}—»•nÞ²†§( ±Ä0ZÌü¨Á]›çç §à2VÄ« Ã{¼æ¸½$òŠù~ J<ÛGää4\Ãu†ϯ¬ºeïó‚Ïk¼Y/”è-;äþšï[¯û^™Žzþ_7÷¸M»™üO™ÓDɤ$­z‹ Îç÷}ž‚ÞVˆ}Aý¨z[Åiãh·zaiP˜ÞmJ0 &2»:ÛÕ ŠÓÎHN—G qÒi³ fζ3s-HæD ñÏËÐoéeK¤ræÄavØé ¹Ó†œRN0”;š&CÄÉ>ÖÆ…ïú;(zîÓâG¦ üÅ(1w0ºCé1:’þ2§WÚ¸ô©?J>%CƒÄH«¦Þë•ú¹›f,Âh§å?F¨IÜŠPYÂÔH·Ð{ÈñˆK=~PK r62¯+óŸÓ)org/apache/regexp/CharacterIterator.class;õo×>f]v.vnFÎâҤ⒢̼tF1 OOMŸ¬Ä²DýœÄ¼tý`°¸5#ƒ¨vq¶äŒÄ"ÇF gFÖÌb×¼7Š‘A9¿(]?± 19#U¿(5=µ¢@ߨ!1¹$µÈˆKò‹û'e¥&—°120201€ #й,@ˆfÓl ì`šƒ¤PK r6R—àsè'org/apache/regexp/RE.class­Y |[Õu?Wzú°ôlËv^c9Øq ŽäÄI0j’€¬(‰YRý‘Ä$$V$Ù(’*ÉÄ@Hi1tck·•5¦íÀ¦Òz+¬‰Mšº²Ai¡íRºulëç6:ºŽnëè-î9÷Ý'?Ë"°þæßïÞsÿçžsî¹çžûñ䯼õ¹§ÀëÙý68Ī,Ìf³S%§ÚƒÌ^…­‚µT9,¬ÎÂêm`'Á0k°²eª–gµV’V#UWU5QËIúÍÔZE­«í¬…µ\MUUk¨º†z¯¥ÖZªÚ©ZG•ËÂÜVÖaƒ5l=YÝ`@Ò7’Ì&‚›©uµºhë©j è¡ê=6¶…m¥jU7XÙvry‡•í¤î‰yU^ªº©òQµËÊüV¶ÛÊöXØ^t³õ$°²}D÷“ AjõXXÈ5>­Ô S+B­÷ZX/Ñ>ì§jÀÊP÷A öJâ¢Á-ìf ;laGÈ=Þ~ßÞc¡po7È€Tû2é|!š.ˆ¦FFÀ?Š*çóöù¡]þˆ«P?u2µjgÏ@°? „üÄ60p¨ì¾@hOЯñ%æpäêãh>âøUNw8Hè¨èWÑyCƒ„60°ª(¼›ðaU¤Ùë ùöã4 ô‡{zUØ×ïí%èRa$8ÐGЭZëñvsÏnT­ùû|ÞgQåÃ8Y‚í8QùÐF¿Ÿ[Ý®šñÃ}\kN\Ãz¹ lä¬×·¿×ÏÝoSíï ÷‡ îQBáþ½1â„ØÉT8Ô pë>Õz¯?8àë÷†úµ¹m)ãk“ÜÁ NÏ/Ͷš‚î ò½}\:‚ùyƒ¡¿S85ÿ±P äÝÝáÐ.‚ÇÕîîæÝ}¯W»K¸wï ì 𼉫Ý%ŒùPǽ9ÆÝQ½X‹ìõ’p´¬£;è í/ãùBý½<‰be|È2Þž^o„§ÐHYG0|P]¿TYG¤7 n€lyÇ@ÈÇ;ZË:x$Êx‘ˆj~”A½¾ãP)0ce=ûhÍyÏ­eÆöEDÇmê“ѱP&žÀ¤îñ:†=j;pÏg†‡ó‰B8ãý%0®6†c\¡4Šô%ïäÇ€­fs™‘\ô$ƒæ`&7ÒÍFc'¹ÄHb,ÛÙë¨Ý7à¶Í'¢¹Ø ×Tôˆæ¢±B"À-dr¨`;-ÄNìNEG(qÐûH4—H#?KÔ—MÈj!š+ld %ÒñÞ¤âMÞ¬âÍF+†Ã•‰m™3»£±Ûr‰a¹%`Ç9q™0Õð8¬ÓÐî@o_8d°\ã‰ìÇÀúü˜ÜæíÉt²€Û\iÞ½=Ú™Š¦G:û ¹dzä†upx·Í?Kd ITH¦9’ù¾Ì޲cÔú® ÏÃ~ß“áŸàŸ4]!Aq ËýêF£lˆáijØà’Ùq£*.³¼"³a6"×iŒ¿„¿’Ù j}…ª‡×dxž“á§ðš…%ev+»M†¯Rß‹T}ª¿†Ë2¼Žà ¿FÕ7¨ú&\Æ'Ê‚;"Czý-ZÒ¶$ˆ·­…&ú²ÌRì¤ ?‡ÿ‘Yš ¼D–ÿþK†oQëgØbxCff•™Þ°°¬ÌÞÇpryª Í+é\"–Iã-oIäcÑl¢e-ͯ4¶V†ÿ¦‘n'ùST±;dv'µî"õÚîh¼%›É'ÇZb©hWÎHßM%ã-~Aµ¬E!_&—ÍZJ×Ϻ¥k¢FÉ&‘áMø%ºÊ´` „–B¦%7šn•ái~§)oÂ/pp¾ÑB2ÕyóÕÙÝì .üDfï‡W4 ÝzËìö™1f”áßà'8é52û »—,¾%³qvƒe•Rh‘-5ÏQ’³’™Î¾D.‰a¸3z<…ÙÝVÉ@ßéBt¬tàASSšÁ¦Šçø;\Ù1ŒvJáCÓÍftæu¼«KAÍ{´ÓÔî»B¯9%Î[k!£vá¤Û+UÚ+ _1K–5ø ¦]Nçw%³ö$~ßäFcjÌ ‡qª¦aõº2%óü”oXP+‚i˜Ìt†s»’#I)µ–d^0ädþà‰d!‘GOŠ .”BaÕì‘Où>R¡ÑÐÞMýwdêxƒ(Éü>´ˆ'Ò…äp2‘wÔ²r~„³Íx¡'ñáh‹ÆãþTâd‚nÎE…v®Ò»$[½‰e²wÒ… …®Ò|€&šŽ'ÆÂÃowuÑ-[È3§9_4/ü÷A+‚AüмЇá¶o¡D8Šø˜!ŽêðqÄ1ŽÃJHÀp >¡ÃIÄ·êðmˆS:|qZ‡3ˆ³:ü>Ä9Î#.èð(âÛuøâ1¾ñ:|âÓ:|7â3:ü~Ä÷èðP‡ïE<®Ã÷!¾_‡?„ø7tø7? Ã¿…ø·uøÃˆ?¢Ã¿ƒøwuø÷T‡Düû:üˆÒá?Dü1>‹xB‡Füqþâ?ÒáIÄS:<øœ?‚øÑ²ñÿX‡ÿq±lüOêðcˆ?UfÿÓ:<ƒøOuøÏF‡Gü„ÿ9âÏ–Íç¼_@<«ÃsˆŸÔወ?§Ã—^—ß툿 ÃO!~zÑ~Y _\´_VÂ_,Ú/+áK:ü ÖøÊÀúzYÐ9ôôàôyNï¡·§_ôA_ôk‚~]ÐoŠN¿)èK‚~‹ÓFø›²}þ·eûüÛ‹ü^…m|”`ûï‘ÓFlX\nã°'¸Ãÿ@¿¡Ø?rÑïÑf¥ÏÓ:×%0 ÎÑ= ’sL•”¾‹5)µ¢2))®90»Ž 4Ò,X]ÎY¨RIü{B|±;¦ï åÀ0›‹}l 2Uðø¡yMHHç.ý”ƒÆE˜¢«w6š‹ãþ¨Á²ËýXÚ]'¨ Ëi,n7z£ ‡="è-‚ô.AO z7Qw}Í,Ô,‚Ãí82 ŽƒîfªÇ Ìéš…ºéù£šúÇŤñM,&T¢¨˜]M A Ê¿À+¢¿)Åä: 3¢ûG¥ v õ6—û,s? ËÝçA1LB‹¸$E¨R×F³ý¯ðjÛË4×~\qèåÚÐø:Ýq!øï‹MÔš]M³°bpÇÃЀŒ•N‚á*#<ÎTãuô:Ú}Âñ=Bû¦¦Oq—º†¼¯ K –kP¤i+'UÍT­zóh®¦fӆÌ৿ö-d¶•ªÕTµ- Цà?J¬ù¼\ PË'̃×ä—ѧ€?,öXXÈ„Cו9ÔF©ér^€¦":†ÔYÄØ"m.âV+›º3ü„èg¿þ@-b V1Ðju E!Ð’è[Dœkqc—`Í Øõ×à6ÀT¯ÅlŸƒkŸæJÚù±Å_/í÷E¯sá–ÏÛ.ÀªR«Í¸½Ëø aî€!<ÎÍÈ2=ÿªæ ~w©Æª:Á„A€ª¶fDé|Ön«jòØŠUæÆ*ÅÖå1+6j˜†ºò˜¨) uy,Š™ÇúŒnjÇŒ•§öòo@z ˇøÒ€Ÿ¬zÙJe‰ îvYÐS*ÏÔ$ú>+èÅÙ·µ-úL¼³Z±¼„óKªmãŠw¯÷ÿZN¸›y¨¾]‘faÝ Çj˜´ *Ö—bÒóÀŒ<…Vˤ.œ­hñT’áÖç’‘’†^Òüs’äÉá’ΜÛnÅ¢Hár“×*Ú;Ó`w)iè,GŠÛ0Å9$Ù±ÔÖúÿ‹­F­ ª-ôeƒÇ®Úà‘;jW)2 š 3Š]‘§À\4oV°'CV‘”ê!)~:éÙ†RtK;©’ÑScôÔa½K•—ØEØhŽìJíGJÍlâÊãµL©Uª§ç/M/(ÒYÓsdÎtÆ4…E’âs°ù,º`ú h¥‘;ašRÍ ôÑ’R-*i*§qõ‚fiÃaéÆIJ Ë'ù‘­Òƒ‚ýqó‚ž"ªH`uØðÂUG§(àlxü4gΪ5‹ú1xOÂuŠŒÕ”“bq×ÚSÒeur%¦Ìí«ÓÀýfáûQá{Aø¾Uø|Tø\>oåCO€M±;Žé?¥µ'a-ô“Ð…Üø·Iå^Üü—VLbE©Õ¥½"òã<––—Ȩ±Œ`Áó?bÁ@ktÒF¤)Ô§ë>‹t¯XzÎ"îkD»1ÄÓ­9-{lQ< Û&ØCe¬® voë† –-c]?Án)cmwÔN²½åL~1áœ|wbY¥/E¶¢\Á4Ɍ墕"L.Rulœ^È+Â[ŸGËú‡Åת{§a…ï~DK"ôh‚vÄ"GwLè—³vN€Yõ7bºSâ²Ú+m`¹¡Ys(ÚàuJíôü—¨-6ÜEWR—ã4éã6c2K.@~‘ioœ¼M‘ñÂSä³PÍŸ0¨;ÿ¢a¦¹ .£zwH3¥à&:̋ńFlÎé×ßpÕ{‹§©D?ÛŠ—Øiñ”Ϻ øì¤ª…*'U­T5SµÚÅ艆U›K¢k̈oÝݸ¢ô|s—Zë]Æúö&šâœ¡ÝeÄOµ è± µŠ7á“«„'58¥îA÷øP~ׂÜ/U9ÖŠrx…0z§.{?qêý85úZ)â7ÐÍê]4~ç^Ghk·¶î3.§¸›èñË;$ÓŸnn§šBó?Öƒçââßó=™BÛ$Íp)íTœÕXv*îjÛõ8=&£Çìr+¦q“8%ÅYËY°+æFé©éù—8‚ê²!‘Y:ŒçÓ…õ­ ßÞ³°W˜g Àç³é™KÀLÚ×c܉ø::±Å…*+<&"øŒ67OÁòw³b’†faÿ,Ñi¼d9Ke(æÍŠtoú Þ;1ÿ4Ñžm¦F¨; UÔvÌBè ÞfîhÄœ4šÅ7(þ„_ËD>X]îÿ½ F‘ W¡ç2Ò±¶aÐLÜw\ĢO€{V{°Ù„ËñÆÕñ–ÇÚAbUEHPø<‹ÏBµãÈ$D試Tƒ=ÄÅyVÓ&¢³Îƒdë#ÐÙ(á Ð4D×-7ì¢nTïÝfo´? öF©ÑN|Åⱎ[XG}‰öz,ŸPS®ÊE°!‹›áQÆUW0}ͨˆú¦fÊ!œÎ2|ášÏáò»)Ò×6•Q˧‰& Ò Lb&Éý˜&úêZXaüÜs7ož…m’‹´ð•‘hE¬Ù ÷Cm‰$Î4Jªaý'KÞ)~ÚL‡lÏäN‡mV9Õ“°ÒY÷MB³®¥}lHÖiO˜aˬÂÖ*ñóN}3zMOÂÁíN¬v49ãª,ü PK r6û®YäG*org/apache/regexp/RECompiler$RERange.class}T[OÓ`~>Únlt0³- 8ŠlxŒ ‰Yˆ.!YÆD¼¡n Ù)Û Ìknü Ä«‰ —f‰C£Æàðç¨ïÛ–±C—¾§ïyOÏ—îçï¯? a‚áz*n°ˆ³¸Éb–Å­ ‰‹¹ L̳u›Å‚)?î Èâ[@dËÅʦUÙ%wà•ã[‡ž/Uö˾f¡Øˆ/ LmTë»)«få vªnïÚ‡µÔæzºZ®Kv}U °Õª4 v³˜£¬µb¥Ø|,0“¸¸ÓkmŒ¹Cë'Tç¾ØÿIo±7´,»eÅAFdí=T3ÂwF«ê…]]Þ‰(¼y¯Ã¤kQ‡c"Ûq+y§JïT1¨X¶µíóEè{ô‰ÑßLzÜ8¦~ͧ4<Á ôŒ‡'¬DzÐÔ1ä"î ’V‘Ä"ðPK r6lˆá"¯™""org/apache/regexp/RECompiler.class¥8 x×qón÷îöN+±, î.œ 1Ò ýàÀÙÆHd¹V-!Œ"c! ·Ò-ÒáÓÝõî„%ƒ©‹'MÒ¤!?-Ä6¸=7¨­M@Ð@ìô/mÒ$MÓŸ´©“ºI›þ¥nú“ô+3oßžö$Aœ¯Ò·ï½™7ofÞüí}áÍO¿4±xÆàŤáWhød.ÀLW¿ê‡_Sà×ƒàƒ—ü𲃀—ˆèS4\¢árfá ‘_ B ü†Ÿ&àš®a%¼HÃghx%¯ÂgiËoúá·øm~‡ ßUàsôþ÷ø}>¯À$X6÷& 7ˆã(ðEzÿ%¾¬ÀÒ›9¾BÿqøjöÃûáOˆüOéô?Sàk ü¹!ÌÍùáëAˆÃ_Òð½ÿ†ß$à¯x]¿àò[4|›^þ ­þVïÐAß#ÌßÑð÷ üƒÿ¨À?Ñ™ßUàŸ û ÿ¢À÷øWZþ ÿNÃÐð}~ À’°ÿ¥À+ð?~øß < ÿç‡$ø‹ ¼I‚Ï!À@aLa…I “æU˜Oa~…) (,¨°*…© «ö³?[ÆÀ¿·s¯™±¨]™Œ•ïH›…‚U`P•ÊŠùñáb*›aàì`P“¶2]n,ëB9³X´ò…º˜GÍ–4²ké+æS™‘{H¸ÇTr‚/gæ­ ñÞÝ{oç¡Ý½{{vv3¨îÈ"S3S|ÈL[hoDÚ$ýÝÝ;wuw’9Èwõîéî|¨³›T¸³¯ãPÏξ/-wíìx`oç}êèíAê‡8Ô½³¯6”7‡µŠý™¡ìx&i%¥9ücøžTfèÍq÷¨YÝÓÛ×…œt[Ïñb*Ýr?¢‹æPÚBU}ÛS™T±µ­oxˆÜ‘M¢Y}¨ñxr}G[c©"A3H„6µòˆóÕwtqµ`w[ÅÞÙ$o½–3œ£ÉÐòÕ© ÞLwæóÙ<òꜶrt3dâÂd¦hNˆWzýâ»!Ž~¡#‰Y6sy× šøª(Ï6‹Ù146bÆRx&‰1ÈÅð§³¶†>ä–%'ryz“Ë¥ÒøfóRçwgó#-fεZòÖîiÙÛ¹'ŸÉ›chNeûpšT…÷ÁûUÈÁO©‡‚Ÿi*[ÎB*ü|Áú¥¸ôÙÊ;ö`°–ÖÞt¬0šÍcGÆÇr±<9~3±?Ã`Ù¼€Âh˺„}c!êTx *¥¡ã~¶Be+™®Â/ xl[fëœÈYhµd,™IU8M¬W-Ô}×øáÃV^ekX­ÊÖ²°ŸETeoSá@[¯›§ß=>6dåïËæÇÌ¢K½|ÎQ3JÆ2œ w–ñhú13–ÍÇò©‘ÑbLܳ ï¡j*ÉT¶Ž,Øe&m›0XÑ“*PÒ]®Å·#vM'w’˜p‚¢Uˆ¸B*‹±:Š1‡/év ë„c£Ö„™´†SchKn˜BÌ<ŒLbðmçX®8I’ŽgÊ|Q0r;•m`oWá½ð³*»mD±æ-Óá8¨ÊêYƒ ƒ£þ]Û Šóp¦˜§TÈgä™ÃüçMg£pôæ08ŸÏ Ó\Èñ8òŽçrôÞ7!6H¬TZçø2r+Ä«œ†Þ¡#àBõMŠ¦ì€™Ï›“ÃÙÜ$Çí=÷t-âåF[˜¶P`rÑE»˜aGàOîµ5 z†Ý‡ÏDÍÈÂ/ÊùvÞ£Ü^Ì:,WÖ/¦CŠåó8JÃ#¤¯‚V)`µ,Þ¤ a1 `åì¶2#E¼…ªb¶›î¡Ã,X¶€(ñ¦%+ÑM £ž7(Œ„«¨H/ÙP}½} Ë7,F!O21ï„x-F‘ëê—¬”ŽØ…<•Nó~åØO(lø,¡£í0ɈFÏ3ØE°9!`_Z ·ò®DÂbp×"¿%% {Ö1ìΖãƒe›::ªÜ|ÆÊÉç£~LÌ|^“83xœz;8†ðqüÂ'\ðO#ü¤ î@øg\°ðI¼á§\ð„ŸvÁïÆñ!Ï{„±!Ê_‚Š&é(‚Ãý|’‘SöÊ›ú9o_Â¥&mÁx?½8uØ›ØÒ^‚µáÈ(ĸ-Ml/¿‰ž†ª0¡§ç^çó9¸=NÆeÿ?rª¯o ä¿Ê«b¢O•µÁ_¶¨·¨£ ·a¿³*‹O@¥„ñ%gKlÜÐŽÄr2¤ ^ƒÀ@(xª^忈Œo8c/'¨u¤&ûHâF¸‚؇ó'Öì „QZöU<[ŧú¬Å©†„Rù•©³°L;vüÆ,hóT+9Õ%þú*,?#š…×`åÀü AK7.f4 «öÝœÇÜWŒÆYX}Ö\†Ú{ŒPY:¦éŒˆp¶iOL!Lgð#ÈË£/ßZ—Mg‰ÏÛ~LÆžJÆ7S¿Qš…uÿ?ÝY›ÄÓ* }–Nˆ¹„^Z¹'¸ruH÷2Þð3e…µì$;Å>kxv„¶x>0Šç3npݹL¡X=E¼o›vñr»ˆ r·l’»šç­{ýGÐ}ü {/û>Ûæy±m¡õ3¡ 3am| üþÈÞ6 óÔ㮫 $¤µNÃjœî>ZÔ?¡Ë ­5‰t÷ëòUx;§0§a-N‡Ïà N¡™É„L ÑzC„eèöY؈ž^jÀúÖ*ô¹Ù G/»WUd@N¶=77Ñ3ZpF«žÑÔ™[Å@Xk‚£8&ÛæÉ’•d§¡/â›XÂu[“ ׮慻¢7ß™ 3á™EiîyÇÁåtoçõn\äàûÅp¿o¬ˆ½×ÜŒ¶MÁ+-¸½ÕKÙ´â|¼¯ŠŒóø s_vË’_pÆP9ØB¬=„ Û$›z.BÓ¦Yhþ,´ìnúæ‘ù Õö4ÍBë,lž);ÂxÿH½1ô„„¶Ð¨ bÛ¼=´µ-Ò.ǽRÜGÄýR\¹ñì*îÜ,yF]Ò] _À~€¾&\SY<€O>ñ¹M÷ž¿ŒÞ-Å©&ªº ÔÚ ÚŠMÂ]ó¦*y4¼’»âU”JX?ýLJ?ˆ"ÇRØZ#´ åÔ}§éZ¶¹Ò6OB\–58Ü‹ÏsøôáƒAûð9ŒOiªq¦.ê2ïóÞ@q4¿îEyjƒZ-îÁE¶ÎÁÕ…¶òe .m‹ƒß¦½ÓYjeÂáp¬¼íDå¶2þ0B‡¼ÚY¨Î"è,gã‹4áÚÔw8îÔö;ËCi«v7ÇE0\Ò«NÅñãmGãÉq_["¿„—+n|÷ÒÁ m%&«G#¦!d¼Q—ã]ÑÓÎÕ b C•À˜‰Šh:Kn=I¯Ëí7!{dêÆSÎ+m “˜','jƒ— ýT¿¯*AÌ h‡^Õ|jÞÉxºŠéUœvzîµ%ÒÈY'°Úu’4´47 ü ˜Âø$>ø ˜ ºã—à`ä ì7B»ðJð ÒNjRa uœuLA•¥‡-¨"7»‡• b,Õ(Ñ»rsöæ9dí$jºV쟗¸¥)˜·4`O°žJ“°­HU#šëa™Ia™ Ë<+,sQX械̤°ÌEa™ Ë\–ùea™Ia™‹Â2ç–ÐOâ‰xî¡–¯sÆÝGÞK †~‚çáûù¸KTœ62¤ÝYá'Í|BŒˆç®Fé@³öæ‰^C;P‘ ù9nVËSä“]Ñó4?ÉÖÍò“¸u}”“GPF‡_™ï,<°Øàçƒ{¾‹A_Óž×¹´òõà€$õî6°ætÇebÒ$5ãånÛ§Ë32¯åǧû.»ü \~»#tEÀëò–¸_÷kÏB§ >¬€ºìA7EæØŒï‰Äå(Þ¿7â*wâñ³•å¯ajîí¨º¶SÙ Š¨ˆ.ó…rn| á Î/xÚ<<P€6{OœI÷õS2xûhKS.dvë‰Á²ÉÁx¢=]ëmãä³[Îí\°ÔÉm®8Õê èâ¹°‹x޹q¢—úB̆}Ø b݇[Û¨îã´…úÇe†v\"ă”<æyê>zÌâDÍÙ¸ÊëŠJKÎ]‰<½7É Y D9ã]˜3"2áµòˆÍqüH[chí’X£RöÅõ£våÑobK'ýX1£kÅNÞŽèÏVö§à z’°~Y1’Óµ´VäÕK >À‡+óIÕøéô‘°iåboirR+JN(ø—yøXÁ'øTÁgèWð9¾PЇ~Ús«'_˜Hé)O·GBÝ>‚'pDBC«'§Ó‰*¸‚«TÂ\>§±}‰ŠÚêQáxi/}OVÐv²è _⪂¯ðµ„ «”@Æ7 æ0Ï÷­‚(|‡pÍùîwION9Ž…’ÁX2‘ *¸†ïWðxt(A%4£àp/‰Úˆ…c‡ £WVIÍƆé}†z˜ž›½ƒ±P¿Qà`R0,NmXF2ªæ°“S“ý‘XŸáѧ&Uª-Y!5–ŒÄ†Â†r8 ÆÃ†Ç •PTMTUzƒ¡#ƒaÚÇΣ&"ÇCÑ`‚²­«FóP"4ž¿¹ŒšóÅt UHOi" s…À`ø6VJ‡òÓ…L–DÓj>ËË:ÛtBëÓš.a·×tÌÕ±3Ú¸ÞÙr/¢J¦ -7!¡Õ{ocÜÛ+Æñ¤8÷j´´*ô¥–Ûè]µã䳩lIS'©Ö™ÜŒ^,ë™|ŽÎñ5”µÀgŽÛu•=Ñ3Ê•õ,¹¯Íj¹ˆ9^ŠÜÝqçgtZº>_Ò—îœÚ¡&E-5M›ÙºÜðjI/”j+œË:™-ÍL‘B:V©ëÿª4ݬéÒ¨8|k%“M—‡é×zš©aõ-@º ãC^]Þ ýÜ·P·ˆúa÷,eXÿ„m õ/Øœò@ëjPd)h?êèØåvxæÑàv\¼†Í‹à hpÚËht—¡”±æ†û7¬­…Ó%R ï Œš[}¿`»­»2YFÛzª¾¦2¤â\OöªTECâ»ÁP‘î'šõÝ×%™5šÚz*Iµ[*–u´ír»Õ_Õ%YÅé$MN°l¤ÄËp¹¬W ø›È¼ŽF“Ë:ZÆæÙºúmŽ‘9äüÎ-´Rßn»Ž¡ŠòlÔÖ./›Â%»Ä~ŸK.ckEÆ[K\cÎû8»K¿ŒÌ³6ÉesYæïüäwRÝ\ÛÁ9ì÷;›xWθÑï[Jdh»lÖ‰vÛ•;ÿøT —ßy4‘—gþö¿7—jU;ÍTq~a®E4ßÂöìˆúüeì¤ï.Ã] Vs—~­¼H?.b7íÏϨ«G§·Œ–c5ÒÍÄg&&~3 3i5“SLöšÉN&ûÌd“€™Œ0yÐL.0Ùo&A&™‰ÉÃfâgÒf&˜¿·Ÿ_ðp‰£>Â{ˆŒLÃk¥•¹!xq’ü´Ê™0î”Ϋ.-«Vé‚p߽ȵ²3‚׬xt‹ÞŸ%Y„ L#àp\5…µ|zfÑpÁ›ZÜ/nyU_@ˆ–Zs“–²m¹%œü;{žËÚpC˜8º”º¯­á•=“7ÊXˆ—I†3û›^Ví!vC`½©Eê3ï 7W@a÷í¼ ~é}kC‹ž‹G?PK r6¶là org/apache/regexp/REDemo.class…W xWþŸ¯•×ÏŽ#ÛMÈ…“¦­,+IZì&ØN1HNp‚ã„vm­åM¥]±ZÅ6”B¡”û>ËQ(GÍMSj*(W(å.7”û÷}-3o%YŠÕ ïó;fþ™7oÞë{¸ënÔc‡:ÆájÈꨃیQxr:ýÍ) s:puÌcAÃSu´0üi:Zq]3mžÎÃõžÀ3u¬Å Œ|Ë<›97jxN7éX‡Xás™ø¼žÀ xÿBÞ¿ˆ‡óð /Õ±Í?üe<¼\Ç+ðJV¯âÕ«u¼¯Õñ:ܬc^¯á :"l_o àM<ߢãÍx _èV oÕ±›-~›Ž=x;_ìL¹…5ÞÖŒE¼SÇ»ðn ïaÊ{5¼ßÀ¸µà&}‡;´@^Ç2>Ä}˜)wñPÐð‘>ª#†»5|LÇ!6ëø¤†O1ßåáÓL9£ã3¸GÃg5Ü+ \ bŽ›ŒczÖŒºfÒœÏDG‡úÓN:c¥LÂ\X3hNå’E h3–™JŒ tÆN§Œ¨1çEšóÞA¦@W€¸áMÏ 4:9±ÕØý®iðáÄ-›®´lËÛ'Pêhp&ML$-Ycµt…|5)ÃNFx®e'û ~QÏZoÖu挩”yÔñ=•bGKüþžÕÊHU.“0<“Okñ—EÅíÙ=f¤ræÀ,I˜ Í¡•[™§LÛ¿Û¯”Y iòÉ÷¡ÉZfKLƒ”tÖrºÄŽ lý¿"1‰ãtDÙŽ«\+qÀHÆŒò­†ÏI|_Øx.`À±³žKöyY5eî°5½,›öE‰/áË_Á}me@̘2Sôž£f2—2Ün²É5³Y˱ûXê«_Ã×%¾oJ|‹Eƒ«ƒD ûødh²9YÏp½¾þ&£Öážã'$NàÉßf šï²>VÃ0B“3Žs¢‡VW3æ;¸O⻸_â{¸Ÿ`U I\¦`hø¾ÄðC ŽÄ0«áÇ?ÁO5üLâç8+ñ œ-ù³â½äffØÛ¿Ä¯(¡t‰_㬆ßHü¿“ø=þ °NÉXN”âÃÝïºÆÂ¸kyœX%ÎaRåùTvÖ%þ„?K$ÙŽ¿HüÓðw‰àŸ%!eÂÐü´™ñÈÅ'qm«Íÿ¿)ùT´šÙKuìÜÎÿ‡rª{o·Äñ€Äƒ( Û3Ûm;^wše4!¤¨õR4°R˜•H+\Ù¡]#MI©uši‡¯@ü µƒ4ílß):nضMw ed³fVR4 M`ýC‰IÌ !E M4K¡‹–re2)Ó‹îWSeL¯$_ÌÊz¦ÍN_‰; u‰ÍÝ~jxEöú´¸aI*rœ»Zh˜~¼j²TNPdÅÎI*M†==ëf1̉¾:Ï•Šz#AA®8ó×±U¡¨E$¯ÓU9zYMéØyòZÝ£1Iô…⼩òbcx"\@ÝÄ2ê—Ð@ËFZ6-A;­„WZ_Hl‚FbíÔ ÷æ¡ÐBÐ: ß2Ú–°&ÒÞº„ö^R¸v"l\FG‘<º"tΑöµŠKìuÁõí¡e<ìØ6T`6Fê°BͦJ5 Ì­c\•®Í%][JÀÆ2DY³„n¶*‰mdû…„Þ¾ ]ž¨È߉ á<.¦y‹šE—øž÷è¢{»è3½ŽN¸íä¤P bÕ„\T ¡ö]„\N€š{‰Ý“G8NsïÄÈl, B†í ‹. FiØAy<"¹½¨$U>ç:RÁJ®¡sèO#%;óØUÀnRqYœI왈,ã‘y\&Wäñ¨;ÐG«þE:•éš»ÂÌÛK¼Et¬wøÄÓê6{p®Tsœþ3â_ºlÉõÞšfdð”¢ü^º ¥v›Æ—1ë-àÝápO(`”VGâ½dGç8 Géˆ'ö’Ác¥¬ú8:͇Ô>ð?PK r6›¨Úe§!org/apache/regexp/REProgram.classmRKOQþn§3eJ¡£¶¼:Õ>ÊLa|4,|Ôµ‘„†%Q.u(CJÛL‹ãÂ…ÿÀ»²báBL¨CXºpéð§¨ç¶6ÄIÎ=ç;÷;Ï;?~;„IÜ "ˆ1•Žñ zqUÀk^Ç ’˜–!3€T“L1„çóÏ^=Éf²OfXŽ¡/[­Ô¼ÒXäåM[À‚§Ôù9áñ1ô:Är7‹ §Zað-eúËv%×íUj®½êl1È«e^ª3¨|+Ï]»B¶rß©8ºL.e'üÙêk›üÉ\+äÏ #\²]y)ÖŸœÃõó*Qóí¢! #Âú…e…0*à%D¸Â-ÜaPxaˆUÝ’Åk¼¸f[®]²·jÖÂlÞ­–\¾Á ­ó7Ü*óJÉš_Y·‹ †HÛåT­‚í:¼ì¼å+e@JЦ»ø…ízæ*w]¾]¬Ö¶ŒäÜù„÷rÿqÑ0 ñ® !hž>ô“¯ð….|‘Nšâ£QÛzÀÃjk…b†1BgŒP„~$éÃ4OÁ¾´™‚¡{Œabˆ—ï3R)Á0b-øþÑâM÷hšqÉðÇ0õ¯ðŸ2/ãŠÇLAn—Lw0"Ô±M<>Ãá³q8Ìás>Ïá&7s¸…ínãp;‡/p¸ƒÃ9|‰Ã‡#îäðe_áp‡»9|•Ã=îåpŸîw0vâM<àe7ÁQñ ‡4‡qòÌ1_ãð‡ sx„ÃqrxŒÃãžðÀ×9|ƒÃ“žâð4“÷ÈÕÏpø6}¿Ãá»4ÿ=ßçðÏrø!‡qxŽÃ ò?åð3?çð šø%‡_qxžÃ¯9ü†Ão9¼ÀáE¿ãð‡ßsø‡?rø‡—9ü™Ã_8¼Âá¯^åð7¯qø;‡×½ìnø‡rxƒÃ›Þâð6‡‘Nÿ&Ø8ü—¾ïpx—à œ——€¾’WrHNäÂp‘Ü\ò`ÄIÜ#å+HöLJ;R==z2©'ÁnœkˆÇ’†3.ÔR:º“1`¼­i×¾–æ¶&`JËÅÚ~­j@‹õUu‰h¬oÂ{âƒCÑ=lYK<ÑW¥ i=ýzUBïÓG†ªÚ›õîT_ƒ…„y†ž4⩘R›‘A¯H%H ç ›çïdDÑ`îõÑXÔØÌá's©XsÌÐZݯï@NˆäóçèˆDIi,t*R}ª·š†8©¢2äèíZB'eŠý9]$Ðç fu)#>¨zÄÒKøj›ÑOÞCýí Ýòw¤W¤æ:†¢F],²%¡Y$©nò¬áâ&Œ¦KSÚr[›ÃÊÓ™!íæç mnz÷éFÓÈÞƒj·ëÉÔ€1?qeäÞh,Ò¦;Ä VXhÑx•éIâ EУå§Ò{$/°Ù(̦oÐ’¸8kfà‘Ë×6%…îúž2H)_–d©cdRv&’<Ò,Yš .` ¦ã*ƒ\2¸Á#Ã,l¤Bi°šI­O¯UMÕߊîQ;ážrV iF•¯¢uëÅ…­4FŒ=åI‘¥¹àÖP?ª6ê½:VŽ ¨'ªfŠJdIµ7T‰Z]‰÷$-ˆÕJµ²²’X¡ê³O‚Éìö_`%ÿsÛÊì_ìß2ûaåÂöHE²ä“æÉÒ|inÍÜ“¥bi¡ÌÞboËÒ"i± ùdã\{ ·#²±+Å Šî”–ÈÒRé YRIûy¹×w• hŽ ¥ ¨kƒ&L–J¤Rb´Œš2`ÒFU––Óâ¬@áÒJ˜ܪ=ýjÒL†½©JL…æm|=R)ƒ ž¦D"ž¨U¼¹nG]‹ÚÔÞ¾­½V•!Œ8'ðÿûMG©ª›ëš[v¶7•¨jnJô9ÊÈ«~Ì8ê4¯\B@Pª¥„ªRPΡF¡Fİl{l3ÚGq‹©’VaBÁÄ<QcqC¥­J¶*Ù¸–[Ñ™«eXèÂjd*)­’¥³ˆ³å8#:¨ eŠ¥³1ªƒÉÊSÍTwlmjoRëðϲ´£$—¥¸D"ª”útC¯TQ/n†~veÕ:CüÉr”ãòkòn`K:ôDTˆÐ#U=™¨6<P£†^—Hh£ÛRF&‚ÈH\ô…6Ò¶î‹1ÇMÁj¤s€->…MVÊÒi-±ªÍŠS“Õ¬uÒzô“¦i¨W 1j.Á ðåJš]‰{ßèW§˜ÑÞTI9žÀèk#‘Òei-‚Ò˜ÃÚ’­ZR‘ªõâËb¦QŠCf\ëîñw Ê-m­ÛѰu_C]GSs[cÓö&lÚv¨6‚,m$ïxh!|7ö"‘ž'k/æWÒ¦2»–®D\ßÓØH4 N¦1D4Ëêg¨x]}C#ýС'‘Ù¢›m&ÅùëÐ]«Q‘:­½V_'~hëÉ|²ÁĬhÊL†£»³.´{Æ'oÐêûõÕÕ§êdC„Nö ÃÁµ}‚yÉéÅ/ú®´+†R“XOª¥.RØ& X‰ëÉØJ[†…„\ DKÌ„æ*0¥x33t=q­À,)íJ­Zµæì™pÝ/^}$ƒ\½ªzÍÿ@¾3yíŒÈ{µÊ@7zÉ¡y»ÉIZW¬{Š\Jð žÈ wjÄ ˜¦aáÔž¸Q!а8'’KC[m,2uZ¬;³°ÖæÄòúµËÖ¬^[}E9.péä@ź‘R1e6Õˆ«VÙ‡Q´,×Ü13´‘L¹‚RsamOÄûfj;—šä³@7mE3‰PÂÆ Q^J㓵š¬?ÕR¤DÉD lEééÒàÊ;{Zšî¹±½=øÓ439L}UéäÄé /<¹8A]Fð‡ŸQü¡K8€aDsÈ”>Ý ‘¥z©K–]‰x¬OMRñMufV¬çB¦K vc–÷NEJ–K‘‘ ,5JXÅKÉN”½G˜ã¥*^,:ìe§0úª½x{Š¨Ý£jŸ(ù•Po<êÓC£¡a­ç’ÑžJÂ#  £ž£!$K›¥-À–›2¢r2èî5RFj4f{­¸ß0†j«ª:»*»†»B]›ª®ÜwîŠ Ë÷q ÷G“QCM%kU kxx¸Ò ¾JŒÃôæêê3ÏZ¯©ý ½wCiÙªÒe«ÖWiI‹­˜`-o’l¹¥ °­“Œ§Ðç”Rº1ç4I)¡}VØT¾[<¬fí×ðàëÐ7ì§«.ž¢e«÷Q9±¯¬š’¸Ï†›“‰æ{5LC ™9´À+¾ÝâÛ÷Ç‘³=Ž+Z†§ `'¯ë)ß$ò¥ÆÎ¸Ÿå)Þ4˧¯l~ÓWf!8x”Í&écÌé¸K¼†“8' w ¢NpYê® 1~ÆYa`‚ÍAÉʃlnÀñ +¢fö}ÂTFoƒÍè$~_˜`>DŸ×Z8Êæ¢óÓhö+ÆÉ…Ê¢4[|?[‚­èíNÖ\š-M³3&˜FÕÇYIñ ¥Y)þ-sÖ òá V†ËaÅ8[9Îüµ.2·<ÍÂÜ`±+Í*jÝÅî§Ø²Šbwš…19 T"ã1–Pª°¨H³U¸Ž§é#Ÿóð‰#c¬´-£íjT¥Vg´Â“ÖŠ³ãìqfþ‡ϸÀo­Õâ ƒ3-MjI¬´é¸<ðZT‹‘†8¢A ÕΚĴùßhñ¿>Æ…t^„ë0cMålÑÖLögÆ ÄEÔ¢ÓÓ윙ñmó3*¡‚¤"7É·1d(°0ê0ÞÈܳÆÐR›ÿdŠ\×*µä2ì­ËH9(9qým'ž³ÙÍBbàŸwc¯cê0\7âß&ü;7fu¬>g µÎbgš5fK'°n´E6M.Î8Ûü¨T[ÂÅÎq¶UÄÔóŠ]ã¬ÙŒ$Nt…Öù‡O¼|„ÍcEµž#Ì]ìy´–Ó|ËÜ6Èô•å±VlP?UO³6eÛ¤»qo¦pÜž½2 !EäŒv³?›úYnÖÁöã¿©[˜Ñ[¨éé&œsá÷zÚŽÊŽq¶³% \(6Ö®ðvõ8{Oë ‡+ÆÙntBçë cÔíg{Û&ؾphœ]”fÚcXà•nÜ@‡iõ`\ޱY%bEË*¤ÑJ¯`|zÜp%‘Ñ}ÈkFÖBó~Só(Nq /(—PW°émº˜MTâ6pÈ^: LØÀ¤ 4¦HL‘D!+¨ì·q‡mÜ‘)¸£Y¸lÜËlÜ˧à^!p•+E2Bû¯B4€!vµ9L÷ ϼÏ^#†íáµbx=|¿~À^/†´‡7ØB>d ù°-þ#ñ£öðcbøq{ø 1ü¤=ü”Þh?-†Ÿ±‡ŸBÄ!A;M9„IW@9ŒÓ´ïÎc®ZJ›RŸttûÜ” •è=ßÌ p´0\¸äaWØQxùΰӱ3ì*\¸3즑G¼°`g¸Ð]X‡­Ç‰ ÷`“W¨aë%¤Â|Ä*”ÝØnÁvg+ŸÇ¶P Ì¡ …æ¶a[Dcç ¶ó‰íb[\ØíÂÂ&lÖbÇΖ v¥•›[ɳò·´”[étÑ\ãÌlåÛpËúз[ûUxÊϾ€Î )wLÅÿâôø_øcSñäÄkr§ÀÿòTü¯LÏÿ®Ì‰#Ñÿ­XÉúY\7~Ÿô<Âî;”¯v„Ô¸”{:ÂnåÞŽ\·bh·V(÷¥Ùým:¡‹ÊAŸ³:ä£2åèA'øœÁã·3¯Ï:~Û‰—ʃÁã¡ãi–ôãDïš"¢¥•;†Ü0 ¯Éð52ÀEÙð!:š}®ê¬³n"ˆcsîèAø\$êé€ò°%Ê6OÉÄ[Æ›“ŽðŒ-Ê#­Aå¸òhš=†«ú8iqT@Ÿ0·ïוo ü'ö”òtøMø-å™ ðÛàwLàw•;2À;&Ö¾ü^ôûèLÒg•f€?ÊŸ3?V~’þôdàϲ€?Ïa™üM=úYІ;=Äê+žbùäŒç±Ù¡§0¶0½?˜UØK#*¹_cSAߘ…Óbå·öúœ5ÉÛgñ^gñ®Z¼ä–ŒD5@Œ–PçdF½ÔXŒVѱTy!(4t9îR^´ºÎ»ÊïÒì%³àEºPlÕÖý¨%¢.eQëÛŽ­O3÷;­ø=FôÒì‡hâÌ åOv¿²‚J 4~i&._¶ Ÿ¬ó‚¢J¸§âÞì3¢äE°Ø’V.^ü^ÀlòçVAÂ\p/)ÒFM­Sù eÐçk\Ž7ÔrŸë0«£#…ôg¯Ô¸}îC¬Êš8ÆþZãñÑV­åŽš¼16»˜û¨ «è8˜¾<Ÿç¶¯M°WÊP±Óçò¹‹ù8ûÛÉ*rX’I>qÀ+‰òÚ1ö÷Ø«û?PK r6­8µjõl"org/apache/regexp/RETestCase.classW \Wÿ?vaÃÈ&Ä’v$Ú, „ÆÚ ½²¡ÍU’6–aÙdÙÙÌÎ6¡¶ZµµñÖÖ‹XÛÆ‹ªxDÃnmlÔª‰Öû¨÷­Õz[µÞ¶~ßÌì²À_ZøñÞ›ïý¿ã}ß÷¾÷qÿ£÷œ@¢IÅ)x¥Š*ªE¯ªÅ«ñ^½–‡×ñðzÞÀÃy¸…‡[¼‰ç7«x ÞÊìo“˜äù°ÄÛy¾M%IïP s;w(¸SÅJOËÖòNï»™ö‰÷2zJÁ]ï“x¿Šà6‰iæü |HâÃáåQ•ø˜Ä1‰f/H%î–ø¸Ä=Ìqœ‡OHÜ«à„Š ðIþþ”ħܧ¢Ÿáá³*ºñ9‰“ N)ø<“¾ âܯâb|QâK ¾¬à+*.cþ^|Uâk_—ø†Ä7%¾%ñ€Ä·%¾#ñ]‰ïI|ŸmùÄYÛ$~,ñ&ýTâg,ýç¿à­_2ñA‰_IüZâ!‰ß(ø­‚ß „ÒVR`åÖ½Æ5FWÚÈ$»v9v*“Üœ5íM5™üø°i ˆ>B;¡# ЄS²†ã˜v†V޵Ípcê°1²³Dƒu¹1+Ÿñ·k²†mfrˆ‚$†3ç¬ÚjÙÉ.#k$ÆÌ.ÛLš³]ý½»i­ó+QŒèIeRÎEcÑÅ-T&”ÁÁ»Û®"ËãÖˆIްó™ÝîBQ&k| ¸mNÊʸDrI-}‡Ô‘e‰}ýf.Ÿ&¦ptq§ïªÇžpÑWæH[œb :W|̰9¾þ Dz7±(ÍÈåLÛéÝŸ7Ò$ëŠèbabþ`]Cf_s(¹|"aæÈž¦…¼äN ×àZ p°X &Fü^Ã0¦!Ƀœ†öjØÇCš‡qd4X ·7Τ!‹ý þ¨áOø³†‡ñJÖ(/þJAjëÖ5ü hø;nÖð"\§áz6hyP6ip×ðüSÁ¿4üÿÑð_ü¢´ÇÈé„1)(#ºcéændtÓ¶-»CÎ;ú#—Yç¬×ð(£+1keïÁ„™õRf‰®ënô»õÞþ~•`;mk$Oî+ Ó£ ™†¶½B#‰}™/h­dÊgÊV™%Ez+‰hÕDŸ³¡ÂV °:ngSiÓÖ1Û< Ž‘öµç²’‘º‘4R™œÓ­¯¨Z§j"$”…¥}s¤['ôî¢íí;H§ªáÅx‰†pÀº²œ<çºîEkAf“Ú†b0'Eñ¥x¥ê<ùeð¥¶mLéÙpš‹̤‰jQ£ EHÒ,jeãg~¨ 0EÄQÊêÚ<ᘮ%}™lÞñðšPE«×x¨_hC¿iŒ˜öÚ°˜îCÉÏõŽ5.höâ]J˜r¢qü[æîÍK&ÅÏú-©=c9ú¸W,«x»¡uNšweŒ1Ë s`ÌÌT^¿õTx}É YY‚0ã\X#9Ë-¾zÂÊg(—5Ñ $Õ£=¶E¾ó^GÝÕ½ÇLÃËq /s‘¡ÌÓ(–REÏäÓiMDÄ2²Óã'¯¦räCo䲜ÞÍÙkÎ×%Z¶ˆL­ã'ªàüUÕÚFÑ_ì]‹9sNÁÛ1¼—Ñyãðߣ8un©œ +ÇiÛàìJXÙ Xe½öDoê õñãWcd³f†âØTåï?Z¢}§Ù•ŽåQ(ÌÑ…8B„r™*~ÉXØl1‡óÉR]Û´ˆOãe!Š/jBàq‚¸©ê&mcœ„«9Óñ¿ôྤ„vû‰Q#•è|o+³U¼!»Çlë€1Ì«IÓÙFï­‘¤†,¡©N‰}»éB¥Ú¿^1·#ŽÅ—ß-2Ü£´ Å)¸i3“tÆÜž†Z%:÷¢.IפœÝLò£C›yg¥/Ÿ FE­òìžÝòªˆK­'Qî•ò“S–¾ÙÖ€áÞÏô;¦€LåôYïD} Î¥6z€Š·´Šp·áÎÔk¸ó>Nû35îlù3õîL ÍUÜ+¸½Jh¾¸Ð5¿ÃsÊ¢:Ý£xž ÂúÑEÔ–IÈȹS¨Žl`àÓ\`KçMâ´I wOŸÄ­.Ëù¾O.`IE<£€‡>ên>ÓßìðÔl ysOVâ.òqÇ%>öÒ"6¯„mña½»Ì×÷¬".÷1Sسu¾ûúfƒtz??{Q?%—®ÀƒxˆÜL³Xê»™F?Ën§,ãPÜ ¥Ý‰óc³ ¬±;ŸÃîÜÊ¢·UÄ`{9iÂÓ²c¾U;*à;ËVM¡m>ðŠ `H)×ÖÊ7â>J ¶µàzt—Ƕª€Ý|¹¼`»;Wò­=QÞ»ê0ªCÓ¡ž)äÜí=œ)Ìò\_} ”ó%2ÈÜ-´šÄÒÒö)ÔLaC¬ÒìçùbÈ\cVÔó]7 Ñâqä±Cáiÿ†S퟇*ý“Œjð/Ù_H’W¥òj7•›æ¤²žB84½ )ú¼¤X;'({¶eOç‚ì霽¥qúÕÝ9í¦à®Ë? šæm'¡u6‡=¯5‡O¢§9L2†ãWJÈø0ùØ¢®ú—<•"ËŠ£®”jþ,„Eè+0LÃÆ ù!ZUè5蟆Av”"£äù÷ìúih¡ ¨·ßÑE¬wÜfåÆZßQýT,nQ›¹ƒy]DîQ/Ã8}U¢m\O\MòºTÍ5îÑø‰PK r6ˆÐ²æ-¬/org/apache/regexp/ReaderCharacterIterator.classmSÛRÛV]Ç’- åf" ¡4­­@ !¡i’’€¡­SŒÛ’IûaŒ3É#É ¿Ò™¼´Í /<„™bÏ„NóžÈ7äú\º·,h‹mÏѾ¬µ¯zû÷ë?¡`?èE¶IÌi˜×Iw…>®ëtÜ`Ý¢ŽÏqSÃné¸;:úð%›—Ør—}îñ±¬c9~[e뚆¯4|­á„'í²ôÖŸÚÏìlÕÍ>5·ÔíÆÎŽÀŶ¥f;•ìfàUÊ éCD©æú², ~$áNÕ©KÃéó\™-b˹e)Ðë7¶ýE`4Ïg:؉7™î®O”vmo9 2rÈ Ä«þšSn‹”ÊÅ´¥¼€¾¶W’õ ê:¾€Æ¦åZM@Is6 éø O¶· L`ÆÀEŒQRÝ«e—Ï \‚i`)ƒ¦Db÷5|k` QݧUç‹g¡2çùòNYîAqgÅm8eÿÌWúîs¨ W9¥)LøW ñ†ï ¤ñÀÀ&ò[†è]¯’µëviWf=Y‘{õ¨é9j•] ¤—§¿¸<ãS)n?•%jät'¼ °'p7£™¤»Nfà¼î´¡êá®ç>··kÔo½"ƒ‚ô}»"yÎ\átjÒ©»á°h’ýÿ_'š{ú§v½.y&HÑm—¢MÅ<­ý(>¤o`ˆç ÐMä;Æó¤»‡ì˜¤ó2I¨dRV ºz„˜u åñ` -¨Gˆ[ʇàŸàñG°  Ò=i· Y¿#ÞD9ÞDï«cô=žmÂháÂrç † GÓÁ<(QÜþS|¼*0|æ¿ðzÚpZžà¦eFñ ‰Ä2ó'Â?PK r6?s2Т/org/apache/regexp/StreamCharacterIterator.classmSKSÓPþnQyûHÑ6€ßO*j¬Š#ƒ+C{)ujÒIRåø Ü9ãJaÃBf¤ÑÝû#\û\‹ç´ÚdrOÎãûιçÜûãÏ—oP0†Ç:úlC/Æ5Lèd;ÃÊY^Îé´œgÛqIÃe Wt\Å5í¸ÎîIöÜà˜›¼Lé˜FŠÿn±wFÃm w4܈|Þ¹çöK;Yp“i§TOÚ/® ¨Ëå•CuwÑvòIòœü4Ù¥GÑlÑõeN@<%åZÁ)“ˆ7%L£¥‚V3VAÛ§û_Ѿ4VQžïÎtA †B‚ "P¼ûÿá+8ðižá£»áôÖát4Bx2„›–æ'pÇF#x?½uðIœ Á·Bðx=o§ù-ÊÆ[>@Sס* ŒûhC5ÆIZ™1E’Ûq‘ðÑ·ÌfN®c´H]×cïÐnQ7£ëèá ±7t/¾V¶ûßmÿ4ûsµþZô©”B'2º!õIÞH÷:qt*¿ªèY¬eÙþ½Ù£k¸¿<×ázEê¦ní=ý[¦ú,TsÌ·—PK r6½ñ68UO/org/apache/regexp/StringCharacterIterator.classuËNÂ@†ÿ¡…B­ (x¯¸(Ó¸Ö˜⢉‰ î†2)%¤i5¾Ž+7.4QL\ø>”ñ TLçdþÌå›ÿœ9Ÿ_ïÐp€=Y”s0°bbkJÖ•T”T lØ4°Å EÒc(žwù-wz<ôËX¡Ä9 >a(ÙÓ×õ+½Ùo †\tÓŠF§ eÛuë³ÌJöìóŒ×áò4&3š é : Ûãíµ ÛLÌر°ˆ¼’‚…"–,ì¢ÆPïKßáîu„#…/î‰w“|¹ éÒäq_2äó_´ºÂ£¬µéç3j¶únþoùT}O„~Ü.©ßYPChUÕÒ´¶0Oº@»2R€Ùxkì¿"õ 5˜úÛ„Ñ(ó‚T¥:„ö4a SJ|r#fý¡Æüƒ¤d™®ÆÈF‚*Š"sC€®Q|PK r6ß»œÃÏÚ!org/apache/regexp/recompile.classuUKsEþF¯­üHd°qb,)rL0A~q 1ÇØq ˜@Æòx½FÚÝZ­¥(n9s‡TùäsrpRI•¸ó;ø =«‡åXìaf§ûëþ¾én­þyñ¬( ðtŒ¡ á}’(b‚㢎I| Óá’†upÔ2Åñ‘Ú/s|ÌQâ˜æ˜QÐY<§ã|Êñ™Ž+˜ç¸ªcŸs|Áqc‘ãKޝ8–4|ͱÌq]Ç .kø†cUÃÇ ën2$flÇæ¢Ùcóî–¤­*l‡a8»±´+îŠbE8Vq-ðmÇšÎÝ4EŽ!ãúVQx¢¼#‹¾´dÝ+®.Ì»UÏ®H_÷¾Ã-†ìzMX²dú²Üô™3žé;Ž¨Ê¹ÎiNÃ÷6ðƒÛø‘È_e¾²·½-}?ჱèԯخS3 °ÉÓMzŠEsÅ—…ÙñZ{ᛤϗµáÍ1†È˜Î à¦çÛwE ÍZ »lnÛŽ¨˜åáoÜ6’欦ýÅ@YiÛ‚Ô°mÀÂyC—z4Øvñ3›ÐP1P02Q§eœòh!ò×i†óúÿ²®.¬ø®å‹* ±#ïÙ²”)Gñçz•}í¾ˆúB½,=UjNÓbJßw}Óvº¯?BÝ)‘d—áÔQ•»¢‡×ÂËr@õ“ms‰TõwÁUf†EGuÔ‡T tæ¤ÂNó)à(ÅõÍ]â8fZ»_ d•º{äH5ÇÏv‹+4ÍÕé¶êãfª±§NÒŸÊöš[škY·)m,»¨N áyÒÙbï?ajαóÀmZNgO╢έ/ö¤èÕÊV»§{Ö±ã¦VX2èþ¨kå6æirŽˆTo,I]ê Ük²ÞV¢û÷’=ðªjT‘Žì„߇ÅcãrcÇwï‰ÍŠÄY¼G6õDÀÔ·Ö<ig´ÇóOÀ…€$.`¼éf#†>Ú>GäÖD—ò¿ çqïwô?Fl(~ˆDô)´èìóó™Éå|&vg²{NødáúP-‡0Jq hÙ‡^#[:¦¼¯«¥_ãêm  >Äàå*%´)-8Ä©N% RÉ”æý>Åš€ižJ^zŠTI?@ºM0¬2ê-æðí mÿå¿]Þl#†ÒÎI–J¦ycÿåŸ*û[t»®ˆ3„ o”éÈ}»š8€»Ü…}—T…1›ag» WK±.ì¹V1º#ÇÊ5Ú"ΫnþPK èŒr6¼]{l],META-INF/LICENSEÝZ[sÛÆ~÷¯Ør¦Si¦4i牱䆭CiD¹n&“‡%° ·°È. Šýõ=—½¤dwúVM¦5IìÙ³çòŸù[ô²Ü)ñ^—ªsêÅ3OþCY§M'¾ž¿.Äßd7J{_¿~ýÍ“‹vÃпyõj¿ßÏ%m37vûªá­Ü«¸ðþúî§µX¬®ÄÛ›ÕÕò~y³Z‹w7wâÃúºw×·w7WÞâ×=uµ\ßß-ø€ß€¯æâJÕºÓ(çæ/¼63¢™p;Ù4¢U²œtP¶uBv•(MWñ*Q+F§ aUoM5–øuáE᳕vƒÕ›¿Ò‰ ·T•ØÄZ•,ä+o͸݉჆çL9¶ªŽõ2öD±Òô«·»A˜}§¬•`¡BŽÃÎXýoÚÏË9·bØÉAÀ¦[+aa·¥‡¼2ÔV6âšDŸ(1vx@Ò^ Y’” ˜žõb <àÔÊñÖ`ÐÁš¦Òªð¡!¥ < ~;v,+MÛšÎKòнv,‡7œ‹wÆ’ýh{“¬|4óRft'.ô%/5{e pŸ/¡ºãb0¢”àt|ÎKáŸÈV´²“[…ÎÃ}ÝXî¼b…Øï¼OûJ’[f¯1š@Ê…MÈ=n§{”Të¬Ù+[¢è‹o_ÿþ’¶3`6|4n«£ÀMV¹ DnTF(5¸r"=Ó3¹üg3ÎĬÅÙÙeîuømò «eY‘LJ A[íPлÕÎQÀSœq[NBm »•‚^íq¤õVÕÊZXN¿ÖdñO¸Ek* G“”UÁÁº+›‘LI(:3ˆF·w?:S{ /G‚S*°~È=äÅðEÈÿZoGK¿ƒ[•ÁÇÍæ_ §ªËîÀß;Ɔò£¶¦…Ëì@ë Ã'e(ú¦ñk!›‡ÄÓzGÇ„´é5&”!åü1· pøzrà½à¤ŒÞåpÒR ‡>?öGc?€Â¾$ ‡0ÒR è.#&›Î«•ɃÔÜ4!ÿ3\*M1KéCIF\èf€‡#¼±¥àaMf•Àµ…,´õ".àêQ¶=ì Ú!Ìy!>¹è{;?B25f™¬p¥¬~+>(q³ãÀ=ÎÛÀŸÞKbÅ7Ò¡ó:JÅ ÷Àè‡èa¬Â­È]˜ û.w€³¨™V=hr%F1˜Æç‰P`acÃ'áÝœg“†UN9ˆ²¾„ÍLCIËôVw°Ë©ÏOñ8àT=IÿB›Ï[£ÙûŽÄûªaU+uÌOÕKK‘‚v¡c´ÊªæyÐ}"Ãm Z0N:ÙªËàt @dkYR‘(²z¢ZG™:yý-B¹¯ñg=~œ1e³ý¢}Â…Zõ@aŸP Wž‰I†mC«à÷§”/²¤õ lÝØvã°ÃƒGà]¤9©çS6"?¡ÁËTîž­9QAT¦í1Þ7 ŒYƒ)ž&/_VíÅ,žiæeq½° ‹T h €q^ØÈ†âhoq]Gäcì¼õfAnt• …v\J²¿+ž-E»ò=࿤ ¢npq”¤e%+R!wpƒj]áPsG…%¤¤éŸ`÷cåc¶¹Vnô"ƒ‘IdÖF»Ç-GGUžvl /=üHˆ—J“z F˜ž5Ä#ÅõºÍè y[i?!ôÙÄŽåRNo;Â~Eôöl$"XÍV`o)ò\ÏNSøˆ_Çc‡ ü,åÉ ˆøØm*v ÌFA<eT„ä t¾OJB§~!~ܶ4`o.×Hx³ôc úz.þŠ´ ·}˜•X\\}¬žmf²4ËQYA•™BèL,ŽxC8%0¼^ `™~}Mµ×È5:Ó½$Ï;81~| ¬Çn±q2Ù ‡—µUðI±{0%ùI5÷ýnº-X9ÖcŸ ]‚ó~ÜÀZ°"jßHôø èÌ¥ÖÑ7žXä}[Nó#Y>ÙñL9'laý1sЭDÐý?ðÎ,Sý€ -Ç((è¸!º=Ÿ5óÐu¶“ŠX^PˆúhS×Èó ¨à—ÿÅØqÀeÏ fÂÉÐ죰«ìûÛMÓÓÉʈ]^µ²‘ìÍÏf‡+’ܺ7;È^ç¤Õ”µô Ò¡öå‰á.¡ 6òàIdõ´ìxA8w¸¾Ú‚úLò¦Êù-öèŠPëæbY£ÿc/ä©0¦£S½eäVâÏr¾q¿H+rkkœ{IÃc”fDþÄŸÁóR4rïF=àQµå" Ê'Np„ŠÏÕVÜùV;É)“sáXÁ-1UÃTl‰2…fÔgJh4RŽù’XWLQô^ˆéa«àË|Ѻ ûÄŠ¡à›¹¸SùdhN[·òí…uà6é‘¶E}Q=î7À­Žˆ •SߨâßÉA%Õ‡ãNâ{*£aÏM¶'n•Æ> ûwêX !ht‡qÂݣ˶Gˆ‹!2±uß’1Ë™î\f;[5@‚7g-ÇŠ‰¹1z¤\eˆÐB•Ác¢99ãì Ÿä´TOV]"hEÿûÆ]=[ÝÜ/ß^Ï ù²7¦ß)w¶Ož]œÉ”Ë’¿2Q¡õ”àCYQ™‚N5+‚’Ä9o&ƃ!„ŽP|‰]31ç-|Ö®l £QÒa;•Oéý’”­@Œ`Ó7AMtL¶NšD•{V‡ïs0ŸYž×Ó”ÐuÂ,™ÛTOå[œZY®—M¹|opÆJõQ¦€mõyˆ¾ép> 3 %¡ ½ßq†øujæÌßD¸•ŽC>è!RóŠ eªŽÏ-B¬Ãd6ˆ¬*ü·Å~'ÈLJPÝ[èK2¡`ë;pD~&ê§p¼QUª«Æ6ÐÖIÄ`áþ/¸óÓÈÀaˆf8›L4­‚ž‰y€ã óÔ½ÅY¥®‚h+ ë™ ¾2W Ž\eÉid­–{†Á§ÑÞ™+#“Ý™úŒ6EJ›ššÅíH>‹©Dòpëlš—8¹­šTáȺq–LTãh2–‰ÊQ'0qÈ·Ôìø›îU tsñ¡ƒ*êÈiê6*5¶¿$1» ‰óÃ1‹Ì†YÙëÉÑUbú¸ãñ ‡©Þ&Ÿ>ÿ7­™§Y¤f0,‚©knyýÊ ¸(ÞÞP}ÙnÊ0m·ÔÞa!ÕÜåÀ©JñE¦A濳 ‚cK´…žŽÿà3„:2õ¨Ê â x£A¬ÚJË÷Jǽ‡¿ ø@a a1ãÑ•!ä˜rg7Bhx¡Æô%\cÈçf‘ÑàÔKÙœéû “a~8mÐ8DJjS­úmÔþö ºŸ`I'—Bá7-^O£6`eà%л"68©=™Ï†l ~óÕàL `Kýy.®´£Ö /mkñø'Øå“ ªº9pK7¶X ȋԼ¤)X‘æsß%U/PW·¨ùÓ8¾œ8÷çZù³ÅZ,×3ñÃb½\ã~\Þÿxóá^|\ÜÝ-V÷Ë뵸¹Ë¯åoÞ‰Åêgñ÷åê èŽæàGœŽºtM¸RecÒ”A4'•§Ðä’©¨!²§ Ƽ_Þ¿¿.Àê«—ËÕ»»åê¯×?]¯î ñÓõÝÛAËÅË÷ËûŸ)„Þ-ïW×k~}`áeÜ.îÀaÞ/îÄ퇻ۛõ5W[¾-lðfôïaSM·t3Ã]á4\ÀsÖôV#=§×]øÅ_BÜl^ÊÓFç€áq\kGÈîL©c›Ì îïYi›_´ž6³{™Ãç`R\ô^Ënèò|‰•WýéÒƒeÀW ;AGè´³QK¸É‚ò‘A§¶öUªË"Þv“Qnœü|6Þ/˜(àL¿Ñ"t¤ÜçñÞ"l9àŽnÇÏç£ç¤|àP&¸¬Ñ´±Ÿke+·Ó>®¯¤—\¯ðn=»}†„bËW H`x¦‹r^h@hœ¹Þ8®¶|gŽU<Öj¼5>ntÉšcĘ‘¿Ñwf†«ùÄàâÙ;ñ »1°[cª½nòÙá'(ʦï%N ‘Œ¨x-u3Z®F²©Ç.‘*‚gÞÁ[ Þܼ±r8‡HÐq^F¦ËêAÓ%ií_߀ ðF/7xñœßÍŢĚ€VÈ‹;/R¡Î’âã©û4]/ Ÿ½n ,´ÜÃSPštN.Ûiæ ¼­V„'u¤¡ìJŇèy êÑï@q§Ú_-I16ktfÓø)ñ–W;È|ùª΃ùâû+46?š=vBÜJFƒ‘=3Áé|ôFK×d·!‘sûkâú¯HŒ’¾ÄtÒ-JBô4)ÊÂÀÏ„±gÒ5ã3&<ç;Ù¦Ž¶©T í ¯f\KÛr­˜Òy´6Ý–ùÉ1`2t娬òµ8ožl¤Ðɦ‘Ìï³hÌhcÔ…øzu…uõÜkpôûâöYþó º¦€¨ÿúBþêþFªìã]üÝá‚¿F1&Zm k,´áC˜j©“¯µj*' @@²3èoð–RAdÎ~ùu&¾ÚB0ªú®/ë¤çââÊtˆï d9„ÿîRP·Nmªz‘?êể¬lgw³˜+îxþ/B©©g'`aãð‚ŠŸösÒ€âô,Ç D2Vn»ˆfö¡‡«ÕJ¯¬Ð iÐÄáÂ(GƒkÄàÖŠéͧùÕ„ÀÓñ>Þ[.Ü»ÆñLrH[îðÆšƒ!]&þr€¿_Å/¤7èytËú+=Êz¦iøù ¡âˆï\^~"B?‚@ÀåËÏ×oC cDEŠ#R×o64-““‘]d9„pÿÜ+§ï»¯Ö×/AeZò% ý)îáß9C1ÙHíô '¼4ÈxŠÿô;o2ÛZ©‰ !ȉÖ@ÌÀѺí”ÊBwüfŸŸ–$¾îNÏ5ñPK èŒr6vè´²Ã.META-INF/NOTICE}±nÃ0 Dw}Çf±÷n] t ümÑYDÊ®ÿ¾r‚2Aï®r_GNc¬žT&Û°xZ)J&Ãî®à#ãØäòkø”š<K‚·`–ßû~Û¶¶NÊÜŸ:ç¾ FIÊj 2Á*±&ò[+<Ô#@aAOíQÓ´7Ï+ûŠQ]K(`œŽk{‰ÑÁ9*ÁÊÊv˜]«w£V/ÈBgú#½á‹áÚB3}çLR`‘BŽS—g´ûPK r6 íAMETA-INF/þÊPK r6sGV^j¤+META-INF/MANIFEST.MFPK r6íA»org/PK r6 íAÝorg/apache/PK r6íAorg/apache/regexp/PK r6¸ ƒR7¤6org/apache/regexp/CharacterArrayCharacterIterator.classPK r62¯+óŸÓ)¤Ýorg/apache/regexp/CharacterIterator.classPK r6R—àsè'¤Ãorg/apache/regexp/RE.classPK r6û®YäG*¤ãorg/apache/regexp/RECompiler$RERange.classPK r6lˆá"¯™""¤org/apache/regexp/RECompiler.classPK r6¡Ö. i '¤þ*org/apache/regexp/REDebugCompiler.classPK r6ÑDVî: ¤¬0org/apache/regexp/REDemo$1.classPK r6¶là ¤Ø1org/apache/regexp/REDemo.classPK r6›¨Úe§!¤×9org/apache/regexp/REProgram.classPK r6!õð¢üs)¤½<org/apache/regexp/RESyntaxException.classPK r6üŠ4%3ö&¤>org/apache/regexp/RETest.classPK r6­8µjõl"¤oQorg/apache/regexp/RETestCase.classPK r6lK½¤¤Zorg/apache/regexp/REUtil.classPK r6ˆÐ²æ-¬/¤\org/apache/regexp/ReaderCharacterIterator.classPK r6?s2Т/¤`org/apache/regexp/StreamCharacterIterator.classPK r6½ñ68UO/¤‚corg/apache/regexp/StringCharacterIterator.classPK r6ß»œÃÏÚ!¤$eorg/apache/regexp/recompile.classPK èŒr6¼]{l],¤2iMETA-INF/LICENSEPK èŒr6vè´²Ã.¤ÌxMETA-INF/NOTICEPK2¼yjakarta-regexp-1.5/jakarta-regexp-1.5.jar100644 0 0 100404 10577337777 15405 0ustar 0 0 PK r6 META-INF/þÊPK r6sGV^jMETA-INF/MANIFEST.MFóMÌËLK-.Ñ K-*ÎÌϳR0Ô3àårÌCq,HLÎHUŠ%ÍôLy¹œ‹RKRSt*Aêõ ã ,u-Ì4” rRœós JKR‹t<ó’õ”4y¹x¹PK r6org/PK r6 org/apache/PK r6org/apache/regexp/PK r6¸ ƒR7org/apache/regexp/CharacterArrayCharacterIterator.class}R]OÓP~κ­¥TÄ9'¬C§ˆ”N?LJ°p±Ä„ äÆÒÒŽ¶3ÓÄ_â• ‰7^hâXâ½÷Gß³Õ¡0mrÞó>ïGßçüøùõ$Ì㙊4¦†p·…˜Â1#ÃT‘Ä”‚Y¡ç„˜WpG肊î*XPpOÆ}£XT)2ÉxÌ ¾ÍÛ-‘éU« ¬LÖ!w’KŽë„+ ²±[*—g¶â%¯Â†‚Æ^úŽ[cÈz~`½² ‡–[+luï‹ WŒÁ÷I{ßò×B*Fj›p‚ ·Òs_hÐñDCW5Œa\Cã “§eÊn…77áfuÝk¸•`£iózèx4oæl³õFµÊ}—»•nÞ²†§( ±Ä0ZÌü¨Á]›çç §à2VÄ« Ã{¼æ¸½$òŠù~ J<ÛGää4\Ãu†ϯ¬ºeïó‚Ïk¼Y/”è-;äþšï[¯û^™Žzþ_7÷¸M»™üO™ÓDɤ$­z‹ Îç÷}ž‚ÞVˆ}Aý¨z[Åiãh·zaiP˜ÞmJ0 &2»:ÛÕ ŠÓÎHN—G qÒi³ fζ3s-HæD ñÏËÐoéeK¤ræÄavØé ¹Ó†œRN0”;š&CÄÉ>ÖÆ…ïú;(zîÓâG¦ üÅ(1w0ºCé1:’þ2§WÚ¸ô©?J>%CƒÄH«¦Þë•ú¹›f,Âh§å?F¨IÜŠPYÂÔH·Ð{ÈñˆK=~PK r62¯+óŸÓ)org/apache/regexp/CharacterIterator.class;õo×>f]v.vnFÎâҤ⒢̼tF1 OOMŸ¬Ä²DýœÄ¼tý`°¸5#ƒ¨vq¶äŒÄ"ÇF gFÖÌb×¼7Š‘A9¿(]?± 19#U¿(5=µ¢@ߨ!1¹$µÈˆKò‹û'e¥&—°120201€ #й,@ˆfÓl ì`šƒ¤PK r6R—àsè'org/apache/regexp/RE.class­Y |[Õu?Wzú°ôlËv^c9Øq ŽäÄI0j’€¬(‰YRý‘Ä$$V$Ù(’*ÉÄ@Hi1tck·•5¦íÀ¦Òz+¬‰Mšº²Ai¡íRºulëç6:ºŽnëè-î9÷Ý'?Ë"°þæßïÞsÿçžsî¹çžûñ䯼õ¹§ÀëÙý68Ī,Ìf³S%§ÚƒÌ^…­‚µT9,¬ÎÂêm`'Á0k°²eª–gµV’V#UWU5QËIúÍÔZE­«í¬…µ\MUUk¨º†z¯¥ÖZªÚ©ZG•ËÂÜVÖaƒ5l=YÝ`@Ò7’Ì&‚›©uµºhë©j è¡ê=6¶…m¥jU7XÙvry‡•í¤î‰yU^ªº©òQµËÊüV¶ÛÊöXØ^t³õ$°²}D÷“ AjõXXÈ5>­Ô S+B­÷ZX/Ñ>ì§jÀÊP÷A öJâ¢Á-ìf ;laGÈ=Þ~ßÞc¡po7È€Tû2é|!š.ˆ¦FFÀ?Š*çóöù¡]þˆ«P?u2µjgÏ@°? „üÄ60p¨ì¾@hOЯñ%æpäêãh>âøUNw8Hè¨èWÑyCƒ„60°ª(¼›ðaU¤Ùë ùöã4 ô‡{zUØ×ïí%èRa$8ÐGЭZëñvsÏnT­ùû|ÞgQåÃ8Y‚í8QùÐF¿Ÿ[Ý®šñÃ}\kN\Ãz¹ lä¬×·¿×ÏÝoSíï ÷‡ îQBáþ½1â„ØÉT8Ô pë>Õz¯?8àë÷†úµ¹m)ãk“ÜÁ NÏ/Ͷš‚î ò½}\:‚ùyƒ¡¿S85ÿ±P äÝÝáÐ.‚ÇÕîîæÝ}¯W»K¸wï ì 𼉫Ý%ŒùPǽ9ÆÝQ½X‹ìõ’p´¬£;è í/ãùBý½<‰be|È2Þž^o„§ÐHYG0|P]¿TYG¤7 n€lyÇ@ÈÇ;ZË:x$Êx‘ˆj~”A½¾ãP)0ce=ûhÍyÏ­eÆöEDÇmê“ѱP&žÀ¤îñ:†=j;pÏg†‡ó‰B8ãý%0®6†c\¡4Šô%ïäÇ€­fs™‘\ô$ƒæ`&7ÒÍFc'¹ÄHb,ÛÙë¨Ý7à¶Í'¢¹Ø ×Tôˆæ¢±B"À-dr¨`;-ÄNìNEG(qÐûH4—H#?KÔ—MÈj!š+ld %ÒñÞ¤âMÞ¬âÍF+†Ã•‰m™3»£±Ûr‰a¹%`Ç9q™0Õð8¬ÓÐî@o_8d°\ã‰ìÇÀúü˜ÜæíÉt²€Û\iÞ½=Ú™Š¦G:û ¹dzä†upx·Í?Kd ITH¦9’ù¾Ì޲cÔú® ÏÃ~ß“áŸàŸ4]!Aq ËýêF£lˆáijØà’Ùq£*.³¼"³a6"×iŒ¿„¿’Ù j}…ª‡×dxž“á§ðš…%ev+»M†¯Rß‹T}ª¿†Ë2¼Žà ¿FÕ7¨ú&\Æ'Ê‚;"Czý-ZÒ¶$ˆ·­…&ú²ÌRì¤ ?‡ÿ‘Yš ¼D–ÿþK†oQëgØbxCff•™Þ°°¬ÌÞÇpryª Í+é\"–Iã-oIäcÑl¢e-ͯ4¶V†ÿ¦‘n'ùST±;dv'µî"õÚîh¼%›É'ÇZb©hWÎHßM%ã-~Aµ¬E!_&—ÍZJ×Ϻ¥k¢FÉ&‘áMø%ºÊ´` „–B¦%7šn•ái~§)oÂ/pp¾ÑB2ÕyóÕÙÝì .üDfï‡W4 ÝzËìö™1f”áßà'8é52û »—,¾%³qvƒe•Rh‘-5ÏQ’³’™Î¾D.‰a¸3z<…ÙÝVÉ@ßéBt¬tàASSšÁ¦Šçø;\Ù1ŒvJáCÓÍftæu¼«KAÍ{´ÓÔî»B¯9%Î[k!£vá¤Û+UÚ+ _1K–5ø ¦]Nçw%³ö$~ßäFcjÌ ‡qª¦aõº2%óü”oXP+‚i˜Ìt†s»’#I)µ–d^0ädþà‰d!‘GOŠ .”BaÕì‘Où>R¡ÑÐÞMýwdêxƒ(Éü>´ˆ'Ò…äp2‘wÔ²r~„³Íx¡'ñáh‹ÆãþTâd‚nÎE…v®Ò»$[½‰e²wÒ… …®Ò|€&šŽ'ÆÂÃowuÑ-[È3§9_4/ü÷A+‚AüмЇá¶o¡D8Šø˜!ŽêðqÄ1ŽÃJHÀp >¡ÃIÄ·êðmˆS:|qZ‡3ˆ³:ü>Ä9Î#.èð(âÛuøâ1¾ñ:|âÓ:|7â3:ü~Ä÷èðP‡ïE<®Ã÷!¾_‡?„ø7tø7? Ã¿…ø·uøÃˆ?¢Ã¿ƒøwuø÷T‡Düû:üˆÒá?Dü1>‹xB‡Füqþâ?ÒáIÄS:<øœ?‚øÑ²ñÿX‡ÿq±lüOêðcˆ?UfÿÓ:<ƒøOuøÏF‡Gü„ÿ9âÏ–Íç¼_@<«ÃsˆŸÔወ?§Ã—^—ß툿 ÃO!~zÑ~Y _\´_VÂ_,Ú/+áK:ü ÖøÊÀúzYÐ9ôôàôyNï¡·§_ôA_ôk‚~]ÐoŠN¿)èK‚~‹ÓFø›²}þ·eûüÛ‹ü^…m|”`ûï‘ÓFlX\nã°'¸Ãÿ@¿¡Ø?rÑïÑf¥ÏÓ:×%0 ÎÑ= ’sL•”¾‹5)µ¢2))®90»Ž 4Ò,X]ÎY¨RIü{B|±;¦ï åÀ0›‹}l 2Uðø¡yMHHç.ý”ƒÆE˜¢«w6š‹ãþ¨Á²ËýXÚ]'¨ Ëi,n7z£ ‡="è-‚ô.AO z7Qw}Í,Ô,‚Ãí82 ŽƒîfªÇ Ìéš…ºéù£šúÇŤñM,&T¢¨˜]M A Ê¿À+¢¿)Åä: 3¢ûG¥ v õ6—û,s? ËÝçA1LB‹¸$E¨R×F³ý¯ðjÛË4×~\qèåÚÐø:Ýq!øï‹MÔš]M³°bpÇÃЀŒ•N‚á*#<ÎTãuô:Ú}Âñ=Bû¦¦Oq—º†¼¯ K –kP¤i+'UÍT­zóh®¦fӆÌ৿ö-d¶•ªÕTµ- Цà?J¬ù¼\ PË'̃×ä—ѧ€?,öXXÈ„Cו9ÔF©ér^€¦":†ÔYÄØ"m.âV+›º3ü„èg¿þ@-b V1Ðju E!Ð’è[Dœkqc—`Í Øõ×à6ÀT¯ÅlŸƒkŸæJÚù±Å_/í÷E¯sá–ÏÛ.ÀªR«Í¸½Ëø aî€!<ÎÍÈ2=ÿªæ ~w©Æª:Á„A€ª¶fDé|Ön«jòØŠUæÆ*ÅÖå1+6j˜†ºò˜¨) uy,Š™ÇúŒnjÇŒ•§öòo@z ˇøÒ€Ÿ¬zÙJe‰ îvYÐS*ÏÔ$ú>+èÅÙ·µ-úL¼³Z±¼„óKªmãŠw¯÷ÿZN¸›y¨¾]‘faÝ Çj˜´ *Ö—bÒóÀŒ<…Vˤ.œ­hñT’áÖç’‘’†^Òüs’äÉá’ΜÛnÅ¢Hár“×*Ú;Ó`w)iè,GŠÛ0Å9$Ù±ÔÖúÿ‹­F­ ª-ôeƒÇ®Úà‘;jW)2 š 3Š]‘§À\4oV°'CV‘”ê!)~:éÙ†RtK;©’ÑScôÔa½K•—ØEØhŽìJíGJÍlâÊãµL©Uª§ç/M/(ÒYÓsdÎtÆ4…E’âs°ù,º`ú h¥‘;ašRÍ ôÑ’R-*i*§qõ‚fiÃaéÆIJ Ë'ù‘­Òƒ‚ýqó‚ž"ªH`uØðÂUG§(àlxü4gΪ5‹ú1xOÂuŠŒÕ”“bq×ÚSÒeur%¦Ìí«ÓÀýfáûQá{Aø¾Uø|Tø\>oåCO€M±;Žé?¥µ'a-ô“Ð…Üø·Iå^Üü—VLbE©Õ¥½"òã<––—Ȩ±Œ`Áó?bÁ@ktÒF¤)Ô§ë>‹t¯XzÎ"îkD»1ÄÓ­9-{lQ< Û&ØCe¬® voë† –-c]?Án)cmwÔN²½åL~1áœ|wbY¥/E¶¢\Á4Ɍ墕"L.Rulœ^È+Â[ŸGËú‡Åת{§a…ï~DK"ôh‚vÄ"GwLè—³vN€Yõ7bºSâ²Ú+m`¹¡Ys(ÚàuJíôü—¨-6ÜEWR—ã4éã6c2K.@~‘ioœ¼M‘ñÂSä³PÍŸ0¨;ÿ¢a¦¹ .£zwH3¥à&:̋ńFlÎé×ßpÕ{‹§©D?ÛŠ—Øiñ”Ϻ øì¤ª…*'U­T5SµÚÅ艆U›K¢k̈oÝݸ¢ô|s—Zë]Æúö&šâœ¡ÝeÄOµ è± µŠ7á“«„'58¥îA÷øP~ׂÜ/U9ÖŠrx…0z§.{?qêý85úZ)â7ÐÍê]4~ç^Ghk·¶î3.§¸›èñË;$ÓŸnn§šBó?Öƒçââßó=™BÛ$Íp)íTœÕXv*îjÛõ8=&£Çìr+¦q“8%ÅYËY°+æFé©éù—8‚ê²!‘Y:ŒçÓ…õ­ ßÞ³°W˜g Àç³é™KÀLÚ×c܉ø::±Å…*+<&"øŒ67OÁòw³b’†faÿ,Ñi¼d9Ke(æÍŠtoú Þ;1ÿ4Ñžm¦F¨; UÔvÌBè ÞfîhÄœ4šÅ7(þ„_ËD>X]îÿ½ F‘ W¡ç2Ò±¶aÐLÜw\ĢO€{V{°Ù„ËñÆÕñ–ÇÚAbUEHPø<‹ÏBµãÈ$D試Tƒ=ÄÅyVÓ&¢³Îƒdë#ÐÙ(á Ð4D×-7ì¢nTïÝfo´? öF©ÑN|Åⱎ[XG}‰öz,ŸPS®ÊE°!‹›áQÆUW0}ͨˆú¦fÊ!œÎ2|ášÏáò»)Ò×6•Q˧‰& Ò Lb&Éý˜&úêZXaüÜs7ož…m’‹´ð•‘hE¬Ù ÷Cm‰$Î4Jªaý'KÞ)~ÚL‡lÏäN‡mV9Õ“°ÒY÷MB³®¥}lHÖiO˜aˬÂÖ*ñóN}3zMOÂÁíN¬v49ãª,ü PK r6û®YäG*org/apache/regexp/RECompiler$RERange.class}T[OÓ`~>Únlt0³- 8ŠlxŒ ‰Yˆ.!YÆD¼¡n Ù)Û Ìknü Ä«‰ —f‰C£Æàðç¨ïÛ–±C—¾§ïyOÏ—îçï¯? a‚áz*n°ˆ³¸Éb–Å­ ‰‹¹ L̳u›Å‚)?î Èâ[@dËÅʦUÙ%wà•ã[‡ž/Uö˾f¡Øˆ/ LmTë»)«få vªnïÚ‡µÔæzºZ®Kv}U °Õª4 v³˜£¬µb¥Ø|,0“¸¸ÓkmŒ¹Cë'Tç¾ØÿIo±7´,»eÅAFdí=T3ÂwF«ê…]]Þ‰(¼y¯Ã¤kQ‡c"Ûq+y§JïT1¨X¶µíóEè{ô‰ÑßLzÜ8¦~ͧ4<Á ôŒ‡'¬DzÐÔ1ä"î ’V‘Ä"ðPK r6lˆá"¯™""org/apache/regexp/RECompiler.class¥8 x×qón÷îöN+±, î.œ 1Ò ýàÀÙÆHd¹V-!Œ"c! ·Ò-ÒáÓÝõî„%ƒ©‹'MÒ¤!?-Ä6¸=7¨­M@Ð@ìô/mÒ$MÓŸ´©“ºI›þ¥nú“ô+3oßžö$Aœ¯Ò·ï½™7ofÞüí}áÍO¿4±xÆàŤáWhød.ÀLW¿ê‡_Sà×ƒàƒ—ü𲃀—ˆèS4\¢árfá ‘_ B ü†Ÿ&àš®a%¼HÃghx%¯ÂgiËoúá·øm~‡ ßUàsôþ÷ø}>¯À$X6÷& 7ˆã(ðEzÿ%¾¬ÀÒ›9¾BÿqøjöÃûáOˆüOéô?Sàk ü¹!ÌÍùáëAˆÃ_Òð½ÿ†ß$à¯x]¿àò[4|›^þ ­þVïÐAß#ÌßÑð÷ üƒÿ¨À?Ñ™ßUàŸ û ÿ¢À÷øWZþ ÿNÃÐð}~ À’°ÿ¥À+ð?~øß < ÿç‡$ø‹ ¼I‚Ï!À@aLa…I “æU˜Oa~…) (,¨°*…© «ö³?[ÆÀ¿·s¯™±¨]™Œ•ïH›…‚U`P•ÊŠùñáb*›aàì`P“¶2]n,ëB9³X´ò…º˜GÍ–4²ké+æS™‘{H¸ÇTr‚/gæ­ ñÞÝ{oç¡Ý½{{vv3¨îÈ"S3S|ÈL[hoDÚ$ýÝÝ;wuw’9Èwõîéî|¨³›T¸³¯ãPÏξ/-wíìx`oç}êèíAê‡8Ô½³¯6”7‡µŠý™¡ìx&i%¥9ücøžTfèÍq÷¨YÝÓÛ×…œt[Ïñb*Ýr?¢‹æPÚBU}ÛS™T±µ­oxˆÜ‘M¢Y}¨ñxr}G[c©"A3H„6µòˆóÕwtqµ`w[ÅÞÙ$o½–3œ£ÉÐòÕ© ÞLwæóÙ<òꜶrt3dâÂd¦hNˆWzýâ»!Ž~¡#‰Y6sy× šøª(Ï6‹Ù146bÆRx&‰1ÈÅð§³¶†>ä–%'ryz“Ë¥ÒøfóRçwgó#-fεZòÖîiÙÛ¹'ŸÉ›chNeûpšT…÷ÁûUÈÁO©‡‚Ÿi*[ÎB*ü|Áú¥¸ôÙÊ;ö`°–ÖÞt¬0šÍcGÆÇr±<9~3±?Ã`Ù¼€Âh˺„}c!êTx *¥¡ã~¶Be+™®Â/ xl[fëœÈYhµd,™IU8M¬W-Ô}×øáÃV^ekX­ÊÖ²°ŸETeoSá@[¯›§ß=>6dåïËæÇÌ¢K½|ÎQ3JÆ2œ w–ñhú13–ÍÇò©‘ÑbLܳ ï¡j*ÉT¶Ž,Øe&m›0XÑ“*PÒ]®Å·#vM'w’˜p‚¢Uˆ¸B*‹±:Š1‡/év ë„c£Ö„™´†SchKn˜BÌ<ŒLbðmçX®8I’ŽgÊ|Q0r;•m`oWá½ð³*»mD±æ-Óá8¨ÊêYƒ ƒ£þ]Û Šóp¦˜§TÈgä™ÃüçMg£pôæ08ŸÏ Ó\Èñ8òŽçrôÞ7!6H¬TZçø2r+Ä«œ†Þ¡#àBõMŠ¦ì€™Ï›“ÃÙÜ$Çí=÷t-âåF[˜¶P`rÑE»˜aGàOîµ5 z†Ý‡ÏDÍÈÂ/ÊùvÞ£Ü^Ì:,WÖ/¦CŠåó8JÃ#¤¯‚V)`µ,Þ¤ a1 `åì¶2#E¼…ªb¶›î¡Ã,X¶€(ñ¦%+ÑM £ž7(Œ„«¨H/ÙP}½} Ë7,F!O21ï„x-F‘ëê—¬”ŽØ…<•Nó~åØO(lø,¡£í0ɈFÏ3ØE°9!`_Z ·ò®DÂbp×"¿%% {Ö1ìΖãƒe›::ªÜ|ÆÊÉç£~LÌ|^“83xœz;8†ðqüÂ'\ðO#ü¤ î@øg\°ðI¼á§\ð„ŸvÁïÆñ!Ï{„±!Ê_‚Š&é(‚Ãý|’‘SöÊ›ú9o_Â¥&mÁx?½8uØ›ØÒ^‚µáÈ(ĸ-Ml/¿‰ž†ª0¡§ç^çó9¸=NÆeÿ?rª¯o ä¿Ê«b¢O•µÁ_¶¨·¨£ ·a¿³*‹O@¥„ñ%gKlÜÐŽÄr2¤ ^ƒÀ@(xª^忈Œo8c/'¨u¤&ûHâF¸‚؇ó'Öì „QZöU<[ŧú¬Å©†„Rù•©³°L;vüÆ,hóT+9Õ%þú*,?#š…×`åÀü AK7.f4 «öÝœÇÜWŒÆYX}Ö\†Ú{ŒPY:¦éŒˆp¶iOL!Lgð#ÈË£/ßZ—Mg‰ÏÛ~LÆžJÆ7S¿Qš…uÿ?ÝY›ÄÓ* }–Nˆ¹„^Z¹'¸ruH÷2Þð3e…µì$;Å>kxv„¶x>0Šç3npݹL¡X=E¼o›vñr»ˆ r·l’»šç­{ýGÐ}ü {/û>Ûæy±m¡õ3¡ 3am| üþÈÞ6 óÔ㮫 $¤µNÃjœî>ZÔ?¡Ë ­5‰t÷ëòUx;§0§a-N‡Ïà N¡™É„L ÑzC„eèöY؈ž^jÀúÖ*ô¹Ù G/»WUd@N¶=77Ñ3ZpF«žÑÔ™[Å@Xk‚£8&ÛæÉ’•d§¡/â›XÂu[“ ׮慻¢7ß™ 3á™EiîyÇÁåtoçõn\äàûÅp¿o¬ˆ½×ÜŒ¶MÁ+-¸½ÕKÙ´â|¼¯ŠŒóø s_vË’_pÆP9ØB¬=„ Û$›z.BÓ¦Yhþ,´ìnúæ‘ù Õö4ÍBë,lž);ÂxÿH½1ô„„¶Ð¨ bÛ¼=´µ-Ò.ǽRÜGÄýR\¹ñì*îÜ,yF]Ò] _À~€¾&\SY<€O>ñ¹M÷ž¿ŒÞ-Å©&ªº ÔÚ ÚŠMÂ]ó¦*y4¼’»âU”JX?ýLJ?ˆ"ÇRØZ#´ åÔ}§éZ¶¹Ò6OB\–58Ü‹ÏsøôáƒAûð9ŒOiªq¦.ê2ïóÞ@q4¿îEyjƒZ-îÁE¶ÎÁÕ…¶òe .m‹ƒß¦½ÓYjeÂáp¬¼íDå¶2þ0B‡¼ÚY¨Î"è,gã‹4áÚÔw8îÔö;ËCi«v7ÇE0\Ò«NÅñãmGãÉq_["¿„—+n|÷ÒÁ m%&«G#¦!d¼Q—ã]ÑÓÎÕ b C•À˜‰Šh:Kn=I¯Ëí7!{dêÆSÎ+m “˜','jƒ— ýT¿¯*AÌ h‡^Õ|jÞÉxºŠéUœvzîµ%ÒÈY'°Úu’4´47 ü ˜Âø$>ø ˜ ºã—à`ä ì7B»ðJð ÒNjRa uœuLA•¥‡-¨"7»‡• b,Õ(Ñ»rsöæ9dí$jºV쟗¸¥)˜·4`O°žJ“°­HU#šëa™Ia™ Ë<+,sQX械̤°ÌEa™ Ë\–ùea™Ia™‹Â2ç–ÐOâ‰xî¡–¯sÆÝGÞK †~‚çáûù¸KTœ62¤ÝYá'Í|BŒˆç®Fé@³öæ‰^C;P‘ ù9nVËSä“]Ñó4?ÉÖÍò“¸u}”“GPF‡_™ï,<°Øàçƒ{¾‹A_Óž×¹´òõà€$õî6°ætÇebÒ$5ãånÛ§Ë32¯åǧû.»ü \~»#tEÀëò–¸_÷kÏB§ >¬€ºìA7EæØŒï‰Äå(Þ¿7â*wâñ³•å¯ajîí¨º¶SÙ Š¨ˆ.ó…rn| á Î/xÚ<<P€6{OœI÷õS2xûhKS.dvë‰Á²ÉÁx¢=]ëmãä³[Îí\°ÔÉm®8Õê èâ¹°‹x޹q¢—úB̆}Ø b݇[Û¨îã´…úÇe†v\"ă”<æyê>zÌâDÍÙ¸ÊëŠJKÎ]‰<½7É Y D9ã]˜3"2áµòˆÍqüH[chí’X£RöÅõ£våÑobK'ýX1£kÅNÞŽèÏVö§à z’°~Y1’Óµ´VäÕK >À‡+óIÕøéô‘°iåboirR+JN(ø—yøXÁ'øTÁgèWð9¾PЇ~Ús«'_˜Hé)O·GBÝ>‚'pDBC«'§Ó‰*¸‚«TÂ\>§±}‰ŠÚêQáxi/}OVÐv²è _⪂¯ðµ„ «”@Æ7 æ0Ï÷­‚(|‡pÍùîwION9Ž…’ÁX2‘ *¸†ïWðxt(A%4£àp/‰Úˆ…c‡ £WVIÍƆé}†z˜ž›½ƒ±P¿Qà`R0,NmXF2ªæ°“S“ý‘XŸáѧ&Uª-Y!5–ŒÄ†Â†r8 ÆÃ†Ç •PTMTUzƒ¡#ƒaÚÇΣ&"ÇCÑ`‚²­«FóP"4ž¿¹ŒšóÅt UHOi" s…À`ø6VJ‡òÓ…L–DÓj>ËË:ÛtBëÓš.a·×tÌÕ±3Ú¸ÞÙr/¢J¦ -7!¡Õ{ocÜÛ+Æñ¤8÷j´´*ô¥–Ûè]µã䳩lIS'©Ö™ÜŒ^,ë™|ŽÎñ5”µÀgŽÛu•=Ñ3Ê•õ,¹¯Íj¹ˆ9^ŠÜÝqçgtZº>_Ò—îœÚ¡&E-5M›ÙºÜðjI/”j+œË:™-ÍL‘B:V©ëÿª4ݬéÒ¨8|k%“M—‡é×zš©aõ-@º ãC^]Þ ýÜ·P·ˆúa÷,eXÿ„m õ/Øœò@ëjPd)h?êèØåvxæÑàv\¼†Í‹à hpÚËht—¡”±æ†û7¬­…Ó%R ï Œš[}¿`»­»2YFÛzª¾¦2¤â\OöªTECâ»ÁP‘î'šõÝ×%™5šÚz*Iµ[*–u´ír»Õ_Õ%YÅé$MN°l¤ÄËp¹¬W ø›È¼ŽF“Ë:ZÆæÙºúmŽ‘9äüÎ-´Rßn»Ž¡ŠòlÔÖ./›Â%»Ä~ŸK.ckEÆ[K\cÎû8»K¿ŒÌ³6ÉesYæïüäwRÝ\ÛÁ9ì÷;›xWθÑï[Jdh»lÖ‰vÛ•;ÿøT —ßy4‘—gþö¿7—jU;ÍTq~a®E4ßÂöìˆúüeì¤ï.Ã] Vs—~­¼H?.b7íÏϨ«G§·Œ–c5ÒÍÄg&&~3 3i5“SLöšÉN&ûÌd“€™Œ0yÐL.0Ùo&A&™‰ÉÃfâgÒf&˜¿·Ÿ_ðp‰£>Â{ˆŒLÃk¥•¹!xq’ü´Ê™0î”Ϋ.-«Vé‚p߽ȵ²3‚׬xt‹ÞŸ%Y„ L#àp\5…µ|zfÑpÁ›ZÜ/nyU_@ˆ–Zs“–²m¹%œü;{žËÚpC˜8º”º¯­á•=“7ÊXˆ—I†3û›^Ví!vC`½©Eê3ï 7W@a÷í¼ ~é}kC‹ž‹G?PK r6¶là org/apache/regexp/REDemo.class…W xWþŸ¯•×ÏŽ#ÛMÈ…“¦­,+IZì&ØN1HNp‚ã„vm­åM¥]±ZÅ6”B¡”û>ËQ(GÍMSj*(W(å.7”û÷}-3o%YŠÕ ïó;fþ™7oÞë{¸ënÔc‡:ÆájÈꨃیQxr:ýÍ) s:puÌcAÃSu´0üi:Zq]3mžÎÃõžÀ3u¬Å Œ|Ë<›97jxN7éX‡Xás™ø¼žÀ xÿBÞ¿ˆ‡óð /Õ±Í?üe<¼\Ç+ðJV¯âÕ«u¼¯Õñ:ܬc^¯á :"l_o àM<ߢãÍx _èV oÕ±›-~›Ž=x;_ìL¹…5ÞÖŒE¼SÇ»ðn ïaÊ{5¼ßÀ¸µà&}‡;´@^Ç2>Ä}˜)wñPÐð‘>ª#†»5|LÇ!6ëø¤†O1ßåáÓL9£ã3¸GÃg5Ü+ \ bŽ›ŒczÖŒºfÒœÏDG‡úÓN:c¥LÂ\X3hNå’E h3–™JŒ tÆN§Œ¨1çEšóÞA¦@W€¸áMÏ 4:9±ÕØý®iðáÄ-›®´lËÛ'Pêhp&ML$-Ycµt…|5)ÃNFx®e'û ~QÏZoÖu挩”yÔñ=•bGKüþžÕÊHU.“0<“Okñ—EÅíÙ=f¤ræÀ,I˜ Í¡•[™§LÛ¿Û¯”Y iòÉ÷¡ÉZfKLƒ”tÖrºÄŽ lý¿"1‰ãtDÙŽ«\+qÀHÆŒò­†ÏI|_Øx.`À±³žKöyY5eî°5½,›öE‰/áË_Á}me@̘2Sôž£f2—2Ün²É5³Y˱ûXê«_Ã×%¾oJ|‹Eƒ«ƒD ûødh²9YÏp½¾þ&£Öážã'$NàÉßf šï²>VÃ0B“3Žs¢‡VW3æ;¸O⻸_â{¸Ÿ`U I\¦`hø¾ÄðC ŽÄ0«áÇ?ÁO5üLâç8+ñ œ-ù³â½äffØÛ¿Ä¯(¡t‰_㬆ßHü¿“ø=þ °NÉXN”âÃÝïºÆÂ¸kyœX%ÎaRåùTvÖ%þ„?K$ÙŽ¿HüÓðw‰àŸ%!eÂÐü´™ñÈÅ'qm«Íÿ¿)ùT´šÙKuìÜÎÿ‡rª{o·Äñ€Äƒ( Û3Ûm;^wše4!¤¨õR4°R˜•H+\Ù¡]#MI©uši‡¯@ü µƒ4ílß):nضMw ed³fVR4 M`ýC‰IÌ !E M4K¡‹–re2)Ó‹îWSeL¯$_ÌÊz¦ÍN_‰; u‰ÍÝ~jxEöú´¸aI*rœ»Zh˜~¼j²TNPdÅÎI*M†==ëf1̉¾:Ï•Šz#AA®8ó×±U¡¨E$¯ÓU9zYMéØyòZÝ£1Iô…⼩òbcx"\@ÝÄ2ê—Ð@ËFZ6-A;­„WZ_Hl‚FbíÔ ÷æ¡ÐBÐ: ß2Ú–°&ÒÞº„ö^R¸v"l\FG‘<º"tΑöµŠKìuÁõí¡e<ìØ6T`6Fê°BͦJ5 Ì­c\•®Í%][JÀÆ2DY³„n¶*‰mdû…„Þ¾ ]ž¨È߉ á<.¦y‹šE—øž÷è¢{»è3½ŽN¸íä¤P bÕ„\T ¡ö]„\N€š{‰Ý“G8NsïÄÈl, B†í ‹. FiØAy<"¹½¨$U>ç:RÁJ®¡sèO#%;óØUÀnRqYœI왈,ã‘y\&Wäñ¨;ÐG«þE:•éš»ÂÌÛK¼Et¬wøÄÓê6{p®Tsœþ3â_ºlÉõÞšfdð”¢ü^º ¥v›Æ—1ë-àÝápO(`”VGâ½dGç8 Géˆ'ö’Ác¥¬ú8:͇Ô>ð?PK r6›¨Úe§!org/apache/regexp/REProgram.classmRKOQþn§3eJ¡£¶¼:Õ>ÊLa|4,|Ôµ‘„†%Q.u(CJÛL‹ãÂ…ÿÀ»²báBL¨CXºpéð§¨ç¶6ÄIÎ=ç;÷;Ï;?~;„IÜ "ˆ1•Žñ zqUÀk^Ç ’˜–!3€T“L1„çóÏ^=Éf²OfXŽ¡/[­Ô¼ÒXäåM[À‚§Ôù9áñ1ô:Är7‹ §Zað-eúËv%×íUj®½êl1È«e^ª3¨|+Ï]»B¶rß©8ºL.e'üÙêk›üÉ\+äÏ #\²]y)ÖŸœÃõó*Qóí¢! #Âú…e…0*à%D¸Â-ÜaPxaˆUÝ’Åk¼¸f[®]²·jÖÂlÞ­–\¾Á ­ó7Ü*óJÉš_Y·‹ †HÛåT­‚í:¼ì¼å+e@JЦ»ø…ízæ*w]¾]¬Ö¶ŒäÜù„÷rÿqÑ0 ñ® !hž>ô“¯ð….|‘Nšâ£QÛzÀÃjk…b†1BgŒP„~$éÃ4OÁ¾´™‚¡{Œabˆ—ï3R)Á0b-øþÑâM÷hšqÉðÇ0õ¯ðŸ2/ãŠÇLAn—Lw0"Ô±M<>Ãá³q8Ìás>Ïá&7s¸…ínãp;‡/p¸ƒÃ9|‰Ã‡#îäðe_áp‡»9|•Ã=îåpŸîw0vâM<àe7ÁQñ ‡4‡qòÌ1_ãð‡ sx„ÃqrxŒÃãžðÀ×9|ƒÃ“žâð4“÷ÈÕÏpø6}¿Ãá»4ÿ=ßçðÏrø!‡qxŽÃ ò?åð3?çð šø%‡_qxžÃ¯9ü†Ão9¼ÀáE¿ãð‡ßsø‡?rø‡—9ü™Ã_8¼Âá¯^åð7¯qø;‡×½ìnø‡rxƒÃ›Þâð6‡‘Nÿ&Ø8ü—¾ïpx—à œ——€¾’WrHNäÂp‘Ü\ò`ÄIÜ#å+HöLJ;R==z2©'ÁnœkˆÇ’†3.ÔR:º“1`¼­i×¾–æ¶&`JËÅÚ~­j@‹õUu‰h¬oÂ{âƒCÑ=lYK<ÑW¥ i=ýzUBïÓG†ªÚ›õîT_ƒ…„y†ž4⩘R›‘A¯H%H ç ›çïdDÑ`îõÑXÔØÌá's©XsÌÐZݯï@NˆäóçèˆDIi,t*R}ª·š†8©¢2äèíZB'eŠý9]$Ðç fu)#>¨zÄÒKøj›ÑOÞCýí Ýòw¤W¤æ:†¢F],²%¡Y$©nò¬áâ&Œ¦KSÚr[›ÃÊÓ™!íæç mnz÷éFÓÈÞƒj·ëÉÔ€1?qeäÞh,Ò¦;Ä VXhÑx•éIâ EУå§Ò{$/°Ù(̦oÐ’¸8kfà‘Ë×6%…îúž2H)_–d©cdRv&’<Ò,Yš .` ¦ã*ƒ\2¸Á#Ã,l¤Bi°šI­O¯UMÕߊîQ;ážrV iF•¯¢uëÅ…­4FŒ=åI‘¥¹àÖP?ª6ê½:VŽ ¨'ªfŠJdIµ7T‰Z]‰÷$-ˆÕJµ²²’X¡ê³O‚Éìö_`%ÿsÛÊì_ìß2ûaåÂöHE²ä“æÉÒ|inÍÜ“¥bi¡ÌÞboËÒ"i± ùdã\{ ·#²±+Å Šî”–ÈÒRé YRIûy¹×w• hŽ ¥ ¨kƒ&L–J¤Rb´Œš2`ÒFU––Óâ¬@áÒJ˜ܪ=ýjÒL†½©JL…æm|=R)ƒ ž¦D"ž¨U¼¹nG]‹ÚÔÞ¾­½V•!Œ8'ðÿûMG©ª›ëš[v¶7•¨jnJô9ÊÈ«~Ì8ê4¯\B@Pª¥„ªRPΡF¡Fİl{l3ÚGq‹©’VaBÁÄ<QcqC¥­J¶*Ù¸–[Ñ™«eXèÂjd*)­’¥³ˆ³å8#:¨ eŠ¥³1ªƒÉÊSÍTwlmjoRëðϲ´£$—¥¸D"ª”útC¯TQ/n†~veÕ:CüÉr”ãòkòn`K:ôDTˆÐ#U=™¨6<P£†^—Hh£ÛRF&‚ÈH\ô…6Ò¶î‹1ÇMÁj¤s€->…MVÊÒi-±ªÍŠS“Õ¬uÒzô“¦i¨W 1j.Á ðåJš]‰{ßèW§˜ÑÞTI9žÀèk#‘Òei-‚Ò˜ÃÚ’­ZR‘ªõâËb¦QŠCf\ëîñw Ê-m­ÛѰu_C]GSs[cÓö&lÚv¨6‚,m$ïxh!|7ö"‘ž'k/æWÒ¦2»–®D\ßÓØH4 N¦1D4Ëêg¨x]}C#ýС'‘Ù¢›m&ÅùëÐ]«Q‘:­½V_'~hëÉ|²ÁĬhÊL†£»³.´{Æ'oÐêûõÕÕ§êdC„Nö ÃÁµ}‚yÉéÅ/ú®´+†R“XOª¥.RØ& X‰ëÉØJ[†…„\ DKÌ„æ*0¥x33t=q­À,)íJ­Zµæì™pÝ/^}$ƒ\½ªzÍÿ@¾3yíŒÈ{µÊ@7zÉ¡y»ÉIZW¬{Š\Jð žÈ wjÄ ˜¦aáÔž¸Q!а8'’KC[m,2uZ¬;³°ÖæÄòúµËÖ¬^[}E9.péä@ź‘R1e6Õˆ«VÙ‡Q´,×Ü13´‘L¹‚RsamOÄûfj;—šä³@7mE3‰PÂÆ Q^J㓵š¬?ÕR¤DÉD lEééÒàÊ;{Zšî¹±½=øÓ439L}UéäÄé /<¹8A]Fð‡ŸQü¡K8€aDsÈ”>Ý ‘¥z©K–]‰x¬OMRñMufV¬çB¦K vc–÷NEJ–K‘‘ ,5JXÅKÉN”½G˜ã¥*^,:ìe§0úª½x{Š¨Ý£jŸ(ù•Po<êÓC£¡a­ç’ÑžJÂ#  £ž£!$K›¥-À–›2¢r2èî5RFj4f{­¸ß0†j«ª:»*»†»B]›ª®ÜwîŠ Ë÷q ÷G“QCM%kU kxx¸Ò ¾JŒÃôæêê3ÏZ¯©ý ½wCiÙªÒe«ÖWiI‹­˜`-o’l¹¥ °­“Œ§Ðç”Rº1ç4I)¡}VØT¾[<¬fí×ðàëÐ7ì§«.ž¢e«÷Q9±¯¬š’¸Ï†›“‰æ{5LC ™9´À+¾ÝâÛ÷Ç‘³=Ž+Z†§ `'¯ë)ß$ò¥ÆÎ¸Ÿå)Þ4˧¯l~ÓWf!8x”Í&écÌé¸K¼†“8' w ¢NpYê® 1~ÆYa`‚ÍAÉʃlnÀñ +¢fö}ÂTFoƒÍè$~_˜`>DŸ×Z8Êæ¢óÓhö+ÆÉ…Ê¢4[|?[‚­èíNÖ\š-M³3&˜FÕÇYIñ ¥Y)þ-sÖ òá V†ËaÅ8[9Îüµ.2·<ÍÂÜ`±+Í*jÝÅî§Ø²Šbwš…19 T"ã1–Pª°¨H³U¸Ž§é#Ÿóð‰#c¬´-£íjT¥Vg´Â“ÖŠ³ãìqfþ‡ϸÀo­Õâ ƒ3-MjI¬´é¸<ðZT‹‘†8¢A ÕΚĴùßhñ¿>Æ…t^„ë0cMålÑÖLögÆ ÄEÔ¢ÓÓ윙ñmó3*¡‚¤"7É·1d(°0ê0ÞÈܳÆÐR›ÿdŠ\×*µä2ì­ËH9(9qým'ž³ÙÍBbàŸwc¯cê0\7âß&ü;7fu¬>g µÎbgš5fK'°n´E6M.Î8Ûü¨T[ÂÅÎq¶UÄÔóŠ]ã¬ÙŒ$Nt…Öù‡O¼|„ÍcEµž#Ì]ìy´–Ó|ËÜ6Èô•å±VlP?UO³6eÛ¤»qo¦pÜž½2 !EäŒv³?›úYnÖÁöã¿©[˜Ñ[¨éé&œsá÷zÚŽÊŽq¶³% \(6Ö®ðvõ8{Oë ‡+ÆÙntBçë cÔíg{Û&ؾphœ]”fÚcXà•nÜ@‡iõ`\ޱY%bEË*¤ÑJ¯`|zÜp%‘Ñ}ÈkFÖBó~Só(Nq /(—PW°émº˜MTâ6pÈ^: LØÀ¤ 4¦HL‘D!+¨ì·q‡mÜ‘)¸£Y¸lÜËlÜ˧à^!p•+E2Bû¯B4€!vµ9L÷ ϼÏ^#†íáµbx=|¿~À^/†´‡7ØB>d ù°-þ#ñ£öðcbøq{ø 1ü¤=ü”Þh?-†Ÿ±‡ŸBÄ!A;M9„IW@9ŒÓ´ïÎc®ZJ›RŸttûÜ” •è=ßÌ p´0\¸äaWØQxùΰӱ3ì*\¸3즑G¼°`g¸Ð]X‡­Ç‰ ÷`“W¨aë%¤Â|Ä*”ÝØnÁvg+ŸÇ¶P Ì¡ …æ¶a[Dcç ¶ó‰íb[\ØíÂÂ&lÖbÇΖ v¥•›[ɳò·´”[étÑ\ãÌlåÛpËúз[ûUxÊϾ€Î )wLÅÿâôø_øcSñäÄkr§ÀÿòTü¯LÏÿ®Ì‰#Ñÿ­XÉúY\7~Ÿô<Âî;”¯v„Ô¸”{:ÂnåÞŽ\·bh·V(÷¥Ùým:¡‹ÊAŸ³:ä£2åèA'øœÁã·3¯Ï:~Û‰—ʃÁã¡ãi–ôãDïš"¢¥•;†Ü0 ¯Éð52ÀEÙð!:š}®ê¬³n"ˆcsîèAø\$êé€ò°%Ê6OÉÄ[Æ›“ŽðŒ-Ê#­Aå¸òhš=†«ú8iqT@Ÿ0·ïוo ü'ö”òtøMø-å™ ðÛàwLàw•;2À;&Ö¾ü^ôûèLÒg•f€?ÊŸ3?V~’þôdàϲ€?Ïa™üM=úYІ;=Äê+žbùäŒç±Ù¡§0¶0½?˜UØK#*¹_cSAߘ…Óbå·öúœ5ÉÛgñ^gñ®Z¼ä–ŒD5@Œ–PçdF½ÔXŒVѱTy!(4t9îR^´ºÎ»ÊïÒì%³àEºPlÕÖý¨%¢.eQëÛŽ­O3÷;­ø=FôÒì‡hâÌ åOv¿²‚J 4~i&._¶ Ÿ¬ó‚¢J¸§âÞì3¢äE°Ø’V.^ü^ÀlòçVAÂ\p/)ÒFM­Sù eÐçk\Ž7ÔrŸë0«£#…ôg¯Ô¸}îC¬Êš8ÆþZãñÑV­åŽš¼16»˜û¨ «è8˜¾<Ÿç¶¯M°WÊP±Óçò¹‹ù8ûÛÉ*rX’I>qÀ+‰òÚ1ö÷Ø«û?PK r6­8µjõl"org/apache/regexp/RETestCase.classW \Wÿ?vaÃÈ&Ä’v$Ú, „ÆÚ ½²¡ÍU’6–aÙdÙÙÌÎ6¡¶ZµµñÖÖ‹XÛÆ‹ªxDÃnmlÔª‰Öû¨÷­Õz[µÞ¶~ßÌì²À_ZøñÞ›ïý¿ã}ß÷¾÷qÿ£÷œ@¢IÅ)x¥Š*ªE¯ªÅ«ñ^½–‡×ñðzÞÀÃy¸…‡[¼‰ç7«x ÞÊìo“˜äù°ÄÛy¾M%IïP s;w(¸SÅJOËÖòNï»™ö‰÷2zJÁ]ï“x¿Šà6‰iæü |HâÃáåQ•ø˜Ä1‰f/H%î–ø¸Ä=Ìqœ‡OHÜ«à„Š ðIþþ”ħܧ¢Ÿáá³*ºñ9‰“ N)ø<“¾ âܯâb|QâK ¾¬à+*.cþ^|Uâk_—ø†Ä7%¾%ñ€Ä·%¾#ñ]‰ïI|ŸmùÄYÛ$~,ñ&ýTâg,ýç¿à­_2ñA‰_IüZâ!‰ß(ø­‚ß „ÒVR`åÖ½Æ5FWÚÈ$»v9v*“Üœ5íM5™üø°i ˆ>B;¡# ЄS²†ã˜v†V޵Ípcê°1²³Dƒu¹1+Ÿñ·k²†mfrˆ‚$†3ç¬ÚjÙÉ.#k$ÆÌ.ÛLš³]ý½»i­ó+QŒèIeRÎEcÑÅ-T&”ÁÁ»Û®"ËãÖˆIްó™ÝîBQ&k| ¸mNÊʸDrI-}‡Ô‘e‰}ýf.Ÿ&¦ptq§ïªÇžpÑWæH[œb :W|̰9¾þ Dz7±(ÍÈåLÛéÝŸ7Ò$ëŠèbabþ`]Cf_s(¹|"aæÈž¦…¼äN ×àZ p°X &Fü^Ã0¦!Ƀœ†öjØÇCš‡qd4X ·7Τ!‹ý þ¨áOø³†‡ñJÖ(/þJAjëÖ5ü hø;nÖð"\§áz6hyP6ip×ðüSÁ¿4üÿÑð_ü¢´ÇÈé„1)(#ºcéændtÓ¶-»CÎ;ú#—Yç¬×ð(£+1keïÁ„™õRf‰®ënô»õÞþ~•`;mk$Oî+ Ó£ ™†¶½B#‰}™/h­dÊgÊV™%Ez+‰hÕDŸ³¡ÂV °:ngSiÓÖ1Û< Ž‘öµç²’‘º‘4R™œÓ­¯¨Z§j"$”…¥}s¤['ôî¢íí;H§ªáÅx‰†pÀº²œ<çºîEkAf“Ú†b0'Eñ¥x¥ê<ùeð¥¶mLéÙpš‹̤‰jQ£ EHÒ,jeãg~¨ 0EÄQÊêÚ<ᘮ%}™lÞñðšPE«×x¨_hC¿iŒ˜öÚ°˜îCÉÏõŽ5.höâ]J˜r¢qü[æîÍK&ÅÏú-©=c9ú¸W,«x»¡uNšweŒ1Ë s`ÌÌT^¿õTx}É YY‚0ã\X#9Ë-¾zÂÊg(—5Ñ $Õ£=¶E¾ó^GÝÕ½ÇLÃËq /s‘¡ÌÓ(–REÏäÓiMDÄ2²Óã'¯¦räCo䲜ÞÍÙkÎ×%Z¶ˆL­ã'ªàüUÕÚFÑ_ì]‹9sNÁÛ1¼—Ñyãðߣ8un©œ +ÇiÛàìJXÙ Xe½öDoê õñãWcd³f†âØTåï?Z¢}§Ù•ŽåQ(ÌÑ…8B„r™*~ÉXØl1‡óÉR]Û´ˆOãe!Š/jBàq‚¸©ê&mcœ„«9Óñ¿ôྤ„vû‰Q#•è|o+³U¼!»Çlë€1Ì«IÓÙFï­‘¤†,¡©N‰}»éB¥Ú¿^1·#ŽÅ—ß-2Ü£´ Å)¸i3“tÆÜž†Z%:÷¢.IפœÝLò£C›yg¥/Ÿ FE­òìžÝòªˆK­'Qî•ò“S–¾ÙÖ€áÞÏô;¦€LåôYïD} Î¥6z€Š·´Šp·áÎÔk¸ó>Nû35îlù3õîL ÍUÜ+¸½Jh¾¸Ð5¿ÃsÊ¢:Ý£xž ÂúÑEÔ–IÈȹS¨Žl`àÓ\`KçMâ´I wOŸÄ­.Ëù¾O.`IE<£€‡>ên>ÓßìðÔl ysOVâ.òqÇ%>öÒ"6¯„mña½»Ì×÷¬".÷1Sسu¾ûúfƒtz??{Q?%—®ÀƒxˆÜL³Xê»™F?Ën§,ãPÜ ¥Ý‰óc³ ¬±;ŸÃîÜÊ¢·UÄ`{9iÂÓ²c¾U;*à;ËVM¡m>ðŠ `H)×ÖÊ7â>J ¶µàzt—Ƕª€Ý|¹¼`»;Wò­=QÞ»ê0ªCÓ¡ž)äÜí=œ)Ìò\_} ”ó%2ÈÜ-´šÄÒÒö)ÔLaC¬ÒìçùbÈ\cVÔó]7 Ñâqä±Cáiÿ†S퟇*ý“Œjð/Ù_H’W¥òj7•›æ¤²žB84½ )ú¼¤X;'({¶eOç‚ì霽¥qúÕÝ9í¦à®Ë? šæm'¡u6‡=¯5‡O¢§9L2†ãWJÈø0ùØ¢®ú—<•"ËŠ£®”jþ,„Eè+0LÃÆ ù!ZUè5蟆Av”"£äù÷ìúih¡ ¨·ßÑE¬wÜfåÆZßQýT,nQ›¹ƒy]DîQ/Ã8}U¢m\O\MòºTÍ5îÑø‰PK r6ˆÐ²æ-¬/org/apache/regexp/ReaderCharacterIterator.classmSÛRÛV]Ç’- åf" ¡4­­@ !¡i’’€¡­SŒÛ’IûaŒ3É#É ¿Ò™¼´Í /<„™bÏ„NóžÈ7äú\º·,h‹mÏѾ¬µ¯zû÷ë?¡`?èE¶IÌi˜×Iw…>®ëtÜ`Ý¢ŽÏqSÃné¸;:úð%›—Ør—}îñ±¬c9~[e뚆¯4|­á„'í²ôÖŸÚÏìlÕÍ>5·ÔíÆÎŽÀŶ¥f;•ìfàUÊ éCD©æú², ~$áNÕ©KÃéó\™-b˹e)Ðë7¶ýE`4Ïg:؉7™î®O”vmo9 2rÈ Ä«þšSn‹”ÊÅ´¥¼€¾¶W’õ ê:¾€Æ¦åZM@Is6 éø O¶· L`ÆÀEŒQRÝ«e—Ï \‚i`)ƒ¦Db÷5|k` QݧUç‹g¡2çùòNYîAqgÅm8eÿÌWúîs¨ W9¥)LøW ñ†ï ¤ñÀÀ&ò[†è]¯’µëviWf=Y‘{õ¨é9j•] ¤—§¿¸<ãS)n?•%jät'¼ °'p7£™¤»Nfà¼î´¡êá®ç>··kÔo½"ƒ‚ô}»"yÎ\átjÒ©»á°h’ýÿ_'š{ú§v½.y&HÑm—¢MÅ<­ý(>¤o`ˆç ÐMä;Æó¤»‡ì˜¤ó2I¨dRV ºz„˜u åñ` -¨Gˆ[ʇàŸàñG°  Ò=i· Y¿#ÞD9ÞDï«cô=žmÂháÂrç † GÓÁ<(QÜþS|¼*0|æ¿ðzÚpZžà¦eFñ ‰Ä2ó'Â?PK r6?s2Т/org/apache/regexp/StreamCharacterIterator.classmSKSÓPþnQyûHÑ6€ßO*j¬Š#ƒ+C{)ujÒIRåø Ü9ãJaÃBf¤ÑÝû#\û\‹ç´ÚdrOÎãûιçÜûãÏ—oP0†Ç:úlC/Æ5Lèd;ÃÊY^Îé´œgÛqIÃe Wt\Å5í¸ÎîIöÜà˜›¼Lé˜FŠÿn±wFÃm w4܈|Þ¹çöK;Yp“i§TOÚ/® ¨Ëå•CuwÑvòIòœü4Ù¥GÑlÑõeN@<%åZÁ)“ˆ7%L£¥‚V3VAÛ§û_Ѿ4VQžïÎtA †B‚ "P¼ûÿá+8ðižá£»áôÖát4Bx2„›–æ'pÇF#x?½uðIœ Á·Bðx=o§ù-ÊÆ[>@Sס* ŒûhC5ÆIZ™1E’Ûq‘ðÑ·ÌfN®c´H]×cïÐnQ7£ëèá ±7t/¾V¶ûßmÿ4ûsµþZô©”B'2º!õIÞH÷:qt*¿ªèY¬eÙþ½Ù£k¸¿<×ázEê¦ní=ý[¦ú,TsÌ·—PK r6½ñ68UO/org/apache/regexp/StringCharacterIterator.classuËNÂ@†ÿ¡…B­ (x¯¸(Ó¸Ö˜⢉‰ î†2)%¤i5¾Ž+7.4QL\ø>”ñ TLçdþÌå›ÿœ9Ÿ_ïÐp€=Y”s0°bbkJÖ•T”T lØ4°Å EÒc(žwù-wz<ôËX¡Ä9 >a(ÙÓ×õ+½Ùo †\tÓŠF§ eÛuë³ÌJöìóŒ×áò4&3š é : Ûãíµ ÛLÌر°ˆ¼’‚…"–,ì¢ÆPïKßáîu„#…/î‰w“|¹ éÒäq_2äó_´ºÂ£¬µéç3j¶únþoùT}O„~Ü.©ßYPChUÕÒ´¶0Oº@»2R€Ùxkì¿"õ 5˜úÛ„Ñ(ó‚T¥:„ö4a SJ|r#fý¡Æüƒ¤d™®ÆÈF‚*Š"sC€®Q|PK r6ß»œÃÏÚ!org/apache/regexp/recompile.classuUKsEþF¯­üHd°qb,)rL0A~q 1ÇØq ˜@Æòx½FÚÝZ­¥(n9s‡TùäsrpRI•¸ó;ø =«‡åXìaf§ûëþ¾én­þyñ¬( ðtŒ¡ á}’(b‚㢎I| Óá’†upÔ2Åñ‘Ú/s|ÌQâ˜æ˜QÐY<§ã|Êñ™Ž+˜ç¸ªcŸs|Áqc‘ãKޝ8–4|ͱÌq]Ç .kø†cUÃÇ ën2$flÇæ¢Ùcóî–¤­*l‡a8»±´+îŠbE8Vq-ðmÇšÎÝ4EŽ!ãúVQx¢¼#‹¾´dÝ+®.Ì»UÏ®H_÷¾Ã-†ìzMX²dú²Üô™3žé;Ž¨Ê¹ÎiNÃ÷6ðƒÛø‘È_e¾²·½-}?ჱèԯخS3 °ÉÓMzŠEsÅ—…ÙñZ{ᛤϗµáÍ1†È˜Î à¦çÛwE ÍZ »lnÛŽ¨˜åáoÜ6’欦ýÅ@YiÛ‚Ô°mÀÂyC—z4Øvñ3›ÐP1P02Q§eœòh!ò×i†óúÿ²®.¬ø®å‹* ±#ïÙ²”)Gñçz•}í¾ˆúB½,=UjNÓbJßw}Óvº¯?BÝ)‘d—áÔQ•»¢‡×ÂËr@õ“ms‰TõwÁUf†EGuÔ‡T tæ¤ÂNó)à(ÅõÍ]â8fZ»_ d•º{äH5ÇÏv‹+4ÍÕé¶êãfª±§NÒŸÊöš[škY·)m,»¨N áyÒÙbï?ajαóÀmZNgO╢έ/ö¤èÕÊV»§{Ö±ã¦VX2èþ¨kå6æirŽˆTo,I]ê Ük²ÞV¢û÷’=ðªjT‘Žì„߇ÅcãrcÇwï‰ÍŠÄY¼G6õDÀÔ·Ö<ig´ÇóOÀ…€$.`¼éf#†>Ú>GäÖD—ò¿ çqïwô?Fl(~ˆDô)´èìóó™Éå|&vg²{NødáúP-‡0Jq hÙ‡^#[:¦¼¯«¥_ãêm  >Äàå*%´)-8Ä©N% RÉ”æý>Åš€ižJ^zŠTI?@ºM0¬2ê-æðí mÿå¿]Þl#†ÒÎI–J¦ycÿåŸ*û[t»®ˆ3„ o”éÈ}»š8€»Ü…}—T…1›ag» WK±.ì¹V1º#ÇÊ5Ú"ΫnþPK èŒr6¼]{l],META-INF/LICENSEÝZ[sÛÆ~÷¯Ør¦Si¦4i牱䆭CiD¹n&“‡%° ·°È. Šýõ=—½¤dwúVM¦5IìÙ³çòŸù[ô²Ü)ñ^—ªsêÅ3OþCY§M'¾ž¿.Äßd7J{_¿~ýÍ“‹vÃпyõj¿ßÏ%m37vûªá­Ü«¸ðþúî§µX¬®ÄÛ›ÕÕò~y³Z‹w7wâÃúºw×·w7WÞâ×=uµ\ßß-ø€ß€¯æâJÕºÓ(çæ/¼63¢™p;Ù4¢U²œtP¶uBv•(MWñ*Q+F§ aUoM5–øuáE᳕vƒÕ›¿Ò‰ ·T•ØÄZ•,ä+o͸݉჆çL9¶ªŽõ2öD±Òô«·»A˜}§¬•`¡BŽÃÎXýoÚÏË9·bØÉAÀ¦[+aa·¥‡¼2ÔV6âšDŸ(1vx@Ò^ Y’” ˜žõb <àÔÊñÖ`ÐÁš¦Òªð¡!¥ < ~;v,+MÛšÎKòнv,‡7œ‹wÆ’ýh{“¬|4óRft'.ô%/5{e pŸ/¡ºãb0¢”àt|ÎKáŸÈV´²“[…ÎÃ}ÝXî¼b…Øï¼OûJ’[f¯1š@Ê…MÈ=n§{”Të¬Ù+[¢è‹o_ÿþ’¶3`6|4n«£ÀMV¹ DnTF(5¸r"=Ó3¹üg3ÎĬÅÙÙeîuømò «eY‘LJ A[íPлÕÎQÀSœq[NBm »•‚^íq¤õVÕÊZXN¿ÖdñO¸Ek* G“”UÁÁº+›‘LI(:3ˆF·w?:S{ /G‚S*°~È=äÅðEÈÿZoGK¿ƒ[•ÁÇÍæ_ §ªËîÀß;Ɔò£¶¦…Ëì@ë Ã'e(ú¦ñk!›‡ÄÓzGÇ„´é5&”!åü1· pøzrà½à¤ŒÞåpÒR ‡>?öGc?€Â¾$ ‡0ÒR è.#&›Î«•ɃÔÜ4!ÿ3\*M1KéCIF\èf€‡#¼±¥àaMf•Àµ…,´õ".àêQ¶=ì Ú!Ìy!>¹è{;?B25f™¬p¥¬~+>(q³ãÀ=ÎÛÀŸÞKbÅ7Ò¡ó:JÅ ÷Àè‡èa¬Â­È]˜ û.w€³¨™V=hr%F1˜Æç‰P`acÃ'áÝœg“†UN9ˆ²¾„ÍLCIËôVw°Ë©ÏOñ8àT=IÿB›Ï[£ÙûŽÄûªaU+uÌOÕKK‘‚v¡c´ÊªæyÐ}"Ãm Z0N:ÙªËàt @dkYR‘(²z¢ZG™:yý-B¹¯ñg=~œ1e³ý¢}Â…Zõ@aŸP Wž‰I†mC«à÷§”/²¤õ lÝØvã°ÃƒGà]¤9©çS6"?¡ÁËTîž­9QAT¦í1Þ7 ŒYƒ)ž&/_VíÅ,žiæeq½° ‹T h €q^ØÈ†âhoq]Gäcì¼õfAnt• …v\J²¿+ž-E»ò=࿤ ¢npq”¤e%+R!wpƒj]áPsG…%¤¤éŸ`÷cåc¶¹Vnô"ƒ‘IdÖF»Ç-GGUžvl /=üHˆ—J“z F˜ž5Ä#ÅõºÍè y[i?!ôÙÄŽåRNo;Â~Eôöl$"XÍV`o)ò\ÏNSøˆ_Çc‡ ü,åÉ ˆøØm*v ÌFA<eT„ä t¾OJB§~!~ܶ4`o.×Hx³ôc úz.þŠ´ ·}˜•X\\}¬žmf²4ËQYA•™BèL,ŽxC8%0¼^ `™~}Mµ×È5:Ó½$Ï;81~| ¬Çn±q2Ù ‡—µUðI±{0%ùI5÷ýnº-X9ÖcŸ ]‚ó~ÜÀZ°"jßHôø èÌ¥ÖÑ7žXä}[Nó#Y>ÙñL9'laý1sЭDÐý?ðÎ,Sý€ -Ç((è¸!º=Ÿ5óÐu¶“ŠX^PˆúhS×Èó ¨à—ÿÅØqÀeÏ fÂÉÐ죰«ìûÛMÓÓÉʈ]^µ²‘ìÍÏf‡+’ܺ7;È^ç¤Õ”µô Ò¡öå‰á.¡ 6òàIdõ´ìxA8w¸¾Ú‚úLò¦Êù-öèŠPëæbY£ÿc/ä©0¦£S½eäVâÏr¾q¿H+rkkœ{IÃc”fDþÄŸÁóR4rïF=àQµå" Ê'Np„ŠÏÕVÜùV;É)“sáXÁ-1UÃTl‰2…fÔgJh4RŽù’XWLQô^ˆéa«àË|Ѻ ûÄŠ¡à›¹¸SùdhN[·òí…uà6é‘¶E}Q=î7À­Žˆ •SߨâßÉA%Õ‡ãNâ{*£aÏM¶'n•Æ> ûwêX !ht‡qÂݣ˶Gˆ‹!2±uß’1Ë™î\f;[5@‚7g-ÇŠ‰¹1z¤\eˆÐB•Ác¢99ãì Ÿä´TOV]"hEÿûÆ]=[ÝÜ/ß^Ï ù²7¦ß)w¶Ož]œÉ”Ë’¿2Q¡õ”àCYQ™‚N5+‚’Ä9o&ƃ!„ŽP|‰]31ç-|Ö®l £QÒa;•Oéý’”­@Œ`Ó7AMtL¶NšD•{V‡ïs0ŸYž×Ó”ÐuÂ,™ÛTOå[œZY®—M¹|opÆJõQ¦€mõyˆ¾ép> 3 %¡ ½ßq†øujæÌßD¸•ŽC>è!RóŠ eªŽÏ-B¬Ãd6ˆ¬*ü·Å~'ÈLJPÝ[èK2¡`ë;pD~&ê§p¼QUª«Æ6ÐÖIÄ`áþ/¸óÓÈÀaˆf8›L4­‚ž‰y€ã óÔ½ÅY¥®‚h+ ë™ ¾2W Ž\eÉid­–{†Á§ÑÞ™+#“Ý™úŒ6EJ›ššÅíH>‹©Dòpëlš—8¹­šTáȺq–LTãh2–‰ÊQ'0qÈ·Ôìø›îU tsñ¡ƒ*êÈiê6*5¶¿$1» ‰óÃ1‹Ì†YÙëÉÑUbú¸ãñ ‡©Þ&Ÿ>ÿ7­™§Y¤f0,‚©knyýÊ ¸(ÞÞP}ÙnÊ0m·ÔÞa!ÕÜåÀ©JñE¦A濳 ‚cK´…žŽÿà3„:2õ¨Ê â x£A¬ÚJË÷Jǽ‡¿ ø@a a1ãÑ•!ä˜rg7Bhx¡Æô%\cÈçf‘ÑàÔKÙœéû “a~8mÐ8DJjS­úmÔþö ºŸ`I'—Bá7-^O£6`eà%л"68©=™Ï†l ~óÕàL `Kýy.®´£Ö /mkñø'Øå“ ªº9pK7¶X ȋԼ¤)X‘æsß%U/PW·¨ùÓ8¾œ8÷çZù³ÅZ,×3ñÃb½\ã~\Þÿxóá^|\ÜÝ-V÷Ë뵸¹Ë¯åoÞ‰Åêgñ÷åê èŽæàGœŽºtM¸RecÒ”A4'•§Ðä’©¨!²§ Ƽ_Þ¿¿.Àê«—ËÕ»»åê¯×?]¯î ñÓõÝÛAËÅË÷ËûŸ)„Þ-ïW×k~}`áeÜ.îÀaÞ/îÄ퇻ۛõ5W[¾-lðfôïaSM·t3Ã]á4\ÀsÖôV#=§×]øÅ_BÜl^ÊÓFç€áq\kGÈîL©c›Ì îïYi›_´ž6³{™Ãç`R\ô^Ënèò|‰•WýéÒƒeÀW ;AGè´³QK¸É‚ò‘A§¶öUªË"Þv“Qnœü|6Þ/˜(àL¿Ñ"t¤ÜçñÞ"l9àŽnÇÏç£ç¤|àP&¸¬Ñ´±Ÿke+·Ó>®¯¤—\¯ðn=»}†„bËW H`x¦‹r^h@hœ¹Þ8®¶|gŽU<Öj¼5>ntÉšcĘ‘¿Ñwf†«ùÄàâÙ;ñ »1°[cª½nòÙá'(ʦï%N ‘Œ¨x-u3Z®F²©Ç.‘*‚gÞÁ[ Þܼ±r8‡HÐq^F¦ËêAÓ%ií_߀ ðF/7xñœßÍŢĚ€VÈ‹;/R¡Î’âã©û4]/ Ÿ½n ,´ÜÃSPštN.Ûiæ ¼­V„'u¤¡ìJŇèy êÑï@q§Ú_-I16ktfÓø)ñ–W;È|ùª΃ùâû+46?š=vBÜJFƒ‘=3Áé|ôFK×d·!‘sûkâú¯HŒ’¾ÄtÒ-JBô4)ÊÂÀÏ„±gÒ5ã3&<ç;Ù¦Ž¶©T í ¯f\KÛr­˜Òy´6Ý–ùÉ1`2t娬òµ8ožl¤Ðɦ‘Ìï³hÌhcÔ…øzu…uõÜkpôûâöYþó º¦€¨ÿúBþêþFªìã]üÝá‚¿F1&Zm k,´áC˜j©“¯µj*' @@²3èoð–RAdÎ~ùu&¾ÚB0ªú®/ë¤çââÊtˆï d9„ÿîRP·Nmªz‘?êể¬lgw³˜+îxþ/B©©g'`aãð‚ŠŸösÒ€âô,Ç D2Vn»ˆfö¡‡«ÕJ¯¬Ð iÐÄáÂ(GƒkÄàÖŠéͧùÕ„ÀÓñ>Þ[.Ü»ÆñLrH[îðÆšƒ!]&þr€¿_Å/¤7èytËú+=Êz¦iøù ¡âˆï\^~"B?‚@ÀåËÏ×oC cDEŠ#R×o64-““‘]d9„pÿÜ+§ï»¯Ö×/AeZò% ý)îáß9C1ÙHíô '¼4ÈxŠÿô;o2ÛZ©‰ !ȉÖ@ÌÀѺí”ÊBwüfŸŸ–$¾îNÏ5ñPK èŒr6vè´²Ã.META-INF/NOTICE}±nÃ0 Dw}Çf±÷n] t ümÑYDÊ®ÿ¾r‚2Aï®r_GNc¬žT&Û°xZ)J&Ãî®à#ãØäòkø”š<K‚·`–ßû~Û¶¶NÊÜŸ:ç¾ FIÊj 2Á*±&ò[+<Ô#@aAOíQÓ´7Ï+ûŠQ]K(`œŽk{‰ÑÁ9*ÁÊÊv˜]«w£V/ÈBgú#½á‹áÚB3}çLR`‘BŽS—g´ûPK r6 íAMETA-INF/þÊPK r6sGV^j¤+META-INF/MANIFEST.MFPK r6íA»org/PK r6 íAÝorg/apache/PK r6íAorg/apache/regexp/PK r6¸ ƒR7¤6org/apache/regexp/CharacterArrayCharacterIterator.classPK r62¯+óŸÓ)¤Ýorg/apache/regexp/CharacterIterator.classPK r6R—àsè'¤Ãorg/apache/regexp/RE.classPK r6û®YäG*¤ãorg/apache/regexp/RECompiler$RERange.classPK r6lˆá"¯™""¤org/apache/regexp/RECompiler.classPK r6¡Ö. i '¤þ*org/apache/regexp/REDebugCompiler.classPK r6ÑDVî: ¤¬0org/apache/regexp/REDemo$1.classPK r6¶là ¤Ø1org/apache/regexp/REDemo.classPK r6›¨Úe§!¤×9org/apache/regexp/REProgram.classPK r6!õð¢üs)¤½<org/apache/regexp/RESyntaxException.classPK r6üŠ4%3ö&¤>org/apache/regexp/RETest.classPK r6­8µjõl"¤oQorg/apache/regexp/RETestCase.classPK r6lK½¤¤Zorg/apache/regexp/REUtil.classPK r6ˆÐ²æ-¬/¤\org/apache/regexp/ReaderCharacterIterator.classPK r6?s2Т/¤`org/apache/regexp/StreamCharacterIterator.classPK r6½ñ68UO/¤‚corg/apache/regexp/StringCharacterIterator.classPK r6ß»œÃÏÚ!¤$eorg/apache/regexp/recompile.classPK èŒr6¼]{l],¤2iMETA-INF/LICENSEPK èŒr6vè´²Ã.¤ÌxMETA-INF/NOTICEPK2¼yjakarta-regexp-1.5/src/java/org/apache/regexp/CharacterArrayCharacterIterator.java100644 0 0 4755 10577337776 25553 0ustar 0 0 /* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.regexp; /** * Encapsulates char[] as CharacterIterator * * @author Ales Novak * @version CVS $Id: CharacterArrayCharacterIterator.java 518156 2007-03-14 14:31:26Z vgritsenko $ */ public final class CharacterArrayCharacterIterator implements CharacterIterator { /** encapsulated */ private final char[] src; /** offset in the char array */ private final int off; /** used portion of the array */ private final int len; /** @param src - encapsulated String */ public CharacterArrayCharacterIterator(char[] src, int off, int len) { this.src = src; this.off = off; this.len = len; } /** @return a substring */ public String substring(int beginIndex, int endIndex) { if (endIndex > len) { throw new IndexOutOfBoundsException("endIndex=" + endIndex + "; sequence size=" + len); } if (beginIndex < 0 || beginIndex > endIndex) { throw new IndexOutOfBoundsException("beginIndex=" + beginIndex + "; endIndex=" + endIndex); } return new String(src, off + beginIndex, endIndex - beginIndex); } /** @return a substring */ public String substring(int beginIndex) { return substring(beginIndex, len); } /** @return a character at the specified position. */ public char charAt(int pos) { return src[off + pos]; } /** @return true iff if the specified index is after the end of the character stream */ public boolean isEnd(int pos) { return (pos >= len); } } jakarta-regexp-1.5/src/java/org/apache/regexp/CharacterIterator.java100644 0 0 2754 10577337776 22734 0ustar 0 0 /* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.regexp; /** * Encapsulates different types of character sources - String, InputStream, ... * Defines a set of common methods * * @author Ales Novak * @version CVS $Id: CharacterIterator.java 518156 2007-03-14 14:31:26Z vgritsenko $ */ public interface CharacterIterator { /** @return a substring */ String substring(int beginIndex, int endIndex); /** @return a substring */ String substring(int beginIndex); /** @return a character at the specified position. */ char charAt(int pos); /** @return true iff if the specified index is after the end of the character stream */ boolean isEnd(int pos); } jakarta-regexp-1.5/src/java/org/apache/regexp/RE.java100644 0 0 203161 10577337776 17667 0ustar 0 0 /* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.regexp; import java.io.Serializable; import java.util.Vector; /** * RE is an efficient, lightweight regular expression evaluator/matcher * class. Regular expressions are pattern descriptions which enable * sophisticated matching of strings. In addition to being able to * match a string against a pattern, you can also extract parts of the * match. This is especially useful in text parsing! Details on the * syntax of regular expression patterns are given below. * *

* To compile a regular expression (RE), you can simply construct an RE * matcher object from the string specification of the pattern, like this: * *

 *  RE r = new RE("a*b");
 * 
* *

* Once you have done this, you can call either of the RE.match methods to * perform matching on a String. For example: * *

 *  boolean matched = r.match("aaaab");
 * 
* * will cause the boolean matched to be set to true because the * pattern "a*b" matches the string "aaaab". * *

* If you were interested in the number of a's which matched the * first part of our example expression, you could change the expression to * "(a*)b". Then when you compiled the expression and matched it against * something like "xaaaab", you would get results like this: * *

 *  RE r = new RE("(a*)b");                  // Compile expression
 *  boolean matched = r.match("xaaaab");     // Match against "xaaaab"
 *
 *  String wholeExpr = r.getParen(0);        // wholeExpr will be 'aaaab'
 *  String insideParens = r.getParen(1);     // insideParens will be 'aaaa'
 *
 *  int startWholeExpr = r.getParenStart(0); // startWholeExpr will be index 1
 *  int endWholeExpr = r.getParenEnd(0);     // endWholeExpr will be index 6
 *  int lenWholeExpr = r.getParenLength(0);  // lenWholeExpr will be 5
 *
 *  int startInside = r.getParenStart(1);    // startInside will be index 1
 *  int endInside = r.getParenEnd(1);        // endInside will be index 5
 *  int lenInside = r.getParenLength(1);     // lenInside will be 4
 * 
* * You can also refer to the contents of a parenthesized expression * within a regular expression itself. This is called a * 'backreference'. The first backreference in a regular expression is * denoted by \1, the second by \2 and so on. So the expression: * *
 *  ([0-9]+)=\1
 * 
* * will match any string of the form n=n (like 0=0 or 2=2). * *

* The full regular expression syntax accepted by RE is described here: * *

 *
 *  Characters
 *
 *    unicodeChar   Matches any identical unicode character
 *    \                    Used to quote a meta-character (like '*')
 *    \\                   Matches a single '\' character
 *    \0nnn                Matches a given octal character
 *    \xhh                 Matches a given 8-bit hexadecimal character
 *    \\uhhhh              Matches a given 16-bit hexadecimal character
 *    \t                   Matches an ASCII tab character
 *    \n                   Matches an ASCII newline character
 *    \r                   Matches an ASCII return character
 *    \f                   Matches an ASCII form feed character
 *
 *
 *  Character Classes
 *
 *    [abc]                Simple character class
 *    [a-zA-Z]             Character class with ranges
 *    [^abc]               Negated character class
 * 
* * NOTE: Incomplete ranges will be interpreted as "starts * from zero" or "ends with last character". *
* I.e. [-a] is the same as [\\u0000-a], and [a-] is the same as [a-\\uFFFF], * [-] means "all characters". * *
 *
 *  Standard POSIX Character Classes
 *
 *    [:alnum:]            Alphanumeric characters.
 *    [:alpha:]            Alphabetic characters.
 *    [:blank:]            Space and tab characters.
 *    [:cntrl:]            Control characters.
 *    [:digit:]            Numeric characters.
 *    [:graph:]            Characters that are printable and are also visible.
 *                         (A space is printable, but not visible, while an
 *                         `a' is both.)
 *    [:lower:]            Lower-case alphabetic characters.
 *    [:print:]            Printable characters (characters that are not
 *                         control characters.)
 *    [:punct:]            Punctuation characters (characters that are not letter,
 *                         digits, control characters, or space characters).
 *    [:space:]            Space characters (such as space, tab, and formfeed,
 *                         to name a few).
 *    [:upper:]            Upper-case alphabetic characters.
 *    [:xdigit:]           Characters that are hexadecimal digits.
 *
 *
 *  Non-standard POSIX-style Character Classes
 *
 *    [:javastart:]        Start of a Java identifier
 *    [:javapart:]         Part of a Java identifier
 *
 *
 *  Predefined Classes
 *
 *    .         Matches any character other than newline
 *    \w        Matches a "word" character (alphanumeric plus "_")
 *    \W        Matches a non-word character
 *    \s        Matches a whitespace character
 *    \S        Matches a non-whitespace character
 *    \d        Matches a digit character
 *    \D        Matches a non-digit character
 *
 *
 *  Boundary Matchers
 *
 *    ^         Matches only at the beginning of a line
 *    $         Matches only at the end of a line
 *    \b        Matches only at a word boundary
 *    \B        Matches only at a non-word boundary
 *
 *
 *  Greedy Closures
 *
 *    A*        Matches A 0 or more times (greedy)
 *    A+        Matches A 1 or more times (greedy)
 *    A?        Matches A 1 or 0 times (greedy)
 *    A{n}      Matches A exactly n times (greedy)
 *    A{n,}     Matches A at least n times (greedy)
 *    A{n,m}    Matches A at least n but not more than m times (greedy)
 *
 *
 *  Reluctant Closures
 *
 *    A*?       Matches A 0 or more times (reluctant)
 *    A+?       Matches A 1 or more times (reluctant)
 *    A??       Matches A 0 or 1 times (reluctant)
 *
 *
 *  Logical Operators
 *
 *    AB        Matches A followed by B
 *    A|B       Matches either A or B
 *    (A)       Used for subexpression grouping
 *   (?:A)      Used for subexpression clustering (just like grouping but
 *              no backrefs)
 *
 *
 *  Backreferences
 *
 *    \1    Backreference to 1st parenthesized subexpression
 *    \2    Backreference to 2nd parenthesized subexpression
 *    \3    Backreference to 3rd parenthesized subexpression
 *    \4    Backreference to 4th parenthesized subexpression
 *    \5    Backreference to 5th parenthesized subexpression
 *    \6    Backreference to 6th parenthesized subexpression
 *    \7    Backreference to 7th parenthesized subexpression
 *    \8    Backreference to 8th parenthesized subexpression
 *    \9    Backreference to 9th parenthesized subexpression
 * 
* *

* All closure operators (+, *, ?, {m,n}) are greedy by default, meaning * that they match as many elements of the string as possible without * causing the overall match to fail. If you want a closure to be * reluctant (non-greedy), you can simply follow it with a '?'. A * reluctant closure will match as few elements of the string as * possible when finding matches. {m,n} closures don't currently * support reluctancy. * *

* Line terminators *
* A line terminator is a one- or two-character sequence that marks * the end of a line of the input character sequence. The following * are recognized as line terminators: *

    *
  • A newline (line feed) character ('\n'),
  • *
  • A carriage-return character followed immediately by a newline character ("\r\n"),
  • *
  • A standalone carriage-return character ('\r'),
  • *
  • A next-line character ('\u0085'),
  • *
  • A line-separator character ('\u2028'), or
  • *
  • A paragraph-separator character ('\u2029).
  • *
* *

* RE runs programs compiled by the RECompiler class. But the RE * matcher class does not include the actual regular expression compiler * for reasons of efficiency. In fact, if you want to pre-compile one * or more regular expressions, the 'recompile' class can be invoked * from the command line to produce compiled output like this: * *

 *    // Pre-compiled regular expression "a*b"
 *    char[] re1Instructions =
 *    {
 *        0x007c, 0x0000, 0x001a, 0x007c, 0x0000, 0x000d, 0x0041,
 *        0x0001, 0x0004, 0x0061, 0x007c, 0x0000, 0x0003, 0x0047,
 *        0x0000, 0xfff6, 0x007c, 0x0000, 0x0003, 0x004e, 0x0000,
 *        0x0003, 0x0041, 0x0001, 0x0004, 0x0062, 0x0045, 0x0000,
 *        0x0000,
 *    };
 *
 *
 *    REProgram re1 = new REProgram(re1Instructions);
 * 
* * You can then construct a regular expression matcher (RE) object from * the pre-compiled expression re1 and thus avoid the overhead of * compiling the expression at runtime. If you require more dynamic * regular expressions, you can construct a single RECompiler object and * re-use it to compile each expression. Similarly, you can change the * program run by a given matcher object at any time. However, RE and * RECompiler are not threadsafe (for efficiency reasons, and because * requiring thread safety in this class is deemed to be a rare * requirement), so you will need to construct a separate compiler or * matcher object for each thread (unless you do thread synchronization * yourself). Once expression compiled into the REProgram object, REProgram * can be safely shared across multiple threads and RE objects. * *


* * * ISSUES: * *

    *
  • com.weusours.util.re is not currently compatible with all * standard POSIX regcomp flags
  • *
  • com.weusours.util.re does not support POSIX equivalence classes * ([=foo=] syntax) (I18N/locale issue)
  • *
  • com.weusours.util.re does not support nested POSIX character * classes (definitely should, but not completely trivial)
  • *
  • com.weusours.util.re Does not support POSIX character collation * concepts ([.foo.] syntax) (I18N/locale issue)
  • *
  • Should there be different matching styles (simple, POSIX, Perl etc?)
  • *
  • Should RE support character iterators (for backwards RE matching!)?
  • *
  • Should RE support reluctant {m,n} closures (does anyone care)?
  • *
  • Not *all* possibilities are considered for greediness when backreferences * are involved (as POSIX suggests should be the case). The POSIX RE * "(ac*)c*d[ac]*\1", when matched against "acdacaa" should yield a match * of acdacaa where \1 is "a". This is not the case in this RE package, * and actually Perl doesn't go to this extent either! Until someone * actually complains about this, I'm not sure it's worth "fixing". * If it ever is fixed, test #137 in RETest.txt should be updated.
  • *
* * * * @see recompile * @see RECompiler * * @author Jonathan Locke * @author Tobias Schäfer * @version $Id: RE.java 518156 2007-03-14 14:31:26Z vgritsenko $ */ public class RE implements Serializable { /** * Specifies normal, case-sensitive matching behaviour. */ public static final int MATCH_NORMAL = 0x0000; /** * Flag to indicate that matching should be case-independent (folded) */ public static final int MATCH_CASEINDEPENDENT = 0x0001; /** * Newlines should match as BOL/EOL (^ and $) */ public static final int MATCH_MULTILINE = 0x0002; /** * Consider all input a single body of text - newlines are matched by . */ public static final int MATCH_SINGLELINE = 0x0004; /************************************************ * * * The format of a node in a program is: * * * * [ OPCODE ] [ OPDATA ] [ OPNEXT ] [ OPERAND ] * * * * char OPCODE - instruction * * char OPDATA - modifying data * * char OPNEXT - next node (relative offset) * * * ************************************************/ // Opcode Char Opdata/Operand Meaning // ---------- ---------- --------------- -------------------------------------------------- static final char OP_END = 'E'; // end of program static final char OP_BOL = '^'; // match only if at beginning of line static final char OP_EOL = '$'; // match only if at end of line static final char OP_ANY = '.'; // match any single character except newline static final char OP_ANYOF = '['; // count/ranges match any char in the list of ranges static final char OP_BRANCH = '|'; // node match this alternative or the next one static final char OP_ATOM = 'A'; // length/string length of string followed by string itself static final char OP_STAR = '*'; // node kleene closure static final char OP_PLUS = '+'; // node positive closure static final char OP_MAYBE = '?'; // node optional closure static final char OP_ESCAPE = '\\'; // escape special escape code char class (escape is E_* code) static final char OP_OPEN = '('; // number nth opening paren static final char OP_OPEN_CLUSTER = '<'; // opening cluster static final char OP_CLOSE = ')'; // number nth closing paren static final char OP_CLOSE_CLUSTER = '>'; // closing cluster static final char OP_BACKREF = '#'; // number reference nth already matched parenthesized string static final char OP_GOTO = 'G'; // nothing but a (back-)pointer static final char OP_NOTHING = 'N'; // match null string such as in '(a|)' static final char OP_CONTINUE = 'C'; // continue to the following command (ignore next) static final char OP_RELUCTANTSTAR = '8'; // none/expr reluctant '*' (mnemonic for char is unshifted '*') static final char OP_RELUCTANTPLUS = '='; // none/expr reluctant '+' (mnemonic for char is unshifted '+') static final char OP_RELUCTANTMAYBE = '/'; // none/expr reluctant '?' (mnemonic for char is unshifted '?') static final char OP_POSIXCLASS = 'P'; // classid one of the posix character classes // Escape codes static final char E_ALNUM = 'w'; // Alphanumeric static final char E_NALNUM = 'W'; // Non-alphanumeric static final char E_BOUND = 'b'; // Word boundary static final char E_NBOUND = 'B'; // Non-word boundary static final char E_SPACE = 's'; // Whitespace static final char E_NSPACE = 'S'; // Non-whitespace static final char E_DIGIT = 'd'; // Digit static final char E_NDIGIT = 'D'; // Non-digit // Posix character classes static final char POSIX_CLASS_ALNUM = 'w'; // Alphanumerics static final char POSIX_CLASS_ALPHA = 'a'; // Alphabetics static final char POSIX_CLASS_BLANK = 'b'; // Blanks static final char POSIX_CLASS_CNTRL = 'c'; // Control characters static final char POSIX_CLASS_DIGIT = 'd'; // Digits static final char POSIX_CLASS_GRAPH = 'g'; // Graphic characters static final char POSIX_CLASS_LOWER = 'l'; // Lowercase characters static final char POSIX_CLASS_PRINT = 'p'; // Printable characters static final char POSIX_CLASS_PUNCT = '!'; // Punctuation static final char POSIX_CLASS_SPACE = 's'; // Spaces static final char POSIX_CLASS_UPPER = 'u'; // Uppercase characters static final char POSIX_CLASS_XDIGIT = 'x'; // Hexadecimal digits static final char POSIX_CLASS_JSTART = 'j'; // Java identifier start static final char POSIX_CLASS_JPART = 'k'; // Java identifier part // Limits static final int maxNode = 65536; // Maximum number of nodes in a program static final int MAX_PAREN = 16; // Number of paren pairs (only 9 can be backrefs) // Node layout constants static final int offsetOpcode = 0; // Opcode offset (first character) static final int offsetOpdata = 1; // Opdata offset (second char) static final int offsetNext = 2; // Next index offset (third char) static final int nodeSize = 3; // Node size (in chars) // State of current program REProgram program; // Compiled regular expression 'program' transient CharacterIterator search; // The string being matched against int matchFlags; // Match behaviour flags int maxParen = MAX_PAREN; // Parenthesized subexpressions transient int parenCount; // Number of subexpressions matched (num open parens + 1) transient int start0; // Cache of start[0] transient int end0; // Cache of start[0] transient int start1; // Cache of start[1] transient int end1; // Cache of start[1] transient int start2; // Cache of start[2] transient int end2; // Cache of start[2] transient int[] startn; // Lazy-alloced array of sub-expression starts transient int[] endn; // Lazy-alloced array of sub-expression ends // Backreferences transient int[] startBackref; // Lazy-alloced array of backref starts transient int[] endBackref; // Lazy-alloced array of backref ends /** * Constructs a regular expression matcher from a String by compiling it * using a new instance of RECompiler. If you will be compiling many * expressions, you may prefer to use a single RECompiler object instead. * * @param pattern The regular expression pattern to compile. * @exception RESyntaxException Thrown if the regular expression has invalid syntax. * @see RECompiler * @see recompile */ public RE(String pattern) throws RESyntaxException { this(pattern, MATCH_NORMAL); } /** * Constructs a regular expression matcher from a String by compiling it * using a new instance of RECompiler. If you will be compiling many * expressions, you may prefer to use a single RECompiler object instead. * * @param pattern The regular expression pattern to compile. * @param matchFlags The matching style * @exception RESyntaxException Thrown if the regular expression has invalid syntax. * @see RECompiler * @see recompile */ public RE(String pattern, int matchFlags) throws RESyntaxException { this(new RECompiler().compile(pattern), matchFlags); } /** * Construct a matcher for a pre-compiled regular expression from program * (bytecode) data. Permits special flags to be passed in to modify matching * behaviour. * * @param program Compiled regular expression program (see RECompiler and/or recompile) * @param matchFlags One or more of the RE match behaviour flags (RE.MATCH_*): * *
     *   MATCH_NORMAL              // Normal (case-sensitive) matching
     *   MATCH_CASEINDEPENDENT     // Case folded comparisons
     *   MATCH_MULTILINE           // Newline matches as BOL/EOL
     * 
* * @see RECompiler * @see REProgram * @see recompile */ public RE(REProgram program, int matchFlags) { setProgram(program); setMatchFlags(matchFlags); } /** * Construct a matcher for a pre-compiled regular expression from program * (bytecode) data. * * @param program Compiled regular expression program * @see RECompiler * @see recompile */ public RE(REProgram program) { this(program, MATCH_NORMAL); } /** * Constructs a regular expression matcher with no initial program. * This is likely to be an uncommon practice, but is still supported. */ public RE() { this((REProgram) null, MATCH_NORMAL); } /** * Converts a 'simplified' regular expression to a full regular expression * * @param pattern The pattern to convert * @return The full regular expression */ public static String simplePatternToFullRegularExpression(String pattern) { StringBuffer buf = new StringBuffer(); for (int i = 0; i < pattern.length(); i++) { char c = pattern.charAt(i); switch (c) { case '*': buf.append(".*"); break; case '.': case '[': case ']': case '\\': case '+': case '?': case '{': case '}': case '$': case '^': case '|': case '(': case ')': buf.append('\\'); default: buf.append(c); break; } } return buf.toString(); } /** * Sets match behaviour flags which alter the way RE does matching. * @param matchFlags One or more of the RE match behaviour flags (RE.MATCH_*): * *
     *   MATCH_NORMAL              // Normal (case-sensitive) matching
     *   MATCH_CASEINDEPENDENT     // Case folded comparisons
     *   MATCH_MULTILINE           // Newline matches as BOL/EOL
     * 
*/ public void setMatchFlags(int matchFlags) { this.matchFlags = matchFlags; } /** * Returns the current match behaviour flags. * @return Current match behaviour flags (RE.MATCH_*). * *
     *   MATCH_NORMAL              // Normal (case-sensitive) matching
     *   MATCH_CASEINDEPENDENT     // Case folded comparisons
     *   MATCH_MULTILINE           // Newline matches as BOL/EOL
     * 
* * @see #setMatchFlags */ public int getMatchFlags() { return matchFlags; } /** * Sets the current regular expression program used by this matcher object. * * @param program Regular expression program compiled by RECompiler. * @see RECompiler * @see REProgram * @see recompile */ public void setProgram(REProgram program) { this.program = program; if (program != null && program.maxParens != -1) { this.maxParen = program.maxParens; } else { this.maxParen = MAX_PAREN; } } /** * Returns the current regular expression program in use by this matcher object. * * @return Regular expression program * @see #setProgram */ public REProgram getProgram() { return program; } /** * Returns the number of parenthesized subexpressions available after a successful match. * * @return Number of available parenthesized subexpressions */ public int getParenCount() { return parenCount; } /** * Gets the contents of a parenthesized subexpression after a successful match. * * @param which Nesting level of subexpression * @return String */ public String getParen(int which) { int start; if (which < parenCount && (start = getParenStart(which)) >= 0) { return search.substring(start, getParenEnd(which)); } return null; } /** * Returns the start index of a given paren level. * * @param which Nesting level of subexpression * @return String index */ public final int getParenStart(int which) { if (which < parenCount) { switch (which) { case 0: return start0; case 1: return start1; case 2: return start2; default: if (startn == null) { allocParens(); } return startn[which]; } } return -1; } /** * Returns the end index of a given paren level. * * @param which Nesting level of subexpression * @return String index */ public final int getParenEnd(int which) { if (which < parenCount) { switch (which) { case 0: return end0; case 1: return end1; case 2: return end2; default: if (endn == null) { allocParens(); } return endn[which]; } } return -1; } /** * Returns the length of a given paren level. * * @param which Nesting level of subexpression * @return Number of characters in the parenthesized subexpression */ public final int getParenLength(int which) { if (which < parenCount) { return getParenEnd(which) - getParenStart(which); } return -1; } /** * Sets the start of a paren level * * @param which Which paren level * @param i Index in input array */ protected final void setParenStart(int which, int i) { if (which < parenCount) { switch (which) { case 0: start0 = i; break; case 1: start1 = i; break; case 2: start2 = i; break; default: if (startn == null) { allocParens(); } startn[which] = i; break; } } } /** * Sets the end of a paren level * * @param which Which paren level * @param i Index in input array */ protected final void setParenEnd(int which, int i) { if (which < parenCount) { switch (which) { case 0: end0 = i; break; case 1: end1 = i; break; case 2: end2 = i; break; default: if (endn == null) { allocParens(); } endn[which] = i; break; } } } /** * Throws an Error representing an internal error condition probably resulting * from a bug in the regular expression compiler (or possibly data corruption). * In practice, this should be very rare. * * @param s Error description */ protected void internalError(String s) throws Error { throw new Error("RE internal error: " + s); } /** * Performs lazy allocation of subexpression arrays */ private void allocParens() { // Allocate arrays for subexpressions startn = new int[maxParen]; endn = new int[maxParen]; // Set sub-expression pointers to invalid values for (int i = 0; i < maxParen; i++) { startn[i] = -1; endn[i] = -1; } } /** * Try to match a string against a subset of nodes in the program * * @param firstNode Node to start at in program * @param lastNode Last valid node (used for matching a subexpression without * matching the rest of the program as well). * @param idxStart Starting position in character array * @return Final input array index if match succeeded. -1 if not. */ protected int matchNodes(int firstNode, int lastNode, int idxStart) { // Our current place in the string int idx = idxStart; // Loop while node is valid int next, opcode, opdata; int idxNew; char[] instruction = program.instruction; for (int node = firstNode; node < lastNode; ) { opcode = instruction[node /* + offsetOpcode */]; next = node + (short) instruction[node + offsetNext]; opdata = instruction[node + offsetOpdata]; switch (opcode) { case OP_MAYBE: case OP_STAR: { // Try to match the following subexpr. If it matches: // MAYBE: Continues matching rest of the expression // STAR: Points back here to repeat subexpr matching if ((idxNew = matchNodes(node + nodeSize, maxNode, idx)) != -1) { return idxNew; } // If failed, just continue with the rest of expression break; } case OP_PLUS: { // Try to match the subexpr again (and again (and ... if ((idxNew = matchNodes(next, maxNode, idx)) != -1) { return idxNew; } // If failed, just continue with the rest of expression // Rest is located at the next pointer of the next instruction // (which must be OP_CONTINUE) node = next + (short) instruction[next + offsetNext]; continue; } case OP_RELUCTANTMAYBE: case OP_RELUCTANTSTAR: { // Try to match the rest without using the reluctant subexpr if ((idxNew = matchNodes(next, maxNode, idx)) != -1) { return idxNew; } // Try reluctant subexpr. If it matches: // RELUCTANTMAYBE: Continues matching rest of the expression // RELUCTANTSTAR: Points back here to repeat reluctant star matching return matchNodes(node + nodeSize, next, idx); } case OP_RELUCTANTPLUS: { // Continue matching the rest without using the reluctant subexpr if ((idxNew = matchNodes(next + (short) instruction[next + offsetNext], maxNode, idx)) != -1) { return idxNew; } // Try to match subexpression again break; } case OP_OPEN: // Match subexpression if ((program.flags & REProgram.OPT_HASBACKREFS) != 0) { startBackref[opdata] = idx; } if ((idxNew = matchNodes(next, maxNode, idx)) != -1) { // Increase valid paren count if (opdata >= parenCount) { parenCount = opdata + 1; } // Don't set paren if already set later on if (getParenStart(opdata) == -1) { setParenStart(opdata, idx); } } return idxNew; case OP_CLOSE: // Done matching subexpression if ((program.flags & REProgram.OPT_HASBACKREFS) != 0) { endBackref[opdata] = idx; } if ((idxNew = matchNodes(next, maxNode, idx)) != -1) { // Increase valid paren count if (opdata >= parenCount) { parenCount = opdata + 1; } // Don't set paren if already set later on if (getParenEnd(opdata) == -1) { setParenEnd(opdata, idx); } } return idxNew; case OP_BACKREF: { // Get the start and end of the backref int s = startBackref[opdata]; int e = endBackref[opdata]; // We don't know the backref yet if (s == -1 || e == -1) { return -1; } // The backref is empty size if (s == e) { break; } // Get the length of the backref int l = e - s; // If there's not enough input left, give up. if (search.isEnd(idx + l - 1)) { return -1; } // Case fold the backref? final boolean caseFold = ((matchFlags & MATCH_CASEINDEPENDENT) != 0); // Compare backref to input for (int i = 0; i < l; i++) { if (compareChars(search.charAt(idx++), search.charAt(s + i), caseFold) != 0) { return -1; } } } break; case OP_BOL: // Fail if we're not at the start of the string if (idx != 0) { // If we're multiline matching, we could still be at the start of a line if ((matchFlags & MATCH_MULTILINE) == MATCH_MULTILINE) { // Continue if at the start of a line if (isNewline(idx - 1)) { break; } } return -1; } break; case OP_EOL: // If we're not at the end of string if (!search.isEnd(0) && !search.isEnd(idx)) { // If we're multi-line matching if ((matchFlags & MATCH_MULTILINE) == MATCH_MULTILINE) { // Continue if we're at the end of a line if (isNewline(idx)) { break; } } return -1; } break; case OP_ESCAPE: // Which escape? switch (opdata) { // Word boundary match case E_NBOUND: case E_BOUND: { char cLast = ((idx == 0) ? '\n' : search.charAt(idx - 1)); char cNext = ((search.isEnd(idx)) ? '\n' : search.charAt(idx)); if ((Character.isLetterOrDigit(cLast) == Character.isLetterOrDigit(cNext)) == (opdata == E_BOUND)) { return -1; } } break; // Alpha-numeric, digit, space, javaLetter, javaLetterOrDigit case E_ALNUM: case E_NALNUM: case E_DIGIT: case E_NDIGIT: case E_SPACE: case E_NSPACE: // Give up if out of input if (search.isEnd(idx)) { return -1; } char c = search.charAt(idx); // Switch on escape switch (opdata) { case E_ALNUM: case E_NALNUM: if (!((Character.isLetterOrDigit(c) || c == '_') == (opdata == E_ALNUM))) { return -1; } break; case E_DIGIT: case E_NDIGIT: if (!(Character.isDigit(c) == (opdata == E_DIGIT))) { return -1; } break; case E_SPACE: case E_NSPACE: if (!(Character.isWhitespace(c) == (opdata == E_SPACE))) { return -1; } break; } idx++; break; default: internalError("Unrecognized escape '" + opdata + "'"); } break; case OP_ANY: if ((matchFlags & MATCH_SINGLELINE) == MATCH_SINGLELINE) { // Match anything if (search.isEnd(idx)) { return -1; } } else { // Match anything but a newline if (search.isEnd(idx) || isNewline(idx)) { return -1; } } idx++; break; case OP_ATOM: { // Match an atom value if (search.isEnd(idx)) { return -1; } // Get length of atom and starting index // int lenAtom = opdata; int startAtom = node + nodeSize; // Give up if not enough input remains to have a match if (search.isEnd(opdata + idx - 1)) { return -1; } // Match atom differently depending on casefolding flag final boolean caseFold = ((matchFlags & MATCH_CASEINDEPENDENT) != 0); for (int i = 0; i < opdata; i++) { if (compareChars(search.charAt(idx++), instruction[startAtom + i], caseFold) != 0) { return -1; } } } break; case OP_POSIXCLASS: { // Out of input? if (search.isEnd(idx)) { return -1; } switch (opdata) { case POSIX_CLASS_ALNUM: if (!Character.isLetterOrDigit(search.charAt(idx))) { return -1; } break; case POSIX_CLASS_ALPHA: if (!Character.isLetter(search.charAt(idx))) { return -1; } break; case POSIX_CLASS_DIGIT: if (!Character.isDigit(search.charAt(idx))) { return -1; } break; case POSIX_CLASS_BLANK: // JWL - bugbug: is this right?? if (!Character.isSpaceChar(search.charAt(idx))) { return -1; } break; case POSIX_CLASS_SPACE: if (!Character.isWhitespace(search.charAt(idx))) { return -1; } break; case POSIX_CLASS_CNTRL: if (Character.getType(search.charAt(idx)) != Character.CONTROL) { return -1; } break; case POSIX_CLASS_GRAPH: // JWL - bugbug??? switch (Character.getType(search.charAt(idx))) { case Character.MATH_SYMBOL: case Character.CURRENCY_SYMBOL: case Character.MODIFIER_SYMBOL: case Character.OTHER_SYMBOL: break; default: return -1; } break; case POSIX_CLASS_LOWER: if (Character.getType(search.charAt(idx)) != Character.LOWERCASE_LETTER) { return -1; } break; case POSIX_CLASS_UPPER: if (Character.getType(search.charAt(idx)) != Character.UPPERCASE_LETTER) { return -1; } break; case POSIX_CLASS_PRINT: if (Character.getType(search.charAt(idx)) == Character.CONTROL) { return -1; } break; case POSIX_CLASS_PUNCT: { int type = Character.getType(search.charAt(idx)); switch(type) { case Character.DASH_PUNCTUATION: case Character.START_PUNCTUATION: case Character.END_PUNCTUATION: case Character.CONNECTOR_PUNCTUATION: case Character.OTHER_PUNCTUATION: break; default: return -1; } } break; case POSIX_CLASS_XDIGIT: // JWL - bugbug?? { boolean isXDigit = ((search.charAt(idx) >= '0' && search.charAt(idx) <= '9') || (search.charAt(idx) >= 'a' && search.charAt(idx) <= 'f') || (search.charAt(idx) >= 'A' && search.charAt(idx) <= 'F')); if (!isXDigit) { return -1; } } break; case POSIX_CLASS_JSTART: if (!Character.isJavaIdentifierStart(search.charAt(idx))) { return -1; } break; case POSIX_CLASS_JPART: if (!Character.isJavaIdentifierPart(search.charAt(idx))) { return -1; } break; default: internalError("Bad posix class"); break; } // Matched. idx++; } break; case OP_ANYOF: { // Out of input? if (search.isEnd(idx)) { return -1; } // Get character to match against character class and maybe casefold char c = search.charAt(idx); boolean caseFold = (matchFlags & MATCH_CASEINDEPENDENT) != 0; // Loop through character class checking our match character int idxRange = node + nodeSize; int idxEnd = idxRange + (opdata * 2); boolean match = false; for (int i = idxRange; !match && i < idxEnd; ) { // Get start, end and match characters char s = instruction[i++]; char e = instruction[i++]; match = ((compareChars(c, s, caseFold) >= 0) && (compareChars(c, e, caseFold) <= 0)); } // Fail if we didn't match the character class if (!match) { return -1; } idx++; } break; case OP_BRANCH: { // Check for choices // FIXME Dead code - only reason to keep is backward compat with pre-compiled exprs. Remove? if (instruction[next /* + offsetOpcode */] != OP_BRANCH) { // If there aren't any other choices, just evaluate this branch. node += nodeSize; continue; } // Try all available branches int nextBranch; do { // Try matching the branch against the string if ((idxNew = matchNodes(node + nodeSize, maxNode, idx)) != -1) { return idxNew; } // Go to next branch (if any) nextBranch = (short) instruction[node + offsetNext]; node += nextBranch; } while (nextBranch != 0 && (instruction[node /* + offsetOpcode */] == OP_BRANCH)); // Failed to match any branch! return -1; } case OP_OPEN_CLUSTER: case OP_CLOSE_CLUSTER: // starting or ending the matching of a subexpression which has no backref. case OP_NOTHING: case OP_GOTO: // Just advance to the next node without doing anything break; case OP_CONTINUE: // Advance to the following node node += nodeSize; continue; case OP_END: // Match has succeeded! setParenEnd(0, idx); return idx; default: // Corrupt program internalError("Invalid opcode '" + opcode + "'"); } // Advance to the next node in the program node = next; } // We "should" never end up here internalError("Corrupt program"); return -1; } /** * Match the current regular expression program against the current * input string, starting at index i of the input string. This method * is only meant for internal use. * * @param i The input string index to start matching at * @return True if the input matched the expression */ protected boolean matchAt(int i) { // Initialize start pointer, paren cache and paren count start0 = -1; end0 = -1; start1 = -1; end1 = -1; start2 = -1; end2 = -1; startn = null; endn = null; parenCount = 1; setParenStart(0, i); // Allocate backref arrays (unless optimizations indicate otherwise) if ((program.flags & REProgram.OPT_HASBACKREFS) != 0) { startBackref = new int[maxParen]; endBackref = new int[maxParen]; } // Match against string int idx; if ((idx = matchNodes(0, maxNode, i)) != -1) { setParenEnd(0, idx); return true; } // Didn't match parenCount = 0; return false; } /** * Matches the current regular expression program against a character array, * starting at a given index. * * @param search String to match against * @param i Index to start searching at * @return True if string matched */ public boolean match(String search, int i) { return match(new StringCharacterIterator(search), i); } /** * Matches the current regular expression program against a character array, * starting at a given index. * * @param search String to match against * @param i Index to start searching at * @return True if string matched */ public boolean match(CharacterIterator search, int i) { // There is no compiled program to search with! if (program == null) { // This should be uncommon enough to be an error case rather // than an exception (which would have to be handled everywhere) internalError("No RE program to run!"); } // Save string to search this.search = search; // Can we optimize the search by looking for new lines? if ((program.flags & REProgram.OPT_HASBOL) == REProgram.OPT_HASBOL) { // Non multi-line matching with BOL: Must match at '0' index if ((matchFlags & MATCH_MULTILINE) == 0) { return i == 0 && matchAt(i); } // Multi-line matching with BOL: Seek to next line for ( ;! search.isEnd(i); i++) { // Skip if we are at the beginning of the line if (isNewline(i)) { continue; } // Match at the beginning of the line if (matchAt(i)) { return true; } // Skip to the end of line for ( ;! search.isEnd(i); i++) { if (isNewline(i)) { break; } } } return false; } // Can we optimize the search by looking for a prefix string? if (program.prefix == null) { // Unprefixed matching must try for a match at each character for ( ;! search.isEnd(i - 1); i++) { // Try a match at index i if (matchAt(i)) { return true; } } return false; } else { // Prefix-anchored matching is possible boolean caseIndependent = (matchFlags & MATCH_CASEINDEPENDENT) != 0; char[] prefix = program.prefix; for ( ; !search.isEnd(i + prefix.length - 1); i++) { int j = i; int k = 0; boolean match; do { // If there's a mismatch of any character in the prefix, give up match = (compareChars(search.charAt(j++), prefix[k++], caseIndependent) == 0); } while (match && k < prefix.length); // See if the whole prefix string matched if (k == prefix.length) { // We matched the full prefix at firstChar, so try it if (matchAt(i)) { return true; } } } return false; } } /** * Matches the current regular expression program against a String. * * @param search String to match against * @return True if string matched */ public boolean match(String search) { return match(search, 0); } /** * Splits a string into an array of strings on regular expression boundaries. * This function works the same way as the Perl function of the same name. * Given a regular expression of "[ab]+" and a string to split of * "xyzzyababbayyzabbbab123", the result would be the array of Strings * "[xyzzy, yyz, 123]". * *

Please note that the first string in the resulting array may be an empty * string. This happens when the very first character of input string is * matched by the pattern. * * @param s String to split on this regular exression * @return Array of strings */ public String[] split(String s) { // Create new vector Vector v = new Vector(); // Start at position 0 and search the whole string int pos = 0; int len = s.length(); // Try a match at each position while (pos < len && match(s, pos)) { // Get start of match int start = getParenStart(0); // Get end of match int newpos = getParenEnd(0); // Check if no progress was made if (newpos == pos) { v.addElement(s.substring(pos, start + 1)); newpos++; } else { v.addElement(s.substring(pos, start)); } // Move to new position pos = newpos; } // Push remainder if it's not empty String remainder = s.substring(pos); if (remainder.length() != 0) { v.addElement(remainder); } // Return vector as an array of strings String[] ret = new String[v.size()]; v.copyInto(ret); return ret; } /** * Flag bit that indicates that subst should replace all occurrences of this * regular expression. */ public static final int REPLACE_ALL = 0x0000; /** * Flag bit that indicates that subst should only replace the first occurrence * of this regular expression. */ public static final int REPLACE_FIRSTONLY = 0x0001; /** * Flag bit that indicates that subst should replace backreferences */ public static final int REPLACE_BACKREFERENCES = 0x0002; /** * Substitutes a string for this regular expression in another string. * This method works like the Perl function of the same name. * Given a regular expression of "a*b", a String to substituteIn of * "aaaabfooaaabgarplyaaabwackyb" and the substitution String "-", the * resulting String returned by subst would be "-foo-garply-wacky-". * * @param substituteIn String to substitute within * @param substitution String to substitute for all matches of this regular expression. * @return The string substituteIn with zero or more occurrences of the current * regular expression replaced with the substitution String (if this regular * expression object doesn't match at any position, the original String is returned * unchanged). */ public String subst(String substituteIn, String substitution) { return subst(substituteIn, substitution, REPLACE_ALL); } /** * Substitutes a string for this regular expression in another string. * This method works like the Perl function of the same name. * Given a regular expression of "a*b", a String to substituteIn of * "aaaabfooaaabgarplyaaabwackyb" and the substitution String "-", the * resulting String returned by subst would be "-foo-garply-wacky-". *

* It is also possible to reference the contents of a parenthesized expression * with $0, $1, ... $9. A regular expression of "http://[\\.\\w\\-\\?/~_@&=%]+", * a String to substituteIn of "visit us: http://www.apache.org!" and the * substitution String "<a href=\"$0\">$0</a>", the resulting String * returned by subst would be * "visit us: <a href=\"http://www.apache.org\">http://www.apache.org</a>!". *

* Note: $0 represents the whole match. * * @param substituteIn String to substitute within * @param substitution String to substitute for matches of this regular expression * @param flags One or more bitwise flags from REPLACE_*. If the REPLACE_FIRSTONLY * flag bit is set, only the first occurrence of this regular expression is replaced. * If the bit is not set (REPLACE_ALL), all occurrences of this pattern will be * replaced. If the flag REPLACE_BACKREFERENCES is set, all backreferences will * be processed. * @return The string substituteIn with zero or more occurrences of the current * regular expression replaced with the substitution String (if this regular * expression object doesn't match at any position, the original String is returned * unchanged). */ public String subst(String substituteIn, String substitution, int flags) { // String to return StringBuffer ret = new StringBuffer(); // Start at position 0 and search the whole string int pos = 0; int len = substituteIn.length(); // Try a match at each position while (pos < len && match(substituteIn, pos)) { // Append string before match ret.append(substituteIn.substring(pos, getParenStart(0))); if ((flags & REPLACE_BACKREFERENCES) != 0) { // Process backreferences int lCurrentPosition = 0; int lLastPosition = -2; int lLength = substitution.length(); while ((lCurrentPosition = substitution.indexOf("$", lCurrentPosition)) >= 0) { if ((lCurrentPosition == 0 || substitution.charAt(lCurrentPosition - 1) != '\\') && lCurrentPosition + 1 < lLength) { char c = substitution.charAt(lCurrentPosition + 1); if (c >= '0' && c <= '9') { // Append everything between the last and the current $ sign ret.append(substitution.substring(lLastPosition + 2, lCurrentPosition)); // Append the parenthesized expression, if present String val = getParen(c - '0'); if (val != null) { ret.append(val); } lLastPosition = lCurrentPosition; } } // Move forward, skipping past match lCurrentPosition++; } // Append everything after the last $ sign ret.append(substitution.substring(lLastPosition + 2, lLength)); } else { // Append substitution without processing backreferences ret.append(substitution); } // Move forward, skipping past match int newpos = getParenEnd(0); // We always want to make progress! if (newpos == pos) { newpos++; } // Try new position pos = newpos; // Break out if we're only supposed to replace one occurrence if ((flags & REPLACE_FIRSTONLY) != 0) { break; } } // If there's remaining input, append it if (pos < len) { ret.append(substituteIn.substring(pos)); } // Return string buffer as string return ret.toString(); } /** * Returns an array of Strings, whose toString representation matches a regular * expression. This method works like the Perl function of the same name. Given * a regular expression of "a*b" and an array of String objects of [foo, aab, zzz, * aaaab], the array of Strings returned by grep would be [aab, aaaab]. * * @param search Array of Objects to search * @return Array of Strings whose toString() value matches this regular expression. */ public String[] grep(Object[] search) { // Create new vector to hold return items Vector v = new Vector(); // Traverse array of objects for (int i = 0; i < search.length; i++) { // Get next object as a string String s = search[i].toString(); // If it matches this regexp, add it to the list if (match(s)) { v.addElement(s); } } // Return vector as an array of strings String[] ret = new String[v.size()]; v.copyInto(ret); return ret; } /** * @return true if character at i-th position in the search string is a newline */ private boolean isNewline(int i) { char nextChar = search.charAt(i); return nextChar == '\n' || nextChar == '\r' || nextChar == '\u0085' || nextChar == '\u2028' || nextChar == '\u2029'; } /** * Compares two characters. * * @param c1 first character to compare. * @param c2 second character to compare. * @param caseIndependent whether comparision is case insensitive or not. * @return negative, 0, or positive integer as the first character * less than, equal to, or greater then the second. */ private int compareChars(char c1, char c2, boolean caseIndependent) { if (caseIndependent) { c1 = Character.toLowerCase(c1); c2 = Character.toLowerCase(c2); } return ((int)c1 - (int)c2); } } jakarta-regexp-1.5/src/java/org/apache/regexp/RECompiler.java100644 0 0 141413 10577337776 21363 0ustar 0 0 /* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.regexp; import java.util.Hashtable; /** * A regular expression compiler class. This class compiles a pattern string into a * regular expression program interpretable by the RE evaluator class. The 'recompile' * command line tool uses this compiler to pre-compile regular expressions for use * with RE. For a description of the syntax accepted by RECompiler and what you can * do with regular expressions, see the documentation for the RE matcher class. * * @see RE * @see recompile * * @author Jonathan Locke * @author Michael McCallum * @version $Id: RECompiler.java 518156 2007-03-14 14:31:26Z vgritsenko $ */ public class RECompiler { // The compiled program char[] instruction; // The compiled RE 'program' instruction buffer int lenInstruction; // The amount of the program buffer currently in use // Input state for compiling regular expression String pattern; // Input string int len; // Length of the pattern string int idx; // Current input index into ac int parens; // Total number of paren pairs // Node flags static final int NODE_NORMAL = 0; // No flags (nothing special) static final int NODE_NULLABLE = 1; // True if node is potentially null static final int NODE_TOPLEVEL = 2; // True if top level expr // Special types of 'escapes' static final int ESC_MASK = 0xffff0; // Escape complexity mask static final int ESC_BACKREF = 0xfffff; // Escape is really a backreference static final int ESC_COMPLEX = 0xffffe; // Escape isn't really a true character static final int ESC_CLASS = 0xffffd; // Escape represents a whole class of characters // {m,n} stacks static final int bracketUnbounded = -1; // Unbounded value int bracketMin; // Minimum number of matches int bracketOpt; // Additional optional matches // Lookup table for POSIX character class names static final Hashtable hashPOSIX = new Hashtable(); static { hashPOSIX.put("alnum", new Character(RE.POSIX_CLASS_ALNUM)); hashPOSIX.put("alpha", new Character(RE.POSIX_CLASS_ALPHA)); hashPOSIX.put("blank", new Character(RE.POSIX_CLASS_BLANK)); hashPOSIX.put("cntrl", new Character(RE.POSIX_CLASS_CNTRL)); hashPOSIX.put("digit", new Character(RE.POSIX_CLASS_DIGIT)); hashPOSIX.put("graph", new Character(RE.POSIX_CLASS_GRAPH)); hashPOSIX.put("lower", new Character(RE.POSIX_CLASS_LOWER)); hashPOSIX.put("print", new Character(RE.POSIX_CLASS_PRINT)); hashPOSIX.put("punct", new Character(RE.POSIX_CLASS_PUNCT)); hashPOSIX.put("space", new Character(RE.POSIX_CLASS_SPACE)); hashPOSIX.put("upper", new Character(RE.POSIX_CLASS_UPPER)); hashPOSIX.put("xdigit", new Character(RE.POSIX_CLASS_XDIGIT)); hashPOSIX.put("javastart", new Character(RE.POSIX_CLASS_JSTART)); hashPOSIX.put("javapart", new Character(RE.POSIX_CLASS_JPART)); } /** * Constructor. Creates (initially empty) storage for a regular expression program. */ public RECompiler() { // Start off with a generous, yet reasonable, initial size instruction = new char[128]; lenInstruction = 0; } /** * Ensures that n more characters can fit in the program buffer. * If n more can't fit, then the size is doubled until it can. * @param n Number of additional characters to ensure will fit. */ void ensure(int n) { // Get current program length int curlen = instruction.length; // If the current length + n more is too much if (lenInstruction + n >= curlen) { // Double the size of the program array until n more will fit while (lenInstruction + n >= curlen) { curlen *= 2; } // Allocate new program array and move data into it char[] newInstruction = new char[curlen]; System.arraycopy(instruction, 0, newInstruction, 0, lenInstruction); instruction = newInstruction; } } /** * Emit a single character into the program stream. * @param c Character to add */ void emit(char c) { // Make room for character ensure(1); // Add character instruction[lenInstruction++] = c; } /** * Inserts a node with a given opcode and opdata at insertAt. The node relative next * pointer is initialized to 0. * @param opcode Opcode for new node * @param opdata Opdata for new node (only the low 16 bits are currently used) * @param insertAt Index at which to insert the new node in the program */ void nodeInsert(char opcode, int opdata, int insertAt) { // Make room for a new node ensure(RE.nodeSize); // Move everything from insertAt to the end down nodeSize elements System.arraycopy(instruction, insertAt, instruction, insertAt + RE.nodeSize, lenInstruction - insertAt); instruction[insertAt /* + RE.offsetOpcode */] = opcode; instruction[insertAt + RE.offsetOpdata ] = (char) opdata; instruction[insertAt + RE.offsetNext ] = 0; lenInstruction += RE.nodeSize; } /** * Appends a node to the end of a node chain * @param node Start of node chain to traverse * @param pointTo Node to have the tail of the chain point to */ void setNextOfEnd(int node, int pointTo) { // Traverse the chain until the next offset is 0 int next = instruction[node + RE.offsetNext]; // while the 'node' is not the last in the chain // and the 'node' is not the last in the program. while ( next != 0 && node < lenInstruction ) { // if the node we are supposed to point to is in the chain then // point to the end of the program instead. // Michael McCallum // FIXME: This is a _hack_ to stop infinite programs. // I believe that the implementation of the reluctant matches is wrong but // have not worked out a better way yet. if (node == pointTo) { pointTo = lenInstruction; } node += next; next = instruction[node + RE.offsetNext]; } // if we have reached the end of the program then dont set the pointTo. // im not sure if this will break any thing but passes all the tests. if ( node < lenInstruction ) { // Some patterns result in very large programs which exceed // capacity of the short used for specifying signed offset of the // next instruction. Example: a{1638} int offset = pointTo - node; if (offset != (short) offset) { throw new RESyntaxException("Exceeded short jump range."); } // Point the last node in the chain to pointTo. instruction[node + RE.offsetNext] = (char) (short) offset; } } /** * Adds a new node * @param opcode Opcode for node * @param opdata Opdata for node (only the low 16 bits are currently used) * @return Index of new node in program */ int node(char opcode, int opdata) { // Make room for a new node ensure(RE.nodeSize); // Add new node at end instruction[lenInstruction /* + RE.offsetOpcode */] = opcode; instruction[lenInstruction + RE.offsetOpdata ] = (char) opdata; instruction[lenInstruction + RE.offsetNext ] = 0; lenInstruction += RE.nodeSize; // Return index of new node return lenInstruction - RE.nodeSize; } /** * Throws a new internal error exception * @exception Error Thrown in the event of an internal error. */ void internalError() throws Error { throw new Error("Internal error!"); } /** * Throws a new syntax error exception * @exception RESyntaxException Thrown if the regular expression has invalid syntax. */ void syntaxError(String s) throws RESyntaxException { throw new RESyntaxException(s); } /** * Match bracket {m,n} expression put results in bracket member variables * @exception RESyntaxException Thrown if the regular expression has invalid syntax. */ void bracket() throws RESyntaxException { // Current character must be a '{' if (idx >= len || pattern.charAt(idx++) != '{') { internalError(); } // Next char must be a digit if (idx >= len || !Character.isDigit(pattern.charAt(idx))) { syntaxError("Expected digit"); } // Get min ('m' of {m,n}) number StringBuffer number = new StringBuffer(); while (idx < len && Character.isDigit(pattern.charAt(idx))) { number.append(pattern.charAt(idx++)); } try { bracketMin = Integer.parseInt(number.toString()); } catch (NumberFormatException e) { syntaxError("Expected valid number"); } // If out of input, fail if (idx >= len) { syntaxError("Expected comma or right bracket"); } // If end of expr, optional limit is 0 if (pattern.charAt(idx) == '}') { idx++; bracketOpt = 0; return; } // Must have at least {m,} and maybe {m,n}. if (idx >= len || pattern.charAt(idx++) != ',') { syntaxError("Expected comma"); } // If out of input, fail if (idx >= len) { syntaxError("Expected comma or right bracket"); } // If {m,} max is unlimited if (pattern.charAt(idx) == '}') { idx++; bracketOpt = bracketUnbounded; return; } // Next char must be a digit if (idx >= len || !Character.isDigit(pattern.charAt(idx))) { syntaxError("Expected digit"); } // Get max number number.setLength(0); while (idx < len && Character.isDigit(pattern.charAt(idx))) { number.append(pattern.charAt(idx++)); } try { bracketOpt = Integer.parseInt(number.toString()) - bracketMin; } catch (NumberFormatException e) { syntaxError("Expected valid number"); } // Optional repetitions must be >= 0 if (bracketOpt < 0) { syntaxError("Bad range"); } // Must have close brace if (idx >= len || pattern.charAt(idx++) != '}') { syntaxError("Missing close brace"); } } /** * Match an escape sequence. Handles quoted chars and octal escapes as well * as normal escape characters. Always advances the input stream by the * right amount. This code "understands" the subtle difference between an * octal escape and a backref. You can access the type of ESC_CLASS or * ESC_COMPLEX or ESC_BACKREF by looking at pattern[idx - 1]. * @return ESC_* code or character if simple escape * @exception RESyntaxException Thrown if the regular expression has invalid syntax. */ int escape() throws RESyntaxException { // "Shouldn't" happen if (pattern.charAt(idx) != '\\') { internalError(); } // Escape shouldn't occur as last character in string! if (idx + 1 == len) { syntaxError("Escape terminates string"); } // Switch on character after backslash idx += 2; char escapeChar = pattern.charAt(idx - 1); switch (escapeChar) { case RE.E_BOUND: case RE.E_NBOUND: return ESC_COMPLEX; case RE.E_ALNUM: case RE.E_NALNUM: case RE.E_SPACE: case RE.E_NSPACE: case RE.E_DIGIT: case RE.E_NDIGIT: return ESC_CLASS; case 'u': case 'x': { // Exact required hex digits for escape type int hexDigits = (escapeChar == 'u' ? 4 : 2); // Parse up to hexDigits characters from input int val = 0; for ( ; idx < len && hexDigits-- > 0; idx++) { // Get char char c = pattern.charAt(idx); // If it's a hexadecimal digit (0-9) if (c >= '0' && c <= '9') { // Compute new value val = (val << 4) + c - '0'; } else { // If it's a hexadecimal letter (a-f) c = Character.toLowerCase(c); if (c >= 'a' && c <= 'f') { // Compute new value val = (val << 4) + (c - 'a') + 10; } else { // If it's not a valid digit or hex letter, the escape must be invalid // because hexDigits of input have not been absorbed yet. syntaxError("Expected " + hexDigits + " hexadecimal digits after \\" + escapeChar); } } } return val; } case 't': return '\t'; case 'n': return '\n'; case 'r': return '\r'; case 'f': return '\f'; case '0': case '1': case '2': case '3': case '4': case '5': case '6': case '7': case '8': case '9': // An octal escape starts with a 0 or has two digits in a row if ((idx < len && Character.isDigit(pattern.charAt(idx))) || escapeChar == '0') { // Handle \nnn octal escapes int val = escapeChar - '0'; if (idx < len && Character.isDigit(pattern.charAt(idx))) { val = ((val << 3) + (pattern.charAt(idx++) - '0')); if (idx < len && Character.isDigit(pattern.charAt(idx))) { val = ((val << 3) + (pattern.charAt(idx++) - '0')); } } return val; } // It's actually a backreference (\[1-9]), not an escape return ESC_BACKREF; default: // Simple quoting of a character return escapeChar; } } /** * Compile a character class * @return Index of class node * @exception RESyntaxException Thrown if the regular expression has invalid syntax. */ int characterClass() throws RESyntaxException { // Check for bad calling or empty class if (pattern.charAt(idx) != '[') { internalError(); } // Check for unterminated or empty class if ((idx + 1) >= len || pattern.charAt(++idx) == ']') { syntaxError("Empty or unterminated class"); } // Check for POSIX character class if (idx < len && pattern.charAt(idx) == ':') { // Skip colon idx++; // POSIX character classes are denoted with lowercase ASCII strings int idxStart = idx; while (idx < len && pattern.charAt(idx) >= 'a' && pattern.charAt(idx) <= 'z') { idx++; } // Should be a ":]" to terminate the POSIX character class if ((idx + 1) < len && pattern.charAt(idx) == ':' && pattern.charAt(idx + 1) == ']') { // Get character class String charClass = pattern.substring(idxStart, idx); // Select the POSIX class id Character i = (Character)hashPOSIX.get(charClass); if (i != null) { // Move past colon and right bracket idx += 2; // Return new POSIX character class node return node(RE.OP_POSIXCLASS, i.charValue()); } syntaxError("Invalid POSIX character class '" + charClass + "'"); } syntaxError("Invalid POSIX character class syntax"); } // Try to build a class. Create OP_ANYOF node int ret = node(RE.OP_ANYOF, 0); // Parse class declaration char CHAR_INVALID = Character.MAX_VALUE; char last = CHAR_INVALID; char simpleChar; boolean include = true; boolean definingRange = false; int idxFirst = idx; char rangeStart = Character.MIN_VALUE; char rangeEnd; RERange range = new RERange(); while (idx < len && pattern.charAt(idx) != ']') { switchOnCharacter: // Switch on character switch (pattern.charAt(idx)) { case '^': include = !include; if (idx == idxFirst) { range.include(Character.MIN_VALUE, Character.MAX_VALUE, true); } idx++; continue; case '\\': { // Escape always advances the stream int c; switch (c = escape ()) { case ESC_COMPLEX: case ESC_BACKREF: // Word boundaries and backrefs not allowed in a character class! syntaxError("Bad character class"); case ESC_CLASS: // Classes can't be an endpoint of a range if (definingRange) { syntaxError("Bad character class"); } // Handle specific type of class (some are ok) switch (pattern.charAt(idx - 1)) { case RE.E_NSPACE: range.include(Character.MIN_VALUE, 7, include); // [Min - \b ) range.include((char) 11, include); // ( \n - \f ) range.include(14, 31, include); // ( \r - ' ') range.include(33, Character.MAX_VALUE, include); // (' ' - Max] break; case RE.E_NALNUM: range.include(Character.MIN_VALUE, '/', include); // [Min - '0') range.include(':', '@', include); // ('9' - 'A') range.include('[', '^', include); // ('Z' - '_') range.include('`', include); // ('_' - 'a') range.include('{', Character.MAX_VALUE, include); // ('z' - Max] break; case RE.E_NDIGIT: range.include(Character.MIN_VALUE, '/', include); // [Min - '0') range.include(':', Character.MAX_VALUE, include); // ('9' - Max] break; case RE.E_SPACE: range.include('\t', include); range.include('\r', include); range.include('\f', include); range.include('\n', include); range.include('\b', include); range.include(' ', include); break; case RE.E_ALNUM: range.include('a', 'z', include); range.include('A', 'Z', include); range.include('_', include); // Fall through! case RE.E_DIGIT: range.include('0', '9', include); break; } // Make last char invalid (can't be a range start) last = CHAR_INVALID; break; default: // Escape is simple so treat as a simple char simpleChar = (char) c; break switchOnCharacter; } } continue; case '-': // Start a range if one isn't already started if (definingRange) { syntaxError("Bad class range"); } definingRange = true; // If no last character, start of range is 0 rangeStart = (last == CHAR_INVALID ? 0 : last); // Premature end of range. define up to Character.MAX_VALUE if ((idx + 1) < len && pattern.charAt(++idx) == ']') { simpleChar = Character.MAX_VALUE; break; } continue; default: simpleChar = pattern.charAt(idx++); break; } // Handle simple character simpleChar if (definingRange) { // if we are defining a range make it now rangeEnd = simpleChar; // Actually create a range if the range is ok if (rangeStart >= rangeEnd) { syntaxError("Bad character class"); } range.include(rangeStart, rangeEnd, include); // We are done defining the range last = CHAR_INVALID; definingRange = false; } else { // If simple character and not start of range, include it if (idx >= len || pattern.charAt(idx) != '-') { range.include(simpleChar, include); } last = simpleChar; } } // Shouldn't be out of input if (idx == len) { syntaxError("Unterminated character class"); } // Absorb the ']' end of class marker idx++; // Emit character class definition instruction[ret + RE.offsetOpdata] = (char)range.num; for (int i = 0; i < range.num; i++) { emit((char)range.minRange[i]); emit((char)range.maxRange[i]); } return ret; } /** * Absorb an atomic character string. This method is a little tricky because * it can un-include the last character of string if a closure operator follows. * This is correct because *+? have higher precedence than concatentation (thus * ABC* means AB(C*) and NOT (ABC)*). * @return Index of new atom node * @exception RESyntaxException Thrown if the regular expression has invalid syntax. */ int atom() throws RESyntaxException { // Create a string node int ret = node(RE.OP_ATOM, 0); // Length of atom int lenAtom = 0; // Loop while we've got input atomLoop: while (idx < len) { // Is there a next char? if ((idx + 1) < len) { char c = pattern.charAt(idx + 1); // If the next 'char' is an escape, look past the whole escape if (pattern.charAt(idx) == '\\') { int idxEscape = idx; escape(); if (idx < len) { c = pattern.charAt(idx); } idx = idxEscape; } // Switch on next char switch (c) { case '{': case '?': case '*': case '+': // If the next character is a closure operator and our atom is non-empty, the // current character should bind to the closure operator rather than the atom if (lenAtom != 0) { break atomLoop; } } } // Switch on current char switch (pattern.charAt(idx)) { case ']': case '^': case '$': case '.': case '[': case '(': case ')': case '|': break atomLoop; case '{': case '?': case '*': case '+': // We should have an atom by now if (lenAtom == 0) { // No atom before closure syntaxError("Missing operand to closure"); } break atomLoop; case '\\': { // Get the escaped character (advances input automatically) int idxBeforeEscape = idx; int c = escape(); // Check if it's a simple escape (as opposed to, say, a backreference) if ((c & ESC_MASK) == ESC_MASK) { // Not a simple escape, so backup to where we were before the escape. idx = idxBeforeEscape; break atomLoop; } // Add escaped char to atom emit((char) c); lenAtom++; } break; default: // Add normal character to atom emit(pattern.charAt(idx++)); lenAtom++; break; } } // This "shouldn't" happen if (lenAtom == 0) { internalError(); } // Emit the atom length into the program instruction[ret + RE.offsetOpdata] = (char)lenAtom; return ret; } /** * Match a terminal node. * @param flags Flags * @return Index of terminal node (closeable) * @exception RESyntaxException Thrown if the regular expression has invalid syntax. */ int terminal(int[] flags) throws RESyntaxException { switch (pattern.charAt(idx)) { case RE.OP_EOL: case RE.OP_BOL: case RE.OP_ANY: return node(pattern.charAt(idx++), 0); case '[': return characterClass(); case '(': return expr(flags); case ')': syntaxError("Unexpected close paren"); case '|': internalError(); case ']': syntaxError("Mismatched class"); case 0: syntaxError("Unexpected end of input"); case '?': case '+': case '{': case '*': syntaxError("Missing operand to closure"); case '\\': { // Don't forget, escape() advances the input stream! int idxBeforeEscape = idx; // Switch on escaped character switch (escape()) { case ESC_CLASS: case ESC_COMPLEX: flags[0] &= ~NODE_NULLABLE; return node(RE.OP_ESCAPE, pattern.charAt(idx - 1)); case ESC_BACKREF: { char backreference = (char)(pattern.charAt(idx - 1) - '0'); if (parens <= backreference) { syntaxError("Bad backreference"); } flags[0] |= NODE_NULLABLE; return node(RE.OP_BACKREF, backreference); } default: // We had a simple escape and we want to have it end up in // an atom, so we back up and fall though to the default handling idx = idxBeforeEscape; flags[0] &= ~NODE_NULLABLE; break; } } } // Everything above either fails or returns. // If it wasn't one of the above, it must be the start of an atom. flags[0] &= ~NODE_NULLABLE; return atom(); } /** * Compile a possibly closured terminal * @param flags Flags passed by reference * @return Index of closured node * @exception RESyntaxException Thrown if the regular expression has invalid syntax. */ int closure(int[] flags) throws RESyntaxException { // Before terminal int idxBeforeTerminal = idx; // Values to pass by reference to terminal() int[] terminalFlags = { NODE_NORMAL }; // Get terminal symbol int ret = terminal(terminalFlags); // Or in flags from terminal symbol flags[0] |= terminalFlags[0]; // Advance input, set NODE_NULLABLE flag and do sanity checks if (idx >= len) { return ret; } boolean greedy = true; char closureType = pattern.charAt(idx); switch (closureType) { case '?': case '*': // The current node can be null flags[0] |= NODE_NULLABLE; // Drop through case '+': // Eat closure character idx++; // Drop through case '{': // Don't allow blantant stupidity int opcode = instruction[ret /* + RE.offsetOpcode */]; if (opcode == RE.OP_BOL || opcode == RE.OP_EOL) { syntaxError("Bad closure operand"); } if ((terminalFlags[0] & NODE_NULLABLE) != 0) { syntaxError("Closure operand can't be nullable"); } } // If the next character is a '?', make the closure non-greedy (reluctant) if (idx < len && pattern.charAt(idx) == '?') { idx++; greedy = false; } if (greedy) { // Actually do the closure now switch (closureType) { case '{': { bracket(); int bracketEnd = idx; int bracketMin = this.bracketMin; int bracketOpt = this.bracketOpt; // Pointer to the last terminal int pos = ret; // Process min first for (int c = 0; c < bracketMin; c++) { // Rewind stream and run it through again - more matchers coming idx = idxBeforeTerminal; setNextOfEnd(pos, pos = terminal(terminalFlags)); } // Do the right thing for maximum ({m,}) if (bracketOpt == bracketUnbounded) { // Drop through now and closure expression. // We are done with the {m,} expr, so skip rest idx = bracketEnd; nodeInsert(RE.OP_STAR, 0, pos); setNextOfEnd(pos + RE.nodeSize, pos); break; } else if (bracketOpt > 0) { int opt[] = new int[bracketOpt + 1]; // Surround first optional terminal with MAYBE nodeInsert(RE.OP_MAYBE, 0, pos); opt[0] = pos; // Add all the rest optional terminals with preceeding MAYBEs for (int c = 1; c < bracketOpt; c++) { opt[c] = node(RE.OP_MAYBE, 0); // Rewind stream and run it through again - more matchers coming idx = idxBeforeTerminal; terminal(terminalFlags); } // Tie ends together int end = opt[bracketOpt] = node(RE.OP_NOTHING, 0); for (int c = 0; c < bracketOpt; c++) { setNextOfEnd(opt[c], end); setNextOfEnd(opt[c] + RE.nodeSize, opt[c + 1]); } } else { // Rollback terminal - no opt matchers present lenInstruction = pos; node(RE.OP_NOTHING, 0); } // We are done. skip the reminder of {m,n} expr idx = bracketEnd; break; } case '?': { nodeInsert(RE.OP_MAYBE, 0, ret); int n = node(RE.OP_NOTHING, 0); setNextOfEnd(ret, n); setNextOfEnd(ret + RE.nodeSize, n); break; } case '*': { nodeInsert(RE.OP_STAR, 0, ret); setNextOfEnd(ret + RE.nodeSize, ret); break; } case '+': { nodeInsert(RE.OP_CONTINUE, 0, ret); int n = node(RE.OP_PLUS, 0); setNextOfEnd(ret + RE.nodeSize, n); setNextOfEnd(n, ret); break; } } } else { // Actually do the closure now switch (closureType) { case '?': { nodeInsert(RE.OP_RELUCTANTMAYBE, 0, ret); int n = node(RE.OP_NOTHING, 0); setNextOfEnd(ret, n); setNextOfEnd(ret + RE.nodeSize, n); break; } case '*': { nodeInsert(RE.OP_RELUCTANTSTAR, 0, ret); setNextOfEnd(ret + RE.nodeSize, ret); break; } case '+': { nodeInsert(RE.OP_CONTINUE, 0, ret); int n = node(RE.OP_RELUCTANTPLUS, 0); setNextOfEnd(n, ret); setNextOfEnd(ret + RE.nodeSize, n); break; } } } return ret; } /** * Compile body of one branch of an or operator (implements concatenation) * * @param flags Flags passed by reference * @return Pointer to first node in the branch * @exception RESyntaxException Thrown if the regular expression has invalid syntax. */ int branch(int[] flags) throws RESyntaxException { // Get each possibly closured piece and concat int node; int ret = -1; int chain = -1; int[] closureFlags = new int[1]; boolean nullable = true; while (idx < len && pattern.charAt(idx) != '|' && pattern.charAt(idx) != ')') { // Get new node closureFlags[0] = NODE_NORMAL; node = closure(closureFlags); if (closureFlags[0] == NODE_NORMAL) { nullable = false; } // If there's a chain, append to the end if (chain != -1) { setNextOfEnd(chain, node); } // Chain starts at current chain = node; if (ret == -1) { ret = node; } } // If we don't run loop, make a nothing node if (ret == -1) { ret = node(RE.OP_NOTHING, 0); } // Set nullable flag for this branch if (nullable) { flags[0] |= NODE_NULLABLE; } return ret; } /** * Compile an expression with possible parens around it. Paren matching * is done at this level so we can tie the branch tails together. * * @param flags Flag value passed by reference * @return Node index of expression in instruction array * @exception RESyntaxException Thrown if the regular expression has invalid syntax. */ int expr(int[] flags) throws RESyntaxException { // Create open paren node unless we were called from the top level (which has no parens) int paren = -1; int ret = -1; int closeParens = parens; if ((flags[0] & NODE_TOPLEVEL) == 0 && pattern.charAt(idx) == '(') { // if its a cluster ( rather than a proper subexpression ie with backrefs ) if (idx + 2 < len && pattern.charAt(idx + 1) == '?' && pattern.charAt(idx + 2) == ':') { paren = 2; idx += 3; ret = node(RE.OP_OPEN_CLUSTER, 0); } else { paren = 1; idx++; ret = node(RE.OP_OPEN, parens++); } } flags[0] &= ~NODE_TOPLEVEL; // Process contents of first branch node boolean open = false; int branch = branch(flags); if (ret == -1) { ret = branch; } else { setNextOfEnd(ret, branch); } // Loop through branches while (idx < len && pattern.charAt(idx) == '|') { // Now open the first branch since there are more than one if (!open) { nodeInsert(RE.OP_BRANCH, 0, branch); open = true; } idx++; setNextOfEnd(branch, branch = node(RE.OP_BRANCH, 0)); branch(flags); } // Create an ending node (either a close paren or an OP_END) int end; if (paren > 0) { if (idx < len && pattern.charAt(idx) == ')') { idx++; } else { syntaxError("Missing close paren"); } if (paren == 1) { end = node(RE.OP_CLOSE, closeParens); } else { end = node(RE.OP_CLOSE_CLUSTER, 0); } } else { end = node(RE.OP_END, 0); } // Append the ending node to the ret nodelist setNextOfEnd(ret, end); // Hook the ends of each branch to the end node int currentNode = ret; int nextNodeOffset = instruction[currentNode + RE.offsetNext]; // while the next node o while (nextNodeOffset != 0 && currentNode < lenInstruction) { // If branch, make the end of the branch's operand chain point to the end node. if (instruction[currentNode /* + RE.offsetOpcode */] == RE.OP_BRANCH) { setNextOfEnd(currentNode + RE.nodeSize, end); } nextNodeOffset = instruction[currentNode + RE.offsetNext]; currentNode += nextNodeOffset; } // Return the node list return ret; } /** * Compiles a regular expression pattern into a program runnable by the pattern * matcher class 'RE'. * @param pattern Regular expression pattern to compile (see RECompiler class * for details). * @return A compiled regular expression program. * @exception RESyntaxException Thrown if the regular expression has invalid syntax. * @see RECompiler * @see RE */ public REProgram compile(String pattern) throws RESyntaxException { // Initialize variables for compilation this.pattern = pattern; // Save pattern in instance variable len = pattern.length(); // Precompute pattern length for speed idx = 0; // Set parsing index to the first character lenInstruction = 0; // Set emitted instruction count to zero parens = 1; // Set paren level to 1 (the implicit outer parens) // Initialize pass by reference flags value int[] flags = { NODE_TOPLEVEL }; // Parse expression expr(flags); // Should be at end of input if (idx != len) { if (pattern.charAt(idx) == ')') { syntaxError("Unmatched close paren"); } syntaxError("Unexpected input remains"); } // Return the result char[] ins = new char[lenInstruction]; System.arraycopy(instruction, 0, ins, 0, lenInstruction); return new REProgram(parens, ins); } /** * Local, nested class for maintaining character ranges for character classes. */ class RERange { int size = 16; // Capacity of current range arrays int[] minRange = new int[size]; // Range minima int[] maxRange = new int[size]; // Range maxima int num = 0; // Number of range array elements in use /** * Deletes the range at a given index from the range lists * @param index Index of range to delete from minRange and maxRange arrays. */ void delete(int index) { // Return if no elements left or index is out of range if (num == 0 || index >= num) { return; } // Move elements down while (++index < num) { if (index - 1 >= 0) { minRange[index-1] = minRange[index]; maxRange[index-1] = maxRange[index]; } } // One less element now num--; } /** * Merges a range into the range list, coalescing ranges if possible. * @param min Minimum end of range * @param max Maximum end of range */ void merge(int min, int max) { // Loop through ranges for (int i = 0; i < num; i++) { // Min-max is subsumed by minRange[i]-maxRange[i] if (min >= minRange[i] && max <= maxRange[i]) { return; } // Min-max subsumes minRange[i]-maxRange[i] else if (min <= minRange[i] && max >= maxRange[i]) { delete(i); merge(min, max); return; } // Min is in the range, but max is outside else if (min >= minRange[i] && min <= maxRange[i]) { min = minRange[i]; delete(i); merge(min, max); return; } // Max is in the range, but min is outside else if (max >= minRange[i] && max <= maxRange[i]) { max = maxRange[i]; delete(i); merge(min, max); return; } } // Must not overlap any other ranges if (num >= size) { size *= 2; int[] newMin = new int[size]; int[] newMax = new int[size]; System.arraycopy(minRange, 0, newMin, 0, num); System.arraycopy(maxRange, 0, newMax, 0, num); minRange = newMin; maxRange = newMax; } minRange[num] = min; maxRange[num] = max; num++; } /** * Removes a range by deleting or shrinking all other ranges * @param min Minimum end of range * @param max Maximum end of range */ void remove(int min, int max) { // Loop through ranges for (int i = 0; i < num; i++) { // minRange[i]-maxRange[i] is subsumed by min-max if (minRange[i] >= min && maxRange[i] <= max) { delete(i); return; } // min-max is subsumed by minRange[i]-maxRange[i] else if (min >= minRange[i] && max <= maxRange[i]) { int minr = minRange[i]; int maxr = maxRange[i]; delete(i); if (minr < min) { merge(minr, min - 1); } if (max < maxr) { merge(max + 1, maxr); } return; } // minRange is in the range, but maxRange is outside else if (minRange[i] >= min && minRange[i] <= max) { minRange[i] = max + 1; return; } // maxRange is in the range, but minRange is outside else if (maxRange[i] >= min && maxRange[i] <= max) { maxRange[i] = min - 1; return; } } } /** * Includes (or excludes) the range from min to max, inclusive. * @param min Minimum end of range * @param max Maximum end of range * @param include True if range should be included. False otherwise. */ void include(int min, int max, boolean include) { if (include) { merge(min, max); } else { remove(min, max); } } /** * Includes a range with the same min and max * @param minmax Minimum and maximum end of range (inclusive) * @param include True if range should be included. False otherwise. */ void include(char minmax, boolean include) { include(minmax, minmax, include); } } } jakarta-regexp-1.5/src/java/org/apache/regexp/REDebugCompiler.java100644 0 0 21714 10577337776 22313 0ustar 0 0 /* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.regexp; import java.io.PrintWriter; import java.util.Hashtable; /** * A subclass of RECompiler which can dump a regular expression program * for debugging purposes. * * @author Jonathan Locke * @version $Id: REDebugCompiler.java 518169 2007-03-14 15:03:35Z vgritsenko $ */ public class REDebugCompiler extends RECompiler { /** * Mapping from opcodes to descriptive strings */ static Hashtable hashOpcode = new Hashtable(); static { hashOpcode.put(new Integer(RE.OP_RELUCTANTSTAR), "OP_RELUCTANTSTAR"); hashOpcode.put(new Integer(RE.OP_RELUCTANTPLUS), "OP_RELUCTANTPLUS"); hashOpcode.put(new Integer(RE.OP_RELUCTANTMAYBE), "OP_RELUCTANTMAYBE"); hashOpcode.put(new Integer(RE.OP_END), "OP_END"); hashOpcode.put(new Integer(RE.OP_BOL), "OP_BOL"); hashOpcode.put(new Integer(RE.OP_EOL), "OP_EOL"); hashOpcode.put(new Integer(RE.OP_ANY), "OP_ANY"); hashOpcode.put(new Integer(RE.OP_ANYOF), "OP_ANYOF"); hashOpcode.put(new Integer(RE.OP_BRANCH), "OP_BRANCH"); hashOpcode.put(new Integer(RE.OP_ATOM), "OP_ATOM"); hashOpcode.put(new Integer(RE.OP_STAR), "OP_STAR"); hashOpcode.put(new Integer(RE.OP_PLUS), "OP_PLUS"); hashOpcode.put(new Integer(RE.OP_MAYBE), "OP_MAYBE"); hashOpcode.put(new Integer(RE.OP_NOTHING), "OP_NOTHING"); hashOpcode.put(new Integer(RE.OP_GOTO), "OP_GOTO"); hashOpcode.put(new Integer(RE.OP_CONTINUE), "OP_CONTINUE"); hashOpcode.put(new Integer(RE.OP_ESCAPE), "OP_ESCAPE"); hashOpcode.put(new Integer(RE.OP_OPEN), "OP_OPEN"); hashOpcode.put(new Integer(RE.OP_CLOSE), "OP_CLOSE"); hashOpcode.put(new Integer(RE.OP_BACKREF), "OP_BACKREF"); hashOpcode.put(new Integer(RE.OP_POSIXCLASS), "OP_POSIXCLASS"); hashOpcode.put(new Integer(RE.OP_OPEN_CLUSTER), "OP_OPEN_CLUSTER"); hashOpcode.put(new Integer(RE.OP_CLOSE_CLUSTER), "OP_CLOSE_CLUSTER"); } /** * Returns a descriptive string for an opcode. * * @param opcode Opcode to convert to a string * @return Description of opcode */ String opcodeToString(char opcode) { // Get string for opcode String ret = (String) hashOpcode.get(new Integer(opcode)); // Just in case we have a corrupt program if (ret == null) { ret = "OP_????"; } return ret; } /** * Return a string describing a (possibly unprintable) character. * * @param c Character to convert to a printable representation * @return String representation of character */ String charToString(char c) { // If it's unprintable, convert to '\###' if (c < ' ' || c > 127) { return "\\" + (int) c; } // Return the character as a string return String.valueOf(c); } /** * Returns a descriptive string for a node in a regular expression program. * @param node Node to describe * @return Description of node */ String nodeToString(int node) { // Get opcode and opdata for node char opcode = instruction[node /* + RE.offsetOpcode */]; int opdata = (int) instruction[node + RE.offsetOpdata ]; // Return opcode as a string and opdata value return opcodeToString(opcode) + ", opdata = " + opdata; } /** * Adds a new node * * @param opcode Opcode for node * @param opdata Opdata for node (only the low 16 bits are currently used) * @return Index of new node in program * / int node(char opcode, int opdata) { System.out.println("====> Add " + opcode + " " + opdata); PrintWriter writer = new PrintWriter(System.out); dumpProgram(writer); writer.flush(); int r = super.node(opcode, opdata); System.out.println("====< "); dumpProgram(writer); writer.flush(); return r; }/**/ /** * Inserts a node with a given opcode and opdata at insertAt. The node relative next * pointer is initialized to 0. * * @param opcode Opcode for new node * @param opdata Opdata for new node (only the low 16 bits are currently used) * @param insertAt Index at which to insert the new node in the program * / void nodeInsert(char opcode, int opdata, int insertAt) { System.out.println("====> Ins " + opcode + " " + opdata + " " + insertAt); PrintWriter writer = new PrintWriter(System.out); dumpProgram(writer); writer.flush(); super.nodeInsert(opcode, opdata, insertAt); System.out.println("====< "); dumpProgram(writer); writer.flush(); }/**/ /** * Appends a node to the end of a node chain * * @param node Start of node chain to traverse * @param pointTo Node to have the tail of the chain point to * / void setNextOfEnd(int node, int pointTo) { System.out.println("====> Link " + node + " " + pointTo); PrintWriter writer = new PrintWriter(System.out); dumpProgram(writer); writer.flush(); super.setNextOfEnd(node, pointTo); System.out.println("====< "); dumpProgram(writer); writer.flush(); }/**/ /** * Dumps the current program to a {@link PrintWriter}. * * @param p PrintWriter for program dump output */ public void dumpProgram(PrintWriter p) { // Loop through the whole program for (int i = 0; i < lenInstruction; ) { // Get opcode, opdata and next fields of current program node char opcode = instruction[i /* + RE.offsetOpcode */]; char opdata = instruction[i + RE.offsetOpdata ]; int next = (short) instruction[i + RE.offsetNext ]; // Display the current program node p.print(i + ". " + nodeToString(i) + ", next = "); // If there's no next, say 'none', otherwise give absolute index of next node if (next == 0) { p.print("none"); } else { p.print(i + next); } // Move past node i += RE.nodeSize; // If character class if (opcode == RE.OP_ANYOF) { // Opening bracket for start of char class p.print(", ["); // Show each range in the char class // int rangeCount = opdata; for (int r = 0; r < opdata; r++) { // Get first and last chars in range char charFirst = instruction[i++]; char charLast = instruction[i++]; // Print range as X-Y, unless range encompasses only one char if (charFirst == charLast) { p.print(charToString(charFirst)); } else { p.print(charToString(charFirst) + "-" + charToString(charLast)); } } // Annotate the end of the char class p.print("]"); } // If atom if (opcode == RE.OP_ATOM) { // Open quote p.print(", \""); // Print each character in the atom for (int len = opdata; len-- != 0; ) { p.print(charToString(instruction[i++])); } // Close quote p.print("\""); } // Print a newline p.println(""); } } /** * Dumps the current program to a System.out. */ public void dumpProgram() { PrintWriter w = new PrintWriter(System.out); dumpProgram(w); w.flush(); } } jakarta-regexp-1.5/src/java/org/apache/regexp/REDemo.java100644 0 0 14623 10577337776 20457 0ustar 0 0 /* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.regexp; import java.applet.Applet; import java.awt.*; import java.awt.event.TextEvent; import java.awt.event.TextListener; import java.awt.event.WindowAdapter; import java.awt.event.WindowEvent; import java.io.CharArrayWriter; import java.io.PrintWriter; /** * Interactive demonstration and testing harness for regular expressions classes. * @author Jonathan Locke * @version $Id: REDemo.java 518156 2007-03-14 14:31:26Z vgritsenko $ */ public class REDemo extends Applet implements TextListener { /** * Matcher and compiler objects */ RE r = new RE(); REDebugCompiler compiler = new REDebugCompiler(); /** * Components */ TextField fieldRE; // Field for entering regexps TextField fieldMatch; // Field for entering match strings TextArea outRE; // Output of RE compiler TextArea outMatch; // Results of matching operation /** * Add controls and init applet */ public void init() { // Add components using the dreaded GridBagLayout GridBagLayout gb = new GridBagLayout(); setLayout(gb); GridBagConstraints c = new GridBagConstraints(); c.insets = new Insets(5, 5, 5, 5); c.anchor = GridBagConstraints.EAST; gb.setConstraints(add(new Label("Regular expression:", Label.RIGHT)), c); c.gridy = 0; c.anchor = GridBagConstraints.WEST; gb.setConstraints(add(fieldRE = new TextField("\\[([:javastart:][:javapart:]*)\\]", 40)), c); c.gridx = 0; c.gridy = GridBagConstraints.RELATIVE; c.anchor = GridBagConstraints.EAST; gb.setConstraints(add(new Label("String:", Label.RIGHT)), c); c.gridy = 1; c.gridx = GridBagConstraints.RELATIVE; c.anchor = GridBagConstraints.WEST; gb.setConstraints(add(fieldMatch = new TextField("aaa([foo])aaa", 40)), c); c.gridy = 2; c.gridx = GridBagConstraints.RELATIVE; c.fill = GridBagConstraints.BOTH; c.weighty = 1.0; c.weightx = 1.0; gb.setConstraints(add(outRE = new TextArea()), c); c.gridy = 2; c.gridx = GridBagConstraints.RELATIVE; gb.setConstraints(add(outMatch = new TextArea()), c); // Listen to text changes fieldRE.addTextListener(this); fieldMatch.addTextListener(this); // Initial UI update textValueChanged(null); } /** * Say something into RE text area * @param s What to say */ void sayRE(String s) { outRE.setText(s); } /** * Say something into match text area * @param s What to say */ void sayMatch(String s) { outMatch.setText(s); } /** * Convert throwable to string * @param t Throwable to convert to string */ String throwableToString(Throwable t) { String s = t.getClass().getName(); String m; if ((m = t.getMessage()) != null) { s += "\n" + m; } return s; } /** * Change regular expression * @param expr Expression to compile */ void updateRE(String expr) { try { // Compile program r.setProgram(compiler.compile(expr)); // Dump program into RE feedback area CharArrayWriter w = new CharArrayWriter(); compiler.dumpProgram(new PrintWriter(w)); sayRE(w.toString()); System.out.println(w); } catch (Exception e) { r.setProgram(null); sayRE(throwableToString(e)); } catch (Throwable t) { r.setProgram(null); sayRE(throwableToString(t)); } } /** * Update matching info by matching the string against the current * compiled regular expression. * @param match String to match against */ void updateMatch(String match) { try { // If the string matches the regexp if (r.match(match)) { // Say that it matches String out = "Matches.\n\n"; // Show contents of parenthesized subexpressions for (int i = 0; i < r.getParenCount(); i++) { out += "$" + i + " = " + r.getParen(i) + "\n"; } sayMatch(out); } else { // Didn't match! sayMatch("Does not match"); } } catch (Throwable t) { sayMatch(throwableToString(t)); } } /** * Called when text values change * @param e TextEvent */ public void textValueChanged(TextEvent e) { // If it's a generic update or the regexp changed... if (e == null || e.getSource() == fieldRE) { // Update regexp updateRE(fieldRE.getText()); } // We always need to update the match results updateMatch(fieldMatch.getText()); } /** * Main application entrypoint. * @param arg Command line arguments */ static public void main(String[] arg) { Frame f = new Frame("RE Demo"); // f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); f.addWindowListener(new WindowAdapter() { public void windowClosing(WindowEvent e) { System.exit(0); } }); REDemo demo = new REDemo(); f.add(demo); demo.init(); f.pack(); f.setVisible(true); } } jakarta-regexp-1.5/src/java/org/apache/regexp/REProgram.java100644 0 0 15333 10577337776 21201 0ustar 0 0 /* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.regexp; import java.io.Serializable; /** * A class that holds compiled regular expressions. This is exposed mainly * for use by the recompile utility (which helps you produce precompiled * REProgram objects). You should not otherwise need to work directly with * this class. * * @see RE * @see RECompiler * * @author Jonathan Locke * @version $Id: REProgram.java 518156 2007-03-14 14:31:26Z vgritsenko $ */ public class REProgram implements Serializable { static final int OPT_HASBACKREFS = 1; static final int OPT_HASBOL = 2; char[] instruction; // The compiled regular expression 'program' int lenInstruction; // The amount of the instruction buffer in use char[] prefix; // Prefix string optimization int flags; // Optimization flags (REProgram.OPT_*) int maxParens = -1; /** * Constructs a program object from a character array * @param instruction Character array with RE opcode instructions in it */ public REProgram(char[] instruction) { this(instruction, instruction.length); } /** * Constructs a program object from a character array * @param parens Count of parens in the program * @param instruction Character array with RE opcode instructions in it */ public REProgram(int parens, char[] instruction) { this(instruction, instruction.length); this.maxParens = parens; } /** * Constructs a program object from a character array * @param instruction Character array with RE opcode instructions in it * @param lenInstruction Amount of instruction array in use */ public REProgram(char[] instruction, int lenInstruction) { setInstructions(instruction, lenInstruction); } /** * Returns a copy of the current regular expression program in a character * array that is exactly the right length to hold the program. If there is * no program compiled yet, getInstructions() will return null. * @return A copy of the current compiled RE program */ public char[] getInstructions() { // Ensure program has been compiled! if (lenInstruction != 0) { // Return copy of program char[] ret = new char[lenInstruction]; System.arraycopy(instruction, 0, ret, 0, lenInstruction); return ret; } return null; } /** * Sets a new regular expression program to run. It is this method which * performs any special compile-time search optimizations. Currently only * two optimizations are in place - one which checks for backreferences * (so that they can be lazily allocated) and another which attempts to * find an prefix anchor string so that substantial amounts of input can * potentially be skipped without running the actual program. * @param instruction Program instruction buffer * @param lenInstruction Length of instruction buffer in use */ public void setInstructions(char[] instruction, int lenInstruction) { // Save reference to instruction array this.instruction = instruction; this.lenInstruction = lenInstruction; // Initialize other program-related variables this.flags = 0; this.prefix = null; // Try various compile-time optimizations if there's a program if (instruction != null && lenInstruction != 0) { // If the first node is a branch if (lenInstruction >= RE.nodeSize && instruction[0 + RE.offsetOpcode] == RE.OP_BRANCH) { // to the end node int next = (short) instruction[0 + RE.offsetNext]; if (instruction[next + RE.offsetOpcode] == RE.OP_END && lenInstruction >= (RE.nodeSize * 2)) { final char nextOp = instruction[RE.nodeSize + RE.offsetOpcode]; // the branch starts with an atom if (nextOp == RE.OP_ATOM) { // then get that atom as an prefix because there's no other choice int lenAtom = instruction[RE.nodeSize + RE.offsetOpdata]; this.prefix = new char[lenAtom]; System.arraycopy(instruction, RE.nodeSize * 2, prefix, 0, lenAtom); } // the branch starts with a BOL else if (nextOp == RE.OP_BOL) { // then set the flag indicating that BOL is present this.flags |= OPT_HASBOL; } } } BackrefScanLoop: // Check for backreferences for (int i = 0; i < lenInstruction; i += RE.nodeSize) { switch (instruction[i + RE.offsetOpcode]) { case RE.OP_ANYOF: i += (instruction[i + RE.offsetOpdata] * 2); break; case RE.OP_ATOM: i += instruction[i + RE.offsetOpdata]; break; case RE.OP_BACKREF: flags |= OPT_HASBACKREFS; break BackrefScanLoop; } } } } /** * Returns a copy of the prefix of current regular expression program * in a character array. If there is no prefix, or there is no program * compiled yet, getPrefix will return null. * @return A copy of the prefix of current compiled RE program */ public char[] getPrefix() { if (prefix != null) { // Return copy of prefix char[] ret = new char[prefix.length]; System.arraycopy(prefix, 0, ret, 0, prefix.length); return ret; } return null; } } jakarta-regexp-1.5/src/java/org/apache/regexp/RESyntaxException.java100644 0 0 3126 10577337776 22714 0ustar 0 0 /* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.regexp; /** * Exception thrown to indicate a syntax error in a regular expression. * This is a non-checked exception because you should only have problems compiling * a regular expression during development. * If you are making regular expresion programs dynamically then you can catch it * if you wish. But should not be forced to. * * @author Jonathan Locke * @author Jonathan Locke * @author Jon S. Stevens * @author Michael McCallum * @version $Id: RETest.java 518156 2007-03-14 14:31:26Z vgritsenko $ */ public class RETest { // True if we want to see output from success cases static final boolean showSuccesses = false; // A new line character. static final String NEW_LINE = System.getProperty("line.separator"); // Construct a debug compiler final REDebugCompiler compiler = new REDebugCompiler(); /** * Main program entrypoint. If an argument is given, it will be compiled * and interactive matching will ensue. If no argument is given, the * file RETest.txt will be used as automated testing input. * @param args Command line arguments (optional regular expression) */ public static void main(String[] args) { try { if (!test( args )) { System.exit(1); } } catch (Exception e) { e.printStackTrace(); System.exit(1); } } /** * Testing entrypoint. * @param args Command line arguments * @exception Exception thrown in case of error */ public static boolean test( String[] args ) throws Exception { RETest test = new RETest(); // Run interactive tests against a single regexp if (args.length == 2) { test.runInteractiveTests(args[1]); } else if (args.length == 1) { // Run automated tests test.runAutomatedTests(args[0]); } else { System.out.println( "Usage: RETest ([-i] [regex]) ([/path/to/testfile.txt])" ); System.out.println( "By Default will run automated tests from file 'docs/RETest.txt' ..." ); System.out.println(); test.runAutomatedTests("docs/RETest.txt"); } return test.failures == 0; } /** * Constructor */ public RETest() { } /** * Compile and test matching against a single expression * @param expr Expression to compile and test */ void runInteractiveTests(String expr) { RE r = new RE(); try { // Compile expression r.setProgram(compiler.compile(expr)); // Show expression say("" + NEW_LINE + "" + expr + "" + NEW_LINE + ""); // Show program for compiled expression PrintWriter writer = new PrintWriter( System.out ); compiler.dumpProgram( writer ); writer.flush(); boolean running = true; // Test matching against compiled expression while ( running ) { // Read from keyboard BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); System.out.print("> "); System.out.flush(); String match = br.readLine(); if ( match != null ) { // Try a match against the keyboard input if (r.match(match)) { say("Match successful."); } else { say("Match failed."); } // Show subparen registers showParens(r); } else { running = false; System.out.println(); } } } catch (Exception e) { say("Error: " + e.toString()); e.printStackTrace(); } } /** * Exit with a fatal error. * @param s Last famous words before exiting */ void die(String s) { say("FATAL ERROR: " + s); System.exit(-1); } /** * Fail with an error. Will print a big failure message to System.out. * * @param log Output before failure * @param s Failure description */ void fail(StringBuffer log, String s) { System.out.print(log.toString()); fail(s); } /** * Fail with an error. Will print a big failure message to System.out. * * @param s Failure description */ void fail(String s) { failures++; say("" + NEW_LINE + ""); say("*******************************************************"); say("********************* FAILURE! **********************"); say("*******************************************************"); say("" + NEW_LINE + ""); say(s); say(""); // make sure the writer gets flushed. compiler.dumpProgram(); say("" + NEW_LINE + ""); } /** * Say something to standard out * @param s What to say */ void say(String s) { System.out.println(s); } /** * Dump parenthesized subexpressions found by a regular expression matcher object * @param r Matcher object with results to show */ void showParens(RE r) { // Loop through each paren for (int i = 0; i < r.getParenCount(); i++) { // Show paren register say("$" + i + " = " + r.getParen(i)); } } /* * number in automated test */ int testCount = 0; /* * Count of failures in automated test */ int failures = 0; /** * Run automated tests in RETest.txt file (from Perl 4.0 test battery) * @exception Exception thrown in case of error */ void runAutomatedTests(String testDocument) throws Exception { long ms = System.currentTimeMillis(); // Some unit tests testPrecompiledRE(); testSplitAndGrep(); testSubst(); testOther(); // Test from script file File testInput = new File(testDocument); if (! testInput.exists()) { throw new Exception ("Could not find: " + testDocument); } BufferedReader br = new BufferedReader(new FileReader(testInput)); try { // While input is available, parse lines while (br.ready()) { RETestCase testcase = getNextTestCase(br); if (testcase != null) { testcase.runTest(); } } } finally { br.close(); } // Show match time say(NEW_LINE + NEW_LINE + "Match time = " + (System.currentTimeMillis() - ms) + " ms."); // Print final results if (failures > 0) { say("*************** THERE ARE FAILURES! *******************"); } say("Tests complete. " + testCount + " tests, " + failures + " failure(s)."); } /** * Run automated unit test * @exception Exception thrown in case of error */ void testOther() throws Exception { // Serialization test 1: Compile regexp and serialize/deserialize it RE r = new RE("(a*)b"); say("Serialized/deserialized (a*)b"); ByteArrayOutputStream out = new ByteArrayOutputStream(128); new ObjectOutputStream(out).writeObject(r); ByteArrayInputStream in = new ByteArrayInputStream(out.toByteArray()); r = (RE)new ObjectInputStream(in).readObject(); if (!r.match("aaab")) { fail("Did not match 'aaab' with deserialized RE."); } else { say("aaaab = true"); showParens(r); } // Serialization test 2: serialize/deserialize used regexp out.reset(); say("Deserialized (a*)b"); new ObjectOutputStream(out).writeObject(r); in = new ByteArrayInputStream(out.toByteArray()); r = (RE)new ObjectInputStream(in).readObject(); if (r.getParenCount() != 0) { fail("Has parens after deserialization."); } if (!r.match("aaab")) { fail("Did not match 'aaab' with deserialized RE."); } else { say("aaaab = true"); showParens(r); } // Test MATCH_CASEINDEPENDENT r = new RE("abc(\\w*)"); say("MATCH_CASEINDEPENDENT abc(\\w*)"); r.setMatchFlags(RE.MATCH_CASEINDEPENDENT); say("abc(d*)"); if (!r.match("abcddd")) { fail("Did not match 'abcddd'."); } else { say("abcddd = true"); showParens(r); } if (!r.match("aBcDDdd")) { fail("Did not match 'aBcDDdd'."); } else { say("aBcDDdd = true"); showParens(r); } if (!r.match("ABCDDDDD")) { fail("Did not match 'ABCDDDDD'."); } else { say("ABCDDDDD = true"); showParens(r); } r = new RE("(A*)b\\1"); r.setMatchFlags(RE.MATCH_CASEINDEPENDENT); if (!r.match("AaAaaaBAAAAAA")) { fail("Did not match 'AaAaaaBAAAAAA'."); } else { say("AaAaaaBAAAAAA = true"); showParens(r); } r = new RE("[A-Z]*"); r.setMatchFlags(RE.MATCH_CASEINDEPENDENT); if (!r.match("CaBgDe12")) { fail("Did not match 'CaBgDe12'."); } else { say("CaBgDe12 = true"); showParens(r); } // Test for eol/bol symbols. r = new RE("^abc$"); if (r.match("\nabc")) { fail("\"\\nabc\" matches \"^abc$\""); } // Test MATCH_MULTILINE. Test for eol/bol symbols. r = new RE("^abc$", RE.MATCH_MULTILINE); if (!r.match("\nabc")) { fail("\"\\nabc\" doesn't match \"^abc$\""); } if (!r.match("\rabc")) { fail("\"\\rabc\" doesn't match \"^abc$\""); } if (!r.match("\r\nabc")) { fail("\"\\r\\nabc\" doesn't match \"^abc$\""); } if (!r.match("\u0085abc")) { fail("\"\\u0085abc\" doesn't match \"^abc$\""); } if (!r.match("\u2028abc")) { fail("\"\\u2028abc\" doesn't match \"^abc$\""); } if (!r.match("\u2029abc")) { fail("\"\\u2029abc\" doesn't match \"^abc$\""); } // Test MATCH_MULTILINE. Test that '.' does not matches new line. r = new RE("^a.*b$", RE.MATCH_MULTILINE); if (r.match("a\nb")) { fail("\"a\\nb\" matches \"^a.*b$\""); } if (r.match("a\rb")) { fail("\"a\\rb\" matches \"^a.*b$\""); } if (r.match("a\r\nb")) { fail("\"a\\r\\nb\" matches \"^a.*b$\""); } if (r.match("a\u0085b")) { fail("\"a\\u0085b\" matches \"^a.*b$\""); } if (r.match("a\u2028b")) { fail("\"a\\u2028b\" matches \"^a.*b$\""); } if (r.match("a\u2029b")) { fail("\"a\\u2029b\" matches \"^a.*b$\""); } // Bug 38331: Large program try { REDebugCompiler c = new REDebugCompiler(); c.compile("(a{8192})?"); fail("(a{8192})? should fail to compile."); c.dumpProgram(); } catch (RESyntaxException e) { // expected } } private void testPrecompiledRE() { // Pre-compiled regular expression "a*b" char[] re1Instructions = { 0x007c, 0x0000, 0x001a, 0x007c, 0x0000, 0x000d, 0x0041, 0x0001, 0x0004, 0x0061, 0x007c, 0x0000, 0x0003, 0x0047, 0x0000, 0xfff6, 0x007c, 0x0000, 0x0003, 0x004e, 0x0000, 0x0003, 0x0041, 0x0001, 0x0004, 0x0062, 0x0045, 0x0000, 0x0000, }; REProgram re1 = new REProgram(re1Instructions); // Simple test of pre-compiled regular expressions RE r = new RE(re1); say("a*b"); boolean result = r.match("aaab"); say("aaab = " + result); showParens(r); if (!result) { fail("\"aaab\" doesn't match to precompiled \"a*b\""); } result = r.match("b"); say("b = " + result); showParens(r); if (!result) { fail("\"b\" doesn't match to precompiled \"a*b\""); } result = r.match("c"); say("c = " + result); showParens(r); if (result) { fail("\"c\" matches to precompiled \"a*b\""); } result = r.match("ccccaaaaab"); say("ccccaaaaab = " + result); showParens(r); if (!result) { fail("\"ccccaaaaab\" doesn't match to precompiled \"a*b\""); } } private void testSplitAndGrep() { String[] expected = {"xxxx", "xxxx", "yyyy", "zzz"}; RE r = new RE("a*b"); String[] s = r.split("xxxxaabxxxxbyyyyaaabzzz"); for (int i = 0; i < expected.length && i < s.length; i++) { assertEquals("Wrong splitted part", expected[i], s[i]); } assertEquals("Wrong number of splitted parts", expected.length, s.length); r = new RE("x+"); expected = new String[] {"xxxx", "xxxx"}; s = r.grep(s); for (int i = 0; i < s.length; i++) { say("s[" + i + "] = " + s[i]); assertEquals("Grep fails", expected[i], s[i]); } assertEquals("Wrong number of string found by grep", expected.length, s.length); } private void testSubst() { RE r = new RE("a*b"); String expected = "-foo-garply-wacky-"; String actual = r.subst("aaaabfooaaabgarplyaaabwackyb", "-"); assertEquals("Wrong result of substitution in \"a*b\"", expected, actual); // Test subst() with backreferences r = new RE("http://[\\.\\w\\-\\?/~_@&=%]+"); actual = r.subst("visit us: http://www.apache.org!", "1234$0", RE.REPLACE_BACKREFERENCES); assertEquals("Wrong subst() result", "visit us: 1234http://www.apache.org!", actual); // Test subst() with backreferences without leading characters // before first backreference r = new RE("(.*?)=(.*)"); actual = r.subst("variable=value", "$1_test_$212", RE.REPLACE_BACKREFERENCES); assertEquals("Wrong subst() result", "variable_test_value12", actual); // Test subst() with NO backreferences r = new RE("^a$"); actual = r.subst("a", "b", RE.REPLACE_BACKREFERENCES); assertEquals("Wrong subst() result", "b", actual); // Test subst() with NO backreferences r = new RE("^a$", RE.MATCH_MULTILINE); actual = r.subst("\r\na\r\n", "b", RE.REPLACE_BACKREFERENCES); assertEquals("Wrong subst() result", "\r\nb\r\n", actual); // Test for Bug #36106 r = new RE("fo(o)"); actual = r.subst("foo", "$1", RE.REPLACE_BACKREFERENCES); assertEquals("Wrong subst() result", "o", actual); // Test for Bug #36405 r = new RE("^(.*?)(x)?$"); actual = r.subst("abc", "$1-$2", RE.REPLACE_BACKREFERENCES); assertEquals("Wrong subst() result", "abc-", actual); r = new RE("^(.*?)(x)?$"); actual = r.subst("abcx", "$1-$2", RE.REPLACE_BACKREFERENCES); assertEquals("Wrong subst() result", "abc-x", actual); r = new RE("([a-b]+?)([c-d]+)"); actual = r.subst("zzabcdzz", "$1-$2", RE.REPLACE_BACKREFERENCES); assertEquals("Wrong subst() result", "zzab-cdzz", actual); } public void assertEquals(String message, String expected, String actual) { if (expected != null && !expected.equals(actual) || actual != null && !actual.equals(expected)) { fail(message + " (expected \"" + expected + "\", actual \"" + actual + "\")"); } } public void assertEquals(String message, int expected, int actual) { if (expected != actual) { fail(message + " (expected \"" + expected + "\", actual \"" + actual + "\")"); } } /** * Converts yesno string to boolean. * @param yesno string representation of expected result * @return true if yesno is "YES", false if yesno is "NO" * stops program otherwise. */ private boolean getExpectedResult(String yesno) { if ("NO".equals(yesno)) { return false; } else if ("YES".equals(yesno)) { return true; } else { // Bad test script die("Test script error!"); return false; //to please javac } } /** * Finds next test description in a given script. * @param br BufferedReader for a script file * @return strign tag for next test description * @exception IOException if some io problems occured */ private String findNextTest(BufferedReader br) throws IOException { String number = ""; while (br.ready()) { number = br.readLine(); if (number == null) { break; } number = number.trim(); if (number.startsWith("##")) { continue; } if (number.startsWith("#")) { break; } if (!number.equals("")) { say("Script error. Line = " + number); System.exit(-1); } } return number; } /** * Creates testcase for the next test description in the script file. * @param br BufferedReader for script file. * @return a new tescase or null. * @exception IOException if some io problems occured */ private RETestCase getNextTestCase(BufferedReader br) throws IOException { // Find next re test case final String tag = findNextTest(br); // Are we done? if (!br.ready()) { return null; } // Get expression final String expr = br.readLine(); // Get test information final String matchAgainst = br.readLine(); final boolean badPattern = "ERR".equals(matchAgainst); boolean shouldMatch = false; int expectedParenCount; String[] expectedParens = null; if (!badPattern) { shouldMatch = getExpectedResult(br.readLine().trim()); if (shouldMatch) { expectedParenCount = Integer.parseInt(br.readLine().trim()); expectedParens = new String[expectedParenCount]; for (int i = 0; i < expectedParenCount; i++) { expectedParens[i] = br.readLine(); } } } return new RETestCase(this, tag, expr, matchAgainst, badPattern, shouldMatch, expectedParens); } } final class RETestCase { final private StringBuffer log = new StringBuffer(); final private int number; final private String tag; // number from script file final private String pattern; final private String toMatch; final private boolean badPattern; final private boolean shouldMatch; final private String[] parens; final private RETest test; private RE regexp; public RETestCase(RETest test, String tag, String pattern, String toMatch, boolean badPattern, boolean shouldMatch, String[] parens) { this.number = ++test.testCount; this.test = test; this.tag = tag; this.pattern = pattern; this.toMatch = toMatch; this.badPattern = badPattern; this.shouldMatch = shouldMatch; if (parens != null) { this.parens = new String[parens.length]; System.arraycopy(parens, 0, this.parens, 0, parens.length); } else { this.parens = null; } } public void runTest() { test.say(tag + "(" + number + "): " + pattern); if (testCreation()) { testMatch(); } } boolean testCreation() { try { // Compile it regexp = new RE(); regexp.setProgram(test.compiler.compile(pattern)); // Expression didn't cause an expected error if (badPattern) { test.fail(log, "Was expected to be an error, but wasn't."); return false; } return true; } // Some expressions *should* cause exceptions to be thrown catch (Exception e) { // If it was supposed to be an error, report success and continue if (badPattern) { log.append(" Match: ERR\n"); success("Produces an error (" + e.toString() + "), as expected."); return false; } // Wasn't supposed to be an error String message = (e.getMessage() == null) ? e.toString() : e.getMessage(); test.fail(log, "Produces an unexpected exception \"" + message + "\""); e.printStackTrace(); } catch (Error e) { // Internal error happened test.fail(log, "Compiler threw fatal error \"" + e.getMessage() + "\""); e.printStackTrace(); } return false; } private void testMatch() { log.append(" Match against: '").append(toMatch).append("'\n"); // Try regular matching try { // Match against the string boolean result = regexp.match(toMatch); log.append(" Matched: ").append(result ? "YES" : "NO").append("\n"); // Check result, parens, and iterators if (checkResult(result) && (!shouldMatch || checkParens())) { // test match(CharacterIterator, int) // for every CharacterIterator implementation. log.append(" Match using StringCharacterIterator\n"); if (!tryMatchUsingCI(new StringCharacterIterator(toMatch))) return; log.append(" Match using CharacterArrayCharacterIterator\n"); if (!tryMatchUsingCI(new CharacterArrayCharacterIterator(toMatch.toCharArray(), 0, toMatch.length()))) return; log.append(" Match using StreamCharacterIterator\n"); if (!tryMatchUsingCI(new StreamCharacterIterator(new ByteArrayInputStream(toMatch.getBytes())))) return; log.append(" Match using ReaderCharacterIterator\n"); if (!tryMatchUsingCI(new ReaderCharacterIterator(new StringReader(toMatch)))) return; } } // Matcher blew it catch(Exception e) { test.fail(log, "Matcher threw exception: " + e.toString()); e.printStackTrace(); } // Internal error catch(Error e) { test.fail(log, "Matcher threw fatal error \"" + e.getMessage() + "\""); e.printStackTrace(); } } private boolean checkResult(boolean result) { // Write status if (result == shouldMatch) { success((shouldMatch ? "Matched" : "Did not match") + " \"" + toMatch + "\", as expected:"); return true; } else { if (shouldMatch) { test.fail(log, "Did not match \"" + toMatch + "\", when expected to."); } else { test.fail(log, "Matched \"" + toMatch + "\", when not expected to."); } return false; } } private boolean checkParens() { // Show subexpression registers if (RETest.showSuccesses) { test.showParens(regexp); } log.append(" Paren count: ").append(regexp.getParenCount()).append("\n"); if (!assertEquals(log, "Wrong number of parens", parens.length, regexp.getParenCount())) { return false; } // Check registers against expected contents for (int p = 0; p < regexp.getParenCount(); p++) { log.append(" Paren ").append(p).append(": ").append(regexp.getParen(p)).append("\n"); // Compare expected result with actual if ("null".equals(parens[p]) && regexp.getParen(p) == null) { // Consider "null" in test file equal to null continue; } if (!assertEquals(log, "Wrong register " + p, parens[p], regexp.getParen(p))) { return false; } } return true; } boolean tryMatchUsingCI(CharacterIterator matchAgainst) { try { boolean result = regexp.match(matchAgainst, 0); log.append(" Match: ").append(result ? "YES" : "NO").append("\n"); return checkResult(result) && (!shouldMatch || checkParens()); } // Matcher blew it catch(Exception e) { test.fail(log, "Matcher threw exception: " + e.toString()); e.printStackTrace(); } // Internal error catch(Error e) { test.fail(log, "Matcher threw fatal error \"" + e.getMessage() + "\""); e.printStackTrace(); } return false; } public boolean assertEquals(StringBuffer log, String message, String expected, String actual) { if (expected != null && !expected.equals(actual) || actual != null && !actual.equals(expected)) { test.fail(log, message + " (expected \"" + expected + "\", actual \"" + actual + "\")"); return false; } return true; } public boolean assertEquals(StringBuffer log, String message, int expected, int actual) { if (expected != actual) { test.fail(log, message + " (expected \"" + expected + "\", actual \"" + actual + "\")"); return false; } return true; } /** * Show a success * @param s Success story */ void success(String s) { if (RETest.showSuccesses) { test.say("" + RETest.NEW_LINE + "-----------------------" + RETest.NEW_LINE + ""); test.say("Expression #" + (number) + " \"" + pattern + "\" "); test.say("Success: " + s); } } } jakarta-regexp-1.5/src/java/org/apache/regexp/REUtil.java100644 0 0 4435 10577337776 20470 0ustar 0 0 /* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.regexp; /** * This is a class that contains utility helper methods for this package. * * @author Jonathan Locke * @version $Id: REUtil.java 518156 2007-03-14 14:31:26Z vgritsenko $ */ public class REUtil { /** complex: */ private static final String complexPrefix = "complex:"; /** * Creates a regular expression, permitting simple or complex syntax * @param expression The expression, beginning with a prefix if it's complex or * having no prefix if it's simple * @param matchFlags Matching style flags * @return The regular expression object * @exception RESyntaxException thrown in case of error */ public static RE createRE(String expression, int matchFlags) throws RESyntaxException { if (expression.startsWith(complexPrefix)) { return new RE(expression.substring(complexPrefix.length()), matchFlags); } return new RE(RE.simplePatternToFullRegularExpression(expression), matchFlags); } /** * Creates a regular expression, permitting simple or complex syntax * @param expression The expression, beginning with a prefix if it's complex or * having no prefix if it's simple * @return The regular expression object * @exception RESyntaxException thrown in case of error */ public static RE createRE(String expression) throws RESyntaxException { return createRE(expression, RE.MATCH_NORMAL); } } jakarta-regexp-1.5/src/java/org/apache/regexp/ReaderCharacterIterator.java100644 0 0 10004 10577337776 24062 0ustar 0 0 /* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.regexp; import java.io.Reader; import java.io.IOException; /** * Encapsulates java.io.Reader as CharacterIterator * * @author Ales Novak * @version CVS $Id: ReaderCharacterIterator.java 518156 2007-03-14 14:31:26Z vgritsenko $ */ public final class ReaderCharacterIterator implements CharacterIterator { /** Underlying reader */ private final Reader reader; /** Buffer of read chars */ private final StringBuffer buff; /** read end? */ private boolean closed; /** @param reader a Reader, which is parsed */ public ReaderCharacterIterator(Reader reader) { this.reader = reader; this.buff = new StringBuffer(512); this.closed = false; } /** @return a substring */ public String substring(int beginIndex, int endIndex) { try { ensure(endIndex); return buff.toString().substring(beginIndex, endIndex); } catch (IOException e) { throw new StringIndexOutOfBoundsException(e.getMessage()); } } /** @return a substring */ public String substring(int beginIndex) { try { readAll(); return buff.toString().substring(beginIndex); } catch (IOException e) { throw new StringIndexOutOfBoundsException(e.getMessage()); } } /** @return a character at the specified position. */ public char charAt(int pos) { try { ensure(pos); return buff.charAt(pos); } catch (IOException e) { throw new StringIndexOutOfBoundsException(e.getMessage()); } } /** @return true iff if the specified index is after the end of the character stream */ public boolean isEnd(int pos) { if (buff.length() > pos) { return false; } else { try { ensure(pos); return (buff.length() <= pos); } catch (IOException e) { throw new StringIndexOutOfBoundsException(e.getMessage()); } } } /** Reads n characters from the stream and appends them to the buffer */ private int read(int n) throws IOException { if (closed) { return 0; } char[] c = new char[n]; int count = 0; int read = 0; do { read = reader.read(c); if (read < 0) // EOF { closed = true; break; } count += read; buff.append(c, 0, read); } while (count < n); return count; } /** Reads rest of the stream. */ private void readAll() throws IOException { while(! closed) { read(1000); } } /** Reads chars up to the idx */ private void ensure(int idx) throws IOException { if (closed) { return; } if (idx < buff.length()) { return; } read(idx + 1 - buff.length()); } } jakarta-regexp-1.5/src/java/org/apache/regexp/StreamCharacterIterator.java100644 0 0 7647 10577337776 24116 0ustar 0 0 /* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.regexp; import java.io.InputStream; import java.io.IOException; /** * Encapsulates java.io.InputStream as CharacterIterator. * * @author Ales Novak * @version CVS $Id: StreamCharacterIterator.java 518156 2007-03-14 14:31:26Z vgritsenko $ */ public final class StreamCharacterIterator implements CharacterIterator { /** Underlying is */ private final InputStream is; /** Buffer of read chars */ private final StringBuffer buff; /** read end? */ private boolean closed; /** @param is an InputStream, which is parsed */ public StreamCharacterIterator(InputStream is) { this.is = is; this.buff = new StringBuffer(512); this.closed = false; } /** @return a substring */ public String substring(int beginIndex, int endIndex) { try { ensure(endIndex); return buff.toString().substring(beginIndex, endIndex); } catch (IOException e) { throw new StringIndexOutOfBoundsException(e.getMessage()); } } /** @return a substring */ public String substring(int beginIndex) { try { readAll(); return buff.toString().substring(beginIndex); } catch (IOException e) { throw new StringIndexOutOfBoundsException(e.getMessage()); } } /** @return a character at the specified position. */ public char charAt(int pos) { try { ensure(pos); return buff.charAt(pos); } catch (IOException e) { throw new StringIndexOutOfBoundsException(e.getMessage()); } } /** @return true iff if the specified index is after the end of the character stream */ public boolean isEnd(int pos) { if (buff.length() > pos) { return false; } else { try { ensure(pos); return (buff.length() <= pos); } catch (IOException e) { throw new StringIndexOutOfBoundsException(e.getMessage()); } } } /** Reads n characters from the stream and appends them to the buffer */ private int read(int n) throws IOException { if (closed) { return 0; } int c; int i = n; while (--i >= 0) { c = is.read(); if (c < 0) // EOF { closed = true; break; } buff.append((char) c); } return n - i; } /** Reads rest of the stream. */ private void readAll() throws IOException { while(! closed) { read(1000); } } /** Reads chars up to the idx */ private void ensure(int idx) throws IOException { if (closed) { return; } if (idx < buff.length()) { return; } read(idx + 1 - buff.length()); } } jakarta-regexp-1.5/src/java/org/apache/regexp/StringCharacterIterator.java100644 0 0 3564 10577337776 24123 0ustar 0 0 /* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.regexp; /** * Encapsulates String as CharacterIterator. * * @author Ales Novak * @version CVS $Id: StringCharacterIterator.java 518156 2007-03-14 14:31:26Z vgritsenko $ */ public final class StringCharacterIterator implements CharacterIterator { /** encapsulated */ private final String src; /** @param src - encapsulated String */ public StringCharacterIterator(String src) { this.src = src; } /** @return a substring */ public String substring(int beginIndex, int endIndex) { return src.substring(beginIndex, endIndex); } /** @return a substring */ public String substring(int beginIndex) { return src.substring(beginIndex); } /** @return a character at the specified position. */ public char charAt(int pos) { return src.charAt(pos); } /** @return true iff if the specified index is after the end of the character stream */ public boolean isEnd(int pos) { return (pos >= src.length()); } } jakarta-regexp-1.5/src/java/org/apache/regexp/recompile.java100644 0 0 11053 10577337776 21315 0ustar 0 0 /* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.regexp; import org.apache.regexp.RECompiler; import org.apache.regexp.RESyntaxException; /** * 'recompile' is a command line tool that pre-compiles one or more regular expressions * for use with the regular expression matcher class 'RE'. For example, the command * java org.apache.regexp.recompile re1 "a*b" produces output like this: * *

 *
 *    // Pre-compiled regular expression 'a*b'
 *    private static final char[] re1Instructions =
 *    {
 *        0x002a, 0x0000, 0x0007, 0x0041, 0x0001, 0xfffd, 0x0061,
 *        0x0041, 0x0001, 0x0004, 0x0062, 0x0045, 0x0000, 0x0000,
 *    };
 *
 *    private static final REProgram re1 = new REProgram(re1Instructions);
 *
 * 
* * By pasting this output into your code, you can construct a regular expression matcher * (RE) object directly from the pre-compiled data (the character array re1), thus avoiding * the overhead of compiling the expression at runtime. For example: * *
 *
 *    RE r = new RE(re1);
 *
 * 
* * @see RE * @see RECompiler * * @author Jonathan Locke * @version $Id: recompile.java 518156 2007-03-14 14:31:26Z vgritsenko $ */ public class recompile { /** * Main application entrypoint. * * @param arg Command line arguments */ static public void main(String[] arg) { // Create a compiler object RECompiler r = new RECompiler(); // Print usage if arguments are incorrect if (arg.length <= 0 || arg.length % 2 != 0) { System.out.println("Usage: recompile "); System.exit(0); } // Loop through arguments, compiling each for (int i = 0; i < arg.length; i += 2) { try { // Compile regular expression String name = arg[i]; String pattern = arg[i+1]; String instructions = name + "Instructions"; // Output program as a nice, formatted character array System.out.print("\n // Pre-compiled regular expression '" + pattern + "'\n" + " private static final char[] " + instructions + " = \n {"); // Compile program for pattern REProgram program = r.compile(pattern); // Number of columns in output int numColumns = 7; // Loop through program char[] p = program.getInstructions(); for (int j = 0; j < p.length; j++) { // End of column? if ((j % numColumns) == 0) { System.out.print("\n "); } // Print character as padded hex number String hex = Integer.toHexString(p[j]); while (hex.length() < 4) { hex = "0" + hex; } System.out.print("0x" + hex + ", "); } // End of program block System.out.println("\n };"); System.out.println("\n private static final REProgram " + name + " = new REProgram(" + instructions + ");"); } catch (RESyntaxException e) { System.out.println("Syntax error in expression \"" + arg[i] + "\": " + e.toString()); } catch (Exception e) { System.out.println("Unexpected exception: " + e.toString()); } catch (Error e) { System.out.println("Internal error: " + e.toString()); } } } } jakarta-regexp-1.5/xdocs/README.txt100644 0 0 322 10577337776 14234 0ustar 0 0 $Id: README.txt 126085 2000-11-27 19:48:03Z jon $ You can find out more information on how the documentation is generated by going to this website: http://jakarta.apache.org/site/jakarta-site2.html thanks!jakarta-regexp-1.5/xdocs/RETest.txt100644 0 0 21473 10577337776 14517 0ustar 0 0 ## Licensed to the Apache Software Foundation (ASF) under one or more ## contributor license agreements. See the NOTICE file distributed with ## this work for additional information regarding copyright ownership. ## The ASF licenses this file to You under the Apache License, Version 2.0 ## (the "License"); you may not use this file except in compliance with ## the License. You may obtain a copy of the License at ## ## http://www.apache.org/licenses/LICENSE-2.0 ## ## Unless required by applicable law or agreed to in writing, software ## distributed under the License is distributed on an "AS IS" BASIS, ## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ## See the License for the specific language governing permissions and ## limitations under the License. #1 abc abc YES 1 abc #2 abc xbc NO #3 abc axc NO #4 abc abx NO #5 abc xabcy YES 1 abc #6 abc ababc YES 1 abc #7 ab*c abc YES 1 abc #8 ab*bc abc YES 1 abc #9 ab*bc abbc YES 1 abbc #10 ab*bc abbbbc YES 1 abbbbc #11 ab+bc abbc YES 1 abbc #12 ab+bc abc NO #13 ab+bc abq NO #14 ab+bc abbbbc YES 1 abbbbc #15 ab?bc abbc YES 1 abbc #16 ab?bc abc YES 1 abc #17 ab?bc abbbbc NO #18 ab?c abc YES 1 abc #19 a.c abc YES 1 abc #20 a.c axc YES 1 axc #21 a.*c axyzc YES 1 axyzc #22 a.*c axyzd NO #23 a[bc]d abc NO #24 a[bc]d abd YES 1 abd #25 a[b-d]e abd NO #26 a[b-d]e ace YES 1 ace #27 a[b-d] aac YES 1 ac #28 a[b-a] ERR #29 a[-b] aa YES 1 aa #30 a[b-] ac YES 1 ac #31 a[]b ERR #32 a[ ERR #33 a] ERR #34 a[]] ERR #35 a[^bc]d aed YES 1 aed #36 a[^bc] abd NO #37 ab|cd abc YES 1 ab #38 ab|cd abcd YES 1 ab #39 ab|cd bcda YES 1 cd #40 a[]b ERR #41 ()ef ef YES 2 ef #42 ()* ERR #43 *a ERR #44 (*)b ERR #45 a\ ERR #46 a\(b a(b YES 1 a(b #47 a\(*b ab YES 1 ab #48 a\(*b a((b YES 1 a((b #49 a\\b a\b YES 1 a\b #50 abc) ERR #51 (abc ERR #52 ((a)) abc YES 3 a a a #53 (a)b(c) abc YES 3 abc a c #54 a+b+c aabbabc YES 1 abc #55 a** ERR #56 a++ ERR #57 a* aaaa YES 1 aaaa #58 a* baaaa YES 1 #59 (a*)* ERR #60 (a*)+ ERR #61 (a|)* ERR #62 (ab|cd)e abcde YES 2 cde cd #63 [abhgefdc]ij hij YES 1 hij #64 ab* xabyabbbz YES 1 ab #65 ab* xayabbbz YES 1 a #66 abcd*efg abcdefg YES 1 abcdefg #67 (ab|ab*)bc abc YES 2 abc a #68 (a|b|c|d|e)f ef YES 2 ef e #69 a|b|c|d|e e YES 1 e #70 (.*)c(.*) abcde YES 3 abcde ab de #71 \((.*), (.*)\) (a, b) YES 3 (a, b) a b #72 a(bc)d abcd YES 2 abcd bc #73 a* x YES 1 #74 ([abc])*d abbbcd YES 2 abbbcd c #75 a* YES 1 #76 ([abc])*bcd abcd YES 2 abcd a #77 (a|b)c*d abcd YES 2 bcd b #78 a([bc]*)c* abc YES 2 abc bc #79 [a-zA-Z_][a-zA-Z0-9_]* alpha YES 1 alpha #80 ((a)(b)c)(d) abcd YES 5 abcd abc a b d #81 (ab|a)b*c abc YES 2 abc ab #82 a[bcd]+dcdcde adcdcde NO #83 ((((((((((a))))))))) ERR #84 (((((((((a))))))))) a YES 10 a a a a a a a a a a #85 [k] ab NO #86 abcd abcd YES 1 abcd #87 a[-]?c abc YES 1 abc #88 multiple words of text uh-uh NO #89 multiple words multiple words, yeah YES 1 multiple words #90 a[bcd]*dcdcde adcdcde YES 1 adcdcde #91 a([bc]*)(c*d) abcd YES 3 abcd bc d #92 a([bc]+)(c*d) abcd YES 3 abcd bc d #93 a([bc]*)(c+d) abcd YES 3 abcd b cd #94 abc NO #95 ^* ERR #96 $* ERR #97 ^abc$ abc YES 1 abc #98 ^abc$ abcc NO #99 ^abc abcc YES 1 abc #100 ^abc$ aabc NO #101 abc$ aabc YES 1 abc #102 ^ abc YES 1 #103 $ abc YES 1 #104 $b b NO #105 (a+|b)* ab YES 2 ab b #106 (a+|b)+ ab YES 2 ab b #107 (a+|b)? ab YES 2 a a #108 (^* ERR #109 )( ERR #110 [^ab]* cde YES 1 cde #111 ^(ab|cd)e abcde NO #112 ^a(bc+|b[eh])g|.h$ abh YES 1 bh #113 (bc+d$|ef*g.|h?i(j|k)) effgz YES 2 effgz effgz #114 (bc+d$|ef*g.|h?i(j|k)) ij YES 3 ij ij j #115 (bc+d$|ef*g.|h?i(j|k)) effg NO #116 (bc+d$|ef*g.|h?i(j|k)) bcdd NO #117 (bc+d$|ef*g.|h?i(j|k)) reffgz YES 2 effgz effgz #118 a*b\s+c aaaab c YES 1 aaaab c #119 a*b\s+c aaaabfc NO #120 a*(b*c*) aabbcc YES 2 aabbcc bbcc #121 a?b+c* b YES 1 b #122 \d+ 99 YES 1 99 #123 ^[:javastart:]+[:javapart:]+$ javaIdentifier0 YES 1 javaIdentifier0 #124 ^[:javastart:]+[:javapart:]+$ ?javaIdentifier NO #125 [a-e]?d\\e yyzabecd\eyyz YES 1 cd\e #126 ((\w+)/)*(\w+) foo/bar/baz YES 4 foo/bar/baz bar/ bar baz #127 i am a green (giant|man|martian) i am a green man YES 2 i am a green man man #128 ([a-c]+?)c abcabcabc YES 2 abc ab #129 ([ab]*?)b aaaaabaaaababab YES 2 aaaaab aaaaa #130 ([ab]*)b aaaaabaaaababab YES 2 aaaaabaaaababab aaaaabaaaababa #131 ([ab]??)b bb YES 2 b #132 (c[ab]?)b cbb YES 2 cbb cb #133 (c[ab]??)b cbb YES 2 cb c #134 (c[ab]*?)b cbb YES 2 cb c #135 [:digit:]+ 789 YES 1 789 #136 [:digit:]+ abc NO #137 [:xdigit:]+ ffe5a YES 1 ffe5a #138 [:wacky:]+ ERR #139 (wee|week)(knights|knight) weeknights YES 3 weeknights wee knights #140 (ac*)c*d[ac]*\1 acdacaa YES 2 acdac ac #141 (a.*b)(a.*b) accbaccccb YES 3 accbaccccb accb accccb #142 (.)=\1 x=x YES 2 x=x x #143 ([ab])=\1 a=a YES 2 a=a a #144 ([ab]+)=\1 abba=abba YES 2 abba=abba abba #145 \u004a J YES 1 J #146 \x4a J YES 1 J #147 \[([:javastart:][:javapart:]*)\] foo[bar]baz YES 2 [bar] bar #148 (\s*\w+)? aa YES 2 aa aa #149 (?:a) a YES 1 a #150 (?:a) aa YES 1 a #151 (?:\w) abc YES 1 a #152 (?:\w\s\w)+ a b c YES 1 a b #153 (a\w)(?:,(a\w))+ ab,ac,ad YES 3 ab,ac,ad ab ad #154 z(\w\s+(?:\w\s+\w)+)z za b bc cd dz YES 2 za b bc cd dz a b bc cd d #155 (([hH][tT]{2}[pP]|[fF][tT][pP]):\/\/)?[a-zA-Z0-9\-]+(\.[a-zA-Z0-9\-]+)* http://www.test.com YES 4 http://www.test.com http:// http .com #156 ((?:[hH][tT]{2}[pP]|[fF][tT][pP]):\/\/)?[a-zA-Z0-9\-]+(\.[a-zA-Z0-9\-]+)* ftp://www.test.com YES 3 ftp://www.test.com ftp:// .com #157 (([hH][tT]{2}[pP]|[fF][tT][pP]):\/\/)?[a-zA-Z0-9\-]+(?:\.[a-zA-Z0-9\-]+)* htTp://www.test.com YES 3 htTp://www.test.com htTp:// htTp #158 (?:([hH][tT]{2}[pP]|[fF][tT][pP]):\/\/)?[a-zA-Z0-9\-]+(\.[a-zA-Z0-9\-]+)* FTP://www.test.com YES 3 FTP://www.test.com FTP .com #159 ^(?:([hH][tT]{2}[pP]|[fF][tT][pP]):\/\/)?[a-zA-Z0-9\-]+(\.[a-zA-Z0-9\-]+)*$ http://.www.test.com NO #160 ^(?:(?:[hH][tT]{2}[pP]|[fF][tT][pP]):\/\/)?[a-zA-Z0-9\-]+(?:\.[a-zA-Z0-9\-]+)*$ FtP://www.test.com YES 1 FtP://www.test.com #161 ^(?:(?:[hH][tT]{2}[pP]|[fF][tT][pP]):\/\/)?[a-zA-Z0-9\-]+(?:\.[a-zA-Z0-9\-]+)*$ FtTP://www.test.com NO #162 ^(?:(?:[hH][tT]{2}[pP]|[fF][tT][pP]):\/\/)?[a-zA-Z0-9\-]+(?:\.[a-zA-Z0-9\-]+)*$ www.test.com YES 1 www.test.com #163 abc.*?x+yz abcaaaaaxyzbbbbxyz YES 1 abcaaaaaxyz #164 abc.+?x+yz abcaaaaaxyzbbbbxyz YES 1 abcaaaaaxyz #165 a.+?(c|d) aaaacaaaaad YES 2 aaaac c #166 a.+(c|d) aaaacaaaaad YES 2 aaaacaaaaad d #167 a+?b+?c+? aaabccaaabbbccc YES 1 aaabc #168 a(.+)b(.+)c(.+)d(.+)e(.+)f(.+)g(.+)h(.+)i(.+)j(.+)k(.+)l(.+)m(.+)n(.+)o(.+)p(.+)q(.+)r a01b02c03d04e05f06g07h08i09j10k11l12m13n14o15p16q17r YES 18 a01b02c03d04e05f06g07h08i09j10k11l12m13n14o15p16q17r 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 16 17 #169 \bfly\b flying NO #170 \bfly\b housefly NO #171 [^ac]+ bd YES 1 bd #172 [^ca]+ bd YES 1 bd #173 [^ac]+ acb YES 1 b #174 [a-z]{0,3} 123abcdefg123 YES 1 #175 ab{0,1}a aa YES 1 aa #176 ab{0,1}a aba YES 1 aba #177 ab{0,1}a abba NO #178 ab{0,2}a aa YES 1 aa #179 ab{0,2}a aba YES 1 aba #180 ab{0,2}a abba YES 1 abba #181 ab{0,2}a abbba NO #182 ab{1,1}a aa NO #183 ab{1,1}a aba YES 1 aba #184 ab{1,1}a abba NO #185 ab{1,2}a aa NO #186 ab{1,2}a aba YES 1 aba #187 ab{1,2}a abba YES 1 abba #188 ab{1,2}a abbba NO #189 ab{0,}a aa YES 1 aa #190 ab{0,}a aba YES 1 aba #191 ab{0,}a abba YES 1 abba #192 ab{1,}a aa NO #193 ab{1,}a aba YES 1 aba #194 ab{1,}a abba YES 1 abba #195 ab{1}a aa NO #196 ab{1}a aba YES 1 aba #197 ab{1}a abba NO #198 ab{0}a aa YES 1 aa #199 ab{0}a aba NO #200 ab{2}a aa NO #201 ab{2}a aba NO #202 ab{2}a abba YES 1 abba #203 ab{2}a abbba NO #204 [ \-] - YES 1 - #205 [a-z0-9\.\-]+ {regexp-1.2} YES 1 regexp-1.2 #206 [a-z0-9\-\.]+ {regexp-1.2} YES 1 regexp-1.2 #207 [a-z\-0-9\.]+ {regexp-1.2} YES 1 regexp-1.2 #208 \w+ a_b YES 1 a_b #209 ([0123])??((((1st)|(2nd))|(3rd))|(\dth)) 1st YES 6 1st null 1st 1st 1st 1st #210 [^\s\]'<>(),;:\.\[] - YES 1 - #211 ^\(?(\d{3})\)?[\- ]?(\d{3})[\- ]?(\d{4})$ (425) 576+1202 NO #212 [^\s\(\)<>@,;:\\\"\.\[\]] - YES 1 - #213 a{0,1}b{0,1}c{0,1}d{0,1}e{0,1}f{0,1}g{0,1}h{0,1}i{0,1}j{0,1}k{0,1}l{0,1} acghij YES 1 acghij #214 [^02468ACEGIKMOQSUW] 012 YES 1 1 #215 [^02468ACEGIKMOQSUW] UVW YES 1 V #216 UUID=(\w{8}\.){3}\w{8} UUID=3babc217.0007d4e1.74726163.006e616d YES 4 UUID=3babc217.0007d4e1.74726163.006e616d 3babc217. 0007d4e1. 74726163. #217 ^\d{4}(-\d{2}){2}$ 2004-01-01 YES 3 2004-01-01 -01 -01 #218 [\W] a NO #219 [\W] 1 NO #220 [\W] ! YES 1 ! #221 [^\W] a YES 1 a #222 [^\W] _ YES 1 _ #223 [\D\S]+ @0 1 _1AByz YES 1 @0 1 _1AByz #224 [^\D\S] @0 1 _1AByz NO #225 ^(a{1}){0,2}$ aa YES 3 aa a a #226 (a{1,3}b){1,3} abaabaaab YES 4 abaabaaab ab aab aaab #227 ^(1_*)??_$ 1__ YES 2 1__ 1_ #228 ^(1_*)*?_$ 1__ YES 2 1__ 1_ #229 ^(1_*)+?_$ 1__ YES 2 1__ 1_ #230 a+?b+?c+?a aaabccaaabbbccc YES 1 aaabcca #231 ^a{1,30}$ aaaaaaaaaaaaaaaaaaaaaaaaaaaab NO jakarta-regexp-1.5/xdocs/applet.xml100644 0 0 2626 10577337776 14576 0ustar 0 0 Vadim Gritsenko Jakarta Regexp Applet

This simple applet provides way for visual debugging and testing Jakarta Regexp package.

jakarta-regexp-1.5/xdocs/changes.xml100644 0 0 20732 10577337776 14737 0ustar 0 0 Jon S. Stevens Vadim Gritsenko Jakarta Regexp History of Changes

This document reflects the changes between releases for the Jakarta Regexp package.

Version 1.5 (18 Mar 2007)

  • Fixed Bug 36405: Referencing an optional backreference returns null (VG)
  • Implemented optimization: RE compiler omits branch instruction if only one branch is present (VG)
  • Fixed Bug 9153: {m,n} implementation had exponential complexity (VG)
  • Fixed Bug 27763: RE incorrectly processed reluctant matchers (VG)
  • Fixed Bug 38331: RE compiler creates incorrect program if pattern results in large program with offsets exceeding capacity of the short (VG)
  • Fixed Bug 37275: RE incorrectly processes nested {n,m} closures (ex: (A{1}){0,2}) (VG)
  • Added accessor for REProgram.prefix (VG)

Version 1.4 (17 Aug 2005)

  • Fixed Bug: RE creates wrong character class when overlapping character ranges are used (ex: [a-h0f-z]) (VG)
  • Fixed Bug 30126: Support negated character classes (\W, \D, \S) in custom character class (VG)
  • Applied patches for Bug 27795: Add optimization for regexps which start with ^ (BOL) (VG)
  • Fixed Bug 25985: In MATCH_MULTILINE mode $ does not match end of line (VG)
  • Fixed Bug 2121: '.' or '-' in bracket expression gives unexpected results (VG)
  • Regexp is relicensed to Apache License, Version 2.0 (VG)
  • Fixed Bug 2525: Leading zero-length string splitted by RE (VG)
  • Applied patches for Bug 4137: Regexp match gets different results on different platforms (VG)
  • Applied patches for Bug 3303: Unicode 3.0 character \\uFFFD (VG)
  • Applied patches for Bug 3773: Problem with parsing greedy match modifiers (VG)
  • Applied patches for Bug 3273: CharacterArrayCharacterIterator docs and implementation mismatch (VG)
  • Fixed Bug 22928: subst() with REPLACE_BACKREFERENCES cuts first 2 characters (VG)

Version 1.3 (2 Sep 2003)

  • Fixed Bug 22804: ArrayIndexOutOfBoundsException on negated classes (VG)
  • New Feature: subst() can now process backreferences when flag REPLACE_BACKREFERENCES is set. See API docs for details. Patch provided by Tobias Schaefer. (VG)
  • Applied patches for Bug 16592: Syntax error: Too many bracketed closures (limit is 10) (VG)
  • Fixed Bug 5212, aka 14954: A bug caused by '-' in character class definition ('[...]') (VG)
  • Fixed Bug 4057: \w does not match underscore (VG)
  • Fixed Bug 1030, aka 10893: {n.m} notation work incorrect if n=0 (VG)
  • Re-visited Bug 3879: Expressions using {0,n} match 0 to n+1 times instead of 0 to n times. Now, expression "[a-z]{0,3}" matches "123abcdefg123" resulting in "" (empty string). (VG)
  • Fixed Bug 306: Why is the RE class not Serializable? (VG)
  • Applied patches for Bug 3879: Expressions using {0,n} match 0 to n+1 times instead of 0 to n times. (JSS)
  • Applied patches for Bug 7288: Bug in negative character ranges. (JSS)
  • Applied patches for Bug 986: Leading "\b" word boundary is ignored. (JSS)
  • Applied patches for Bug 3877: {n} and {n,m} not thread safe. (JSS)
  • Applied patches for Bug 8467: Number of paren pairs limited to 16 (JSS)
  • Fixed RE.grep() documentation to reflect a String[] is returned instead of an Object[].
  • New Feature: Clustering (i.e. non backref'd grouping)
  • Rebuilt website with latest Jakarta-Site dependency

Version 1.2 (27 Nov 2000)

  • Updated to Ant 1.2 (JSS)
  • Documentation now built with Anakia (JSS)
  • Fixed bug
  • Fixed bug: StringIndexOutOfBoundsException if paren is empty
  • Fixed bug: Case independent flag does not work in prefix optimization code
  • New Feature: Added flag MATCH_SINGLELINE - newlines are matched by '.'

Version 1.1 (14 May 2000)

Contributions by Ales Novak:

  • RECompiler.compile() - copy on return
  • RE.matchNodes() - BOL and EOL cases if RE.MATCH_MULTILINE is specified. - Think of RETest.java which prints MATCH!!!: ...... two times while in the older version only one time.
  • RE.java also contains an extension which allow to parse InputStreams, Readers and char arrays in addition to Strings. All needed modifications are only in the RE class.

Contributions by Jon S. Stevens:

  • Fix in the build system for building on NT
  • Documentation fixes / additions

Version 1.0

  • Repackaging from original contribution. No major code changes.
jakarta-regexp-1.5/xdocs/index.xml100644 0 0 5754 10577337776 14425 0ustar 0 0 Jon S. Stevens Jakarta Regexp

Jakarta Regexp is a 100% Pure Java Regular Expression package that was graciously donated to the Apache Software Foundation by Jonathan Locke. He originally wrote this software back in 1996 and it has stood up quite well to the test of time. It includes complete Javadoc documentation as well as a simple applet for visual debugging and testing suite for compatibility.

This package is intended to be an answer to a question we commonly hear in the Java world:

"Why isn't there a decent regular expression package available for Java under a BSD-Style (ie: Apache) license?"

You can:

  • Download builds.
  • View the list of changes between revisions.
  • Launch applet and run regular expressions interactively.
  • View Javadoc online. It is also included in the distribution download.

If you would like to get involved with this project in one way or another (Mailing lists, SVN, Contributions), please see the Getting Involved section of the Jakarta Website.

Contributors

  • Jonathan Locke wrote the original code.
  • James Davidson for making the contact with Jonathan and asking him to release his source code.
  • Jon S. Stevens is responsible for re-packaging it and preparing it for release.
  • Craig McClanahan is responsible for setting up the CVS and mailing lists.
  • Ales Novak has contributed bug fixes and feature enhancements.
  • Michael McCallum contributed a patch to add clustering support.
jakarta-regexp-1.5/xdocs/stylesheets/site.xml100644 0 0 3711 10577337776 16625 0ustar 0 0 Jakarta Regexp _bug.cgi?id=3879">3879: Expressions using {0,n} match 0 to n+1 times instead of 0 to n times. Now, expression "[a-z]{0,3}" matches "123abcdefg123" resulting in "" (empty string). (VG)
  • Fixed Bug 306: Why is the RE class not Serializable? (VG)
  • Applied patches for Bug 3879: Expressions using {0,n} match 0 to n+1 times instead of 0 to n times. (JSS)
  • Applied patches for Bug 7288: Bug in negative character ranges. (JSS)
  • Applied patches for Bug 986: Leading "\b" word boundary is ignored. (JSS)
  • Applied patches for Bug 3877: {n} and {n,m} not thread safe. (JSS)
  • Applied patches for Bug 8467: Number of paren pairs limited to 16 (JSS)
  • Fixed RE.grep() documentation to reflect a String[] is returned instead of an Object[].
  • New Feature: Clustering (i.e. non backref'd grouping)
  • Rebuilt website with latest Jakarta-Site dependency
  • Version 1.2 (27 Nov 2000)

    • U