MCPcopy Create free account
hub / github.com/apache/mesos / SetFilters

Method SetFilters

support/cpplint.py:906–922  ·  view source on GitHub ↗

Sets the error-message filters. These filters are applied when deciding whether to emit a given error message. Args: filters: A string of comma-separated filters (eg "+whitespace/indent"). Each filter should start with + or -; else we die. Raises: ValueE

(self, filters)

Source from the content-addressed store, hash-verified

904 self.counting = counting_style
905
906 def SetFilters(self, filters):
907 """Sets the error-message filters.
908
909 These filters are applied when deciding whether to emit a given
910 error message.
911
912 Args:
913 filters: A string of comma-separated filters (eg "+whitespace/indent").
914 Each filter should start with + or -; else we die.
915
916 Raises:
917 ValueError: The comma-separated filters did not all start with '+' or '-'.
918 E.g. "-,+whitespace,-whitespace/indent,whitespace/badfilter"
919 """
920 # Default filters always have less priority than the flag ones.
921 self.filters = _DEFAULT_FILTERS[:]
922 self.AddFilters(filters)
923
924 def AddFilters(self, filters):
925 """ Adds more filters to the existing list of error-message filters. """

Callers 1

_SetFiltersFunction · 0.80

Calls 1

AddFiltersMethod · 0.95

Tested by

no test coverage detected