X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fdatamodel%2FAlignmentView.java;h=6ab71c74530268fe5f7427156cfe077813d23a9c;hb=85299bc2db43c8b108169661ebc1c4d9b2d3d2e5;hp=d3d1b2b4b990832721a42a548598edb0c7254786;hpb=3d0101179759ef157b088ea135423cd909512d9f;p=jalview.git diff --git a/src/jalview/datamodel/AlignmentView.java b/src/jalview/datamodel/AlignmentView.java index d3d1b2b..6ab71c7 100644 --- a/src/jalview/datamodel/AlignmentView.java +++ b/src/jalview/datamodel/AlignmentView.java @@ -74,7 +74,7 @@ public class AlignmentView ScGroup() { - seqs = new ArrayList(); + seqs = new ArrayList<>(); } /** @@ -160,7 +160,6 @@ public class AlignmentView SequenceI[] selseqs; if (selection != null && selection.getSize() > 0) { - List sel = selection.getSequences(null); this.selected = new ScGroup(); selseqs = selection.getSequencesInOrder(alignment, selectedRegionOnly); @@ -170,9 +169,9 @@ public class AlignmentView selseqs = alignment.getSequencesArray(); } - List> seqsets = new ArrayList>(); + List> seqsets = new ArrayList<>(); // get the alignment's group list and make a copy - List grps = new ArrayList(); + List grps = new ArrayList<>(); List gg = alignment.getGroups(); grps.addAll(gg); ScGroup[] sgrps = null; @@ -185,7 +184,7 @@ public class AlignmentView // strip out any groups that do not actually intersect with the // visible and selected region int ssel = selection.getStartRes(), esel = selection.getEndRes(); - List isg = new ArrayList(); + List isg = new ArrayList<>(); for (SequenceGroup sg : grps) { if (!(sg.getStartRes() > esel || sg.getEndRes() < ssel)) @@ -245,7 +244,7 @@ public class AlignmentView { if (scGroups == null) { - scGroups = new ArrayList(); + scGroups = new ArrayList<>(); } addedgps[sg] = true; scGroups.add(sgrps[sg]); @@ -1129,11 +1128,11 @@ public class AlignmentView public static void testSelectionViews(AlignmentI alignment, HiddenColumns hidden, SequenceGroup selection) { - System.out.println("Testing standard view creation:\n"); + jalview.bin.Console.outPrintln("Testing standard view creation:\n"); AlignmentView view = null; try { - System.out.println( + jalview.bin.Console.outPrintln( "View with no hidden columns, no limit to selection, no groups to be collected:"); view = new AlignmentView(alignment, hidden, selection, false, false, false); @@ -1142,12 +1141,12 @@ public class AlignmentView } catch (Exception e) { e.printStackTrace(); - System.err.println( + jalview.bin.Console.errPrintln( "Failed to generate alignment with selection but no groups marked."); } try { - System.out.println( + jalview.bin.Console.outPrintln( "View with no hidden columns, no limit to selection, and all groups to be collected:"); view = new AlignmentView(alignment, hidden, selection, false, false, true); @@ -1155,12 +1154,12 @@ public class AlignmentView } catch (Exception e) { e.printStackTrace(); - System.err.println( + jalview.bin.Console.errPrintln( "Failed to generate alignment with selection marked but no groups marked."); } try { - System.out.println( + jalview.bin.Console.outPrintln( "View with no hidden columns, limited to selection and no groups to be collected:"); view = new AlignmentView(alignment, hidden, selection, false, true, false); @@ -1168,12 +1167,12 @@ public class AlignmentView } catch (Exception e) { e.printStackTrace(); - System.err.println( + jalview.bin.Console.errPrintln( "Failed to generate alignment with selection restricted but no groups marked."); } try { - System.out.println( + jalview.bin.Console.outPrintln( "View with no hidden columns, limited to selection, and all groups to be collected:"); view = new AlignmentView(alignment, hidden, selection, false, true, true); @@ -1181,12 +1180,12 @@ public class AlignmentView } catch (Exception e) { e.printStackTrace(); - System.err.println( + jalview.bin.Console.errPrintln( "Failed to generate alignment with selection restricted and groups marked."); } try { - System.out.println( + jalview.bin.Console.outPrintln( "View *with* hidden columns, no limit to selection, no groups to be collected:"); view = new AlignmentView(alignment, hidden, selection, true, false, false); @@ -1194,12 +1193,12 @@ public class AlignmentView } catch (Exception e) { e.printStackTrace(); - System.err.println( + jalview.bin.Console.errPrintln( "Failed to generate alignment with selection but no groups marked."); } try { - System.out.println( + jalview.bin.Console.outPrintln( "View *with* hidden columns, no limit to selection, and all groups to be collected:"); view = new AlignmentView(alignment, hidden, selection, true, false, true); @@ -1207,12 +1206,12 @@ public class AlignmentView } catch (Exception e) { e.printStackTrace(); - System.err.println( + jalview.bin.Console.errPrintln( "Failed to generate alignment with selection marked but no groups marked."); } try { - System.out.println( + jalview.bin.Console.outPrintln( "View *with* hidden columns, limited to selection and no groups to be collected:"); view = new AlignmentView(alignment, hidden, selection, true, true, false); @@ -1220,12 +1219,12 @@ public class AlignmentView } catch (Exception e) { e.printStackTrace(); - System.err.println( + jalview.bin.Console.errPrintln( "Failed to generate alignment with selection restricted but no groups marked."); } try { - System.out.println( + jalview.bin.Console.outPrintln( "View *with* hidden columns, limited to selection, and all groups to be collected:"); view = new AlignmentView(alignment, hidden, selection, true, true, true); @@ -1233,7 +1232,7 @@ public class AlignmentView } catch (Exception e) { e.printStackTrace(); - System.err.println( + jalview.bin.Console.errPrintln( "Failed to generate alignment with selection restricted and groups marked."); }