Added spec's to most of the code.

Signed-off-by: Lucas Arnström <lucasarnstrom@gmail.com>