method-combination-utilities

API Reference

method-combination-utilities

Various method combinations and utilities to make it easy to create new method combinations.

METHOD-COMBINATION-UTILITIES

  • Function CALL-METHODS (methods)
    It's rare to see a method combination that doesn't define this method, so might as well pull it into this utilities package. CALL-METHODS returns a list of CALL-METHOD forms; one for each method in METHODS
  • Function WRAP-PRIMARY-FORM (primary-form &optional around-methods before-methods after-methods)
    This is similar to COMBINE-STANDARD-METHODS, but it takes an already- generated primary form rather than a list of primary methods. This is because it is fairly common for a method combination to deal with primary methods in some specialized way, then combine them with normal :AROUND/:BEFORE/:AFTER methods. See the BASIC and APPEND/NCONC combinations in this package for examples.
  • Function COMBINE-STANDARD-METHODS (primary-methods &optional around-methods before-methods after-methods)
    It is fairly common practice to take the STANDARD method combination and wrap it with additional qualified methods. This encapsulates the standard behavior as much as possible to make wrapping simpler. Each argument should be a list of methods to be handled the way the corresponding methods are in the STANDARD method combination. It assumes all the lists are ordered properly already. See the LAX method combination in this package for an example.
  • Macro METHOD-COMBINATION-EXPAND (form)
    Given a function call form, this returns the method-combination form that would be generated in the process of satisfying that call. This is only expected to work for functions whose method-combination was created using the long form of DEFINE-METHOD-COMBINATION.