Pergunta

I'm looking for a way to fetch a ChannelManager ref from within a Component#doBeforeRender call, in a somewhat similar way to the QueryManager.

Is there a *Manager registry I can ask for service interfaces?

Best, Edoardo

Foi útil?

Solução

go to ChannelManager and find usages of it. It will give you enough hits..like:

public static ChannelManager getChannelManager() {
    ComponentManager componentManager = HstServices.getComponentManager();
    if (componentManager == null) {
        return null;
    }

    return HstServices.getComponentManager().getComponent(ChannelManager.class.getName());

}

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top