| Modifier and Type | Field and Description |
|---|---|
| protected final Array | |
| protected long | |
| protected boolean |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public int | attributesHash()
Returns: A hash code based on only the attribute values, which might be different compared to |
| public void | |
| public final int | compare(final Attribute arg0, final Attribute arg1)
Implements java. Used for sorting attributes by type (not by value) |
| public int | compareTo(Attributes other)
Implements java. Compares this object with the specified object for order. |
| private final void | |
| private final void | |
| public boolean | equals(Object other)
Overrides java. Implements java. Indicates whether some other object is "equal to" this comparator. |
| public final Attribute | Returns: The attribute (which can safely be cast) if any, otherwise nullExample usage: ((BlendingAttribute)material.get(BlendingAttribute.ID)).sourceFunction; |
| public final <T extends Attribute> T | |
| public final Array | |
| public final long | |
| public final boolean | has(final long type)
Returns: True if this collection has the specified attribute, i.e. attributes.has(ColorAttribute.Diffuse); Or when multiple attribute types are specified, true if this collection has all specified attributes, i.e. attributes.has(out, ColorAttribute.Diffuse | ColorAttribute.Specular | TextureAttribute.Diffuse); |
| public int | |
| protected int | indexOf(final long type)
Returns: the index of the attribute with the specified type or negative if not available. |
| public final Iterator | |
| public final void | remove(final long mask)
Removes the attribute from the material, i.e.: material.remove(BlendingAttribute.ID); Can also be used to remove multiple attributes also, i.e. remove(AttributeA.ID | AttributeB.ID); |
| public final boolean | Returns: True if this collection contains the same attributes (and optionally attribute values) as the other.True to compare attribute values, false to only compare attribute types compareValues)Check if this collection has the same attributes as the other collection. |
| public final boolean | Returns: True if this collection contains the same attributes (but not values) as the other. |
| public final void | |
| public final void | |
| public final void | |
| public final void | |
| public final void | |
| public final void | |
| public int | |
| public final void |
| attributes | back to summary |
|---|---|
| protected final Array<Attribute> attributes | |
| mask | back to summary |
|---|---|
| protected long mask | |
| sorted | back to summary |
|---|---|
| protected boolean sorted | |
| Attributes | back to summary |
|---|---|
| public Attributes() | |
| attributesHash | back to summary |
|---|---|
public int attributesHash()
| |
| clear | back to summary |
|---|---|
| public void clear() Removes all attributes | |
| compare | back to summary |
|---|---|
| public final int compare(final Attribute arg0, final Attribute arg1) Implements java. Used for sorting attributes by type (not by value)
| |
| compareTo | back to summary |
|---|---|
| public int compareTo(Attributes other) Implements java. Doc from java. Compares this object with the specified object for order. Returns a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object. The implementor must ensure The implementor must also ensure that the relation is transitive:
Finally, the implementor must ensure that
| |
| disable | back to summary |
|---|---|
| private final void disable(final long mask) | |
| enable | back to summary |
|---|---|
| private final void enable(final long mask) | |
| equals | back to summary |
|---|---|
| public boolean equals(Object other) Overrides java. Implements java. Doc from java. Indicates whether some other object is "equal to"
this comparator. This method must obey the general contract of
Note that it is always safe not to override
| |
| get | back to summary |
|---|---|
| public final Attribute get(final long type) Example usage: ((BlendingAttribute)material.get(BlendingAttribute.ID)).sourceFunction;
| |
| get | back to summary |
|---|---|
| public final <T extends Attribute> T get(Class<T> clazz, final long type) Example usage: ((BlendingAttribute)material.get(BlendingAttribute.ID)).sourceFunction;
| |
| get | back to summary |
|---|---|
| public final Array Get multiple attributes at once. Example: material.get(out, ColorAttribute.Diffuse | ColorAttribute.Specular | TextureAttribute.Diffuse); | |
| getMask | back to summary |
|---|---|
public final long getMask()
| |
| has | back to summary |
|---|---|
public final boolean has(final long type)
| |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Doc from java. Returns a hash code value for this object. This method is
supported for the benefit of hash tables such as those provided by
The general contract of
| |
| indexOf | back to summary |
|---|---|
protected int indexOf(final long type)
| |
| iterator | back to summary |
|---|---|
| public final Iterator Implements java. Used for iterating through the attributes
| |
| remove | back to summary |
|---|---|
| public final void remove(final long mask) Removes the attribute from the material, i.e.: material.remove(BlendingAttribute.ID); Can also be used to remove multiple attributes also, i.e. remove(AttributeA.ID | AttributeB.ID); | |
| same | back to summary |
|---|---|
| public final boolean same(final Attributes other, boolean compareValues) Check if this collection has the same attributes as the other collection. If compareValues is true, it also compares the values of each attribute.
| |
| same | back to summary |
|---|---|
public final boolean same(final Attributes other)
| |
| set | back to summary |
|---|---|
| public final void set(final Attribute attribute) Add a attribute to this material. If the material already contains an attribute of the same type it is overwritten. | |
| set | back to summary |
|---|---|
| public final void set(final Attribute attribute1, final Attribute attribute2) Add multiple attributes to this material. If the material already contains an attribute of the same type it is overwritten. | |
| set | back to summary |
|---|---|
| public final void set(final Attribute attribute1, final Attribute attribute2, final Attribute attribute3) Add multiple attributes to this material. If the material already contains an attribute of the same type it is overwritten. | |
| set | back to summary |
|---|---|
| public final void set(final Attribute attribute1, final Attribute attribute2, final Attribute attribute3, final Attribute attribute4) Add multiple attributes to this material. If the material already contains an attribute of the same type it is overwritten. | |
| set | back to summary |
|---|---|
| public final void set(final Attribute... attributes) Add an array of attributes to this material. If the material already contains an attribute of the same type it is overwritten. | |
| set | back to summary |
|---|---|
| public final void set(final Iterable<Attribute> attributes) Add an array of attributes to this material. If the material already contains an attribute of the same type it is overwritten. | |
| size | back to summary |
|---|---|
public int size()
| |
| sort | back to summary |
|---|---|
| public final void sort() Sort the attributes by their ID | |