Specify/get _isStraight flag value

@param bool $flag
@return bool
8626
public function isStraight($flag = null)
    {
        if ($flag !== null) {
            $this->_isStraight = $flag;
        }
        return $this->_isStraight;
    }
1066591
public function useLayout($flag = null): bool
    {
        if (\is_bool($flag)) {
            $this->layoutFlag = $flag;
        }

        return $this->layoutFlag;
    }
1302177
public function getOption($flag) {
        return isset($this->options[$flag]) ? $this->options[$flag] : null;
    }
1075664
private function detectFlags($argument)
    {
        if ((substr($argument, 0, 2) === '--') && (!strpos($argument, '='))) {
            $this->flags->push(ltrim($argument, '--'));
            return true;
        }
        return false;
    }
1164774
public function isSelected($flag = null)
    {
        if ($flag !== null) {
            $this->isSelected = !!$flag;

            $this->setCollapsed(!$flag);
        }

        return $this->isSelected;
    }
605345
public static function convertFromDelegateFlags($flags = null)
    {
        if (null === $flags) {
            return self::NOPARAM;
        }

        $converted = 0;

        foreach (self::$flagMap as $from => $to) {
            if ($flags & $to) {
                $converted |= $from;
            }
        }

        return $converted;
    }
412751
protected static function getStatusByBooleanFlags(
        bool $isPending,
        bool $isDeleted,
        bool $isBanned
    ): int {
        if ($isBanned === true) {
            return PostInterface::STATUS_DELETED;
        }

        if ($isDeleted === true) {
            return PostInterface::STATUS_DELETED;
        }

        if ($isPending === true) {
            return PostInterface::STATUS_PENDING_MODERATION;
        }

        return PostInterface::STATUS_PUBLISHED;
    }
213572
def has_flags(self, *flags):
        

        mask = sum(flags)
        return (self.bits & mask) == mask
1261654
public static boolean
isFlag(int index) {
	flags.check(index);
	if ((index >= 1 && index <= 4) || (index >= 12))
		return false;
	return true;
}
1160009
public function setFlag($flag)
    {
        if (!in_array($flag, [DiscloseNode::FLAG_HIDE, DiscloseNode::ALT_FLAG_HIDE, DiscloseNode::FLAG_SHOW, DiscloseNode::ALT_FLAG_SHOW])) {
            throw new UnexpectedValueException(sprintf(
                'The value of the parameter \'flag\' must be set to \'%s\', \'%s\', \'%s\' or \'%s\'.',
                DiscloseNode::FLAG_HIDE,
                DiscloseNode::ALT_FLAG_HIDE,
                DiscloseNode::FLAG_SHOW,
                DiscloseNode::ALT_FLAG_SHOW
            ));
        }

        $this->flag = $flag;

        return $this;
    }
651438
public function pasv($flag = true)
    {
        return ($this->isConnected() === true) ? ftp_pasv($this->getConnection(), $flag) : false;
    }
325553
private static function getImageFlag(array $flags): int
    {
        $res = 0;
        foreach ($flags as $flag) {
            $res |= constant(Image::class . '::' . $flag);
        }
        return $res;
    }
1253373
private function isFlagEnabled($flag): bool
    {
        $flag = $this->parseFlag($flag);

        return $flag === ($this->flags & $flag);
    }
160698
public function contains($needle, $flags = 0)
    {
        return ($flags & self::CASE_SENSITIVE) ? (strpos($this->getInternalValue(),
                $needle) !== false) : (stripos($this->getInternalValue(), $needle) !== false);
    }
241930
public static function isAllBitSet( int $target, int $flag ) : bool
    {
        return self::isBitSet( $target, $flag, self::BITTEST_MODE_ALL );
    }
528761
public function removeFlag($flag)
    {
        
        $currentFlags = $this->getFlags();
        for ($i = 0; $i < count($currentFlags); $i++){
            if ($currentFlags[$i] == $flag){
                break;
            }
        }
        
        if ($i <= count($currentFlags)){
            // The flag is found.
            unset($currentFlags[$i]);
            $this->setFlags($currentFlags);
        }
        
    }
1368150
public function isExternal($flag = false)
    {
        $this->external = true;

        if ($flag) {
            $this->baseUrl = '';
        }

        return $this;
    }