lua-users home
lua-l archive

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


b = Buffer(1024)
s1 = b:Segment(128, 256) -- from 128 to 384
s1 = b:Segment(128):size(256) -- from 128 to 384
s1 = b:Segment(128):to(384) -- from 128 to 384
s2 = b:Segment(439)      -- from 439 to 1024
s3 = b:Segment()      -- from 0 to 1024
s4 = b:Segment():size(128)      -- from 0 to 128
s5 = b:Segment(128):to(384):next() -- from 384 to 640
s5 = b:Segment(128):to(384):shift(10) -- from 138 to 394