org.apache.batik.css.engine

Class StyleDeclaration

public class StyleDeclaration extends Object

This class represents a collection of CSS property values.
Field Summary
protected intcount
The number of values in the declaration.
protected int[]indexes
The value indexes.
protected static intINITIAL_LENGTH
protected boolean[]priorities
The value priorities.
protected Value[]values
The values.
Method Summary
voidappend(Value v, int idx, boolean prio)
Appends a value to the declaration.
intgetIndex(int idx)
Returns the property index of a value.
booleangetPriority(int idx)
Tells whether a value is important.
ValuegetValue(int idx)
Returns the value at the given index.
voidput(int idx, Value v, int i, boolean prio)
Sets a value within the declaration.
voidremove(int idx)
Removes the value at the given index.
intsize()
Returns the number of values in the declaration.
StringtoString(CSSEngine eng)
Returns a printable representation of this style rule.

Field Detail

count

protected int count
The number of values in the declaration.

indexes

protected int[] indexes
The value indexes.

INITIAL_LENGTH

protected static final int INITIAL_LENGTH

priorities

protected boolean[] priorities
The value priorities.

values

protected Value[] values
The values.

Method Detail

append

public void append(Value v, int idx, boolean prio)
Appends a value to the declaration.

getIndex

public int getIndex(int idx)
Returns the property index of a value.

getPriority

public boolean getPriority(int idx)
Tells whether a value is important.

getValue

public Value getValue(int idx)
Returns the value at the given index.

put

public void put(int idx, Value v, int i, boolean prio)
Sets a value within the declaration.

remove

public void remove(int idx)
Removes the value at the given index.

size

public int size()
Returns the number of values in the declaration.

toString

public String toString(CSSEngine eng)
Returns a printable representation of this style rule.
Copyright B) 2008 Apache Software Foundation. All Rights Reserved.