|
19 | 19 | */ |
20 | 20 | package org.neo4j.gds.leiden; |
21 | 21 |
|
22 | | -import org.neo4j.gds.AlgoBaseProc; |
23 | | -import org.neo4j.gds.AlgorithmFactory; |
24 | | -import org.neo4j.gds.core.CypherMapWrapper; |
25 | | -import org.neo4j.gds.executor.ComputationResultConsumer; |
| 22 | +import org.neo4j.gds.BaseProc; |
26 | 23 | import org.neo4j.gds.executor.ProcedureExecutor; |
27 | 24 | import org.neo4j.procedure.Description; |
28 | 25 | import org.neo4j.procedure.Name; |
|
31 | 28 | import java.util.Map; |
32 | 29 | import java.util.stream.Stream; |
33 | 30 |
|
| 31 | +import static org.neo4j.gds.AlgoBaseProc.STATS_DESCRIPTION; |
34 | 32 | import static org.neo4j.procedure.Mode.READ; |
35 | 33 |
|
36 | | -public class LeidenStatsProc extends AlgoBaseProc<Leiden, LeidenResult, LeidenStatsConfig, StatsResult> { |
| 34 | +public class LeidenStatsProc extends BaseProc { |
37 | 35 |
|
38 | 36 | @Procedure(value = "gds.alpha.leiden.stats", mode = READ) |
39 | 37 | @Description(STATS_DESCRIPTION) |
40 | 38 | public Stream<StatsResult> stats( |
41 | 39 | @Name(value = "graphName") String graphName, |
42 | 40 | @Name(value = "configuration", defaultValue = "{}") Map<String, Object> configuration |
43 | 41 | ) { |
44 | | - var statsSpec = new LeidenStatsSpec(); |
45 | 42 | return new ProcedureExecutor<>( |
46 | | - statsSpec, |
| 43 | + new LeidenStatsSpec(), |
47 | 44 | executionContext() |
48 | 45 | ).compute(graphName, configuration, true, true); |
49 | 46 | } |
50 | | - |
51 | | - |
52 | | - |
53 | | - @Override |
54 | | - @Deprecated |
55 | | - public AlgorithmFactory<?, Leiden, LeidenStatsConfig> algorithmFactory() { |
56 | | - return null; |
57 | | - } |
58 | | - |
59 | | - @Override |
60 | | - @Deprecated |
61 | | - public <T extends ComputationResultConsumer<Leiden, LeidenResult, LeidenStatsConfig, Stream<StatsResult>>> T computationResultConsumer() { |
62 | | - return null; |
63 | | - } |
64 | | - |
65 | | - @Override |
66 | | - @Deprecated |
67 | | - protected LeidenStatsConfig newConfig(String username, CypherMapWrapper config) { |
68 | | - return null; |
69 | | - } |
70 | 47 | } |
0 commit comments