.TH "doc_api_review_core_keyString_md" 3elektra "Mon Jan 9 2023" "Version 0.9.11" "Elektra" \" -*- nroff -*-
.ad l
.nh
.SH NAME
doc_api_review_core_keyString_md \- keyString 

.IP "\(bu" 2
start = 2021-02-26 16:05
.IP "\(bu" 2
end = 2021-02-26 16:40
.IP "\(bu" 2
moderator = Stefan Hanreich stefanhani@gmail.com
.IP "\(bu" 2
reviewer = Robert Sowula
.PP
.SH "Signature"
.PP
\fCconst char *keyString(const Key *key)\fP
.SH "Checklist"
.PP
.SS "Doxygen"
(bullet points are in order of appearance)
.PP
.IP "\(bu" 2
[ ] First line explains briefly what the function does 
.br
.IP "  \(bu" 4
[ ] Get the pointer to the string representing the Key's value\&.
.PP

.IP "\(bu" 2
[ ] Simple example or snippet how to use the function 
.br
.IP "  \(bu" 4
[ ] add example
.PP

.IP "\(bu" 2
[ ] Longer description of function containing common use cases 
.br
.IP "  \(bu" 4
[ ] add explanation about pointers 
.br

.IP "  \(bu" 4
[ ] add explanation about modifications from the user
.PP

.IP "\(bu" 2
[ ] Description of functions reads nicely 
.br
.IP "  \(bu" 4
[ ] \fC(null)\fP -> \fC'(null)'\fP 
.br

.IP "  \(bu" 4
[ ] \fC(binary)\fP -> \fC'(binary)'\fP
.PP

.IP "\(bu" 2
[ ] \fC@pre\fP 
.br
.IP "  \(bu" 4
[x] add?
.PP

.IP "\(bu" 2
[ ] \fC@post\fP 
.br
.IP "  \(bu" 4
[x] add?
.PP

.IP "\(bu" 2
[ ] \fC@invariant\fP 
.br
.IP "  \(bu" 4
[x] add?
.PP

.IP "\(bu" 2
[ ] \fC@param\fP for every parameter 
.br
.IP "  \(bu" 4
[ ] move before return 
.br

.IP "  \(bu" 4
[ ] key: key -> Key
.PP

.IP "\(bu" 2
[ ] \fC@return\fP / \fC@retval\fP 
.br
.IP "  \(bu" 4
[ ] pointer to the string representing the Key's value 
.br

.IP "  \(bu" 4
[ ] \fC(null)\fP -> \fC'(null)'\fP 
.br

.IP "  \(bu" 4
[ ] \fC(binary)\fP -> \fC'(binary)'\fP
.PP

.IP "\(bu" 2
[ ] \fC@since\fP 
.br
.IP "  \(bu" 4
[ ] add \fC1\&.0\&.0\fP
.PP

.IP "\(bu" 2
[x] \fC@ingroup\fP
.IP "\(bu" 2
[ ] \fC@see\fP 
.br
.IP "  \(bu" 4
[ ] \fC\fBkeyGetString()\fP\fP 
.br

.IP "  \(bu" 4
[ ] \fC\fBkeyGetBinary()\fP\fP 
.br

.IP "  \(bu" 4
[ ] \fC\fBkeyValue()\fP\fP
.PP

.PP
.SS "Naming"
.IP "\(bu" 2
Abbreviations used in function names must be defined in the \fBGlossary\fP
.IP "\(bu" 2
[x] Function names should neither be too long, nor too short
.IP "\(bu" 2
[ ] Function name should be clear and unambiguous 
.br
.IP "  \(bu" 4
[ ] \fC\fBkeyString()\fP\fP vs \fC\fBkeyGetString()\fP\fP
.PP

.IP "\(bu" 2
Abbreviations used in parameter names must be defined in the \fBGlossary\fP
.IP "\(bu" 2
[x] Parameter names should neither be too long, nor too short
.IP "\(bu" 2
[x] Parameter names should be clear and unambiguous
.PP
.SS "Compatibility"
(only in PRs)
.PP
.IP "\(bu" 2
\fBSymbol versioning\fP is correct for breaking changes
.IP "\(bu" 2
ABI/API changes are forward-compatible (breaking backwards-compatibility to add additional symbols is fine)
.PP
.SS "Parameter & Return Types"
.IP "\(bu" 2
Function parameters should use enum types instead of boolean types wherever sensible
.IP "\(bu" 2
[x] Wherever possible, function parameters should be \fCconst\fP
.IP "\(bu" 2
[x] Wherever possible, return types should be \fCconst\fP
.IP "\(bu" 2
[x] Functions should have the least amount of parameters feasible
.PP
.SS "Structural Clarity"
.IP "\(bu" 2
[ ] Functions should do exactly one thing 
.br
.IP "  \(bu" 4
[ ] Return Values (null) and (binary)
.PP

.IP "\(bu" 2
[x] Function name has the appropriate prefix
.IP "\(bu" 2
[ ] Order of signatures in kdb\&.h\&.in is the same as Doxygen 
.br
.IP "  \(bu" 4
[ ] swapped \fCwith \fBkeyGetValueSize()\fP\fP
.PP

.IP "\(bu" 2
[x] No functions with similar purpose exist
.PP
.SS "Memory Management"
.IP "\(bu" 2
[x] Memory Management should be handled by the function wherever possible
.PP
.SS "Extensibility"
.IP "\(bu" 2
[x] Function is easily extensible, e\&.g\&., with flags
.IP "\(bu" 2
[ ] Documentation does not impose limits, that would hinder further extensions 
.br
.IP "  \(bu" 4
'(null)' & '(binary)'
.PP

.PP
.SS "Tests"
.IP "\(bu" 2
[ ] Function code is fully covered by tests 
.br
.IP "  \(bu" 4
[x] Line 198 
.br

.IP "  \(bu" 4
[x] Line 203
.PP

.IP "\(bu" 2
All possible error states are covered by tests
.IP "\(bu" 2
All possible enum values are covered by tests
.IP "\(bu" 2
[x] No inconsistencies between tests and documentation
.PP
.SH "Summary"
.PP
Think about changing the return values for 1\&.0\&.0\&. It seems like a hard step, but also inevitable to do at some point\&. Now would probably be better than in the future\&.
.SH "Other Issues discovered (unrelated to function)"
.PP

