pub struct FactionSummary { /* private fields */ }Expand description
Per-faction values derived from the tables.
Implementations§
Source§impl FactionSummary
impl FactionSummary
Sourcepub fn victory_regions(&self) -> &Vec<String>
pub fn victory_regions(&self) -> &Vec<String>
start_pos_victory_conditions regions of the faction, in table order.
Sourcepub fn client_state_of(&self) -> &Option<String>
pub fn client_state_of(&self) -> &Option<String>
Faction this one is a client state of.
Sourcepub fn subjects(&self) -> &Vec<String>
pub fn subjects(&self) -> &Vec<String>
Client states and vassals of the faction, in startpos faction order.
Sourcepub fn progenitor(&self) -> &Option<String>
pub fn progenitor(&self) -> &Option<String>
start_pos_characters id of the faction’s progenitor, if any.
Source§impl FactionSummary
impl FactionSummary
Sourcepub fn region_count(&self) -> usize
pub fn region_count(&self) -> usize
Number of owned regions.
Sourcepub fn has_war_or_vassal(&self) -> bool
pub fn has_war_or_vassal(&self) -> bool
The faction is at war, or in a vassal relation (either side).
Sourcepub fn horde(&self) -> Option<bool>
pub fn horde(&self) -> Option<bool>
For factions that can be hordes (factions.can_be_horde), whether they start as a horde (own no regions).
Sourcepub fn without_characters(&self) -> bool
pub fn without_characters(&self) -> bool
The faction has no living characters.
Trait Implementations§
Source§impl Clone for FactionSummary
impl Clone for FactionSummary
Source§fn clone(&self) -> FactionSummary
fn clone(&self) -> FactionSummary
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FactionSummary
impl Debug for FactionSummary
Source§impl Default for FactionSummary
impl Default for FactionSummary
Source§fn default() -> FactionSummary
fn default() -> FactionSummary
Returns the “default value” for a type. Read more
impl Eq for FactionSummary
Source§impl PartialEq for FactionSummary
impl PartialEq for FactionSummary
impl StructuralPartialEq for FactionSummary
Auto Trait Implementations§
impl Freeze for FactionSummary
impl RefUnwindSafe for FactionSummary
impl Send for FactionSummary
impl Sync for FactionSummary
impl Unpin for FactionSummary
impl UnsafeUnpin for FactionSummary
impl UnwindSafe for FactionSummary
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreimpl<T> MaybeSend for T
impl<T> MaybeSync for T
§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
Read this value from the supplied reader. Same as
ReadEndian::read_from_little_endian().impl<T> Scalar for T
§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.