lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Hi Journeyer,

By coincidence, I have just finished editing a new article on this very subject on the WiKi:

http://lua-users.org/wiki/ClassesAsConstructorClosures

This covers the three major patterns in the Lua literature: metatable, prototype and function-based, and wraps them in a common class scheme with a universal type matching predicate.

John Hind.

> ------------------------------
>
> Message: 2
> Date: Sun, 23 Feb 2014 11:19:58 +0900
> From: "Journeyer J. Joh" <oosaprogrammer@gmail.com>
> Subject: How can I learn about Object Oriented programming with lua?
> To: Lua mailing list <lua-l@lists.lua.org>
> Message-ID:
> 	<CALYKT1iAOXC4ZDSFhnQHn2CMwr8z8Rfmr1EREoDbqki5kwa22w@mail.gmail.c
> om>
> Content-Type: text/plain; charset="iso-8859-1"
>
> Hi,
>
> I am almost newbie about lua. Actually I've read the book - Programming
> in Lua and experienced Orbit, Orbiter. But that is about it.
>
> I want to learn programming skill in the OO style.
> Firstly, I want to try to implement GoF Patterns with lua.
>
> To do this, I've read chapters about OO programming from the book
> above.
> But I think the book didn't mention about virtual function.
>
> But I found some materials from the url below.
>
> http://lua-users.org/wiki/SampleCode
>
> Among several materials above, there are two in my eyes,
> YetAnotherClassImplementation<http://lua-
> users.org/wiki/YetAnotherClassImpl=
> ementation>
> ObjectLua <http://lua-users.org/wiki/ObjectLua>
>
> But before I go further by myself, I'd like to listen some advice from
> experienced lua programmers.
>
> What is the best way to learn about how to program OO style lua?
> What method would be the best for OO style lua programming?
>
> I use lua 5.1
>
> Sincerely
> Journeyer
> ----------------------------------------
> Journeyer J. Joh
> o o s a p r o g r a m m e r
> a t
> g m a i l  d o t  c o m
> ----------------------------------------


---
This email is free from viruses and malware because avast! Antivirus protection is active.
http://www.avast.com