get_resource_inventory/get_resource_inventory.rs
1//! TMF639 Resource Inventory API Example
2
3use tmf_client::common::tmf_error::TMFError;
4use tmf_client::TMFClient;
5
6fn main() -> Result<(), TMFError> {
7 #[cfg(feature = "tmf639")]
8 {
9 use tmf_client::BlockingOperations;
10 use tmflib::HasName;
11
12 let resources = TMFClient::new("https://localhost", None)
13 .tmf639()
14 .resource()
15 .list(None)?;
16
17 for resource in resources {
18 println!("Name: {}", resource.get_name())
19 }
20 }
21
22 Ok(())
23}