We give a classification of the type D spacetimes based on the invariant
differential properties of the Weyl principal structure. Our classification is
established using tensorial invariants of the Weyl tensor and, consequently,
besides its intrinsic nature, it is valid for the whole set of the type D
metrics and it applies on both, vacuum and non-vacuum solutions. We consider
the Cotton-zero type D metrics and we study the classes that are compatible
with this condition. The subfamily of spacetimes with constant argument of the
Weyl eigenvalue is analyzed in more detail by offering a canonical expression
for the metric tensor and by giving a generalization of some results about the
non-existence of purely magnetic solutions. The usefulness of these results is
illustrated in characterizing and classifying a family of Einstein-Maxwell
solutions. Our approach permits us to give intrinsic and explicit conditions
that label every metric, obtaining in this way an operational algorithm to
detect them. In particular a characterization of the Reissner-Nordstr\"{o}m
metric is accomplished.Comment: 29 pages, 0 figure