Changes for page Scripting

Last modified by Simpel on 2023/02/14

<
From version < 22.1 >
edited by Caleb James DeLisle
on 2010/03/03
To version < 22.2 >
edited by Caleb James DeLisle
on 2010/03/03
>
Change comment: Explained difference between Context and XWikiContext better, removed a misplaced comma.

Summary

Details

Page properties
Content
... ... @@ -35,7 +35,7 @@
35 35  
36 36  == XWiki Core Access ==
37 37  
38 -Sometimes the XWiki Api doesn't provide the methods which you need for your application. you can gain raw access the core of XWiki but it presents an increased security risk, and requires programming rights to run. Using the core should be avoided if at all possible.
38 +Sometimes the XWiki Api doesn't provide the methods which you need for your application. you can gain raw access the core of XWiki but it presents an increased security risk and requires programming rights to run. Using the core should be avoided if at all possible.
39 39  {{code language=java}}
40 40  {{groovy}}
41 41  def xc = xcontext.getContext();
... ... @@ -48,7 +48,8 @@
48 48  * [[The underlying XWiki object which backs the **##xwiki##** object>>http://maven.xwiki.org/site/xwiki-core-parent/xwiki-core/apidocs/com/xpn/xwiki/XWiki.html]]: **##wiki##**
49 49  * [[The underlying XWikiDocument behind the current Document>>http://maven.xwiki.org/site/xwiki-core-parent/xwiki-core/apidocs/com/xpn/xwiki/doc/XWikiDocument.html]]: **##xdoc##**
50 50  
51 -You will find that many of the methods in **##wiki##** and **##xdoc##** require an instance of the XWikiContext, this is **##xc##** not **##xcontext##**.
51 +You will find that many of the methods in **##wiki##** and **##xdoc##** require an instance of the XWikiContext, this is the underlying xcontext **##xc##** not the Api context **##xcontext##**.
52 +
52 52  Again, these methods are only for the rare cases when functionality is not provided by the public Api. We put a lot of effort into preserving the behavior of the public Api and much less into preserving the behavior of core methods so you may find that core methods are deprecated, removed, or their behavior is changed in subsequent versions.
53 53  
54 54  {{id name=velocity /}}

Get Connected