import jalview.datamodel.AnnotatedCollectionI;
import jalview.datamodel.SequenceCollectionI;
import jalview.datamodel.SequenceI;
+import jalview.util.ColorUtils;
import java.awt.Color;
import java.util.Hashtable;
*/
public class CovariationColourScheme extends ResidueColourScheme
{
- public Hashtable helixcolorhash = new Hashtable();
+ public Map<String, Color> helixcolorhash = new Hashtable<String, Color>();
- public Hashtable positionsToHelix = new Hashtable();
+ public Map<Integer, String> positionsToHelix = new Hashtable<Integer, String>();
int numHelix = 0;
for (int j = 0; j <= numHelix; j++)
{
- helixcolorhash.put(Integer.toString(j),
- jalview.util.ColorUtils.generateRandomColor(Color.white));
+ helixcolorhash.put(String.valueOf(j),
+ ColorUtils.generateRandomColor(Color.white));
}
}
Color currentColour = Color.white;
String currentHelix = null;
// System.out.println(c + " " + j);
- currentHelix = (String) positionsToHelix.get(j);
+ currentHelix = positionsToHelix.get(j);
// System.out.println(positionsToHelix.get(j));
if (currentHelix != null)
{
- currentColour = (Color) helixcolorhash.get(currentHelix);
+ currentColour = helixcolorhash.get(currentHelix);
}
// System.out.println(c + " " + j + " helix " + currentHelix + " " +