-- -------------------------------------------------------------------------------- -- FILE: listener.lua -- DESCRIPTION: protoc-gen-lua -- Google's Protocol Buffers project, ported to lua. -- https://code.google.com/p/protoc-gen-lua/ -- -- Copyright (c) 2010 , 林卓毅 (Zhuoyi Lin) netsnail@gmail.com -- All rights reserved. -- -- Use, modification and distribution are subject to the "New BSD License" -- as listed at <url: http://www.opensource.org/licenses/bsd-license.php >. -- -- COMPANY: NetEase -- CREATED: 2010年08月02日 17时35分25秒 CST -------------------------------------------------------------------------------- -- local setmetatable = setmetatable module "listener" local _null_listener = { Modified = function() end } function NullMessageListener() return _null_listener end local _listener_meta = { Modified = function(self) if self.dirty then return end if self._parent_message then self._parent_message:_Modified() end end } _listener_meta.__index = _listener_meta function Listener(parent_message) local o = {} o.__mode = "v" o._parent_message = parent_message o.dirty = false return setmetatable(o, _listener_meta) end
Name | Type | Size | Permission | Actions |
---|---|---|---|---|
containers.lua | File | 2.23 KB | 0644 |
|
decoder.lua | File | 11.29 KB | 0644 |
|
descriptor.lua | File | 1.88 KB | 0644 |
|
encoder.lua | File | 14.62 KB | 0644 |
|
ipset_message_pb.lua | File | 16.58 KB | 0644 |
|
listener.lua | File | 1.26 KB | 0644 |
|
pb.so | File | 15.19 KB | 0755 |
|
protobuf.lua | File | 34.49 KB | 0644 |
|
text_format.lua | File | 2.41 KB | 0644 |
|
type_checkers.lua | File | 2.3 KB | 0644 |
|
wire_format.lua | File | 3.67 KB | 0644 |
|
ws_message_pb.lua | File | 18.03 KB | 0644 |
|