Is sharable if marked as and if buttons are sharable (they might
        hold sensitive data).
977505
def is_sharable(self):
        
        return self.sharable and all(x.is_sharable() for x in self.buttons)
68891
def shareable(self, boolean):
        """"""
        if(boolean):
            r = self.flag({
                "flag": "make_shareable"
            })
        else:
            r = self.flag({
                "flag": "make_not_shareable"
            })

        return r
755248
public function isHintEnabled()
    {
        $isParamPresent = $this->_request->getParam('ath', false) === '1';

        if ($isParamPresent) {
            $applicationMode = $this->appState->getMode();
            $storeId = $this->storeManager->getStore()->getId();

            if ($applicationMode === AppState::MODE_DEVELOPER || $this->developerHelper->isDevAllowed($storeId)) {
                return true;
            }
        }

        return false;
    }
605421
public static function isEnabled()
    {
        if (!self::$_checkedEnabled) {
            self::$_checkedEnabled = true;

            $conf = self::getConfiguration();

            $enabled = false;
            if (strtolower($conf->trigger) == 'always') {
                $enabled = true;
            } elseif (strtolower($conf->trigger) == 'parameter') {
                if ((isset($_GET['profile']) && $_GET['profile'] == true) || (isset($_COOKIE['profile']) && $_COOKIE['profile'] == true)) {
                    $enabled = true;
                }
            }

            // Process filters
            if ($enabled && $conf->enableFilters) {

                // sampling filter
                if ($enabled && rand(0,100000) > $conf->filters->sampling * 1000) {
                    $enabled = false;
                }

                // request uri whitelist/blacklist
                $requestUri = isset($_SERVER['REQUEST_URI']) ? $_SERVER['REQUEST_URI'] : ''; // TODO: use script name instead for cli?
                if ($enabled && $conf->filters->requestUriWhiteList && !preg_match($conf->filters->requestUriWhiteList, $requestUri)) {
                    $enabled = false;
                }
                if ($enabled && $conf->filters->requestUriBlackList && preg_match($conf->filters->requestUriBlackList, $requestUri)) {
                    $enabled = false;
                }

                // note: timeThreshold and memoryThreshold will be checked before persisting records. In these cases data will still be recorded during the request
            }

            if ($enabled) {
                self::enable();
            }
        }
        return self::$_enabled;
    }
821753
function isPotentiallyTabbableIOS(element) {
    var /** @type {?} */ nodeName = element.nodeName.toLowerCase();
    var /** @type {?} */ inputType = nodeName === 'input' && ((element)).type;
    return inputType === 'text'
        || inputType === 'password'
        || nodeName === 'select'
        || nodeName === 'textarea';
}
232291
private void checkAndEnableSaveButton() {
		boolean enabled = true;
		enabled &= txt_PubCert.getDocument().getLength() > MIN_CERT_LENGTH;
		bt_save.setEnabled(enabled);
	}
1063096
function isProtectionEnabled() {
    	return 	$this->_sheet ||
				$this->_objects ||
				$this->_scenarios ||
				$this->_formatCells ||
				$this->_formatColumns ||
				$this->_formatRows ||
				$this->_insertColumns ||
				$this->_insertRows ||
				$this->_insertHyperlinks ||
				$this->_deleteColumns ||
				$this->_deleteRows ||
				$this->_selectLockedCells ||
				$this->_sort ||
				$this->_autoFilter ||
				$this->_pivotTables ||
				$this->_selectUnlockedCells;
    }
1171951
function isKeyable(value) {
        var type = typeof value;
        return type == 'number' || type == 'boolean' || type == 'string' && value != '__proto__' || value == null;
      }
1343930
private function isFilterable(): bool
    {
        if (empty($this->user)) {
            return false;
        }

        if (! array_key_exists('id', $this->user)) {
            return false;
        }

        if ($this->isSuperuser()) {
            return false;
        }

        if ($this->isSkipTable()) {
            return false;
        }

        $controllerName = $this->getControllerClassName();

        // no relevant controller found for specified table
        if (! $controllerName) {
            return false;
        }

        // table's controller is cake's default controller, this is probably a many-to-many join table
        if ('Cake\Controller\Controller' === $controllerName) {
            return false;
        }

        return true;
    }
808871
def _CheckData(yaml_data):
  """"""
  legal_keys = set(('blacklist', 'whitelist'))
  unknown_keys = set(yaml_data) - legal_keys
  if unknown_keys:
    raise UnknownConfigKeyError(
        'Unknown keys in configuration: %s' % unknown_keys)

  for key, data in six.iteritems(yaml_data):
    _AssertDataIsList(key, data)
1346739
public boolean isAmendable() {
		if (getTimestamp() == null) {
			return false;
		}
		long now = Utils.timestamp();
		// check timestamp for recent correction,
		return (getTimestamp() + (Config.VOTE_LOCKED_AFTER_SEC * 1000)) > now;
	}
475900
boolean canBeFoldedWith(MouseState ms) {
        return ms.buttonsPressed.equals(buttonsPressed) && ms.wheel == wheel;
    }
451984
private void checkAndEnableViewButton() {
		boolean enabled = true;
		enabled &= Desktop.isDesktopSupported();
		enabled &= txt_PubCert.getDocument().getLength() > MIN_CERT_LENGTH;
		bt_view.setEnabled(enabled);
	}
364723
def hashable(data, v):
    """"""
    try:
        data[v]
    except (TypeError, KeyError, IndexError):
        return False
    return True
1276920
def secure(self, value):
        """"""
        self._secure = value
        self._thumb  = self._link_to_img()
909870
def is_editable(self, request):
        
        return request.user.is_superuser or request.user.id == self.user_id
216396
def has_safe_repr(value):
    """"""
    if value is None or value is NotImplemented or value is Ellipsis:
        return True
    if type(value) in (bool, int, float, complex, range_type, Markup) + string_types:
        return True
    if type(value) in (tuple, list, set, frozenset):
        for item in value:
            if not has_safe_repr(item):
                return False
        return True
    elif type(value) is dict:
        for key, value in iteritems(value):
            if not has_safe_repr(key):
                return False
            if not has_safe_repr(value):
                return False
        return True
    return False