Use these MATLAB® functions to view information about the members of an interface:
doc — View classes and functions in a
package. When you publish an interface, you can add descriptive text. For more
information, see Publish Help Text for MATLAB Interface to C++ Library.
methods — View constructor, method,
and package function names for a class.
'-full' option — View
constructor, method, and package function signatures.
methodsview — Table representation of
method signatures. You might find the
methodsview window easier to
use as a reference guide because you do not need to scroll through the Command Window to
If you created the
school interface in the example Publish Interface to Header-Only C++ Library, then you can use it
in this example. With the
schoolInterface.dll file in the current folder,
Display the classes and package functions.
then press Tab. This command loads the package. MATLAB displays a list of members. To view the package, press the Backspace key to remove the period, then press Enter. MATLAB displays:
Classes contained in clib.school: Person - clib.school.Person Representation of C++ class Person Teacher - clib.school.Teacher Representation of C++ class Teacher Student - clib.school.Student Representation of C++ class Student Functions contained in clib.school: getName - clib.school.getName Representation of C++ function getName
To display the inputs and outputs for the
getName package function,
clib.school.getName Representation of C++ function getName inputs p clib.school.Person outputs RetVal string
To display class methods, call the
methods function for each class. For example, type:
Methods for class clib.school.Person: Person eq ge getAge getName gt le lt ne setAge setName Methods of clib.school.Person inherited from handle.
To display function signatures, call the
methodsview function for each class. For example, type:
The function opens a window that displays the methods and information about arguments and returned values. For example, the signatures for the constructors are: