Class: Icalendar::Values::Binary

Inherits:
Icalendar::Value show all
Defined in:
lib/icalendar/values/binary.rb

Instance Attribute Summary

Attributes inherited from Icalendar::Value

#ical_params

Instance Method Summary collapse

Methods inherited from Icalendar::Value

#ical_param, #initialize, #to_ical, #value, value_type, #value_type

Constructor Details

This class inherits a constructor from Icalendar::Value

Instance Method Details

#params_icalObject


8
9
10
11
12
# File 'lib/icalendar/values/binary.rb', line 8

def params_ical
  ical_param :value, 'BINARY'
  ical_param :encoding, 'BASE64'
  super
end

#value_icalObject


14
15
16
17
18
19
20
# File 'lib/icalendar/values/binary.rb', line 14

def value_ical
  if base64?
    value
  else
    Base64.strict_encode64 value
  end
end