org.apache.tools.ant.types.resources.selectors

Class Type

public class Type extends Object implements ResourceSelector

Type file/dir ResourceSelector.

Since: Ant 1.7

Nested Class Summary
static classType.FileDir
Implements the type attribute.
Field Summary
static TypeDIR
Static dir type selector.
static TypeFILE
Static file type selector.
Constructor Summary
Type()
Default constructor.
Type(Type.FileDir fd)
Convenience constructor.
Method Summary
booleanisSelected(Resource r)
Return true if this Resource is selected.
voidsetType(Type.FileDir fd)
Set type; file|dir.

Field Detail

DIR

public static final Type DIR
Static dir type selector.

FILE

public static final Type FILE
Static file type selector.

Constructor Detail

Type

public Type()
Default constructor.

Type

public Type(Type.FileDir fd)
Convenience constructor.

Parameters: fd the FileDir type.

Method Detail

isSelected

public boolean isSelected(Resource r)
Return true if this Resource is selected.

Parameters: r the Resource to check.

Returns: whether the Resource was selected.

setType

public void setType(Type.FileDir fd)
Set type; file|dir.

Parameters: fd a FileDir object.