Giter VIP home page Giter VIP logo

Comments (2)

marcoschwartz avatar marcoschwartz commented on July 30, 2024

Hello Charles,

Thanks for reaching out! Happy to hear that you enjoy using my library.

I think I got what you want to do here, basically use an element of the
linked list as a variable right? I think it would be more like:

rest.variable(me->name, me->value, "element");

As you always need to give a name to the variable you are using. Can you
tell me which library you are using for linked lists? I will check if it
doesn't raise the memory footprint of the library too much.

Cheers,
Marco Schwartz

On Thu, Jul 2, 2015 at 11:48 PM, Charles [email protected] wrote:

Marco,
just started to play with your lib today on a ESP8266, I love it :-)

I'm also using another lib, in this lib I've got a linked list of data.
Each linked list entry contains a pointer to a variable name and another to
variable value (+ another on next item entry if any). both are char *
Would it be possible to have the option to create variable(char *, char *)
? To be able as a stupid example to do something like that :

MyLinkedList * me = Entry;
rest.variable(me->name, me->value);

I could have done it, but I'm very old school, and I like to know exactly
what my code is doing. And to be honest, String class always provided so
much pain (mainly because I'm far away for expert in C++) that when I can
avoid them I do. All my var affectation and management is done in the other
lib, I just need to pass to rest the pointer to the pair of name/values.

Hope this makes sense

Charles


Reply to this email directly or view it on GitHub
#56.

from arest.

hallard avatar hallard commented on July 30, 2024

Marco,
You got it, and we're lucky, because on my linked list, the me->name element is already the variable name I want to expose, so it's fine. My problem is on the 2nd element which in my case is a char * instead of a string.

The library I'm using is a custom one I created (and currently working on), I will push it on github soon (need to check compilation is fine with other targets), lot of stuff to do.

By the way, I modified your lib to allow char *, as 2nd param, seems to work fine but I will be more confortable if you want to check what I done because you know your lib far better than me. I used new command code 'c' 'seems it was not used. Once I will validate I will do a push request, I've just forked your repo ;-)
Talk to you soon
Cheers,

from arest.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.