-
Notifications
You must be signed in to change notification settings - Fork 247
Update PRODID and VERSION property handling
#748
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
@minichma TBD: Add the current ical.net version to the PRODID |
|
The RFC says the PRODID should contain
so, yes, including the version would probably be a good idea. |
|
@minichma RFC5545 says that PRODID and VERSION are mandatory. This may be the reason for the current implementation (always set the defaults when serializing). TBD:
|
Issue: `Calendar` has setters for `ProductId` and `Version` which are overridden with fixed values when serializing. - When creating a new `Calendar` instance, `ProductId` and `Version` contain default values - When Deserializing an iCalendar, `ProductId` and `Version` will be taken from the input - `ProductId` and `Version` can be overridden by user code. An attempt to set as an empty string will throw. - Update the default `PRODID` property `LibraryMetadata.ProdId` to include the ical.net assembly version. Example: "PRODID:-//github.com/ical-org/ical.net//NONSGML ical.net 5.4.3//EN" - Modified `CalendarSerializer.SerializeToString` so that the `ProdId` or `Version` set by users do not get overridden - Add an xmldoc description about the purpose of `ProdId` and `Version`, and about the risks when modified - Add unit tests Resolves ical-org#531
My preferred option too. Only populate ProdId and Version when creating a new calendar, but not when deserializing an existing one. |
|



Issue:
Calendarhas setters forProductIdandVersionwhich are overridden with fixed values when serializing.Calendarinstance,ProductIdandVersioncontain default valuesProductIdandVersionwill be taken from the inputProductIdandVersioncan be overridden by user code. An attempt to set as an empty string will throw.PRODIDpropertyLibraryMetadata.ProdIdto include the ical.net assembly version. Example: "PRODID:-//github.com/ical-org/ical.net//NONSGML ical.net 5.4.3//EN"CalendarSerializer.SerializeToStringso that theProdIdorVersionset by users do not get overriddenProdIdandVersion, and about the risks when modifiedResolves #531