Class: Sigma::UnsignedInput

Inherits:
Object
  • Object
show all
Extended by:
FFI::Library
Defined in:
lib/sigma/input.rb

Overview

Unsigned inputs used in constructing unsigned transactions

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#pointerObject

Returns the value of attribute pointer.



196
197
198
# File 'lib/sigma/input.rb', line 196

def pointer
  @pointer
end

Class Method Details

.with_raw_pointer(pointer) ⇒ UnsignedInput

Note:

A user of sigma_rb generally does not need to call this function

Takes ownership of an existing UnsignedInput Pointer.

Parameters:

  • pointer (FFI::MemoryPointer)

Returns:



202
203
204
# File 'lib/sigma/input.rb', line 202

def self.with_raw_pointer(pointer)
  init(pointer)
end

Instance Method Details

#get_box_idBoxId

Get box id

Returns:



208
209
210
211
212
# File 'lib/sigma/input.rb', line 208

def get_box_id
  pointer = FFI::MemoryPointer.new(:pointer)
  ergo_lib_unsigned_input_box_id(self.pointer, pointer)
  Sigma::BoxId.with_raw_pointer(pointer)
end

#get_context_extensionContextExension

Get context extension

Returns:

  • (ContextExension)


216
217
218
219
220
# File 'lib/sigma/input.rb', line 216

def get_context_extension
  pointer = FFI::MemoryPointer.new(:pointer)
  ergo_lib_unsigned_input_context_extension(self.pointer, pointer)
  Sigma::ContextExtension.with_raw_pointer(pointer)
end