mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
simplify
This commit is contained in:
@@ -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);
|
||||
|
||||
+5
@@ -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
-4
@@ -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 {
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user