GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  CSS::SAC::LEXICALUNIT (3)

.ds Aq ’

NAME

CSS::SAC::LexicalUnit - SAC units

CONTENTS

SYNOPSIS



  use CSS::SAC::LexicalUnit qw(:constants);
  foo if $lu->is_type(LU_TYPE_CONSTANT);



DESCRIPTION

In the SAC spec, LexicalUnit is a linked list, that is, you only ever hold one LexicalUnit, and you ask for the next of for the previous one when you want to move on.

Such a model seems awkward, though I’m sure it makes sense somehow in Java, likely for a Java-specific reason.

In the Perl implementation, I have changed this. A LexicalUnit is an object that stands on it’s own and has no next/previous objects. Instead, the $handler->property callback gets called with a LexicalUnitList, which is in fact just an array ref of LexicalUnits.

We also don’t differentiate between IntegerValue, FloatValue, and StringValue, it’s always Value in Perl. This also applies to Parameters and SubValues. Both are called as Value and return an array ref of LexicalUnits.

I added the is_type() method, see CSS::SAC::Condition for advantages of that approach.

CONSTANTS

o ATTR
o CENTIMETER
o COUNTER_FUNCTION
o COUNTERS_FUNCTION
o DEGREE
o DIMENSION
o EM
o EX
o FUNCTION
o GRADIAN
o HERTZ
o IDENT
o INCH
o INHERIT
o INTEGER
o KILOHERTZ
o MILLIMETER
o MILLISECOND
o OPERATOR_COMMA
o OPERATOR_EXP
o OPERATOR_GE
o OPERATOR_GT
o OPERATOR_LE
o OPERATOR_LT
o OPERATOR_MINUS
o OPERATOR_MOD
o OPERATOR_MULTIPLY
o OPERATOR_PLUS
o OPERATOR_SLASH
o OPERATOR_TILDE
o PERCENTAGE
o PICA
o PIXEL
o POINT
o RADIAN
o REAL
o RECT_FUNCTION
o RGBCOLOR
o SECOND
o STRING_VALUE
o SUB_EXPRESSION
o UNICODERANGE
o URI

METHODS

o CSS::SAC::LexicalUnit->new($type,$text,$value) or $lu->new($type,$text,$value)

Creates a new unit. The $type must be one of the type constants, the text depends on the type of unit (unit text, func name, etc...), and the value is the content of the lu.

o $lu->DimensionUnitText([$dut]) or getDimensionUnitText

get/set the text of the dimension unit (eg cm, px, etc...)

o $lu->FunctionName([$fn]) or getFunctionName

get/set the name of the function (eg attr, uri, etc...)

o $lu->Value([$value]) or getValue

get/set the value of the lu (which may be another lu, or a lu list)

o $lu->LexicalUnitType([$type]) or getLexicalUnitType

get/set the type of the lu

o $lu->is_type($lu_constant)

returns true is this lu is of type $lu_constant

AUTHOR

Robin Berjon <robin@knowscape.com>

This module is licensed under the same terms as Perl itself.

Search for    or go to Top of page |  Section 3 |  Main Index


perl v5.20.3 CSS::SAC::LEXICALUNIT (3) 2001-08-17

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.