Skip to main content

FloorRegion

Struct FloorRegion 

Source
pub struct FloorRegion {
    pub id: FloorRegionId,
    pub name: String,
    pub boundary: Vec<NodeId>,
    pub secondary_joists: Vec<SecondaryMember>,
    pub slab_ids: Vec<SlabId>,
}
Expand description

床領域。大梁が囲む 1 スパン区画(D1)。版の仕様は持たない(Slab が持つ)。

Fields§

§id: FloorRegionId

床領域 ID(Model::floor_regions の配列インデックスと一致すること)。

§name: String

表示名(ナビゲータ・診断で領域を指し示すために用いる)。空文字は名前なし。

§boundary: Vec<NodeId>

境界の節点列(大梁の閉路。反時計回り、始点は繰り返さない)。

§secondary_joists: Vec<SecondaryMember>

この床領域に属する小梁(SecondaryMember::Joist)の実体。 リスト内の順序は任意。

§slab_ids: Vec<SlabId>

この床領域に属する床板の ID リスト。床領域内が小梁で複数の打設単位に 分かれている場合、複数持ちうる。順序は任意。重複・他領域との共有は許さない (Model::validate が確認)。

Implementations§

Source§

impl FloorRegion

Source

pub fn new(id: FloorRegionId, boundary: Vec<NodeId>) -> Self

床領域を作る(版なし・小梁なし)。

Source

pub fn boundary_coords(&self, model: &Model) -> Option<Vec<[f64; 3]>>

境界多角形の座標列 [mm]。節点が引けない(陳腐化した参照)場合は None

Source

pub fn edge_nodes(&self, k: usize) -> Option<[NodeId; 2]>

境界の辺 k の両端節点。

Source

pub fn reference_node(&self) -> Option<NodeId>

領域を代表する節点(境界の先頭)。階の帰属や診断の表示など、 「この領域はどこにあるか」を 1 点で示す用途に使う。

Source

pub fn level(&self, model: &Model) -> Option<f64>

領域のレベル Z [mm](境界座標の Z の平均)。境界が引けなければ None

Trait Implementations§

Source§

impl Clone for FloorRegion

Source§

fn clone(&self) -> FloorRegion

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for FloorRegion

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for FloorRegion

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl PartialEq for FloorRegion

Source§

fn eq(&self, other: &FloorRegion) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Serialize for FloorRegion

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for FloorRegion

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.