Package org.cytoscape.filter.model
Interface CompositeFilter<C,E>
-
- Type Parameters:
C- The context type of the elements thisFilteroperates on.E- The element type thisFilteroperates on.
- All Superinterfaces:
Filter<C,E>,Transformer<C,E>
public interface CompositeFilter<C,E> extends Filter<C,E>
AFilterthat computes the set-union or set-intersection of theFilters it contains. The ordering of the child filters does not affect the final output of this filter, but may impact performance.Module:
filter-apiTo use this in your app, include the following dependency in your POM:
<dependency> <groupId>org.cytoscape</groupId> <artifactId>filter-api</artifactId> </dependency>
Cytoscape Backwards Compatibility (API Interface): We expect that this interface will be used but not implemented by developers using this interface. As such, we reserve the right to add methods to the interface as part of minor version upgrades. We will not remove methods for any changes other than major version upgrades.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classCompositeFilter.TypeDetermines how aCompositeFiltercombines the results of its containedFilters.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidappend(Filter<C,E> filter)Appendsfilterto the list of children.Filter<C,E>get(int index)Returns theFilterat the given index.intgetLength()Returns the number of direct childrenFilters contained by thisCompositeFilter.CompositeFilter.TypegetType()Returns the type of combining semantics used by this filter.intindexOf(Filter<C,E> filter)Returns the index offilterwithin the list of children, or-1iffilteris not in that list.voidinsert(int index, Filter<C,E> filter)Insertsfilterat the given index within the list of children.Filter<C,E>remove(int index)Removes theFilterat the given index from the list of children and returns in.voidsetType(CompositeFilter.Type type)Sets the type of combining semantics used by this filter.-
Methods inherited from interface org.cytoscape.filter.model.Filter
accepts, isAlwaysFalse
-
Methods inherited from interface org.cytoscape.filter.model.Transformer
addListener, getContextType, getElementType, getId, getName, removeListener
-
-
-
-
Method Detail
-
append
void append(Filter<C,E> filter)
Appendsfilterto the list of children.- Parameters:
filter- theFilterto add.
-
insert
void insert(int index, Filter<C,E> filter)Insertsfilterat the given index within the list of children.- Parameters:
index- the index where the filter should be inserted.filter- theFilterto add.
-
get
Filter<C,E> get(int index)
Returns theFilterat the given index.- Parameters:
index- the index of theFilterto get.- Returns:
- the
Filterat the given index.
-
remove
Filter<C,E> remove(int index)
Removes theFilterat the given index from the list of children and returns in.- Parameters:
index- the index of theFilterto get.- Returns:
- the
Filterat the given index.
-
indexOf
int indexOf(Filter<C,E> filter)
Returns the index offilterwithin the list of children, or-1iffilteris not in that list.- Parameters:
filter- thefilterwhose index should be looked up.- Returns:
- the index of
filteror-1if it cannot be found.
-
getLength
int getLength()
Returns the number of direct childrenFilters contained by thisCompositeFilter.- Returns:
- the number of direct children.
-
getType
CompositeFilter.Type getType()
Returns the type of combining semantics used by this filter.- Returns:
- the type of combining semantics used by this filter.
-
setType
void setType(CompositeFilter.Type type)
Sets the type of combining semantics used by this filter.- Parameters:
type- the combining semantics to use.
-
-