From 578748065556f359feab4068317d736aaa60483c Mon Sep 17 00:00:00 2001 From: Dr Scofield Date: Wed, 24 Sep 2008 12:04:58 +0000 Subject: From: alan webb (alan_webb@us.ibm.com) cleanups. --- .../Rest/Inventory/RestAppearanceServices.cs | 120 ++++++++++----------- 1 file changed, 60 insertions(+), 60 deletions(-) (limited to 'OpenSim/ApplicationPlugins') diff --git a/OpenSim/ApplicationPlugins/Rest/Inventory/RestAppearanceServices.cs b/OpenSim/ApplicationPlugins/Rest/Inventory/RestAppearanceServices.cs index c375ade..4a44321 100644 --- a/OpenSim/ApplicationPlugins/Rest/Inventory/RestAppearanceServices.cs +++ b/OpenSim/ApplicationPlugins/Rest/Inventory/RestAppearanceServices.cs @@ -721,18 +721,19 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory private void FormatPart(AppearanceRequestData rdata, string part, UUID item, UUID asset) { - if(item != UUID.Zero || asset != UUID.Zero) + if (item != UUID.Zero || asset != UUID.Zero) { - rdata.writer.WriteStartElement(part); - if(item != UUID.Zero) + rdata.writer.WriteStartElement(part); + if (item != UUID.Zero) { - rdata.writer.WriteAttributeString("Item",item.ToString()); + rdata.writer.WriteAttributeString("Item",item.ToString()); } - if(asset != UUID.Zero) + + if (asset != UUID.Zero) { - rdata.writer.WriteAttributeString("Item",asset.ToString()); + rdata.writer.WriteAttributeString("Item",asset.ToString()); } - rdata.writer.WriteEndElement(); + rdata.writer.WriteEndElement(); } } @@ -741,16 +742,16 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory Rest.Log.DebugFormat("{0} FormatUserAppearance", MsgId); - if(rdata.userAppearance != null) + if (rdata.userAppearance != null) { - Rest.Log.DebugFormat("{0} FormatUserAppearance: appearance object exists", MsgId); - rdata.writer.WriteStartElement("Appearance"); + Rest.Log.DebugFormat("{0} FormatUserAppearance: appearance object exists", MsgId); + rdata.writer.WriteStartElement("Appearance"); - rdata.writer.WriteAttributeString("Height", rdata.userAppearance.AvatarHeight.ToString()); - if(rdata.userAppearance.Owner != null) - rdata.writer.WriteAttributeString("Owner", rdata.userAppearance.Owner.ToString()); - rdata.writer.WriteAttributeString("Serial", rdata.userAppearance.Serial.ToString()); + rdata.writer.WriteAttributeString("Height", rdata.userAppearance.AvatarHeight.ToString()); + if (rdata.userAppearance.Owner != null) + rdata.writer.WriteAttributeString("Owner", rdata.userAppearance.Owner.ToString()); + rdata.writer.WriteAttributeString("Serial", rdata.userAppearance.Serial.ToString()); FormatPart(rdata, "Body", rdata.userAppearance.BodyItem, rdata.userAppearance.BodyAsset); FormatPart(rdata, "Skin", rdata.userAppearance.SkinItem, rdata.userAppearance.SkinAsset); @@ -769,73 +770,72 @@ namespace OpenSim.ApplicationPlugins.Rest.Inventory FormatPart(rdata, "UnderShirt", rdata.userAppearance.UnderShirtItem, rdata.userAppearance.UnderShirtAsset); FormatPart(rdata, "UnderPants", rdata.userAppearance.UnderPantsItem, rdata.userAppearance.UnderPantsAsset); - Hashtable attachments = rdata.userAppearance.GetAttachments(); - - if(attachments != null) - { + Hashtable attachments = rdata.userAppearance.GetAttachments(); - Rest.Log.DebugFormat("{0} FormatUserAppearance: Formatting attachments", MsgId); + if (attachments != null) + { - rdata.writer.WriteStartElement("Attachments"); - for (int i=0; i