Documentation ¶
Index ¶
- Constants
- func BinaryDecoderError(msg string) error
- func InvalidBoolError(value string) error
- func InvalidCalendarUserAddress(address string) error
- func InvalidCharacter(value uint8) error
- func InvalidDateLength(length int) error
- func InvalidDateTimeLength(length int) error
- func InvalidDay(msg string) error
- func InvalidDurationFormat(value string) error
- func InvalidDurationInteger(msg string) error
- func InvalidEndDateTime(msg string) error
- func InvalidEndDuration(msg string) error
- func InvalidEscapeSequence(value string) error
- func InvalidFrequency(value string) error
- func InvalidHours(msg string) error
- func InvalidIntLimits(low, high int) error
- func InvalidInteger(value string) error
- func InvalidMinutes(msg string) error
- func InvalidMonth(msg string) error
- func InvalidPeriodOfTime(value string) error
- func InvalidPrefix(value string) error
- func InvalidRecurrenceRule(value string) error
- func InvalidSeconds(msg string) error
- func InvalidStartDateTime(msg string) error
- func InvalidUTCOffset(value string) error
- func InvalidUTCOffsetLength(length int) error
- func InvalidWeekDay(value string) error
- func InvalidYear(msg string) error
- func OutOfBounds(num int) error
- type AlarmTriggerRelationship
- type AlarmTriggerRelationshipValue
- type AlternateTextRepresentation
- type BinaryValue
- type BooleanValue
- type CalendarUserAddressValue
- type CalendarUserType
- type CalendarUserTypeValue
- type CommonName
- type ContentLine
- type DateTimeValue
- type DateValue
- type Delegatees
- type Delegators
- type DirectoryEntryReference
- type DurationValue
- type EncodingFormat
- type FloatValue
- type FormatType
- type FreeBusyTimeType
- type FreeBusyTimeValue
- type GroupOrListMembership
- type IANAToken
- type InlineEncoding
- type IntegerValue
- type Language
- type Name
- type Param
- type ParamText
- type ParamValue
- type ParticipationRole
- type ParticipationRoleValue
- type ParticipationStatus
- type ParticipationStatusValue
- type PeriodOfTimeValue
- type PropParamType
- type PropValueType
- type RSVPExpectation
- type RSVPExpectationValue
- type RecurrenceIdentifierRange
- type RecurrenceIdentifierRangeValue
- type RecurrenceRuleFrequency
- type RecurrenceRuleValue
- type RelationshipType
- type RelationshipTypeValue
- type SentBy
- type TextValue
- type TimeValue
- type TimeZoneIdentifier
- type Token
- type TokenType
- type URIValue
- type UTCOffsetValue
- type Value
- type ValueDataType
- type ValueDataTypeValue
- type VendorID
- type WeekDay
- type WeekDayNumber
- type XName
Constants ¶
const ( // LineBreakDelimiter represents a CRLF sequence in a byte representation. LineBreakDelimiter string = "\r\n" // WhitespaceDelimiter represents a single whitespace character in a byte representation. WhitespaceDelimiter string = " " // MaxLineSizeBytes denotes how long a content line should be before it is folded up with line breaks. MaxLineSizeBytes int = 75 )
Variables ¶
This section is empty.
Functions ¶
func BinaryDecoderError ¶
func InvalidBoolError ¶
func InvalidCharacter ¶
func InvalidDateLength ¶
func InvalidDateTimeLength ¶
func InvalidDay ¶
func InvalidDurationFormat ¶
func InvalidDurationInteger ¶
func InvalidEndDateTime ¶
func InvalidEndDuration ¶
func InvalidEscapeSequence ¶
func InvalidFrequency ¶
func InvalidHours ¶
func InvalidIntLimits ¶
func InvalidInteger ¶
func InvalidMinutes ¶
func InvalidMonth ¶
func InvalidPeriodOfTime ¶
func InvalidPrefix ¶
func InvalidRecurrenceRule ¶
func InvalidSeconds ¶
func InvalidStartDateTime ¶
func InvalidUTCOffset ¶
func InvalidUTCOffsetLength ¶
func InvalidWeekDay ¶
func InvalidYear ¶
func OutOfBounds ¶
Types ¶
type AlarmTriggerRelationship ¶
type AlarmTriggerRelationship AlarmTriggerRelationshipValue
func (AlarmTriggerRelationship) ParameterName ¶
func (a AlarmTriggerRelationship) ParameterName() string
func (AlarmTriggerRelationship) String ¶
func (a AlarmTriggerRelationship) String() string
func (AlarmTriggerRelationship) Type ¶
func (a AlarmTriggerRelationship) Type() PropParamType
type AlarmTriggerRelationshipValue ¶
type AlarmTriggerRelationshipValue string
const ( Start AlarmTriggerRelationshipValue = "START" End AlarmTriggerRelationshipValue = "END" )
type AlternateTextRepresentation ¶
type AlternateTextRepresentation string // QuotedString
AlternateTextRepresentation specifies an alternate text representation for the property value on the content line. Value has to be a Token of type QuotedString.
func (AlternateTextRepresentation) ParameterName ¶
func (a AlternateTextRepresentation) ParameterName() string
func (AlternateTextRepresentation) String ¶
func (a AlternateTextRepresentation) String() string
func (AlternateTextRepresentation) Type ¶
func (a AlternateTextRepresentation) Type() PropParamType
type BinaryValue ¶
type BinaryValue []byte
func NewBinaryValueFromBase64 ¶
func NewBinaryValueFromBase64(value string) (BinaryValue, error)
func (BinaryValue) String ¶
func (b BinaryValue) String() string
func (BinaryValue) Type ¶
func (b BinaryValue) Type() PropValueType
type BooleanValue ¶
type BooleanValue bool
func NewBooleanValue ¶
func NewBooleanValue(value string) (BooleanValue, error)
func (BooleanValue) String ¶
func (b BooleanValue) String() string
func (BooleanValue) Type ¶
func (b BooleanValue) Type() PropValueType
type CalendarUserAddressValue ¶
func NewCalendarUserAddressValue ¶
func NewCalendarUserAddressValue(address string) (CalendarUserAddressValue, error)
func (CalendarUserAddressValue) QuotedString ¶
func (c CalendarUserAddressValue) QuotedString() string
func (CalendarUserAddressValue) String ¶
func (c CalendarUserAddressValue) String() string
func (CalendarUserAddressValue) StringWithPrefix ¶
func (c CalendarUserAddressValue) StringWithPrefix() string
func (CalendarUserAddressValue) Type ¶
func (c CalendarUserAddressValue) Type() PropValueType
type CalendarUserType ¶
type CalendarUserType string // CalendarUserTypeValue | IANAToken | XName
func (CalendarUserType) ParameterName ¶
func (c CalendarUserType) ParameterName() string
func (CalendarUserType) String ¶
func (c CalendarUserType) String() string
func (CalendarUserType) Type ¶
func (c CalendarUserType) Type() PropParamType
type CalendarUserTypeValue ¶
type CalendarUserTypeValue string
const ( Individual CalendarUserTypeValue = "INDIVIDUAL" Group CalendarUserTypeValue = "GROUP" Resource CalendarUserTypeValue = "RESOURCE" Room CalendarUserTypeValue = "ROOM" Unknown CalendarUserTypeValue = "UNKNOWN" )
type CommonName ¶
type CommonName string // IANAToken | XName
CommonName specifies the common name to be associated with the calendar user specified by the property.
func (CommonName) ParameterName ¶
func (c CommonName) ParameterName() string
func (CommonName) String ¶
func (c CommonName) String() string
func (CommonName) Type ¶
func (c CommonName) Type() PropParamType
type ContentLine ¶
type DateTimeValue ¶
func NewDateTimeValue ¶
func NewDateTimeValue(value string) (DateTimeValue, error)
func (DateTimeValue) IsZero ¶
func (d DateTimeValue) IsZero() bool
func (DateTimeValue) String ¶
func (d DateTimeValue) String() string
func (DateTimeValue) Type ¶
func (d DateTimeValue) Type() PropValueType
type DateValue ¶
func NewDateValue ¶
func (DateValue) Type ¶
func (d DateValue) Type() PropValueType
type Delegatees ¶
type Delegatees []CalendarUserAddressValue
func (Delegatees) ParameterName ¶
func (d Delegatees) ParameterName() string
func (Delegatees) String ¶
func (d Delegatees) String() string
func (Delegatees) Type ¶
func (d Delegatees) Type() PropParamType
type Delegators ¶
type Delegators []CalendarUserAddressValue
func (Delegators) ParameterName ¶
func (d Delegators) ParameterName() string
func (Delegators) String ¶
func (d Delegators) String() string
func (Delegators) Type ¶
func (d Delegators) Type() PropParamType
type DirectoryEntryReference ¶
type DirectoryEntryReference string
TODO (c.nicola): DQUOTE uri DQUOTE (https://datatracker.ietf.org/doc/html/rfc3986#section-3)
func (DirectoryEntryReference) ParameterName ¶
func (d DirectoryEntryReference) ParameterName() string
func (DirectoryEntryReference) String ¶
func (d DirectoryEntryReference) String() string
func (DirectoryEntryReference) Type ¶
func (d DirectoryEntryReference) Type() PropParamType
type DurationValue ¶
func NewDurationValue ¶
func NewDurationValue(value string) (DurationValue, error)
func (DurationValue) String ¶
func (d DurationValue) String() string
func (DurationValue) Type ¶
func (d DurationValue) Type() PropValueType
type EncodingFormat ¶
type EncodingFormat string
const ( EightBit EncodingFormat = "8BIT" Base64 EncodingFormat = "BASE64" )
type FloatValue ¶
type FloatValue float64
func NewFloatValue ¶
func NewFloatValue(value string) (FloatValue, error)
func (FloatValue) String ¶
func (f FloatValue) String() string
func (FloatValue) Type ¶
func (f FloatValue) Type() PropValueType
type FormatType ¶
type FormatType string
TODO (c.nicola): type-name | subtype-name (https://datatracker.ietf.org/doc/html/rfc4288#section-4.2)
func (FormatType) ParameterName ¶
func (f FormatType) ParameterName() string
func (FormatType) String ¶
func (f FormatType) String() string
func (FormatType) Type ¶
func (f FormatType) Type() PropParamType
type FreeBusyTimeType ¶
type FreeBusyTimeType string // FreeBusyTimeValue | IANAToken | XName
func (FreeBusyTimeType) ParameterName ¶
func (f FreeBusyTimeType) ParameterName() string
func (FreeBusyTimeType) String ¶
func (f FreeBusyTimeType) String() string
func (FreeBusyTimeType) Type ¶
func (f FreeBusyTimeType) Type() PropParamType
type FreeBusyTimeValue ¶
type FreeBusyTimeValue string
const ( Free FreeBusyTimeValue = "FREE" Busy FreeBusyTimeValue = "BUSY" BusyTentative FreeBusyTimeValue = "BUSY-TENTATIVE" )
type GroupOrListMembership ¶
type GroupOrListMembership []CalendarUserAddressValue
func (GroupOrListMembership) ParameterName ¶
func (g GroupOrListMembership) ParameterName() string
func (GroupOrListMembership) String ¶
func (g GroupOrListMembership) String() string
func (GroupOrListMembership) Type ¶
func (g GroupOrListMembership) Type() PropParamType
type InlineEncoding ¶
type InlineEncoding EncodingFormat
func (InlineEncoding) ParameterName ¶
func (i InlineEncoding) ParameterName() string
func (InlineEncoding) String ¶
func (i InlineEncoding) String() string
func (InlineEncoding) Type ¶
func (i InlineEncoding) Type() PropParamType
type IntegerValue ¶
type IntegerValue int
func NewIntegerValue ¶
func NewIntegerValue(value string) (IntegerValue, error)
func (IntegerValue) String ¶
func (i IntegerValue) String() string
func (IntegerValue) Type ¶
func (i IntegerValue) Type() PropValueType
type Language ¶
type Language string
TODO (c.nicola): language (https://datatracker.ietf.org/doc/html/rfc5646)
func (Language) ParameterName ¶
func (Language) Type ¶
func (l Language) Type() PropParamType
type Param ¶
type Param struct { ParamName Name ValueList []ParamValue }
type ParamValue ¶
type ParamValue struct {
Text interface{} // ParamText or QuotedString
}
type ParticipationRole ¶
type ParticipationRole string
TODO (c.nicola): ParticipationRoleValue | XName | IANAToken.
func (ParticipationRole) ParameterName ¶
func (p ParticipationRole) ParameterName() string
func (ParticipationRole) String ¶
func (p ParticipationRole) String() string
func (ParticipationRole) Type ¶
func (p ParticipationRole) Type() PropParamType
type ParticipationRoleValue ¶
type ParticipationRoleValue string
const ( Chair ParticipationRoleValue = "CHAIR" ReqParticipant ParticipationRoleValue = "REQ-PARTICIPANT" OptParticipant ParticipationRoleValue = "OPT-PARTICIPANT" NonParticipant ParticipationRoleValue = "NON-PARTICIPANT" )
type ParticipationStatus ¶
type ParticipationStatus string
TODO: (c.nicola): partstat-event | partstat-todo | partstat-jour | XName | IANAToken.
func (ParticipationStatus) ParameterName ¶
func (p ParticipationStatus) ParameterName() string
func (ParticipationStatus) String ¶
func (p ParticipationStatus) String() string
func (ParticipationStatus) Type ¶
func (p ParticipationStatus) Type() PropParamType
type ParticipationStatusValue ¶
type ParticipationStatusValue string
const ( NeedsAction ParticipationStatusValue = "NEEDS-ACTION" Accepted ParticipationStatusValue = "ACCEPTED" Declined ParticipationStatusValue = "DECLINED" Tentative ParticipationStatusValue = "TENTATIVE" Delegated ParticipationStatusValue = "DELEGATED" Completed ParticipationStatusValue = "COMPLETED" InProcess ParticipationStatusValue = "IN-PROCESS" )
type PeriodOfTimeValue ¶
func NewPeriodOfTimeValue ¶
func NewPeriodOfTimeValue(value string) (PeriodOfTimeValue, error)
func (PeriodOfTimeValue) String ¶
func (p PeriodOfTimeValue) String() string
func (PeriodOfTimeValue) Type ¶
func (p PeriodOfTimeValue) Type() PropValueType
type PropParamType ¶
type PropParamType uint
const ( AlternateTextRepresentationType PropParamType = 1 << iota CommonNameType CalendarUserTypeType DelegatorType DelegateeType DirectoryEntryReferenceType InlineEncodingType FormatTypeType FreeBusyTimeTypeType LanguageType GroupOrListMembershipType ParticipationStatusType RecurrenceIdentifierRangeType AlarmTriggerRelationshipType RelationshipTypeType ParticipationRoleType RSVPExpectationType SentByType TimeZoneIdentifierType ValueDataTypeType XParamType )
func (PropParamType) Is ¶
func (p PropParamType) Is(paramType PropParamType) bool
type PropValueType ¶
type PropValueType uint
const ( BinaryType PropValueType = 1 << iota BooleanType CalendarUserAddressType DateType DateTimeType DurationType FloatType IntegerType PeriodOfTimeType RecurrenceRuleType TextType TimeType URIType UTFOffsetType )
func (PropValueType) Is ¶
func (p PropValueType) Is(valueType PropValueType) bool
type RSVPExpectation ¶
type RSVPExpectation RSVPExpectationValue
func (RSVPExpectation) ParameterName ¶
func (r RSVPExpectation) ParameterName() string
func (RSVPExpectation) String ¶
func (r RSVPExpectation) String() string
func (RSVPExpectation) Type ¶
func (r RSVPExpectation) Type() PropParamType
type RSVPExpectationValue ¶
type RSVPExpectationValue string
const ( True RSVPExpectationValue = "TRUE" False RSVPExpectationValue = "FALSE" )
type RecurrenceIdentifierRange ¶
type RecurrenceIdentifierRange RecurrenceIdentifierRangeValue
func (RecurrenceIdentifierRange) ParameterName ¶
func (r RecurrenceIdentifierRange) ParameterName() string
func (RecurrenceIdentifierRange) String ¶
func (r RecurrenceIdentifierRange) String() string
func (RecurrenceIdentifierRange) Type ¶
func (r RecurrenceIdentifierRange) Type() PropParamType
type RecurrenceIdentifierRangeValue ¶
type RecurrenceIdentifierRangeValue string
const ThisAndTheFuture RecurrenceIdentifierRangeValue = "THISANDTHEFUTURE"
type RecurrenceRuleFrequency ¶
type RecurrenceRuleFrequency uint
const ( Secondly RecurrenceRuleFrequency = 1 << iota Minutely Hourly Daily Weekly Monthly Yearly )
func (RecurrenceRuleFrequency) String ¶
func (r RecurrenceRuleFrequency) String() string
type RecurrenceRuleValue ¶
type RecurrenceRuleValue struct { Frequency RecurrenceRuleFrequency Until DateTimeValue Count int Interval int BySecond []int ByMinute []int ByHour []int ByDay []WeekDayNumber ByMonthDay []int ByYearDay []int ByWeekNum []int ByMonth []int BySetPos []int WeekDay WeekDay }
func NewRecurrenceRuleValue ¶
func NewRecurrenceRuleValue(value string) (RecurrenceRuleValue, error)
func (RecurrenceRuleValue) String ¶
func (r RecurrenceRuleValue) String() string
func (RecurrenceRuleValue) Type ¶
func (r RecurrenceRuleValue) Type() PropValueType
type RelationshipType ¶
type RelationshipType string
TODO (c.nicola): RelationshipTypeValue | XName | IANAToken.
func (RelationshipType) ParameterName ¶
func (r RelationshipType) ParameterName() string
func (RelationshipType) String ¶
func (r RelationshipType) String() string
func (RelationshipType) Type ¶
func (r RelationshipType) Type() PropParamType
type RelationshipTypeValue ¶
type RelationshipTypeValue string
const ( Parent RelationshipTypeValue = "PARENT" Child RelationshipTypeValue = "CHILD" Sibling RelationshipTypeValue = "SIBLING" )
type SentBy ¶
type SentBy string
TODO (c.nicola): DQUOTE cal-address DQUOTE (https://datatracker.ietf.org/doc/html/rfc5545#section-3.3.3)
func (SentBy) ParameterName ¶
func (SentBy) Type ¶
func (s SentBy) Type() PropParamType
type TextValue ¶
type TextValue string
func NewTextValue ¶
func (TextValue) Type ¶
func (t TextValue) Type() PropValueType
type TimeValue ¶
func NewTimeValue ¶
func (TimeValue) Type ¶
func (t TimeValue) Type() PropValueType
type TimeZoneIdentifier ¶
type TimeZoneIdentifier string
TODO (c.nicola): tzidprefix paramtext (time zone database entries) (https://www.iana.org/time-zones)
func (TimeZoneIdentifier) ParameterName ¶
func (t TimeZoneIdentifier) ParameterName() string
func (TimeZoneIdentifier) String ¶
func (t TimeZoneIdentifier) String() string
func (TimeZoneIdentifier) Type ¶
func (t TimeZoneIdentifier) Type() PropParamType
type Token ¶
func (Token) DebugString ¶
func (Token) LiteralSafe ¶
LiteralSafe returns a version of the stored literal that is safe for terminal output.
type UTCOffsetValue ¶
func NewUTCOffsetValue ¶
func NewUTCOffsetValue(value string) (UTCOffsetValue, error)
func (UTCOffsetValue) String ¶
func (u UTCOffsetValue) String() string
func (UTCOffsetValue) Type ¶
func (u UTCOffsetValue) Type() PropValueType
type ValueDataType ¶
type ValueDataType string
TODO (c.nicola): ValueDataTypeValue | XName | IANAToken.
func (ValueDataType) ParameterName ¶
func (v ValueDataType) ParameterName() string
func (ValueDataType) String ¶
func (v ValueDataType) String() string
func (ValueDataType) Type ¶
func (v ValueDataType) Type() PropParamType
type ValueDataTypeValue ¶
type ValueDataTypeValue string
const ( BinaryParam ValueDataTypeValue = "BINARY" BooleanParam ValueDataTypeValue = "BOOLEAN" CalAddressParam ValueDataTypeValue = "CAL-ADDRESS" DateParam ValueDataTypeValue = "DATE" DateTimeParam ValueDataTypeValue = "DATE-TIME" DurationParam ValueDataTypeValue = "DURATION" FloatParam ValueDataTypeValue = "FLOAT" IntegerParam ValueDataTypeValue = "INTEGER" PeriodParam ValueDataTypeValue = "PERIOD" RecurParam ValueDataTypeValue = "RECUR" TextParam ValueDataTypeValue = "TEXT" TimeParam ValueDataTypeValue = "TIME" URIParam ValueDataTypeValue = "URI" UTCOffsetParam ValueDataTypeValue = "UTF-OFFSET" )
type VendorID ¶
type VendorID struct { // NOTE (c.nicola): Not sure what the notation in the RFC is trying to tell me. // Can this Value be only 1-3 characters long? Cannot find any // examples for this. For the time being the length is unrestricted. Value string }
type WeekDayNumber ¶
func (WeekDayNumber) String ¶
func (w WeekDayNumber) String() string