com.steadystate.css.dom
public class MediaListImpl extends java.lang.Object implements MediaList, java.io.Serializable
| Constructor and Description |
|---|
MediaListImpl(SACMediaList mediaList) |
| Modifier and Type | Method and Description |
|---|---|
void |
appendMedium(java.lang.String newMedium)
Adds the medium
newMedium to the end of the list. |
void |
deleteMedium(java.lang.String oldMedium)
Deletes the medium indicated by
oldMedium from the list. |
int |
getLength()
The number of media in the list.
|
java.lang.String |
getMediaText()
The parsable textual representation of the media list.
|
java.lang.String |
item(int index)
Returns the
indexth in the list. |
void |
setMediaText(java.lang.String mediaText) |
java.lang.String |
toString() |
public MediaListImpl(SACMediaList mediaList)
public java.lang.String getMediaText()
MediaListgetMediaText in interface MediaListpublic void setMediaText(java.lang.String mediaText)
throws org.w3c.dom.DOMException
setMediaText in interface MediaListorg.w3c.dom.DOMExceptionpublic int getLength()
MediaList0 to length-1 inclusive.public java.lang.String item(int index)
MediaListindexth in the list. If index is
greater than or equal to the number of media in the list, this
returns null.public void deleteMedium(java.lang.String oldMedium)
throws org.w3c.dom.DOMException
MediaListoldMedium from the list.deleteMedium in interface MediaListorg.w3c.dom.DOMException - NO_MODIFICATION_ALLOWED_ERR: Raised if this list is readonly.
oldMedium is not in the
list.public void appendMedium(java.lang.String newMedium)
throws org.w3c.dom.DOMException
MediaListnewMedium to the end of the list. If the
newMedium is already used, it is first removed.appendMedium in interface MediaListorg.w3c.dom.DOMException - INVALID_CHARACTER_ERR: If the medium contains characters that are
invalid in the underlying style language.
public java.lang.String toString()
toString in class java.lang.Object