Module: DeclMethod

Included in:
DefMethod, DefModule
Defined in:
ext/numo/narray/gen/erbpp2.rb

Instance Method Summary collapse

Instance Method Details

#def_alias(from, to) ⇒ Object



160
161
162
# File 'ext/numo/narray/gen/erbpp2.rb', line 160

def def_alias(from, to)
  DefAlias.new(self, from:from, to:to)
end

#def_alloc_func(m, erb_path = nil, **opts, &block) ⇒ Object



139
140
141
# File 'ext/numo/narray/gen/erbpp2.rb', line 139

def def_alloc_func(m, erb_path=nil, **opts, &block)
  DefAllocFunc.new(self, erb_path||m, name:m, singleton:true, **opts, &block)
end

#def_const(m, v, **opts, &block) ⇒ Object



163
164
165
# File 'ext/numo/narray/gen/erbpp2.rb', line 163

def def_const(m, v, **opts, &block)
  DefConst.new(self, name:m, value:v, **opts, &block)
end

#def_method(m, erb_path = nil, **opts, &block) ⇒ Object



145
146
147
# File 'ext/numo/narray/gen/erbpp2.rb', line 145

def def_method(m, erb_path=nil, **opts, &block)
  DefMethod.new(self, erb_path||m, name:m, **opts, &block)
end

#def_module_function(m, erb_path = nil, **opts, &block) ⇒ Object



157
158
159
# File 'ext/numo/narray/gen/erbpp2.rb', line 157

def def_module_function(m, erb_path=nil, **opts, &block)
  DefModuleFunction.new(self, erb_path||m, name:m, **opts, &block)
end

#def_singleton_method(m, erb_path = nil, **opts, &block) ⇒ Object



151
152
153
# File 'ext/numo/narray/gen/erbpp2.rb', line 151

def def_singleton_method(m, erb_path=nil, **opts, &block)
  DefMethod.new(self, erb_path||m, name:m, singleton:true, **opts, &block)
end

#undef_alloc_funcObject



142
143
144
# File 'ext/numo/narray/gen/erbpp2.rb', line 142

def undef_alloc_func
  UndefAllocFunc.new(self)
end

#undef_method(m) ⇒ Object



148
149
150
# File 'ext/numo/narray/gen/erbpp2.rb', line 148

def undef_method(m)
  UndefMethod.new(self,name:m)
end

#undef_singleton_method(m) ⇒ Object



154
155
156
# File 'ext/numo/narray/gen/erbpp2.rb', line 154

def undef_singleton_method(m)
  UndefSingletonMethod.new(self,name:m)
end