Package ro.sync.ecss.extensions.api.link
Class LinkTextResolver
java.lang.Object
ro.sync.ecss.extensions.api.link.LinkTextResolver
- Direct Known Subclasses:
DitaLinkTextResolver
,DocbookLinkTextResolver
Resolves a link and obtains a text representation. This interface is used
when CSS function oxy_link-text() is encountered in the CSS on 'content' properties.
- Since:
- 14.2
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
activated
(AuthorAccess authorAccess) Signals that this resolver has entered in use.void
Any cache should be cleared in order to prepare for future evaluations.void
deactivated
(AuthorAccess authorAccess) Signals that this resolver has exit from use.void
refresh()
Signals a major refresh.void
Marks the references used by the given node as being invalid and requiring refreshing.resolveReference
(AuthorNode node) Gets a text representation for the reference.void
The given URLs have changed.
-
Constructor Details
-
LinkTextResolver
public LinkTextResolver()
-
-
Method Details
-
resolveReference
Gets a text representation for the reference. This text will be used inside author page next to the the link element.- Parameters:
node
- Author node.- Returns:
- The link text.
- Throws:
InvalidLinkException
- When it is not possible to resolve the link.
-
update
The given URLs have changed. Update the cache of references if any of the resolved links were loaded from one of these URL.- Parameters:
modifiedURLs
- The URLs that are modified.
-
refresh
public void refresh()Signals a major refresh. Any cache should be cleared in order to prepare for future evaluations. -
clearReferencesCache
public void clearReferencesCache()Any cache should be cleared in order to prepare for future evaluations. -
activated
Signals that this resolver has entered in use. All kinds of listeners can be added on this call (likeAuthorMouseListener
orAuthorListener
).- Parameters:
authorAccess
- TheAuthorAccess
of the Author page where the listener was activated.
-
deactivated
Signals that this resolver has exit from use. All listeners should be removed on this call.- Parameters:
authorAccess
- TheAuthorAccess
of the Author page where the listener was activated.
-
refreshNodeReferences
Marks the references used by the given node as being invalid and requiring refreshing. After performing an internal refresh the resolver must get an editor access usingAuthorAccess.getEditorAccess()
and callWSAuthorEditorPageBase.refresh(AuthorNode)
so that the editing area updates.- Parameters:
node
- The node to be refresh.
-