public function generateSchema(SchemaDescriptor $schema)
    {
        $response = new GeneratorResponse();

        foreach ($schema->getFields() as $field) {
            $this->updateFieldOptions($schema, $field);
        }

        if ($schema->isMixinSchema()) {
            $this->generateMixin($schema, $response);
            $this->generateMixinInterface($schema, $response);
            $this->generateMixinMajorInterface($schema, $response);
            $this->generateMixinTrait($schema, $response);
        } else {
            $this->generateMessage($schema, $response);
            $this->generateMessageInterface($schema, $response);
        }

        return $response;
    }