NVentimiglia / Websockets.PCL

C# Websockets for all platforms using native bridges
MIT License
98 stars 36 forks source link

Not able to add cookie as parameter #15

Open samiramin opened 8 years ago

samiramin commented 8 years ago

I am trying to pass cookie as parameter with new setCookie method. I have added method in IWebSocketConnection interface of Websockets project, and also added method in Websockets.iOS and Websockets.Droid project.

I am using PCL project for iOS and android. From my main project I am trying to call setCookie method with cookie parameter it gives error.

Error CS1061: Type Websockets.IWebSocketConnection' does not contain a definition forsetCookie' and no extension method setCookie' of typeWebsockets.IWebSocketConnection' could be found. Are you missing an assembly reference? (CS1061)

I am able to use connection.setCookie method but when I try to compile it it shows the above error.

Without setting cookie websocket is able to connect with test url i.e ws://echo.websocket.org/

I am only able to access and use the method which are already there, I am not able to add my method. Why I am not able to access new methods?

NVentimiglia commented 8 years ago

https://github.com/NVentimiglia/Websockets.PCL/blob/master/Websockets/IWebSocketConnection.cs

There is no setCookie method. if you define it, I will accept a pull request

samiramin commented 8 years ago

@NVentimiglia, I know there is no setCookie method, I have added new method and using it in my PCL project. But to generate a pull request It should work. My issue is I am able to use setCookie method using intellisense and when I build the app it gives an error.

NVentimiglia commented 8 years ago

Have this source somewhere for review ? I will accept pulls.