Class: OpenCV::Cv::Ptr::Cv_Ml_DTrees
- Inherits:
-
Object
- Object
- OpenCV::Cv::Ptr::Cv_Ml_DTrees
- Extended by:
- FFI::DataConverter
- Defined in:
- lib/ropencv/ropencv_types.rb
Specializing collapse
Class Method Summary collapse
- .new(*args) ⇒ Object
-
.null ⇒ Object
returns a null pointer to the object.
Instance Method Summary collapse
- #empty ⇒ Bool
- #get ⇒ Cv::Ml::DTrees
-
#release ⇒ Void
methods.
- #reset(p) ⇒ Void
- #swap(other) ⇒ Void
-
#to_s ⇒ Object
converts Ptr::Cv_Ml_DTrees into a string by crawling through all its attributes.
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(m, *args) ⇒ Object
54436 54437 54438 54439 |
# File 'lib/ropencv/ropencv_types.rb', line 54436 def method_missing(m,*args) raise "Ptr cv::Ptr is empty. Cannot call #{m} on it!" if empty get.method(m).call(*args) end |
Class Method Details
.ptr ⇒ Object .ptr ⇒ Object .ptr ⇒ Object .ptr ⇒ Object .ptr ⇒ Object
54240 54241 54242 54243 54244 54245 54246 54247 54248 54249 54250 54251 54252 54253 54254 54255 54256 54257 54258 54259 54260 54261 54262 54263 54264 54265 54266 54267 54268 54269 54270 54271 54272 54273 54274 54275 54276 54277 54278 54279 54280 54281 54282 54283 54284 54285 54286 54287 54288 54289 54290 54291 54292 54293 54294 54295 54296 54297 54298 54299 54300 54301 54302 54303 54304 54305 54306 54307 54308 54309 54310 54311 54312 54313 54314 54315 54316 |
# File 'lib/ropencv/ropencv_types.rb', line 54240 def self.new(*args) if args.first.is_a?(FFI::Pointer) || args.first.is_a?(Ptr::Cv_Ml_DTreesStruct) raise ArgumentError, "too many arguments for creating #{self.name} from Pointer" unless args.size == 1 return super(args.first) end # overloaded method wrapper for cv::Ptr<cv::ml::DTrees>::Ptr<cv::ml::DTrees>() @@cv_ptr_cv_ml_d_trees_ptr_cv_ml_d_trees_defaults0 ||= [] if(args.size >= 0 && args.size <= 0) targs = args.clone targs.size.upto(-1) do |i| targs[i] = @@cv_ptr_cv_ml_d_trees_ptr_cv_ml_d_trees_defaults0[i] end begin return Rbind::cv_ptr_cv_ml_d_trees_ptr_cv_ml_d_trees(*targs) rescue TypeError => e @error = e end end # overloaded method wrapper for cv::Ptr<cv::ml::DTrees>::Ptr<cv::ml::DTrees>(cv::Ptr<cv::ml::DTrees> other) @@cv_ptr_cv_ml_d_trees_ptr_cv_ml_d_trees__2_defaults1 ||= [nil] if(args.size >= 1 && args.size <= 1) targs = args.clone targs.size.upto(0) do |i| targs[i] = @@cv_ptr_cv_ml_d_trees_ptr_cv_ml_d_trees__2_defaults1[i] end begin return Rbind::cv_ptr_cv_ml_d_trees_ptr_cv_ml_d_trees__2(*targs) rescue TypeError => e @error = e end end # overloaded method wrapper for cv::Ptr<cv::ml::DTrees>::Ptr<cv::ml::DTrees>(cv::Ptr<cv::ml::DTrees> owner, cv::ml::DTrees* p) @@cv_ptr_cv_ml_d_trees_ptr_cv_ml_d_trees__3_defaults2 ||= [nil, nil] if(args.size >= 2 && args.size <= 2) targs = args.clone targs.size.upto(1) do |i| targs[i] = @@cv_ptr_cv_ml_d_trees_ptr_cv_ml_d_trees__3_defaults2[i] end begin return Rbind::cv_ptr_cv_ml_d_trees_ptr_cv_ml_d_trees__3(*targs) rescue TypeError => e @error = e end end # overloaded method wrapper for cv::Ptr<cv::ml::DTrees>::Ptr<cv::ml::DTrees>(cv::ml::DTrees* p) @@cv_ptr_cv_ml_d_trees_ptr_cv_ml_d_trees__4_defaults3 ||= [nil] if(args.size >= 1 && args.size <= 1) targs = args.clone targs.size.upto(0) do |i| targs[i] = @@cv_ptr_cv_ml_d_trees_ptr_cv_ml_d_trees__4_defaults3[i] end begin return Rbind::cv_ptr_cv_ml_d_trees_ptr_cv_ml_d_trees__4(*targs) rescue TypeError => e @error = e end end # overloaded method wrapper for cv::Ptr<cv::ml::DTrees>::Ptr<cv::ml::DTrees>(cv::Ptr<cv::ml::StatModel> owner, cv::ml::DTrees* p) @@cv_ptr_cv_ml_d_trees_ptr_cv_ml_d_trees__5_defaults4 ||= [nil, nil] if(args.size >= 2 && args.size <= 2) targs = args.clone targs.size.upto(1) do |i| targs[i] = @@cv_ptr_cv_ml_d_trees_ptr_cv_ml_d_trees__5_defaults4[i] end begin return Rbind::cv_ptr_cv_ml_d_trees_ptr_cv_ml_d_trees__5(*targs) rescue TypeError => e @error = e end end raise ArgumentError, "no constructor for #{self}(#{args.inspect})" end |
.null ⇒ Object
returns a null pointer to the object
54221 54222 54223 |
# File 'lib/ropencv/ropencv_types.rb', line 54221 def self.null new(Ptr::Cv_Ml_DTreesStruct.new) end |
Instance Method Details
#empty ⇒ Bool
Note:
method wrapper for bool cv::Ptrcv::ml::DTrees::empty()
54428 54429 54430 54431 |
# File 'lib/ropencv/ropencv_types.rb', line 54428 def empty() __validate_pointer__ Rbind::cv_ptr_cv_ml_d_trees_empty( self) end |
#get ⇒ Cv::Ml::DTrees
Note:
method wrapper for cv::ml::DTrees* cv::Ptrcv::ml::DTrees::get()
54416 54417 54418 54419 54420 54421 54422 54423 54424 |
# File 'lib/ropencv/ropencv_types.rb', line 54416 def get() __validate_pointer__ result = Rbind::cv_ptr_cv_ml_d_trees_get( self) if result.respond_to?(:__owner__?) && !result.__owner__? # store owner insight the pointer to not get garbage collected result.instance_variable_get(:@__obj_ptr__).instance_variable_set(:@__owner__,self) end result end |
#release ⇒ Void
Note:
method wrapper for void cv::Ptrcv::ml::DTrees::release()
methods
54393 54394 54395 54396 |
# File 'lib/ropencv/ropencv_types.rb', line 54393 def release() __validate_pointer__ Rbind::cv_ptr_cv_ml_d_trees_release( self) end |
#reset(p) ⇒ Void
Note:
method wrapper for void cv::Ptrcv::ml::DTrees::reset(cv::ml::DTrees* p)
54401 54402 54403 54404 |
# File 'lib/ropencv/ropencv_types.rb', line 54401 def reset(p) __validate_pointer__ Rbind::cv_ptr_cv_ml_d_trees_reset( self, p) end |
#swap(other) ⇒ Void
Note:
method wrapper for void cv::Ptrcv::ml::DTrees::swap(cv::Ptrcv::ml::DTrees other)
54409 54410 54411 54412 |
# File 'lib/ropencv/ropencv_types.rb', line 54409 def swap(other) __validate_pointer__ Rbind::cv_ptr_cv_ml_d_trees_swap( self, other) end |
#to_s ⇒ Object
converts Ptr::Cv_Ml_DTrees into a string by crawling through all its attributes
54382 54383 54384 |
# File 'lib/ropencv/ropencv_types.rb', line 54382 def to_s "#<cv::Ptr<cv::ml::DTrees> >" end |