.\" Automatically generated by Pod::Man 4.09 (Pod::Simple 3.35) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .if !\nF .nr F 0 .if \nF>0 \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} .\} .\" ======================================================================== .\" .IX Title "CSS::DOM::Exception 3pm" .TH CSS::DOM::Exception 3pm "2018-02-12" "perl v5.26.1" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" CSS::DOM::Exception \- The Exception interface for CSS::DOM .SH "SYNOPSIS" .IX Header "SYNOPSIS" .Vb 1 \& use CSS::DOM::Exception \*(AqSYNTAX_ERR\*(Aq; \& \& eval { \& die new CSS::DOM::Exception \& SYNTAX_ERR, \& \*(Aq1 is not a valid property declaration\*(Aq \& }; \& \& $@ == SYNTAX_ERR; # true \& \& print $@; # prints "1 is not a valid property declaration\en"; .Ve .SH "DESCRIPTION" .IX Header "DESCRIPTION" This module implementations the W3C's DOMException interface. CSS::DOM::Exception objects stringify to the message passed to the constructer and numify to the error number (see below, under '\s-1EXPORTS\s0'). .SH "METHODS" .IX Header "METHODS" .ie n .IP "new CSS::DOM::Exception $type, $message" 4 .el .IP "new CSS::DOM::Exception \f(CW$type\fR, \f(CW$message\fR" 4 .IX Item "new CSS::DOM::Exception $type, $message" This class method creates a new exception object. \f(CW$type\fR is expected to be an integer (you can use the constants listed under '\s-1EXPORTS\s0'). \&\f(CW$message\fR is the error message. .SH "EXPORTS" .IX Header "EXPORTS" The following constants are optionally exported. The descriptions are copied from the \s-1DOM\s0 spec. .IP "\s-1INDEX_SIZE_ERR\s0 (1)" 4 .IX Item "INDEX_SIZE_ERR (1)" If index or size is negative, or greater than the allowed value .IP "\s-1DOMSTRING_SIZE_ERR\s0 (2)" 4 .IX Item "DOMSTRING_SIZE_ERR (2)" If the specified range of text does not fit into a DOMString .IP "\s-1HIERARCHY_REQUEST_ERR\s0 (3)" 4 .IX Item "HIERARCHY_REQUEST_ERR (3)" If any node is inserted somewhere it doesn't belong .IP "\s-1WRONG_DOCUMENT_ERR\s0 (4)" 4 .IX Item "WRONG_DOCUMENT_ERR (4)" If a node is used in a different document than the one that created it (that doesn't support it) .IP "\s-1INVALID_CHARACTER_ERR\s0 (5)" 4 .IX Item "INVALID_CHARACTER_ERR (5)" If an invalid character is specified, such as in a name. .IP "\s-1NO_DATA_ALLOWED_ERR\s0 (6)" 4 .IX Item "NO_DATA_ALLOWED_ERR (6)" If data is specified for a node which does not support data .IP "\s-1NO_MODIFICATION_ALLOWED_ERR\s0 (7)" 4 .IX Item "NO_MODIFICATION_ALLOWED_ERR (7)" If an attempt is made to modify an object where modifications are not allowed .IP "\s-1NOT_FOUND_ERR\s0 (8)" 4 .IX Item "NOT_FOUND_ERR (8)" If an attempt was made to reference a node in a context where it does not exist .IP "\s-1NOT_SUPPORTED_ERR\s0 (9)" 4 .IX Item "NOT_SUPPORTED_ERR (9)" If the implementation does not support the type of object requested .IP "\s-1INUSE_ATTRIBUTE_ERR\s0 (10)" 4 .IX Item "INUSE_ATTRIBUTE_ERR (10)" If an attempt is made to add an attribute that is already inuse elsewhere .IP "\s-1INVALID_STATE_ERR\s0 (11)" 4 .IX Item "INVALID_STATE_ERR (11)" If an attempt is made to use an object that is not, or is no longer, usable .IP "\s-1SYNTAX_ERR\s0 (12)" 4 .IX Item "SYNTAX_ERR (12)" If an invalid or illegal string is specified .IP "\s-1INVALID_MODIFICATION_ERR\s0 (13)" 4 .IX Item "INVALID_MODIFICATION_ERR (13)" If an attempt is made to modify the type of the underlying object .IP "\s-1NAMESPACE_ERR\s0 (14)" 4 .IX Item "NAMESPACE_ERR (14)" If an attempt is made to create or change an object in a way which is incorrect with regard to namespaces .IP "\s-1INVALID_ACCESS_ERR\s0 (15)" 4 .IX Item "INVALID_ACCESS_ERR (15)" If a parameter or an operation is not supported by the underlying object .SH "SEE ALSO" .IX Header "SEE ALSO" \&\s-1CSS::DOM\s0, HTML::DOM::Exception