This commit is contained in:
Vladimir Krivosheev
2014-11-05 13:42:35 +01:00
parent cf5c7707fa
commit 9ffddb0e0a
3 changed files with 18 additions and 4 deletions
@@ -43,6 +43,11 @@ public abstract class BreakpointTarget {
return visitor.visitScript(script);
}
@Override
public String toString() {
return script.toString();
}
@Override
public boolean equals(Object o) {
if (this == o) {
@@ -61,6 +66,8 @@ public abstract class BreakpointTarget {
}
}
public abstract String toString();
/**
* A target that refers to a script by its name. Breakpoint will be set on every matching script currently loaded in VM.
*/
@@ -76,6 +83,11 @@ public abstract class BreakpointTarget {
return name;
}
@Override
public String toString() {
return name;
}
@Override
public <R> R accept(@NotNull Visitor<R> visitor) {
return visitor.visitScriptName(name);
@@ -19,6 +19,11 @@ public final class ScriptRegExpBreakpointTarget extends BreakpointTarget {
}
}
@Override
public String toString() {
return regExp;
}
@Override
public boolean equals(Object o) {
if (this == o) {
@@ -1,10 +1,7 @@
package org.jetbrains.debugger;
/**
* Supports targets that refer to a script by a 'regexp' of its name.
* After {@link Vm#setBreakpoint} is
* called, breakpoint will be set on every script currently loaded in VM whose name matches.
* E.g. you can safely set a breakpoint before the script is actually loaded.
* Supports targets that refer to a script by a 'regexp' of its name
*/
public interface ScriptRegExpSupport {
/**