def _encode(self, value):
        if value > self.max:
            raise ValueError("Value %d exceeds max %d" % (value, self.max))
        if value < self.min:
            raise ValueError("Value %d is less than min %d" % (value, self.min))
        return struct.pack(self.sizeFmtMap[self.size], value)
dataset/ETHPy150Open jookies/jasmin/jasmin/vendor/smpp/pdu/pdu_encoding.py/IntegerBaseEncoder._encode/original