Loading src/com/elphel/vdt/VDT.java +2 −0 Original line number Diff line number Diff line Loading @@ -158,5 +158,7 @@ public class VDT { public static final String GENERATOR_ID_STATE_DIR = "StateDir"; public static final String GENERATOR_ID_STATE_FILE = "StateFile"; public static final String TIME_STAMP_FORMAT = "yyyyMMddHHmmssSSS"; } // class VDT src/com/elphel/vdt/VerilogUtils.java +5 −1 Original line number Diff line number Diff line Loading @@ -24,8 +24,10 @@ import java.util.Iterator; import java.util.Set; import java.util.Vector; import com.elphel.vdt.ui.variables.SelectedResourceManager; import com.elphel.vdt.veditor.VerilogPlugin; import com.elphel.vdt.veditor.document.HdlDocument; import com.elphel.vdt.veditor.document.VerilogDocument; import com.elphel.vdt.veditor.parser.OutlineContainer; import com.elphel.vdt.veditor.parser.OutlineDatabase; //import com.elphel.vdt.veditor.parser.vhdl.VhdlOutlineElementFactory.PackageDeclElement; Loading Loading @@ -67,7 +69,9 @@ public class VerilogUtils { e.printStackTrace(); } if (hdlDocument!=null) return hdlDocument.getOutlineDatabase(); /* will create a new one if does not exist */ return null; // Create HdlDocument from selected/restored HDLfile hdlDocument=new VerilogDocument(project, (IFile) SelectedResourceManager.getDefault().getChosenVerilogFile()); return hdlDocument.getOutlineDatabase(); /* will create a new one if does not exist */ } public static String [] getExtList(String str){ Loading src/com/elphel/vdt/core/options/ParamBasedListOption.java +1 −1 Original line number Diff line number Diff line Loading @@ -39,7 +39,7 @@ public class ParamBasedListOption extends ParamBasedOption { /** * Set the option value * * @param value the sequnce of the list items separated by SEPARATOR. * @param value the sequence of the list items separated by SEPARATOR. */ public void setValue(String value) { List<String> list = OptionsUtils.convertStringToList(value); Loading src/com/elphel/vdt/core/options/ValueBasedListOption.java +1 −1 Original line number Diff line number Diff line Loading @@ -46,7 +46,7 @@ public class ValueBasedListOption extends Option { /** * Set the option value * * @param value the sequnce of the list items separated by SEPARATOR. * @param value the sequence of the list items separated by SEPARATOR. */ public void setValue(String value) { List<String> list = OptionsUtils.convertStringToList(value); Loading src/com/elphel/vdt/core/tools/config/xml/XMLConfig.java +17 −7 Original line number Diff line number Diff line Loading @@ -114,6 +114,7 @@ public class XMLConfig extends Config { static final String CONTEXT_TOOL_DEPENDS_LIST_TAG = "depends-list"; static final String CONTEXT_TOOL_DEPENDS_TAG = "depends"; static final String CONTEXT_TOOL_DEPENDS_STATE_TAG = "state"; static final String CONTEXT_TOOL_DEPENDS_FILES_TAG = "files"; // TODO: May add other types of dependencies static final String CONTEXT_TOOL_DFLT_ACTION_LABEL = "Run for"; Loading Loading @@ -663,7 +664,8 @@ public class XMLConfig extends Config { List<String> toolExtensionsList = readToolExtensionsList(contextNode, contextName); List<RunFor> toolRunfor= readToolRunForList(contextNode, contextName); List<String> toolDepends= readToolDependsList(contextNode, contextName); List<String> toolDependsStates= readToolDependsList(contextNode, contextName,false); List<String> toolDependsFiles= readToolDependsList(contextNode, contextName,true); if (VerilogPlugin.getPreferenceBoolean(PreferenceStrings.DEBUG_OTHER)) { System.out.println("contextNode.getNodeValue()="+contextNode.getNodeValue()); Loading Loading @@ -692,7 +694,8 @@ public class XMLConfig extends Config { toolInfo, toolRunfor, ignoreFilter, toolDepends, toolDependsStates, toolDependsFiles, logDir, stateDir, disabled, Loading Loading @@ -1045,9 +1048,12 @@ public class XMLConfig extends Config { return extList; } private List<String> readToolDependsList(Node toolNode, String toolName) private List<String> readToolDependsList(Node toolNode, String toolName, boolean filesNotStates) throws ConfigException { String filesStateTag= filesNotStates?CONTEXT_TOOL_DEPENDS_FILES_TAG:CONTEXT_TOOL_DEPENDS_STATE_TAG; String otherTag= (!filesNotStates)?CONTEXT_TOOL_DEPENDS_FILES_TAG:CONTEXT_TOOL_DEPENDS_STATE_TAG; String toolInfo = "Tool '" + toolName + "'"; List<String> depList = new ArrayList<String>(); Loading @@ -1066,10 +1072,14 @@ public class XMLConfig extends Config { // TODO: allow here other types of dependencies (conditionals(source files) for(Iterator<Node> n = depNodes.iterator(); n.hasNext();) { Node node = (Node)n.next(); String dep = getAttributeValue(node, CONTEXT_TOOL_DEPENDS_STATE_TAG); if(dep == null) throw new ConfigException(toolInfo + ": Attribute '" + CONTEXT_TOOL_DEPENDS_STATE_TAG + "' is absent"); String dep = getAttributeValue(node, filesStateTag); if (dep != null) { depList.add(dep); } else if (getAttributeValue(node, otherTag)==null){ throw new ConfigException(toolInfo + ": Both alternative attributes '" + CONTEXT_TOOL_DEPENDS_FILES_TAG + " and '"+CONTEXT_TOOL_DEPENDS_STATE_TAG +"' are absent"); } } return depList; } Loading Loading
src/com/elphel/vdt/VDT.java +2 −0 Original line number Diff line number Diff line Loading @@ -158,5 +158,7 @@ public class VDT { public static final String GENERATOR_ID_STATE_DIR = "StateDir"; public static final String GENERATOR_ID_STATE_FILE = "StateFile"; public static final String TIME_STAMP_FORMAT = "yyyyMMddHHmmssSSS"; } // class VDT
src/com/elphel/vdt/VerilogUtils.java +5 −1 Original line number Diff line number Diff line Loading @@ -24,8 +24,10 @@ import java.util.Iterator; import java.util.Set; import java.util.Vector; import com.elphel.vdt.ui.variables.SelectedResourceManager; import com.elphel.vdt.veditor.VerilogPlugin; import com.elphel.vdt.veditor.document.HdlDocument; import com.elphel.vdt.veditor.document.VerilogDocument; import com.elphel.vdt.veditor.parser.OutlineContainer; import com.elphel.vdt.veditor.parser.OutlineDatabase; //import com.elphel.vdt.veditor.parser.vhdl.VhdlOutlineElementFactory.PackageDeclElement; Loading Loading @@ -67,7 +69,9 @@ public class VerilogUtils { e.printStackTrace(); } if (hdlDocument!=null) return hdlDocument.getOutlineDatabase(); /* will create a new one if does not exist */ return null; // Create HdlDocument from selected/restored HDLfile hdlDocument=new VerilogDocument(project, (IFile) SelectedResourceManager.getDefault().getChosenVerilogFile()); return hdlDocument.getOutlineDatabase(); /* will create a new one if does not exist */ } public static String [] getExtList(String str){ Loading
src/com/elphel/vdt/core/options/ParamBasedListOption.java +1 −1 Original line number Diff line number Diff line Loading @@ -39,7 +39,7 @@ public class ParamBasedListOption extends ParamBasedOption { /** * Set the option value * * @param value the sequnce of the list items separated by SEPARATOR. * @param value the sequence of the list items separated by SEPARATOR. */ public void setValue(String value) { List<String> list = OptionsUtils.convertStringToList(value); Loading
src/com/elphel/vdt/core/options/ValueBasedListOption.java +1 −1 Original line number Diff line number Diff line Loading @@ -46,7 +46,7 @@ public class ValueBasedListOption extends Option { /** * Set the option value * * @param value the sequnce of the list items separated by SEPARATOR. * @param value the sequence of the list items separated by SEPARATOR. */ public void setValue(String value) { List<String> list = OptionsUtils.convertStringToList(value); Loading
src/com/elphel/vdt/core/tools/config/xml/XMLConfig.java +17 −7 Original line number Diff line number Diff line Loading @@ -114,6 +114,7 @@ public class XMLConfig extends Config { static final String CONTEXT_TOOL_DEPENDS_LIST_TAG = "depends-list"; static final String CONTEXT_TOOL_DEPENDS_TAG = "depends"; static final String CONTEXT_TOOL_DEPENDS_STATE_TAG = "state"; static final String CONTEXT_TOOL_DEPENDS_FILES_TAG = "files"; // TODO: May add other types of dependencies static final String CONTEXT_TOOL_DFLT_ACTION_LABEL = "Run for"; Loading Loading @@ -663,7 +664,8 @@ public class XMLConfig extends Config { List<String> toolExtensionsList = readToolExtensionsList(contextNode, contextName); List<RunFor> toolRunfor= readToolRunForList(contextNode, contextName); List<String> toolDepends= readToolDependsList(contextNode, contextName); List<String> toolDependsStates= readToolDependsList(contextNode, contextName,false); List<String> toolDependsFiles= readToolDependsList(contextNode, contextName,true); if (VerilogPlugin.getPreferenceBoolean(PreferenceStrings.DEBUG_OTHER)) { System.out.println("contextNode.getNodeValue()="+contextNode.getNodeValue()); Loading Loading @@ -692,7 +694,8 @@ public class XMLConfig extends Config { toolInfo, toolRunfor, ignoreFilter, toolDepends, toolDependsStates, toolDependsFiles, logDir, stateDir, disabled, Loading Loading @@ -1045,9 +1048,12 @@ public class XMLConfig extends Config { return extList; } private List<String> readToolDependsList(Node toolNode, String toolName) private List<String> readToolDependsList(Node toolNode, String toolName, boolean filesNotStates) throws ConfigException { String filesStateTag= filesNotStates?CONTEXT_TOOL_DEPENDS_FILES_TAG:CONTEXT_TOOL_DEPENDS_STATE_TAG; String otherTag= (!filesNotStates)?CONTEXT_TOOL_DEPENDS_FILES_TAG:CONTEXT_TOOL_DEPENDS_STATE_TAG; String toolInfo = "Tool '" + toolName + "'"; List<String> depList = new ArrayList<String>(); Loading @@ -1066,10 +1072,14 @@ public class XMLConfig extends Config { // TODO: allow here other types of dependencies (conditionals(source files) for(Iterator<Node> n = depNodes.iterator(); n.hasNext();) { Node node = (Node)n.next(); String dep = getAttributeValue(node, CONTEXT_TOOL_DEPENDS_STATE_TAG); if(dep == null) throw new ConfigException(toolInfo + ": Attribute '" + CONTEXT_TOOL_DEPENDS_STATE_TAG + "' is absent"); String dep = getAttributeValue(node, filesStateTag); if (dep != null) { depList.add(dep); } else if (getAttributeValue(node, otherTag)==null){ throw new ConfigException(toolInfo + ": Both alternative attributes '" + CONTEXT_TOOL_DEPENDS_FILES_TAG + " and '"+CONTEXT_TOOL_DEPENDS_STATE_TAG +"' are absent"); } } return depList; } Loading