Add structure methods to generator