### Get Size Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarComponent.html Returns the number of entries in the ICalendarComponent. ```APIDOC ## impl ICalendarComponent ### `size(&self) -> usize` Returns the total number of entries in the component. ``` -------------------------------- ### Get Transparency Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarComponent.html Retrieves the transparency of the ICalendarComponent. ```APIDOC ## impl ICalendarComponent ### `transparency(&self) -> Option<&ICalendarTransparency>` Returns the transparency of the component if set. ``` -------------------------------- ### Get Property Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarComponent.html Retrieves a specific ICalendarEntry for a given ICalendarProperty. ```APIDOC ## impl ICalendarComponent ### `property(&self, prop: &ICalendarProperty) -> Option<&ICalendarEntry>` Returns a reference to the ICalendarEntry for the specified property, if it exists. ``` -------------------------------- ### Uri Methods Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/enum.Uri.html Provides methods for parsing, converting to string, and getting the size of a Uri. ```APIDOC ## Implementations for Uri ### `impl Uri` * **`pub fn parse(value: impl Into) -> Self`**: Parses a string into a Uri. * **`pub fn as_str(&self) -> Option<&str>`**: Returns the Uri as a string slice, if possible. * **`pub fn size(&self) -> usize`**: Returns the size of the Uri in bytes. * **`pub fn to_unwrapped_string(&self) -> String`**: Converts the Uri to a String, panicking if it cannot be represented as a string. * **`pub fn into_unwrapped_string(self) -> String`**: Consumes the Uri and converts it into a String, panicking if it cannot be represented as a string. ``` -------------------------------- ### Get Next Entry Source: https://docs.rs/calcard/0.3.2/calcard/struct.Parser.html Extracts the next available entry from the parser's input. ```rust pub fn entry(&mut self) -> Entry ``` -------------------------------- ### ICalendarPeriod Enum Definition Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/enum.ICalendarPeriod.html Defines the ICalendarPeriod enum with two variants: Range and Duration. Use Range for periods with a defined start and end, and Duration for periods with a start and a specified length. ```rust pub enum ICalendarPeriod { Range { start: PartialDateTime, end: PartialDateTime, }, Duration { start: PartialDateTime, duration: ICalendarDuration, }, } ``` -------------------------------- ### Run Test Suite Source: https://docs.rs/calcard Execute the library's test suite using Cargo. The `--all-features` flag ensures all features are included in the test run. ```bash $ cargo test --all-features ``` -------------------------------- ### TryInto Implementation Source: https://docs.rs/calcard/0.3.2/calcard/vcard/enum.VCardVersion.html Provides a convenient way to attempt conversion into a VCardVersion from another type, leveraging the TryFrom implementation. ```APIDOC ## type Error = >::Error ### Description The type returned in the event of a conversion error. ## fn try_into(self) -> Result>::Error> ### Description Performs the conversion from the current type `T` into another type `U`. ### Method `try_into` ### Parameters - `self` (T): The value to convert. ### Returns - `Result>::Error>`: Ok containing the target type `U` if successful, or an Err if the conversion fails. ``` -------------------------------- ### type_id Source: https://docs.rs/calcard/0.3.2/calcard/vcard/struct.VCard.html Gets the TypeId of the VCard. ```APIDOC ## impl Any for T ### fn type_id(&self) -> TypeId Gets the `TypeId` of the `VCard`. ``` -------------------------------- ### default Source: https://docs.rs/calcard/0.3.2/calcard/vcard/struct.VCard.html Creates a default VCard instance. ```APIDOC ## impl Default for VCard ### fn default() -> VCard Returns the default value for a `VCard`, typically an empty vCard. ``` -------------------------------- ### Get Status Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarComponent.html Retrieves the status of the ICalendarComponent. ```APIDOC ## impl ICalendarComponent ### `status(&self) -> Option<&ICalendarStatus>` Returns the status of the component if set. ``` -------------------------------- ### Implement CloneToUninit for T Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/dates/struct.CalendarEvent.html Nightly-only experimental API for cloning to uninitialized memory. ```rust impl CloneToUninit for T where T: Clone, unsafe fn clone_to_uninit(&self, dest: *mut u8) 🔬This is a nightly-only experimental API. (`clone_to_uninit`) Performs copy-assignment from `self` to `dest`. Read more Source ``` -------------------------------- ### TryFrom Implementation Source: https://docs.rs/calcard/0.3.2/calcard/vcard/enum.VCardVersion.html Enables attempting to create a VCardVersion from another type, with error handling for failed conversions. ```APIDOC ## type Error = Infallible ### Description The type returned in the event of a conversion error. ## fn try_from(value: U) -> Result>::Error> ### Description Performs the conversion from another type `U` into a VCardVersion. ### Method `try_from` ### Parameters - `value` (U): The value to convert. ### Returns - `Result>::Error>`: Ok containing the VCardVersion if successful, or an Err if the conversion fails. ``` -------------------------------- ### Get JSID Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarComponent.html Retrieves the JSID of the ICalendarComponent. ```APIDOC ## impl ICalendarComponent ### `jsid(&self) -> Option<&str>` Returns the JSID of the component if set. ``` -------------------------------- ### Query Parameters by Name Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarEntry.html Provides methods to iterate over, get a single instance of, or check for the existence of a specific parameter by its name. ```rust pub fn parameters( &self, prop: &ICalendarParameterName, ) -> impl Iterator ``` ```rust pub fn parameter( &self, prop: &ICalendarParameterName, ) -> Option<&ICalendarParameterValue> ``` ```rust pub fn has_parameter(&self, prop: &ICalendarParameterName) -> bool ``` -------------------------------- ### clone_to_uninit Source: https://docs.rs/calcard/0.3.2/calcard/common/enum.CalendarScale.html This is a nightly-only experimental API. Performs copy-assignment from `self` to `dest`. ```APIDOC ## unsafe fn clone_to_uninit(&self, dest: *mut u8) ### Description Performs copy-assignment from `self` to `dest`. ### Method `clone_to_uninit` ### Parameters #### Path Parameters - **dest** (*mut u8) - Required - The destination pointer. ``` -------------------------------- ### Get UID Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarComponent.html Retrieves the UID of the ICalendarComponent. ```APIDOC ## impl ICalendarComponent ### `uid(&self) -> Option<&str>` Returns the UID of the component if set. ``` -------------------------------- ### Create New ICalendarEntry Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarEntry.html Constructs a new ICalendarEntry with a given name. Use associated methods like `with_params` or `with_value` to add further details. ```rust pub fn new(name: ICalendarProperty) -> Self ``` -------------------------------- ### CloneToUninit Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/enum.ICalendarValueType.html Provides a method to clone data to an uninitialized memory location. This is an experimental, nightly-only API. ```APIDOC ## unsafe fn clone_to_uninit(&self, dest: *mut u8) ### Description Performs copy-assignment from `self` to `dest`. ### Method `unsafe fn clone_to_uninit` ### Parameters - `dest` (*mut u8) - The destination pointer. ### Notes This is a nightly-only experimental API. ``` -------------------------------- ### RRule::validate Source: https://docs.rs/calcard/0.3.2/calcard/datecalc/rrule/struct.RRule.html Validates an RRule instance against a starting datetime. ```APIDOC ## RRule::validate ### Description Validates an RRule instance against a starting datetime. ### Signature `pub fn validate(self, dt_start: DateTime) -> Result` ### Parameters - `self` (RRule) - The RRule instance to validate. - `dt_start` (DateTime) - The starting datetime for validation. ### Returns - `Result` - A Result containing the validated RRule instance if successful, otherwise an RRuleError. ``` -------------------------------- ### Get a Specific Property Entry Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarComponent.html Retrieves a reference to the first ICalendarEntry matching the specified property name. Returns None if the property is not found. ```rust pub fn property(&self, prop: &ICalendarProperty) -> Option<&ICalendarEntry> ``` -------------------------------- ### Run Test Suite with MIRI Source: https://docs.rs/calcard Run the test suite with MIRI for memory safety checks. This requires the nightly toolchain. ```bash $ cargo +nightly miri test --all-features ``` -------------------------------- ### Get property ID or phonetic system Source: https://docs.rs/calcard/0.3.2/calcard/vcard/struct.VCardEntry.html Retrieves the property ID or phonetic system information from the VCardEntry. Phonetic system details include type and script. ```rust pub fn prop_id(&self) -> Option<&str> ``` ```rust pub fn phonetic_system(&self) -> Option> ``` ```rust pub fn phonetic_script(&self) -> Option<&str> ``` -------------------------------- ### Get Timezone Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarComponent.html Retrieves the timezone information associated with the ICalendarComponent. ```APIDOC ## impl ICalendarComponent ### `timezone(&self) -> Option<(&str, Tz)>` Returns the timezone information if available. ``` -------------------------------- ### Parser::new Source: https://docs.rs/calcard/0.3.2/calcard/struct.Parser.html Creates a new Parser instance with the given input string. ```APIDOC ## new ### Description Creates a new Parser instance with the given input string. ### Method ```rust pub fn new(input: &'x str) -> Self ``` ### Parameters * `input` (&'x str) - The input string to parse. ``` -------------------------------- ### Compare ICalendarEntry Instances Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarEntry.html Implements ordering and equality comparisons for ICalendarEntry, allowing them to be sorted and checked for equality. ```rust fn cmp(&self, other: &ICalendarEntry) -> Ordering ``` ```rust fn max(self, other: Self) -> Self where Self: Sized, ``` ```rust fn min(self, other: Self) -> Self where Self: Sized, ``` ```rust fn clamp(self, min: Self, max: Self) -> Self where Self: Sized, ``` ```rust fn eq(&self, other: &ICalendarEntry) -> bool ``` ```rust fn ne(&self, other: &Rhs) -> bool ``` ```rust fn partial_cmp(&self, other: &ICalendarEntry) -> Option ``` ```rust fn lt(&self, other: &Rhs) -> bool ``` ```rust fn le(&self, other: &Rhs) -> bool ``` ```rust fn gt(&self, other: &Rhs) -> bool ``` ```rust fn ge(&self, other: &Rhs) -> bool ``` -------------------------------- ### Get UID Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarComponent.html Retrieves the UID (Unique Identifier) of the component, if it has been set. ```rust pub fn uid(&self) -> Option<&str> ``` -------------------------------- ### Get Component by ID Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendar.html Retrieves an optional reference to an ICalendarComponent by its ID. ```rust pub fn component_by_id(&self, id: u32) -> Option<&ICalendarComponent> ``` -------------------------------- ### ICalendarDuration Methods Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarDuration.html Provides methods for creating, converting, and querying ICalendarDuration instances. ```APIDOC ### impl ICalendarDuration #### `pub fn from_seconds(seconds: i64) -> Self` Creates an `ICalendarDuration` from a total number of seconds. #### `pub fn to_time_delta(&self) -> Option` Converts the `ICalendarDuration` to a `TimeDelta`. #### `pub fn as_seconds(&self) -> i64` Returns the total duration in seconds. #### `pub fn is_empty(&self) -> bool` Checks if the duration is empty (all fields are zero). ``` -------------------------------- ### Get JSID Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarEntry.html Retrieves the JavaScript identifier (JSID) from an ICalendarEntry, if available. ```rust pub fn jsid(&self) -> Option<&str> ``` -------------------------------- ### from Source: https://docs.rs/calcard/0.3.2/calcard/vcard/struct.VCard.html Creates a VCard from itself (identity conversion). ```APIDOC ## impl From for T ### fn from(t: T) -> T Returns the argument unchanged. Used for identity conversions. ``` -------------------------------- ### NWeekday::new Constructor Source: https://docs.rs/calcard/0.3.2/calcard/datecalc/rrule/enum.NWeekday.html Creates a new NWeekday instance. Use `None` for the number to represent `Every` weekday, or provide an `i16` number for `Nth` weekday. ```rust pub fn new(number: Option, weekday: Weekday) -> Self> ``` -------------------------------- ### ICalendarRelated Enum Definition Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/enum.ICalendarRelated.html Defines the ICalendarRelated enum with Start and End variants. ```rust pub enum ICalendarRelated { Start, End, } ``` -------------------------------- ### NWeekday::new Constructor Source: https://docs.rs/calcard/0.3.2/calcard/datecalc/rrule/enum.NWeekday.html Creates a new NWeekday instance. The `number` parameter is optional and specifies the occurrence number for `Nth` variants. ```APIDOC ## NWeekday::new ```rust pub fn new(number: Option, weekday: Weekday) -> Self ``` ### Description Constructs a new `NWeekday` enum variant. If `number` is `Some(n)`, it creates an `Nth` variant. If `number` is `None`, it creates an `Every` variant. ``` -------------------------------- ### Get Timezones Iterator Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendar.html Returns an iterator over all timezone components within the ICalendar. ```rust pub fn timezones(&self) -> impl Iterator ``` -------------------------------- ### Get Timezone Identifier Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarEntry.html Retrieves the timezone identifier (TZID) from an ICalendarEntry, if present. ```rust pub fn tz_id(&self) -> Option<&str> ``` -------------------------------- ### fmt (Display) Source: https://docs.rs/calcard/0.3.2/calcard/vcard/struct.VCard.html Formats the VCard for display. ```APIDOC ## impl Display for VCard ### fn fmt(&self, f: &mut Formatter<'_>) -> Result Formats the `VCard` value using the given formatter for display output. ``` -------------------------------- ### ICalendarEntry Utility Methods Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarEntry.html Utility methods for checking entry types and retrieving specific information. ```APIDOC ## impl ICalendarEntry ### `is_type(&self, typ: &ICalendarValueType) -> bool` Checks if the entry is of a specific value type. ### `tz_id(&self) -> Option<&str>` Retrieves the time zone identifier for the entry, if available. ### `parameters(&self, prop: &ICalendarParameterName) -> impl Iterator` Returns an iterator over all parameter values for a given parameter name. ### `parameter(&self, prop: &ICalendarParameterName) -> Option<&ICalendarParameterValue>` Retrieves the first parameter value for a given parameter name, if it exists. ### `has_parameter(&self, prop: &ICalendarParameterName) -> bool` Checks if the entry has a parameter with the specified name. ### `jsid(&self) -> Option<&str>` Retrieves the JavaScript identifier for the entry, if available. ### `is_derived(&self) -> bool` Indicates whether the entry is derived. ### `calendar_address(&self) -> Option<&str>` Retrieves the calendar address for the entry, if available. ### `size(&self) -> usize` Returns the number of values in the entry. ``` -------------------------------- ### try_from Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarDay.html Performs the conversion from one type to another, returning a `Result`. ```APIDOC ## fn try_from(value: U) -> Result>::Error> ### Description Performs the conversion. ### Type Alias - `Error`: `Infallible` ### Signature ```rust fn try_from(value: U) -> Result>::Error> ``` ``` -------------------------------- ### Get Properties Iterator Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarComponent.html Returns an iterator over all ICalendarEntry items matching a specific ICalendarProperty. ```APIDOC ## impl ICalendarComponent ### `properties<'x, 'y: 'x>(&'x self, prop: &'y ICalendarProperty) -> impl Iterator + 'x` Returns an iterator over all entries matching the given property. ``` -------------------------------- ### Blanket Implementations Source: https://docs.rs/calcard/0.3.2/calcard/jscalendar/enum.JSCalendarValue.html Showcases blanket implementations for common traits like Any, Borrow, CloneToUninit, From, Into, ToOwned, TryFrom, and TryInto. ```APIDOC ### impl Any for T ### Description Implements the `Any` trait for any type `T`, providing runtime type information. ``` ```APIDOC #### fn type_id(&self) -> TypeId ### Description Gets the `TypeId` of `self`. ### Method `type_id` ``` ```APIDOC ### impl Borrow for T ### Description Implements the `Borrow` trait for any type `T`, allowing immutable borrowing. ``` ```APIDOC #### fn borrow(&self) -> &T ### Description Immutably borrows from an owned value. ### Method `borrow` ``` ```APIDOC ### impl BorrowMut for T ### Description Implements the `BorrowMut` trait for any type `T`, allowing mutable borrowing. ``` ```APIDOC #### fn borrow_mut(&mut self) -> &mut T ### Description Mutably borrows from an owned value. ### Method `borrow_mut` ``` ```APIDOC ### impl CloneToUninit for T ### Description Implements the `CloneToUninit` trait for any type `T` that implements `Clone`. This is a nightly-only experimental API. ``` ```APIDOC #### unsafe fn clone_to_uninit(&self, dest: *mut u8) ### Description 🔬This is a nightly-only experimental API. (`clone_to_uninit`) Performs copy-assignment from `self` to `dest`. ### Method `clone_to_uninit` ### Parameters - `dest`: `*mut u8` - A mutable pointer to the destination memory. ``` ```APIDOC ### impl From for T ### Description Implements the `From` trait for any type `T`, allowing conversion from itself. ``` ```APIDOC #### fn from(t: T) -> T ### Description Returns the argument unchanged. ### Method `from` ### Parameters - `t`: `T` - The value to convert. ``` ```APIDOC ### impl Into for T ### Description Implements the `Into` trait for any type `T` where `U` implements `From`, enabling conversion into `U`. ``` ```APIDOC #### fn into(self) -> U ### Description Calls `U::from(self)`. That is, this conversion is whatever the implementation of `From for U` chooses to do. ### Method `into` ``` ```APIDOC ### impl ToOwned for T ### Description Implements the `ToOwned` trait for any type `T` that implements `Clone`, allowing creation of owned data from borrowed data. ``` ```APIDOC #### type Owned = T ### Description The resulting type after obtaining ownership. ``` ```APIDOC #### fn to_owned(&self) -> T ### Description Creates owned data from borrowed data, usually by cloning. ### Method `to_owned` ``` ```APIDOC #### fn clone_into(&self, target: &mut T) ### Description Uses borrowed data to replace owned data, usually by cloning. ### Method `clone_into` ### Parameters - `target`: `&mut T` - A mutable reference to the target owned data. ``` ```APIDOC ### impl TryFrom for T ### Description Implements the `TryFrom` trait for any types `T` and `U` where `U` implements `Into`, enabling fallible conversion from `U` to `T`. ``` ```APIDOC #### type Error = Infallible ### Description The type returned in the event of a conversion error. For this implementation, it's `Infallible`. ``` ```APIDOC #### fn try_from(value: U) -> Result>::Error> ### Description Performs the conversion from `U` to `T`. ### Method `try_from` ### Parameters - `value`: `U` - The value to convert. ``` ```APIDOC ### impl TryInto for T ### Description Implements the `TryInto` trait for any types `T` and `U` where `U` implements `TryFrom`, enabling fallible conversion from `T` into `U`. ``` ```APIDOC #### type Error = >::Error ### Description The type returned in the event of a conversion error. ``` ```APIDOC #### fn try_into(self) -> Result>::Error> ### Description Performs the conversion from `T` to `U`. ### Method `try_into` ``` -------------------------------- ### Get Mutable Property Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarComponent.html Retrieves a mutable reference to a specific ICalendarEntry for a given ICalendarProperty. ```APIDOC ## impl ICalendarComponent ### `property_mut(&mut self, prop: &ICalendarProperty) -> Option<&mut ICalendarEntry>` Returns a mutable reference to the ICalendarEntry for the specified property, if it exists. ``` -------------------------------- ### Get Calendar Address Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarEntry.html Retrieves the calendar address associated with the ICalendarEntry, if one exists. ```rust pub fn calendar_address(&self) -> Option<&str> ``` -------------------------------- ### ICalendarEntry Constructors and Builders Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarEntry.html Provides methods for creating and modifying ICalendarEntry instances. ```APIDOC ## impl ICalendarEntry ### `new(name: ICalendarProperty) -> Self` Creates a new ICalendarEntry with the given name. ### `with_params(self, params: Vec) -> Self` Returns a new ICalendarEntry with the specified parameters. ### `with_value(self, value: impl Into) -> Self` Returns a new ICalendarEntry with an added value. ### `with_values(self, values: Vec) -> Self` Returns a new ICalendarEntry with the specified values. ### `with_param(self, param: impl Into) -> Self` Returns a new ICalendarEntry with an added parameter. ### `add_param(&mut self, param: impl Into)` Adds a parameter to the existing ICalendarEntry. ### `with_param_opt(self, param: Option>) -> Self` Returns a new ICalendarEntry with an optional parameter if provided. ``` -------------------------------- ### Default ConversionOptions Source: https://docs.rs/calcard/0.3.2/calcard/jscontact/import/struct.ConversionOptions.html Provides information on how to obtain the default `ConversionOptions` value. ```APIDOC ### impl Default for ConversionOptions #### fn default() -> Self Returns the default `ConversionOptions` value. ``` -------------------------------- ### CalendarExpand - Default Implementation Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/dates/struct.CalendarExpand.html Provides a default value for CalendarExpand, initializing it with empty event and error lists. ```APIDOC ### impl Default for CalendarExpand #### fn default() -> CalendarExpand Returns the default value for `CalendarExpand`, which is an empty struct with no events and no errors. ``` -------------------------------- ### Get the month value from ICalendarMonth Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarMonth.html Returns the month as a u8 value from the ICalendarMonth instance. ```rust pub fn month(&self) -> u8 ``` -------------------------------- ### Get Size of ICalendarParameterValue Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/enum.ICalendarParameterValue.html Returns the size in bytes of the ICalendarParameterValue. This can be useful for memory estimations. ```rust pub fn size(&self) -> usize ``` -------------------------------- ### ICalendarParameter Constructors and Methods Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarParameter.html Provides various methods for creating and manipulating ICalendarParameter instances. ```APIDOC ## impl ICalendarParameter ### `new` ```rust pub fn new( name: ICalendarParameterName, value: impl Into, ) -> Self ``` Creates a new ICalendarParameter. ### `altrep` ```rust pub fn altrep(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'ALTREP'. ### `cn` ```rust pub fn cn(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'CN'. ### `cutype` ```rust pub fn cutype(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'CUTYPE'. ### `delegated_from` ```rust pub fn delegated_from(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'DELEGATED-FROM'. ### `delegated_to` ```rust pub fn delegated_to(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'DELEGATED-TO'. ### `dir` ```rust pub fn dir(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'DIR'. ### `fmttype` ```rust pub fn fmttype(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'FMTTYPE'. ### `fbtype` ```rust pub fn fbtype(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'FBTYPE'. ### `language` ```rust pub fn language(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'LANGUAGE'. ### `member` ```rust pub fn member(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'MEMBER'. ### `partstat` ```rust pub fn partstat(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'PARTSTAT'. ### `range` ```rust pub fn range(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'RANGE'. ### `related` ```rust pub fn related(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'RELATED'. ### `reltype` ```rust pub fn reltype(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'RELTYPE'. ### `role` ```rust pub fn role(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'ROLE'. ### `rsvp` ```rust pub fn rsvp(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'RSVP'. ### `schedule_agent` ```rust pub fn schedule_agent(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'SCHEDULE-AGENT'. ### `schedule_force_send` ```rust pub fn schedule_force_send(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'SCHEDULE-FORCE-SEND'. ### `schedule_status` ```rust pub fn schedule_status(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'SCHEDULE-STATUS'. ### `sent_by` ```rust pub fn sent_by(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'SENT-BY'. ### `tzid` ```rust pub fn tzid(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'TZID'. ### `value` ```rust pub fn value(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'VALUE'. ### `display` ```rust pub fn display(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'DISPLAY'. ### `email` ```rust pub fn email(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'EMAIL'. ### `feature` ```rust pub fn feature(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'FEATURE'. ### `label` ```rust pub fn label(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'LABEL'. ### `size` ```rust pub fn size(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'SIZE'. ### `filename` ```rust pub fn filename(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'FILENAME'. ### `managed_id` ```rust pub fn managed_id(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'MANAGED-ID'. ### `order` ```rust pub fn order(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'ORDER'. ### `schema` ```rust pub fn schema(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'SCHEMA'. ### `derived` ```rust pub fn derived(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'DERIVED'. ### `gap` ```rust pub fn gap(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'GAP'. ### `linkrel` ```rust pub fn linkrel(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'LINKREL'. ### `jsptr` ```rust pub fn jsptr(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'JSPTR'. ### `jsid` ```rust pub fn jsid(value: impl Into) -> Self ``` Creates an ICalendarParameter with the name 'JSID'. ``` -------------------------------- ### Setting include_vcard_parameters Source: https://docs.rs/calcard/0.3.2/calcard/jscontact/import/struct.ConversionOptions.html Demonstrates how to set the `include_vcard_parameters` field when creating or modifying a `ConversionOptions` instance. ```APIDOC ## impl ConversionOptions ### pub fn include_vcard_parameters(self, include: bool) -> Self Sets the `include_vcard_parameters` option for the `ConversionOptions` struct. ``` -------------------------------- ### fn type_id Source: https://docs.rs/calcard/0.3.2/calcard/common/timezone/enum.Tz.html Gets the TypeId of the Tz enum instance. This is part of the Any trait implementation. ```APIDOC #### fn type_id(&self) -> TypeId ### Description Gets the `TypeId` of `self`. Read more ``` -------------------------------- ### Define CalendarEvent Struct Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/dates/struct.CalendarEvent.html Defines the CalendarEvent struct with generic types for start and end times. ```rust pub struct CalendarEvent { pub comp_id: u32, pub start: S, pub end: E, } ``` -------------------------------- ### try_parse Method Source: https://docs.rs/calcard/0.3.2/calcard/vcard/enum.VCardVersion.html Attempts to parse a string into a VCardVersion. Returns None if the string does not match any known version. ```APIDOC ## Method: try_parse ### Description Attempts to parse a string input into a `VCardVersion` enum variant. ### Signature ```rust pub fn try_parse(input: &str) -> Option ``` ### Parameters * `input` (&str): The string to parse. ``` -------------------------------- ### Get Unique IDs from ICalendar Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendar.html Provides an iterator over all unique identifiers (UIDs) present in the ICalendar. ```rust pub fn uids(&self) -> impl Iterator ``` -------------------------------- ### TryFrom Source: https://docs.rs/calcard/0.3.2/calcard/jscontact/enum.JSContactKind.html Enables fallible conversion from one type to another. ```APIDOC ## type Error = Infallible ### Description The type returned in the event of a conversion error. `Infallible` indicates that this conversion cannot fail. ## fn try_from(value: U) -> Result>::Error> ### Description Performs the conversion from `U` to `T`. ### Method `try_from` ### Parameters - `value` (U): The value to convert. ### Returns A `Result` containing the converted value of type `T` if successful, or an error if the conversion fails. ``` -------------------------------- ### ICalendarSkip IanaString Implementation Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/enum.ICalendarSkip.html Provides a method to get the static string representation of an ICalendarSkip variant. ```rust fn as_str(&self) -> &'static str ``` -------------------------------- ### Implement From for T Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/dates/struct.CalendarEvent.html Provides a trivial conversion from T to T. ```rust impl From for T fn from(t: T) -> T Returns the argument unchanged. Source ``` -------------------------------- ### ICalendarSkip as_str Implementation Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/enum.ICalendarSkip.html Provides a method to get the static string representation of an ICalendarSkip variant. ```rust pub fn as_js_str(&self) -> &'static str ``` -------------------------------- ### From Source: https://docs.rs/calcard/0.3.2/calcard/jscontact/enum.JSContactKind.html Enables conversion from one type to another. ```APIDOC ## fn from(t: T) -> T ### Description Returns the argument unchanged. This is a placeholder implementation for the `From for T` trait. ### Method `from` ### Parameters - `t` (T): The value to convert. ### Returns The argument `t`. ``` -------------------------------- ### Offset Implementation for RRuleOffset Source: https://docs.rs/calcard/0.3.2/calcard/common/timezone/enum.RRuleOffset.html Provides a method to get the fixed offset from UTC for an RRuleOffset value. ```rust fn fix(&self) -> FixedOffset ``` -------------------------------- ### ICalendarEntry Trait Implementations Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarEntry.html Standard trait implementations for ICalendarEntry, including Clone, Debug, Serialize, Deserialize, Ord, PartialEq, and PartialOrd. ```APIDOC ## Trait Implementations ### `impl Clone for ICalendarEntry` - `clone(&self) -> ICalendarEntry`: Returns a duplicate of the value. - `clone_from(&mut self, source: &Self)` ### `impl Debug for ICalendarEntry` - `fmt(&self, f: &mut Formatter<'_>) -> Result`: Formats the value using the given formatter. ### `impl<'de> Deserialize<'de> for ICalendarEntry` - `deserialize<__D>(__deserializer: __D) -> Result`: Deserialize this value from the given Serde deserializer. ### `impl Ord for ICalendarEntry` - `cmp(&self, other: &ICalendarEntry) -> Ordering`: Compares `self` and `other`. - `max(self, other: Self) -> Self`: Returns the maximum of two values. - `min(self, other: Self) -> Self`: Returns the minimum of two values. - `clamp(self, min: Self, max: Self) -> Self`: Restricts a value to a certain interval. ### `impl PartialEq for ICalendarEntry` - `eq(&self, other: &ICalendarEntry) -> bool`: Tests for equality. - `ne(&self, other: &Rhs) -> bool`: Tests for inequality. ### `impl PartialOrd for ICalendarEntry` - `partial_cmp(&self, other: &ICalendarEntry) -> Option`: Returns an ordering between `self` and `other` if one exists. - `lt(&self, other: &Rhs) -> bool`: Tests less than. - `le(&self, other: &Rhs) -> bool`: Tests less than or equal to. - `gt(&self, other: &Rhs) -> bool`: Tests greater than. - `ge(&self, other: &Rhs) -> bool`: Tests greater than or equal to. ### `impl Serialize for ICalendarEntry` - `serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>`: Serialize this value into the given Serde serializer. ``` -------------------------------- ### ICalendarRelated Enum Definition Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/enum.ICalendarRelated.html This snippet shows the definition of the ICalendarRelated enum, which has two variants: Start and End. ```APIDOC ## Enum ICalendarRelated This enum represents the related property in iCalendar, which can be either `Start` or `End`. ### Variants * **Start**: Represents the start of a recurring event or component. * **End**: Represents the end of a recurring event or component. ### Example Usage ```rust use calcard::icalendar::ICalendarRelated; let related_start = ICalendarRelated::Start; let related_end = ICalendarRelated::End; println!("Related start: {:?}", related_start); println!("Related end: {:?}", related_end); ``` ``` -------------------------------- ### timestamp_opt Source: https://docs.rs/calcard/0.3.2/calcard/common/timezone/enum.Tz.html Creates a new DateTime from a UNIX timestamp and nanoseconds, returning a LocalResult. ```APIDOC ## timestamp_opt ### Description Makes a new `DateTime` from the number of non-leap seconds since January 1, 1970 0:00:00 UTC (aka “UNIX timestamp”) and the number of nanoseconds since the last whole non-leap second. ### Signature `fn timestamp_opt(&self, secs: i64, nsecs: u32) -> LocalResult>` ``` -------------------------------- ### Get Mutable Properties Iterator Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarComponent.html Returns a mutable iterator over all ICalendarEntry items matching a specific ICalendarProperty. ```APIDOC ## impl ICalendarComponent ### `properties_mut<'x, 'y: 'x>(&'x mut self, prop: &'y ICalendarProperty) -> impl Iterator + 'x` Returns a mutable iterator over all entries matching the given property. ``` -------------------------------- ### UIDs and Size Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendar.html Provides methods to get all unique identifiers (UIDs) and the total number of components in the calendar. ```APIDOC ## Calendar Information ### `uids` ```rust pub fn uids(&self) -> impl Iterator ``` Returns an iterator over the unique identifiers (UIDs) of all components in the `ICalendar` object. ### `size` ```rust pub fn size(&self) -> usize ``` Returns the total number of components currently stored in the `ICalendar` object. ``` -------------------------------- ### Builder Methods for ConversionOptions Source: https://docs.rs/calcard/0.3.2/calcard/jscalendar/import/struct.ConversionOptions.html Provides builder-style methods to configure ConversionOptions. ```APIDOC ### impl ConversionOptions #### pub fn include_ical_components(self, include: bool) -> Self Configures the `include_ical_components` option. #### pub fn return_first(self, return_first: bool) -> Self Configures the `return_first` option. ``` -------------------------------- ### CalendarExpand - Clone Implementation Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/dates/struct.CalendarExpand.html Allows creating a deep copy of a CalendarExpand instance. ```APIDOC ### impl Clone for CalendarExpand #### fn clone(&self) -> CalendarExpand Returns a duplicate of the `CalendarExpand` value. ``` -------------------------------- ### Get Alarms for Component ID Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendar.html Returns an iterator over alarm components associated with a specific component ID. ```rust pub fn alarms_for_id( &self, id: u32, ) -> impl Iterator ``` -------------------------------- ### fn from Source: https://docs.rs/calcard/0.3.2/calcard/common/timezone/enum.Tz.html Creates a new instance of the same type from the given value. This is a standard From trait implementation. ```APIDOC #### fn from(t: T) -> T ### Description Returns the argument unchanged. ``` -------------------------------- ### Get ICalendarParameterValue as Boolean Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/enum.ICalendarParameterValue.html Attempts to retrieve the value of an ICalendarParameterValue as a bool. Returns None if the variant is not Bool. ```rust pub fn as_bool(&self) -> Option ``` -------------------------------- ### Get ICalendarParameterValue as Integer Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/enum.ICalendarParameterValue.html Attempts to retrieve the value of an ICalendarParameterValue as a u64. Returns None if the variant is not Integer. ```rust pub fn as_integer(&self) -> Option ``` -------------------------------- ### CalendarExpand - PartialEq Implementation Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/dates/struct.CalendarExpand.html Enables comparison for equality between two CalendarExpand instances. ```APIDOC ### impl PartialEq for CalendarExpand #### fn eq(&self, other: &CalendarExpand) -> bool Tests if `self` and `other` `CalendarExpand` values are equal. ``` -------------------------------- ### Create New Parser Instance Source: https://docs.rs/calcard/0.3.2/calcard/struct.Parser.html Creates a new Parser instance with the given input string slice. ```rust pub fn new(input: &'x str) -> Self ``` -------------------------------- ### Get ICalendarParameterValue as Text Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/enum.ICalendarParameterValue.html Attempts to retrieve the value of an ICalendarParameterValue as a string slice. Returns None if the variant is not Text. ```rust pub fn as_text(&self) -> Option<&str> ``` -------------------------------- ### Validate RRule Source: https://docs.rs/calcard/0.3.2/calcard/datecalc/rrule/struct.RRule.html Validates an RRule instance against a given start date and time. Returns a Result indicating success or an RRuleError. ```rust pub fn validate(self, dt_start: DateTime) -> Result ``` -------------------------------- ### Setting include_vcard_parameters Source: https://docs.rs/calcard/0.3.2/calcard/jscontact/import/struct.ConversionOptions.html Demonstrates how to set the include_vcard_parameters field on a ConversionOptions instance. This method allows chaining configuration options. ```rust pub fn include_vcard_parameters(self, include: bool) -> Self ``` -------------------------------- ### Get Status Property Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarComponent.html Retrieves the ICalendarStatus of the component, such as 'CONFIRMED', 'TENTATIVE', or 'CANCELLED'. Returns None if the status property is not present. ```rust pub fn status(&self) -> Option<&ICalendarStatus> ``` -------------------------------- ### NWeekday StructuralPartialEq Implementation Source: https://docs.rs/calcard/0.3.2/calcard/datecalc/rrule/enum.NWeekday.html Enables structural equality comparisons for NWeekday values, useful in scenarios requiring deep equality checks. ```rust impl StructuralPartialEq for NWeekday ``` -------------------------------- ### NWeekday Blanket Implementations Source: https://docs.rs/calcard/0.3.2/calcard/datecalc/rrule/enum.NWeekday.html Shows blanket implementations for NWeekday, including Any, Borrow, BorrowMut, CloneToUninit, From, Into, ToOwned, TryFrom, and TryInto, providing common trait functionalities. ```rust impl Any for T where T: 'static + ?Sized, ``` ```rust fn type_id(&self) -> TypeId ``` ```rust impl Borrow for T where T: ?Sized, ``` ```rust fn borrow(&self) -> &T ``` ```rust impl BorrowMut for T where T: ?Sized, ``` ```rust fn borrow_mut(&mut self) -> &mut T ``` ```rust impl CloneToUninit for T where T: Clone, ``` ```rust unsafe fn clone_to_uninit(&self, dest: *mut u8) ``` ```rust impl From for T ``` ```rust fn from(t: T) -> T ``` ```rust impl Into for T where U: From, ``` ```rust fn into(self) -> U ``` ```rust impl ToOwned for T where T: Clone, ``` ```rust type Owned = T ``` ```rust fn to_owned(&self) -> T ``` ```rust fn clone_into(&self, target: &mut T) ``` ```rust impl TryFrom for T where U: Into, ``` ```rust type Error = Infallible ``` ```rust fn try_from(value: U) -> Result>::Error> ``` ```rust impl TryInto for T where U: TryFrom, ``` ```rust type Error = >::Error ``` ```rust fn try_into(self) -> Result>::Error> ``` -------------------------------- ### Get reference to Other value Source: https://docs.rs/calcard/0.3.2/calcard/common/enum.IanaType.html Returns an Option<&O> if the IanaType is Other, providing a shared reference to the Other value. Returns None if the variant is Iana. ```rust pub fn other(&self) -> Option<&O> ``` -------------------------------- ### fmt (Debug) Source: https://docs.rs/calcard/0.3.2/calcard/vcard/struct.VCard.html Formats the VCard for debugging purposes. ```APIDOC ## impl Debug for VCard ### fn fmt(&self, f: &mut Formatter<'_>) -> Result Formats the `VCard` value using the given formatter for debug output. ``` -------------------------------- ### Get language or alternative ID Source: https://docs.rs/calcard/0.3.2/calcard/vcard/struct.VCardEntry.html Extracts the language string or the alternative ID from the VCardEntry's parameters. Returns `None` if not present. ```rust pub fn language(&self) -> Option<&str> ``` ```rust pub fn alt_id(&self) -> Option<&str> ``` -------------------------------- ### clone_from Source: https://docs.rs/calcard/0.3.2/calcard/vcard/struct.VCard.html Performs copy-assignment from a source VCard. ```APIDOC ## impl Clone for VCard ### fn clone_from(&mut self, source: &Self) Performs copy-assignment from the `source` `VCard` to `self`. ``` -------------------------------- ### Get Transparency Property Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarComponent.html Retrieves the ICalendarTransparency of the component, indicating whether it is 'TRANSPARENT' or 'OPAQUE' (busy/free time). Returns None if not specified. ```rust pub fn transparency(&self) -> Option<&ICalendarTransparency> ``` -------------------------------- ### VCardEntry Constructors and Builders Source: https://docs.rs/calcard/0.3.2/calcard/vcard/struct.VCardEntry.html Provides methods for creating and modifying VCardEntry instances. ```APIDOC ### impl VCardEntry #### `pub fn new(name: VCardProperty) -> Self` Creates a new VCardEntry with the given name. #### `pub fn with_params(self, params: Vec) -> Self` Sets the parameters for the VCardEntry. #### `pub fn with_group(self, group: Option) -> Self` Sets the group for the VCardEntry. #### `pub fn with_value(self, value: impl Into) -> Self` Adds a single value to the VCardEntry. #### `pub fn with_values(self, values: Vec) -> Self` Adds multiple values to the VCardEntry. #### `pub fn with_param(self, param: impl Into) -> Self` Adds a single parameter to the VCardEntry. #### `pub fn add_param(&mut self, param: impl Into)` Mutably adds a parameter to the VCardEntry. #### `pub fn with_param_opt(self, param: Option>) -> Self` Adds an optional parameter to the VCardEntry. ``` -------------------------------- ### Get Timezone Information Source: https://docs.rs/calcard/0.3.2/calcard/icalendar/struct.ICalendarComponent.html Retrieves the timezone information associated with the component, if available. Returns a tuple of the timezone ID and Tz object. ```rust pub fn timezone(&self) -> Option<(&str, Tz)> ```