001/** 002 * BioJava development code 003 * 004 * This code may be freely distributed and modified under the 005 * terms of the GNU Lesser General Public Licence. This should 006 * be distributed with the code. If you do not have a copy, 007 * see: 008 * 009 * http://www.gnu.org/copyleft/lesser.html 010 * 011 * Copyright for this code is held jointly by the individual 012 * authors. These should be listed in @author doc comments. 013 * 014 * For more information on the BioJava project and its aims, 015 * or to join the biojava-l mailing list, visit the home page 016 * at: 017 * 018 * http://www.biojava.org/ 019 * 020 * Created on 2012-11-20 021 * Created by Douglas Myers-Turnbull 022 * 023 * @since 3.0.6 024 */ 025package org.biojava.nbio.structure.rcsb; 026 027import java.util.ArrayList; 028import java.util.List; 029 030/** 031 * Corresponds to a polymer in a {@code describeMol} XML file. 032 * 033 * @see <a href="http://www.pdb.org/pdb/software/rest.do#descPDB">RCSB RESTful</a> 034 * 035 * @author dmyerstu 036 * @since 3.0.6 037 */ 038public class RCSBPolymer { 039 040 private List<Character> chains; 041 042 private String description; 043 044 private String enzClass; 045 046 private Integer index; 047 048 private Integer length; 049 050 private RCSBMacromolecule molecule; 051 052 private List<String> synonyms; 053 054 private RCSBTaxonomy taxonomy; 055 056 private String type; 057 058 private Double weight; 059 060 public RCSBPolymer() { 061 chains = new ArrayList<Character>(); 062 synonyms = new ArrayList<String>(); 063 } 064 065 public List<Character> getChains() { 066 return chains; 067 } 068 069 public String getDescription() { 070 return description; 071 } 072 073 public String getEnzClass() { 074 return enzClass; 075 } 076 077 public Integer getIndex() { 078 return index; 079 } 080 081 public Integer getLength() { 082 return length; 083 } 084 085 public RCSBMacromolecule getMolecule() { 086 return molecule; 087 } 088 089 public List<String> getSynonyms() { 090 return synonyms; 091 } 092 093 public RCSBTaxonomy getTaxonomy() { 094 return taxonomy; 095 } 096 097 public String getType() { 098 return type; 099 } 100 101 public Double getWeight() { 102 return weight; 103 } 104 105 void addChain(char chain) { 106 chains.add(chain); 107 } 108 109 void addSynonym(String synonym) { 110 synonyms.add(synonym); 111 } 112 113 void setDescription(String description) { 114 this.description = description; 115 } 116 117 void setEnzClass(String enzClass) { 118 this.enzClass = enzClass; 119 } 120 121 void setIndex(Integer index) { 122 this.index = index; 123 } 124 125 void setLength(Integer length) { 126 this.length = length; 127 } 128 129 void setMolecule(RCSBMacromolecule molecule) { 130 this.molecule = molecule; 131 } 132 133 void setTaxonomy(RCSBTaxonomy taxonomy) { 134 this.taxonomy = taxonomy; 135 } 136 137 void setType(String string) { 138 type = string; 139 } 140 141 void setWeight(Double weight) { 142 this.weight = weight; 143 } 144 145}