sockets-for-pcl icon indicating copy to clipboard operation
sockets-for-pcl copied to clipboard

.Net Standard 2.0 version

Open melucas opened this issue 7 years ago • 6 comments

Any thoughts on converting this project to .Net Standard 2.0 or .Net Core now that MS has depreciated the portable projects?

melucas avatar Feb 08 '18 16:02 melucas

Yes, I do have plans to switch it over in the near future. That said, I had expected it would be possible to use sockets directly from netstandard2, though I hadn't verified that.

rdavisau avatar Mar 01 '18 11:03 rdavisau

So far it a is working as expect. However, the complier moans about back converting the assembly to .Net 4.x. I have tried it in a xamarin forms app running as Universal Windows and on an iPhone and my UDP connection are working and returning data.

melucas avatar Mar 07 '18 19:03 melucas

are there any new information about porting to netstandard2.0 ?

alanu86 avatar May 02 '18 13:05 alanu86

That feature would be absolutly great!

newdeal30 avatar May 03 '18 19:05 newdeal30

It was all working beautifully for me until I tried to reference the Socket property in Release mode.

// Should not be called on a TcpSocketClient that is not already connected.
if (m_oClient.Socket.Connected)
    await m_oClient.DisconnectAsync();

when I got this

warning : ILTransform : warning ILT0003: Method 'Communicator.<DisconnectAsync>d__10.MoveNext()' will always throw an exception due to the missing method 'TcpSocketClient.get_Socket()' in assembly 'Sockets.Plugin'.

so it can build and deploy fine, but then yes, it throws. The problem doesn't exist in Debug.

dog44wgm avatar Oct 25 '21 19:10 dog44wgm

Sorry, I forgot to mention that the problem exists in UWP only.

dog44wgm avatar Oct 25 '21 19:10 dog44wgm