Struct Neighbor<T>
A simple container for neighbor search results.
Contains a reference to a neighbor particle, the local direction
in which it was found, and a flag indicating whether the
direction is relative to the querying particle's head or tail.
Assembly: .dll
Syntax
public struct Neighbor<T> where T : class
Type Parameters
Name |
Description |
T |
The type of the neighbor particle.
|
Constructors
|
Edit this page
View Source
Neighbor(T, Direction, bool)
Declaration
public Neighbor(T neighbor, Direction localDir, bool atHead)
Parameters
Type |
Name |
Description |
T |
neighbor |
|
Direction |
localDir |
|
bool |
atHead |
|
Fields
|
Edit this page
View Source
Null
Declaration
public static Neighbor<T> Null
Field Value
|
Edit this page
View Source
atHead
Declaration
Field Value
|
Edit this page
View Source
localDir
Declaration
public Direction localDir
Field Value
|
Edit this page
View Source
neighbor
Declaration
Field Value
Methods
|
Edit this page
View Source
Equals(object)
Indicates whether this instance and a specified object are equal.
Declaration
public override bool Equals(object obj)
Parameters
Type |
Name |
Description |
object |
obj |
The object to compare with the current instance.
|
Returns
Type |
Description |
bool |
true if obj and this instance are the same type and represent the same value; otherwise, false.
|
Overrides
System.ValueType.Equals(object)
|
Edit this page
View Source
GetHashCode()
Returns the hash code for this instance.
Declaration
public override int GetHashCode()
Returns
Type |
Description |
int |
A 32-bit signed integer that is the hash code for this instance.
|
Overrides
System.ValueType.GetHashCode()
Operators
|
Edit this page
View Source
operator ==(Neighbor<T>, Neighbor<T>)
Declaration
public static bool operator ==(Neighbor<T> nbr1, Neighbor<T> nbr2)
Parameters
Returns
|
Edit this page
View Source
operator !=(Neighbor<T>, Neighbor<T>)
Declaration
public static bool operator !=(Neighbor<T> nbr1, Neighbor<T> nbr2)
Parameters
Returns