Skip to main content

Ext

Struct Ext 

Source
pub struct Ext { /* private fields */ }
Expand description

拡張の表。Ext::default() は同梱の分だけ(カタログは .lbcat・.zmx、面のモデルは ideal_mapping、 プラグインは無し。解析の同梱のプラグインは上の層が重ねる)

Implementations§

Source§

impl Ext

Source

pub fn new() -> Ext

Source

pub fn add_catalog_source( &mut self, s: Arc<dyn LensCatalogSource + Send + Sync>, ) -> &mut Ext

レンズカタログの形式を足す(同じ拡張子なら後から足したものを使う)

Source

pub fn add_surface_model(&mut self, m: Arc<dyn SurfaceModel>) -> &mut Ext

利用者定義の面のモデルを足す(同じ名前は差し替える)

Source

pub fn remove_surface_model(&mut self, name: &str) -> bool

面のモデルを外す(あれば true)

Source

pub fn add_shape_model(&mut self, m: Arc<dyn ShapeModel>) -> &mut Ext

利用者定義の形のモデルを足す(同じ名前は差し替える)

Source

pub fn remove_shape_model(&mut self, name: &str) -> bool

形のモデルを外す(あれば true)

Source

pub fn add_source_model(&mut self, m: Arc<dyn SourceModel>) -> &mut Ext

利用者定義の光源のモデルを足す(同じ名前は差し替える)

Source

pub fn remove_source_model(&mut self, name: &str) -> bool

光源のモデルを外す(あれば true)

Source

pub fn add_material_catalog( &mut self, name: &str, models: Vec<Arc<dyn MaterialModel>>, ) -> &mut Ext

利用者定義の材料のカタログを足す(名前は AGF のカタログと同じに引く。大文字小文字は問わず、同じ名前は差し替える)

Source

pub fn remove_material_catalog(&mut self, name: &str) -> bool

材料のカタログを外す(あれば true)

Source

pub fn material_catalog(&self, name: &str) -> Option<&Arc<MaterialCatalog>>

名前の材料のカタログ(大文字小文字は問わない)

Source

pub fn material_catalogs(&self) -> Vec<String>

材料のカタログの名前(足したときの綴り、名前の順)

Source

pub fn add_coating_source(&mut self, s: Arc<dyn CoatingSource>) -> &mut Ext

膜のファイル形式を足す(同じ拡張子なら後から足したものを使う。同梱の形式と同じ拡張子ならこちらが勝つ)

Source

pub fn coating_sources(&self) -> Vec<Arc<dyn CoatingSource>>

膜のファイル形式(足したものが新しい順。同梱の形式は含まない)

Source

pub fn coating_source_for(&self, ext: &str) -> Option<&Arc<dyn CoatingSource>>

拡張子 ext(大文字小文字は問わない)を読む足した膜のファイル形式(新しいものが先)

Source

pub fn add_coating_catalog(&mut self, name: &str, set: CoatingSet) -> &mut Ext

膜の一覧を足す(名前は大文字小文字を問わず、同じ名前は差し替える。中の膜の引き方は crate::usercoating)

Source

pub fn remove_coating_catalog(&mut self, name: &str) -> bool

膜の一覧を外す(あれば true)

Source

pub fn coating_catalog(&self, name: &str) -> Option<&Arc<CoatingCatalog>>

名前の膜の一覧(大文字小文字は問わない)

Source

pub fn coating_catalogs(&self) -> Vec<String>

膜の一覧の名前(足したときの綴り、名前の順)

Source

pub fn coating_names(&self) -> Vec<String>

登録した膜の一覧にある膜の名前(名前の順、重なりなし。GUI の膜の欄の候補など)

Source

pub fn find_coating(&self, coat: &str) -> Option<&Arc<CoatingCatalog>>

膜 coat(大文字小文字は問わない)を持つ膜の一覧(2 つにあれば一覧の名前の順で先)

Source

pub fn plugins(&self) -> &Registry

プラグインの表

Source

pub fn plugins_mut(&mut self) -> &mut Registry

プラグインの表(足す・外す)

Source

pub fn slot<T>(&self) -> Option<&T>
where T: Any + Send + Sync,

上の層の表 T(無ければ None)。検出器の種類・拡張の解析など、core の知らない型の表を載せる欄

Source

pub fn slot_mut<T>(&mut self) -> &mut T
where T: Any + Send + Sync + Clone + Default,

上の層の表 T を変える(無ければ既定値で作る。ほかの表と共有している中身は写してから変える)

Source

pub fn merge(&mut self, other: &Ext) -> &mut Ext

other の分を足す(形式は後ろに、同じ名前の面のモデル・プラグインは other が勝つ。上の層の表は、other に ある型の表を other のもので置き換える)

Source

pub fn catalog_sources(&self) -> Vec<Arc<dyn LensCatalogSource + Send + Sync>>

カタログを読む形式の一覧(足したものが新しい順に先、最後に同梱の LbcatSource・ZmxFileSource)

Source

pub fn surface_model(&self, name: &str) -> Result<Arc<dyn SurfaceModel>, Error>

名前の面のモデル

Source

pub fn surface_models(&self) -> Vec<String>

面のモデルの名前(名前の順)

Source

pub fn shape_model(&self, name: &str) -> Result<Arc<dyn ShapeModel>, Error>

名前の形のモデル

Source

pub fn shape_models(&self) -> Vec<String>

形のモデルの名前(名前の順)

Source

pub fn source_model(&self, name: &str) -> Result<Arc<dyn SourceModel>, Error>

名前の光源のモデル

Source

pub fn source_models(&self) -> Vec<String>

光源のモデルの名前(名前の順)

Trait Implementations§

Source§

impl Clone for Ext

Source§

fn clone(&self) -> Ext

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 Ext

Source§

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

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

impl Default for Ext

Source§

fn default() -> Ext

Returns the “default value” for a type. Read more

Auto Trait Implementations§

§

impl !RefUnwindSafe for Ext

§

impl !UnwindSafe for Ext

§

impl Freeze for Ext

§

impl Send for Ext

§

impl Sync for Ext

§

impl Unpin for Ext

§

impl UnsafeUnpin for Ext

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
§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

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> DynClone for T
where T: Clone,

Source§

fn __clone_box(&self, _: Private) -> *mut ()

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> IntoEither for T

Source§

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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
where F: FnOnce(&Self) -> bool,

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
§

impl<T> Pointable for T

§

const ALIGN: usize

The alignment of pointer.
§

type Init = T

The type for initializers.
§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

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 = !

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

fn try_from(value: U) -> Result<T, !>

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.
§

impl<T> WasmNotSend for T
where T: Send,

§

impl<T> WasmNotSendSync for T
where T: WasmNotSend + WasmNotSync,

§

impl<T> WasmNotSync for T
where T: Sync,