155 |
my $methods; |
my $methods; |
156 |
if ( $class->can('meta') ) { |
if ( $class->can('meta') ) { |
157 |
$methods = dom2html( |
$methods = dom2html( |
|
h2 => [ 'Methods' ], |
|
158 |
ul => [ |
ul => [ |
159 |
map { ( |
map { ( |
160 |
li => [ a => { href => '/~/' . $self->package . '/' . $_ } => [ $_ ] ] |
li => [ a => { href => '/~/' . $self->package . '/' . $_ } => [ $_ ] ] |
161 |
) } $self->methods |
) } $self->methods |
162 |
] |
] |
163 |
); |
); |
164 |
|
$methods = "<h2>Methods</h2>$methods" if $methods; |
165 |
} else { |
} else { |
166 |
$methods = '<b>not introspectable</b>'; |
$methods = '<b>not introspectable</b>'; |
167 |
} |
} |
169 |
my $attributes; |
my $attributes; |
170 |
if ( $class->get_attribute_list ) { |
if ( $class->get_attribute_list ) { |
171 |
$attributes = dom2html( |
$attributes = dom2html( |
|
h2 => [ 'Atrributes' ], |
|
172 |
table => [ |
table => [ |
173 |
map { |
map { |
174 |
my $attr = $class->get_attribute($_); |
my $attr = $class->get_attribute($_); |
180 |
} $class->get_attribute_list |
} $class->get_attribute_list |
181 |
], |
], |
182 |
); |
); |
183 |
|
$attributes = "<h2>Attributes</h2>$attributes" if $attributes; |
184 |
} else { |
} else { |
185 |
$attributes = '<b>no attributes</b>'; |
$attributes = '<b>no attributes</b>'; |
186 |
} |
} |