- Documentation
- Reference manual
- Packages
- A C++ interface to SWI-Prolog
- A C++ interface to SWI-Prolog
- Overview of accessing and changing values
- Converting PlTerm to native C and C++ types
- Unification
- Comparison
- Analysing compound terms
- Miscellaneous
- The class PlTerm_string
- The class PlCodeList
- The class PlCharList
- The class PlCompound
- The class PlFunctor
- The class PlTerm_tail
- The class PlTermv
- The class PlAtom - Supporting Prolog constants
- Classes for the recorded database: PlRecord and PlRecordExternalCopy
- Overview of accessing and changing values
- A C++ interface to SWI-Prolog
- A C++ interface to SWI-Prolog
1.11.10 The class PlFunctor
PlFunctor wraps functor_t, the internal
representation of a name/arity pair. A functor
name is a program object rather than arbitrarily encoded external data
and is therefore hard-wired to UTF-8, consistent with PlModule
and
PlPredicate (and the PL_predicate() CĀ API);
these constructors take no PlEncoding argument.
- PlFunctor :: PlFunctor(functor_t handle)
- Create from a C-interface functor handle (
functor_t). Used internally and for integration with the C-interface. - PlFunctor :: PlFunctor(const char *name, size_t arity)
- PlFunctor :: PlFunctor(const std::string& name, size_t arity)
- PlFunctor :: PlFunctor(const std::wstring& name, size_t arity)
- Create a functor from name and arity. The
char*andstd::stringname is interpreted as UTF-8. See PL_new_functor() and PL_new_atom_mbchars(). - PlFunctor :: PlFunctor(PlAtom name, size_t arity)
- Create a functor from an existing
PlAtomand arity. See PL_new_functor(). - bool is_null()
- bool not_null()
- Test whether the wrapped
functor_thandle is null.