Class AbstractNetworkQuery<T>
java.lang.Object
repast.simphony.query.space.graph.AbstractNetworkQuery<T>
- All Implemented Interfaces:
Query<T>
- Direct Known Subclasses:
NetworkAdjacent
,NetworkPredecessor
,NetworkSuccessor
- Version:
- $Revision$ $Date$
- Author:
- Nick Collier
-
Field Summary
-
Constructor Summary
ModifierConstructorDescriptionprotected
AbstractNetworkQuery
(Context<T> context, T obj) Creates a network query that will query any networks in the specified context using the specified object.protected
AbstractNetworkQuery
(Network<T> network, T obj) Creates a network query that will query the specified network using the specified object. -
Method Summary
Modifier and TypeMethodDescriptiongetNetNghIterable
(Network<T> net) Implementor should return the iterator appropriate to their query.query()
Gets an iterable over a collection of nodes.Gets an iterable over the collection of nodes returned by this query.
-
Field Details
-
target
-
-
Constructor Details
-
AbstractNetworkQuery
Creates a network query that will query any networks in the specified context using the specified object.- Parameters:
context
-obj
-
-
AbstractNetworkQuery
Creates a network query that will query the specified network using the specified object.- Parameters:
network
-obj
-
-
-
Method Details
-
query
Gets an iterable over a collection of nodes. The actual members of this set will be determined by sub-classes. For example, the NetworkAdjacent query will return an iterable over nodes that are adjacent to the node specified in the constructor. -
getNetNghIterable
Implementor should return the iterator appropriate to their query. For example, an network adjacent query would return an iterator over the nodes adjacent to the target node specified in the constructor.- Parameters:
net
-- Returns:
- the iterator appropriate to the implemented query.
-
query
Gets an iterable over the collection of nodes returned by this query. where the members of that collection are also part of the specified iterable parameter. The actual members of the iterable returned by the query will be determined by sub-classes. For example, the NetworkAdjacent query will return an iterable over nodes that are adjacent to the node specified in the constructor.
-