1 # $Id: NoUnicodeExt.pm,v 1.3 2003-07-30 13:39:23 matt Exp $
3 package XML::SAX::PurePerl::Reader;
10 sub switch_encoding_stream {
11 my ($fh, $encoding) = @_;
12 throw XML::SAX::Exception::Parse (
13 Message => "Only ASCII encoding allowed without perl 5.7.2 or higher. You tried: $encoding",
14 ) if $encoding !~ /(ASCII|UTF\-?8)/i;
17 sub switch_encoding_string {
18 my (undef, $encoding) = @_;
19 throw XML::SAX::Exception::Parse (
20 Message => "Only ASCII encoding allowed without perl 5.7.2 or higher. You tried: $encoding",
21 ) if $encoding !~ /(ASCII|UTF\-?8)/i;