Module: AssOle::Snippets::IsSnippet Private

Included in:
LikeOleRuntime
Defined in:
lib/ass_ole/snippets.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.

Defined Under Namespace

Modules: Argv, MethodMissing, WinPath

Instance Method Summary collapse

Instance Method Details

#extended(obj) ⇒ 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.



70
71
72
73
74
75
76
77
78
# File 'lib/ass_ole/snippets.rb', line 70

def extended(obj)
  return if obj == AssOle::Snippets::IsSnippet
  obj.send(:extend, MethodMissing) unless\
    obj.singleton_class.include? MethodMissing
  obj.send(:extend, Argv) unless\
    obj.singleton_class.include? Argv
  obj.send(:extend, WinPath) unless\
    obj.singleton_class.include? WinPath
end

#helper?(obj) ⇒ Boolean

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.

Returns:

  • (Boolean)


66
67
68
# File 'lib/ass_ole/snippets.rb', line 66

def helper?(obj)
  obj.class == Module
end

#included(obj) ⇒ 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.



59
60
61
62
63
64
# File 'lib/ass_ole/snippets.rb', line 59

def included(obj)
  return if helper?(obj)
  obj.send(:include, MethodMissing) unless obj.include? MethodMissing
  obj.send(:include, Argv) unless obj.include? Argv
  obj.send(:include, WinPath) unless obj.include? WinPath
end