QuickSander / ArduinoHttpServer

Server side minimalistic HTTP protocol implementation for the Arduino platform.
GNU General Public License v3.0
23 stars 11 forks source link

'Method' is not a member of 'ArduinoHttpServer' #15

Closed thalesfsp closed 5 years ago

thalesfsp commented 5 years ago

Tried to run the example, and got this compilation error.

QuickSander commented 5 years ago

Hi, Could you please paste the full compilation error. Which example are you referring to? The checked in example is built every pull request. The examples in the documentation might contain flaws which I then need to correct.

It is highly dependent on the kind of environment you use. With platform.io it should work out of the box.

thalesfsp commented 5 years ago

Hi! I'm using the latest Arduino IDE, not Platform.io IDE and trying to run the example in the Arduino MKR1010 WiFi, latest board firmware. About the error, this is the error :) 'Method' is not a member of 'ArduinoHttpServer'

QuickSander commented 5 years ago

Hi,

I have to make a guess here so sorry for any mistakes, but are you talking about:

enum class Method : char
{
   Invalid, Get, Put, Post, Head, Delete
};

Then you need to refer to it like the following:

ArduinoHttpServer::Method method( ArduinoHttpServer::Method::Invalid ); You need to make sure you have a C++11 compatible compiler.

I hope this helps.

thalesfsp commented 5 years ago

Thank you!