gdsconv::conv

Trait FromGds

Source
pub trait FromGds: Sized {
    // Required methods
    fn from_gds(layer: GdsLayer) -> Option<Self>;
    fn from_gds_pin(layer: GdsLayer) -> Option<Self>;
    fn from_gds_label(layer: GdsLayer) -> Option<Self>;
}
Expand description

A layer type that can be constructed from a GdsLayer.

Required Methods§

Source

fn from_gds(layer: GdsLayer) -> Option<Self>

Converts the given GDS layer to this layer type.

Returns None if the GDS layer has no valid mapping to the new layer type.

Source

fn from_gds_pin(layer: GdsLayer) -> Option<Self>

Converts the given GDS layer to this layer type if the GDS layer is a pin-type layer.

Should return None if the GDS layer has no valid mapping to the new layer type, or if the given GDS layer is not a pin layer.

Source

fn from_gds_label(layer: GdsLayer) -> Option<Self>

Converts the given GDS layer to this layer type if the GDS layer is a label-type layer.

Should return None if the GDS layer has no valid mapping to the new layer type, or if the given GDS layer is not a label layer.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§