Documentation that focuses on code itself, such as its function, correct use, expected output, relationship to other code as well as database and tables connections, and usage examples.
Questions tagged [code-documentation]
381 questions
0
votes
2 answers
Can't find documentation on a cool Angular feature for two-way binding
This is not a question on how to do Angular bindings. It's not about ngModel etc.
It's about a feature that I've just been educated on, seemingly working and quite nicely.
I've never heard of it and I can't confirm it in any documentation I've…

DonkeyBanana
- 3,266
- 4
- 26
- 65
0
votes
1 answer
PHP param type hinted with '?'
I was reading through some of the Zend framework's hydration source code and came across something I haven't encountered before:
public function hydrate(string $name, ?array $data = null) : string
I've never seen something type hinted like the…

Skytiger
- 1,745
- 4
- 26
- 53
0
votes
1 answer
custom filtering of methods in sphinx
I would like to add to my sphinx documentation a menu, "todo items", which should contain all the methods of my project containing some todo items, like this:
""":todo: Fonction à implémenter"""
I would like to display the name of the class, the…

lolveley
- 1,659
- 2
- 18
- 34
0
votes
1 answer
How to open files for built-in code in IntelliJ-Idea for Kotlin
As an example, if someone wants to see the all the members for the built-in class Array, how do I see the file in IntelliJ-IDEA Kotlin without going to Kotlin's Reference Documentation? Basically, how does someone open Array's source file?
I don't…

Jisip
- 415
- 3
- 14
0
votes
1 answer
Can I determine what errors a function will raise from typing?
Let's say I have the function:
def foo(integer: int) -> int:
if integer < 0:
raise ValueError("The integer must be positive")
return integer * 2
If I look at the signature for this function, it will only tell me that it takes an…

Pro Q
- 4,391
- 4
- 43
- 92
0
votes
0 answers
Swift documentary: Parameter displayed in extra box
Swift 5, Xcode 10.
Writing documentation for my code I came across a problem with @escaping that resulted in an extra box with "- No Description" in the documentation window (as described here).
So I changed this:
private func myFunc(something:…

Neph
- 1,823
- 2
- 31
- 69
0
votes
0 answers
Accessing Variant Elements by Index: What does the documentation tell me?
The following code works well on my computer:
#include
#include
#include
int main() {
std::variant var;
var = 20;
if (std::get_if<0>(&var))
std::cout << "a double\n";
else if…

fabian
- 1,413
- 1
- 13
- 24
0
votes
1 answer
Java documentation practice for overriding methods whose return type is subclass of overridden method's return type
I am writing Javadoc for a new package where I am facing the dilemma mentioned in the title.
I have base class method defined as,
class Vector {
..
public abstract Vector add(Vector v);
..
}
The overriding method is defined as,
class…

user1200373
- 181
- 6
0
votes
1 answer
How to find proper header file from documentation
Really basic question here -
How am I supposed to determine the proper header file from Embarcadero's (or other) documentation when I already know what component I want to use?
For example, I am writing some ADO code, so I am getting errors like…

Vic Fanberg
- 983
- 1
- 7
- 14
0
votes
1 answer
GhostDoc how to get attributes of a property?
I use the aforesaid documentation tool on Visual Studio 2017.
I can reach the GhostDoc Options > Rules > Property Template and customize the code. I have a property like;
[Display(Name="Text here")]
[Required]
public int CompanyId {get;set;}
I want…

sulhadin
- 521
- 4
- 16
0
votes
0 answers
Numbers in function parameters in documentation?
I've been trying to read up on some C libraries from die.net, and I'm a bit thrown off by numbers inside parameters, i.e:
See Also
alarm(2), nanosleep(2), signal(2), signal(7)
Referenced By
aio(7), clock_nanosleep(2), getitimer(2), perlfaq5(1),…

Funny Geeks
- 483
- 5
- 12
0
votes
0 answers
JSDoc: "Any" placeholder for similarly structured, nested objects
I am trying to document the following object:
let x = {
stopCP: {
enabled: false,
method: "POST",
body: "STOP"
},
startCP: {
enabled: false,
method: "POST",
body: "START"
},
…

Sv443
- 708
- 1
- 7
- 27
0
votes
1 answer
javascript function documentation newbie question
Newbie alert!!
When you require a module in your code such as below and you hover your mouse on a function your calling from that module you get a pop up with some documentation about the function ie parameters, returns and throws etc etc
const AWS…

Mark Lloyd
- 141
- 2
- 13
0
votes
1 answer
Is Apache Hadoop's build artifacts documented anywhere?
I have just started out with Apache Hadoop, as such, my first goal is basically to get a "hello world" app running. The first task is always to set up the development environment and be able to compile code. More specifically, I am trying to compile…

Martin Andersson
- 18,072
- 9
- 87
- 115
0
votes
1 answer
python3, in help(int) text, what is the Data descriptors described?
When you get the help string for int types using help(int). The very last part is:
| ----------------------------------------------------------------------
| Data descriptors defined here:
|
| denominator
| the denominator of a rational…

professor.jenkins
- 155
- 1
- 1
- 8