Class: RemoteRuby::Plugin

Inherits:
Object
  • Object
show all
Defined in:
lib/remote_ruby/plugin.rb

Overview

Base class for Plugins to execution context to insert additonal code to the generated remote code.

Direct Known Subclasses

RailsPlugin

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Plugin

Returns a new instance of Plugin.



21
# File 'lib/remote_ruby/plugin.rb', line 21

def initialize(**args); end

Class Method Details

.build_plugins(args = {}) ⇒ Object



8
9
10
11
12
13
14
15
16
17
18
# File 'lib/remote_ruby/plugin.rb', line 8

def build_plugins(args = {})
  res = []

  RemoteRuby.plugins.each do |name, klass|
    options = args.delete(name)

    res << klass.new(**options) if options
  end

  res
end

Instance Method Details

#code_headerObject



23
# File 'lib/remote_ruby/plugin.rb', line 23

def code_header; end