return Controller.extend({
allFacets: ['languages', 'repositories', 'tags', 'qprofile', 'debt_characteristics', 'severities', 'statuses',
- 'available_since'],
+ 'available_since', 'inheritance'],
facetsFromServer: ['languages', 'repositories', 'tags'],
pageSize: 200,
ruleFields: ['name', 'lang', 'langName', 'sysTags', 'tags', 'status'],
'coding-rules/facets/characteristic-facet',
'coding-rules/facets/severity-facet',
'coding-rules/facets/status-facet',
- 'coding-rules/facets/available-since-facet'
+ 'coding-rules/facets/available-since-facet',
+ 'coding-rules/facets/inheritance-facet'
],
function (FacetsView,
BaseFacet,
CharacteristicFacet,
SeverityFacet,
StatusFacet,
- AvailableSinceFacet) {
+ AvailableSinceFacet,
+ InheritanceFacet) {
return FacetsView.extend({
return StatusFacet;
case 'available_since':
return AvailableSinceFacet;
+ case 'inheritance':
+ return InheritanceFacet;
default:
return BaseFacet;
}
--- /dev/null
+define([
+ 'coding-rules/facets/base-facet'
+], function (BaseFacet) {
+
+ var $ = jQuery;
+
+ return BaseFacet.extend({
+
+ initialize: function (options) {
+ this.listenTo(options.app.state, 'change:query', this.onQueryChange);
+ },
+
+ onQueryChange: function () {
+ var query = this.options.app.state.get('query'),
+ isProfileSelected = query.qprofile != null;
+ if (isProfileSelected) {
+ var profile = _.findWhere(this.options.app.qualityProfiles, { key: query.qprofile });
+ if (profile != null && profile.parentKey == null) {
+ this.forbid();
+ }
+ } else {
+ this.forbid();
+ }
+ },
+
+ onRender: function () {
+ BaseFacet.prototype.onRender.apply(this, arguments);
+ this.onQueryChange();
+ },
+
+ forbid: function () {
+ BaseFacet.prototype.forbid.apply(this, arguments);
+ this.$el.prop('title', t('coding_rules.filters.inheritance.inactive'));
+ },
+
+ allow: function () {
+ BaseFacet.prototype.allow.apply(this, arguments);
+ this.$el.prop('title', null);
+ },
+
+ getValues: function () {
+ var values = ['NONE', 'INHERITED', 'OVERRIDES'];
+ return values.map(function (key) {
+ return {
+ label: t('coding_rules.filters.inheritance', key.toLowerCase()),
+ val: key
+ };
+ });
+ },
+
+ toggleFacet: function (e) {
+ var obj = {},
+ property = this.model.get('property');
+ if ($(e.currentTarget).is('.active')) {
+ obj[property] = null;
+ } else {
+ obj[property] = $(e.currentTarget).data('value');
+ }
+ this.options.app.state.updateFilter(obj);
+ },
+
+ serializeData: function () {
+ return _.extend(BaseFacet.prototype.serializeData.apply(this, arguments), {
+ values: this.getValues()
+ });
+ }
+ });
+
+});
return Marionette.ItemView.extend({
className: 'search-navigator-facet-box',
+ forbiddenClassName: 'search-navigator-facet-box-forbidden',
modelEvents: function () {
return {
},
toggle: function () {
- this.options.app.controller.toggleFacet(this.model.id);
+ if (!this.isForbidden()) {
+ this.options.app.controller.toggleFacet(this.model.id);
+ }
},
getValue: function () {
this.options.app.state.updateFilter(obj);
},
+ forbid: function () {
+ this.options.app.controller.disableFacet(this.model.id);
+ this.$el.addClass(this.forbiddenClassName);
+ },
+
+ allow: function () {
+ this.$el.removeClass(this.forbiddenClassName);
+ },
+
+ isForbidden: function () {
+ return this.$el.hasClass(this.forbiddenClassName);
+ },
+
sortValues: function (values) {
return _.sortBy(values, function (v) {
return -v.count;
--- /dev/null
+/* global casper:false */
+
+var lib = require('../lib');
+
+lib.initMessages();
+lib.changeWorkingDirectory('coding-rules-page-inheritance-facet');
+
+
+casper.test.begin('coding-rules-page-inheritance-facet', 11, function (test) {
+ casper
+ .start(lib.buildUrl('coding-rules'), function () {
+ lib.setDefaultViewport();
+
+ lib.mockRequest('/api/l10n/index', '{}');
+ lib.mockRequestFromFile('/api/rules/app', 'app.json');
+ lib.mockRequestFromFile('/api/rules/search', 'search-not-inherited.json', { data: { inheritance: 'NONE' } });
+ lib.mockRequestFromFile('/api/rules/search', 'search-inherited.json', { data: { inheritance: 'INHERITED' } });
+ lib.mockRequestFromFile('/api/rules/search', 'search-overriden.json', { data: { inheritance: 'OVERRIDES' } });
+ lib.mockRequestFromFile('/api/rules/search', 'search-qprofile.json',
+ { data: { qprofile: 'java-default-with-mojo-conventions-49307' } });
+ lib.mockRequestFromFile('/api/rules/search', 'search-qprofile2.json',
+ { data: { qprofile: 'java-top-profile-without-formatting-conventions-50037' } });
+ lib.mockRequestFromFile('/api/rules/search', 'search.json');
+ })
+
+ .then(function () {
+ casper.waitForSelector('.coding-rule');
+ })
+
+ .then(function () {
+ test.assertSelectorContains('#coding-rules-total', '609');
+ test.assertExists('.search-navigator-facet-box-forbidden[data-property="inheritance"]');
+ casper.click('[data-property="qprofile"] .js-facet-toggle');
+ casper.waitForSelector('.js-facet[data-value="java-default-with-mojo-conventions-49307"]');
+ })
+
+ .then(function () {
+ casper.click('.js-facet[data-value="java-default-with-mojo-conventions-49307"]');
+ casper.waitForSelectorTextChange('#coding-rules-total');
+ })
+
+ .then(function () {
+ test.assertSelectorContains('#coding-rules-total', '407');
+ test.assertDoesntExist('.search-navigator-facet-box-forbidden[data-property="inheritance"]');
+ casper.click('[data-property="inheritance"] .js-facet-toggle');
+ casper.waitForSelector('[data-property="inheritance"] [data-value="NONE"]');
+ })
+
+ .then(function () {
+ casper.click('[data-property="inheritance"] [data-value="NONE"]');
+ casper.waitForSelectorTextChange('#coding-rules-total');
+ })
+
+ .then(function () {
+ test.assertSelectorContains('#coding-rules-total', '103');
+ casper.click('[data-property="inheritance"] [data-value="INHERITED"]');
+ casper.waitForSelectorTextChange('#coding-rules-total');
+ })
+
+ .then(function () {
+ test.assertSelectorContains('#coding-rules-total', '101');
+ casper.click('[data-property="inheritance"] [data-value="OVERRIDES"]');
+ casper.waitForSelectorTextChange('#coding-rules-total');
+ })
+
+ .then(function () {
+ test.assertSelectorContains('#coding-rules-total', '102');
+ casper.click('.js-facet[data-value="java-top-profile-without-formatting-conventions-50037"]');
+ casper.waitForSelectorTextChange('#coding-rules-total');
+ })
+
+ .then(function () {
+ test.assertSelectorContains('#coding-rules-total', '408');
+ test.assertExists('.search-navigator-facet-box-forbidden[data-property="inheritance"]');
+ casper.click('[data-property="qprofile"] .js-facet-toggle');
+ casper.waitForSelectorTextChange('#coding-rules-total');
+ })
+
+ .then(function () {
+ test.assertSelectorContains('#coding-rules-total', '609');
+ test.assertExists('.search-navigator-facet-box-forbidden[data-property="inheritance"]');
+ })
+
+ .run(function () {
+ test.done();
+ });
+});
--- /dev/null
+{
+ "canWrite": false,
+ "qualityprofiles": [
+ {
+ "key": "java-default-with-mojo-conventions-49307",
+ "name": "Default - Maven Conventions",
+ "lang": "java",
+ "parentKey": "java-top-profile-without-formatting-conventions-50037"
+ },
+ {
+ "key": "java-default-with-sonarsource-conventions-27339",
+ "name": "Default - SonarSource conventions",
+ "lang": "java",
+ "parentKey": "java-top-profile-without-formatting-conventions-50037"
+ },
+ {
+ "key": "java-top-profile-without-formatting-conventions-50037",
+ "name": "Default - Top",
+ "lang": "java"
+ },
+ {
+ "key": "java-findbugs-14954",
+ "name": "FindBugs",
+ "lang": "java"
+ },
+ {
+ "key": "java-for-sq-java-plugin-only-92289",
+ "name": "For SQ Java Plugin Only",
+ "lang": "java",
+ "parentKey": "java-default-with-sonarsource-conventions-27339"
+ },
+ {
+ "key": "java-for-sq-only-95381",
+ "name": "For SQ Only",
+ "lang": "java",
+ "parentKey": "java-default-with-sonarsource-conventions-27339"
+ },
+ {
+ "key": "php-psr-2-06315",
+ "name": "PSR-2",
+ "lang": "php"
+ },
+ {
+ "key": "java-sonar-way-80423",
+ "name": "Sonar way",
+ "lang": "java"
+ },
+ {
+ "key": "js-sonar-way",
+ "name": "Sonar way",
+ "lang": "js"
+ },
+ {
+ "key": "php-sonar-way-05548",
+ "name": "Sonar way",
+ "lang": "php"
+ },
+ {
+ "key": "py-sonar-way-80265",
+ "name": "Sonar way",
+ "lang": "py"
+ },
+ {
+ "key": "java-without-findbugs",
+ "name": "Without Findbugs",
+ "lang": "java"
+ }
+ ],
+ "languages": {
+ "py": "Python",
+ "js": "JavaScript",
+ "php": "PHP",
+ "java": "Java"
+ },
+ "repositories": [
+ {
+ "key": "common-java",
+ "name": "Common SonarQube",
+ "language": "java"
+ },
+ {
+ "key": "common-js",
+ "name": "Common SonarQube",
+ "language": "js"
+ },
+ {
+ "key": "common-php",
+ "name": "Common SonarQube",
+ "language": "php"
+ },
+ {
+ "key": "common-py",
+ "name": "Common SonarQube",
+ "language": "py"
+ },
+ {
+ "key": "Pylint",
+ "name": "Pylint",
+ "language": "py"
+ },
+ {
+ "key": "javascript",
+ "name": "SonarQube",
+ "language": "js"
+ },
+ {
+ "key": "php",
+ "name": "SonarQube",
+ "language": "php"
+ },
+ {
+ "key": "python",
+ "name": "SonarQube",
+ "language": "py"
+ },
+ {
+ "key": "squid",
+ "name": "SonarQube",
+ "language": "java"
+ }
+ ],
+ "statuses": {
+ "BETA": "Beta",
+ "DEPRECATED": "Deprecated",
+ "READY": "Ready"
+ },
+ "characteristics": {
+ "UNDERSTANDABILITY": "Maintainability: Understandability",
+ "MAINTAINABILITY": "Maintainability",
+ "TIME_ZONE_RELATED_PORTABILITY": "Portability: Time zone related portability",
+ "READABILITY": "Maintainability: Readability",
+ "SECURITY_FEATURES": "Security: Security features",
+ "ARCHITECTURE_RELIABILITY": "Reliability: Architecture related reliability",
+ "OS_RELATED_PORTABILITY": "Portability: OS related portability",
+ "EXCEPTION_HANDLING": "Reliability: Exception handling",
+ "LOGIC_CHANGEABILITY": "Changeability: Logic related changeability",
+ "SOFTWARE_RELATED_PORTABILITY": "Portability: Software related portability",
+ "INPUT_VALIDATION_AND_REPRESENTATION": "Security: Input validation and representation",
+ "LANGUAGE_RELATED_PORTABILITY": "Portability: Language related portability",
+ "ERRORS": "Security: Errors",
+ "SECURITY": "Security",
+ "RELIABILITY": "Reliability",
+ "PORTABILITY": "Portability",
+ "HARDWARE_RELATED_PORTABILITY": "Portability: Hardware related portability",
+ "SYNCHRONIZATION_RELIABILITY": "Reliability: Synchronization related reliability",
+ "TRANSPORTABILITY": "Reusability: Transportability",
+ "COMPILER_RELATED_PORTABILITY": "Portability: Compiler related portability",
+ "RESOURCE_RELIABILITY": "Reliability: Resource",
+ "CPU_EFFICIENCY": "Efficiency: Processor use",
+ "EFFICIENCY": "Efficiency",
+ "CHANGEABILITY": "Changeability",
+ "DATA_CHANGEABILITY": "Changeability: Data related changeability",
+ "API_ABUSE": "Security: API abuse",
+ "ARCHITECTURE_CHANGEABILITY": "Changeability: Architecture related changeability",
+ "UNIT_TESTS": "Reliability: Unit tests",
+ "INSTRUCTION_RELIABILITY": "Reliability: Instruction related reliability",
+ "REUSABILITY": "Reusability",
+ "MODULARITY": "Reusability: Modularity",
+ "UNIT_TESTABILITY": "Testability: Unit level testability",
+ "TESTABILITY": "Testability",
+ "INTEGRATION_TESTABILITY": "Testability: Integration level testability",
+ "NETWORK_USE": "Efficiency: Network use",
+ "MEMORY_EFFICIENCY": "Efficiency: Memory use",
+ "DATA_RELIABILITY": "Reliability: Data related reliability",
+ "FAULT_TOLERANCE": "Reliability: Fault tolerance",
+ "LOGIC_RELIABILITY": "Reliability: Logic related reliability"
+ }
+}
--- /dev/null
+{
+ "total": 101,
+ "p": 1,
+ "ps": 25,
+ "rules": [
+ {
+ "key": "squid:S2077",
+ "name": "Values passed to SQL commands should be sanitized",
+ "lang": "java",
+ "langName": "Java",
+ "sysTags": [
+ "cwe",
+ "owasp-top10",
+ "security",
+ "sql"
+ ],
+ "tags": [
+ "custom-tag"
+ ]
+ },
+ {
+ "key": "php:S107",
+ "name": "Functions should not have too many parameters",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1192",
+ "name": "String literals should not be duplicated",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1145",
+ "name": "\"if\" statement conditions should not always evaluate to \"true\" or to \"false\"",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "bug",
+ "cwe",
+ "security"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S108",
+ "name": "Nested blocks of code should not be left empty",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1301",
+ "name": "\"switch\" statements should have at least 3 \"case\" clauses",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S103",
+ "name": "Lines should not be too long",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1144",
+ "name": "Unused private method should be removed",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "unused"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S105",
+ "name": "Tabulation characters should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention",
+ "psr2"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1481",
+ "name": "Unused local variables should be removed",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "unused"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1142",
+ "name": "Functions should not contain too many return statements",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S104",
+ "name": "Files should not have too many lines",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1605",
+ "name": "PHP 4 style calls to parent constructors should not be used in PHP5 \"__construct\" functions",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1448",
+ "name": "Classes should not have too many methods",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1603",
+ "name": "PHP 4 constructor declarations should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1779",
+ "name": "Only LF character (Unix-like) should be used to end lines",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention",
+ "psr2"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1185",
+ "name": "Overriding methods should do more than simply call the same method in the super class",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1600",
+ "name": "Deprecated predefined variables should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1109",
+ "name": "A close curly brace should be located at the beginning of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2001",
+ "name": "Functions deprecated in PHP 5 should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "obsolete"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2002",
+ "name": "Errors should not be silenced",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2000",
+ "name": "Files should not contain characters before \"<?php\"",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "user-experience"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1105",
+ "name": "An open curly brace should be located at the end of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1200",
+ "name": "Classes should not be coupled to too many other classes (Single Responsibility Principle)",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1106",
+ "name": "An open curly brace should be located at the beginning of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ }
+ ],
+ "facets": [
+ {
+ "property": "tags",
+ "values": [
+ {
+ "val": "convention",
+ "count": 67
+ },
+ {
+ "val": "brain-overload",
+ "count": 36
+ },
+ {
+ "val": "bug",
+ "count": 36
+ },
+ {
+ "val": "cwe",
+ "count": 17
+ },
+ {
+ "val": "unused",
+ "count": 16
+ },
+ {
+ "val": "security",
+ "count": 14
+ },
+ {
+ "val": "pitfall",
+ "count": 12
+ },
+ {
+ "val": "psr2",
+ "count": 12
+ },
+ {
+ "val": "error-handling",
+ "count": 11
+ },
+ {
+ "val": "pitfail",
+ "count": 10
+ }
+ ]
+ },
+ {
+ "property": "languages",
+ "values": [
+ {
+ "val": "java",
+ "count": 212
+ },
+ {
+ "val": "py",
+ "count": 212
+ },
+ {
+ "val": "php",
+ "count": 103
+ },
+ {
+ "val": "js",
+ "count": 77
+ }
+ ]
+ },
+ {
+ "property": "repositories",
+ "values": [
+ {
+ "val": "squid",
+ "count": 206
+ },
+ {
+ "val": "Pylint",
+ "count": 180
+ },
+ {
+ "val": "php",
+ "count": 97
+ },
+ {
+ "val": "javascript",
+ "count": 73
+ },
+ {
+ "val": "python",
+ "count": 28
+ },
+ {
+ "val": "common-java",
+ "count": 6
+ },
+ {
+ "val": "common-php",
+ "count": 6
+ },
+ {
+ "val": "manual",
+ "count": 5
+ },
+ {
+ "val": "common-js",
+ "count": 4
+ },
+ {
+ "val": "common-py",
+ "count": 4
+ }
+ ]
+ }
+ ]
+}
--- /dev/null
+{
+ "total": 103,
+ "p": 1,
+ "ps": 25,
+ "rules": [
+ {
+ "key": "squid:S2077",
+ "name": "Values passed to SQL commands should be sanitized",
+ "lang": "java",
+ "langName": "Java",
+ "sysTags": [
+ "cwe",
+ "owasp-top10",
+ "security",
+ "sql"
+ ],
+ "tags": [
+ "custom-tag"
+ ]
+ },
+ {
+ "key": "php:S107",
+ "name": "Functions should not have too many parameters",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1192",
+ "name": "String literals should not be duplicated",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1145",
+ "name": "\"if\" statement conditions should not always evaluate to \"true\" or to \"false\"",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "bug",
+ "cwe",
+ "security"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S108",
+ "name": "Nested blocks of code should not be left empty",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1301",
+ "name": "\"switch\" statements should have at least 3 \"case\" clauses",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S103",
+ "name": "Lines should not be too long",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1144",
+ "name": "Unused private method should be removed",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "unused"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S105",
+ "name": "Tabulation characters should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention",
+ "psr2"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1481",
+ "name": "Unused local variables should be removed",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "unused"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1142",
+ "name": "Functions should not contain too many return statements",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S104",
+ "name": "Files should not have too many lines",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1605",
+ "name": "PHP 4 style calls to parent constructors should not be used in PHP5 \"__construct\" functions",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1448",
+ "name": "Classes should not have too many methods",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1603",
+ "name": "PHP 4 constructor declarations should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1779",
+ "name": "Only LF character (Unix-like) should be used to end lines",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention",
+ "psr2"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1185",
+ "name": "Overriding methods should do more than simply call the same method in the super class",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1600",
+ "name": "Deprecated predefined variables should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1109",
+ "name": "A close curly brace should be located at the beginning of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2001",
+ "name": "Functions deprecated in PHP 5 should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "obsolete"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2002",
+ "name": "Errors should not be silenced",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2000",
+ "name": "Files should not contain characters before \"<?php\"",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "user-experience"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1105",
+ "name": "An open curly brace should be located at the end of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1200",
+ "name": "Classes should not be coupled to too many other classes (Single Responsibility Principle)",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1106",
+ "name": "An open curly brace should be located at the beginning of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ }
+ ],
+ "facets": [
+ {
+ "property": "tags",
+ "values": [
+ {
+ "val": "convention",
+ "count": 67
+ },
+ {
+ "val": "brain-overload",
+ "count": 36
+ },
+ {
+ "val": "bug",
+ "count": 36
+ },
+ {
+ "val": "cwe",
+ "count": 17
+ },
+ {
+ "val": "unused",
+ "count": 16
+ },
+ {
+ "val": "security",
+ "count": 14
+ },
+ {
+ "val": "pitfall",
+ "count": 12
+ },
+ {
+ "val": "psr2",
+ "count": 12
+ },
+ {
+ "val": "error-handling",
+ "count": 11
+ },
+ {
+ "val": "pitfail",
+ "count": 10
+ }
+ ]
+ },
+ {
+ "property": "languages",
+ "values": [
+ {
+ "val": "java",
+ "count": 212
+ },
+ {
+ "val": "py",
+ "count": 212
+ },
+ {
+ "val": "php",
+ "count": 103
+ },
+ {
+ "val": "js",
+ "count": 77
+ }
+ ]
+ },
+ {
+ "property": "repositories",
+ "values": [
+ {
+ "val": "squid",
+ "count": 206
+ },
+ {
+ "val": "Pylint",
+ "count": 180
+ },
+ {
+ "val": "php",
+ "count": 97
+ },
+ {
+ "val": "javascript",
+ "count": 73
+ },
+ {
+ "val": "python",
+ "count": 28
+ },
+ {
+ "val": "common-java",
+ "count": 6
+ },
+ {
+ "val": "common-php",
+ "count": 6
+ },
+ {
+ "val": "manual",
+ "count": 5
+ },
+ {
+ "val": "common-js",
+ "count": 4
+ },
+ {
+ "val": "common-py",
+ "count": 4
+ }
+ ]
+ }
+ ]
+}
--- /dev/null
+{
+ "total": 102,
+ "p": 1,
+ "ps": 25,
+ "rules": [
+ {
+ "key": "squid:S2077",
+ "name": "Values passed to SQL commands should be sanitized",
+ "lang": "java",
+ "langName": "Java",
+ "sysTags": [
+ "cwe",
+ "owasp-top10",
+ "security",
+ "sql"
+ ],
+ "tags": [
+ "custom-tag"
+ ]
+ },
+ {
+ "key": "php:S107",
+ "name": "Functions should not have too many parameters",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1192",
+ "name": "String literals should not be duplicated",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1145",
+ "name": "\"if\" statement conditions should not always evaluate to \"true\" or to \"false\"",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "bug",
+ "cwe",
+ "security"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S108",
+ "name": "Nested blocks of code should not be left empty",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1301",
+ "name": "\"switch\" statements should have at least 3 \"case\" clauses",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S103",
+ "name": "Lines should not be too long",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1144",
+ "name": "Unused private method should be removed",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "unused"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S105",
+ "name": "Tabulation characters should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention",
+ "psr2"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1481",
+ "name": "Unused local variables should be removed",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "unused"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1142",
+ "name": "Functions should not contain too many return statements",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S104",
+ "name": "Files should not have too many lines",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1605",
+ "name": "PHP 4 style calls to parent constructors should not be used in PHP5 \"__construct\" functions",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1448",
+ "name": "Classes should not have too many methods",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1603",
+ "name": "PHP 4 constructor declarations should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1779",
+ "name": "Only LF character (Unix-like) should be used to end lines",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention",
+ "psr2"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1185",
+ "name": "Overriding methods should do more than simply call the same method in the super class",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1600",
+ "name": "Deprecated predefined variables should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1109",
+ "name": "A close curly brace should be located at the beginning of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2001",
+ "name": "Functions deprecated in PHP 5 should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "obsolete"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2002",
+ "name": "Errors should not be silenced",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2000",
+ "name": "Files should not contain characters before \"<?php\"",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "user-experience"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1105",
+ "name": "An open curly brace should be located at the end of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1200",
+ "name": "Classes should not be coupled to too many other classes (Single Responsibility Principle)",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1106",
+ "name": "An open curly brace should be located at the beginning of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ }
+ ],
+ "facets": [
+ {
+ "property": "tags",
+ "values": [
+ {
+ "val": "convention",
+ "count": 67
+ },
+ {
+ "val": "brain-overload",
+ "count": 36
+ },
+ {
+ "val": "bug",
+ "count": 36
+ },
+ {
+ "val": "cwe",
+ "count": 17
+ },
+ {
+ "val": "unused",
+ "count": 16
+ },
+ {
+ "val": "security",
+ "count": 14
+ },
+ {
+ "val": "pitfall",
+ "count": 12
+ },
+ {
+ "val": "psr2",
+ "count": 12
+ },
+ {
+ "val": "error-handling",
+ "count": 11
+ },
+ {
+ "val": "pitfail",
+ "count": 10
+ }
+ ]
+ },
+ {
+ "property": "languages",
+ "values": [
+ {
+ "val": "java",
+ "count": 212
+ },
+ {
+ "val": "py",
+ "count": 212
+ },
+ {
+ "val": "php",
+ "count": 103
+ },
+ {
+ "val": "js",
+ "count": 77
+ }
+ ]
+ },
+ {
+ "property": "repositories",
+ "values": [
+ {
+ "val": "squid",
+ "count": 206
+ },
+ {
+ "val": "Pylint",
+ "count": 180
+ },
+ {
+ "val": "php",
+ "count": 97
+ },
+ {
+ "val": "javascript",
+ "count": 73
+ },
+ {
+ "val": "python",
+ "count": 28
+ },
+ {
+ "val": "common-java",
+ "count": 6
+ },
+ {
+ "val": "common-php",
+ "count": 6
+ },
+ {
+ "val": "manual",
+ "count": 5
+ },
+ {
+ "val": "common-js",
+ "count": 4
+ },
+ {
+ "val": "common-py",
+ "count": 4
+ }
+ ]
+ }
+ ]
+}
--- /dev/null
+{
+ "total": 407,
+ "p": 1,
+ "ps": 25,
+ "rules": [
+ {
+ "key": "squid:S2077",
+ "name": "Values passed to SQL commands should be sanitized",
+ "lang": "java",
+ "langName": "Java",
+ "sysTags": [
+ "cwe",
+ "owasp-top10",
+ "security",
+ "sql"
+ ],
+ "tags": [
+ "custom-tag"
+ ]
+ },
+ {
+ "key": "php:S107",
+ "name": "Functions should not have too many parameters",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1192",
+ "name": "String literals should not be duplicated",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1145",
+ "name": "\"if\" statement conditions should not always evaluate to \"true\" or to \"false\"",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "bug",
+ "cwe",
+ "security"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S108",
+ "name": "Nested blocks of code should not be left empty",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1301",
+ "name": "\"switch\" statements should have at least 3 \"case\" clauses",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S103",
+ "name": "Lines should not be too long",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1144",
+ "name": "Unused private method should be removed",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "unused"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S105",
+ "name": "Tabulation characters should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention",
+ "psr2"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1481",
+ "name": "Unused local variables should be removed",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "unused"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1142",
+ "name": "Functions should not contain too many return statements",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S104",
+ "name": "Files should not have too many lines",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1605",
+ "name": "PHP 4 style calls to parent constructors should not be used in PHP5 \"__construct\" functions",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1448",
+ "name": "Classes should not have too many methods",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1603",
+ "name": "PHP 4 constructor declarations should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1779",
+ "name": "Only LF character (Unix-like) should be used to end lines",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention",
+ "psr2"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1185",
+ "name": "Overriding methods should do more than simply call the same method in the super class",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1600",
+ "name": "Deprecated predefined variables should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1109",
+ "name": "A close curly brace should be located at the beginning of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2001",
+ "name": "Functions deprecated in PHP 5 should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "obsolete"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2002",
+ "name": "Errors should not be silenced",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2000",
+ "name": "Files should not contain characters before \"<?php\"",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "user-experience"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1105",
+ "name": "An open curly brace should be located at the end of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1200",
+ "name": "Classes should not be coupled to too many other classes (Single Responsibility Principle)",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1106",
+ "name": "An open curly brace should be located at the beginning of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ }
+ ],
+ "facets": [
+ {
+ "property": "tags",
+ "values": [
+ {
+ "val": "convention",
+ "count": 67
+ },
+ {
+ "val": "brain-overload",
+ "count": 36
+ },
+ {
+ "val": "bug",
+ "count": 36
+ },
+ {
+ "val": "cwe",
+ "count": 17
+ },
+ {
+ "val": "unused",
+ "count": 16
+ },
+ {
+ "val": "security",
+ "count": 14
+ },
+ {
+ "val": "pitfall",
+ "count": 12
+ },
+ {
+ "val": "psr2",
+ "count": 12
+ },
+ {
+ "val": "error-handling",
+ "count": 11
+ },
+ {
+ "val": "pitfail",
+ "count": 10
+ }
+ ]
+ },
+ {
+ "property": "languages",
+ "values": [
+ {
+ "val": "java",
+ "count": 212
+ },
+ {
+ "val": "py",
+ "count": 212
+ },
+ {
+ "val": "php",
+ "count": 103
+ },
+ {
+ "val": "js",
+ "count": 77
+ }
+ ]
+ },
+ {
+ "property": "repositories",
+ "values": [
+ {
+ "val": "squid",
+ "count": 206
+ },
+ {
+ "val": "Pylint",
+ "count": 180
+ },
+ {
+ "val": "php",
+ "count": 97
+ },
+ {
+ "val": "javascript",
+ "count": 73
+ },
+ {
+ "val": "python",
+ "count": 28
+ },
+ {
+ "val": "common-java",
+ "count": 6
+ },
+ {
+ "val": "common-php",
+ "count": 6
+ },
+ {
+ "val": "manual",
+ "count": 5
+ },
+ {
+ "val": "common-js",
+ "count": 4
+ },
+ {
+ "val": "common-py",
+ "count": 4
+ }
+ ]
+ }
+ ]
+}
--- /dev/null
+{
+ "total": 408,
+ "p": 1,
+ "ps": 25,
+ "rules": [
+ {
+ "key": "squid:S2077",
+ "name": "Values passed to SQL commands should be sanitized",
+ "lang": "java",
+ "langName": "Java",
+ "sysTags": [
+ "cwe",
+ "owasp-top10",
+ "security",
+ "sql"
+ ],
+ "tags": [
+ "custom-tag"
+ ]
+ },
+ {
+ "key": "php:S107",
+ "name": "Functions should not have too many parameters",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1192",
+ "name": "String literals should not be duplicated",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1145",
+ "name": "\"if\" statement conditions should not always evaluate to \"true\" or to \"false\"",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "bug",
+ "cwe",
+ "security"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S108",
+ "name": "Nested blocks of code should not be left empty",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1301",
+ "name": "\"switch\" statements should have at least 3 \"case\" clauses",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S103",
+ "name": "Lines should not be too long",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1144",
+ "name": "Unused private method should be removed",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "unused"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S105",
+ "name": "Tabulation characters should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention",
+ "psr2"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1481",
+ "name": "Unused local variables should be removed",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "unused"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1142",
+ "name": "Functions should not contain too many return statements",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S104",
+ "name": "Files should not have too many lines",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1605",
+ "name": "PHP 4 style calls to parent constructors should not be used in PHP5 \"__construct\" functions",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1448",
+ "name": "Classes should not have too many methods",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1603",
+ "name": "PHP 4 constructor declarations should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1779",
+ "name": "Only LF character (Unix-like) should be used to end lines",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention",
+ "psr2"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1185",
+ "name": "Overriding methods should do more than simply call the same method in the super class",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1600",
+ "name": "Deprecated predefined variables should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1109",
+ "name": "A close curly brace should be located at the beginning of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2001",
+ "name": "Functions deprecated in PHP 5 should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "obsolete"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2002",
+ "name": "Errors should not be silenced",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2000",
+ "name": "Files should not contain characters before \"<?php\"",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "user-experience"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1105",
+ "name": "An open curly brace should be located at the end of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1200",
+ "name": "Classes should not be coupled to too many other classes (Single Responsibility Principle)",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1106",
+ "name": "An open curly brace should be located at the beginning of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ }
+ ],
+ "facets": [
+ {
+ "property": "tags",
+ "values": [
+ {
+ "val": "convention",
+ "count": 67
+ },
+ {
+ "val": "brain-overload",
+ "count": 36
+ },
+ {
+ "val": "bug",
+ "count": 36
+ },
+ {
+ "val": "cwe",
+ "count": 17
+ },
+ {
+ "val": "unused",
+ "count": 16
+ },
+ {
+ "val": "security",
+ "count": 14
+ },
+ {
+ "val": "pitfall",
+ "count": 12
+ },
+ {
+ "val": "psr2",
+ "count": 12
+ },
+ {
+ "val": "error-handling",
+ "count": 11
+ },
+ {
+ "val": "pitfail",
+ "count": 10
+ }
+ ]
+ },
+ {
+ "property": "languages",
+ "values": [
+ {
+ "val": "java",
+ "count": 212
+ },
+ {
+ "val": "py",
+ "count": 212
+ },
+ {
+ "val": "php",
+ "count": 103
+ },
+ {
+ "val": "js",
+ "count": 77
+ }
+ ]
+ },
+ {
+ "property": "repositories",
+ "values": [
+ {
+ "val": "squid",
+ "count": 206
+ },
+ {
+ "val": "Pylint",
+ "count": 180
+ },
+ {
+ "val": "php",
+ "count": 97
+ },
+ {
+ "val": "javascript",
+ "count": 73
+ },
+ {
+ "val": "python",
+ "count": 28
+ },
+ {
+ "val": "common-java",
+ "count": 6
+ },
+ {
+ "val": "common-php",
+ "count": 6
+ },
+ {
+ "val": "manual",
+ "count": 5
+ },
+ {
+ "val": "common-js",
+ "count": 4
+ },
+ {
+ "val": "common-py",
+ "count": 4
+ }
+ ]
+ }
+ ]
+}
--- /dev/null
+{
+ "total": 609,
+ "p": 1,
+ "ps": 25,
+ "rules": [
+ {
+ "key": "squid:S2077",
+ "name": "Values passed to SQL commands should be sanitized",
+ "lang": "java",
+ "langName": "Java",
+ "sysTags": [
+ "cwe",
+ "owasp-top10",
+ "security",
+ "sql"
+ ],
+ "tags": [
+ "custom-tag"
+ ]
+ },
+ {
+ "key": "php:S107",
+ "name": "Functions should not have too many parameters",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1192",
+ "name": "String literals should not be duplicated",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1145",
+ "name": "\"if\" statement conditions should not always evaluate to \"true\" or to \"false\"",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "bug",
+ "cwe",
+ "security"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S108",
+ "name": "Nested blocks of code should not be left empty",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1301",
+ "name": "\"switch\" statements should have at least 3 \"case\" clauses",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S103",
+ "name": "Lines should not be too long",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1144",
+ "name": "Unused private method should be removed",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "unused"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S105",
+ "name": "Tabulation characters should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention",
+ "psr2"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1481",
+ "name": "Unused local variables should be removed",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "unused"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1142",
+ "name": "Functions should not contain too many return statements",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S104",
+ "name": "Files should not have too many lines",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1605",
+ "name": "PHP 4 style calls to parent constructors should not be used in PHP5 \"__construct\" functions",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1448",
+ "name": "Classes should not have too many methods",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1603",
+ "name": "PHP 4 constructor declarations should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1779",
+ "name": "Only LF character (Unix-like) should be used to end lines",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention",
+ "psr2"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1185",
+ "name": "Overriding methods should do more than simply call the same method in the super class",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [],
+ "tags": []
+ },
+ {
+ "key": "php:S1600",
+ "name": "Deprecated predefined variables should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1109",
+ "name": "A close curly brace should be located at the beginning of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2001",
+ "name": "Functions deprecated in PHP 5 should not be used",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "obsolete"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2002",
+ "name": "Errors should not be silenced",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "pitfail"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S2000",
+ "name": "Files should not contain characters before \"<?php\"",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "user-experience"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1105",
+ "name": "An open curly brace should be located at the end of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1200",
+ "name": "Classes should not be coupled to too many other classes (Single Responsibility Principle)",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "brain-overload"
+ ],
+ "tags": []
+ },
+ {
+ "key": "php:S1106",
+ "name": "An open curly brace should be located at the beginning of a line",
+ "lang": "php",
+ "langName": "PHP",
+ "sysTags": [
+ "convention"
+ ],
+ "tags": []
+ }
+ ],
+ "facets": [
+ {
+ "property": "tags",
+ "values": [
+ {
+ "val": "convention",
+ "count": 67
+ },
+ {
+ "val": "brain-overload",
+ "count": 36
+ },
+ {
+ "val": "bug",
+ "count": 36
+ },
+ {
+ "val": "cwe",
+ "count": 17
+ },
+ {
+ "val": "unused",
+ "count": 16
+ },
+ {
+ "val": "security",
+ "count": 14
+ },
+ {
+ "val": "pitfall",
+ "count": 12
+ },
+ {
+ "val": "psr2",
+ "count": 12
+ },
+ {
+ "val": "error-handling",
+ "count": 11
+ },
+ {
+ "val": "pitfail",
+ "count": 10
+ }
+ ]
+ },
+ {
+ "property": "languages",
+ "values": [
+ {
+ "val": "java",
+ "count": 212
+ },
+ {
+ "val": "py",
+ "count": 212
+ },
+ {
+ "val": "php",
+ "count": 103
+ },
+ {
+ "val": "js",
+ "count": 77
+ }
+ ]
+ },
+ {
+ "property": "repositories",
+ "values": [
+ {
+ "val": "squid",
+ "count": 206
+ },
+ {
+ "val": "Pylint",
+ "count": 180
+ },
+ {
+ "val": "php",
+ "count": 97
+ },
+ {
+ "val": "javascript",
+ "count": 73
+ },
+ {
+ "val": "python",
+ "count": 28
+ },
+ {
+ "val": "common-java",
+ "count": 6
+ },
+ {
+ "val": "common-php",
+ "count": 6
+ },
+ {
+ "val": "manual",
+ "count": 5
+ },
+ {
+ "val": "common-js",
+ "count": 4
+ },
+ {
+ "val": "common-py",
+ "count": 4
+ }
+ ]
+ }
+ ]
+}
}
}
+.search-navigator-facet-box-forbidden {
+ .search-navigator-facet-box-collapsed;
+ opacity: 0.5;
+
+ .search-navigator-facet-header {
+ cursor: default;
+
+ &:hover { color: @secondFontColor; }
+ }
+}
+
.search-navigator-facet {
position: relative;
width: 100%;
coding_rules.filters.quality_profile=Quality Profile
coding_rules.filters.inheritance=Inheritance
coding_rules.filters.inheritance.inactive=Inheritance criterion is available when an inherited quality profile is selected
-coding_rules.filters.inheritance.not_inherited=Not Inherited
+coding_rules.filters.inheritance.none=Not Inherited
coding_rules.filters.inheritance.inherited=Inherited
-coding_rules.filters.inheritance.overriden=Overriden
+coding_rules.filters.inheritance.overrides=Overriden
coding_rules.filters.key=Key
coding_rules.filters.language=Language
coding_rules.filters.name=Name
coding_rules.facet.severities=Severity
coding_rules.facet.statuses=Status
coding_rules.facet.available_since=Available Since
+coding_rules.facet.inheritance=Inheritance
coding_rules.facets.languages=Languages
coding_rules.facets.tags=Tags