AEm supports PDF via some library and that library provides set of functionality. To edit PDF you need application which can understand format like to edit Video you need to have some app which understands video editing.
What do you mean by 'pdf code' that you've mentioned here. Do you mean that there's a concern coming because we deal with active content of pdf ? and that's why pdf editing is not allowed by aem?
You can explore AEM desktop app Adobe Experience Manager Desktop App via which yo ucan open PDF in their native applications on desktop, edit and save and changes would be updated in AEM.