pub struct TofBankGeometry {
pub two_theta_deg: f64,
}Expand description
Facility-neutral fixed geometry for one focused TOF detector bank.
Fields§
§two_theta_deg: f64Nominal bank scattering angle in degrees 2theta.
Implementations§
Source§impl TofBankGeometry
impl TofBankGeometry
Sourcepub fn validate(self) -> Result<(), TofError>
pub fn validate(self) -> Result<(), TofError>
Validate the strict physical scattering-angle domain.
§Errors
Returns TofError::InvalidBankTwoTheta unless the angle is finite and
strictly within 0 < 2theta < 180°.
Sourcepub fn theta_radians(self) -> Result<f64, TofError>
pub fn theta_radians(self) -> Result<f64, TofError>
Return the half scattering angle in radians after validation.
§Errors
Returns TofError::InvalidBankTwoTheta for invalid geometry.
Trait Implementations§
Source§impl Clone for TofBankGeometry
impl Clone for TofBankGeometry
Source§fn clone(&self) -> TofBankGeometry
fn clone(&self) -> TofBankGeometry
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for TofBankGeometry
Source§impl Debug for TofBankGeometry
impl Debug for TofBankGeometry
Source§impl PartialEq for TofBankGeometry
impl PartialEq for TofBankGeometry
impl StructuralPartialEq for TofBankGeometry
Auto Trait Implementations§
impl Freeze for TofBankGeometry
impl RefUnwindSafe for TofBankGeometry
impl Send for TofBankGeometry
impl Sync for TofBankGeometry
impl Unpin for TofBankGeometry
impl UnsafeUnpin for TofBankGeometry
impl UnwindSafe for TofBankGeometry
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more