Rev 7762 | Blame | Compare with Previous | Last modification | View Log | Download | RSS feed
\name{getBitIndicators}\alias{getBitIndicators}\alias{setBitIndicators}\title{Operate on bit fields}\description{The \code{getBitIndicators} function decompose a value into its respectivebit components.The \code{setBitIndicators} combines individual components into asingle numberto "set" a bit field value.}\usage{getBitIndicators(val, defs)setBitIndicators(vals, defs)}%- maybe also 'usage' for other objects documented here.\arguments{\item{val}{the value to break up into the bit field components.}\item{defs}{the named integer vector that defines the bit field elements.}\item{vals}{the individual components that are to be combined into asingle integer value representing the collection of components.These can be given as names or integer values that correspond to theelements in the defs, either by name or value.}}\value{\code{getBitIndicators} returns a named integer vector representingthe components of the bit field in the value.The names of the vector give the symbolic elements that were set inthe value.\code{setBitIndicators} returns a single integer value representingthe value from combining the different components (e.g. ORing the bitsof the different values).}\references{Curl homepage \url{https://curl.se/}}\author{Duncan Temple Lang}\seealso{The features field in \code{\link{curlVersion}}.}\examples{getBitIndicators(7, c(A = 1, B = 2, C = 4))getBitIndicators(3, c(A = 1, B = 2, C = 4))getBitIndicators(5, c(A = 1, B = 2, C = 4))}\keyword{manip}