Sha256: 3096ceb274cfc298bb278d621161842f4c7af51f5ec93be994cdae16cd6af07c
Contents?: true
Size: 328 Bytes
Versions: 11
Compression:
Stored size: 328 Bytes
Contents
module XDR::Int extend XDR::Concerns::ConvertsToXDR extend XDR::Concerns::IntegerConverter def self.write(val, io) raise XDR::WriteError, "val is not Integer" unless val.is_a?(Integer) # TODO: check bounds io.write [val].pack("l>") end def self.read(io) read_bytes(io, 4).unpack("l>").first end end
Version data entries
11 entries across 11 versions & 2 rubygems