001package gudusoft.gsqlparser.analyzer.v2;
002
003import gudusoft.gsqlparser.ir.common.SourceAnchor;
004
005import java.util.List;
006
007/**
008 * A single entry in an impact analysis result.
009 */
010public class ImpactEntry {
011
012    /** Entity identifier (routine ID or table name). */
013    private final String entityId;
014
015    /** Human-readable entity name. */
016    private final String entityName;
017
018    /** Impact distance (0 = direct, 1 = one hop, etc.). */
019    private final int depth;
020
021    /** Impact path as a list of edge descriptions. */
022    private final List<String> impactPath;
023
024    /** Source code anchor. */
025    private final SourceAnchor anchor;
026
027    public ImpactEntry(String entityId, String entityName, int depth,
028                       List<String> impactPath, SourceAnchor anchor) {
029        this.entityId = entityId;
030        this.entityName = entityName;
031        this.depth = depth;
032        this.impactPath = impactPath;
033        this.anchor = anchor;
034    }
035
036    public String getEntityId() { return entityId; }
037    public String getEntityName() { return entityName; }
038    public int getDepth() { return depth; }
039    public List<String> getImpactPath() { return impactPath; }
040    public SourceAnchor getAnchor() { return anchor; }
041}