Answered my own question, but posting for future reference (Method not defined or removed from search path)

11 views (last 30 days)
I have a class method calling a superclass method, ie,
getData@headerDirectory.SuperClassObject(sub_class_obj,rawData)
I have a getData method written for the superclass, yet when I called the getData method for the "subclass", I get the error "Method 'getData' is not defined for class 'headerDirectory.SuperClassObject' or is removed from MATLAB's search path.
I run
which -all getData
and get the path for both classes. I have another similar project where I do the same thing, so I could not figure out why this wasn't working.
I realized that in my superclass directory, I had +headerDirectory, but no @SuperClassObj folder. The methods and classdef file were free floating in the +headerDirectory.
I don't know if anyone else has accidentally done this, it took me embarassingly too long to figure it out.

Accepted Answer

Ryan
Ryan on 16 Oct 2014
Answer in post.

More Answers (0)

Categories

Find more on Software Development Tools in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!