Package qupath.lib.objects
Class DefaultPathObjectConnectionGroup
java.lang.Object
qupath.lib.objects.DefaultPathObjectConnectionGroup
- All Implemented Interfaces:
Externalizable
,Serializable
,PathObjectConnectionGroup
public class DefaultPathObjectConnectionGroup
extends Object
implements PathObjectConnectionGroup, Externalizable
Simple, default implementation of
PathObjectConnectionGroup
.- Author:
- Pete Bankhead
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
Key to use when storing object connections as a property of an ImageData object. -
Constructor Summary
ConstructorDescriptionDefault constructor.Create a connections group, copying the connections from an existing group. -
Method Summary
Modifier and TypeMethodDescriptionboolean
containsObject
(PathObject pathObject) Returns true if the specified PathObject is contained within this group.getConnectedObjects
(PathObject pathObject) Get all the connections to a specified PathObject stored in this group.Get an unmodifiable collection containing all the PathObjects contained within this group.getPathObjectsForRegion
(ImageRegion region) Get all the objects with connections that may intersect the specified region.void
void
-
Field Details
-
KEY_OBJECT_CONNECTIONS
Key to use when storing object connections as a property of an ImageData object.- See Also:
-
-
Constructor Details
-
DefaultPathObjectConnectionGroup
public DefaultPathObjectConnectionGroup()Default constructor. -
DefaultPathObjectConnectionGroup
Create a connections group, copying the connections from an existing group. This may be useful if the other PathObjectConnectionGroup is not itself serializable.- Parameters:
connections
-
-
-
Method Details
-
getPathObjects
Description copied from interface:PathObjectConnectionGroup
Get an unmodifiable collection containing all the PathObjects contained within this group.- Specified by:
getPathObjects
in interfacePathObjectConnectionGroup
- Returns:
-
getConnectedObjects
Description copied from interface:PathObjectConnectionGroup
Get all the connections to a specified PathObject stored in this group.If containsObject(pathObject) returns null, this will return an empty list (and not null).
- Specified by:
getConnectedObjects
in interfacePathObjectConnectionGroup
- Parameters:
pathObject
-- Returns:
-
getPathObjectsForRegion
Description copied from interface:PathObjectConnectionGroup
Get all the objects with connections that may intersect the specified region.- Specified by:
getPathObjectsForRegion
in interfacePathObjectConnectionGroup
- Parameters:
region
-- Returns:
-
writeExternal
- Specified by:
writeExternal
in interfaceExternalizable
- Throws:
IOException
-
readExternal
- Specified by:
readExternal
in interfaceExternalizable
- Throws:
IOException
ClassNotFoundException
-
containsObject
Description copied from interface:PathObjectConnectionGroup
Returns true if the specified PathObject is contained within this group.- Specified by:
containsObject
in interfacePathObjectConnectionGroup
- Parameters:
pathObject
-- Returns:
-