Class: ICU::Calendar::Library::VersionInfo
- Inherits:
-
FFI::MemoryPointer
- Object
- FFI::MemoryPointer
- ICU::Calendar::Library::VersionInfo
- Extended by:
- FFI::DataConverter
- Defined in:
- lib/icu/calendar/library/version_info.rb
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize ⇒ VersionInfo
constructor
A new instance of VersionInfo.
- #to_a ⇒ Object
- #to_s ⇒ Object
Constructor Details
#initialize ⇒ VersionInfo
Returns a new instance of VersionInfo.
10 11 12 |
# File 'lib/icu/calendar/library/version_info.rb', line 10 def initialize super(:uint8, U_MAX_VERSION_LENGTH) end |
Class Method Details
.native_type ⇒ Object
6 7 8 |
# File 'lib/icu/calendar/library/version_info.rb', line 6 def self.native_type FFI::Type::POINTER end |
Instance Method Details
#to_a ⇒ Object
14 15 16 |
# File 'lib/icu/calendar/library/version_info.rb', line 14 def to_a read_array_of_uint8(U_MAX_VERSION_LENGTH) end |
#to_s ⇒ Object
18 19 20 21 22 23 |
# File 'lib/icu/calendar/library/version_info.rb', line 18 def to_s FFI::MemoryPointer.new(:char, U_MAX_VERSION_STRING_LENGTH) do |buffer| Library.u_versionToString(self, buffer) return buffer.read_string_to_null end end |