pub struct Company {
pub company_code: String,
pub company_name: String,
pub country: String,
pub local_currency: String,
pub functional_currency: String,
pub is_parent: bool,
pub parent_company: Option<String>,
pub ownership_percentage: Option<Decimal>,
pub consolidation_method: ConsolidationMethod,
}Expand description
Company entity for graph building and consolidation.
This is a simplified view of a company entity with ownership and consolidation attributes for building entity relationship graphs.
Fields§
§company_code: StringCompany code identifier
company_name: StringCompany name
country: StringCountry code (ISO 3166-1 alpha-2)
local_currency: StringLocal/functional currency (ISO 4217)
functional_currency: StringFunctional currency for translation
is_parent: boolIs this the parent/holding company
parent_company: Option<String>Parent company code (if subsidiary)
ownership_percentage: Option<Decimal>Ownership percentage (0-100)
consolidation_method: ConsolidationMethodConsolidation method
Implementations§
Source§impl Company
impl Company
Sourcepub fn new(
company_code: impl Into<String>,
company_name: impl Into<String>,
country: impl Into<String>,
local_currency: impl Into<String>,
) -> Self
pub fn new( company_code: impl Into<String>, company_name: impl Into<String>, country: impl Into<String>, local_currency: impl Into<String>, ) -> Self
Create a new company entity.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Company
impl<'de> Deserialize<'de> for Company
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<&CompanyCode> for Company
impl From<&CompanyCode> for Company
Source§fn from(cc: &CompanyCode) -> Self
fn from(cc: &CompanyCode) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for Company
impl RefUnwindSafe for Company
impl Send for Company
impl Sync for Company
impl Unpin for Company
impl UnwindSafe for Company
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more