Source code for wow.models.reputation

 1"""Models for the Reputation API."""
 2
 3from wow.models._common import Document, IdRef, Model, Ref, TypedName
 4
 5__all__ = [
 6    "ReputationFaction",
 7    "ReputationFactionIndex",
 8    "ReputationTier",
 9    "ReputationTierSet",
10    "ReputationTierSetIndex",
11]
12
13
[docs] 14class ReputationFactionIndex(Document): 15 """Every reputation faction. ``root_factions`` are the top-level entries shown in the reputation pane.""" 16 17 factions: tuple[Ref, ...] 18 root_factions: tuple[Ref, ...]
19 20
[docs] 21class ReputationFaction(Document): 22 """A reputation faction, such as a city, tribe or army.""" 23 24 id: int 25 name: str 26 reputation_tiers: IdRef 27 description: str | None = None 28 player_faction: TypedName | None = None 29 is_header: bool = False 30 factions: tuple[Ref, ...] = ()
31 32
[docs] 33class ReputationTier(Model): 34 """One standing level within a reputation tier set, such as Honored.""" 35 36 id: int 37 name: str 38 min_value: int 39 max_value: int
40 41
[docs] 42class ReputationTierSetIndex(Document): 43 """Every reputation tier set. Battle.net calls this document ``reputation-tiers``.""" 44 45 reputation_tiers: tuple[IdRef, ...]
46 47
[docs] 48class ReputationTierSet(Document): 49 """One reputation tier set: the standing levels a faction's reputation can reach. 50 51 Battle.net calls this document ``reputation-tiers``; it is named ``ReputationTierSet`` here so it does not 52 collide with :class:`~wow._async.resources.reputation.AsyncReputationTiers`'s generated sync twin. 53 """ 54 55 id: int 56 tiers: tuple[ReputationTier, ...]