package net.ranides.demo.debugger;

import com.sun.jdi.VirtualMachine;
import net.ranides.demo.debugger.impl.CDiConnection;

public interface DiConnection extends AutoCloseable {

    static DiConnection connect(String addr) {
        return CDiConnection.connect(addr);
    }

    static DiConnection connect(String host, String port) {
        return CDiConnection.connect(host, port);
    }

    @Override
    void close();

    VirtualMachine vm();

    DiMirror mirror();

    DiLocation locate(String type, int line);

    DiLocation locate(String location);

    DiClasses types(String name);

    DiClasses types();

}
