User Tools


Differences

This shows you the differences between two versions of the page.

Link to this comparison view

cl:functions:function-keywords [2019/06/15 02:00]
cl:functions:function-keywords [2019/06/18 10:00] (current)
Line 1: Line 1:
 +====== Standard Generic Function FUNCTION-KEYWORDS ======
 +
 +====Syntax====
 +  * **function-keywords** //method// → //keys, allow-other-keys-p//​
 +
 +====Method Signatures====
 +  * **function-keywords** (//method// **[[CL:​Types:​standard-method]]**)
 +
 +====Arguments and Values====
 +  * //method// - a //​[[CL:​Glossary:​method]]//​.
 +  * //keys// - a //​[[CL:​Glossary:​list]]//​.
 +  * //​allow-other-keys-p//​ - a //​[[CL:​Glossary:​generalized boolean]]//​.
 +
 +====Description====
 +Returns the keyword parameter specifiers for a //method//.
 +
 +Two values are returned: a //​[[CL:​Glossary:​list]]//​ of the explicitly named keywords and a //​[[CL:​Glossary:​generalized boolean]]// that states whether **''&​allow-other-keys''​** had been specified in the //method// definition.
 +
 +====Examples====
 +<​blockquote> ​
 +([[CL:​Macros:​defmethod]] gf1 ((a [[CL:​Types:​integer]]) &​optional (b 2) 
 +                            &key (c 3) ((:dee d) 4) e ((eff f))) 
 +  ([[CL:​Functions:​list]] a b c d e f)) <​r>#<​STANDARD-METHOD GF1 ([[CL:​Types:​INTEGER]]) 36324653>​ </r>
 +([[CL:​Functions:​find-method]] #'gf1 '() ([[CL:​Functions:​list]] ([[CL:​Functions:​find-class]] '​[[CL:​Types:​integer]]))) <​r>#<​STANDARD-METHOD GF1 ([[CL:​Types:​INTEGER]]) 36324653>​ </r>
 +(function-keywords [[CL:​Variables:​repl-star|*]]) <​r>​(:​C :DEE :E EFF)
 +//​[[CL:​Glossary:​false]]//</​r>​
 +
 +([[CL:​Macros:​defmethod]] gf2 ((a [[CL:​Types:​integer]])) ​
 +  ([[CL:​Functions:​list]] a b c d e f)) <​r>#<​STANDARD-METHOD GF2 ([[CL:​Types:​INTEGER]]) 42701775>​ </r>
 +(function-keywords ([[CL:​Functions:​find-method]] #'gf1 '() ([[CL:​Functions:​list]] ([[CL:​Functions:​find-class]] '​[[CL:​Types:​integer]])))) <r>()
 +//​[[CL:​Glossary:​false]]//​ </r>
 +
 +([[CL:​Macros:​defmethod]] gf3 ((a [[CL:​Types:​integer]]) &key b c d &​allow-other-keys) ​
 +  ([[CL:​Functions:​list]] a b c d e f)) <​r>#<​STANDARD-METHOD GF3 ([[CL:​Types:​INTEGER]]) 50814231>​ </r>
 +(function-keywords [[CL:​Variables:​repl-star|*]]) <​r>​(:​B :C :D)
 +//​[[CL:​Glossary:​true]]//</​r>​
 +</​blockquote>​
 +
 +====Affected By====
 +**[[CL:​Macros:​defmethod]]**
 +
 +====Exceptional Situations====
 +None.
 +
 +====See Also====
 +  * **[[CL:​Macros:​defmethod|Macro DEFMETHOD]]**
 +
 +====Notes====
 +None.