XML::LibXML::RegExp(3) User Contributed Perl Documentation XML::LibXML::RegExp(3)NAME
XML::LibXML::RegExp - XML::LibXML::RegExp - interface to libxml2 regular expressions
SYNOPSIS
use XML::LibXML;
my $compiled_re = XML::LibXML::RegExp->new('[0-9]{5}(-[0-9]{4})?');
if ($compiled_re->isDeterministic()) { ... }
if ($compiled_re->matches($string)) { ... }
$compiled_re = XML::LibXML::RegExp->new( $regexp_str );
$bool = $compiled_re->matches($string);
$bool = $compiled_re->isDeterministic();
DESCRIPTION
This is a perl interface to libxml2's implementation of regular expressions, which are used e.g. for validation of XML Schema simple types
(pattern facet).
new()
$compiled_re = XML::LibXML::RegExp->new( $regexp_str );
The constructor takes a string containing a regular expression and returns a compiled regexp object.
matches($string)
$bool = $compiled_re->matches($string);
Given a string value, returns a true value if the value is matched by the compiled regular expression.
isDeterministic()
$bool = $compiled_re->isDeterministic();
Returns a true value if the regular expression is deterministic; returns false otherwise. (See the definition of determinism in the XML
spec (http://www.w3.org/TR/REC-xml/#determinism <http://www.w3.org/TR/REC-xml/#determinism>))
AUTHORS
Matt Sergeant, Christian Glahn, Petr Pajas
VERSION
2.0008
COPYRIGHT
2001-2007, AxKit.com Ltd.
2002-2006, Christian Glahn.
2006-2009, Petr Pajas.
perl v5.16.2 2012-10-22 XML::LibXML::RegExp(3)
Check Out this Related Man Page
XML::LibXML::RegExp(3) User Contributed Perl Documentation XML::LibXML::RegExp(3)NAME
XML::LibXML::RegExp - XML::LibXML::RegExp - interface to libxml2 regular expressions
SYNOPSIS
use XML::LibXML;
my $compiled_re = XML::LibXML::RegExp->new('[0-9]{5}(-[0-9]{4})?');
if ($compiled_re->isDeterministic()) { ... }
if ($compiled_re->matches($string)) { ... }
$compiled_re = XML::LibXML::RegExp->new( $regexp_str );
$bool = $compiled_re->matches($string);
$bool = $compiled_re->isDeterministic();
DESCRIPTION
This is a perl interface to libxml2's implementation of regular expressions, which are used e.g. for validation of XML Schema simple types
(pattern facet).
new()
$compiled_re = XML::LibXML::RegExp->new( $regexp_str );
The constructor takes a string containing a regular expression and returns a compiled regexp object.
matches($string)
$bool = $compiled_re->matches($string);
Given a string value, returns a true value if the value is matched by the compiled regular expression.
isDeterministic()
$bool = $compiled_re->isDeterministic();
Returns a true value if the regular expression is deterministic; returns false otherwise. (See the definition of determinism in the XML
spec (<http://www.w3.org/TR/REC-xml/#determinism>))
AUTHORS
Matt Sergeant, Christian Glahn, Petr Pajas
VERSION
2.0110
COPYRIGHT
2001-2007, AxKit.com Ltd.
2002-2006, Christian Glahn.
2006-2009, Petr Pajas.
LICENSE
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
perl v5.18.2 2014-02-01 XML::LibXML::RegExp(3)
Hi guys,
does anyone know how to test for a regular expression - i want to include it in a script to make sure the variable is a regexp
cheers (3 Replies)
or I don't know how to make it work ...
Hello
im trying to build regexp that will match me single string or function call inside of brackets
for example I have :
<% myFunction("blah",foo) %>
or
<% myVar %>
and not match :
<% if(myFunction("blah",foo)==1) %>
or
<% while(myvar < 3){... (2 Replies)
I use SAS (a statistical software) and have to remove last character or the last 1/2 numbers that appear after characters from the string using Perl Regular Expression (which is recognized by SAS).
Input: f183ii10 f183ii2 f182ii1 f182ii2 f183iim f22ii f22ii11 f22ii12 pmh4 pmhm
Desired... (2 Replies)
A couple co-workers have a disagreement. Can you guys please settle this?
One co-worker says regular expressions can inherently search and replace. His argument is that he can do a s/ regexp / replace in perl (and many other languages).
The other says that by definition regular expressions... (2 Replies)
Hello, I need a script to edit a custom XML, although I know it should be fairly easy to create such a script, I'm failing miserably.
The script should be able to read from a file containing the ids of one tag of the xml (<content contentid="XXX".... for example) and then remove this content.
For... (5 Replies)
I'm a Unix and C programming newbie, and I've been tasked with calling a web service from a legacy Unix app... I've come across libxml2 and libsoup, gnome's libraries for XML/SOAP processing... But I'm seeking guidance on the development process... :o (0 Replies)
Hi again,
I use Ubuntu 8.10. I could not install xml-config. Although libxml2-dev is installed, ./configure cannot find xml-config.
Help me out please...
apprentice (7 Replies)
Greetings all,
...here is yet another string of awk/sed questions from a RegExp-Challenged luser :eek:
I'm looking to have sed/awk do some clean-up on routing tables and to that end, I would like to do the following:
1.) If a line contains the word "masks" or "subnets" prepend CR/LF to... (16 Replies)
Hello all,
I need to match the red expressions in the following lines :
MACRO_P+P-_scrambledServices_REM_PRC30.xml
MACRO_P+P-_scrambledServices_REM_RS636.xml
MACRO_P+P-_scrambledServices_REM_RS535.xml
and so on...
Can anyone give me a PERL regular expression to match those characters ?
... (5 Replies)
i need to read/write a xml file in c
i found libxml2, but the documentation is awfull,
im using google but i get most of vb, or c# results
can anyone point me to a introduction tutorial?
actually, any kind of documentation would be ok (just not the oficial The XML C parser and toolkit... (2 Replies)
I would like to to catch the ip at the following line with egrep and regexp:
ip = 192.9.110.20
and I built the following regexp to do it:
(?<=ip\s=\s)\S+
when I check it with regexp simulator, it works but when I use it in the following egrep command it doesn't work -
egrep -e... (2 Replies)
Hello,
I was trying to identify lines who has a word of the following pattern "xyyx" (where x, and ys are different characters).
I was trying the following grep -
egrep '(\S)()\2\1'
This pattern do catches the wanted pattern, but it also catches "GGGG" or "CCCC" patterns. I was trying to... (5 Replies)