Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generic attributes for addresses #32

Closed
jcelerier opened this issue Feb 24, 2016 · 3 comments
Closed

Generic attributes for addresses #32

jcelerier opened this issue Feb 24, 2016 · 3 comments

Comments

@jcelerier
Copy link
Member

Maybe the API should allow for setting / getting custom attributes ?
For instance this would allow to add tags, description, etc... without too much hassle.

e.g. in Address :

virtual void setAttribute(const std::string&, Value*) = 0;
virtual Value* getAttribute(const std::string&, Value*) const = 0;

However not all protocols may be able to support this (e.g. MIDI) so it could be an extension, or have a default implementation :

virtual void setAttribute(const std::string&, Value*) {
    // do nothing
}
virtual Value* getAttribute(const std::string&, Value*) const {
    return nullptr; 
}
@jcelerier
Copy link
Member Author

@thzebra this would be necessary in order to support all the attributes in the examples files

@thzebra
Copy link

thzebra commented Feb 24, 2016

ok, i'll see to it

@jcelerier
Copy link
Member Author

done since a long time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants