コード例 #1
0
 public AdditionalData(XmlNode xmlNode)
 {
     XmlNodeList mimeTypeNodeList = xmlNode.SelectNodes("mimeType");
     if (mimeTypeNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in mimeTypeNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 mimeTypeIDRef = item.Attributes["id"].Name;
                 MimeType ob = MimeType();
                 IDManager.SetID(mimeTypeIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 mimeTypeIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 mimeType = new MimeType(item);
             }
         }
     }
     
 
     XmlNodeList stringNodeList = xmlNode.SelectNodes("string");
     if (stringNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in stringNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 stringIDRef = item.Attributes["id"].Name;
                 XsdTypeString ob = XsdTypeString();
                 IDManager.SetID(stringIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 stringIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 string = new XsdTypeString(item);
             }
         }
     }
     
 
     XmlNodeList hexadecimalBinaryNodeList = xmlNode.SelectNodes("hexadecimalBinary");
     if (hexadecimalBinaryNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in hexadecimalBinaryNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 hexadecimalBinaryIDRef = item.Attributes["id"].Name;
                 XsdTypeHexBinary ob = XsdTypeHexBinary();
                 IDManager.SetID(hexadecimalBinaryIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 hexadecimalBinaryIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 hexadecimalBinary = new XsdTypeHexBinary(item);
             }
         }
     }
     
 
     XmlNodeList base64BinaryNodeList = xmlNode.SelectNodes("base64Binary");
     if (base64BinaryNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in base64BinaryNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 base64BinaryIDRef = item.Attributes["id"].Name;
                 XsdTypeBase64Binary ob = XsdTypeBase64Binary();
                 IDManager.SetID(base64BinaryIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 base64BinaryIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 base64Binary = new XsdTypeBase64Binary(item);
             }
         }
     }
     
 
     XmlNodeList originalMessageNodeList = xmlNode.SelectNodes("originalMessage");
     if (originalMessageNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in originalMessageNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 originalMessageIDRef = item.Attributes["id"].Name;
                 XsdTypeBoolean ob = XsdTypeBoolean();
                 IDManager.SetID(originalMessageIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 originalMessageIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 originalMessage = new XsdTypeBoolean(item);
             }
         }
     }
     
 
 }
コード例 #2
0
 public ExternalDocument(XmlNode xmlNode)
 {
     XmlNodeList mimeTypeNodeList = xmlNode.SelectNodes("mimeType");
     if (mimeTypeNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in mimeTypeNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 mimeTypeIDRef = item.Attributes["id"].Name;
                 MimeType ob = MimeType();
                 IDManager.SetID(mimeTypeIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 mimeTypeIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 mimeType = new MimeType(item);
             }
         }
     }
     
 
     XmlNodeList stringNodeList = xmlNode.SelectNodes("string");
     if (stringNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in stringNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 stringIDRef = item.Attributes["id"].Name;
                 XsdTypeString ob = XsdTypeString();
                 IDManager.SetID(stringIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 stringIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 string = new XsdTypeString(item);
             }
         }
     }
     
 
     XmlNodeList hexadecimalBinaryNodeList = xmlNode.SelectNodes("hexadecimalBinary");
     if (hexadecimalBinaryNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in hexadecimalBinaryNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 hexadecimalBinaryIDRef = item.Attributes["id"].Name;
                 XsdTypeHexBinary ob = XsdTypeHexBinary();
                 IDManager.SetID(hexadecimalBinaryIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 hexadecimalBinaryIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 hexadecimalBinary = new XsdTypeHexBinary(item);
             }
         }
     }
     
 
     XmlNodeList base64BinaryNodeList = xmlNode.SelectNodes("base64Binary");
     if (base64BinaryNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in base64BinaryNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 base64BinaryIDRef = item.Attributes["id"].Name;
                 XsdTypeBase64Binary ob = XsdTypeBase64Binary();
                 IDManager.SetID(base64BinaryIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 base64BinaryIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 base64Binary = new XsdTypeBase64Binary(item);
             }
         }
     }
     
 
     XmlNodeList urlNodeList = xmlNode.SelectNodes("url");
     if (urlNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in urlNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 urlIDRef = item.Attributes["id"].Name;
                 XsdTypeAnyURI ob = XsdTypeAnyURI();
                 IDManager.SetID(urlIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 urlIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 url = new XsdTypeAnyURI(item);
             }
         }
     }
     
 
     XmlNodeList attachmentReferenceNodeList = xmlNode.SelectNodes("attachmentReference");
     if (attachmentReferenceNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in attachmentReferenceNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 attachmentReferenceIDRef = item.Attributes["id"].Name;
                 HTTPAttachmentReference ob = HTTPAttachmentReference();
                 IDManager.SetID(attachmentReferenceIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 attachmentReferenceIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 attachmentReference = new HTTPAttachmentReference(item);
             }
         }
     }
     
 
 }
