+ /**
+ * Overrides the default implementation (which generates concatenated
+ * commands) to generate one per colour (because the XML-RPC interface to
+ * PyMOL only accepts one command at a time)
+ *
+ * @param colourMap
+ * @return
+ */
+ @Override
+ public List<StructureCommandI> colourBySequence(
+ Map<Object, AtomSpecModel> colourMap)
+ {
+ List<StructureCommandI> commands = new ArrayList<>();
+ for (Object key : colourMap.keySet())
+ {
+ Color colour = (Color) key;
+ final AtomSpecModel colourData = colourMap.get(colour);
+ commands.add(getColourCommand(colourData, colour));
+ }
+
+ return commands;
+ }
+