protected String getStateLabel(ATNState s) {
if ( s==null ) return "null";
String stateLabel = "";
if (s instanceof BlockStartState) {
stateLabel += "→\\n";
}
else if (s instanceof BlockEndState) {
stateLabel += "←\\n";
}
stateLabel += String.valueOf(s.stateNumber);
if (s instanceof PlusBlockStartState || s instanceof PlusLoopbackState) {
stateLabel += "+";
}
else if (s instanceof StarBlockStartState || s instanceof StarLoopEntryState || s instanceof StarLoopbackState) {
stateLabel += "*";
}
if ( s instanceof DecisionState && ((DecisionState)s).decision>=0 ) {
stateLabel = stateLabel+"\\nd="+((DecisionState)s).decision;
}
return stateLabel;
}
DOTGenerator.java 文件源码
java
阅读 19
收藏 0
点赞 0
评论 0
项目:codebuff
作者:
评论列表
文章目录