Package org.moltools.design.data.impl

Examples of org.moltools.design.data.impl.SimpleSubSequenceTemplate


  /**Returns the upstream part of the template (this is independent of target poly type)*/
  @Override
  protected void setTemplateForFivePrimeArm() {
    int pos = getTargetPosition();
    pat5 = new SimpleSubSequenceTemplate(this, "Template for 5' arm", //$NON-NLS-1$
                           getType(), 1, pos - 1,
                           getID());

  }
View Full Code Here


  protected void setTemplateForThreePrimeArm() {
    //There are three different modes to consider, target is position (no poly), SNP or InDel
    TargettedSequence template;
    String tempID = "TEMPLATE|3|"+getID(); //$NON-NLS-1$
    if (targetPoly == 0) { //No poly
      template = new SimpleSubSequenceTemplate(this, "Template for 3' arm", getType(), //$NON-NLS-1$
                             getTargetPosition(), length(), getID());
    }
    else { //Target is Poly
      Polymorphism poly = getPolys()[targetPoly - 1];
      if (poly instanceof SNP) {

        Nucleotide n = (Nucleotide) poly.getVariants()[variantIndex];
        if (n == null) {
          throw new UnsupportedOperationException("No target nucleotide found"); //$NON-NLS-1$
        }

        String seq = subsequence(getTargetPosition()+1, length());
        String nt = String.valueOf(n.getChar());
        String full = nt + seq;
       
        template = new SimpleSubSequenceTemplate(tempID, full, getType(),
                               getTargetPosition(), length(), getID());
      }
      else if (poly instanceof InDel) {
        switch (variantIndex) {
          case InDel.INS:
            template = new SimpleSubSequenceTemplate(this, tempID, getType(),
                                   getTargetPosition(), length(), getID());
            break;
          case InDel.DEL:
            template = new SimpleSubSequenceTemplate(this,tempID, getType(),
                                   getTargetPosition() + poly.length(), length(), getID());
            break;
          default:
            throw new UnsupportedOperationException(
                "Invalid InDel mode specified"); //$NON-NLS-1$
View Full Code Here

          pa3 = (PropertyAcceptorNucleotideSequence) p.getTSSPair().getSequence(TSSPair.KEY_THREE_PRIME);
        }
        catch (ClusterException e) {
          pa3 = null;
        }   
        SimpleSubSequenceTemplate threeTemplate = null;
        try {
          threeTemplate = (SimpleSubSequenceTemplate) t.getTemplateCluster().getSequence(ProbeMakerTarget.KEY_THREE_PRIME);
        }
        catch (ClusterException e) {
          ProbeMakerPropertyUtils.addMessage(p,new Message(
View Full Code Here

  }

  @Override
  protected TargettedSequence getTemplateForFivePrime() {
    //return the 5' half of the sequence, and keep the probe arms 3' end fixed
    return new SimpleSubSequenceTemplate(this, "TEMPLATE|5|"+getID(), //$NON-NLS-1$
                           getType(), 1,
                           length() / 2, getID());
  }
View Full Code Here

  }

  @Override
  protected TargettedSequence getTemplateForThreePrime() {
    //return the 3' half of the sequence, and keep the probe arms 5' end fixed
    return new SimpleSubSequenceTemplate(this, "TEMPLATE|3|"+getID(), //$NON-NLS-1$
                           getType(), length() / 2 + 1,
                           length(), getID());
  }
View Full Code Here

    super(id,sequence,name);
  }
 
  @Override
  protected TargettedSequence getTemplateForFivePrime() {
    return new SimpleSubSequenceTemplate(this,"Template",getType(),1,length(),getID())//$NON-NLS-1$
  }
View Full Code Here

      return;
    }
    //target is Poly
    Polymorphism poly = getPolys()[targetPoly - 1];
    if (poly instanceof SNP) {
      pat3 = new SimpleSubSequenceTemplate(this, "Template for 3' arm", getType(), //$NON-NLS-1$
          getTargetPosition() + 1,
          length(), getID());
      Nucleotide n = (Nucleotide) poly.getVariants()[variantIndex];
      if (n == null) {
        throw new UnsupportedOperationException("No target nucleotide found"); //$NON-NLS-1$
View Full Code Here

    /**Returns the part of the template downstream of the invader position*/
  @Override
  protected TargettedSequence getTemplateForFivePrime() {
    //return the sequence, and keep the probe arms 3' end fixed
    return new SimpleSubSequenceTemplate(this, "Template for 5' arm", //$NON-NLS-1$
                           getType(), targetPos + 1,
                           length(), getID());
  }
View Full Code Here

  /**Returns the part of the template downstream of the invader position*/
  @Override
  protected TargettedSequence getTemplateForThreePrime() {
    //return the sequence, and keep the probe arms 5' end fixed
    return new SimpleSubSequenceTemplate(this, "Template for 3' arm", //$NON-NLS-1$
                           getType(), targetPos + 1,
                           length(), getID());
  }
View Full Code Here

    super(id,sequence,name);
  }
 
  @Override
  protected TargettedSequence getTemplateForFivePrime() {
    return new SimpleSubSequenceTemplate(this,"Template",getType(),1,length(),getID())//$NON-NLS-1$
  }
View Full Code Here

TOP

Related Classes of org.moltools.design.data.impl.SimpleSubSequenceTemplate

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.