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 */ 021package org.biojavax.bio.seq.io; 022 023import org.biojava.bio.seq.io.SequenceBuilderFactory; 024import org.biojava.bio.symbol.PackedSymbolListFactory; 025 026/** 027 * Simple factory for constructing new RichSequenceBuilder objects. 028 * @author Richard Holland 029 * @author Mark Schreiber 030 * @since 1.5 031 */ 032public interface RichSequenceBuilderFactory extends SequenceBuilderFactory { 033 034 /** 035 * The value that will be used as a threshold for the <code>THRESHOLD</code> 036 * builder. Set to 5000. 037 */ 038 public final static int THRESHOLD_VALUE = 5000; 039 040 /** 041 * Accessor for the default factory. This implementation will not 042 * do any compression of a sequence regardless of size. 043 */ 044 public final static RichSequenceBuilderFactory FACTORY = new SimpleRichSequenceBuilderFactory(); 045 046 /** 047 * Accessor for a factory that produces builders that compress the 048 * <code>SymbolList</code> of a <code>RichSequence</code>. 049 */ 050 public final static RichSequenceBuilderFactory PACKED = new SimpleRichSequenceBuilderFactory(new PackedSymbolListFactory(), 0); 051 052 /** 053 * Accessor for a factory that produces builders that compress the 054 * <code>SymbolList</code> of a <code>RichSequence</code> when the length of the 055 * <code>SymbolList</code> exceeds <code>THRESHOLD</code>. 056 */ 057 public final static RichSequenceBuilderFactory THRESHOLD = new SimpleRichSequenceBuilderFactory(new PackedSymbolListFactory(), THRESHOLD_VALUE); 058 059 060 061}