/[pub]/suikawiki/script/misc/plugins/link/iw-spec.pm
Suika

Contents of /suikawiki/script/misc/plugins/link/iw-spec.pm

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (show annotations) (download)
Sun May 16 23:05:49 2010 UTC (15 years, 1 month ago) by wakaba
Branch: MAIN
CVS Tags: suikawiki3-redirect, HEAD
Error occurred while calculating annotation data.
added latest .pm files

1 use strict;
2 package SuikaWiki::Plugin::Registry;
3
4
5 our %Info;
6 $Info{q#InterWikiForSpecifications#}->{Name} = q#InterWikiForSpecifications#;
7 $Info{q#InterWikiForSpecifications#}->{q#Version#} = q#2004.0831.0328#;
8 $Info{q#InterWikiForSpecifications#}->{q#InterfaceVersion#} = q#2.9.1#;
9 $Info{q#InterWikiForSpecifications#}->{q#mkpluginVersion#} = q#2.1.19#;
10 $Info{q#InterWikiForSpecifications#}->{q#module_name#} = q#SuikaWiki::Plugin::plugin::InterWikiForSpecifications10407310328081Ll4#;
11 $Info{q#InterWikiForSpecifications#}->{q#Date.RCS#} = q#$Date: 2004/08/06 03:38:11 $#;
12 $Info{q#InterWikiForSpecifications#}->{RequiredPlugin} = [q#InterWikiCore#];
13 $Info{q#InterWikiForSpecifications#}->{RequiredModule} = [q#URI#];
14 $Info{q#InterWikiForSpecifications#}->{Description} = [[q#InterWiki - Technical Specifications such as W3C Recommendations#, q#en#, q##]];
15 $Info{q#InterWikiForSpecifications#}->{License} = [[q#%%Perl%%#, q##, q##]];
16 $Info{q#InterWikiForSpecifications#}->{Author} = [[[[q#Wakaba#, q#ja#, q#Latn#]], [[q#w@suika.fam.cx#]], [q##]]];
17 package SuikaWiki::Plugin::plugin::InterWikiForSpecifications10407310328081Ll4;
18
19
20 #line 1 "(WikiPlugin module source iw-spec.wp2, block Plugin/Use)"
21 require URI;
22 use Message::Util::Error;
23 #line 1 "(WikiPlugin module InterWikiForSpecifications, chunk 1)"
24
25 {my $def = {q#Parameter#, {}, q#Description#, [[q#"Path" extracted by "iws--select-w3c-dom".#, q#en#, q##]], q#main#, sub {my ($f, $rule_name, $p, $o, %opt) = @_;
26
27 #line 1 "(WikiPlugin module source iw-spec.wp2, block FormattingRule[name()='[q#link-to-resource#, q#view-resource#]/iws__path']/Formatting)"
28 $p->{-parent}->append_text ($o->{iwc__param}->{q#http://suika.fam.cx/~wakaba/archive/2004/8/6/iw-spec\#path#});}}
29 #line 1 "(WikiPlugin module InterWikiForSpecifications, chunk 2)"
30 ;
31 $SuikaWiki::Plugin::Rule{link_to_resource}->{iws__path} = $def;
32 $SuikaWiki::Plugin::Rule{view_resource}->{iws__path} = $def;
33 };
34
35 {my $def = {q#Parameter#, {}, q#Description#, [[q#"Module" extracted by "iws--select-w3c-dom".#, q#en#, q##]], q#main#, sub {my ($f, $rule_name, $p, $o, %opt) = @_;
36
37 #line 1 "(WikiPlugin module source iw-spec.wp2, block FormattingRule[name()='[q#link-to-resource#, q#view-resource#]/iws__module']/Formatting)"
38 $p->{-parent}->append_text ($o->{iwc__param}->{q#http://suika.fam.cx/~wakaba/archive/2004/8/6/iw-spec\#module#}); }}
39 #line 1 "(WikiPlugin module InterWikiForSpecifications, chunk 4)"
40 ;
41 $SuikaWiki::Plugin::Rule{link_to_resource}->{iws__module} = $def;
42 $SuikaWiki::Plugin::Rule{view_resource}->{iws__module} = $def;
43 };
44
45 $SuikaWiki::Plugin::Rule{link_to_resource}->{iws__select_w3c_dom} = {q#Parameter#, {q#SCHEMENAME#, {q#Type#, q#template#, q#Default#, q#(none)#, q#Description#, [[q#Template used when scheme name is SCHEMENAME#, q#en#, q##]]}, q#otherwise#, {q#Type#, q#template#, q#Default#, q#(none)#, q#Description#, [[q#Template used when no SCHEMENAME parameter matches#, q#en#, q##]]}, q#path#, {q#Type#, q#uri:path#, q#Default#, q#"Core/"#, q#Description#, [[q##, q#en#, q##]]}}, q#Description#, [[q#"Select" for W3C DOM Specifications (Level 2 or higher)#, q#en#, q##]], q#main#, sub {my ($f, $rule_name, $p, $o, %opt) = @_;
46
47 #line 1 "(WikiPlugin module source iw-spec.wp2, block FormattingRule[name()='[q#link-to-resource#]/iws__select_w3c_dom']/Formatting)"
48 my ($module, $path) = ('Core', '');
49 $p->{q#path#} = do { my $r = $f->parse_attr ($p=>q#path#, $o, -non_parsed_to_node => 1, %opt); ref $r?$r->inner_text:$r};
50 if ($p->{path} =~ m#(\w[^/]+)/(.+)#) {
51 $module = $1;
52 $path = $2;
53 }
54 (my $module2 = $module) =~ tr/-/_/;
55 local $o->{iwc__param}->{q#http://suika.fam.cx/~wakaba/archive/2004/8/6/iw-spec\#module#} = $module;
56 local $o->{iwc__param}->{q#http://suika.fam.cx/~wakaba/archive/2004/8/6/iw-spec\#path#} = $path;
57 my $rule;
58 if (defined $p->{$module2}) {
59 $rule = $p->{$module2} = do { my $r = $f->parse_attr ($p=>$module2, $o, -non_parsed_to_node => 1, %opt); ref $r?$r->inner_text:$r};
60 } else {
61 $rule = $p->{q#otherwise#} = do { my $r = $f->parse_attr ($p=>q#otherwise#, $o, -non_parsed_to_node => 1, %opt); ref $r?$r->inner_text:$r};
62 }
63 try {
64 $f->replace ($rule, param => $o, -parent => $p->{-parent});
65 } catch Message::Util::Formatter::error with {
66 my $err = shift;
67 if ($err->{-object}->{-category_name} eq $f->{-category_name}) {
68 my $wiki = $err->{option}->{param}->{wiki};
69 ($SuikaWiki::Plugin::Registry::Info{q#Error#}->{module_name} || SuikaWiki::Plugin->module_package (q#Error#))->reporting_formatting_template_error
70 ($err, $wiki,
71 template => $rule);
72 } else {
73 $err->throw;
74 }
75 };}}
76 #line 1 "(WikiPlugin module InterWikiForSpecifications, chunk 6)"
77 ;
78 package SuikaWiki::Plugin::Registry;
79
80 $Info{q#InterWikiForSpecifications#}->{provide} = {q#rule#, {q#link_to_resource#, [q#iws__path#, q#iws__module#, q#iws__select_w3c_dom#], q#view_resource#, [q#iws__path#, q#iws__module#]}};
81
82 1;

admin@suikawiki.org
ViewVC Help
Powered by ViewVC 1.1.24