git://source.jalview.org
/
jalview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
bugfix to avoid null pointer exceptions being raised for groups with no colourscheme...
[jalview.git]
/
src
/
jalview
/
datamodel
/
CigarCigar.java
diff --git
a/src/jalview/datamodel/CigarCigar.java
b/src/jalview/datamodel/CigarCigar.java
index
57848eb
..
83cce19
100644
(file)
--- a/
src/jalview/datamodel/CigarCigar.java
+++ b/
src/jalview/datamodel/CigarCigar.java
@@
-1,6
+1,6
@@
/*
* Jalview - A Sequence Alignment Editor and Viewer
/*
* Jalview - A Sequence Alignment Editor and Viewer
- * Copyright (C) 2006 AM Waterhouse, J Procter, G Barton, M Clamp, S Searle
+ * Copyright (C) 2007 AM Waterhouse, J Procter, G Barton, M Clamp, S Searle
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
@@
-22,14
+22,16
@@
public class CigarCigar
extends CigarSimple
{
SeqCigar refCigar;
extends CigarSimple
{
SeqCigar refCigar;
- /**
- * Apply CIGAR operations to the result of another cigar
- * @param cigar Cigar
- */
- CigarCigar(SeqCigar cigar) {
- super();
- refCigar = cigar;
- }
+ /**
+ * Apply CIGAR operations to the result of another cigar
+ * @param cigar Cigar
+ */
+ CigarCigar(SeqCigar cigar)
+ {
+ super();
+ refCigar = cigar;
+ }
+
/**
*
* @return String formed by applying CIGAR operations to the reference object
/**
*
* @return String formed by applying CIGAR operations to the reference object
@@
-38,13
+40,20
@@
public class CigarCigar
*/
public String getSequenceString(char GapChar)
{
*/
public String getSequenceString(char GapChar)
{
- if (length==0)
+ if (length == 0)
+ {
return "";
return "";
+ }
String refString = refCigar.getSequenceString(GapChar);
String refString = refCigar.getSequenceString(GapChar);
- if (refString!=null) {
- return (length==0) ? "" : (String) getSequenceAndDeletions(refString, GapChar)[0];
- } else
+ if (refString != null)
+ {
+ return (length == 0) ? "" :
+ (String) getSequenceAndDeletions(refString, GapChar)[0];
+ }
+ else
+ {
return null;
return null;
+ }
}
}
}
}