Class ClosenessCentrality
- java.lang.Object
-
- org.apache.hugegraph.computer.algorithm.centrality.closeness.ClosenessCentrality
-
- All Implemented Interfaces:
org.apache.hugegraph.computer.core.worker.Computation<ClosenessMessage>
public class ClosenessCentrality extends java.lang.Object implements org.apache.hugegraph.computer.core.worker.Computation<ClosenessMessage>
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringOPTION_SAMPLE_RATEstatic java.lang.StringOPTION_WEIGHT_PROPERTY
-
Constructor Summary
Constructors Constructor Description ClosenessCentrality()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Stringcategory()voidclose(org.apache.hugegraph.computer.core.config.Config config)voidcompute(org.apache.hugegraph.computer.core.worker.ComputationContext context, org.apache.hugegraph.computer.core.graph.vertex.Vertex vertex, java.util.Iterator<ClosenessMessage> messages)voidcompute0(org.apache.hugegraph.computer.core.worker.ComputationContext context, org.apache.hugegraph.computer.core.graph.vertex.Vertex vertex)voidinit(org.apache.hugegraph.computer.core.config.Config config)java.lang.Stringname()
-
-
-
Field Detail
-
OPTION_WEIGHT_PROPERTY
public static final java.lang.String OPTION_WEIGHT_PROPERTY
- See Also:
- Constant Field Values
-
OPTION_SAMPLE_RATE
public static final java.lang.String OPTION_SAMPLE_RATE
- See Also:
- Constant Field Values
-
-
Method Detail
-
name
public java.lang.String name()
- Specified by:
namein interfaceorg.apache.hugegraph.computer.core.worker.Computation<ClosenessMessage>
-
category
public java.lang.String category()
- Specified by:
categoryin interfaceorg.apache.hugegraph.computer.core.worker.Computation<ClosenessMessage>
-
init
public void init(org.apache.hugegraph.computer.core.config.Config config)
- Specified by:
initin interfaceorg.apache.hugegraph.computer.core.worker.Computation<ClosenessMessage>
-
close
public void close(org.apache.hugegraph.computer.core.config.Config config)
- Specified by:
closein interfaceorg.apache.hugegraph.computer.core.worker.Computation<ClosenessMessage>
-
compute0
public void compute0(org.apache.hugegraph.computer.core.worker.ComputationContext context, org.apache.hugegraph.computer.core.graph.vertex.Vertex vertex)- Specified by:
compute0in interfaceorg.apache.hugegraph.computer.core.worker.Computation<ClosenessMessage>
-
compute
public void compute(org.apache.hugegraph.computer.core.worker.ComputationContext context, org.apache.hugegraph.computer.core.graph.vertex.Vertex vertex, java.util.Iterator<ClosenessMessage> messages)- Specified by:
computein interfaceorg.apache.hugegraph.computer.core.worker.Computation<ClosenessMessage>
-
-