fr.cnes.sirius.patrius.fieldsofview
Class OmnidirectionalField

java.lang.Object
  extended by fr.cnes.sirius.patrius.fieldsofview.OmnidirectionalField
All Implemented Interfaces:
IFieldOfView

public final class OmnidirectionalField
extends Object
implements IFieldOfView

This class describes an omnidirectional field of view : any vector is in it, the angular distance is always 1 (positive).

Since:
1.2
Version:
$Id: OmnidirectionalField.java 17586 2017-05-10 13:29:16Z bignon $
Author:
Thomas Trapier
See Also:
IFieldOfView
Concurrency :
immutable

Constructor Summary
OmnidirectionalField(String name)
          Constructor of an omnidirectional field of view.
 
Method Summary
 double getAngularDistance(Vector3D direction)
          this method has no sense in the case of an omnidirectional field.
 String getName()
          
 boolean isInTheField(Vector3D direction)
          Any vector being in the field, this method always return true
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OmnidirectionalField

public OmnidirectionalField(String name)
Constructor of an omnidirectional field of view.

Parameters:
name - the name of this field
Method Detail

getAngularDistance

public double getAngularDistance(Vector3D direction)
this method has no sense in the case of an omnidirectional field. The convention for all other fields to return a positive value if then vector is in the field : this method always return 1, all vectors being in it.

Specified by:
getAngularDistance in interface IFieldOfView
Parameters:
direction - the direction vector (unused)
Returns:
always 1.0

isInTheField

public boolean isInTheField(Vector3D direction)
Any vector being in the field, this method always return true

Specified by:
isInTheField in interface IFieldOfView
Parameters:
direction - the direction vector (unused)
Returns:
always true

getName

public String getName()

Specified by:
getName in interface IFieldOfView
Returns:
the name of the field


Copyright © 2017 CNES. All Rights Reserved.