コード例 #3
0
 public Resource(XmlNode xmlNode)
 {
     XmlNodeList resourceIdNodeList = xmlNode.SelectNodes("resourceId");
     if (resourceIdNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in resourceIdNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 resourceIdIDRef = item.Attributes["id"].Name;
                 ResourceId ob = ResourceId();
                 IDManager.SetID(resourceIdIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 resourceIdIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 resourceId = new ResourceId(item);
             }
         }
     }
     
 
     XmlNodeList resourceTypeNodeList = xmlNode.SelectNodes("resourceType");
     if (resourceTypeNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in resourceTypeNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 resourceTypeIDRef = item.Attributes["id"].Name;
                 ResourceType ob = ResourceType();
                 IDManager.SetID(resourceTypeIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 resourceTypeIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 resourceType = new ResourceType(item);
             }
         }
     }
     
 
     XmlNodeList languageNodeList = xmlNode.SelectNodes("language");
     if (languageNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in languageNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 languageIDRef = item.Attributes["id"].Name;
                 Language ob = Language();
                 IDManager.SetID(languageIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 languageIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 language = new Language(item);
             }
         }
     }
     
 
     XmlNodeList sizeInBytesNodeList = xmlNode.SelectNodes("sizeInBytes");
     if (sizeInBytesNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in sizeInBytesNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 sizeInBytesIDRef = item.Attributes["id"].Name;
                 XsdTypeDecimal ob = XsdTypeDecimal();
                 IDManager.SetID(sizeInBytesIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 sizeInBytesIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 sizeInBytes = new XsdTypeDecimal(item);
             }
         }
     }
     
 
     XmlNodeList lengthNodeList = xmlNode.SelectNodes("length");
     if (lengthNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in lengthNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 lengthIDRef = item.Attributes["id"].Name;
                 ResourceLength ob = ResourceLength();
                 IDManager.SetID(lengthIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 lengthIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 length = new ResourceLength(item);
             }
         }
     }
     
 
     XmlNodeList mimeTypeNodeList = xmlNode.SelectNodes("mimeType");
     if (mimeTypeNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in mimeTypeNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 mimeTypeIDRef = item.Attributes["id"].Name;
                 MimeType ob = MimeType();
                 IDManager.SetID(mimeTypeIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 mimeTypeIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 mimeType = new MimeType(item);
             }
         }
     }
     
 
     XmlNodeList nameNodeList = xmlNode.SelectNodes("name");
     if (nameNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in nameNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 nameIDRef = item.Attributes["id"].Name;
                 XsdTypeNormalizedString ob = XsdTypeNormalizedString();
                 IDManager.SetID(nameIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 nameIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 name = new XsdTypeNormalizedString(item);
             }
         }
     }
     
 
     XmlNodeList commentsNodeList = xmlNode.SelectNodes("comments");
     if (commentsNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in commentsNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 commentsIDRef = item.Attributes["id"].Name;
                 XsdTypeString ob = XsdTypeString();
                 IDManager.SetID(commentsIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 commentsIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 comments = new XsdTypeString(item);
             }
         }
     }
     
 
     XmlNodeList stringNodeList = xmlNode.SelectNodes("string");
     if (stringNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in stringNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 stringIDRef = item.Attributes["id"].Name;
                 XsdTypeString ob = XsdTypeString();
                 IDManager.SetID(stringIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 stringIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 string = new XsdTypeString(item);
             }
         }
     }
     
 
     XmlNodeList hexadecimalBinaryNodeList = xmlNode.SelectNodes("hexadecimalBinary");
     if (hexadecimalBinaryNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in hexadecimalBinaryNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 hexadecimalBinaryIDRef = item.Attributes["id"].Name;
                 XsdTypeHexBinary ob = XsdTypeHexBinary();
                 IDManager.SetID(hexadecimalBinaryIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 hexadecimalBinaryIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 hexadecimalBinary = new XsdTypeHexBinary(item);
             }
         }
     }
     
 
     XmlNodeList base64BinaryNodeList = xmlNode.SelectNodes("base64Binary");
     if (base64BinaryNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in base64BinaryNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 base64BinaryIDRef = item.Attributes["id"].Name;
                 XsdTypeBase64Binary ob = XsdTypeBase64Binary();
                 IDManager.SetID(base64BinaryIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 base64BinaryIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 base64Binary = new XsdTypeBase64Binary(item);
             }
         }
     }
     
 
     XmlNodeList urlNodeList = xmlNode.SelectNodes("url");
     if (urlNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in urlNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 urlIDRef = item.Attributes["id"].Name;
                 XsdTypeAnyURI ob = XsdTypeAnyURI();
                 IDManager.SetID(urlIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 urlIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 url = new XsdTypeAnyURI(item);
             }
         }
     }
     
 
 }