Add StructuralContext class.

It will be used for reference resolution.
Add Reference class.
Remove copy constructor.
Some renamings