/[suikacvs]/messaging/manakai/lib/Message/URI/URIReference.pm
Suika

Diff of /messaging/manakai/lib/Message/URI/URIReference.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.5 by wakaba, Mon Jul 16 11:58:02 2007 UTC revision 1.6 by wakaba, Sat Aug 11 13:06:39 2007 UTC
# Line 9  push our @ISA, 'Message::IF::URIImplemen Line 9  push our @ISA, 'Message::IF::URIImplemen
9  sub create_uri_reference ($$) {  sub create_uri_reference ($$) {
10    if (UNIVERSAL::isa ($_[1], 'Message::IF::URIReference')) {    if (UNIVERSAL::isa ($_[1], 'Message::IF::URIReference')) {
11      local $Error::Depth = $Error::Depth + 1;      local $Error::Depth = $Error::Depth + 1;
12      return $_[1]->clone_uri_reference;      my $uri = $_[1]->uri_reference;
13        return bless \$uri, 'Message::URI::URIReference';
14    } elsif (ref $_[1] eq 'SCALAR') {    } elsif (ref $_[1] eq 'SCALAR') {
15      my $uri = $_[1];      my $uri = ''.${$_[1]};
16      return bless $uri, 'Message::URI::URIReference';      return bless \$uri, 'Message::URI::URIReference';
17    } else {    } else {
18      my $v = "$_[1]";      my $uri = ''.$_[1];
19      return bless \$v, 'Message::URI::URIReference';      return bless \$uri, 'Message::URI::URIReference';
20    }    }
21  }  } # create_uri_reference
   
 our $HasFeature;  
 $HasFeature->{'http://suika.fam.cx/www/2006/feature/uri'}->{''} = 1;  
 $HasFeature->{'http://suika.fam.cx/www/2006/feature/uri'}->{'4.0'} = 1;  
22    
23  package Message::IF::URIReference;  package Message::IF::URIReference;
24  package Message::URI::URIReference;  package Message::URI::URIReference;
# Line 2253  $r} Line 2250  $r}
2250  ,  ,
2251  fallback => 1;  fallback => 1;
2252    
2253    #      Portions of the Perl implementation contained in the module
2254    #      are derived from the example parser (April 7, 2004) available at
2255    #      <URI::http://www.gbiv.com/protocols/uri/rev-2002/uri_test.pl>
2256    #      that is placed in the Public Domain by Roy T. Fielding
2257    #      and Day Software, Inc.
2258    
2259  1;  1;
2260  ## License: <http://suika.fam.cx/~wakaba/archive/2004/8/18/license#Perl+MPL>  ## License: <http://suika.fam.cx/~wakaba/archive/2004/8/18/license#Perl+MPL>
2261  ## $Date$  ## $Date$

Legend:
Removed from v.1.5  
changed lines
  Added in v.1.6

admin@suikawiki.org
ViewVC Help
Powered by ViewVC 1.1.24