summaryrefslogtreecommitdiff
path: root/src/net/sourceforge/plantuml/activitydiagram3/command/CommandNolink.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/net/sourceforge/plantuml/activitydiagram3/command/CommandNolink.java')
-rw-r--r--src/net/sourceforge/plantuml/activitydiagram3/command/CommandNolink.java12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/net/sourceforge/plantuml/activitydiagram3/command/CommandNolink.java b/src/net/sourceforge/plantuml/activitydiagram3/command/CommandNolink.java
index 2bb62c3..4dbc8e9 100644
--- a/src/net/sourceforge/plantuml/activitydiagram3/command/CommandNolink.java
+++ b/src/net/sourceforge/plantuml/activitydiagram3/command/CommandNolink.java
@@ -2,7 +2,7 @@
* PlantUML : a free UML diagram generator
* ========================================================================
*
- * (C) Copyright 2009-2017, Arnaud Roques
+ * (C) Copyright 2009-2020, Arnaud Roques
*
* Project Info: http://plantuml.com
*
@@ -35,9 +35,11 @@
*/
package net.sourceforge.plantuml.activitydiagram3.command;
+import net.sourceforge.plantuml.LineLocation;
import net.sourceforge.plantuml.activitydiagram3.ActivityDiagram3;
import net.sourceforge.plantuml.command.CommandExecutionResult;
import net.sourceforge.plantuml.command.SingleLineCommand2;
+import net.sourceforge.plantuml.command.regex.IRegex;
import net.sourceforge.plantuml.command.regex.RegexConcat;
import net.sourceforge.plantuml.command.regex.RegexLeaf;
import net.sourceforge.plantuml.command.regex.RegexResult;
@@ -49,15 +51,15 @@ public class CommandNolink extends SingleLineCommand2<ActivityDiagram3> {
super(getRegexConcat());
}
- static RegexConcat getRegexConcat() {
- return new RegexConcat(new RegexLeaf("^"), //
+ static IRegex getRegexConcat() {
+ return RegexConcat.build(CommandNolink.class.getName(), RegexLeaf.start(), //
new RegexLeaf("nolink"), //
new RegexLeaf(";?"), //
- new RegexLeaf("$"));
+ RegexLeaf.end());
}
@Override
- protected CommandExecutionResult executeArg(ActivityDiagram3 diagram, RegexResult arg) {
+ protected CommandExecutionResult executeArg(ActivityDiagram3 diagram, LineLocation location, RegexResult arg) {
// diagram.setColorNextArrow(color);
diagram.setLabelNextArrow(Display.getWithNewlines("NOLINK"));
return CommandExecutionResult.ok();