Davanum Srinivas wrote:
> Can i make minor edits? (say type->xsi:type)
>
this may not be as minor as it looks - AFAIU what Soumadeep has in SO is
distinction between Attributes and SynapseObject (similar to distinction
between attributes and elements in XML ) - if you use xsi:type this
distinction will no longer be possible to discover on XML level ... as
it seems that Atrributes in SynapseObject can only contain primitive
values i think it would be better to have them directly mapped to XML
attributes (easier to grasp for new users, smaller XML, and simpler) - i
will add it wiki as XML-N
BTW: i think mailing list is much better for discussion than wiki page
especially as it seems changes to synapse wiki pages are not reflected
to mailing list ...
best,
alek
ps. my modifications to wiki page:
Unfortunately those examples are too simplistic to be of practical value
and non of approaches work well to model more complex data.
However this gets more interesting if address is represented as
extensible data structure where street is not mixed with concept of
address and a person may have multiple addresses but still we attach
only one name to a contact (so attribute is very well fitting):
== XML-3 ==
{{{
<contacts>
<contact name="John">
<address>
<line1>360 Morse Ave</line1>
<city>Sunnyvale</city>
<state>US</state>
<zip>94086</zip>
</address>
</contact>
<contact name="Mary">
<address type="home">
<line1>410 Dale Park</line1>
<line1>Apt 10</line1>
<city>Sunnyvale</city>
<state>US</state>
<zip>94086</zip>
<address>
<address type="work">
<line1>222 Sunny Blvd</line1>
<city>Sunnyvale</city>
<state>US</state>
<zip>94086</zip>
<address>
</contact>
</contacts>
}}}
= Simplified XML (XML-N) =
It uses XML attributes for SynapseObject Attribute and simple convention
to represent type "{type}value" ex. "{int}10"
and it should be possible to write XML schema to validate such values if
there was ever need (break string
into type "{int}" and valudate rest against XML schemas xsd:int)
{{{
<ConsumerIdentification>
<consumer consumer-type="GOLD" ip-address-from="192.167.6.0"
ip-address-to="192.167.6.255"
http-auth-username="john" ws-sec-username="john"
>
<assignedService>stockQuote1</assignedService>
<assignedService>waterMeter</assignedService>
</consumer>
</ConsumerIdentification>
}}}
It is both short and can be validated. And cvan be automatically
processed to provide
functionality of SynapseObject API
>
> On 3/23/06, Soumadeep <[EMAIL PROTECTED]> wrote:
>
>> Sanjiva,
>>
>> The wiki page for SynapseObject is at
>> <http://wiki.apache.org/incubator/SynapseProposal/synapseobject>
>>
>> Thanks
>> Soumadeep
>> -----Original Message-----
>> From: Sanjiva Weerawarana [mailto:[EMAIL PROTECTED]
>> Sent: Wednesday, March 22, 2006 6:20 PM
>> To: [email protected]
>> Subject: RE: status of the Synapse Object discussions
>>
>> On Wed, 2006-03-22 at 17:50 +0530, Soumadeep wrote:
>>
>>> Vikas and I put together a page describing SO... will host it by EOD...
>>> hopefully..
>>>
>> If you guys can cover opposing positions / alternate suggestions too
>> that will definitely help me.
>>
>> Thanks,
>>
>> Sanjiva.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
>>
>
>
> --
> Davanum Srinivas : http://wso2.com/blogs/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>
--
The best way to predict the future is to invent it - Alan Kay
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]