Re: How to bind a static member variable

Timo Boll <[email protected]> Mon, 8 Apr 2013 13:17:01 +0200
Newsgroups gmane.comp.lang.lua.bind.user
Message-ID <[email protected]>
--===============0192842283100967752==
Content-Type: multipart/alternative;
	boundary="Apple-Mail=_5346727F-8317-4429-B7E1-9F6278837EF6"


--Apple-Mail=_5346727F-8317-4429-B7E1-9F6278837EF6
Content-Transfer-Encoding: quoted-printable
Content-Type: text/plain;
	charset=iso-8859-1

Did you try .def_readonly? Maybe the error is a result of trying to bind =
a const type with .def

Am 08.04.2013 um 12:32 schrieb Lorenzo Pistone:

> I've tried to do so, but I'm getting "def_readwrite is not a member of =
luabind". I have successfully bound a static member _function_ though =
(with .def).
>=20
> On 04/08/2013 08:40 AM, Iliya Trendafilov wrote:
>> Hi,
>>=20
>> In the (rather old) docs, there's an example binding static function: =
http://www.rasterbar.com/products/luabind/docs.html#nested-scopes-and-stat=
ic-functions
>> Binding static members should be obvious from there
>>=20
>>=20
>>=20
>> On Sun, Apr 7, 2013 at 1:52 PM, Lorenzo Pistone =
<[email protected]> wrote:
>> Hello,
>> I cannot find any reference on how to bind a static member variable, =
so
>> that I can access it from lua as myclass.staticmember.
>>=20
>> Cheers.


--Apple-Mail=_5346727F-8317-4429-B7E1-9F6278837EF6
Content-Transfer-Encoding: 7bit
Content-Type: text/html;
	charset=iso-8859-1

<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Did you try .def_readonly? Maybe the error is a result of trying to bind a const type with .def<div><br><div><div>Am 08.04.2013 um 12:32 schrieb Lorenzo Pistone:</div><br class="Apple-interchange-newline"><blockquote type="cite">
  
    <meta content="text/html; charset=ISO-8859-1" http-equiv="Content-Type">
  
  <div bgcolor="#FFFFFF" text="#000000">
    <div class="moz-cite-prefix">I've tried to do so, but I'm getting
      "def_readwrite is not a member of luabind". I have successfully
      bound a static member _function_ though (with .def).<br>
      <br>
      On 04/08/2013 08:40 AM, Iliya Trendafilov wrote:<br>
    </div>
    <blockquote cite="mid:CAA9zKUsLNscELZhS2yEueh2_z+KEup0b5hgiv8Ts=ZTV+svNFA@mail.gmail.com" type="cite">
      <div dir="ltr">
        <div>
          <div>Hi,<br>
            <br>
          </div>
          In the (rather old) docs, there's an example binding static
          function: <a moz-do-not-send="true" href="http://www.rasterbar.com/products/luabind/docs.html#nested-scopes-and-static-functions">http://www.rasterbar.com/products/luabind/docs.html#nested-scopes-and-static-functions</a><br>
        </div>
        Binding static members should be obvious from there<br>
        <br>
      </div>
      <div class="gmail_extra"><br>
        <br>
        <div class="gmail_quote">On Sun, Apr 7, 2013 at 1:52 PM, Lorenzo
          Pistone <span dir="ltr">&lt;<a moz-do-not-send="true" href="mailto:[email protected]" target="_blank">[email protected]</a>&gt;</span>
          wrote:<br>
          <blockquote class="gmail_quote" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0.8ex; border-left-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; padding-left: 1ex; position: static; z-index: auto; ">Hello,<br>
            I cannot find any reference on how to bind a static member
            variable, so<br>
            that I can access it from lua as myclass.staticmember.<br>
            <br>
            Cheers.<br></blockquote></div></div></blockquote></div></blockquote></div><br></div></body></html>
--Apple-Mail=_5346727F-8317-4429-B7E1-9F6278837EF6--


--===============0192842283100967752==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

------------------------------------------------------------------------------
Minimize network downtime and maximize team effectiveness.
Reduce network management and security costs.Learn how to hire 
the most talented Cisco Certified professionals. Visit the 
Employer Resources Portal
http://www.cisco.com/web/learning/employer_resources/index.html
--===============0192842283100967752==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
luabind-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/luabind-user

--===============0192842283100967752==--