Required more explanation for isReleaseSupported() Method
Author: sivaprasad9394
Publication Date: 9/22/2020 5:44
Hello Team,
I would like to understand more on this method, For me documentation is not enough.
--- Indicates wether this element supports release(boolean) or not.
de.espirit.firstspirit.access.store.IDProvider
If some has some more information please share me.
for (ReferenceEntry entry : page.getIncomingReferences()) {
if (entry.getType() == ReferenceEntry.SITE_STORE_REFERENCE && entry.getReferencedElement() instanceof PageRef) {
PageRef pageRef = (PageRef) entry.getReferencedElement();
if (pageRef.getStore().isReleaseSupported()){
....
........
...........
}
}
}
In the above code pageRef.getStore().isReleaseSupported() when will this condition become true? For me it always returns false in the code implementation.
But in Bean-shell test for pageRef it shows true.

More about current store and release store information required.
Thank you,
Regards,
Siva
Tags: idprovider, isreleasesupported, pageref, store
-
Author: StefanSchulz - 9/22/2020 10:35
Hi Siva,
The logic behind isReleaseSupported is not that complex: It is true if
- the element, the method is invoked upon, is in the current store (i.e., the store represents the working state not the released state)
- the store related to the element does actually support current and release states, which is the case for page store, site store, media store and global store but not content store and template store.
Hope this helps.
Best wishes
Stefan
0
Please sign in to leave a comment.
Comments
1 comment