Freeciv-3.3
Loading...
Searching...
No Matches
Public Member Functions | Data Fields | Static Public Attributes
generate_packets.FieldFlags Class Reference

Public Member Functions

"FieldFlags" parse (cls, str flags_text)
 
 __init__ (self, typing.Iterable[str] flag_texts)
 

Data Fields

 add_caps
 
 remove_caps
 
 is_key
 
 diff
 

Static Public Attributes

 ADD_CAP_PATTERN = re.compile(r"^add-cap\(([^()]+)\‍)$")
 
 REMOVE_CAP_PATTERN = re.compile(r"^remove-cap\(([^()]+)\‍)$")
 
bool is_key = False
 
bool diff = False
 
str add_caps : "set[str]"
 
str remove_caps : "set[str]"
 

Detailed Description

Information about flags of a given Field. Multiple Field objects can
share one FieldFlags instance, e.g. when defined on the same line.

Definition at line 458 of file generate_packets.py.

Constructor & Destructor Documentation

◆ __init__()

generate_packets.FieldFlags.__init__ (   self,
typing.Iterable[str flag_texts 
)

Definition at line 491 of file generate_packets.py.

Member Function Documentation

◆ parse()

"FieldFlags" generate_packets.FieldFlags.parse (   cls,
str  flags_text 
)
Parse a FieldFlags object from a comma-separated flag line

Definition at line 482 of file generate_packets.py.

Field Documentation

◆ ADD_CAP_PATTERN

generate_packets.FieldFlags.ADD_CAP_PATTERN = re.compile(r"^add-cap\(([^()]+)\‍)$")
static

Definition at line 462 of file generate_packets.py.

◆ add_caps [1/2]

str generate_packets.FieldFlags.add_caps : "set[str]"
static

Definition at line 474 of file generate_packets.py.

◆ add_caps [2/2]

generate_packets.FieldFlags.add_caps

Definition at line 492 of file generate_packets.py.

◆ diff [1/2]

bool generate_packets.FieldFlags.diff = False
static

Definition at line 471 of file generate_packets.py.

◆ diff [2/2]

generate_packets.FieldFlags.diff

Definition at line 500 of file generate_packets.py.

◆ is_key [1/2]

bool generate_packets.FieldFlags.is_key = False
static

Definition at line 468 of file generate_packets.py.

◆ is_key [2/2]

generate_packets.FieldFlags.is_key

Definition at line 497 of file generate_packets.py.

◆ REMOVE_CAP_PATTERN

generate_packets.FieldFlags.REMOVE_CAP_PATTERN = re.compile(r"^remove-cap\(([^()]+)\‍)$")
static

Definition at line 465 of file generate_packets.py.

◆ remove_caps [1/2]

str generate_packets.FieldFlags.remove_caps : "set[str]"
static

Definition at line 477 of file generate_packets.py.

◆ remove_caps [2/2]

generate_packets.FieldFlags.remove_caps

Definition at line 493 of file generate_packets.py.