NAME
CSS::Selector - a Perl object oriented interface to the markup properties associated with a CSS Selector class.
SYNOPSIS
use CSS::Selector;
my $style = CSS::Selector->new(
-source => '/path/to/some.css',
-adaptor => 'AceGraphics');
my @styles = $css->styles;
my $tag = @styles[0];
my %markups = %{$css->style($tag)};
DESCRIPTION
CSS::Selector is intended to be accessed via a CSS object. It is a class to represent CSS selectors (duh!).
METHODS
This section describes the class and object methods for a CSS::Selector object.
CONSTRUCTORS
There is only one constructor, the new() method.
- $style = CSS::Selector->new(@options)
-
The new() method creates a new Selector object. The options are a set of property/value pairs as follows:
Option Value Default ------ ----- ------- -adaptor adaptor to be used to translate the default CSS properties. -source path to stylesheet file to be parsed. none -debug when true, debugging messages are false sent to STDERR.
new() will thow an exception if the -name tag is undefined.
ACCESSORS
The following accessor methods provide access to various attributes of the CSS object. Called with no arguments, they each return the current value of the attribute. Called with a single argument, they set the attribute and return its previous value.
Accessor Name Description
--------------- -----------
debug() Get/set debug mode
source() Get/set the source
name(),tag() Get/set the attributes of a Selector
value() Get the value of a Selector property
properties(),attributes() List the attributes of a Selector
BUGS
Please report them.
SEE ALSO
AUTHOR
Allen Day <day@cshl.org>
Copyright (c) 2001 Cold Spring Harbor Laboratory
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See DISCLAIMER.txt for disclaimers of warranty.
2 POD Errors
The following errors were encountered while parsing the POD:
- Around line 143:
'=item' outside of any '=over'
- Around line 161:
You forgot a '=back' before '=head2'