Class: Babeltrace::CTF::Definition

Inherits:
Object
  • Object
show all
Defined in:
lib/babeltrace/ctf/events.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(definition) ⇒ Definition

Returns a new instance of Definition.



295
296
297
# File 'lib/babeltrace/ctf/events.rb', line 295

def initialize(definition)
  @definition = definition
end

Instance Attribute Details

#definitionObject (readonly)

Returns the value of attribute definition.



288
289
290
# File 'lib/babeltrace/ctf/events.rb', line 288

def definition
  @definition
end

Class Method Details

.create(d) ⇒ Object



290
291
292
293
# File 'lib/babeltrace/ctf/events.rb', line 290

def self.create(d)
  return nil if d.pointer.null?
  d.decl.def_class.new(d)
end

Instance Method Details

#declObject



303
304
305
# File 'lib/babeltrace/ctf/events.rb', line 303

def decl
  @definition.decl
end

#nameObject



299
300
301
# File 'lib/babeltrace/ctf/events.rb', line 299

def name
  @definition.name
end