public class NavLinkPair extends Object
NavPointNeighbourLink
.
hashCode()
and equals(Object)
overridden.Constructor and Description |
---|
NavLinkPair(NavPointNeighbourLink first) |
NavLinkPair(NavPointNeighbourLink first,
NavPointNeighbourLink second)
If 'first' is NULL and 'second' is NULL ...
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj) |
double |
getDistance(ILocated point)
Distance "point" from "link".
|
Location |
getFirstVector()
Get vector of the first link.
|
NavPointNeighbourLink |
getLinkComingFrom(NavPoint navPointLinkIsComingFrom)
Returns link that originates in 'navPointLinkIsComingFrom', if such exists.
|
NavPointNeighbourLink |
getLinkComingFrom(UnrealId navPointLinkIsComingFromId)
Returns link that originates in 'navPointLinkIsComingFromId', if such exists.
|
NavPointNeighbourLink |
getLinkLeadingTo(NavPoint navPointLinkEndsIn)
Returns link that ends in 'navPointLinkEndsIn', if such exists.
|
NavPointNeighbourLink |
getLinkLeadingTo(UnrealId navPointLinkEndsInId)
Returns link that ends in 'navPointLinkEndsInId', if such exists.
|
NavPointNeighbourLink |
getNavLink1()
Returns first
NavPointNeighbourLink , this is NEVER NULL. |
NavPointNeighbourLink |
getNavLink2()
Returns second
NavPointNeighbourLink , may be null. |
NavPoint |
getNavPoint1()
Returns first's
NavPointNeighbourLink.getFromNavPoint() , this is NEVER NULL. |
NavPoint |
getNavPoint2()
Returns first's
NavPointNeighbourLink.getToNavPoint() , this is NEVER NULL. |
Location |
getSecondVector()
Get vector of the second link.
|
int |
hashCode() |
boolean |
isLinkNavPoint(NavPoint navPoint)
Does this
NavLinkPair contains (as either end) 'navPoint'. |
boolean |
isLinkNavPoint(UnrealId navPointId)
Does this
NavLinkPair contains (as either end) 'navPoint'. |
public NavLinkPair(NavPointNeighbourLink first)
public NavLinkPair(NavPointNeighbourLink first, NavPointNeighbourLink second)
IllegalArgumentException
.
If 'first' is NULL and 'second' is NOT ... it swaps 'first' and 'second'.
If 'first' is NOT NULL and 'second' is NOT NULL ... it may swap them to satisfy hashCode()
implementation.first
- second
- public NavPointNeighbourLink getNavLink1()
NavPointNeighbourLink
, this is NEVER NULL.public NavPointNeighbourLink getNavLink2()
NavPointNeighbourLink
, may be null.public NavPoint getNavPoint1()
NavPointNeighbourLink.getFromNavPoint()
, this is NEVER NULL.public NavPoint getNavPoint2()
NavPointNeighbourLink.getToNavPoint()
, this is NEVER NULL.public boolean isLinkNavPoint(NavPoint navPoint)
NavLinkPair
contains (as either end) 'navPoint'.navPoint
- public boolean isLinkNavPoint(UnrealId navPointId)
NavLinkPair
contains (as either end) 'navPoint'.navPoint
- public NavPointNeighbourLink getLinkLeadingTo(UnrealId navPointLinkEndsInId)
navPointLinkEndsInId
- public NavPointNeighbourLink getLinkComingFrom(UnrealId navPointLinkIsComingFromId)
navPointLinkIsComingFromId
- public NavPointNeighbourLink getLinkLeadingTo(NavPoint navPointLinkEndsIn)
navPointLinkEndsIn
- public NavPointNeighbourLink getLinkComingFrom(NavPoint navPointLinkIsComingFrom)
navPointLinkIsComingFrom
- public Location getFirstVector()
public Location getSecondVector()
public double getDistance(ILocated point)
point
- Copyright © 2012 AMIS research group, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic. All Rights Reserved.