package ch.usi.inf.sp.callgraph.renderer;

import java.util.Map;

public class TypeHierarchyEdge implements DotEdge {
    private final DotClassNode subClass;
    private final DotClassNode superClass;

    public TypeHierarchyEdge(DotClassNode subClass, DotClassNode superClass) {
        this.subClass = subClass;
        this.superClass = superClass;
    }

    public DotClassNode getFrom() {
        return subClass;
    }

    public DotClassNode getTo() {
        return superClass;
    }

    @Override
    public Map<String, String> getProperties() {
        return Map.of(
                "style", superClass.getStyle(),
                "color", "black"
        );
    }
}
