pgrx_pg_config::cargo

Trait PgrxManifestExt

Source
pub trait PgrxManifestExt {
    // Required methods
    fn package_name(&self) -> Result<String>;
    fn package_version(&self) -> Result<String>;
    fn lib_name(&self) -> Result<String>;
    fn target_name(&self) -> Result<String>;
    fn lib_filename(&self) -> Result<String>;
}
Expand description

Extension to cargo_toml::Manifest. Import by adding use pgrx_pg_config::cargo::PgrxManifestExt; and extended functions will be available on Manifest values.

Required Methods§

Source

fn package_name(&self) -> Result<String>

Package name

Source

fn package_version(&self) -> Result<String>

Package version

Source

fn lib_name(&self) -> Result<String>

Resolved string for target library name, either its lib.name, or package name with hyphens replaced with underscore. https://doc.rust-lang.org/cargo/reference/cargo-targets.html#the-name-field

Source

fn target_name(&self) -> Result<String>

Resolved string for target artifact name, used for matching on cargo_metadata::message::Artifact.

Source

fn lib_filename(&self) -> Result<String>

Resolved string for target library name extension filename

Implementations on Foreign Types§

Source§

impl PgrxManifestExt for Manifest

Implementors§