Package Torello.Browser
Class CSS.CSSProperty
- java.lang.Object
-
- Torello.Java.JSON.BaseType
-
- Torello.Browser.CSS.CSSProperty
-
- All Implemented Interfaces:
java.io.Serializable
- Enclosing class:
- CSS
public static class CSS.CSSProperty extends BaseType implements java.io.Serializable
CSS property declaration data.- See Also:
- Serialized Form
Hi-Lited Source-Code:- View Here: Torello/Browser/CSS.java
- Open New Browser-Tab: Torello/Browser/CSS.java
File Size: 6,012 Bytes Line Count: 155 '\n' Characters Found
-
-
Field Summary
Serializable ID Modifier and Type Field protected static long
serialVersionUID
For Object Serialization.Type Properties Modifier and Type Field Boolean
disabled
Whether the property is disabled by the user (present for source-based properties only).Boolean
implicit
Whether the property is implicit (impliesfalse
if absent).Boolean
important
Whether the property has "!important" annotation (impliesfalse
if absent).String
name
The property name.Boolean
parsedOk
Whether the property is understood by the browser (impliestrue
if absent).CSS.SourceRange
range
The entire property range in the enclosing style declaration (if available).String
text
The full property text as specified in the style.String
value
The property value.
-
Constructor Summary
Constructors Constructor Description CSSProperty(String name, String value, Boolean important, Boolean implicit, String text, Boolean parsedOk, Boolean disabled, CSS.SourceRange range)
ConstructorCSSProperty(JsonObject jo)
JSON Object Constructor
-
Method Summary
Generate Array that Indicates which Parameter are Optional Modifier and Type Method boolean[]
optionals()
Implementing this method allows sub-classes to specify which JSON Properties may be absent or null.Methods: class java.lang.Object Modifier and Type Method boolean
equals(Object other)
Checks whether'this'
equals an input Java-Object
int
hashCode()
Generates a Hash-Code for'this'
instance
-
-
-
Field Detail
-
serialVersionUID
protected static final long serialVersionUID
For Object Serialization. java.io.Serializable- See Also:
- Constant Field Values
-
name
public final java.lang.String name
The property name.
-
value
public final java.lang.String value
The property value.
-
important
public final java.lang.Boolean important
Whether the property has "!important" annotation (impliesfalse
if absent).
OPTIONAL
-
implicit
public final java.lang.Boolean implicit
Whether the property is implicit (impliesfalse
if absent).
OPTIONAL
-
text
public final java.lang.String text
The full property text as specified in the style.
OPTIONAL
-
parsedOk
public final java.lang.Boolean parsedOk
Whether the property is understood by the browser (impliestrue
if absent).
OPTIONAL
-
disabled
public final java.lang.Boolean disabled
Whether the property is disabled by the user (present for source-based properties only).
OPTIONAL
-
range
public final CSS.SourceRange range
The entire property range in the enclosing style declaration (if available).
OPTIONAL
-
-
Constructor Detail
-
CSSProperty
public CSSProperty(java.lang.String name, java.lang.String value, java.lang.Boolean important, java.lang.Boolean implicit, java.lang.String text, java.lang.Boolean parsedOk, java.lang.Boolean disabled, CSS.SourceRange range)
Constructor- Parameters:
name
- The property name.value
- The property value.important
- Whether the property has "!important" annotation (impliesfalse
if absent).
OPTIONALimplicit
- Whether the property is implicit (impliesfalse
if absent).
OPTIONALtext
- The full property text as specified in the style.
OPTIONALparsedOk
- Whether the property is understood by the browser (impliestrue
if absent).
OPTIONALdisabled
- Whether the property is disabled by the user (present for source-based properties only).
OPTIONALrange
- The entire property range in the enclosing style declaration (if available).
OPTIONAL
-
CSSProperty
public CSSProperty(JsonObject jo)
JSON Object Constructor- Parameters:
jo
- A Json-Object having data about an instance of'CSSProperty'
.
-
-
Method Detail
-
optionals
public boolean[] optionals()
Description copied from class:BaseType
Implementing this method allows sub-classes to specify which JSON Properties may be absent or null. When binding aJsonObject
to a Java-Object, if some of the expected fields for the Java-Object map to Properties which might be left-out or omitted, then that may be indicated by setting that fields array positionTRUE
.
NOTE: This array should have a length equal to the number of fields contained by the Java Object. The first boolean in the array should specify whether the first Object Field may by absent. The second boolean should specify whether the second Object Field is optional in the JSON - and so on and so forth...
-
equals
public boolean equals(java.lang.Object other)
Checks whether'this'
equals an input Java-Object
- Overrides:
equals
in classjava.lang.Object
- Code:
- Exact Method Body:
if (other == null) return false; if (other.getClass() != this.getClass()) return false; CSSProperty o = (CSSProperty) other; return Objects.equals(this.name, o.name) && Objects.equals(this.value, o.value) && Objects.equals(this.important, o.important) && Objects.equals(this.implicit, o.implicit) && Objects.equals(this.text, o.text) && Objects.equals(this.parsedOk, o.parsedOk) && Objects.equals(this.disabled, o.disabled) && Objects.equals(this.range, o.range);
-
hashCode
public int hashCode()
Generates a Hash-Code for'this'
instance- Overrides:
hashCode
in classjava.lang.Object
- Code:
- Exact Method Body:
return Objects.hashCode(this.name) + Objects.hashCode(this.value) + Objects.hashCode(this.important) + Objects.hashCode(this.implicit) + Objects.hashCode(this.text) + Objects.hashCode(this.parsedOk) + Objects.hashCode(this.disabled) + this.range.hashCode();
-
-