Can IDocumentationProvider::homePage be non-const?

Milian Wolff mail at milianw.de
Mon Nov 30 17:32:43 UTC 2009


On Monday, 30. November 2009 17:49:01 Aleix Pol wrote:
> I guess it's fine. Can you change it? That way we can iterate from that.
> You should use the home page to help the user navigate inside the provider,
> not for other purposes like configuration. That would make navigation
> disappointing.

See other mail, I'll stick to casting for now. And I don't want to use it for 
configuration, just want to display the index page of PHP documentation. The 
thing is that I pass the provider as parent, because the IDocumentation can 
add something to the history and has to access the provider for that.

> On Mon, Nov 30, 2009 at 5:14 PM, Milian Wolff <mail at milianw.de> wrote:
> > Hey all, esp. Apol:
> >
> > Can I remove the "const" from IDocumentationProvider::homePage() ? Thing
> > is,
> > that I want to pass "this" as parent/provider to the returned
> > IDocumentation.
> > This fails, since this is const, but it should be non-const.
> >
> > I'd rather not do some const-casting or similar, but instead just remove
> > the
> > "const". Esp. considering that the IDocumentation returned by homePage
> > has the
> > ability to modify the IDocumenationProvider (adding history, etc. pp.).

-- 
Milian Wolff
mail at milianw.de
http://milianw.de




More information about the KDevelop-devel mailing list