net.sourceforge.plantuml.eggs.PSystemPathFactory Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of plantuml-mit Show documentation
Show all versions of plantuml-mit Show documentation
PlantUML is a component that allows to quickly write diagrams from text.
// THIS FILE HAS BEEN GENERATED BY A PREPROCESSOR.
package net.sourceforge.plantuml.eggs;
import net.sourceforge.plantuml.AbstractPSystem;
import net.sourceforge.plantuml.command.PSystemSingleLineFactory;
import net.sourceforge.plantuml.core.UmlSource;
import net.sourceforge.plantuml.regex.Matcher2;
import net.sourceforge.plantuml.regex.MyPattern;
import net.sourceforge.plantuml.regex.Pattern2;
public class PSystemPathFactory extends PSystemSingleLineFactory {
// ::remove folder when __HAXE__
// ::remove file when __CORE__
final private static Pattern2 p = MyPattern.cmpile("^path[%s]+([0-9A-Za-z]+)$");
@Override
protected AbstractPSystem executeLine(UmlSource source, String line) {
final Matcher2 m = p.matcher(line);
if (m.find() == false) {
return null;
}
return new PSystemPath(source, m.group(1));
}
}