MCPcopy Create free account
hub / github.com/aboutcode-org/scancode-toolkit / is_digits_only

Method is_digits_only

src/licensedcode/query.py:791–796  ·  view source on GitHub ↗

Return True if this query run contains only digit tokens.

(self)

Source from the content-addressed store, hash-verified

789 return enumerate(self.tokens, self.start)
790
791 def is_digits_only(self):
792 """
793 Return True if this query run contains only digit tokens.
794 """
795 # FIXME: this should be cached
796 return intbitset(self.tokens).issubset(self.digit_only_tids)
797
798 def is_matchable(self, include_low=False, qspans=None):
799 """

Callers 1

is_matchableMethod · 0.95

Calls 1

issubsetMethod · 0.80

Tested by

no test coverage detected