Switch to the visitor pattern for assembly.