Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 72 lines (48 sloc) 3.008 kB
4fcb0fd @dichodaemon initial import
dichodaemon authored
1 == ONIGURUMA FOR RUBY:
2
3 Ruby bindings to the Oniguruma[http://www.geocities.jp/kosako3/oniguruma/] regular expression library (no need to recompile Ruby).
4
5 == FEATURES:
6
7 * Increased performance.
8 * Same interface than standard Regexp class (easy transition!).
9 * Support for named groups, look-ahead, look-behind, and other
10 cool features!
62c7eac @dichodaemon * Added documentation for MatchData.
dichodaemon authored
11 * Support for other regexp syntaxes (Perl, Python, Java, etc.)
4fcb0fd @dichodaemon initial import
dichodaemon authored
12
13 == SYNOPSIS:
14
15 reg = Oniguruma::ORegex.new( '(?<before>.*)(a)(?<after>.*)' )
16 match = reg.match( 'terraforming' )
17 puts match[0] <= 'terraforming'
18 puts match[:before] <= 'terr'
19 puts match[:after] <= 'forming'
32a5bc1 @dichodaemon Added regexp syntax reference. Removed doc directory.
dichodaemon authored
20
21 == SYNTAX
22
23 Consult the Syntax.txt[link:files/Syntax_txt.html] page.
4fcb0fd @dichodaemon initial import
dichodaemon authored
24
25 == REQUIREMENTS:
26
d3308bf @dichodaemon * Changed minimal libonig version to 4.6
dichodaemon authored
27 * Oniguruma[http://www.geocities.jp/kosako3/oniguruma/] library v. 4.6 or higher
4fcb0fd @dichodaemon initial import
dichodaemon authored
28
29 == INSTALL:
30
31 sudo gem install -r oniguruma
32
33 == BUGS/PROBLEMS/INCOMPATIBILITIES:
34
35 * <code>ORegexp#~</code> is not implemented.
36 * <code>ORegexp#kcode</code> results are not compatible with <code>Regexp</code>.
37 * <code>ORegexp</code> options set in the string are not visible, this affects
38 <code>ORegexp#options</code>, <code>ORegexp#to_s</code>, <code>ORegexp#inspect</code>
39 and <code>ORegexp#==</code>.
40
41 == TODO:
42
43 * Complete documentation (methods, oniguruma syntax).
44
45 == CREDITS:
46
62c7eac @dichodaemon * Added documentation for MatchData.
dichodaemon authored
47 * N. Lugovoi. ORegexp.sub and ORegexp.gsub code and lots of other stuff.
6ffc8f1 @dichodaemon Updated History.txt and README.txt
dichodaemon authored
48 * K. Kosako. For his great library.
49 * A lot of the documentation has been copied from the original Ruby Regex documentation.
4fcb0fd @dichodaemon initial import
dichodaemon authored
50
51 == LICENSE:
52
53 New BSD License
54
55 Copyright (c) 2007, Dizan Vasquez
56 All rights reserved.
57
58 Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
59
60 * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
61 * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the
62 documentation and/or other materials provided with the distribution.
63 * Neither the name of the author nor the names of its contributors may be used to endorse or promote products derived from this
64 software without specific prior written permission.
65
66 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
67 LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
68 OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
69 LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
70 THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
71 THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Something went wrong with that request. Please try again.