import java.util.Map;
import java.util.Map.Entry;
-import jalview.bin.Console;
-
/**
* A base class holding methods useful to all classes that implement commands
* for structure viewers
public List<StructureCommandI> colourBySequence(
Map<Object, AtomSpecModel> colourMap)
{
+ if (colourMap == null)
+ {
+ return null;
+ }
List<StructureCommandI> commands = new ArrayList<>();
StringBuilder sb = new StringBuilder(colourMap.size() * 20);
boolean first = true;
/*
* give up after 10 secs plus 1 sec per file
*/
+ if (files == null)
+ {
+ return true;
+ }
long starttime = System.currentTimeMillis();
long endTime = 10000 + 1000 * files.length + starttime;
String notLoaded = null;
public List<String> executeCommands(List<StructureCommandI> commands,
boolean getReply, String msg)
{
+ if (commands == null)
+ {
+ return null;
+ }
return executeCommand(getReply, msg,
commands.toArray(new StructureCommandI[commands.size()]));
}
AlignmentViewPanel viewPanel)
{
String[] files = getStructureFiles();
+ if (files == null)
+ {
+ return null;
+ }
SequenceRenderer sr = getSequenceRenderer(viewPanel);
FeatureRenderer fr = viewPanel.getFeatureRenderer();
FeatureColourFinder finder = new FeatureColourFinder(fr);