private static void RemovePolicyFormatFromBinding(BindingCollection bindings) { foreach (Binding binding in bindings) { foreach (OperationBinding opBinding in binding.Operations) { RemovePolicyFormatFromExtensions(opBinding.Extensions); } } }
private static bool IsBindingNameUsed(string name, object collection) { WsdlNS.BindingCollection bindings = (WsdlNS.BindingCollection)collection; foreach (WsdlNS.Binding binding in bindings) { if (binding.Name == name) { return(true); } } return(false); }
public ServiceDescription () { bindings = new BindingCollection (this); extensions = new ServiceDescriptionFormatExtensionCollection (this); imports = new ImportCollection (this); messages = new MessageCollection (this); portTypes = new PortTypeCollection (this); serviceDescriptions = null; services = new ServiceCollection (this); targetNamespace = null; types = new Types (); }
public ServiceDescription() { bindings = new BindingCollection(this); extensions = new ServiceDescriptionFormatExtensionCollection(this); imports = new ImportCollection(this); messages = new MessageCollection(this); portTypes = new PortTypeCollection(this); serviceDescriptions = null; services = new ServiceCollection(this); targetNamespace = null; types = new Types(); }
public override void Check(ConformanceCheckContext ctx, BindingCollection value) { foreach (Binding b in value) { foreach (object ext in b.Extensions) { if (ext.GetType() == typeof(SoapBinding)) { return; } } } ctx.ReportRuleViolation(value, BasicProfileRules.R2401); }
public ServiceDescription() { bindings = new BindingCollection(this); extensions = new ServiceDescriptionFormatExtensionCollection(this); imports = new ImportCollection(this); messages = new MessageCollection(this); #if !NET_2_0 // name = String.Empty; #endif portTypes = new PortTypeCollection(this); serviceDescriptions = null; services = new ServiceCollection(this); targetNamespace = null; types = new Types(); }
public Parser(WSDescriber wsDesc, ref bool untrustedSSLSecureChannel, ref List<Param> respHeader) { HttpWebRequest wr = GetHttpWebReq(wsDesc); HttpWebResponse wres = null; try { wres = (HttpWebResponse)wr.GetResponse(); } catch (WebException wex) { if (wex.Status == WebExceptionStatus.TrustFailure) { ServicePointManager.ServerCertificateValidationCallback = delegate { return true; }; wr = GetHttpWebReq(wsDesc); wres = (HttpWebResponse)wr.GetResponse(); untrustedSSLSecureChannel = true; } } if (wres != null) { for (int i = 0; i < wres.Headers.Count; ++i) { respHeader.Add(new Param() { Name = wres.Headers.Keys[i].ToLowerInvariant(), Value = wres.Headers[i].ToLowerInvariant() }); } StreamReader streamReader = new StreamReader(wres.GetResponseStream()); rawWSDL = XDocument.Parse(streamReader.ReadToEnd()); TextReader myTextReader = new StringReader(rawWSDL.ToString()); serviceDescription = ServiceDescription.Read(myTextReader); TargetNameSpace = serviceDescription.TargetNamespace; bindColl = serviceDescription.Bindings; portTypColl = serviceDescription.PortTypes; msgColl = serviceDescription.Messages; types = serviceDescription.Types; schemas = types.Schemas; } }
public ServiceDescription () { bindings = new BindingCollection (this); extensions = new ServiceDescriptionFormatExtensionCollection (this); imports = new ImportCollection (this); messages = new MessageCollection (this); #if !NET_2_0 // name = String.Empty; #endif portTypes = new PortTypeCollection (this); serviceDescriptions = null; services = new ServiceCollection (this); targetNamespace = null; types = new Types (); }
public void InitializeBindingCollection () { // workaround for internal constructor ServiceDescription desc = new ServiceDescription (); bc = desc.Bindings; }
public virtual void Check(ConformanceCheckContext ctx, BindingCollection value) { }
public override void Check (ConformanceCheckContext ctx, BindingCollection value) { foreach (Binding b in value) foreach (object ext in b.Extensions) if (ext.GetType () == typeof (SoapBinding)) return; ctx.ReportRuleViolation (value, BasicProfileRules.R2401); }
public virtual void Check (ConformanceCheckContext ctx, BindingCollection value) { }