W3C home > Mailing lists > Public > www-dom@w3.org > October to December 2000

Expected RGBColor, Counter, Rect behavior

From: Blaine Brodie <bbrodie@savagesoftware.com>
Date: Thu, 05 Oct 2000 10:38:24 -0700
Message-id: <fc.0085846d000147df0085846d000147df.14805@savagesoftware.com>
To: www-dom@w3.org
If a user has a reference to an outstanding RGBColor, Counter or Rect
object and the object is removed from its parent CSSStyleDeclaration, are
calls to the outstanding objects expected to throw an exception?

Ex [assuming I have a CSSStyleDeclaration named 'style']

//create property
style.setProperty( "content", " counter(par-num, upper-roman) \". \"  ",
"" ); 

//retrieve counter object
CSSPrimitiveValue pv = (CSSPrimitiveValue)style.getPropertyCSSValue(
"content" );
Counter counter = pv.getCounterValue();

//remove property
style.removeProperty("content");


//use counter interface eventhough it has been removed.
counter.getIdentifier();

Should the last line throw some type of invalid state exception?  Thanks
for the clarification.
----
Blaine
Received on Thursday, 5 October 2000 13:38:55 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 22 June 2012 06:13:48 GMT