1Regexp::Common::URI::neUwsse(r3)Contributed Perl DocumenRteagteixopn::Common::URI::news(3)
2
3
4
6 Regexp::Common::URI::news -- Returns a pattern for file URIs.
7
9 use Regexp::Common qw /URI/;
10
11 while (<>) {
12 /$RE{URI}{news}/ and print "Contains a news URI.\n";
13 }
14
16 $RE{URI}{news}
17 Returns a pattern that matches news URIs, as defined by RFC 1738. News
18 URIs have the form:
19
20 "news:" ( "*" | group | article "@" host )
21
22 Under "{-keep}", the following are returned:
23
24 $1 The complete URI.
25
26 $2 The scheme.
27
28 $3 The part of the URI following "news://".
29
30 $RE{URI}{NNTP}
31 Returns a pattern that matches NNTP URIs, as defined by RFC 1738. NNTP
32 URIs have the form:
33
34 "nntp://" host [ ":" port ] "/" group [ "/" digits ]
35
36 Under "{-keep}", the following are returned:
37
38 $1 The complete URI.
39
40 $2 The scheme.
41
42 $3 The part of the URI following "nntp://".
43
44 $4 The host and port, separated by a colon. If no port was given, just
45 the host.
46
47 $5 The host.
48
49 $6 The port, if given.
50
51 $7 The group.
52
53 $8 The digits, if given.
54
56 [RFC 1738]
57 Berners-Lee, Tim, Masinter, L., McCahill, M.: Uniform Resource
58 Locators (URL). December 1994.
59
61 Regexp::Common::URI for other supported URIs.
62
64 Damian Conway (damian@conway.org)
65
67 This package is maintained by Abigail (regexp-common@abigail.be).
68
70 Bound to be plenty.
71
73 This software is Copyright (c) 2001 - 2009, Damian Conway and Abigail.
74
75 This module is free software, and maybe used under any of the following
76 licenses:
77
78 1) The Perl Artistic License. See the file COPYRIGHT.AL.
79 2) The Perl Artistic License 2.0. See the file COPYRIGHT.AL2.
80 3) The BSD Licence. See the file COPYRIGHT.BSD.
81 4) The MIT Licence. See the file COPYRIGHT.MIT.
82
83
84
85perl v5.12.0 2010-01-02 Regexp::Common::URI::news(3)