Пример #1
0
        // Parses an interface
        private void ParseInterface(URTNamespace parsingNamespace)
        {
            Util.Log("SdlParser.ParseInterface");           
            String intfName = LookupAttribute(s_nameString, null, true);
            URTInterface parsingInterface = parsingNamespace.LookupInterface(intfName);

            if (parsingInterface == null)
            {
                parsingInterface = new URTInterface(intfName, parsingNamespace.Namespace, parsingNamespace.EncodedNS);              
                parsingNamespace.AddInterface(parsingInterface);                
            }

            int curDepth = _XMLReader.Depth;
            ReadNextXmlElement();
            while(_XMLReader.Depth > curDepth)
            {
                if(MatchingNamespace(s_sudsNamespaceString))
                {
                    String elmName = _XMLReader.LocalName;
                    if(MatchingStrings(elmName, s_extendsString))
                    {
                        String nameValue = LookupAttribute(s_nameString, null, true);
                        String nameValueNS = ParseQName(ref nameValue);
                        parsingInterface.Extends(nameValue, nameValueNS, this);
                        ReadNextXmlElement();
                        continue;
                    }
                    else if(MatchingStrings(elmName, s_requestResponseString))
                    {
                        ParseRRMethod(null, parsingInterface);
                        continue;
                    }
                    else if(MatchingStrings(elmName, s_onewayString))
                    {
                        ParseOnewayMethod(null, parsingInterface);
                        continue;
                    }
                }

                // Ignore others elements such as annotations
                SkipXmlElement();
            }

            return;
        }