mappingFields.add(((PatternScanMatch.PatternScanLocation) location).getLevel().getTagNumber()); mappingFields.add (((PatternScanMatch.PatternScanLocation) location).getCigarAlignment()); } else if (location instanceof PantherMatch.PantherLocation) { PantherMatch.PantherLocation pantherLocation = (PantherMatch.PantherLocation) location;
public Object clone() throws CloneNotSupportedException { final Set<PatternScanLocation> clonedLocations = new HashSet<PatternScanLocation>(this.getLocations().size()); for (PatternScanLocation location : this.getLocations()) { clonedLocations.add((PatternScanLocation) location.clone()); } return new PatternScanMatch(this.getSignature(), clonedLocations); }
public Object clone() throws CloneNotSupportedException { return new PatternScanLocation(this.getStart(), this.getEnd(), this.getLevel(), this.getCigarAlignment()); }
/** * Returns sequence alignment. * * @return Sequence alignment. */ @XmlElement(required = true) public String getAlignment() { if (cigarAlignment == null) { return null; } AlignmentEncoder encoder = new CigarAlignmentEncoder(); return encoder.decode(getMatch().getProtein().getSequence(), cigarAlignment, getStart(), getEnd()); }
public PatternScanLocation(int start, int end, Level level, String cigarAlignment) { super(start, end); setLevel(level); setCigarAlignment(cigarAlignment); }
private PatternScanMatch buildMatch(Signature signature, ProSitePatternRawMatch rawMatch) { PatternScanMatch.PatternScanLocation location = new PatternScanMatch.PatternScanLocation( rawMatch.getLocationStart(), rawMatch.getLocationEnd(), rawMatch.getPatternLevel(), rawMatch.getCigarAlignment()); return new PatternScanMatch(signature, rawMatch.getModelId(), Collections.singleton(location)); } }
public void setAlignment(String alignment) { AlignmentEncoder encoder = new CigarAlignmentEncoder(); setCigarAlignment(encoder.encode(alignment)); }