Content::convert() for conv. betw. content models.
authordaniel <daniel.kinzler@wikimedia.de>
Mon, 5 Nov 2012 15:53:48 +0000 (16:53 +0100)
committerdaniel <daniel.kinzler@wikimedia.de>
Tue, 6 Nov 2012 16:39:10 +0000 (17:39 +0100)
commitea4473037d0cad16286b80bb6c5bafe06c4dafd8
tree77ef4faae710d17dc55cf070c640fd88fcb6e261
parentf5ff38bab0af0dbfe70733fead6ce7a6c23ae9c0
Content::convert() for conv. betw. content models.

This is needed to fix bug 41706 and similar, watch for follow-ups.

Automatic, implicit conversion may be handy in several cases, especially
for converting between different text based content models. E.g. it should
be possible to create a diff between a JavaScript and a wikitext page. This
change lais the foundations for this ability.

Change-Id: Ie7d87b67b24ac9897cb5696220a7785b228d3c79
docs/hooks.txt
includes/content/AbstractContent.php
includes/content/Content.php
includes/content/TextContent.php
tests/phpunit/includes/content/TextContentTest.php