Package org.sbml.jsbml.util.filters

Examples of org.sbml.jsbml.util.filters.SpeciesReferenceFilter


  /**
   * @throws java.lang.Exception
   */
  @Before
  public void setUp() throws Exception {
    filter = new SpeciesReferenceFilter(null, "modifier");
  }
View Full Code Here


   *         {@link #listOfModifiers} which has 'id' as species attribute (or
   *         name depending on the level and version). Can be null if it
   *         doesn't exist.
   */
  public ModifierSpeciesReference getModifierForSpecies(String id) {
    SpeciesReferenceFilter srf = new SpeciesReferenceFilter(id);
    srf.setFilterForSpecies(true);
    return getListOfModifiers().firstHit(srf);
  }
View Full Code Here

   * @return the {@link SpeciesReference} of the {@link #listOfProducts} which
   *         has 'id' as species attribute (or name depending on the level and
   *         version). Can be null if it doesn't exist.
   */
  public SpeciesReference getProductForSpecies(String id) {
    SpeciesReferenceFilter srf = new SpeciesReferenceFilter(id);
    srf.setFilterForSpecies(true);
    return getListOfProducts().firstHit(srf);
  }
View Full Code Here

   * @return the {@link SpeciesReference} of the {@link #listOfReactants}
   *         which has 'id' as species attribute (or name depending on the
   *         level and version). Can be null if it doesn't exist.
   */
  public SpeciesReference getReactantForSpecies(String id) {
    SpeciesReferenceFilter srf = new SpeciesReferenceFilter(id);
    srf.setFilterForSpecies(true);
    return getListOfReactants().firstHit(srf);
  }
View Full Code Here

   * @return
   */
  private boolean references(ListOf<? extends SimpleSpeciesReference> list,
      Species s) {
    if (list != null) {
      return list.firstHit(new SpeciesReferenceFilter(s)) != null;
    }
    return false;
  }
View Full Code Here

     * @param speciesReferences
     * @param species
     * @return
     */
    private static boolean contains(ListOf<? extends SimpleSpeciesReference> speciesReferences,  Species species) {
      return speciesReferences.firstHit(new SpeciesReferenceFilter(species)) != null;
    }
View Full Code Here

   *         {@link #listOfModifiers} which has 'id' as species attribute (or
   *         name depending on the level and version). Can be null if it
   *         doesn't exist.
   */
  public ModifierSpeciesReference getModifierForSpecies(String id) {
    SpeciesReferenceFilter srf = new SpeciesReferenceFilter(id);
    srf.setFilterForSpecies(true);
    return getListOfModifiers().firstHit(srf);
  }
View Full Code Here

   * @return the {@link SpeciesReference} of the {@link #listOfProducts} which
   *         has 'id' as species attribute (or name depending on the level and
   *         version). Can be null if it doesn't exist.
   */
  public SpeciesReference getProductForSpecies(String id) {
    SpeciesReferenceFilter srf = new SpeciesReferenceFilter(id);
    srf.setFilterForSpecies(true);
    return getListOfProducts().firstHit(srf);
  }
View Full Code Here

   * @return the {@link SpeciesReference} of the {@link #listOfReactants}
   *         which has 'id' as species attribute (or name depending on the
   *         level and version). Can be null if it doesn't exist.
   */
  public SpeciesReference getReactantForSpecies(String id) {
    SpeciesReferenceFilter srf = new SpeciesReferenceFilter(id);
    srf.setFilterForSpecies(true);
    return getListOfReactants().firstHit(srf);
  }
View Full Code Here

   *         {@link #listOfModifiers} which has 'id' as species attribute (or
   *         name depending on the level and version). Can be null if it
   *         doesn't exist.
   */
  public ModifierSpeciesReference getModifierForSpecies(String id) {
    SpeciesReferenceFilter srf = new SpeciesReferenceFilter(id);
    srf.setFilterForSpecies(true);
    return getListOfModifiers().firstHit(srf);
  }
View Full Code Here

TOP

Related Classes of org.sbml.jsbml.util.filters.SpeciesReferenceFilter

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.