Module: AssOle::AppExtension::Plug Private

Defined in:
lib/ass_ole/app_extension.rb

This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#info_baseObject (readonly)

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



439
440
441
# File 'lib/ass_ole/app_extension.rb', line 439

def info_base
  @info_base
end

Class Method Details

.external_runtime_getObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



469
470
471
472
473
# File 'lib/ass_ole/app_extension.rb', line 469

def self.external_runtime_get
  Module.new do
    is_ole_runtime :external
  end
end

.new(info_base) {|inst| ... } ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Parameters:

  • info_base (AssMaintainer::InfoBase)

    instance

Yields:

  • (inst)


476
477
478
479
480
481
482
483
# File 'lib/ass_ole/app_extension.rb', line 476

def self.new(info_base)
  inst = Class.new do
    like_ole_runtime Plug.external_runtime_get
    include Plug
  end.new(info_base)
  yield inst if block_given?
  inst
end

Instance Method Details

#exec(ext_klass, safe_mode) ⇒ ext_klass

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Make new ext_klass plugged instance

Parameters:

  • safe_mode (true false nil String)

    define of safe mode for an extension. For more info see 1C docomentation for SafeMode property of ConfigurationExtension object

  • ext_klass (Class)

Returns:

  • (ext_klass)

    instance



453
454
455
# File 'lib/ass_ole/app_extension.rb', line 453

def exec(ext_klass, safe_mode)
  new_ext(ext_klass, safe_mode).plug
end

#initialize(info_base) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Parameters:

  • info_base (AssMaintainer::InfoBase)

    instance



443
444
445
446
# File 'lib/ass_ole/app_extension.rb', line 443

def initialize(info_base)
  @info_base = info_base
  ole_runtime_get.run info_base
end

#new_ext(ext_klass, safe_mode) ⇒ ext_klass

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Make new ext_klass instance

Parameters:

  • ext_klass (Class)
  • safe_mode (true false nil String)

    define of safe mode for an extension. For more info see 1C docomentation for SafeMode property of ConfigurationExtension object

Returns:

  • (ext_klass)

    instance



464
465
466
# File 'lib/ass_ole/app_extension.rb', line 464

def new_ext(ext_klass, safe_mode)
  ext_klass.new(self, safe_mode)
end