Class BasicProtein

java.lang.Object
org.forester.protein.BasicProtein
All Implemented Interfaces:
Protein

public class BasicProtein extends Object implements Protein
  • Field Details

    • DomainMidPositionComparator

      public static Comparator<Domain> DomainMidPositionComparator
  • Constructor Details

    • BasicProtein

      public BasicProtein(String id_str, String species_str, int length)
  • Method Details

    • addProteinDomain

      public void addProteinDomain(Domain protein_domain)
      Specified by:
      addProteinDomain in interface Protein
    • contains

      public boolean contains(List<String> query_domain_ids, boolean in_nc_order)
      Description copied from interface: Protein
      If in_nc_order is set to true, this should return true only and only if the order in List 'domains' and this protein (as determined by the start positions of the domains of this proteins, _not_ by their index) are the same (interspersing, 'other', domains in this are ignored). If in_nc_order is set to false, this should return true only and only if this contains all domains listed in 'domains' (order and count do not matter).
      Specified by:
      contains in interface Protein
      Parameters:
      query_domain_ids - a list of domain ids in a certain order.
      in_nc_order - to consider order
      Returns:
    • getAccession

      public String getAccession()
      Specified by:
      getAccession in interface Protein
    • getDescription

      public String getDescription()
      Specified by:
      getDescription in interface Protein
    • getDomainsSortedByPosition

      public List<Domain> getDomainsSortedByPosition()
      Specified by:
      getDomainsSortedByPosition in interface Protein
    • getLength

      public int getLength()
      Specified by:
      getLength in interface Protein
    • getName

      public String getName()
      Specified by:
      getName in interface Protein
    • getNumberOfProteinDomains

      public int getNumberOfProteinDomains()
      Specified by:
      getNumberOfProteinDomains in interface Protein
    • getProteinDomain

      public Domain getProteinDomain(int index)
      Specified by:
      getProteinDomain in interface Protein
    • getProteinDomainCount

      public int getProteinDomainCount(String domain_id)
      Specified by:
      getProteinDomainCount in interface Protein
    • getProteinDomains

      public List<Domain> getProteinDomains()
      Specified by:
      getProteinDomains in interface Protein
    • getProteinDomains

      public List<Domain> getProteinDomains(String domain_id)
      Specified by:
      getProteinDomains in interface Protein
    • getProteinId

      public ProteinId getProteinId()
      Specified by:
      getProteinId in interface Protein
    • getSpecies

      public Species getSpecies()
      Specified by:
      getSpecies in interface Protein
    • setAccession

      public void setAccession(String accession)
    • setDescription

      public void setDescription(String description)
    • setName

      public void setName(String name)
    • toDomainArchitectureString

      public String toDomainArchitectureString(String separator)
    • toDomainArchitectureString

      public String toDomainArchitectureString(String separator, int repeats_limit, String repeat_separator)
    • toString

      public String toString()
      Overrides:
      toString in class Object