Alright, I took the results from the poll, updated the wiki page and created a github repo where we can work on it.
Everyone who wants to participate, preferably people who write publicly available class libraries, just ask if you want in, I'll get you listed and repo access.
Standard class API
- Robin
- The Omniscient
- Posts: 6506
- Joined: Fri Feb 20, 2009 4:29 pm
- Location: The Netherlands
- Contact:
Re: Standard class API
Although I haven't written one of the class libraries, I'd like to help on this project.
As for the function name, we can't use Class or class, since both are used by one or more of the libraries. Perhaps the library could provide a table "common", with a function "class", so the example could be: Tree = common.class("Tree", Tree).
As for the function name, we can't use Class or class, since both are used by one or more of the libraries. Perhaps the library could provide a table "common", with a function "class", so the example could be: Tree = common.class("Tree", Tree).
Help us help you: attach a .love.
- bartbes
- Sex machine
- Posts: 4946
- Joined: Fri Aug 29, 2008 10:35 am
- Location: The Netherlands
- Contact:
Re: Standard class API
I actually used common-class in the example in the repo .
- Robin
- The Omniscient
- Posts: 6506
- Joined: Fri Feb 20, 2009 4:29 pm
- Location: The Netherlands
- Contact:
Re: Standard class API
I know, I read that. But common-class is not a valid identifier, while common.class is (well, not really, but you know what I mean).bartbes wrote:I actually used common-class in the example in the repo .
EDIT: BTW, how is the actual back end selected? Automatically? Explicitly specified by the lover?
Help us help you: attach a .love.
- bartbes
- Sex machine
- Posts: 4946
- Joined: Fri Aug 29, 2008 10:35 am
- Location: The Netherlands
- Contact:
Re: Standard class API
Back-end? The front end is provided by one of the libs, so slither, for example, could have a switch that would make it export this.
Re: Standard class API
Is there any way someone could break down exactly what all of this means for a semi-newbie programmer like myself? What exactly is this doing for LOVE?
Perhaps I am being thrown off by the use of the word 'class', which I've only seen in Object oriented languages. It's my understanding that Lua is not OOP.
Perhaps I am being thrown off by the use of the word 'class', which I've only seen in Object oriented languages. It's my understanding that Lua is not OOP.
- Robin
- The Omniscient
- Posts: 6506
- Joined: Fri Feb 20, 2009 4:29 pm
- Location: The Netherlands
- Contact:
Re: Standard class API
It means that libraries don't have to pick a class system, which would otherwise result in needing to have a ton of class systems for large projects using multiple librariesEnsayia wrote:Is there any way someone could break down exactly what all of this means for a semi-newbie programmer like myself? What exactly is this doing for LOVE?
Lua is object oriented, but it doesn't provide a standard way of making classes and objects. That is where the lover-made libraries come in (SECS, MiddleClass, Slither, hump.class, ...). The thing is, they each have different syntax and ways of doing things, which means problems if you have to use more than one at the same time.Ensayia wrote:It's my understanding that Lua is not OOP.
Help us help you: attach a .love.
Re: Standard class API
dead?
i want to use it :-)
i want to use it :-)
- bartbes
- Sex machine
- Posts: 4946
- Joined: Fri Aug 29, 2008 10:35 am
- Location: The Netherlands
- Contact:
Re: Standard class API
It was implemented in MiddleClass, hump.class, SECS and Slither.
Who is online
Users browsing this forum: Amazon [Bot], Google [Bot] and 3 guests