icalendar.prop.adr module#
ADR property of RFC 6350.
- class icalendar.prop.adr.AdrFields(po_box, extended, street, locality, region, postal_code, country)[source]#
Bases:
NamedTupleNamed fields for vCard ADR (Address) property per RFC 6350 Section 6.3.1.
Provides named access to the seven address components.
Create new instance of AdrFields(po_box, extended, street, locality, region, postal_code, country)
- class icalendar.prop.adr.vAdr(fields, /, params=None)[source]#
Bases:
objectvCard ADR (Address) structured property per RFC 6350 Section 6.3.1.
The ADR property represents a delivery address as a single text value. The structured type value consists of a sequence of seven address components. The component values must be specified in their corresponding position.
post office box
extended address (e.g., apartment or suite number)
street address
locality (e.g., city)
region (e.g., state or province)
postal code
country name (full name)
When a component value is missing, the associated component separator MUST still be specified.
Semicolons are field separators and are NOT escaped. Commas and backslashes within field values ARE escaped per RFC 6350.
- Parameters:
Examples
>>> from icalendar.prop import vAdr >>> adr = vAdr(("", "", "123 Main St", "Springfield", "IL", "62701", "USA")) >>> adr.to_ical() b';;123 Main St;Springfield;IL;62701;USA' >>> vAdr.from_ical(";;123 Main St;Springfield;IL;62701;USA") AdrFields(po_box='', extended='', street='123 Main St', locality='Springfield', region='IL', postal_code='62701', country='USA')
- classmethod from_jcal(jcal_property)[source]#
Parse jCal from RFC 7265.
- Parameters:
jcal_property (
list) – The jCal property to parse.- Raises:
JCalParsingError – If the provided jCal is invalid.
- Return type:
- params: Parameters#