Skip to main content

set_feature_element

Function set_feature_element 

Source
pub fn set_feature_element(
    config_json: &str,
    params: SetFeatureElementParams<'_>,
) -> Result<String>
Expand description

Set feature element (update FBOM record)

This function updates feature-to-element mappings in CFG_FBOM.

§Arguments

  • config_json - JSON configuration string
  • params - Feature element parameters (feature_code and element_code required; updates optional)

§Returns

Modified configuration JSON string

§Example

use sz_configtool_lib::elements::{set_feature_element, SetFeatureElementParams};

let config = r#"{ ... }"#;
let params = SetFeatureElementParams::new("NAME", "FIRST_NAME")
    .with_display_level(1);
let updated = set_feature_element(&config, params)?;