Author: ruwan
Date: Sun Oct 31 03:46:31 2010
New Revision: 1029239
URL: http://svn.apache.org/viewvc?rev=1029239&view=rev
Log:
adding the rewrite mediator schema
Added:
synapse/trunk/java/repository/schema/mediators/transformation/rewrite.xsd
Modified:
synapse/trunk/java/repository/schema/mediators/mediators.xsd
Modified: synapse/trunk/java/repository/schema/mediators/mediators.xsd
URL:
http://svn.apache.org/viewvc/synapse/trunk/java/repository/schema/mediators/mediators.xsd?rev=1029239&r1=1029238&r2=1029239&view=diff
==============================================================================
--- synapse/trunk/java/repository/schema/mediators/mediators.xsd (original)
+++ synapse/trunk/java/repository/schema/mediators/mediators.xsd Sun Oct 31
03:46:31 2010
@@ -37,6 +37,7 @@
<xs:include schemaLocation="transformation/fault.xsd"/>
<xs:include schemaLocation="transformation/xslt.xsd"/>
<xs:include schemaLocation="transformation/xquery.xsd"/>
+ <xs:include schemaLocation="transformation/rewrite.xsd"/>
<xs:include schemaLocation="advanced/rm_sequence.xsd"/>
<xs:include schemaLocation="advanced/db_mediators.xsd"/>
<xs:include schemaLocation="advanced/cache.xsd"/>
@@ -85,6 +86,7 @@
<xs:element ref="aggregate"/>
<xs:element ref="cache"/>
<xs:element ref="callout"/>
+ <xs:element ref="rewrite"/>
</xs:choice>
</xs:group>
Added: synapse/trunk/java/repository/schema/mediators/transformation/rewrite.xsd
URL:
http://svn.apache.org/viewvc/synapse/trunk/java/repository/schema/mediators/transformation/rewrite.xsd?rev=1029239&view=auto
==============================================================================
--- synapse/trunk/java/repository/schema/mediators/transformation/rewrite.xsd
(added)
+++ synapse/trunk/java/repository/schema/mediators/transformation/rewrite.xsd
Sun Oct 31 03:46:31 2010
@@ -0,0 +1,82 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified"
+ targetNamespace="http://synapse.apache.org/ns/2010/04/configuration"
+ xmlns="http://synapse.apache.org/ns/2010/04/configuration">
+
+ <xs:element name="rewrite">
+ <xs:annotation>
+ <xs:documentation source="description">
+ XQuery mediator to transform messages
+ </xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="rule" minOccurs="1" maxOccurs="unbounded">
+ <xs:complexType>
+ <xs:choice maxOccurs="unbounded">
+ <xs:element name="condition" minOccurs="0"
maxOccurs="1">
+ <xs:complexType>
+ <!-- TODO: evaluator definition -->
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="action" minOccurs="1"
maxOccurs="1">
+ <xs:complexType>
+ <xs:attribute name="value" use="optional"
type="xs:string"/>
+ <xs:attribute name="xpath" use="optional"
type="xs:string"/>
+ <xs:attribute name="regex" use="optional"
type="xs:string"/>
+ <xs:attribute name="type" use="optional">
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="set"/>
+ <xs:enumeration
value="append"/>
+ <xs:enumeration
value="prepend"/>
+ <xs:enumeration
value="replace"/>
+ <xs:enumeration
value="remove"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
+ <xs:attribute name="fragment"
use="optional">
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration
value="protocol"/>
+ <xs:enumeration value="user"/>
+ <xs:enumeration value="host"/>
+ <xs:enumeration value="port"/>
+ <xs:enumeration value="path"/>
+ <xs:enumeration value="query"/>
+ <xs:enumeration value="ref"/>
+ <xs:enumeration value="full"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ </xs:choice>
+ </xs:complexType>
+ </xs:element>
+ </xs:sequence>
+ <xs:attribute name="inProperty" use="optional" type="xs:string"/>
+ <xs:attribute name="outProperty" use="optional" type="xs:string"/>
+ </xs:complexType>
+ </xs:element>
+
+</xs:schema>
\ No newline at end of file