Class CSSStyleSheetImpl
java.lang.Object
org.htmlunit.cssparser.dom.CSSStyleSheetImpl
- All Implemented Interfaces:
Serializable
Implementation of CSSStyleSheet.
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classCSSStyleSheetRuleIndex.(package private) static final classstatic final classSelectorEntry. -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate CSSRuleListImplprivate booleanprivate Stringprivate MediaListImplprivate Nodeprivate AbstractCSSRuleImplprivate String -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoiddeleteRule(int index) delete the rule at the given pos.booleanbooleangetHref()getMedia()getTitle()inthashCode()voidinsertRule(String rule, int index) inserts a new rule.private voidvoidClean the index.voidsetCssRules(CSSRuleListImpl rules) voidsetDisabled(boolean disabled) We will need to respond more fully if a stylesheet is disabled, probably by generating an event for the main application.voidSet the href.voidsetMediaText(String mediaText) Set the media text.voidsetOwnerNode(Node ownerNode) Set the owner node.voidsetOwnerRule(AbstractCSSRuleImpl ownerRule) voidSet the CSSStyleSheetRuleIndex.voidSet the title.toString()private void
-
Field Details
-
disabled_
private boolean disabled_ -
ownerNode_
-
href_
-
title_
-
media_
-
ownerRule_
-
cssRules_
-
index_
-
-
Constructor Details
-
CSSStyleSheetImpl
public CSSStyleSheetImpl()Ctor.
-
-
Method Details
-
getDisabled
public boolean getDisabled()- Returns:
- the disable state
-
setDisabled
public void setDisabled(boolean disabled) We will need to respond more fully if a stylesheet is disabled, probably by generating an event for the main application.- Parameters:
disabled- the new disabled
-
getOwnerNode
- Returns:
- the owner node
-
getHref
- Returns:
- the href
-
getTitle
- Returns:
- the title
-
getMedia
- Returns:
- the media list
-
getOwnerRule
- Returns:
- the owner rule
-
getCssRules
- Returns:
- the css rules
-
insertRule
inserts a new rule.- Parameters:
rule- the rule to insertindex- the insert pos- Throws:
DOMException- in case of error
-
deleteRule
delete the rule at the given pos.- Parameters:
index- the pos- Throws:
DOMException- in case of error
-
setOwnerNode
-
setHref
-
setTitle
-
setMediaText
Set the media text.- Parameters:
mediaText- the new media text
-
setOwnerRule
- Parameters:
ownerRule- the new ownerRule
-
setCssRules
- Parameters:
rules- the new rules
-
toString
-
equals
-
hashCode
-
writeObject
- Throws:
IOException
-
readObject
- Throws:
IOExceptionClassNotFoundException
-
getRuleIndex
- Returns:
- the CSSStyleSheetRuleIndex
-
setRuleIndex
Set the CSSStyleSheetRuleIndex.- Parameters:
index- the new index
-
resetRuleIndex
public void resetRuleIndex()Clean the index.
-