View Javadoc

    1   /*
    2    * Copyright (c) 2001-2003 The XDoclet team
    3    * All rights reserved.
    4    */
    5   package xjavadoc.predicates;
    6
    7   import xjavadoc.XProgramElement;
    8
    9   /***
    10   * Filter that accepts program elements that have a certain tag
    11   *
    12   * @created   29. juli 2002
    13   */
    14  public class HasTag extends ProgramElementPredicate
    15  {
    16  	private String     _tagName;
    17
    18  	public HasTag()
    19  	{
    20  	}
    21
    22  	public HasTag( String tagName )
    23  	{
    24  		setTagName( tagName );
    25  	}
    26
    27  	public void setTagName( String tagName )
    28  	{
    29  		_tagName = tagName;
    30  	}
    31
    32  	protected boolean evaluate( XProgramElement programElement )
    33  	{
    34  		return programElement.getDoc().hasTag( _tagName );
    35  	}
    36  }
    37