ABSTRACT

In the previous chapter, we introduced a member variable with unusual behavior. The behavior was unusual because the variable didn’t really behave like a variable. Instead, it seemed like View

was really a member function dressed up to look like a variable. In this chapter, we explore how dotreference member variable syntax might be used to call a member function. The first thing we need to investigate is operator conversion. We need to understand what happens to the arguments when MATLAB converts operator notation into a function call. We already have a good understanding of

substruct

, but we don’t really know the variable types supported. Armed with this knowledge we will be able to tear down the wall that currently exists between member variables and member functions. This will allow us to investigate another common object-oriented specialty class, the functor.