<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: DeclarativeWebScript and public methods in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/declarativewebscript-and-public-methods/m-p/168656#M122101</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Yeah Rhino (the JS interpreter embedded in Alfresco) has pretty good Java integration, and although there might be some overhead in JS -&amp;gt; Java calls, it's probably pretty quick once the JVM has warmed up (I'm assuming a lot of the bridging code would get JITted before too long).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In terms of profiling, I'd probably profile the entire Web Script and then compare the use of Javascript idioms with calls through to Java.&amp;nbsp; Hopefully you'll find that the execution time is dominated by something else entirely (eg. network I/O).&amp;nbsp; :wink:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You've probably already seen this, but there's more documentation on this kind of thing at:&lt;/SPAN&gt;&lt;BR /&gt;&lt;UL&gt;&lt;LI&gt;&lt;A href="http://wiki.alfresco.com/wiki/JavaScript_API#Adding_Custom_Script_APIs" rel="nofollow noopener noreferrer"&gt;http://wiki.alfresco.com/wiki/JavaScript_API#Adding_Custom_Script_APIs&lt;/A&gt;&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;&lt;A href="http://wiki.alfresco.com/wiki/JavaScript_API#Native_Java_API_Access" rel="nofollow noopener noreferrer"&gt;http://wiki.alfresco.com/wiki/JavaScript_API#Native_Java_API_Access&lt;/A&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;SPAN&gt;Cheers,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Peter&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 13 Aug 2008 22:19:29 GMT</pubDate>
    <dc:creator>pmonks</dc:creator>
    <dc:date>2008-08-13T22:19:29Z</dc:date>
    <item>
      <title>DeclarativeWebScript and public methods</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/declarativewebscript-and-public-methods/m-p/168655#M122100</link>
      <description>Hey this is neat!&amp;nbsp;&amp;nbsp; Am I wastefully re-inventing something that is already possible in DeclarativeWebScript? I have some public&amp;nbsp; string manipulation methods in my DeclarativeWebScript subclass. I want to be able to call them from the javascript . AFAIK the methods are not exposed anywhere to the jav</description>
      <pubDate>Wed, 13 Aug 2008 19:51:47 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/declarativewebscript-and-public-methods/m-p/168655#M122100</guid>
      <dc:creator>alrice</dc:creator>
      <dc:date>2008-08-13T19:51:47Z</dc:date>
    </item>
    <item>
      <title>Re: DeclarativeWebScript and public methods</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/declarativewebscript-and-public-methods/m-p/168656#M122101</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Yeah Rhino (the JS interpreter embedded in Alfresco) has pretty good Java integration, and although there might be some overhead in JS -&amp;gt; Java calls, it's probably pretty quick once the JVM has warmed up (I'm assuming a lot of the bridging code would get JITted before too long).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In terms of profiling, I'd probably profile the entire Web Script and then compare the use of Javascript idioms with calls through to Java.&amp;nbsp; Hopefully you'll find that the execution time is dominated by something else entirely (eg. network I/O).&amp;nbsp; :wink:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You've probably already seen this, but there's more documentation on this kind of thing at:&lt;/SPAN&gt;&lt;BR /&gt;&lt;UL&gt;&lt;LI&gt;&lt;A href="http://wiki.alfresco.com/wiki/JavaScript_API#Adding_Custom_Script_APIs" rel="nofollow noopener noreferrer"&gt;http://wiki.alfresco.com/wiki/JavaScript_API#Adding_Custom_Script_APIs&lt;/A&gt;&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;&lt;A href="http://wiki.alfresco.com/wiki/JavaScript_API#Native_Java_API_Access" rel="nofollow noopener noreferrer"&gt;http://wiki.alfresco.com/wiki/JavaScript_API#Native_Java_API_Access&lt;/A&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;SPAN&gt;Cheers,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Peter&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 Aug 2008 22:19:29 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/declarativewebscript-and-public-methods/m-p/168656#M122101</guid>
      <dc:creator>pmonks</dc:creator>
      <dc:date>2008-08-13T22:19:29Z</dc:date>
    </item>
    <item>
      <title>Re: DeclarativeWebScript and public methods</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/declarativewebscript-and-public-methods/m-p/168657#M122102</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;OK thanks!&amp;nbsp; &lt;span class="lia-unicode-emoji" title=":smiling_face_with_sunglasses:"&gt;😎&lt;/span&gt;&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 Aug 2008 22:30:01 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/declarativewebscript-and-public-methods/m-p/168657#M122102</guid>
      <dc:creator>alrice</dc:creator>
      <dc:date>2008-08-13T22:30:01Z</dc:date>
    </item>
  </channel>
</rss>

