Skip to content

Instantly share code, notes, and snippets.

View bhathiya's full-sized avatar

Bhathiya Jayasekara bhathiya

View GitHub Profile
<property name="xmlfile" expression="get-property('registry', 'gov:/xml/body.xml')" type="OM" />
<property name="regProperty" expression="get-property('registry', 'gov:/data/xml/collectionx@abc')"/>
<script language="js" description="Query Parameter Encoding Script">
mc.setProperty("ENCODED_PARAMS", encodeURIComponent(mc.getProperty('QUERY_PARAMS')));
</scrpt>
<script language="js" description="URL Encoding Script">
mc.setProperty("ENCODED_URL", encodeURI(mc.getProperty('URL_TO_BE_ENCODED')));
</scrpt>
<root>
<book>A Song of Ice and Fire</book>
<author>George R. R. Martin</author>
</root>
<property name="xmlFile" expression="get-property('registry','gov:/test.xml')" scope="default" type="OM"></property>
<log level="custom">
<property name="Book_Name" expression="$ctx:xmlFile//book"></property>
</log>
import ballerina/log;
import ballerina/http;
import ballerina/math;
import ballerina/system;
import ballerina/io;
import ballerina/mysql;
import ballerina/sql;
import ballerina/config;
const string UUID = "UUID";