pub struct BoundingBox<V>(/* private fields */);Expand description
bounding box
Implementations§
Source§impl<V> BoundingBox<V>where
V: Bounded,
impl<V> BoundingBox<V>where
V: Bounded,
Sourcepub fn new() -> BoundingBox<V>
pub fn new() -> BoundingBox<V>
Creates an empty bounding box
Sourcepub fn push(&mut self, point: V)
pub fn push(&mut self, point: V)
Adds a point to the bounding box.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let mut bdd_box = BoundingBox::new();
bdd_box.push(Vector2::new(-1.0, 1.0));
bdd_box.push(Vector2::new(1.0, -1.0));
assert_eq!(bdd_box.min(), Vector2::new(-1.0, -1.0));
assert_eq!(bdd_box.max(), Vector2::new(1.0, 1.0));§Remarks
If the added point has NAN component, then the point is not added.
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let mut bdd_box = BoundingBox::new();
bdd_box.push(Vector2::new(-1.0, 1.0));
bdd_box.push(Vector2::new(1.0, -1.0));
bdd_box.push(Vector2::new(std::f64::NAN, 1.0));
bdd_box.push(Vector2::new(-1.0, std::f64::NAN));
assert_eq!(bdd_box.min(), Vector2::new(-1.0, -1.0));
assert_eq!(bdd_box.max(), Vector2::new(1.0, 1.0));Sourcepub fn is_empty(self) -> bool
pub fn is_empty(self) -> bool
Returns the bounding box is empty or not.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let mut bdd_box = BoundingBox::new();
assert!(bdd_box.is_empty());
bdd_box.push(Vector2::new(-1.0, 1.0));
assert!(!bdd_box.is_empty());Sourcepub const fn max(self) -> V
pub const fn max(self) -> V
Returns the reference to the maximum point.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let mut bdd_box = BoundingBox::new();
bdd_box.push(Vector2::new(-1.0, 1.0));
bdd_box.push(Vector2::new(1.0, -1.0));
assert_eq!(bdd_box.max(), Vector2::new(1.0, 1.0));§Remarks
If the bounding box is empty, returned vector consists NEG_INFINITY components.
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let bdd_box = BoundingBox::<Vector2>::new();
assert_eq!(bdd_box.max(), Vector2::from([f64::NEG_INFINITY; 2]));Sourcepub const fn min(self) -> V
pub const fn min(self) -> V
Returns the reference to the minimal point.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let mut bdd_box = BoundingBox::new();
bdd_box.push(Vector2::new(-1.0, 1.0));
bdd_box.push(Vector2::new(1.0, -1.0));
assert_eq!(bdd_box.min(), Vector2::new(-1.0, -1.0));§Remarks
If the bounding box is empty, returned vector consists INFINITY components.
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let bdd_box = BoundingBox::<Vector2>::new();
assert_eq!(bdd_box.min(), Vector2::from([f64::INFINITY; 2]));Sourcepub fn diagonal(self) -> <V as Bounded>::Vector
pub fn diagonal(self) -> <V as Bounded>::Vector
Returns the diagonal vector.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let mut bdd_box = BoundingBox::new();
bdd_box.push(Vector2::new(-2.0, -3.0));
bdd_box.push(Vector2::new(6.0, 4.0));
assert_eq!(bdd_box.diagonal(), Vector2::new(8.0, 7.0));§Remarks
If the bounding box is empty, returned vector consists f64::NEG_INFINITY components.
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let bdd_box = BoundingBox::<Vector2>::new();
assert_eq!(bdd_box.diagonal(), Vector2::new(f64::NEG_INFINITY, f64::NEG_INFINITY));Sourcepub fn diameter(self) -> <V as Bounded>::Scalar
pub fn diameter(self) -> <V as Bounded>::Scalar
Returns the diameter of the bounding box.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let mut bdd_box = BoundingBox::new();
bdd_box.push(Vector2::new(-1.0, -3.0));
bdd_box.push(Vector2::new(2.0, 1.0));
assert_eq!(bdd_box.diameter(), 5.0);§Remarks
If the bounding box is empty, returns f64::NEG_INFINITY.
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let bdd_box = BoundingBox::<Vector3>::new();
assert_eq!(bdd_box.diameter(), f64::NEG_INFINITY);Sourcepub fn size(self) -> <V as Bounded>::Scalar
pub fn size(self) -> <V as Bounded>::Scalar
Returns the maximum length of the edges of the bounding box.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let mut bdd_box = BoundingBox::new();
bdd_box.push(Vector3::new(-1.0, -3.0, 2.0));
bdd_box.push(Vector3::new(2.0, 1.0, 10.0));
assert_eq!(bdd_box.size(), 8.0);§Remarks
If the bounding box is empty, returns f64::NEG_INFINITY.
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let bdd_box = BoundingBox::<Vector3>::new();
assert_eq!(bdd_box.size(), f64::NEG_INFINITY);Sourcepub fn center(self) -> V
pub fn center(self) -> V
Returns the center of the bounding box.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let mut bdd_box = BoundingBox::new();
bdd_box.push(Vector2::new(-1.0, -3.0));
bdd_box.push(Vector2::new(5.0, 1.0));
assert_eq!(bdd_box.center(), Vector2::new(2.0, -1.0));§Remarks
If the bounding box is empty, returned vector consists std::f64::NAN components.
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let bdd_box = BoundingBox::<Vector3>::new();
let center = bdd_box.center();
assert!(center[0].is_nan());
assert!(center[1].is_nan());
assert!(center[2].is_nan());Sourcepub fn contains(self, pt: V) -> bool
pub fn contains(self, pt: V) -> bool
Returns whether self contains pt or not.
§Examples
use truck_base::{cgmath64::*, bounding_box::*};
let bdd_box = BoundingBox::from_iter(vec![Point2::new(0.0, 0.0), Point2::new(1.0, 1.0)]);
assert!(bdd_box.contains(Point2::new(0.5, 0.5)));
assert!(bdd_box.contains(Point2::new(0.0, 0.5)));
assert!(!bdd_box.contains(Point2::new(-0.1, 0.5)));Trait Implementations§
Source§impl<V> Add<&BoundingBox<V>> for &BoundingBox<V>where
V: Bounded,
impl<V> Add<&BoundingBox<V>> for &BoundingBox<V>where
V: Bounded,
Source§fn add(self, other: &BoundingBox<V>) -> BoundingBox<V>
fn add(self, other: &BoundingBox<V>) -> BoundingBox<V>
Returns the direct sum of self and other.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let bdd_box0 = BoundingBox::from_iter(&[
Vector2::new(3.0, 2.0), Vector2::new(5.0, 6.0),
]);
let bdd_box1 = BoundingBox::from_iter(&[
Vector2::new(4.0, 1.0), Vector2::new(7.0, 4.0),
]);
let bdd_box = &bdd_box0 + &bdd_box1;
assert_eq!(bdd_box.min(), Vector2::new(3.0, 1.0));
assert_eq!(bdd_box.max(), Vector2::new(7.0, 6.0));
let cloned_bdd_box = &bdd_box + &BoundingBox::new();
assert_eq!(cloned_bdd_box.min(), Vector2::new(3.0, 1.0));
assert_eq!(cloned_bdd_box.max(), Vector2::new(7.0, 6.0));Source§type Output = BoundingBox<V>
type Output = BoundingBox<V>
+ operator.Source§impl<V> Add<&BoundingBox<V>> for BoundingBox<V>where
V: Bounded,
impl<V> Add<&BoundingBox<V>> for BoundingBox<V>where
V: Bounded,
Source§fn add(self, other: &BoundingBox<V>) -> BoundingBox<V>
fn add(self, other: &BoundingBox<V>) -> BoundingBox<V>
Returns the direct sum of self and other.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let bdd_box0 = BoundingBox::from_iter(&[
Vector2::new(3.0, 2.0), Vector2::new(5.0, 6.0),
]);
let bdd_box1 = BoundingBox::from_iter(&[
Vector2::new(4.0, 1.0), Vector2::new(7.0, 4.0),
]);
let bdd_box = bdd_box0 + &bdd_box1;
assert_eq!(bdd_box.min(), Vector2::new(3.0, 1.0));
assert_eq!(bdd_box.max(), Vector2::new(7.0, 6.0));
let cloned_bdd_box = bdd_box + &BoundingBox::new();
assert_eq!(cloned_bdd_box.min(), Vector2::new(3.0, 1.0));
assert_eq!(cloned_bdd_box.max(), Vector2::new(7.0, 6.0));Source§type Output = BoundingBox<V>
type Output = BoundingBox<V>
+ operator.Source§impl<V> Add<BoundingBox<V>> for &BoundingBox<V>where
V: Bounded,
impl<V> Add<BoundingBox<V>> for &BoundingBox<V>where
V: Bounded,
Source§fn add(self, other: BoundingBox<V>) -> BoundingBox<V>
fn add(self, other: BoundingBox<V>) -> BoundingBox<V>
Returns the direct sum of self and other.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let bdd_box0 = BoundingBox::from_iter(&[
Vector2::new(3.0, 2.0), Vector2::new(5.0, 6.0),
]);
let bdd_box1 = BoundingBox::from_iter(&[
Vector2::new(4.0, 1.0), Vector2::new(7.0, 4.0),
]);
let bdd_box = &bdd_box0 + bdd_box1;
assert_eq!(bdd_box.min(), Vector2::new(3.0, 1.0));
assert_eq!(bdd_box.max(), Vector2::new(7.0, 6.0));
let cloned_bdd_box = &bdd_box + BoundingBox::new();
assert_eq!(cloned_bdd_box.min(), Vector2::new(3.0, 1.0));
assert_eq!(cloned_bdd_box.max(), Vector2::new(7.0, 6.0));Source§type Output = BoundingBox<V>
type Output = BoundingBox<V>
+ operator.Source§impl<V> Add for BoundingBox<V>where
V: Bounded,
impl<V> Add for BoundingBox<V>where
V: Bounded,
Source§fn add(self, other: BoundingBox<V>) -> BoundingBox<V>
fn add(self, other: BoundingBox<V>) -> BoundingBox<V>
Returns the direct sum of self and other.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let bdd_box0 = BoundingBox::from_iter(&[
Vector2::new(3.0, 2.0), Vector2::new(5.0, 6.0),
]);
let bdd_box1 = BoundingBox::from_iter(&[
Vector2::new(4.0, 1.0), Vector2::new(7.0, 4.0),
]);
let bdd_box = bdd_box0 + bdd_box1;
assert_eq!(bdd_box.min(), Vector2::new(3.0, 1.0));
assert_eq!(bdd_box.max(), Vector2::new(7.0, 6.0));
let cloned_bdd_box = bdd_box + BoundingBox::new();
assert_eq!(cloned_bdd_box.min(), Vector2::new(3.0, 1.0));
assert_eq!(cloned_bdd_box.max(), Vector2::new(7.0, 6.0));Source§type Output = BoundingBox<V>
type Output = BoundingBox<V>
+ operator.Source§impl<V> AddAssign<&BoundingBox<V>> for BoundingBox<V>where
V: Bounded,
impl<V> AddAssign<&BoundingBox<V>> for BoundingBox<V>where
V: Bounded,
Source§fn add_assign(&mut self, other: &BoundingBox<V>)
fn add_assign(&mut self, other: &BoundingBox<V>)
Puts the points in other into self.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let mut bdd_box = BoundingBox::from_iter(&[
Vector2::new(3.0, 2.0), Vector2::new(5.0, 6.0),
]);
bdd_box += &BoundingBox::from_iter(&[
Vector2::new(4.0, 1.0), Vector2::new(7.0, 4.0),
]);
assert_eq!(bdd_box.min(), Vector2::new(3.0, 1.0));
assert_eq!(bdd_box.max(), Vector2::new(7.0, 6.0));
bdd_box += &BoundingBox::new();
assert_eq!(bdd_box.min(), Vector2::new(3.0, 1.0));
assert_eq!(bdd_box.max(), Vector2::new(7.0, 6.0));Source§impl<V> AddAssign for BoundingBox<V>where
V: Bounded,
impl<V> AddAssign for BoundingBox<V>where
V: Bounded,
Source§fn add_assign(&mut self, other: BoundingBox<V>)
fn add_assign(&mut self, other: BoundingBox<V>)
Puts the points in other into self.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let mut bdd_box = BoundingBox::from_iter(&[
Vector2::new(3.0, 2.0), Vector2::new(5.0, 6.0),
]);
bdd_box += BoundingBox::from_iter(&[
Vector2::new(4.0, 1.0), Vector2::new(7.0, 4.0),
]);
assert_eq!(bdd_box.min(), Vector2::new(3.0, 1.0));
assert_eq!(bdd_box.max(), Vector2::new(7.0, 6.0));
bdd_box += BoundingBox::new();
assert_eq!(bdd_box.min(), Vector2::new(3.0, 1.0));
assert_eq!(bdd_box.max(), Vector2::new(7.0, 6.0));Source§impl<V> BitXor<&BoundingBox<V>> for &BoundingBox<V>where
V: Bounded,
impl<V> BitXor<&BoundingBox<V>> for &BoundingBox<V>where
V: Bounded,
Source§fn bitxor(self, other: &BoundingBox<V>) -> BoundingBox<V>
fn bitxor(self, other: &BoundingBox<V>) -> BoundingBox<V>
Returns the intersection of self and other.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let bdd_box0 = BoundingBox::from_iter(&[
Vector2::new(3.0, 2.0), Vector2::new(5.0, 6.0),
]);
let bdd_box1 = BoundingBox::from_iter(&[
Vector2::new(4.0, 1.0), Vector2::new(7.0, 4.0),
]);
let bdd_box = &bdd_box0 ^ &bdd_box1;
assert_eq!(bdd_box.min(), Vector2::new(4.0, 2.0));
assert_eq!(bdd_box.max(), Vector2::new(5.0, 4.0));
let new_empty = &bdd_box ^ &BoundingBox::new();
assert!(new_empty.is_empty());Source§type Output = BoundingBox<V>
type Output = BoundingBox<V>
^ operator.Source§impl<V> BitXor<&BoundingBox<V>> for BoundingBox<V>where
V: Bounded,
impl<V> BitXor<&BoundingBox<V>> for BoundingBox<V>where
V: Bounded,
Source§fn bitxor(self, other: &BoundingBox<V>) -> BoundingBox<V>
fn bitxor(self, other: &BoundingBox<V>) -> BoundingBox<V>
Returns the intersection of self and other.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let bdd_box0 = BoundingBox::from_iter(&[
Vector2::new(3.0, 2.0), Vector2::new(5.0, 6.0),
]);
let bdd_box1 = BoundingBox::from_iter(&[
Vector2::new(4.0, 1.0), Vector2::new(7.0, 4.0),
]);
let bdd_box = bdd_box0 ^ &bdd_box1;
assert_eq!(bdd_box.min(), Vector2::new(4.0, 2.0));
assert_eq!(bdd_box.max(), Vector2::new(5.0, 4.0));
let new_empty = bdd_box ^ &BoundingBox::new();
assert!(new_empty.is_empty());Source§type Output = BoundingBox<V>
type Output = BoundingBox<V>
^ operator.Source§impl<V> BitXor<BoundingBox<V>> for &BoundingBox<V>where
V: Bounded,
impl<V> BitXor<BoundingBox<V>> for &BoundingBox<V>where
V: Bounded,
Source§fn bitxor(self, other: BoundingBox<V>) -> BoundingBox<V>
fn bitxor(self, other: BoundingBox<V>) -> BoundingBox<V>
Returns the intersection of self and other.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let bdd_box0 = BoundingBox::from_iter(&[
Vector2::new(3.0, 2.0), Vector2::new(5.0, 6.0),
]);
let bdd_box1 = BoundingBox::from_iter(&[
Vector2::new(4.0, 1.0), Vector2::new(7.0, 4.0),
]);
let bdd_box = &bdd_box0 ^ bdd_box1;
assert_eq!(bdd_box.min(), Vector2::new(4.0, 2.0));
assert_eq!(bdd_box.max(), Vector2::new(5.0, 4.0));
let new_empty = &bdd_box ^ BoundingBox::new();
assert!(new_empty.is_empty());Source§type Output = BoundingBox<V>
type Output = BoundingBox<V>
^ operator.Source§impl<V> BitXor for BoundingBox<V>where
V: Bounded,
impl<V> BitXor for BoundingBox<V>where
V: Bounded,
Source§fn bitxor(self, other: BoundingBox<V>) -> BoundingBox<V>
fn bitxor(self, other: BoundingBox<V>) -> BoundingBox<V>
Returns the intersection of self and other.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let bdd_box0 = BoundingBox::from_iter(&[
Vector2::new(3.0, 2.0), Vector2::new(5.0, 6.0),
]);
let bdd_box1 = BoundingBox::from_iter(&[
Vector2::new(4.0, 1.0), Vector2::new(7.0, 4.0),
]);
let bdd_box = bdd_box0 ^ bdd_box1;
assert_eq!(bdd_box.min(), Vector2::new(4.0, 2.0));
assert_eq!(bdd_box.max(), Vector2::new(5.0, 4.0));
let new_empty = bdd_box ^ BoundingBox::new();
assert!(new_empty.is_empty());Source§type Output = BoundingBox<V>
type Output = BoundingBox<V>
^ operator.Source§impl<V> BitXorAssign<&BoundingBox<V>> for BoundingBox<V>where
V: Bounded,
impl<V> BitXorAssign<&BoundingBox<V>> for BoundingBox<V>where
V: Bounded,
Source§fn bitxor_assign(&mut self, other: &BoundingBox<V>)
fn bitxor_assign(&mut self, other: &BoundingBox<V>)
Assigns the intersection of self and other to self.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let mut bdd_box = BoundingBox::from_iter(&[
Vector2::new(3.0, 2.0), Vector2::new(5.0, 6.0),
]);
bdd_box ^= &BoundingBox::from_iter(&[
Vector2::new(4.0, 1.0), Vector2::new(7.0, 4.0),
]);
assert_eq!(bdd_box.min(), Vector2::new(4.0, 2.0));
assert_eq!(bdd_box.max(), Vector2::new(5.0, 4.0));
bdd_box ^= &BoundingBox::new();
assert!(bdd_box.is_empty());Source§impl<V> BitXorAssign for BoundingBox<V>where
V: Bounded,
impl<V> BitXorAssign for BoundingBox<V>where
V: Bounded,
Source§fn bitxor_assign(&mut self, other: BoundingBox<V>)
fn bitxor_assign(&mut self, other: BoundingBox<V>)
Assigns the intersection of self and other to self.
§Examples
use truck_base::{cgmath64::*, bounding_box::*, tolerance::*};
let mut bdd_box = BoundingBox::from_iter(&[
Vector2::new(3.0, 2.0), Vector2::new(5.0, 6.0),
]);
bdd_box ^= BoundingBox::from_iter(&[
Vector2::new(4.0, 1.0), Vector2::new(7.0, 4.0),
]);
assert_eq!(bdd_box.min(), Vector2::new(4.0, 2.0));
assert_eq!(bdd_box.max(), Vector2::new(5.0, 4.0));
bdd_box ^= BoundingBox::new();
assert!(bdd_box.is_empty());Source§impl<V> Clone for BoundingBox<V>where
V: Clone,
impl<V> Clone for BoundingBox<V>where
V: Clone,
Source§fn clone(&self) -> BoundingBox<V>
fn clone(&self) -> BoundingBox<V>
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl<V> Debug for BoundingBox<V>where
V: Debug,
impl<V> Debug for BoundingBox<V>where
V: Debug,
Source§impl<V> Default for BoundingBox<V>where
V: Bounded,
impl<V> Default for BoundingBox<V>where
V: Bounded,
Source§fn default() -> BoundingBox<V>
fn default() -> BoundingBox<V>
Source§impl<'de, V> Deserialize<'de> for BoundingBox<V>where
V: Deserialize<'de>,
impl<'de, V> Deserialize<'de> for BoundingBox<V>where
V: Deserialize<'de>,
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<BoundingBox<V>, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<BoundingBox<V>, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Source§impl<'a, V> FromIterator<&'a V> for BoundingBox<V>where
V: Bounded,
impl<'a, V> FromIterator<&'a V> for BoundingBox<V>where
V: Bounded,
Source§fn from_iter<I>(iter: I) -> BoundingBox<V>where
I: IntoIterator<Item = &'a V>,
fn from_iter<I>(iter: I) -> BoundingBox<V>where
I: IntoIterator<Item = &'a V>,
Source§impl<V> FromIterator<V> for BoundingBox<V>where
V: Bounded,
impl<V> FromIterator<V> for BoundingBox<V>where
V: Bounded,
Source§fn from_iter<I>(iter: I) -> BoundingBox<V>where
I: IntoIterator<Item = V>,
fn from_iter<I>(iter: I) -> BoundingBox<V>where
I: IntoIterator<Item = V>,
Source§impl<V> PartialEq for BoundingBox<V>where
V: PartialEq,
impl<V> PartialEq for BoundingBox<V>where
V: PartialEq,
Source§impl<V> PartialOrd for BoundingBox<V>where
V: Bounded,
impl<V> PartialOrd for BoundingBox<V>where
V: Bounded,
Source§fn partial_cmp(&self, other: &BoundingBox<V>) -> Option<Ordering>
fn partial_cmp(&self, other: &BoundingBox<V>) -> Option<Ordering>
Inclusion relationship
§Examples
use truck_base::{cgmath64::*, bounding_box::*};
let bbx0 = BoundingBox::from_iter(&[
Point2::new(0.0, 0.0),
Point2::new(1.0, 1.0),
]);
let bbx1 = BoundingBox::from_iter(&[
Point2::new(0.25, 0.25),
Point2::new(0.75, 0.75),
]);
// bbx0 includes bbx1.
assert!(bbx0 > bbx1);
let bbx2 = BoundingBox::from_iter(&[
Point2::new(-1.0, -1.0),
Point2::new(0.75, 0.75),
]);
// bbx0 does not include bbx2, and bbx2 does not include bbx0.
assert!(!(bbx0 > bbx2));
assert!(!(bbx0 < bbx2));
assert!(!(bbx0 == bbx2));Source§impl<V> Serialize for BoundingBox<V>where
V: Serialize,
impl<V> Serialize for BoundingBox<V>where
V: Serialize,
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
impl<V> Copy for BoundingBox<V>where
V: Copy,
impl<V> Eq for BoundingBox<V>where
V: Eq,
impl<V> StructuralPartialEq for BoundingBox<V>
Auto Trait Implementations§
impl<V> Freeze for BoundingBox<V>where
V: Freeze,
impl<V> RefUnwindSafe for BoundingBox<V>where
V: RefUnwindSafe,
impl<V> Send for BoundingBox<V>where
V: Send,
impl<V> Sync for BoundingBox<V>where
V: Sync,
impl<V> Unpin for BoundingBox<V>where
V: Unpin,
impl<V> UnwindSafe for BoundingBox<V>where
V: UnwindSafe,
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
clone_to_uninit)Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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>
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>
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 moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
ReadEndian::read_from_little_endian().