当前位置: 首页 > news >正文

html做音乐网站模板网络公司排名及利润

html做音乐网站模板,网络公司排名及利润,wordpress 主页地址函数,淘宝上做微请帖的在哪个网站注意#xff1a;该文章涉及到的调用方法若找不到 请移步第一部分内容查找 C# 生成wsdl和dll教程请移步 【超细完整版】C# WebService 通过URL生成WSDL文件和DLL文件 【生成篇】 开始 首先实现一个类#xff0c;用于实现对URL的验证等 public class InputFormatVerifica…注意该文章涉及到的调用方法若找不到 请移步第一部分内容查找 C# 生成wsdl和dll教程请移步 【超细完整版】C# WebService 通过URL生成WSDL文件和DLL文件 【生成篇】 开始 首先实现一个类用于实现对URL的验证等 public class InputFormatVerification {/// summary/// 是否合法Url地址统一资源定位/// /summary/// param namestrValueurl地址/param/// returns成功返回true 失败返回false/returnspublic static bool IsUrl(string strValue){string RegexStr string.Empty;RegexStr ^(http|https)\://([a-zA-Z0-9\.\-](\:[a-zA-Z0-9\.%\$\-])*)*((25[0-5]|2[0-4][0-9]|[0-1]{1}[0-9]{2}|[1-9]{1}[0-9]{1}|[1-9])\.(25[0-5]|2[0-4][0-9]|[0-1]{1}[0-9]{2}|[1-9]{1}[0-9]{1}|[1-9]|0)\.(25[0-5]|2[0-4][0-9]|[0-1]{1}[0-9]{2}|[1-9]{1}[0-9]{1}|[1-9]|0)\.(25[0-5]|2[0-4][0-9]|[0-1]{1}[0-9]{2}|[1-9]{1}[0-9]{1}|[0-9])|localhost|([a-zA-Z0-9\-]\.)*[a-zA-Z0-9\-]\.(com|edu|gov|int|mil|net|org|biz|arpa|info|name|pro|aero|coop|museum|[a-zA-Z]{1,10}))(\:[0-9])*(/($|[a-zA-Z0-9\.\,\?\\\\%\$#\~_\-]))*$;return formatChecks(RegexStr, strValue);}/// summary/// 检测串值是否为合法的格式/// /summary/// param namestrRegex正则表达式/param/// param namestrValue要检测的String值/param/// returns成功返回true 失败返回false/returnspublic static bool formatChecks(string strRegex, string strValue){if (string.IsNullOrWhiteSpace(strValue)){return false;}Regex re new Regex(strRegex);return re.IsMatch(strValue);} }实现Invoke 获取WebService中的所有web 方法 #region 获取web方法 /// summary /// 获取WebService接口的所有WebMethod方法 /// 通过WebService方法的特性为【System.Web.Services.Protocols.SoapDocumentMethodAttribute】 /// 根据特性SoapDocumentMethodAttribute来筛选出所有WebMethod方法 /// /summary /// param nameurl/param public static ListMethodInfo GetAllWebMethodsFromLink(string url, out string className) {className GetClassNameFromUrl(url);CompilerResults result UrlToDllFile(url);Assembly assembly result.CompiledAssembly;Type type assembly.GetType(className);return GetWebMethods(type); } /// summary /// 获取WebService接口的所有WebMethod方法 /// 通过WebService方法的特性为【System.Web.Services.Protocols.SoapDocumentMethodAttribute】 /// 根据特性SoapDocumentMethodAttribute来筛选出所有WebMethod方法 /// /summary /// param namewsdlFilePath/param public static ListMethodInfo GetAllWebMethodsFromWsdl(string wsdlFilePath, out string className) {className GetClassNameFromWsdl(wsdlFilePath);CompilerResults result WsdlToDll(wsdlFilePath);Assembly assembly result.CompiledAssembly;Type type assembly.GetType(className);return GetWebMethods(type); }private static ListMethodInfo GetWebMethods(Type type) {ListMethodInfo methodInfoList new ListMethodInfo();if (type null){return methodInfoList;}MethodInfo[] methodInfos type.GetMethods();for (int i 0; i methodInfos.Length; i){MethodInfo methodInfo methodInfos[i];//WebMethod方法的特性为System.Web.Services.Protocols.SoapDocumentMethodAttribute Attribute attribute methodInfo.GetCustomAttribute(typeof(System.Web.Services.Protocols.SoapDocumentMethodAttribute));if (methodInfo.MemberType MemberTypes.Method attribute ! null){methodInfoList.Add(methodInfo);}}return methodInfoList; } #endregion通过wsdl或url进行调用 /// summary /// 调用WebService /// /summary /// param nameaddressWebService地址/param /// param namemethodName方法名称/param /// param nameargs参数列表/param /// param nametimeOut/param /// returns返回调用结果/returns /// exception crefException/exception private static object InvokeWebService(string address, string methodName, object[] args, string timeOut ) {try{string className string.Empty;CompilerResults result null;//支持直接URL或wsdl类型文件的调用if (InputFormatVerification.IsUrl(address)){className GetClassNameFromUrl(address);result UrlToDllFile(address);}else{className GetClassNameFromWsdl(address);result WsdlToDll(address);}Assembly assembly result.CompiledAssembly;Type type assembly.GetType(className);FieldInfo[] arry type.GetFields();//实例类型对象 object obj Activator.CreateInstance(type);System.Reflection.MethodInfo mi type.GetMethod(methodName);//添加超时时间if (!string.IsNullOrEmpty(timeOut)){int timeout 0;int.TryParse(timeOut, out timeout);if (timeout 0) timeout 1200;//设置超时时间((System.Web.Services.Protocols.WebClientProtocol)(obj)).Timeout timeout * 1000;//毫秒s,timeOut超时时间设置为分钟}var res mi.Invoke(obj, args);return res;}catch (Exception ex){throw new Exception(ex.InnerException.Message, new Exception(ex.InnerException.StackTrace));} }老规矩
http://www.zqtcl.cn/news/318989/

