Package com.jgalgo.graph
Interface WeightsBool<K>
- Type Parameters:
K
- the elements (vertices/edges) type
- All Known Subinterfaces:
IWeightsBool
Specific weights of
boolean
.- Author:
- Barak Ugav
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Get the default weight of this weights container.default Boolean
Deprecated.boolean
Get the weight associated with the given element.default Boolean
Deprecated.Please useget(Object)
instead to avoid un/boxing.void
Set the weight associated with the given element.default void
Deprecated.Please useset(Object, boolean)
instead to avoid un/boxing.
-
Method Details
-
get
Get the weight associated with the given element.- Parameters:
element
- an element (edge/vertex).- Returns:
- the weight associated with the given element.
-
getAsObj
Deprecated.Please useget(Object)
instead to avoid un/boxing.Get the weight associated with the given element.This method return the weight as an object, and should not be used when its known what type the weights are.
-
set
Set the weight associated with the given element.- Parameters:
element
- an element (edge/vertex).weight
- new weight that will be associated with the given element
-
setAsObj
Deprecated.Please useset(Object, boolean)
instead to avoid un/boxing.Set the weight associated with the given element.This method accept the weight as an object, and should not be used when its known what type the weights are.
-
defaultWeight
boolean defaultWeight()Get the default weight of this weights container.The default weight is the weight associated with all elements that were not explicitly set using
set(Object, boolean)
.- Returns:
- the default weight of this weights container.
-
defaultWeightAsObj
Deprecated.Please usedefaultWeight()
instead to avoid un/boxing.Get the default weight of this weights container.The default weight is the weight associated with all ids that were not explicitly set. This method return the default weight as an object, and should not be used when its known what type the weights are.
- Specified by:
defaultWeightAsObj
in interfaceWeights<K,
Boolean> - Returns:
- the default weight of this weights container
-
defaultWeight()
instead to avoid un/boxing.