summaryrefslogtreecommitdiffhomepage
path: root/libs/nixio/docsrc/nixio.bit.lua
diff options
context:
space:
mode:
authorSteven Barth <steven@midlink.org>2009-04-21 16:26:45 +0000
committerSteven Barth <steven@midlink.org>2009-04-21 16:26:45 +0000
commita2b916ab736802050b19562b7c163e3f3bb1566f (patch)
treed35b68f7bcac43f66f4cdb915ef327b76856594b /libs/nixio/docsrc/nixio.bit.lua
parent085a0a9ec040fc3ea5ee537d2cee724aa775747b (diff)
Merge nixio 0.2
Diffstat (limited to 'libs/nixio/docsrc/nixio.bit.lua')
-rw-r--r--libs/nixio/docsrc/nixio.bit.lua86
1 files changed, 86 insertions, 0 deletions
diff --git a/libs/nixio/docsrc/nixio.bit.lua b/libs/nixio/docsrc/nixio.bit.lua
new file mode 100644
index 0000000000..3bdad51f2f
--- /dev/null
+++ b/libs/nixio/docsrc/nixio.bit.lua
@@ -0,0 +1,86 @@
+--- Bitfield operators and mainpulation functions.
+-- Can be used as a drop-in replacement for bitlib.
+module "nixio.bit"
+
+--- Bitwise OR several numbers.
+-- @class function
+-- @name bor
+-- @param oper1 First Operand
+-- @param oper2 Second Operand
+-- @param ... More Operands
+-- @return number
+
+--- Bitwise AND several numbers.
+-- @class function
+-- @name band
+-- @param oper1 First Operand
+-- @param oper2 Second Operand
+-- @param ... More Operands
+-- @return number
+
+--- Bitwise XOR several numbers.
+-- @class function
+-- @name bxor
+-- @param oper1 First Operand
+-- @param oper2 Second Operand
+-- @param ... More Operands
+-- @return number
+
+--- Left shift a number.
+-- @class function
+-- @name shl
+-- @param oper number
+-- @param shift bits to shift
+-- @return number
+
+--- Right shift a number.
+-- @class function
+-- @name shr
+-- @param oper number
+-- @param shift bits to shift
+-- @return number
+
+--- Arithmetically right shift a number.
+-- @class function
+-- @name ashr
+-- @param oper number
+-- @param shift bits to shift
+-- @return number
+
+--- Integer division of 2 or more numbers.
+-- @class function
+-- @name div
+-- @param oper1 Operand 1
+-- @param oper2 Operand 2
+-- @param ... More Operands
+-- @return number
+
+--- Cast a number to the bit-operating range.
+-- @class function
+-- @name cast
+-- @param oper number
+-- @return number
+
+--- Sets one or more flags of a bitfield.
+-- @class function
+-- @name set
+-- @param bitfield Bitfield
+-- @param flag1 First Flag
+-- @param ... More Flags
+-- @return altered bitfield
+
+--- Unsets one or more flags of a bitfield.
+-- @class function
+-- @name unset
+-- @param bitfield Bitfield
+-- @param flag1 First Flag
+-- @param ... More Flags
+-- @return altered bitfield
+
+--- Checks whether given flags are set in a bitfield.
+-- @class function
+-- @name check
+-- @param bitfield Bitfield
+-- @param flag1 First Flag
+-- @param ... More Flags
+-- @return true when all flags are set, otherwise false \ No newline at end of file