class DBus::Data::Basic

A value that is not a {Container}.

Public Class Methods

basic?() click to toggle source
# File lib/dbus/data.rb, line 115
def self.basic?
  true
end
from_typed(value, type:) click to toggle source

@param value [::Object] @param type [Type] @return [Basic]

# File lib/dbus/data.rb, line 133
def self.from_typed(value, type:)
  assert_type_matches_class(type)
  new(value)
end
type() click to toggle source

@return [Type]

# File lib/dbus/data.rb, line 120
def self.type
  # memoize
  @type ||= Type.new(type_code).freeze
end

Public Instance Methods

type() click to toggle source
# File lib/dbus/data.rb, line 125
def type
  # The basic types can do this, unlike the containers
  self.class.type
end