相关文章:

  • 怎样在外贸网站做业务简付后wordpress
  • html网页制作源代码成品长沙 网站优化
  • 长沙做网站哪里好百度招聘 网站开发
  • 创建网站服务器银川建设厅网站
  • 海口建设局网站代运营网站建设
  • 网站建设环境搭建心得体会微信开发者模式
  • 网站点击率多少正常落地页网站
  • 做淘宝店铺有哪些好的网站东莞网站制作建设收费
  • Wordpress 实名认证太原网站搜索优化
  • 大良网站建设dwxw网站可以自己做
  • 自己怎么建网站佛山哪家网站建设比较好
  • 长沙短视频制作公司广州网站优化注意事项
  • 北京西城网站建设公司蓬莱做网站价格
  • 网站镜像做排名网站托管工作室
  • 江苏省建设协会网站wordpress小说采集
  • 网站运行费用预算计算机学了出来干嘛
  • 什么网站上公司的评价最客观青州网站优化
  • 网站开发下载那个kk网龙岩
  • 网站页面统计代码是什么意思国外网站模板欣赏
  • 徐州社交网站传奇做网站空间
  • 网站服务器租赁怎样用ps做网站的效果图
  • 温州网站建设制作苏州做网站费用
  • 山东网站建设和游戏开发的公司排名网站开发工程师待遇淄博
  • 创建网站的代码公司网站建设服务公司
  • 徐州建站推广仿织梦长沙网站公司
  • 中山做网站的新闻静态网站模板下载
  • 以学校为目标做网站策划书企业管理软件都有哪些
  • 黄石网站开发云开发小程序源码
  • 重点实验室网站建设萧山好的做网站的公司
  • 物流网站的建设网站建设优化是什么鬼