Sets a single flag, leaving the others intact. @type FlagBit: int @param FlagBit: One of the L{Flags}. @type FlagValue: bool @param FlagValue: Boolean value of the flag.
(self, FlagBit, FlagValue)
| 744 | return bool(self.get_flags(FlagBit)) |
| 745 | |
| 746 | def set_flag_value(self, FlagBit, FlagValue): |
| 747 | """ |
| 748 | Sets a single flag, leaving the others intact. |
| 749 | |
| 750 | @type FlagBit: int |
| 751 | @param FlagBit: One of the L{Flags}. |
| 752 | |
| 753 | @type FlagValue: bool |
| 754 | @param FlagValue: Boolean value of the flag. |
| 755 | """ |
| 756 | if FlagValue: |
| 757 | eflags = FlagBit |
| 758 | else: |
| 759 | eflags = 0 |
| 760 | FlagMask = 0xFFFFFFFF ^ FlagBit |
| 761 | self.set_flags(eflags, FlagMask) |
| 762 | |
| 763 | def get_zf(self): |
| 764 | """ |