  Bordered Heegaard Floer homology is a three-manifold invariant which
associates to a surface F an algebra A(F) and to a three-manifold Y with
boundary identified with F a module over A(F). In this paper, we establish
naturality properties of this invariant. Changing the diffeomorphism between F
and the boundary of Y tensors the bordered invariant with a suitable bimodule
over A(F). These bimodules give an action of a suitably based mapping class
group on the category of modules over A(F). The Hochschild homology of such a
bimodule is identified with the knot Floer homology of the associated open book
decomposition. In the course of establishing these results, we also calculate
the homology of A(F). We also prove a duality theorem relating the two versions
of the 3-manifold invariant. Finally, in the case of a genus one surface, we
calculate the mapping class group action explicitly. This completes the
description of bordered Heegaard Floer homology for knot complements in terms
of the knot Floer homology.
