public class Attribute<T> extends Object
Constructor and Description |
---|
Attribute(Class<T> cls,
String name,
NullaryFunction<T> initializer) |
Attribute(Class<T> cls,
String name,
T defaultValue) |
Modifier and Type | Method and Description |
---|---|
T |
get(AttributedObject node) |
static Attribute<?> |
get(int index) |
static Set<Attribute<?>> |
getAttributes(AttributedObject node) |
int |
index() |
boolean |
isSet(AttributedObject node) |
String |
name() |
static int |
numberOfAttributes() |
void |
set(AttributedObject node,
T arg) |
String |
toString() |
Class<?> |
type() |
public Attribute(Class<T> cls, String name, NullaryFunction<T> initializer)
public static int numberOfAttributes()
public static Attribute<?> get(int index)
public static Set<Attribute<?>> getAttributes(AttributedObject node)
public T get(AttributedObject node)
public void set(AttributedObject node, T arg)
public boolean isSet(AttributedObject node)
public String name()
public int index()
public Class<?> type()
Copyright © 2017 Oracle. All rights reserved.