How can I get a Confluence PageManager object from outside of a page?

Brian Alston May 22, 2015

I am writing some back-end code for our confluence plug-in that requires PageManager and AttachmentManager objects (we are adding attachments to pages). My code does not live in a page, nor is it associated with a page. So, how can I go about getting these objects from outside of a page?

1 answer

1 accepted

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

Post a new question

0 votes
Answer accepted
Brian Alston May 22, 2015

I found the answer:

 

PageManager pageManager = (PageManager) ContainerManager.getComponent("pageManager");

 

I have no prior experience with Spring, so this was throwing me.

TAGS
AUG Leaders

Atlassian Community Events