def serialize(self,writer: SerializationWriter) -> None:
        """
        Serializes information the current object
        param writer: Serialization writer to use to serialize this model
        Returns: None
        """
        if writer is None:
            raise TypeError("writer cannot be null.")
        writer.write_collection_of_primitive_values("assignCategories", self.assign_categories)
        writer.write_str_value("copyToFolder", self.copy_to_folder)
        writer.write_bool_value("delete", self.delete)
        writer.write_collection_of_object_values("forwardAsAttachmentTo", self.forward_as_attachment_to)
        writer.write_collection_of_object_values("forwardTo", self.forward_to)
        writer.write_bool_value("markAsRead", self.mark_as_read)
        writer.write_enum_value("markImportance", self.mark_importance)
        writer.write_str_value("moveToFolder", self.move_to_folder)
        writer.write_str_value("@odata.type", self.odata_type)
        writer.write_bool_value("permanentDelete", self.permanent_delete)
        writer.write_collection_of_object_values("redirectTo", self.redirect_to)
        writer.write_bool_value("stopProcessingRules", self.stop_processing_rules)
        writer.write_additional_data_value(self.additional_data)

        Serializes information the current object
        param writer: Serialization writer to use to serialize this model
        Returns: None
        
msgraph/generated/models/message_rule_actions.py