- public int begin;
- public int end;
- public float score;
- public String type;
- public String description;
- public Hashtable otherDetails;
- public java.util.Vector links;
-
- // Feature group can be set from a features file
- // as a group of features between STARTGROUP and ENDGROUP markers
- public String featureGroup;
-
- public SequenceFeature()
- {}
- /**
- * Constructs a duplicate feature.
- * Note: Uses clone on the otherDetails so only shallow copies are made
- * of additional properties and method will silently fail if unclonable
- * objects are found in the hash.
- * @param cpy
- */
- public SequenceFeature(SequenceFeature cpy) {
- if (cpy!=null) {
- begin = cpy.begin;
- end = cpy.end;
- score = cpy.score;
- type = new String(cpy.type);
- description = new String(cpy.description);
- featureGroup = new String(cpy.featureGroup);
- if (cpy.otherDetails!=null) {
- try {
- otherDetails = (Hashtable) cpy.otherDetails.clone();
- } catch (Exception e) {
- // Uncloneable objects in the otherDetails - don't complain
- }
- }
- if (cpy.links!=null && cpy.links.size()>0) {
- links=new Vector();
- for (int i=0,iSize=cpy.links.size(); i<iSize; i++) {
- links.setElementAt(cpy.links.elementAt(i), i);
- }
- }
- }
- }
- public SequenceFeature(String type,
- String desc,
- String status,
- int begin, int end,
- String featureGroup)
- {
- this.type = type;
- this.description = desc;
- setValue("status", status);
- this.begin = begin;
- this.end = end;
- this.featureGroup = featureGroup;
- }