Package de.unirostock.sems.xmlutils.alg
Class Weighter
- java.lang.Object
-
- de.unirostock.sems.xmlutils.alg.Weighter
-
- Direct Known Subclasses:
SemsWeighter,XyWeighter
public abstract class Weighter extends Object
The Class Weighter to compute the weight of nodes and subtrees in a document.- Author:
- Martin Scharm
-
-
Constructor Summary
Constructors Constructor Description Weighter()
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description abstract doublegetWeight(DocumentNode node)Computes the weight of a DocumentNode.abstract doublegetWeight(TextNode node)Computes the weight of a TextNode.
-
-
-
Method Detail
-
getWeight
public abstract double getWeight(DocumentNode node)
Computes the weight of a DocumentNode.- Parameters:
node- the node- Returns:
- the weight
-
getWeight
public abstract double getWeight(TextNode node)
Computes the weight of a TextNode.- Parameters:
node- the node- Returns:
- the weight
-
-