Skip to content

Commit

Permalink
fix for chrom alias defaults
Browse files Browse the repository at this point in the history
  • Loading branch information
jrobinso committed Sep 30, 2024
1 parent 5629b43 commit c644d51
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 8 deletions.
20 changes: 12 additions & 8 deletions src/main/java/org/broad/igv/feature/genome/ChromAlias.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,34 +5,38 @@
import java.util.Map;

public class ChromAlias {

private String chr;

/**
* Map of name set -> alias
*/
private Map<String, String> aliases;

public ChromAlias(String chr) {
this.chr = chr;
this.aliases = new HashMap<>();
}

public String getChr() {
return chr;
}

public void put(String nameSet, String alias) {
aliases.put(nameSet, alias);
}

public String get(String nameSet) {
return aliases.get(nameSet);
}

public boolean containsKey(String nameSet) {
return aliases.containsKey(nameSet);
}

public Collection<String> values() {
return aliases.values();
}





}
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ private void init(String id, List<String> chromosomeNames) {

boolean skipRest = false;
ChromAlias record = new ChromAlias(name);
record.put("__CANONICAL__", name);
aliasRecords.add(record);

//
Expand Down

0 comments on commit c644d51

Please sign in to comment.