Score
0
Watch 12 Star 19 Fork 7

黄昏MMM / WCF-DotNetCoreC#GPL-2.0

Join us
Explore and code with more than 2 million developers,Free private repositories !:)
Sign up
.NET Core调用WCF(不通过代理类) spread retract

Clone or download
Cancel
Notice: Creating folder will generate an empty file .keep, because not support in Git
Loading...
README.md

A library makes .NET Core programs be able to call WCF server without proxy classes.

Finally

static void Main(string[] args)
{
    //Init Container
    IServiceProvider serviceProvider = InitServiceProvider();
	
	//Calling WCF
    using (IServiceScope serviceScope = serviceProvider.CreateScope())
    {
        IProductService productService = serviceScope.ServiceProvider.GetService<IProductService>();//This is a remote interface
        string products = productService.GetProducts();
        Console.WriteLine(products);
    }
    
    Console.ReadKey();
}

Comments ( 0 )

Sign in for post a comment

C#
1
https://gitee.com/lishilei0523/WCF-DotNetCore.git
git@gitee.com:lishilei0523/WCF-DotNetCore.git
lishilei0523
WCF-DotNetCore
WCF-DotNetCore
master

Help Search