class DeviceInfo

Overview

A wrapper around a LibPortMIDI::DeviceInfo struct. Consider instances to be snapshots, because their instance variables do not change over time. For example, the value of #opened? will not change when the corresponding device is opened.

To get a fresh instance call PortMIDI#get_device_info.

Defined in:

port_midi/device_info.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(di : LibPortMIDI::DeviceInfo) #

[View source]

Instance Method Detail

def input? : Bool #

Returns true if this is an input device.


[View source]
def interface : String #

[View source]
def name : String #

[View source]
def opened? : Bool #

Returns true if this device is opened. As noted in the class comment, this is a snapshot: the value will not change when the device is opened or closed.


[View source]
def output? : Bool #

Returns true if this is an output device.


[View source]
def version : Int32 #

[View source]